Re: Dlopening documentation
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Bob Friesenhahn wrote: | On Thu, 4 Mar 2004, Gary V. Vaughan wrote: | |I have a feeling that this is all done automatically by lt_dlopen. If it |isn't then it should be... | |Comments? | | | It seems to me that this text covers the case when libltdl is not | used. It is possible to use modules built by libtool without using | libltdl. :-) Ah yes. That makes sense. I think the text as it stands is just plain confusing. I'll tweak it to make it clear that this stuff only applies to riding dlopen() bareback... and that if you want to take the path of least resistance lt_dlopen already does all that stuff for you. Cheers, Gary. - -- Gary V. Vaughan ())_. [EMAIL PROTECTED],gnu.org} Research Scientist ( '/ http://www.oranda.demon.co.uk GNU Hacker / )= http://www.gnu.org/software/libtool Technical Author `(_~)_ http://sources.redhat.com/autobook -BEGIN PGP SIGNATURE- Version: GnuPG v1.2.2 (GNU/Linux) Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org iD8DBQFATgbWFRMICSmD1gYRAn3RAJ9u4U/evcUx1zkuk9F6BJfpmvwEeQCgxjv9 jj3jS5I/tbqZPyBFOyhAvSw= =EzDt -END PGP SIGNATURE- ___ Libtool mailing list [EMAIL PROTECTED] http://mail.gnu.org/mailman/listinfo/libtool
Re: Dlopening documentation
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Peter O'Gorman wrote: | Last time I looked lt_dlopen did all of this. Indeedy :-) | It seems that we ought to recommend that libname.la be the filename | passed to lt_dlopen(), things probably work best in that case, but hey, | you're the one with author in your .sig :) Agreed. On both counts :-b I'll make the association between the dlopen and lt_dlopen docs more explicit. Cheers, Gary. - -- Gary V. Vaughan ())_. [EMAIL PROTECTED],gnu.org} Research Scientist ( '/ http://tkd.kicks-ass.net GNU Hacker / )= http://www.gnu.org/software/libtool Technical Author `(_~)_ http://sources.redhat.com/autobook -BEGIN PGP SIGNATURE- Version: GnuPG v1.2.2 (GNU/Linux) Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org iD8DBQFATgdhFRMICSmD1gYRAn5nAJ9YADhKiZPmojSdWHtCUi0+t0WUmQCfd/Oa RxjmRhPyr3ufOwg487+lSlk= =h5Ub -END PGP SIGNATURE- ___ Libtool mailing list [EMAIL PROTECTED] http://mail.gnu.org/mailman/listinfo/libtool
Re: Dlopening documentation
On Thu, 4 Mar 2004, Gary V. Vaughan wrote: I have a feeling that this is all done automatically by lt_dlopen. If it isn't then it should be... Comments? It seems to me that this text covers the case when libltdl is not used. It is possible to use modules built by libtool without using libltdl. :-) Bob == Bob Friesenhahn [EMAIL PROTECTED] http://www.simplesystems.org/users/bfriesen ___ Libtool mailing list [EMAIL PROTECTED] http://mail.gnu.org/mailman/listinfo/libtool
Re: Dlopening documentation
Gary V. Vaughan wrote: The current libtool docs say: @node Finding the dlname @section Finding the correct name to dlopen @cindex names of dynamic modules @cindex dynamic modules, names After a library has been linked with @samp{-module}, it can be dlopened. Unfortunately, because of the variation in library names, your package needs to determine the correct file to dlopen. The most straightforward and flexible implementation is to determine the name at runtime, by finding the installed @samp{.la} file, and searching it for the following lines: @example # The name that we can @code{dlopen}. dlname='@var{dlname}' @end example If @var{dlname} is empty, then the library cannot be dlopened. Otherwise, it gives the dlname of the library. So, if the library was installed as @file{/usr/local/lib/libhello.la}, and the @var{dlname} was @file{libhello.so.3}, then @file{/usr/local/lib/libhello.so.3} should be dlopened. If your program uses this approach, then it should search the directories listed in the @[EMAIL PROTECTED]@code{LIBPATH} on AIX, and @code{SHLIB_PATH} on HP-UX.} environment variable, as well as the directory where libraries will eventually be installed. Searching this variable (or equivalent) will guarantee that your program can find its dlopened modules, even before installation, provided you have linked them using libtool. I have a feeling that this is all done automatically by lt_dlopen. If it isn't then it should be... Comments? Last time I looked lt_dlopen did all of this. It seems that we ought to recommend that libname.la be the filename passed to lt_dlopen(), things probably work best in that case, but hey, you're the one with author in your .sig :) Peter -- Peter O'Gorman - http://www.pogma.com ___ Libtool mailing list [EMAIL PROTECTED] http://mail.gnu.org/mailman/listinfo/libtool
Re: Dlopening documentation
On Thu, Mar 04, 2004 at 06:29:16PM +, Gary V. Vaughan wrote: If @var{dlname} is empty, then the library cannot be dlopened. Otherwise, it gives the dlname of the library. So, if the library was installed as @file{/usr/local/lib/libhello.la}, and the @var{dlname} was @file{libhello.so.3}, then @file{/usr/local/lib/libhello.so.3} should be dlopened. If your program uses this approach, then it should search the directories listed in the @[EMAIL PROTECTED]@code{LIBPATH} on AIX, and @code{SHLIB_PATH} on HP-UX.} environment variable, as well as the directory where libraries will eventually be installed. Searching this variable (or equivalent) will guarantee that your program can find its dlopened modules, even before installation, provided you have linked them using libtool. I have a feeling that this is all done automatically by lt_dlopen. If it isn't then it should be... Yes, it should be. BTW, how do we handle the case where need_lib_prefix!=no? -- albert chin ([EMAIL PROTECTED]) ___ Libtool mailing list [EMAIL PROTECTED] http://mail.gnu.org/mailman/listinfo/libtool
Dlopening documentation
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 The current libtool docs say: @node Finding the dlname @section Finding the correct name to dlopen @cindex names of dynamic modules @cindex dynamic modules, names After a library has been linked with @samp{-module}, it can be dlopened. Unfortunately, because of the variation in library names, your package needs to determine the correct file to dlopen. The most straightforward and flexible implementation is to determine the name at runtime, by finding the installed @samp{.la} file, and searching it for the following lines: @example # The name that we can @code{dlopen}. dlname='@var{dlname}' @end example If @var{dlname} is empty, then the library cannot be dlopened. Otherwise, it gives the dlname of the library. So, if the library was installed as @file{/usr/local/lib/libhello.la}, and the @var{dlname} was @file{libhello.so.3}, then @file{/usr/local/lib/libhello.so.3} should be dlopened. If your program uses this approach, then it should search the directories listed in the @[EMAIL PROTECTED]@code{LIBPATH} on AIX, and @code{SHLIB_PATH} on HP-UX.} environment variable, as well as the directory where libraries will eventually be installed. Searching this variable (or equivalent) will guarantee that your program can find its dlopened modules, even before installation, provided you have linked them using libtool. I have a feeling that this is all done automatically by lt_dlopen. If it isn't then it should be... Comments? Cheers, Gary. - -- Gary V. Vaughan ())_. [EMAIL PROTECTED],gnu.org} Research Scientist ( '/ http://www.oranda.demon.co.uk GNU Hacker / )= http://www.gnu.org/software/libtool Technical Author `(_~)_ http://sources.redhat.com/autobook -BEGIN PGP SIGNATURE- Version: GnuPG v1.2.2 (GNU/Linux) Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org iD8DBQFAR3V7FRMICSmD1gYRApgGAKCCjCTkoUnNNFAUWcWnasuSuV5emQCeNMJk szxgxoSil/N4ZUWQQi6vebY= =FzWl -END PGP SIGNATURE- ___ Libtool mailing list [EMAIL PROTECTED] http://mail.gnu.org/mailman/listinfo/libtool