[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

RE: -rpath with libtool and Debian Linux

> -----Original Message-----
> From: Ian Lance Taylor [mailto:ian@cygnus.com]
> Sent: Saturday, January 30, 1999 11:40 PM
> To: Marcus.Brinkmann@ruhr-uni-bochum.de
> Cc: oliva@dcc.unicamp.br; jgg@ualberta.ca;
> debian-devel@lists.debian.org; bug-libtool@gnu.org
> Subject: Re: -rpath with libtool and Debian Linux
>    Date: Sat, 30 Jan 1999 23:30:43 +0100
>    From: Marcus Brinkmann <Marcus.Brinkmann@ruhr-uni-bochum.de>
>    Why should the application choose to hard code the PATH in 
> the binary?
>    AFAICS, there is no apparent reason for it. What has the 
> path to do with the
>    library? I think the only thing that should be hard coded 
> is the exact
>    soname and library name. Maybe I am missing something?
> Suppose you have your own set of shared libraries, in your own
> directory.  Suppose you want to let other people use your programs
> linked against your own shared libraries.  You can tell everyone who
> uses your programs to set LD_LIBRARY_PATH, or you can simply use
> -rpath so that your programs can always find your shared libraries.

I fully agree; I've already said that in this case -rpath is perfectly
justified (and whenever possible the use of paths that are interpreted
relative to the executable directory is a plus)

> In general, it's convenient to store the path in the executable any
> time a shared library is installed in a directory which the dynamic
> linker does not search by default.

Especially if it is related to the executable. If it's a requisite (that
is if you say: My program will only work if you installed libraries
libsomething on your system) you should expect this library to be
*installed*, that is the system setup to be changed so that the linker
will find it, and then -rpath is a nuisance.
> Incidentally, I don't know what you mean by saying both soname and
> library name.  There is only one name recorded for a shared library:
> the soname.



Bernard Dautrevaux
Microprocess Ingéniérie
97 bis, rue de Colombes
Tel:	+33 (0) 1 47 68 80 80
Fax:	+33 (0) 1 47 88 97 85
e-mail:	dautrevaux@microprocess.com

Reply to: