GNU bug report logs - #71326
ld-wrapper does not handle all possibilities to specify libraries and their search paths

Previous Next

Package: guix;

Reported by: Stefan <stefan-guix <at> vodafonemail.de>

Date: Sun, 2 Jun 2024 13:31:01 UTC

Severity: normal

To reply to this bug, email your comments to 71326 AT debbugs.gnu.org.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-guix <at> gnu.org:
bug#71326; Package guix. (Sun, 02 Jun 2024 13:31:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Stefan <stefan-guix <at> vodafonemail.de>:
New bug report received and forwarded. Copy sent to bug-guix <at> gnu.org. (Sun, 02 Jun 2024 13:31:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Stefan <stefan-guix <at> vodafonemail.de>
To: bug-guix <at> gnu.org
Subject: ld-wrapper does not handle all possibilities to specify libraries and
 their search paths
Date: Sun, 2 Jun 2024 15:29:34 +0200
Hi!

Beside using an absolute path, the ld of Binutils has eight ways¹ to pass a library like libfoo.so via options:

-lfoo
-l foo
-library=foo
--library=foo
-l:libfoo.so
-l :libfoo.so
-library=:libfoo.so
--library=:libfoo.so

The ld-wrapper however only supports one of these possibilities, which is the most common: -lfoo. GCC itself does not support the -[-]library= variants.


Similarly there are four ways to specify a library search path /bar for ld:

-L/bar
-L /bar
-library-path=/bar
--library-path=/bar

The ld-wrapper only supports the first two. GCC itself does not support the -[-]library-path= variant.


The lld form the LLVM project supports all these different options as well.


Bye

Stefan


¹ <https://sourceware.org/binutils/docs-2.42/ld/Options.html>




This bug report was last modified 137 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.