This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
Re: non standard libs
- To: Nicholas Mc Guire <der dot herr at hofr dot at>
- Subject: Re: non standard libs
- From: Alexandre Oliva <aoliva at redhat dot com>
- Date: 24 Dec 2000 16:04:48 -0200
- Cc: gcc-help at gcc dot gnu dot org
- Organization: GCC Team, Red Hat
- References: <200012241402.HAA05527@nis.hofr.at>
On Dec 24, 2000, Nicholas Mc Guire <der.herr@hofr.at> wrote:
> which compiles ok , but does not use the glibc-2.0.7 libs but the normal system
> libs in /lib (blibc-2.1.3) and thus segfaults on the old system.
> could someone point out to me whats wrong with the compiler flags I was using ?
Nothing's wrong with your flags. You just failed to tell the linker
to add a note in the program that, at run-time, it should look for
libc in this other directory. Set LD_RUN_PATH or use -rpath to
accomplish that.
An alternative is to create a link in /lib with the libc SONAME
encoded in the program that points to the old version of glibc.
It might be that you'll also have to tell the linker that the program
needs the old dynamic loader (ld.so). I don't know how to do that,
though.
--
Alexandre Oliva Enjoy Guarana', see http://www.ic.unicamp.br/~oliva/
Red Hat GCC Developer aoliva@{cygnus.com, redhat.com}
CS PhD student at IC-Unicamp oliva@{lsd.ic.unicamp.br, gnu.org}
Free Software Evangelist *Please* write to mailing lists, not to me