This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
Re: shared library not found
- From: Ian Lance Taylor <iant at google dot com>
- To: booleandomain <booleandomain at gmail dot com>
- Cc: gcc-help at gcc dot gnu dot org
- Date: Mon, 06 Jul 2009 09:04:17 -0700
- Subject: Re: shared library not found
- References: <loom.20090703T124451-983@post.gmane.org>
booleandomain <booleandomain@gmail.com> writes:
> Well, bash get configured and compiled fine, but then if I issue ldd bash I get
> the following:
>
> linux-vdso.so.1 => (0x00007fffcb3ff000)
> libncurses.so.5 => not found
> libdl.so.2 => /tools/lib/libdl.so.2 (0x00007f14c2e65000)
> libc.so.6 => /tools/lib/libc.so.6 (0x00007f14c2b0d000)
> /tools/lib/ld-linux-x86-64.so.2 (0x00007f14c3069000)
>
> I have not installed ncurses in /tools. If I install it before attempting to
> compile bash, the problem is fixed.
>
> But I wonder why gcc does not complain at build-time... I can't check every
> compiled executable/library with ldd before installing it.
This means that the program linker was able to find libncurses.so.5 at
build time, but that the dynamic linker is not able to find
libncurses.so.5 at run time. There is nothing to complain about at
build time. Basically, this means that your program linker and dynamic
linker are using different search paths. You may find it useful to read
the documentation of the -rpath and -rpath-link options in the linker
manual.
Ian