Opened 2 months ago

Last modified 2 months ago

#63224 new defect

poedit @2.4.3: rev-upgrade failed: Port poedit still broken after rebuilding 3 times

Reported by: cooljeanius (Eric Gallager) Owned by:
Priority: Normal Milestone:
Component: ports Version: 2.7.1
Keywords: bigsur Cc: l2dy (Zero King)
Port: poedit

Description

Seems to be an issue with it using its own gettext:

DEBUG: Ignoring loadcommand containing @rpath in /Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/bin/msgcat
Could not open /lib/libtextstyle.0.dylib: Error opening or reading file (referenced from /Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/bin/msgcat)
DEBUG: Marking /Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/bin/msgcat as broken
DEBUG: Ignoring loadcommand containing @rpath in /Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/bin/msgcat
DEBUG: Ignoring loadcommand containing @rpath in /Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/bin/msgcat
DEBUG: Ignoring loadcommand containing @rpath in /Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/bin/msgfmt
DEBUG: Marking /Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/bin/msgfmt as broken
DEBUG: Ignoring loadcommand containing @rpath in /Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/bin/msgfmt
DEBUG: Ignoring loadcommand containing @rpath in /Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/bin/msgfmt
DEBUG: Ignoring loadcommand containing @rpath in /Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/bin/msgmerge
DEBUG: Marking /Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/bin/msgmerge as broken
DEBUG: Ignoring loadcommand containing @rpath in /Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/bin/msgmerge
DEBUG: Ignoring loadcommand containing @rpath in /Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/bin/msgmerge
DEBUG: Ignoring loadcommand containing @rpath in /Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/bin/msgunfmt
DEBUG: Marking /Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/bin/msgunfmt as broken
DEBUG: Ignoring loadcommand containing @rpath in /Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/bin/msgunfmt
DEBUG: Ignoring loadcommand containing @rpath in /Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/bin/msgunfmt
DEBUG: Ignoring loadcommand containing @rpath in /Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/bin/msguniq
DEBUG: Marking /Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/bin/msguniq as broken
DEBUG: Ignoring loadcommand containing @rpath in /Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/bin/msguniq
DEBUG: Ignoring loadcommand containing @rpath in /Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/bin/msguniq
DEBUG: Ignoring loadcommand containing @rpath in /Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/bin/xgettext
DEBUG: Marking /Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/bin/xgettext as broken
DEBUG: Ignoring loadcommand containing @rpath in /Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/bin/xgettext
DEBUG: Ignoring loadcommand containing @rpath in /Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/bin/xgettext
DEBUG: Ignoring loadcommand containing @rpath in /Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/lib/libgettextlib-0.21.dylib
DEBUG: Ignoring loadcommand containing @rpath in /Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/lib/libgettextpo.0.dylib
DEBUG: Marking /Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/lib/libgettextsrc-0.21.dylib as broken
DEBUG: Ignoring loadcommand containing @rpath in /Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/lib/libgettextsrc-0.21.dylib
DEBUG: Ignoring loadcommand containing @rpath in /Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/lib/libgettextsrc-0.21.dylib
--->  Found 7 broken files, matching files to ports
Error: Port poedit is still broken after rebuilding it more than 3 times.
DEBUG: rev-upgrade failed: Port poedit still broken after rebuilding 3 times
    while executing
"error "Port $portname still broken after rebuilding $rebuild_tries time${s}""
    (procedure "revupgrade_scanandrebuild" line 310)
    invoked from within
"revupgrade_scanandrebuild broken_port_counts $opts"
    ("uplevel" body line 3)
    invoked from within
"uplevel 1 $body"
Error: rev-upgrade failed: Port poedit still broken after rebuilding 3 times

Change History (3)

comment:1 Changed 2 months ago by l2dy (Zero King)

I'm not able to reproduce this error, which version and architecture of macOS are you using?

comment:2 in reply to:  1 Changed 2 months ago by cooljeanius (Eric Gallager)

Replying to l2dy:

I'm not able to reproduce this error, which version and architecture of macOS are you using?

I am on Big Sur (11.4) on x86_64

comment:3 in reply to:  1 Changed 2 months ago by ryandesign (Ryan Schmidt)

Keywords: bigsur added

Replying to l2dy:

I'm not able to reproduce this error, which version and architecture of macOS are you using?

You are able to build this port on Big Sur? We are not able to build it on Big Sur on the buildbot.

If we look at the binary that was produced for Catalina we see that some of the libraries have wrong-looking install_names, specifically libtextstyle.0.dylib and libasprintf.0.dylib:

$ find ./poedit-2.4.3_0.darwin_19.x86_64/Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/lib -type f | xargs otool -L
./poedit-2.4.3_0.darwin_19.x86_64/Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/lib/libgettextpo.0.dylib:
	@rpath/libgettextpo.0.dylib (compatibility version 6.0.0, current version 6.7.0)
	@rpath/libintl.8.dylib (compatibility version 11.0.0, current version 11.0.0)
	/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1281.100.1)
	/usr/lib/libiconv.2.dylib (compatibility version 7.0.0, current version 7.0.0)
./poedit-2.4.3_0.darwin_19.x86_64/Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/lib/libtextstyle.0.dylib:
	//lib/libtextstyle.0.dylib (compatibility version 2.0.0, current version 2.1.0)
	/usr/lib/libiconv.2.dylib (compatibility version 7.0.0, current version 7.0.0)
	/usr/lib/libncurses.5.4.dylib (compatibility version 5.4.0, current version 5.4.0)
	/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1281.100.1)
./poedit-2.4.3_0.darwin_19.x86_64/Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/lib/libintl.8.dylib:
	@rpath/libintl.8.dylib (compatibility version 11.0.0, current version 11.0.0)
	/usr/lib/libiconv.2.dylib (compatibility version 7.0.0, current version 7.0.0)
	/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1281.100.1)
./poedit-2.4.3_0.darwin_19.x86_64/Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/lib/libasprintf.0.dylib:
	//lib/libasprintf.0.dylib (compatibility version 1.0.0, current version 1.0.0)
	/usr/lib/libc++.1.dylib (compatibility version 1.0.0, current version 902.1.0)
	/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1281.100.1)
./poedit-2.4.3_0.darwin_19.x86_64/Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/lib/libgettextsrc-0.21.dylib:
	@rpath/libgettextsrc-0.21.dylib (compatibility version 0.0.0, current version 0.0.0)
	@rpath/libgettextlib-0.21.dylib (compatibility version 0.0.0, current version 0.0.0)
	@rpath/libintl.8.dylib (compatibility version 11.0.0, current version 11.0.0)
	@executable_path/../lib/libtextstyle.0.dylib (compatibility version 2.0.0, current version 2.1.0)
	/usr/lib/libncurses.5.4.dylib (compatibility version 5.4.0, current version 5.4.0)
	/usr/lib/libiconv.2.dylib (compatibility version 7.0.0, current version 7.0.0)
	/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1281.100.1)
./poedit-2.4.3_0.darwin_19.x86_64/Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/lib/libgettextlib-0.21.dylib:
	@rpath/libgettextlib-0.21.dylib (compatibility version 0.0.0, current version 0.0.0)
	@rpath/libintl.8.dylib (compatibility version 11.0.0, current version 11.0.0)
	/usr/lib/libiconv.2.dylib (compatibility version 7.0.0, current version 7.0.0)
	/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1281.100.1)

However when we look at the binaries, the error has been corrected in them (the erroneous //lib prefix has been replaced by @executable_path/../lib:

$ find ./poedit-2.4.3_0.darwin_19.x86_64/Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/bin -type f | xargs otool -L
./poedit-2.4.3_0.darwin_19.x86_64/Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/bin/msgmerge:
	@rpath/libgettextsrc-0.21.dylib (compatibility version 0.0.0, current version 0.0.0)
	@rpath/libgettextlib-0.21.dylib (compatibility version 0.0.0, current version 0.0.0)
	@executable_path/../lib/libtextstyle.0.dylib (compatibility version 2.0.0, current version 2.1.0)
	/usr/lib/libncurses.5.4.dylib (compatibility version 5.4.0, current version 5.4.0)
	@rpath/libintl.8.dylib (compatibility version 11.0.0, current version 11.0.0)
	/usr/lib/libiconv.2.dylib (compatibility version 7.0.0, current version 7.0.0)
	/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1281.100.1)
./poedit-2.4.3_0.darwin_19.x86_64/Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/bin/msgcat:
	@rpath/libgettextsrc-0.21.dylib (compatibility version 0.0.0, current version 0.0.0)
	@rpath/libgettextlib-0.21.dylib (compatibility version 0.0.0, current version 0.0.0)
	@executable_path/../lib/libtextstyle.0.dylib (compatibility version 2.0.0, current version 2.1.0)
	/usr/lib/libncurses.5.4.dylib (compatibility version 5.4.0, current version 5.4.0)
	@rpath/libintl.8.dylib (compatibility version 11.0.0, current version 11.0.0)
	/usr/lib/libiconv.2.dylib (compatibility version 7.0.0, current version 7.0.0)
	/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1281.100.1)
./poedit-2.4.3_0.darwin_19.x86_64/Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/bin/msgunfmt:
	@rpath/libgettextsrc-0.21.dylib (compatibility version 0.0.0, current version 0.0.0)
	@rpath/libgettextlib-0.21.dylib (compatibility version 0.0.0, current version 0.0.0)
	@executable_path/../lib/libtextstyle.0.dylib (compatibility version 2.0.0, current version 2.1.0)
	/usr/lib/libncurses.5.4.dylib (compatibility version 5.4.0, current version 5.4.0)
	@rpath/libintl.8.dylib (compatibility version 11.0.0, current version 11.0.0)
	/usr/lib/libiconv.2.dylib (compatibility version 7.0.0, current version 7.0.0)
	/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1281.100.1)
./poedit-2.4.3_0.darwin_19.x86_64/Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/bin/msgfmt:
	@rpath/libgettextsrc-0.21.dylib (compatibility version 0.0.0, current version 0.0.0)
	@rpath/libgettextlib-0.21.dylib (compatibility version 0.0.0, current version 0.0.0)
	@executable_path/../lib/libtextstyle.0.dylib (compatibility version 2.0.0, current version 2.1.0)
	/usr/lib/libncurses.5.4.dylib (compatibility version 5.4.0, current version 5.4.0)
	@rpath/libintl.8.dylib (compatibility version 11.0.0, current version 11.0.0)
	/usr/lib/libiconv.2.dylib (compatibility version 7.0.0, current version 7.0.0)
	/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1281.100.1)
./poedit-2.4.3_0.darwin_19.x86_64/Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/bin/xgettext:
	@rpath/libgettextsrc-0.21.dylib (compatibility version 0.0.0, current version 0.0.0)
	@rpath/libgettextlib-0.21.dylib (compatibility version 0.0.0, current version 0.0.0)
	@executable_path/../lib/libtextstyle.0.dylib (compatibility version 2.0.0, current version 2.1.0)
	/usr/lib/libncurses.5.4.dylib (compatibility version 5.4.0, current version 5.4.0)
	@rpath/libintl.8.dylib (compatibility version 11.0.0, current version 11.0.0)
	/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1281.100.1)
	/usr/lib/libiconv.2.dylib (compatibility version 7.0.0, current version 7.0.0)
./poedit-2.4.3_0.darwin_19.x86_64/Applications/MacPorts/Poedit.app/Contents/PlugIns/GettextTools.bundle/Contents/MacOS/bin/msguniq:
	@rpath/libgettextsrc-0.21.dylib (compatibility version 0.0.0, current version 0.0.0)
	@rpath/libgettextlib-0.21.dylib (compatibility version 0.0.0, current version 0.0.0)
	@executable_path/../lib/libtextstyle.0.dylib (compatibility version 2.0.0, current version 2.1.0)
	/usr/lib/libncurses.5.4.dylib (compatibility version 5.4.0, current version 5.4.0)
	@rpath/libintl.8.dylib (compatibility version 11.0.0, current version 11.0.0)
	/usr/lib/libiconv.2.dylib (compatibility version 7.0.0, current version 7.0.0)
	/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1281.100.1)

This fixup happens in macos/fixup-dylib-deps.sh when it is invoked from deps/generate_build_ninja.py:

                                     # fix dylib references to work
                                     '$top_srcdir/../macos/fixup-dylib-deps.sh //lib @executable_path/../lib $destdir/lib $destdir/bin/*',

Eric's error message refers to /lib/libtextstyle.0.dylib (one leading slash) not //lib/libtextstyle.0.dylib (two leading slashes). Perhaps whatever causes the two leading slashes on Catalina and earlier leaves only the single leading slash on Big Sur and therefore the replacement of //lib with @executable_path/../lib does not have any effect.

The best fix would be to make the build produce correct install_names in the first place and remove the need to fix them up later. Failing that, a simple workaround could be to call fixup-dylib-deps.sh twice, once for //lib and a second time for /lib.

Upstream has fixed this issue in https://github.com/vslavik/poedit/commit/888920d1bdcb5107a80f4d436257e9cec23cf0d8 which is in poedit 3.0. Perhaps the port could be updated to that version.

Note: See TracTickets for help on using tickets.