[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
rpath problems
From: |
Werner LEMBERG |
Subject: |
rpath problems |
Date: |
Sun, 08 Feb 2004 23:11:40 +0100 (CET) |
Assume that a library is built with --enable-shared, and that libtool
isn't used for linking later on. Today it is common that a library
`foo' provide its own `foo-config' script to get the necessary
compilation and linking flags right.
Now consider the command `foo-config --libs'. Besides giving the
arguments to -L it makes sense IMHO to give arguments to --rpath (or
-R, depending on the platform) also. Unfortunately, it seems there
is no documented way to pass the necessary information.
Currently, I have the following in my configure.ac script:
AC_PROG_LIBTOOL
# urgh -- these are internal libtool variables...
AC_SUBST([enable_shared])
AC_SUBST([hardcode_libdir_flag_spec])
AC_SUBST([wl])
and the following code in my foo-config file:
...
address@hidden@
address@hidden@
hardcode_libdir_flag_spec='@hardcode_libdir_flag_spec@'
...
rpath=
if test "$enable_shared" = "yes" ; then
eval "rpath=\"$hardcode_libdir_flag_spec\""
fi
libs=-L$libdir $rpath -lfoo
Is there something better available?
Werner
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- rpath problems,
Werner LEMBERG <=