Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 675794 - =app-arch/libarchive-3.3.3 fails bootstrap, ./libtool prints "can't find: dsymutil" and $EPREFIX/tmp/usr/x86_64-apple-darwin18/binutils-bin/8.2.1/ranlib prints "(libarchive_fe_la-err.o) malformed object"
Summary: =app-arch/libarchive-3.3.3 fails bootstrap, ./libtool prints "can't find: dsy...
Alias: None
Product: Gentoo/Alt
Classification: Unclassified
Component: Prefix Support (show other bugs)
Hardware: x86 OS X
: Normal major with 4 votes (vote)
Assignee: Michał Górny
Depends on:
Reported: 2019-01-18 19:16 UTC by Espen
Modified: 2020-12-19 19:53 UTC (History)
4 users (show)

See Also:
Package list:
Runtime testing required: ---

app-arch/libarchive-3.3.3-build.log (build.log,144.09 KB, application/octet-stream)
2019-03-29 00:03 UTC, tsaotse

Note You need to log in before you can comment on or make changes to this bug.
Description Espen 2019-01-18 19:16:20 UTC
=app-arch/libarchive-3.3.3 fails bootstrap, ./libtool prints "can't find: dsymutil" and $EPREFIX/tmp/usr/x86_64-apple-darwin18/binutils-bin/8.2.1/ranlib prints "(libarchive_fe_la-err.o) malformed object"

I'm trying to install gentoo prefix on macos mojave. Build fails at libarchive. Build log here: Compiled with MAKEOPTS -j1.

dsymutil present on system (xcode CLI tools).
Comment 1 ashtophet 2019-01-23 17:05:50 UTC
I can confirm this here.

Mac OS Mojave 10.14.12, MacBookPro15,1.

If relevant, under Mac OS the very same libarchive-3.3.3 vanilla fails (./configure && make V=1 -j 3 > make.log.

In I've uploaded the following files:

1.- environment.txt, environment file.
2.- config.log, configure log.
3.- build.log, build log.

4.- macos/env.txt, 'env' output outside PREFIX, if relevant.
5.- macos/config.log, configure log outside PREFIX, if relevant.
6.- macos/make.log, make output outside PREFIX, if relevant.
Comment 2 ashtophet 2019-01-27 11:27:07 UTC
Comment 3 ashtophet 2019-01-30 17:23:30 UTC
It seems the problem is related to binutils-apple.
If I replace $EPREFIX/tmp/usr/x86_64-apple-darwin18/binutils-bin/8.2.1./ar and ranlib with Mac OS system's ones the compilation succeeds.
Comment 4 Fabian Groffen gentoo-dev 2019-01-30 19:20:46 UTC

Do you have $EPREFIX/usr/bin/dsymutil?
Comment 5 ashtophet 2019-01-30 19:27:05 UTC
Nope (we are on stage2).

I do have $EPREFIX/tmp/usr/bin/dsmyutil which is a symlink to $EPREFIX/tmp/usr/bin/x86_64-apple-darwin18-dsymutil which is a symlink to $EPREFIX/tmp/usr/x86_64-apple-darwin18/bin/dsymutil
Comment 6 Fabian Groffen gentoo-dev 2019-01-30 19:31:59 UTC
I'm wondering if this is related to any of the other problems where tools weren't exactly found from ROOT/tmp.

I think it's a good idea to wait for
to get fixed.
Comment 7 tsaotse 2019-03-29 00:03:19 UTC
Created attachment 571126 [details]

libtool: link: x86_64-apple-darwin18-ar cru .libs/libarchive_fe.a libarchive_fe/.libs/libarchive_fe_la-err.o libarchive_fe/.libs/libarchive_fe_la-line_reader.o libarchive_fe/.libs/libarchive_fe_la-passphrase.o
/Users/owen/Gentoo/tmp/usr/x86_64-apple-darwin18/binutils-bin/8.2.1/ranlib: object: .libs/libarchive_fe.a(libarchive_fe_la-err.o) malformed object (unknown load command 1)
x86_64-apple-darwin18-ar: internal ranlib command failed
make[1]: *** [Makefile:3443:] Error 1
make[1]: Leaving directory '/Users/owen/Gentoo/tmp/var/tmp/portage/app-arch/libarchive-3.3.3/work/libarchive-3.3.3-abi_x86_64.amd64'
make: *** [Makefile:3007: all] Error 2
 * ERROR: app-arch/libarchive-3.3.3::gentoo_prefix failed (compile phase):
Comment 8 Fabian Groffen gentoo-dev 2020-12-19 19:53:38 UTC
Not sure why this isn't a Prefix bug, but this is likely fixed with binutils-apple-11.*, and not an issue with current bootstraps on macOS which use GCC and host provided cctools.