Installing Ldso

Installation of Ld.so

Install Ld.so by running the following commands:



cd util &&
make ldd ldconfig &&
cp ldd /bin &&
cp ldconfig /sbin &&
cd ../man &&
cp ldd.1 /usr/share/man/man1 &&
cp *.8 /usr/share/man/man8 &&
rm /usr/bin/ldd &&
hash -r

The "hash -r" command is to make bash forget about the locations of previously executed commands. If you have executed ldd before, bash expects it to be found in /usr/bin. Since we moved it to /bin, the cache needs to be purged so bash can find it in /bin when you want to execute it again.

You might have noticed that we don't use the compiler optimizations for this package. The reason is that overriding the CFLAGS variable causes compilation problems. You would have to edit the Config.mk file and add the proper values to the CFLAGS variable and then compile the package. If you want to do that it's up to you. I don't think it's worth the trouble though. The ld and ldd programs usually are only rarely used.

Contents

From the Ld.so package we're using the ldconfig and ldd programs.

Description

ldconfig

ldconfig creates the necessary links and cache (for use by the run-time linker, ld.so) to the most recent shared libraries found in the directories specified on the command line, in the file /etc/ld.so.conf, and in the trusted directories (/usr/lib and /lib). ldconfig checks the header and file names of the libraries it encounters when determining which versions should have their links updated.

ldd

ldd prints the shared libraries required by each program or shared library specified on the command line.