I'm using libtool to create plugin libraries for a program I'm working on.
These plugins are named without the lib prefix, that's all fine and it works great.


However, I need these plugins to be in the same directory as where the main executable resides, and I cannot install them into one of the $blah/lib paths or add the current path to LD_LIBRARY_PATH.

So I went searching for some way to get win32-like DLL behaviour (eg. first doing a search for DLL's in the current directory), but then for Linux.
I've found how to get such functionality at the following page:
http://www.flipcode.com/cgi-bin/msg.cgi?showThread=Tip-PathToEXE&forum=totd&id=-1


I can now use this ${ORIGIN} variable to load those plugins from the same directory as where the main executable lives.
To my knowledge, this is only possible when building the software by hand, though.. (or using a custom makefile, but that's not an option)


When I try to specify this soname using libtool (adding it to the LDFLAGS primary, eg. -Wl,-soname -Wl,{ORIGIN}/mylibname.so) it gets overridden by the libtool script, which also uses it to set the so name.

So my question is; is it possible to somehow put this {ORIGIN} variable in there and make libtool use it?
Or perhaps some way to turn off this soname setting from libtool?


Thanks,
Richard

_________________________________________________________________
Add photos to your messages with MSN 8. Get 2 months FREE*. http://join.msn.com/?page=features/featuredemail




_______________________________________________
Libtool mailing list
[EMAIL PROTECTED]
http://mail.gnu.org/mailman/listinfo/libtool

Reply via email to