Opened 7 years ago
Closed 5 years ago
#55781 closed defect (fixed)
kdevplatform @4.7.4: error: expected expression
Reported by: | fpiraneo (Francesco Piraneo G.) | Owned by: | NicosPavlov |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | ports | Version: | 2.4.2 |
Keywords: | Cc: | ||
Port: | kdevplatform |
Description
On MacOS High Sierra building kdevelop, building stops with the underlined error. Logfile attached.
Attachments (1)
Change History (11)
Changed 7 years ago by fpiraneo (Francesco Piraneo G.)
Attachment: | kdevplatform-build.log added |
---|
comment:1 Changed 7 years ago by fpiraneo (Francesco Piraneo G.)
Cc: | fpiraneo added |
---|
comment:2 Changed 7 years ago by ryandesign (Ryan Carsten Schmidt)
Cc: | fpiraneo removed |
---|---|
Owner: | set to NicosPavlov |
Port: | kdevplatform added; kdevelop removed |
Status: | new → assigned |
Summary: | kdevelop @4.7.4: "Failed to build kdevplatform: command execution failed" → kdevplatform @4.7.4: error: expected expression |
:info:build [ 53%] Building CXX object interfaces/CMakeFiles/kdevplatforminterfaces.dir/iuicontroller.cpp.o :info:build cd /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_kde_kdevplatform/kdevplatform/work/build/interfaces && /usr/bin/c++ -DKDE4_CMAKE_TOPLEVEL_DIR_LENGTH=147 -DKDE_DEFAULT_DEBUG_AREA=9502 -DKDE_DEPRECATED_WARNINGS -DMAKE_KDEVPLATFORMINTERFACES_LIB -DQT_NO_CAST_TO_ASCII -DQT_NO_STL -DQT_USE_FAST_CONCATENATION -DQT_USE_FAST_OPERATOR_PLUS -DQURL_NO_CAST_FROM_QSTRING -D_REENTRANT -I/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_kde_kdevplatform/kdevplatform/work/build/interfaces -I/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_kde_kdevplatform/kdevplatform/work/kdevplatform-1.7.4/interfaces -I/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_kde_kdevplatform/kdevplatform/work/kdevplatform-1.7.4 -I/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_kde_kdevplatform/kdevplatform/work/build -I/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_kde_kdevplatform/kdevplatform/work/kdevplatform-1.7.4/util -I/opt/local/include/KDE4 -I/opt/local/include/KDE4/KDE -I/opt/local/include/KDE -I/opt/local/include -I/opt/local/libexec/qt4/include/QtXmlPatterns -I/opt/local/libexec/qt4/include/QtXml -I/opt/local/libexec/qt4/include/QtWebKit -I/opt/local/libexec/qt4/include/QtUiTools -I/opt/local/libexec/qt4/include/QtTest -I/opt/local/libexec/qt4/include/QtSvg -I/opt/local/libexec/qt4/include/QtSql -I/opt/local/libexec/qt4/include/QtScriptTools -I/opt/local/libexec/qt4/include/QtScript -I/opt/local/libexec/qt4/include/QtOpenGL -I/opt/local/libexec/qt4/include/QtNetwork -I/opt/local/libexec/qt4/include/QtMultimedia -I/opt/local/libexec/qt4/include/QtHelp -I/opt/local/libexec/qt4/include/QtDesigner -I/opt/local/libexec/qt4/include/QtDeclarative -I/opt/local/libexec/qt4/include/QtDBus -I/opt/local/libexec/qt4/include/Qt3Support -I/opt/local/libexec/qt4/include/QtGui -I/opt/local/libexec/qt4/include/QtCore -I/opt/local/libexec/qt4/include -I/opt/local/libexec/qt4/share/mkspecs/default -pipe -Os -fno-common -DNDEBUG -DQT_NO_DEBUG -arch x86_64 -mmacosx-version-min=10.13 -fPIC -D__APPLE_KDE__ -o CMakeFiles/kdevplatforminterfaces.dir/iuicontroller.cpp.o -c /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_kde_kdevplatform/kdevplatform/work/kdevplatform-1.7.4/interfaces/iuicontroller.cpp :info:build In file included from /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_kde_kdevplatform/kdevplatform/work/kdevplatform-1.7.4/interfaces/iplugin.cpp:40: :info:build /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_kde_kdevplatform/kdevplatform/work/kdevplatform-1.7.4/interfaces/iplugincontroller.h:126:108: error: expected expression :info:build Q_SCRIPTABLE virtual IPlugin *pluginForExtension(const QString &extension, const QString& pluginName = {}, const QVariantMap& constraints = {} ) = 0; :info:build ^ :info:build /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_kde_kdevplatform/kdevplatform/work/kdevplatform-1.7.4/interfaces/iplugincontroller.h:126:145: error: expected expression :info:build Q_SCRIPTABLE virtual IPlugin *pluginForExtension(const QString &extension, const QString& pluginName = {}, const QVariantMap& constraints = {} ) = 0; :info:build ^ :info:build /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_kde_kdevplatform/kdevplatform/work/kdevplatform-1.7.4/interfaces/iplugincontroller.h:137:111: error: expected expression :info:build virtual QList<IPlugin*> allPluginsForExtension(const QString &extension, const QVariantMap& constraints = {}) = 0; :info:build ^ :info:build /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_kde_kdevplatform/kdevplatform/work/kdevplatform-1.7.4/interfaces/iplugincontroller.h:174:112: error: expected expression :info:build virtual KPluginInfo::List queryExtensionPlugins(const QString &extension, const QVariantMap& constraints = {}) const = 0; :info:build ^ :info:build 2 warnings generated. :info:build [ 53%] Building CXX object sublime/CMakeFiles/sublime.dir/mainwindow_p.cpp.o :info:build cd /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_kde_kdevplatform/kdevplatform/work/build/sublime && /usr/bin/c++ -DKDE4_CMAKE_TOPLEVEL_DIR_LENGTH=147 -DKDE_DEFAULT_DEBUG_AREA=9504 -DKDE_DEPRECATED_WARNINGS -DMAKE_SUBLIME_LIB -DQT_NO_CAST_TO_ASCII -DQT_NO_STL -DQT_USE_FAST_CONCATENATION -DQT_USE_FAST_OPERATOR_PLUS -DQURL_NO_CAST_FROM_QSTRING -D_REENTRANT -I/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_kde_kdevplatform/kdevplatform/work/build/sublime -I/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_kde_kdevplatform/kdevplatform/work/kdevplatform-1.7.4/sublime -I/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_kde_kdevplatform/kdevplatform/work/kdevplatform-1.7.4 -I/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_kde_kdevplatform/kdevplatform/work/build -I/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_kde_kdevplatform/kdevplatform/work/kdevplatform-1.7.4/util -I/opt/local/include/KDE4 -I/opt/local/include/KDE4/KDE -I/opt/local/include/KDE -I/opt/local/include -I/opt/local/libexec/qt4/include/QtXmlPatterns -I/opt/local/libexec/qt4/include/QtXml -I/opt/local/libexec/qt4/include/QtWebKit -I/opt/local/libexec/qt4/include/QtUiTools -I/opt/local/libexec/qt4/include/QtTest -I/opt/local/libexec/qt4/include/QtSvg -I/opt/local/libexec/qt4/include/QtSql -I/opt/local/libexec/qt4/include/QtScriptTools -I/opt/local/libexec/qt4/include/QtScript -I/opt/local/libexec/qt4/include/QtOpenGL -I/opt/local/libexec/qt4/include/QtNetwork -I/opt/local/libexec/qt4/include/QtMultimedia -I/opt/local/libexec/qt4/include/QtHelp -I/opt/local/libexec/qt4/include/QtDesigner -I/opt/local/libexec/qt4/include/QtDeclarative -I/opt/local/libexec/qt4/include/QtDBus -I/opt/local/libexec/qt4/include/Qt3Support -I/opt/local/libexec/qt4/include/QtGui -I/opt/local/libexec/qt4/include/QtCore -I/opt/local/libexec/qt4/include -I/opt/local/libexec/qt4/share/mkspecs/default -pipe -Os -fno-common -DNDEBUG -DQT_NO_DEBUG -arch x86_64 -mmacosx-version-min=10.13 -fPIC -D__APPLE_KDE__ -o CMakeFiles/sublime.dir/mainwindow_p.cpp.o -c /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_kde_kdevplatform/kdevplatform/work/kdevplatform-1.7.4/sublime/mainwindow_p.cpp :info:build 4 errors generated. :info:build make[2]: *** [interfaces/CMakeFiles/kdevplatforminterfaces.dir/iplugin.cpp.o] Error 1 :info:build make[2]: *** Waiting for unfinished jobs....
comment:3 follow-up: 4 Changed 7 years ago by NicosPavlov
I am afraid I can't reproduce that error, but from the log, it seems that you are employing a non-compliant compiler:
:warn:configure All compilers are either blacklisted or unavailable; defaulting to first fallback option :debug:configure Environment: :debug:configure CC='/usr/bin/cc' :debug:configure CC_PRINT_OPTIONS='YES' :debug:configure CC_PRINT_OPTIONS_FILE='/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_kde_kdevplatform/kdevplatform/work/.CC_PRINT_OPTIONS' :debug:configure CFLAGS='-pipe -Os' :debug:configure CPATH='/opt/local/include' :debug:configure CXX='/usr/bin/c++'
As kdevelop requires c++11, I assume clang or at least a compiler compatible with libc++ should be employed. The errors in the log point to the same problem.
comment:4 Changed 7 years ago by fpiraneo (Francesco Piraneo G.)
Replying to NicosPavlov:
I am afraid I can't reproduce that error, but from the log, it seems that you are employing a non-compliant compiler: (cut) As kdevelop requires c++11, I assume clang or at least a compiler compatible with libc++ should be employed. The errors in the log point to the same problem.
Yeah, clang! Exactly what I'm using... All Apple original branded compiler! Beware of imitations!
~ >clang --version Apple LLVM version 9.0.0 (clang-900.0.39.2) Target: x86_64-apple-darwin17.4.0 Thread model: posix InstalledDir: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin
What else?
comment:5 Changed 7 years ago by kencu (Ken)
This kdevelop
Portfile will need to be adjusted somewhat. This part:
#Using c++11 for Lion and higher in case of clang 64-bit if {${configure.compiler} eq "clang" && ${os.platform} eq "darwin" && ${os.major} >= 11} { lappend merger_configure_args(x86_64) -DCMAKE_CXX_FLAGS='-stdlib=libc++ -std=c++11' -DHAVE_UNORDERED_MAP=1 if {${build_arch} eq "x86_64" && ![variant_isset universal]} { configure.args-append -DCMAKE_CXX_FLAGS="-stdlib=libc++ -std=c++11" -DHAVE_UNORDERED_MAP=1 } }
would not work correctly with the cxx11 1.1
PortGroup, as it is forcing stdlib=libc++
rather than allowing that PG to function as designed.
There is a similar section in the kdevplatform
portfile that will also need to be looked at:
if {${configure.compiler} ne "clang"} { #Adding -fexceptions, required by gcc compilers patchfiles-append patch-languageCMakeLists.diff } elseif {${os.platform} eq "darwin" && ${os.major} >= 11} { #Using c++11 for Lion and higher in case of clang 64-bit lappend merger_configure_args(x86_64) -DCMAKE_CXX_FLAGS='-stdlib=libc++ -std=c++11' -DHAVE_UNORDERED_MAP=1 if {${build_arch} eq "x86_64" && ![variant_isset universal]} { configure.args-append -DCMAKE_CXX_FLAGS="-stdlib=libc++ -std=c++11" -DHAVE_UNORDERED_MAP=1 } }
That doesn't explain the OP's error, though.
comment:6 Changed 7 years ago by NicosPavlov
Fair point, I'll fix that. This part is mostly historical, before the cxx11 1.1 PG was included in the Portfile.
comment:7 Changed 5 years ago by ryandesign (Ryan Carsten Schmidt)
Now that MacPorts 2.6.0 is out, both the cxx11 1.1 portgroup and other OS version specific hacks that related to the C++ standard lib should be removed in favor of:
compiler.cxx_standard 2011
But if the project does not already include -std=c++11
in its CXXFLAGS, the port still needs to do so manually.
comment:8 Changed 5 years ago by ryandesign (Ryan Carsten Schmidt)
Please make sure you make the needed changes in all affected ports; I see at least kdevplatform and kdevelop use this code.
comment:9 Changed 5 years ago by NicosPavlov
Thanks for the pointer. Only kdevplatform and kdevelop should be in that situation, they caused different issues to build them. I'll perform the changes, sorry for leaving that ticket hanging.
comment:10 Changed 5 years ago by Nicolas Pavillon <pavillon.nicolas@…>
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
Port build log