Opened 14 years ago

Closed 14 years ago

#25712 closed defect (fixed)

latest qt4-mac update does not build

Reported by: cjones051073 (Chris Jones) Owned by: michaelld (Michael Dickens)
Priority: Normal Milestone:
Component: ports Version: 1.9.1
Keywords: qt4 Cc: whcordis@…, mf2k (Frank Schima), jb.morgado@…
Port: qt4-mac

Description (last modified by michaelld (Michael Dickens))

I get

--->  Building qt4-mac
Error: Target org.macports.build returned: shell command failed
Log for qt4-mac is at: /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_ports_aqua_qt4-mac/main.log
Error: Unable to upgrade port: 1
To report a bug, see <http://guide.macports.org/#project.tickets>

with

Chris-Jones-Macbook-Pro ~ > cat  /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_ports_aqua_qt4-mac/main.log
<snip>
:debug:build Environment: CPATH='/opt/local/include/dbus-1.0:/opt/local/lib/dbus-1.0/include:/opt/local/include' CC_PRINT_OPTIONS_FILE='/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_aqua_qt4-mac/work/.CC_PRINT_OPTIONS' LIBRARY_PATH='/opt/local/lib' CC_PRINT_OPTIONS='YES' MACOSX_DEPLOYMENT_TARGET='10.6'
:debug:build Assembled command: 'cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_aqua_qt4-mac/work/qt-everywhere-opensource-src-4.6.3" && /usr/bin/make -j2 first'
:info:build /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_aqua_qt4-mac/work/qt-everywhere-opensource-src-4.6.3/bin/qmake -spec mkspecs/macx-g++ -macx -o Makefile projects.pro
:info:build make: *** [Makefile] Segmentation fault
:info:build make: *** Deleting file `Makefile'
:info:build shell command " cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_aqua_qt4-mac/work/qt-everywhere-opensource-src-4.6.3" && /usr/bin/make -j2 first " returned error 2
:error:build Target org.macports.build returned: shell command failed
:debug:build Backtrace: shell command failed
    while executing
"command_exec build"
    (procedure "portbuild::build_main" line 8)
    invoked from within
"$procedure $targetname"
:info:build Warning: the following items did not execute (for qt4-mac): org.macports.destroot org.macports.build
:notice:build Log for qt4-mac is at: /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_ports_aqua_qt4-mac/main.log
Chris-Jones-Macbook-Pro ~ > 

Chris

Attachments (2)

qt4_select_tries.txt (146.5 KB) - added by mf2k (Frank Schima) 14 years ago.
qt4-mac-tests.txt (1.2 KB) - added by mf2k (Frank Schima) 14 years ago.

Download all attachments as: .zip

Change History (30)

comment:1 Changed 14 years ago by michaelld (Michael Dickens)

Description: modified (diff)
Owner: changed from macports-tickets@… to michaelld@…

Please remember to look up the maintainer & enter that in the "Owned by" box.

Could you please post the whole log? There's a couple other things I'd like to verify about it.

comment:2 Changed 14 years ago by michaelld (Michael Dickens)

Can you provide the computer / OS / XCode / MacPorts info & versions?

If you know how to edit Portfiles, could you find the one for qt4-mac & remove the line that has "-optimized-qmake" in it & try again?

comment:3 in reply to:  2 Changed 14 years ago by maxdrift85@…

Replying to michaelld@…:

If you know how to edit Portfiles, could you find the one for qt4-mac & remove the line that has "-optimized-qmake" in it & try again?

I tried and without "-optimized-qmake" it works!

comment:4 Changed 14 years ago by michaelld (Michael Dickens)

I'm glad that did the trick! This flag works on 10.5 i386, so I'm thinking it might be a 10.6-specific issue. Maybe x86_64, but I won't know unless I get some stats back from people having issues. So whatever computer-specific info you can provide would be useful.

comment:5 Changed 14 years ago by cjones051073 (Chris Jones)

I have the problem with - OS X 10.6.4 : Mac Book Pro (late 2008) : Xcode 3.2.2 (64 bit). MacPorts 1.9.1

Will try without --optimized-qmake and report back.

comment:6 Changed 14 years ago by whcordis@…

Cc: whcordis@… added

Cc Me!

comment:7 Changed 14 years ago by cjones051073 (Chris Jones)

Removing -optimized-qmake worked for me. I did though get another odd message during deactivation of the old version

Chris-Jones-Macbook-Pro /opt/local/var/macports/sources/rsync.macports.org/release/ports/aqua/qt4-mac > sudo port upgrade qt4-mac
--->  Computing dependencies for qt4-mac
--->  Fetching qt4-mac
--->  Attempting to fetch qt-everywhere-opensource-src-4.6.3.tar.gz from http://ftp.heanet.ie/mirrors/ftp.trolltech.com/pub/qt/source/
--->  Verifying checksum(s) for qt4-mac
--->  Extracting qt4-mac
--->  Applying patches to qt4-mac
--->  Configuring qt4-mac
--->  Building qt4-mac
--->  Staging qt4-mac into destroot
--->  Computing dependencies for qt4-mac
--->  Installing qt4-mac @4.6.3_4
Error: Target org.macports.deactivate returned: can't read "current_select": no such variable
Log for qt4-mac is at: /opt/local/var/macports/logs/_opt_local_var_macports_registry_portfiles_qt4-mac_4.6.3_3/main.log
Warning: Failed to execute portfile from registry for qt4-mac @4.6.3_3
--->  Deactivating qt4-mac @4.6.3_3
--->  Activating qt4-mac @4.6.3_4
--->  Cleaning qt4-mac

comment:8 Changed 14 years ago by jwhowse4

I had this error while upgrading a Mac running Snow Leopard 10.6.4 and did not have any error while upgrading a Mac running Leopard 10.5.8. So you may be right that the problem is Snow Leopard specific.

comment:9 Changed 14 years ago by michaelld (Michael Dickens)

@jonesc: Can you post the log for the odd 'current_select' error? I've looked at the code way too many times and just don't see it. Maybe the log will help.

comment:10 Changed 14 years ago by cjones051073 (Chris Jones)

Hi,

Sorry, the log is now gone. I've since run a port clean ....

Chris

comment:11 Changed 14 years ago by michaelld (Michael Dickens)

OK; can you post the qt4-mac Portfile itself? I thought I corrected this issue on an older version, but maybe I didn't.

comment:12 Changed 14 years ago by mf2k (Frank Schima)

I can confirm that removing --optimized-qmake allows qt4_mac to build again on Snow Leopard. I also see the select error, here is the log:

version:1
:debug:main Executing org.macports.main (qt4-mac)
:debug:deactivate deactivate phase started at Sat Jul 17 17:20:42 MDT 2010
:debug:deactivate Executing proc-pre-org.macports.deactivate-deactivate-0
:info:deactivate Selecting version "none" for qt4
:info:deactivate rm: /opt/local/share/qt4: is a directory
:info:deactivate there were 1 errors selecting version "none"!
:info:deactivate shell command "/opt/local/bin/qt4_select none" returned error 5
:error:deactivate Target org.macports.deactivate returned: shell command failed
:debug:deactivate Backtrace: shell command failed
    while executing
"$pre $targetname"
:info:deactivate Warning: the following items did not execute (for qt4-mac): org.macports.deactivate
:notice:deactivate Log for qt4-mac is at: /opt/local/var/macports/logs/_opt_local_var_macports_registry_portfiles_qt4-mac_4.6.3_3/main.log

comment:13 Changed 14 years ago by mf2k (Frank Schima)

Cc: macsforever2000@… added

Cc Me!

comment:14 Changed 14 years ago by michaelld (Michael Dickens)

@macsforever2000: What port(s) owns whatever is inside of the directory /opt/local/share/qt4 ?

comment:15 Changed 14 years ago by mf2k (Frank Schima)

$ pwd
/opt/local/share/qt4
$ ls -l
total 8
drwxr-xr-x  3 root  admin  102 Jul  4 14:49 mkspecs
lrwxr-xr-x  1 root  admin   40 Jul 17 17:21 qt4-mac -> /opt/local/libexec/qt4-mac/share/qt4-mac
$ port provides qt4-mac/ 
/opt/local/share/qt4/qt4-mac is not provided by a MacPorts port.
$ port provides mkspecs/features/crypto.prf 
/opt/local/share/qt4/mkspecs/features/crypto.prf is provided by: qca

comment:16 Changed 14 years ago by michaelld (Michael Dickens)

and what does "port installed qt4-mac" return?

comment:17 Changed 14 years ago by cjones051073 (Chris Jones)

Hi,

I've put my qt4-mac Portfile (with the hack to remove -optimized-qmake) here

<http://www.hep.phy.cam.ac.uk/~jonesc/Portfile>

Chris

comment:18 Changed 14 years ago by cjones051073 (Chris Jones)

Chris-Jones-Macbook-Pro ~ > sudo port installed qt4-mac
The following ports are currently installed:
  qt4-mac @4.6.3_4 (active)

comment:19 Changed 14 years ago by michaelld (Michael Dickens)

Thanks for the feedback from all of you; I think I'm getting closer to understanding what's going on.

Can you both (jonesc and macsforever2000) do the following (on your 10.6 boxes):

sudo qt4_select -d none 2>&1 | tee ~/Desktop/qt4_select_tries.txt
sudo qt4_select -d qt4-mac 2>&1 | tee -a ~/Desktop/qt4_select_tries.txt

and then post the file "~/Desktop/qt4_select_tries.txt" to this ticket or your website? Thanks!

comment:20 Changed 14 years ago by cjones051073 (Chris Jones)

comment:21 Changed 14 years ago by michaelld (Michael Dickens)

@jonesc: Thanks.

Can you both also do

foo=`port installed qt4-mac | grep active | sed -e 's@(active)@@g'`
sudo port deactivate $foo 2>&1 | tee ~/Desktop/qt4-mac-tests.txt
sudo port -f activate $foo 2>&1 | tee -a ~/Desktop/qt4-mac-tests.txt

and post the file "~/Desktop/qt4-mac-tests.txt". If the "activate" generates warnings about 'phonon' already being there, the you might want to go & clean up those warning file(s). No big deal if you don't.

comment:22 Changed 14 years ago by cjones051073 (Chris Jones)

The deactivate generates a load of warnings

Chris-Jones-Macbook-Pro ~ > echo $foo
qt4-mac @4.6.3_4
Chris-Jones-Macbook-Pro ~ > sudo port deactivate $foo 2>&1 | tee ~/Desktop/qt4-mac-tests.txt
Password:
 Port 'qt4-mac' was selected; none is now selected.
  To select another port for group 'qt4',  please run 'qt4_select'.
Error: Target org.macports.deactivate returned: no files matched glob pattern "?honon"
Log for qt4-mac is at: /opt/local/var/macports/logs/_opt_local_var_macports_registry_portfiles_qt4-mac_4.6.3_4/main.log
Warning: Failed to execute portfile from registry for qt4-mac @4.6.3_4
--->  Deactivating qt4-mac @4.6.3_4
--->  Unable to uninstall/deactivate qt4-mac @4.6.3_4, the following ports depend on it:
--->  	akonadi @1.3.1_1
--->  	attica @0.1.4_0
--->  	automoc @0.9.88_1
--->  	kdebase4 @4.4.5_0
--->  	kdebase4-runtime @4.4.5_0
--->  	kdegraphics4 @4.4.5_1
--->  	kdelibs4 @4.4.5_2
--->  	kdepimlibs4 @4.4.5_0
--->  	kdesdk4 @4.4.5_0
--->  	kdeutils4 @4.4.5_0
--->  	oxygen-icons @4.4.5_0
--->  	qca @2.0.2_1
--->  	qimageblitz @0.0.5_4
--->  	root @5.26.00b_6+builtin_ftgl+fftw3+ftgl+opengl+pythia+python+qt_mac+roofit+ssl+xml
--->  	shared-desktop-ontologies @0.5_0
--->  	soprano @2.4.3_0
Error: port deactivate failed: Please uninstall the ports that depend on qt4-mac first.

Shall I force this step as well ?

comment:23 Changed 14 years ago by michaelld (Michael Dickens)

Yes, please do force the first, and the I don't think you'll need to force the second so try without the "-f" first & if that fails then force it. I'd like to see what 'port' prints out as warnings and such. I will fix the "?honon" issue along with the "optimized-qmake" flag issue, hopefully later today.

comment:24 in reply to:  16 Changed 14 years ago by mf2k (Frank Schima)

Replying to michaelld@…:

and what does "port installed qt4-mac" return?

$ port installed qt4-mac
The following ports are currently installed:
  qt4-mac @4.6.3_4 (active)

Changed 14 years ago by mf2k (Frank Schima)

Attachment: qt4_select_tries.txt added

Changed 14 years ago by mf2k (Frank Schima)

Attachment: qt4-mac-tests.txt added

comment:25 Changed 14 years ago by cjones051073 (Chris Jones)

comment:26 Changed 14 years ago by michaelld (Michael Dickens)

Great -- I've got enough info to fix these issues, I think. Thanks for all your help!

comment:27 Changed 14 years ago by jb.morgado@…

Cc: jb.morgado@… added

Cc Me!

comment:28 Changed 14 years ago by michaelld (Michael Dickens)

Resolution: fixed
Status: newclosed

I've checked in the fixes for this ticket's initial issue in r69882. It also addresses the "no files matched glob pattern "?honon"" warning, and hopefully also the "can't read "current_select": no such variable" warning.

As for the "Selecting version "none" for qt4; rm: /opt/local/share/qt4: is a directory" issue, that's a combination of "qt4_select" doing what it's supposed to do, combined with "I really don't know how that directory got there in the first place". I'm working on fixing the culprits, in this case: "qt4_select" and "qca" -- the latter resulting from ticket #25670 and #25715, and the former because it needs some TLC to handle such situations robustly.

I'm closing this ticket, but please reopen it if the original issue isn't resolved for you.

Note: See TracTickets for help on using tickets.