This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
ld doesn't check for ld.so.1 in /lib
- From: Robert Millan <zeratul2 at wanadoo dot es>
- To: bug-binutils at gnu dot org, binutils at sources dot redhat dot com
- Date: Wed, 30 Jul 2003 02:58:59 +0000
- Subject: ld doesn't check for ld.so.1 in /lib
- Organisation: free as in freedom
- References: <20030730013508.GA24581@aragorn>
[ please CC me, i'm not subscribed ]
Hi again,
As I just said, ld has some trouble when running on GNU/FreeBSD. The
problem is that it's unable to find ld.so.1:
$ gcc hello.c -o /dev/null
/home/rmh/tmp/toolchain/install/bin/ld: warning: ld.so.1, needed by /lib/libc.so.1, not found (try using -rpath or -rpath-link)
[...]
By running ld under strace, I obtained this:
open("/usr/lib/ld.so.1", O_RDONLY) = -1 ENOENT (No such file or directory)
open("/usr/local/lib/ld.so.1", O_RDONLY) = -1 ENOENT (No such file or directory)
write(2, "\0\0", 2ld) = 2
[warning message follows]
It seems that ld is looking for ld.so.1 in /usr/lib and in /usr/local/lib,
but not in /lib (which is the real location of ld.so.1).
Any tips on which part of the ld code determines the directories to check for?
I'm confused by the many references to /usr/lib and /usr/local/lib in src/ld.
Thanks,
--
Robert Millan
"[..] but the delight and pride of Aule is in the deed of making, and in the
thing made, and neither in possession nor in his own mastery; wherefore he
gives and hoards not, and is free from care, passing ever on to some new work."
-- J.R.R.T, Ainulindale (Silmarillion)