Page MenuHomeFreeBSD

Mk/Uses/libtool.mk: pass through LDFLAGS `-fuse-ld=*`
ClosedPublic

Authored by emaste on Dec 22 2017, 5:28 PM.
Tags
None
Referenced Files
F167910553: D13589.id37057.diff
Tue, Aug 25, 9:39 AM
Unknown Object (File)
Thu, Aug 13, 5:36 PM
Unknown Object (File)
Tue, Aug 11, 11:08 PM
Unknown Object (File)
Sat, Aug 8, 5:15 PM
Unknown Object (File)
Jul 22 2026, 7:12 PM
Unknown Object (File)
Jul 20 2026, 12:16 AM
Unknown Object (File)
Jul 18 2026, 5:04 AM
Unknown Object (File)
Jun 26 2026, 9:50 PM
Subscribers

Details

Summary

Some ports depend on permissive or broken behaviour from the GNU BFD linker, ld.bfd. Clang and GCC support a -fuse-ld= flag to specify the linker to use, and as we migrate to installing lld as the base system's /usr/bin/ld we'll want to make use of -fuse-ld=bfd to let ports that fail with lld use bfd instead.

An upstream libtool change from Feb 2016 supports passing through -fuse-ld=, but it has not yet made it into a release: http://git.savannah.gnu.org/cgit/libtool.git/commit/?id=f9970d99293faf908fdc153a653fa5781095fb7a

Patch an equivalent change into ltmain.sh via Mk/Uses/libtool.mk.

See PR 224514 for an earlier attempt which address this in the libtool port only, and so fixes those ports that have USES=autoreconf but not ports using their own ltmain.sh. @tijl suggested this change.

Diff Detail

Repository
rP FreeBSD ports repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable