This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: ld, shared objects and makefiles


On Wed, Aug 05, 2009 at 07:01:31PM +1000, John Fisher wrote:
> There's a problem when I do it this way with .so shared objects. The  
> name of the directory containing the referenced shared object becomes  
> part of the outer shared object. When dlopen is called for the  
> referenced shared object, it can't be found. The paths to the referenced  
> shared object on the development host and the target are different.

Build your shared objects with a soname.  Then the soname will be
used in DT_NEEDED tags rather than the file name.  Otherwise you'll
need to create links in the working directory to your shared objects.
Or hack on ld.

-- 
Alan Modra
Australia Development Lab, IBM


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]