[MacPorts] #49074: Error: Processing of port qt5-mac failed
#49074: Error: Processing of port qt5-mac failed ----------------------+-------------------------------- Reporter: fpvvd1@… | Owner: macports-tickets@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.3.4 Keywords: QT | Port: qt5-mac ----------------------+-------------------------------- OS X El Capitan (10.11) Error: org.macports.build for port qt5-mac returned: command execution failed Please see the log file for port qt5-mac for details: /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_aqua_qt5-mac/qt5-mac/main.log To report a bug, follow the instructions in the guide: http://guide.macports.org/#project.tickets Error: Processing of port qt5-mac failed[[BR]] main.log (tail): macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_aqua_qt5-mac/qt5-mac/work /qt-everywhere-opensource-src-5.4.2/qtbase/lib -framework QtCore -framework DiskArbitration -framework IOKit -framework Security -lz -framework SystemConfiguration -framework CoreFoundation -framework CoreServices -lssl -lcrypto :info:build mv -f QtNetwork ../../lib/QtNetwork.framework/Versions/5/QtNetwork :info:build ln -s Versions/Current/QtNetwork ../../lib/QtNetwork.framework/QtNetwork :info:build rm -f ../../lib/QtNetwork.framework/Versions/Current :info:build ln -s 5 ../../lib/QtNetwork.framework/Versions/Current :info:build make[3]: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_aqua_qt5-mac/qt5-mac/work /qt-everywhere-opensource-src-5.4.2/qtbase/src/network' :info:build make[2]: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_aqua_qt5-mac/qt5-mac/work /qt-everywhere-opensource-src-5.4.2/qtbase/src' :info:build make[1]: *** [sub-src-make_first] Error 2 :info:build make[1]: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_aqua_qt5-mac/qt5-mac/work /qt-everywhere-opensource-src-5.4.2/qtbase' :info:build make: *** [module-qtbase-make_first] Error 2 :info:build make: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_aqua_qt5-mac/qt5-mac/work /qt-everywhere-opensource-src-5.4.2' :info:build Command failed: cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_aqua_qt5-mac/qt5-mac/work /qt-everywhere-opensource-src-5.4.2" && /usr/bin/make -j2 -w :info:build Exit code: 2 :error:build org.macports.build for port qt5-mac returned: command execution failed :debug:build Error code: CHILDSTATUS 55341 2 :debug:build Backtrace: command execution failed while executing "system -nice 0 $fullcmdstring" ("eval" body line 1) invoked from within "eval system $notty $nice \$fullcmdstring" invoked from within "command_exec build" (procedure "portbuild::build_main" line 8) invoked from within "portbuild::build_main org.macports.build" ("eval" body line 1) invoked from within "eval $procedure $targetname" :info:build Warning: targets not executed for qt5-mac: org.macports.activate org.macports.build org.macports.destroot org.macports.install :notice:build Please see the log file for port qt5-mac for details: /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_aqua_qt5-mac/qt5-mac/main.log -- Ticket URL: <https://trac.macports.org/ticket/49074> MacPorts <https://www.macports.org/> Ports system for OS X
#49074: qt5-mac @5.4.2: error: declaration of anonymous struct must be a definition -----------------------+------------------------ Reporter: fpvvd1@… | Owner: mcalhoun@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.3.4 Resolution: | Keywords: elcapitan Port: qt5-mac | -----------------------+------------------------ Changes (by ryandesign@…): * keywords: QT => elcapitan * owner: macports-tickets@… => mcalhoun@… Old description:
OS X El Capitan (10.11) Error: org.macports.build for port qt5-mac returned: command execution failed Please see the log file for port qt5-mac for details: /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_aqua_qt5-mac/qt5-mac/main.log To report a bug, follow the instructions in the guide: http://guide.macports.org/#project.tickets Error: Processing of port qt5-mac failed[[BR]] main.log (tail): macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_aqua_qt5-mac/qt5-mac/work /qt-everywhere-opensource-src-5.4.2/qtbase/lib -framework QtCore -framework DiskArbitration -framework IOKit -framework Security -lz -framework SystemConfiguration -framework CoreFoundation -framework CoreServices -lssl -lcrypto :info:build mv -f QtNetwork ../../lib/QtNetwork.framework/Versions/5/QtNetwork :info:build ln -s Versions/Current/QtNetwork ../../lib/QtNetwork.framework/QtNetwork :info:build rm -f ../../lib/QtNetwork.framework/Versions/Current :info:build ln -s 5 ../../lib/QtNetwork.framework/Versions/Current :info:build make[3]: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_aqua_qt5-mac/qt5-mac/work /qt-everywhere-opensource-src-5.4.2/qtbase/src/network' :info:build make[2]: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_aqua_qt5-mac/qt5-mac/work /qt-everywhere-opensource-src-5.4.2/qtbase/src' :info:build make[1]: *** [sub-src-make_first] Error 2 :info:build make[1]: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_aqua_qt5-mac/qt5-mac/work /qt-everywhere-opensource-src-5.4.2/qtbase' :info:build make: *** [module-qtbase-make_first] Error 2 :info:build make: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_aqua_qt5-mac/qt5-mac/work /qt-everywhere-opensource-src-5.4.2' :info:build Command failed: cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_aqua_qt5-mac/qt5-mac/work /qt-everywhere-opensource-src-5.4.2" && /usr/bin/make -j2 -w :info:build Exit code: 2 :error:build org.macports.build for port qt5-mac returned: command execution failed :debug:build Error code: CHILDSTATUS 55341 2 :debug:build Backtrace: command execution failed while executing "system -nice 0 $fullcmdstring" ("eval" body line 1) invoked from within "eval system $notty $nice \$fullcmdstring" invoked from within "command_exec build" (procedure "portbuild::build_main" line 8) invoked from within "portbuild::build_main org.macports.build" ("eval" body line 1) invoked from within "eval $procedure $targetname" :info:build Warning: targets not executed for qt5-mac: org.macports.activate org.macports.build org.macports.destroot org.macports.install :notice:build Please see the log file for port qt5-mac for details: /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_aqua_qt5-mac/qt5-mac/main.log
New description: OS X El Capitan (10.11) {{{ Error: org.macports.build for port qt5-mac returned: command execution failed Please see the log file for port qt5-mac for details: /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_aqua_qt5-mac/qt5-mac/main.log To report a bug, follow the instructions in the guide: http://guide.macports.org/#project.tickets Error: Processing of port qt5-mac failed }}} main.log (tail): {{{ macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_aqua_qt5-mac/qt5-mac/work /qt-everywhere-opensource-src-5.4.2/qtbase/lib -framework QtCore -framework DiskArbitration -framework IOKit -framework Security -lz -framework SystemConfiguration -framework CoreFoundation -framework CoreServices -lssl -lcrypto :info:build mv -f QtNetwork ../../lib/QtNetwork.framework/Versions/5/QtNetwork :info:build ln -s Versions/Current/QtNetwork ../../lib/QtNetwork.framework/QtNetwork :info:build rm -f ../../lib/QtNetwork.framework/Versions/Current :info:build ln -s 5 ../../lib/QtNetwork.framework/Versions/Current :info:build make[3]: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_aqua_qt5-mac/qt5-mac/work /qt-everywhere-opensource-src-5.4.2/qtbase/src/network' :info:build make[2]: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_aqua_qt5-mac/qt5-mac/work /qt-everywhere-opensource-src-5.4.2/qtbase/src' :info:build make[1]: *** [sub-src-make_first] Error 2 :info:build make[1]: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_aqua_qt5-mac/qt5-mac/work /qt-everywhere-opensource-src-5.4.2/qtbase' :info:build make: *** [module-qtbase-make_first] Error 2 :info:build make: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_aqua_qt5-mac/qt5-mac/work /qt-everywhere-opensource-src-5.4.2' :info:build Command failed: cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_aqua_qt5-mac/qt5-mac/work /qt-everywhere-opensource-src-5.4.2" && /usr/bin/make -j2 -w :info:build Exit code: 2 :error:build org.macports.build for port qt5-mac returned: command execution failed :debug:build Error code: CHILDSTATUS 55341 2 :debug:build Backtrace: command execution failed while executing "system -nice 0 $fullcmdstring" ("eval" body line 1) invoked from within "eval system $notty $nice \$fullcmdstring" invoked from within "command_exec build" (procedure "portbuild::build_main" line 8) invoked from within "portbuild::build_main org.macports.build" ("eval" body line 1) invoked from within "eval $procedure $targetname" :info:build Warning: targets not executed for qt5-mac: org.macports.activate org.macports.build org.macports.destroot org.macports.install :notice:build Please see the log file for port qt5-mac for details: /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_aqua_qt5-mac/qt5-mac/main.log }}} -- Comment: Maybe [ticket:48252 updating to 5.5.0] would help. -- Ticket URL: <https://trac.macports.org/ticket/49074#comment:1> MacPorts <https://www.macports.org/> Ports system for OS X
#49074: qt5-mac @5.4.2: error: declaration of anonymous struct must be a definition -----------------------+------------------------ Reporter: fpvvd1@… | Owner: mcalhoun@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.3.4 Resolution: | Keywords: elcapitan Port: qt5-mac | -----------------------+------------------------ Comment (by casey.webster@…): The patches for qcocoacursor.mm and lalr.cpp in the link above for qt 5.5 are not specific to qt 5.5 and fix the problems building 5.4.2 on el capitan. I've created patches for lalr.cpp and qcocoacursor.mm taken from the links in the 5.5.0 bug and have successfully built and installed qt-5@5.4.2 with them. I will attach both diffs to this bug as well as a diff of my modified Portfile to apply them (probably not the way the maintainer will do it, but good enough for anyone else who wants to build before port tree is updated. -- Ticket URL: <https://trac.macports.org/ticket/49074#comment:3> MacPorts <https://www.macports.org/> Ports system for OS X
#49074: qt5-mac @5.4.2: error: declaration of anonymous struct must be a definition -----------------------+------------------------ Reporter: fpvvd1@… | Owner: mcalhoun@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.3.4 Resolution: | Keywords: elcapitan Port: qt5-mac | -----------------------+------------------------ Comment (by pjkim00@…): Replying to [comment:3 casey.webster@…]:
The patches for qcocoacursor.mm and lalr.cpp in the link above for qt 5.5 are not specific to qt 5.5 and fix the problems building 5.4.2 on el capitan.
I've created patches for lalr.cpp and qcocoacursor.mm taken from the links in the 5.5.0 bug and have successfully built and installed qt-5@5.4.2 with them. I will attach both diffs to this bug as well as a diff of my modified Portfile to apply them (probably not the way the maintainer will do it, but good enough for anyone else who wants to build before port tree is updated.
Tried cleaning, applying patch to Portfile, copying diff files to files dir and building. After about ~45 minutes of building, the build failed. It got a LOT farther than without the patches however. The log file is 169MB! big so I am still trying to find out what the failure is. -- Ticket URL: <https://trac.macports.org/ticket/49074#comment:6> MacPorts <https://www.macports.org/> Ports system for OS X
#49074: qt5-mac @5.4.2: error: declaration of anonymous struct must be a definition -----------------------+------------------------ Reporter: fpvvd1@… | Owner: mcalhoun@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.3.4 Resolution: | Keywords: elcapitan Port: qt5-mac | -----------------------+------------------------ Changes (by ryandesign@…): * cc: aelhossi@… (added) Comment: Has duplicate #49247. -- Ticket URL: <https://trac.macports.org/ticket/49074#comment:8> MacPorts <https://www.macports.org/> Ports system for OS X
#49074: qt5-mac @5.4.2: error: declaration of anonymous struct must be a definition -----------------------+------------------------ Reporter: fpvvd1@… | Owner: mcalhoun@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.3.4 Resolution: | Keywords: elcapitan Port: qt5-mac | -----------------------+------------------------ Comment (by aelhossi@…): Replying to [comment:6 pjkim00@…]:
Replying to [comment:3 casey.webster@…]:
The patches for qcocoacursor.mm and lalr.cpp in the link above for qt 5.5 are not specific to qt 5.5 and fix the problems building 5.4.2 on el capitan.
I've created patches for lalr.cpp and qcocoacursor.mm taken from the links in the 5.5.0 bug and have successfully built and installed qt-5@5.4.2 with them. I will attach both diffs to this bug as well as a diff of my modified Portfile to apply them (probably not the way the maintainer will do it, but good enough for anyone else who wants to build before port tree is updated.
Tried cleaning, applying patch to Portfile, copying diff files to files dir and building. After about ~45 minutes of building, the build failed. It got a LOT farther than without the patches however. The log file is 169MB! big so I am still trying to find out what the failure is.
Same thing for me. I applied the batch, and I now I passed the initial error, but got much more errors. Any solution for this! -- Ticket URL: <https://trac.macports.org/ticket/49074#comment:9> MacPorts <https://www.macports.org/> Ports system for OS X
#49074: qt5-mac @5.4.2: error: declaration of anonymous struct must be a definition -----------------------+------------------------ Reporter: fpvvd1@… | Owner: mcalhoun@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.3.4 Resolution: | Keywords: elcapitan Port: qt5-mac | -----------------------+------------------------ Comment (by framic5@…): I ran into the same problem as mentioned before. This is due to a library which is not found by clang++: {{{ :info:build [4153/10366] SOLINK(module) ffmpegsumo.so, POSTBUILDS :info:build FAILED: if [ ! -e ffmpegsumo.so -o ! -e ffmpegsumo.so.TOC ] || otool -l ffmpegsumo.so | grep -q LC_REEXPORT_DYLIB ; then /usr/bin/clang++ -bundle -Wl,-search_paths_first -stdlib=libc++ -Wl,-dead_strip -mmacosx- version-min=10.7 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk -Lgen/third_party/ffmpeg -arch x86_64 -L. -o ffmpegsumo.so @ffmpegsumo.so.rsp && { otool -l ffmpegsumo.so | grep LC_ID_DYLIB -A 5; nm -gP ffmpegsumo.so | cut -f1-2 -d' ' | grep -v U$; true; } > ffmpegsumo.so.TOC; else /usr/bin/clang++ -bundle -Wl,-search_paths_first -stdlib=libc++ -Wl,-dead_strip -mmacosx-version-min=10.7 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk -Lgen/third_party/ffmpeg -arch x86_64 -L. -o ffmpegsumo.so @ffmpegsumo.so.rsp && { otool -l ffmpegsumo.so | grep LC_ID_DYLIB -A 5; nm -gP ffmpegsumo.so | cut -f1-2 -d' ' | grep -v U$; true; } > ffmpegsumo.so.tmp && if ! cmp -s ffmpegsumo.so.tmp ffmpegsumo.so.TOC; then mv ffmpegsumo.so.tmp ffmpegsumo.so.TOC ; fi; fi :info:build clang: error: no such file or directory: '/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk/usr/lib/libz.dylib' }}} The first one is libz.dylib from the log above, others will follow. A complete list: * libz.dylib * libssl.dylib * libcrypto.dylib * libresolv.dylib * libbsm.dylib * libcups.dylib It seems that, beginning with Xcode 7, .tbd libraries instead of .dylib are used. Please refer to https://forums.developer.apple.com/message/8609#8609
For those who are curious, the .tbd files are new "text-based stub libraries", that provide a much more compact version of the stub libraries for use in the SDK, and help to significantly reduce its download size. In the folder /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk/usr/lib/ only the .tbd version of the mentioned libraries is available, whereas the .dylib file can be found at /usr/lib.
According to the link above, adding a flag for every library might be a solution, but that didn't work for me. I also failed to include the /usr/lib path or the tbd suffix to the qmake environment by altering make.conf for the chosen platform macx-clang. I could finish the build with symlinks from /usr/lib to the sysroot path set for clang++. But this is no proper solution to fix the Portfile, I guess. -- Ticket URL: <https://trac.macports.org/ticket/49074#comment:11> MacPorts <https://www.macports.org/> Ports system for OS X
#49074: qt5-mac @5.4.2: error: declaration of anonymous struct must be a definition -----------------------+------------------------ Reporter: fpvvd1@… | Owner: mcalhoun@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.3.4 Resolution: | Keywords: elcapitan Port: qt5-mac | -----------------------+------------------------ Comment (by michaelld@…): So the real issue here is not Apple's new TBD libraries. The issue is that this Qt module (qtwebengine) isn't looking for dependencies in the MacPorts ${prefix}. It has a bunch of hard-wired dependencies, which point to ${SDK}/usr/lib ... not even /usr/lib (which, as you say, might work). So, the better solution will be to get qtwebengine finding the libraries in the correct location. -- Ticket URL: <https://trac.macports.org/ticket/49074#comment:13> MacPorts <https://www.macports.org/> Ports system for OS X
#49074: qt5-mac @5.4.2: error: declaration of anonymous struct must be a definition -----------------------+------------------------ Reporter: fpvvd1@… | Owner: mcalhoun@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.3.4 Resolution: | Keywords: elcapitan Port: qt5-mac | -----------------------+------------------------ Comment (by casey.webster@…): Replying to [comment:11 framic5@…]:
I ran into the same problem as mentioned before. This is due to a library which is not found by clang++:
...
The first one is libz.dylib from the log above, others will follow. A complete list: * libz.dylib * libssl.dylib * libcrypto.dylib * libresolv.dylib * libbsm.dylib * libcups.dylib
I have the first three of those libraries in the macport tree provided by the 'openssl` and `zlib` packages, so you might try installing those and see if it helps. The last three I have in /usr/lib. Perhaps try installing openssl and zlib then attempt to build the port normally. -- Ticket URL: <https://trac.macports.org/ticket/49074#comment:14> MacPorts <https://www.macports.org/> Ports system for OS X
#49074: qt5-mac @5.4.2: error: declaration of anonymous struct must be a definition -----------------------+------------------------ Reporter: fpvvd1@… | Owner: mcalhoun@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.3.4 Resolution: | Keywords: elcapitan Port: qt5-mac | -----------------------+------------------------ Comment (by framic5@…): Replying to [comment:14 casey.webster@…]:
I have the first three of those libraries in the macport tree provided by the 'openssl` and `zlib` packages, so you might try installing those and see if it helps. I have both ports installed, as dependency of qt5-mac. So, nothing changed. This provides libz.dylib, libssl.dylib, libcrypto.dylib in second location, ${prefix}/lib. (/opt/local/lib for me)
-- Ticket URL: <https://trac.macports.org/ticket/49074#comment:15> MacPorts <https://www.macports.org/> Ports system for OS X
#49074: qt5-mac @5.4.2: error: declaration of anonymous struct must be a definition -----------------------+------------------------ Reporter: fpvvd1@… | Owner: mcalhoun@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.3.4 Resolution: | Keywords: elcapitan Port: qt5-mac | -----------------------+------------------------ Comment (by michaelld@…): These libraries are installed by MacPorts as dependencies of qt5-mac (and, qt4-mac too). The issue is in finding them. qtwebengine isn't "doing the right thing" here by hard-wiring where to find these when not using the internal version (provided inside qt5-mac). -- Ticket URL: <https://trac.macports.org/ticket/49074#comment:16> MacPorts <https://www.macports.org/> Ports system for OS X
#49074: qt5-mac @5.4.2: error: declaration of anonymous struct must be a definition -----------------------+------------------------ Reporter: fpvvd1@… | Owner: mcalhoun@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.3.4 Resolution: | Keywords: elcapitan Port: qt5-mac | -----------------------+------------------------ Comment (by casey.webster@…): Ok, I was grasping at straws trying to reconcile why it builds for me and not others. -- Ticket URL: <https://trac.macports.org/ticket/49074#comment:17> MacPorts <https://www.macports.org/> Ports system for OS X
#49074: qt5-mac @5.4.2: error: declaration of anonymous struct must be a definition -----------------------+------------------------ Reporter: fpvvd1@… | Owner: mcalhoun@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.3.4 Resolution: | Keywords: elcapitan Port: qt5-mac | -----------------------+------------------------ Comment (by michaelld@…): NP. I've no idea why it would build for you & not others. It doesn't build for me because of the TBD libraries issue. -- Ticket URL: <https://trac.macports.org/ticket/49074#comment:18> MacPorts <https://www.macports.org/> Ports system for OS X
#49074: qt5-mac @5.4.2: error: declaration of anonymous struct must be a definition -----------------------+------------------------ Reporter: fpvvd1@… | Owner: mcalhoun@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.3.4 Resolution: | Keywords: elcapitan Port: qt5-mac | -----------------------+------------------------ Comment (by casey.webster@…): Replying to [comment:18 michaelld@…]:
NP. I've no idea why it would build for you & not others. It doesn't build for me because of the TBD libraries issue.
Figured out it is building for me because my default python is 3.4. Qt runs a python script that bails on a print without parenthesis causing a SyntaxError to be raised and fails to retrieve a python version number. It then assumes python < 2.7 and disables qtwebengine from being built. That explains why I am "successfully" building Qt while others are running into errors in Qtwebengine. {{{ cd qtwebengine/ && ( test -e Makefile || /opt/local/var/macports/build/_usr_local_ports_aqua_qt5-mac/qt5-mac/work /qt-everywhere-opensource-src-5.4.2/qtbase/bin/qmake /opt/local/var/macports/build/_usr_local_ports_aqua_qt5-mac/qt5-mac/work /qt-everywhere-opensource-src-5.4.2/qtwebengine/qtwebengine.pro -o Makefile ) && /Applications/Xcode.app/Contents/Developer/usr/bin/make -f Makefile cd qttools/ && ( test -e Makefile || /opt/local/var/macports/build/_usr_local_ports_aqua_qt5-mac/qt5-mac/work /qt-everywhere-opensource-src-5.4.2/qtbase/bin/qmake /opt/local/var/macports/build/_usr_local_ports_aqua_qt5-mac/qt5-mac/work /qt-everywhere-opensource-src-5.4.2/qttools/qttools.pro -o Makefile ) && /Applications/Xcode.app/Contents/Developer/usr/bin/make -f Makefile Info: creating cache file /opt/local/var/macports/build/_usr_local_ports_aqua_qt5-mac/qt5-mac/work /qt-everywhere-opensource-src-5.4.2/qttools/.qmake.cache File "<string>", line 1 import sys; print sys.version_info.major ^ SyntaxError: invalid syntax File "<string>", line 1 import sys; print sys.version_info.minor ^ SyntaxError: invalid syntax Info: creating cache file /opt/local/var/macports/build/_usr_local_ports_aqua_qt5-mac/qt5-mac/work /qt-everywhere-opensource-src-5.4.2/qtwebengine/.qmake.cache Using Python version ., but at least Python version 2.7 is required to build Qt WebEngine. QtWebEngine will not be built. }}} {{{ % python --version Python 3.4.3 }}} -- Ticket URL: <https://trac.macports.org/ticket/49074#comment:21> MacPorts <https://www.macports.org/> Ports system for OS X
#49074: qt5-mac @5.4.2: error: declaration of anonymous struct must be a definition -----------------------+------------------------ Reporter: fpvvd1@… | Owner: mcalhoun@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.3.4 Resolution: | Keywords: elcapitan Port: qt5-mac | -----------------------+------------------------ Comment (by jakubzeman@…): After applying the patches the build took much more time but at the end it failed. See attached lo (jzeman_main.log). -- Ticket URL: <https://trac.macports.org/ticket/49074#comment:23> MacPorts <https://www.macports.org/> Ports system for OS X
#49074: qt5-mac @5.4.2: error: declaration of anonymous struct must be a definition -----------------------+------------------------ Reporter: fpvvd1@… | Owner: mcalhoun@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.3.4 Resolution: | Keywords: elcapitan Port: qt5-mac | -----------------------+------------------------ Comment (by michaelld@…): Replying to [comment:23 jakubzeman@…]:
After applying the patches the build took much more time but at the end it failed. See attached lo (jzeman_main.log).
You're getting the TBD libraries issue, same as the rest of us. Maybe we should just disable building Qtwebengine? What's it used for anyway? -- Ticket URL: <https://trac.macports.org/ticket/49074#comment:24> MacPorts <https://www.macports.org/> Ports system for OS X
#49074: qt5-mac @5.4.2: error: declaration of anonymous struct must be a definition -----------------------+------------------------ Reporter: fpvvd1@… | Owner: mcalhoun@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.3.4 Resolution: | Keywords: elcapitan Port: qt5-mac | -----------------------+------------------------ Comment (by jakubzeman@…): Here is a workaround: sudo port install zlib openssl xorg-libsm libgnomecups sudo su - cd /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk/usr/lib cp /usr/lib/libresolv.* . cp /usr/lib/libbsm.* . cp /usr/lib/libcups.* . cp /usr/lib/libcrypto.* . cp /usr/lib/libssl.* . cp /usr/lib/libz.* . -- Ticket URL: <https://trac.macports.org/ticket/49074#comment:25> MacPorts <https://www.macports.org/> Ports system for OS X
#49074: qt5-mac @5.4.2: error: declaration of anonymous struct must be a definition -----------------------+------------------------ Reporter: fpvvd1@… | Owner: mcalhoun@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.3.4 Resolution: | Keywords: elcapitan Port: qt5-mac | -----------------------+------------------------ Comment (by framic5@…): Replying to [comment:25 jakubzeman@…]:
Here is a workaround:
Certainly your workaround will work, but let me comment on this. Installing ports zlib openssl xorg-libsm libgnomecups is not necessary for this, because all libraries are installed in /opt/local/lib. All libraries are already available at /usr/lib without installing ports. Besides that, xorg-libsm provides libSM.dylib and not libbsm.dylib, libgnomecups provides libgnomecups-1.0.dylib and not libcups.dylib. Instead of copying the libraries from /usr/lib I would recommend symlinks as mentioned above. For example with lib.dylib: {{{ sudo ln -s /usr/lib/libz.dylib /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk/usr/lib/libz.dylib }}} -- Ticket URL: <https://trac.macports.org/ticket/49074#comment:26> MacPorts <https://www.macports.org/> Ports system for OS X
#49074: qt5-mac @5.4.2: error: declaration of anonymous struct must be a definition -----------------------+------------------------ Reporter: fpvvd1@… | Owner: mcalhoun@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.3.4 Resolution: | Keywords: elcapitan Port: qt5-mac | -----------------------+------------------------ Comment (by framic5@…): After making some progress with manual changes for the first libraries, I found a general solution. The problem can be tracked down to hard-coded relations in the chromium part of qtwebengine. On the project page one can find a solution: https://codereview.qt-project.org/#/c/127759/ Until this change is included in a newer version of Qt5, a patch to chromium can be used. If no dylib variant is found in the sysroot path, the library tbd version is used. This allowed a successful build of qt5-mac for me. -- Ticket URL: <https://trac.macports.org/ticket/49074#comment:27> MacPorts <https://www.macports.org/> Ports system for OS X
#49074: qt5-mac @5.4.2: error: declaration of anonymous struct must be a definition -----------------------+------------------------ Reporter: fpvvd1@… | Owner: mcalhoun@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.3.4 Resolution: | Keywords: elcapitan Port: qt5-mac | -----------------------+------------------------ Comment (by pjkim00@…): Replying to [comment:27 framic5@…]:
Until this change is included in a newer version of Qt5, a patch to chromium can be used. If no dylib variant is found in the sysroot path, the library tbd version is used. This allowed a successful build of qt5-mac for me. Applied patches and building.... still building.... how long will build take?...... looking good so far.... still building... cows back home.... good gravy, when will it end?.... can't hold .. on .. much.. longer.... put me out of my misery!
It worked! Thanks framic and casey and everyone else who contributes to this great cause. -- Ticket URL: <https://trac.macports.org/ticket/49074#comment:28> MacPorts <https://www.macports.org/> Ports system for OS X
#49074: qt5-mac @5.4.2: error: declaration of anonymous struct must be a definition -----------------------+------------------------ Reporter: fpvvd1@… | Owner: mcalhoun@… Type: defect | Status: closed Priority: Normal | Milestone: Component: ports | Version: 2.3.4 Resolution: fixed | Keywords: elcapitan Port: qt5-mac | -----------------------+------------------------ Changes (by mcalhoun@…): * status: new => closed * resolution: => fixed Comment: The upstream patch is now part of qt5 (r142505) -- Ticket URL: <https://trac.macports.org/ticket/49074#comment:29> MacPorts <https://www.macports.org/> Ports system for OS X
participants (1)
-
MacPorts