Opened 3 years ago

Closed 2 years ago

Last modified 2 years ago

#54372 closed defect (fixed)

scidavis @1.22 isn't using the right compiler

Reported by: ryandesign (Ryan Schmidt) Owned by: NicosPavlov
Priority: Normal Milestone:
Component: ports Version:
Keywords: Cc:
Port: scidavis

Description

scidavis is hardcoded to build with clang++; this fails on systems that don't have clang++ provided by Xcode, such as Snow Leopard and earlier.

https://build.macports.org/builders/ports-10.5_ppc_legacy-builder/builds/33968:

https://build.macports.org/builders/ports-10.6_x86_64_legacy-builder/builds/34520

make[1]: clang++: Command not found

scidavis should be UsingTheRightCompiler. If it requires clang, it should be blacklisting compilers that are not clang.

Attachments (2)

patch-Portfile-scidavis.diff (812 bytes) - added by NicosPavlov 2 years ago.
scidavis-main.log (1000.8 KB) - added by NicosPavlov 2 years ago.

Download all attachments as: .zip

Change History (12)

comment:1 Changed 3 years ago by ryandesign (Ryan Schmidt)

Summary: scidavis @1.14 isn't using the right compilerscidavis @1.22 isn't using the right compiler

Problem remains with 1.22.

comment:2 Changed 3 years ago by NicosPavlov

Yes, some issues at qmake level make this problem not that easy to solve.

See this thread for reference: https://lists.macports.org/pipermail/macports-dev/2017-July/036022.html

comment:3 Changed 2 years ago by NicosPavlov

For reference, here is a diff of the Portfile that enables compilation with gcc. However, this ends up with linking problems (see main.log), so that gcc compilers will be blacklisted.

Changed 2 years ago by NicosPavlov

Changed 2 years ago by NicosPavlov

Attachment: scidavis-main.log added

comment:4 Changed 2 years ago by Nicolas Pavillon <pavillon.nicolas@…>

In 8b6a91ee06cb8d47b6baf6f632bec36c38adbfd3/macports-ports (master):

scidavis: update to 1.23, blacklist gcc compilers (see #54372)

comment:5 Changed 2 years ago by Nicolas Pavillon <pavillon.nicolas@…>

In d929f21c39f070c546f42050513bca411dcb0731/macports-ports (master):

scidavis uncomment use of portgroup compiler_blacklist, also blacklist old clang versions without c++ compilers (see #54372)

comment:6 Changed 2 years ago by Nicolas Pavillon <pavillon.nicolas@…>

In ea5c5104fca793be8cdad835fdffcabb5f129867/macports-ports (master):

scidavis: do not hardcode compiler (see #54372)

comment:7 Changed 2 years ago by kencu (Ken)

The build still fails, despite the cxx11 PortGroup. I'm fairly sure this is because the link line does not specify -stdlib as it should:

/opt/local/bin/clang++-mp-5.0 -L/opt/local/lib -Wl,-headerpad_max_install_names -arch x86_64 -Xarch_x86_64 -mmacosx-version-min=10.8 -o scidavis.app/Contents/MacOS/scidavis ../tmp/scidavis/main.o ../tmp/scidavis/qrc_appicons.o ../tmp/scidavis/qrc_icons.o   -F/opt/local/libexec/qt4/Library/Frameworks -F/opt/local/libexec/qt4/lib  -L../libscidavis -lscidavis -L/opt/local/lib -L/opt/local/local/lib -lqwt -lqwtplot3d -lgsl -lgslcblas -lz -lmuparser -lpython2.7 ../3rdparty/liborigin/liborigin.a -framework OpenGL -framework AGL -F/opt/local/libexec/qt4/Library/Frameworks -F/opt/local/libexec/qt4/lib -L/opt/local/libexec/qt4/lib -framework QtSvg -F/opt/local/Library/Frameworks -framework QtGui -framework QtCore -framework QtXml -framework QtOpenGL -framework QtNetwork 

This could be fixed by adding the stdlib=XXX onto the configure.cxx if the compiler is clang, or by digging in and figuring out why the CXX flags are not being included in the link line.

If you want any help with this, I can probably get this fixed for you.

Last edited 2 years ago by kencu (Ken) (previous) (diff)

comment:8 Changed 2 years ago by NicosPavlov

My main issue is that I lack testing capabilities for older systems, so that I am doing quite some trials and errors. If you have better testing capabilities or a better understanding of the issues, I sure welcome your help.

The port has a policy of openmaintainer anyway, so please feel free to improve the portfile.

comment:9 Changed 2 years ago by NicosPavlov

Resolution: fixed
Status: newclosed

Closing this ticket as while the port still does not compile on older platforms, the issue described in it (not using the right compiler) is in itself solved.

comment:10 Changed 2 years ago by kencu (Ken)

linking issue now fixed as well

Note: See TracTickets for help on using tickets.