Opened 10 years ago

Closed 10 years ago

#43854 closed defect (invalid)

gawk: extract failed because xz couldn't find libintl.8.dylib version 10.0.0 or later

Reported by: c_sorensen@… Owned by: macports-tickets@…
Priority: Normal Milestone:
Component: ports Version: 2.3.0
Keywords: Cc: ryandesign (Ryan Carsten Schmidt)
Port: gawk

Description

I'm trying to upgrade my MacPorts, and got a series of failures.

Following the instructions for errors with Xcode 4.2+, I tried installing apple-gcc42.

$ sudo port install apple-gcc42
--->  Computing dependencies for apple-gcc42
--->  Fetching archive for apple-gcc42
--->  Attempting to fetch apple-gcc42-5666.3_13.darwin_12.x86_64.tbz2 from http://packages.macports.org/apple-gcc42
--->  Attempting to fetch apple-gcc42-5666.3_13.darwin_12.x86_64.tbz2.rmd160 from http://packages.macports.org/apple-gcc42
--->  Installing apple-gcc42 @5666.3_13
--->  Activating apple-gcc42 @5666.3_13
--->  Cleaning apple-gcc42
--->  Updating database of binaries
--->  Scanning binaries for linking errors
--->  Found 113 broken file(s), matching files to ports  
--->  Found 20 broken port(s), determining rebuild order
--->  Rebuilding in order
     expat @2.1.0 
     dbus @1.8.2 
     fontconfig @2.11.1 
     gettext @0.18.3.2 
     python27 @2.7.6 
     gawk @4.1.0 
     libidn @1.26 
     curl @7.37.0 +ssl
     xz @5.0.5 
     opensp @1.5.2 
     openjade @1.3.2 
     gdbm @1.11 
     glib2 @2.40.0 
     cairo @1.12.16 +x11
     py27-cairo @1.10.0 +x11
     dbus-glib @0.102 
     dbus-python27 @1.2.0 
     gobject-introspection @1.40.0 
     py27-gobject @2.28.6 
     poppler @0.24.5 
--->  Cleaning expat
--->  Computing dependencies for dbus
--->  Cleaning dbus
--->  Computing dependencies for fontconfig
--->  Cleaning fontconfig
--->  Computing dependencies for gettext
--->  Cleaning gettext
--->  Computing dependencies for python27
--->  Cleaning python27
--->  Computing dependencies for gawk
--->  Applying patches to gawk
Error: org.macports.patch for port gawk returned: command execution failed
Please see the log file for port gawk for details:
    /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_gawk/gawk/main.log
Error: Unable to upgrade port: 1
Error rebuilding gawk
    while executing
"error "Error rebuilding $portname""
    (procedure "revupgrade_scanandrebuild" line 395)
    invoked from within
"revupgrade_scanandrebuild broken_port_counts $opts"
    (procedure "macports::revupgrade" line 5)
    invoked from within
"macports::revupgrade $opts"
    (procedure "action_revupgrade" line 2)
    invoked from within
"action_revupgrade $action $portlist $opts"
    (procedure "action_target" line 96)
    invoked from within
"$action_proc $action $portlist [array get global_options]"
    (procedure "process_cmd" line 93)
    invoked from within
"process_cmd $remaining_args"
    invoked from within
"if { [llength $remaining_args] > 0 } {

    # If there are remaining arguments, process those as a command
    set exit_status [process_cmd $remaining..."
    (file "/opt/local/bin/port" line 5254)

The log file (attached) includes:

:debug:patch Executing command line:  cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_gawk/gawk/work/gawk-4.1.1" && /usr/bin/patch -p0 < '/opt/local/var/macports/sources/rsync.macports.org/release/tarballs/ports/lang/gawk/files/patch-extensions-Makefile.in.diff'
:info:patch can't find file to patch at input line 3
:info:patch Perhaps you used the wrong -p or --strip option?
:info:patch The text leading up to this was:
:info:patch --------------------------
:info:patch |--- extension/Makefile.in.orig	2014-04-08 11:13:03.000000000 -0500
:info:patch |+++ extension/Makefile.in	2014-04-18 19:52:28.000000000 -0500
:info:patch --------------------------

Any thoughts?

Attachments (1)

main.log (7.3 KB) - added by c_sorensen@… 10 years ago.

Download all attachments as: .zip

Change History (7)

comment:1 Changed 10 years ago by c_sorensen@…

Cc: c_sorensen@… added

Cc Me!

comment:2 Changed 10 years ago by ryandesign (Ryan Carsten Schmidt)

Cc: ryandesign@… added; c_sorensen@… removed
Port: gawk added
Resolution: invalid
Status: newclosed
Summary: apple-gcc42 won't install on OSX 10.8.5gawk: can't find file to patch at input line 3

Your output shows that apple-gcc42 was successfully installed; that the rev-upgrade procedure that MacPorts always runs after installs and upgrades found some other ports to be broken (i.e. mislinked), and tried to rebuild them; and that rebuilding gawk failed because you did not clean it by running "sudo port clean gawk" first; you should do that now. Then run "port outdated" to see what ports are outdated, then probably run "sudo port upgrade outdated" to upgrade them all. Hopefully rev-upgrade does not find any mislinked ports at that point, or if it does, it can rebuild them successfully, but if gawk or another port still fails to build at that point, by all means re-open this ticket and attach the new main.log.

Changed 10 years ago by c_sorensen@…

Attachment: main.log added

comment:3 Changed 10 years ago by c_sorensen@…

Resolution: invalid
Status: closedreopened

Thanks for the suggestions. ALso, thanks for cleaning up the subject on the ticket. It's my first ticket.

I had previously cleaned gawk. But just in case, I did it again. Here is the transcript.

sorensen2:~ sorensen$ sudo port clean gawk
Password:
--->  Cleaning gawk
sorensen2:~ sorensen$ port outdated
The following installed ports are outdated:
gawk                           4.1.0_0 < 4.1.1_2         
gmp                            5.1.2_0 < 6.0.0_0         
gtk-doc                        1.20_1 < 1.20_2           
itstool                        2.0.2_0 < 2.0.2_1         
openjade                       1.3.2_7 < 1.3.2_8         
py27-libxml2                   2.9.1_0 < 2.9.1_1         
sorensen2:~ sorensen$ sudo port upgrade outdated
--->  Computing dependencies for gawk
--->  Fetching archive for gawk
--->  Attempting to fetch gawk-4.1.1_2.darwin_12.x86_64.tbz2 from http://packages.macports.org/gawk
--->  Attempting to fetch gawk-4.1.1_2.darwin_12.x86_64.tbz2 from http://lil.fr.packages.macports.org/gawk
--->  Attempting to fetch gawk-4.1.1_2.darwin_12.x86_64.tbz2 from http://mse.uk.packages.macports.org/sites/packages.macports.org/gawk
--->  Fetching distfiles for gawk
--->  Verifying checksums for gawk
--->  Extracting gawk
--->  Applying patches to gawk
Error: org.macports.patch for port gawk returned: command execution failed
Please see the log file for port gawk for details:
    /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_gawk/gawk/main.log
Error: Unable to upgrade port: 1
To report a bug, follow the instructions in the guide:
    http://guide.macports.org/#project.tickets
sorensen2:~ sorensen$ 

As you suggested, I'm reopening the ticket. I'd welcome any suggestions about how to investigate this further.

THanks,

Carl

comment:4 Changed 10 years ago by ryandesign (Ryan Carsten Schmidt)

Summary: gawk: can't find file to patch at input line 3gawk: extract failed because xz couldn't find libintl.8.dylib version 10.0.0 or later

Aha, so the log shows us that the reason why the patch phase couldn't find the file to patch is that no files were extracted, because the extraction program failed:

:info:extract dyld: Library not loaded: /opt/local/lib/libintl.8.dylib
:info:extract   Referenced from: /opt/local/bin/xz
:info:extract   Reason: Incompatible library version: xz requires version 10.0.0 or later, but libintl.8.dylib provides version 9.0.0

libintl is the gettext library. The gettext port in MacPorts should be providing library version 10.2.0, but for some reason it thinks you only have library version 9.0.0. Please show me the output of these commands:

port -v installed gettext
otool -L /opt/local/lib/libintl.8.dylib

comment:5 Changed 10 years ago by c_sorensen@…

Here are the outputs:

new-host-5:~ sorensen$ port -v installed gettext
The following ports are currently installed:
  gettext @0.18.3.2_0 (active) platform='darwin 12' archs='x86_64'
new-host-5:~ sorensen$ otool -L /opt/local/lib/libintl.8.dylib
/opt/local/lib/libintl.8.dylib:
	/opt/local/lib/libintl.8.dylib (compatibility version 9.0.0, current version 9.2.0)
	/opt/local/lib/libiconv.2.dylib (compatibility version 8.0.0, current version 8.0.0)
	/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 124.1.1)
	/System/Library/Frameworks/CoreFoundation.framework/Versions/A/CoreFoundation (compatibility version 150.0.0, current version 550.0.0)

I decided to try to update gettext:

new-host-5:~ sorensen$ sudo port clean gettext
--->  Cleaning gettext
new-host-5:~ sorensen$ sudo port upgrade gettext
--->  Scanning binaries for linking errors
--->  Found 113 broken file(s), matching files to ports
--->  Found 20 broken port(s), determining rebuild order
--->  Rebuilding in order
     expat @2.1.0 
     gettext @0.18.3.2 
     dbus @1.8.2 
     fontconfig @2.11.1 
     gawk @4.1.0 
     gdbm @1.11 
     glib2 @2.40.0 
     dbus-glib @0.102 
     libidn @1.26 
     xz @5.0.5 
     opensp @1.5.2 
     openjade @1.3.2 
     python27 @2.7.6 
     dbus-python27 @1.2.0 
     cairo @1.12.16 +x11
     gobject-introspection @1.40.0 
     py27-cairo @1.10.0 +x11
     py27-gobject @2.28.6 
     curl @7.37.0 +ssl
     poppler @0.24.5 
--->  Cleaning expat
--->  Computing dependencies for gettext
--->  Cleaning gettext
--->  Computing dependencies for dbus
--->  Cleaning dbus
--->  Computing dependencies for fontconfig
--->  Cleaning fontconfig
--->  Computing dependencies for gawk
--->  Applying patches to gawk
Error: org.macports.patch for port gawk returned: command execution failed
Please see the log file for port gawk for details:
    /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_gawk/gawk/main.log
Error: Unable to upgrade port: 1
Error rebuilding gawk
    while executing
"error "Error rebuilding $portname""
    (procedure "revupgrade_scanandrebuild" line 395)
    invoked from within
"revupgrade_scanandrebuild broken_port_counts $opts"
    (procedure "macports::revupgrade" line 5)
    invoked from within
"macports::revupgrade $opts"
    (procedure "action_revupgrade" line 2)
    invoked from within
"action_revupgrade $action $portlist $opts"
    (procedure "action_upgrade" line 25)
    invoked from within
"$action_proc $action $portlist [array get global_options]"
    (procedure "process_cmd" line 93)
    invoked from within
"process_cmd $remaining_args"
    invoked from within
"if { [llength $remaining_args] > 0 } {

    # If there are remaining arguments, process those as a command
    set exit_status [process_cmd $remaining..."
    (file "/opt/local/bin/port" line 5254)

Still hanging on the gawk problem -- it appears I can't update gettext because it needs gawk, and I can't update gawk because it needs a dylib that gettext isn't providing.

Oh -- I think I just found the problem. I have installed AuroraZ88, which is a finite element program that does some weird stuff with /opt/local -- it needs an older version of libintl.8.dylib.

I will go back to the current version and see if I can make things work.

For now, why don't you close the ticket. I'll reopen it if need be.

Thanks for your help.

comment:6 in reply to:  5 Changed 10 years ago by ryandesign (Ryan Carsten Schmidt)

Resolution: invalid
Status: reopenedclosed

Ok, your output confirms that although MacPorts thinks it has installed the current version of gettext, it has gotten replaced by an older version behind MacPorts' back.

The reason attempting to upgrade gettext did nothing is because, as far as MacPorts knows, it is already up to date.

After any install or upgrade action, including install or upgrade actions that do nothing, MacPorts then runs the rev-upgrade process, which tries to identify and rebuild mislinked packages, in this case starting with gawk, and failing as before. But it's probable that the only reason the other ports are considered mislinked is for the same reason that xz dosen't work: the wrong gettext library is installed.

You can get the right gettext library by forcibly rebuilding it:

sudo port -n upgrade --force gettext

However, if AuroraZ88 overwrote MacPorts' gettext, who knows what else it overwrote that you would also have to rebuild. If you can figure it out, rebuild those ports as well, in the correct dependency order. Otherwise, uninstall all ports, then reinstall the ones you want.

Please inform the developers of AuroraZ88 to re-package their software in a way that does not overwrite files in /opt/local.

Note: See TracTickets for help on using tickets.