Subject: -rpath linker options
To: None <>
From: Brook Milligan <>
List: tech-pkg
Date: 06/29/2006 09:39:28
I am trying to make a package for a large set of software that
installs in its own place (e.g., ${PREFIX}/${PKGHOME}) rather than
being spread about the various directories in ${PREFIX}.  This package
creates both shared libraries and binary programs that use those
shared libraries.  It does not use libtool, and for the moment I think
it is too invasive to teach it how to do so.

I have arranged for the correct -rpath flags to be set for the linker
(e.g., -Wl,-rpath,${PREFIX}/${PKGHOME}/lib).  From objdump output, it
seems that this directory never makes it into the RPATH of either the
installed libraries or the binary programs.  It also seems that the
wrapper scripts intentionally remove those options while constructing
the actual linking commands, although I am not certain I fully
understand the meaning of the logs.

This raises several questions:

- Is my interpretation of the wrapper action correct (i.e., is it
  removing such command line options)?

- Is there a means of configuring the wrappers so they will allow such
  -rpath options to be used?

- Is there some other solution to the problem of missing rpath
  directories in the libraries and programs?

Thanks alot for your help.