On Tue, 12 Sep 2000, Ralf Baechle wrote:
> Kanoj, got an idea why the kernel might load ld.so to a different address
> than it is linked for?
Because the suggested address space is already occupied?
> Note that ldd is running ld.so directly, therefore on an Origin it will
> always say ``not a dynamic executable''. This again will confuse
> libtool into producing wrong library and rpm into generating packages
> without library dependency information and probably a few more
> neat little resulting bugs.
For rpm see how I handle the require/provide lists in my RPM packages --
I try not to use ldd at all, as this does not work for cross-compilation.
Readelf and objdump are much better tools to fetch such dependencies and
have the advantage of not including indirect ones (which may vary between
library releases).
> Btw, this same problem should also affect glibc 2.2.
It does. No idea, why, at the moment, but it can be easily reproduced
e.g. by `/lib/ld.so.1 /bin/rpm -ya' (this way of invoking makes the ld.so
preferred space be occupied by the direct invocation, so the second copy
of ld.so that gets loaded by dlopening NSS modules gets mmapped at a
non-standard address).
Maciej
--
+ Maciej W. Rozycki, Technical University of Gdansk, Poland +
+--------------------------------------------------------------+
+ e-mail: macro@xxxxxxxxxxxxx, PGP key available +
|