2003-12-09 09:07:09 +00:00
|
|
|
#! /bin/sh
|
|
|
|
# Output a system dependent set of variables, describing how to set the
|
|
|
|
# run time search path of shared libraries in an executable.
|
|
|
|
#
|
2008-02-15 09:58:01 +00:00
|
|
|
# Copyright 1996-2007 Free Software Foundation, Inc.
|
2003-12-09 09:07:09 +00:00
|
|
|
# Taken from GNU libtool, 2001
|
|
|
|
# Originally by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
|
|
|
|
#
|
2006-11-21 11:00:14 +00:00
|
|
|
# This file is free software; the Free Software Foundation gives
|
|
|
|
# unlimited permission to copy and/or distribute it, with or without
|
|
|
|
# modifications, as long as this notice is preserved.
|
2003-12-09 09:07:09 +00:00
|
|
|
#
|
|
|
|
# The first argument passed to this file is the canonical host specification,
|
|
|
|
# CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM
|
|
|
|
# or
|
|
|
|
# CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM
|
|
|
|
# The environment variables CC, GCC, LDFLAGS, LD, with_gnu_ld
|
|
|
|
# should be set by the caller.
|
|
|
|
#
|
|
|
|
# The set of defined variables is at the end of this script.
|
|
|
|
|
|
|
|
# Known limitations:
|
|
|
|
# - On IRIX 6.5 with CC="cc", the run time search patch must not be longer
|
|
|
|
# than 256 bytes, otherwise the compiler driver will dump core. The only
|
|
|
|
# known workaround is to choose shorter directory names for the build
|
|
|
|
# directory and/or the installation directory.
|
|
|
|
|
2006-11-21 11:00:14 +00:00
|
|
|
# All known linkers require a `.a' archive for static linking (except MSVC,
|
2003-12-09 09:07:09 +00:00
|
|
|
# which needs '.lib').
|
|
|
|
libext=a
|
|
|
|
shrext=.so
|
|
|
|
|
|
|
|
host="$1"
|
|
|
|
host_cpu=`echo "$host" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
|
|
|
|
host_vendor=`echo "$host" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
|
|
|
|
host_os=`echo "$host" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
|
|
|
|
|
2006-11-21 11:00:14 +00:00
|
|
|
# Code taken from libtool.m4's _LT_CC_BASENAME.
|
|
|
|
|
|
|
|
for cc_temp in $CC""; do
|
|
|
|
case $cc_temp in
|
|
|
|
compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
|
|
|
|
distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
|
|
|
|
\-*) ;;
|
|
|
|
*) break;;
|
|
|
|
esac
|
|
|
|
done
|
|
|
|
cc_basename=`echo "$cc_temp" | sed -e 's%^.*/%%'`
|
|
|
|
|
2003-12-09 09:07:09 +00:00
|
|
|
# Code taken from libtool.m4's AC_LIBTOOL_PROG_COMPILER_PIC.
|
|
|
|
|
|
|
|
wl=
|
|
|
|
if test "$GCC" = yes; then
|
|
|
|
wl='-Wl,'
|
|
|
|
else
|
|
|
|
case "$host_os" in
|
|
|
|
aix*)
|
|
|
|
wl='-Wl,'
|
|
|
|
;;
|
2006-11-21 11:00:14 +00:00
|
|
|
darwin*)
|
|
|
|
case $cc_basename in
|
|
|
|
xlc*)
|
|
|
|
wl='-Wl,'
|
|
|
|
;;
|
|
|
|
esac
|
|
|
|
;;
|
2008-02-15 09:58:01 +00:00
|
|
|
mingw* | cygwin* | pw32* | os2*)
|
2003-12-09 09:07:09 +00:00
|
|
|
;;
|
|
|
|
hpux9* | hpux10* | hpux11*)
|
|
|
|
wl='-Wl,'
|
|
|
|
;;
|
|
|
|
irix5* | irix6* | nonstopux*)
|
|
|
|
wl='-Wl,'
|
|
|
|
;;
|
|
|
|
newsos6)
|
|
|
|
;;
|
2008-02-15 09:58:01 +00:00
|
|
|
linux* | k*bsd*-gnu)
|
2006-11-21 11:00:14 +00:00
|
|
|
case $cc_basename in
|
|
|
|
icc* | ecc*)
|
|
|
|
wl='-Wl,'
|
|
|
|
;;
|
|
|
|
pgcc | pgf77 | pgf90)
|
2003-12-09 09:07:09 +00:00
|
|
|
wl='-Wl,'
|
|
|
|
;;
|
2006-11-21 11:00:14 +00:00
|
|
|
ccc*)
|
2003-12-09 09:07:09 +00:00
|
|
|
wl='-Wl,'
|
|
|
|
;;
|
2006-11-21 11:00:14 +00:00
|
|
|
como)
|
|
|
|
wl='-lopt='
|
|
|
|
;;
|
|
|
|
*)
|
|
|
|
case `$CC -V 2>&1 | sed 5q` in
|
|
|
|
*Sun\ C*)
|
|
|
|
wl='-Wl,'
|
|
|
|
;;
|
|
|
|
esac
|
|
|
|
;;
|
2003-12-09 09:07:09 +00:00
|
|
|
esac
|
|
|
|
;;
|
|
|
|
osf3* | osf4* | osf5*)
|
|
|
|
wl='-Wl,'
|
|
|
|
;;
|
2008-02-15 09:58:01 +00:00
|
|
|
rdos*)
|
2003-12-09 09:07:09 +00:00
|
|
|
;;
|
|
|
|
solaris*)
|
|
|
|
wl='-Wl,'
|
|
|
|
;;
|
|
|
|
sunos4*)
|
|
|
|
wl='-Qoption ld '
|
|
|
|
;;
|
2008-02-15 09:58:01 +00:00
|
|
|
sysv4 | sysv4.2uw2* | sysv4.3*)
|
2003-12-09 09:07:09 +00:00
|
|
|
wl='-Wl,'
|
|
|
|
;;
|
|
|
|
sysv4*MP*)
|
|
|
|
;;
|
2008-02-15 09:58:01 +00:00
|
|
|
sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
|
|
|
|
wl='-Wl,'
|
|
|
|
;;
|
2006-11-21 11:00:14 +00:00
|
|
|
unicos*)
|
|
|
|
wl='-Wl,'
|
|
|
|
;;
|
2003-12-09 09:07:09 +00:00
|
|
|
uts4*)
|
|
|
|
;;
|
|
|
|
esac
|
|
|
|
fi
|
|
|
|
|
|
|
|
# Code taken from libtool.m4's AC_LIBTOOL_PROG_LD_SHLIBS.
|
|
|
|
|
|
|
|
hardcode_libdir_flag_spec=
|
|
|
|
hardcode_libdir_separator=
|
|
|
|
hardcode_direct=no
|
|
|
|
hardcode_minus_L=no
|
|
|
|
|
|
|
|
case "$host_os" in
|
|
|
|
cygwin* | mingw* | pw32*)
|
|
|
|
# FIXME: the MSVC++ port hasn't been tested in a loooong time
|
|
|
|
# When not using gcc, we currently assume that we are using
|
|
|
|
# Microsoft Visual C++.
|
|
|
|
if test "$GCC" != yes; then
|
|
|
|
with_gnu_ld=no
|
|
|
|
fi
|
|
|
|
;;
|
2006-11-21 11:00:14 +00:00
|
|
|
interix*)
|
|
|
|
# we just hope/assume this is gcc and not c89 (= MSVC++)
|
|
|
|
with_gnu_ld=yes
|
|
|
|
;;
|
2003-12-09 09:07:09 +00:00
|
|
|
openbsd*)
|
|
|
|
with_gnu_ld=no
|
|
|
|
;;
|
|
|
|
esac
|
|
|
|
|
|
|
|
ld_shlibs=yes
|
|
|
|
if test "$with_gnu_ld" = yes; then
|
2006-11-21 11:00:14 +00:00
|
|
|
# Set some defaults for GNU ld with shared library support. These
|
|
|
|
# are reset later if shared libraries are not supported. Putting them
|
|
|
|
# here allows them to be overridden if necessary.
|
|
|
|
# Unlike libtool, we use -rpath here, not --rpath, since the documented
|
|
|
|
# option of GNU ld is called -rpath, not --rpath.
|
|
|
|
hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
|
2003-12-09 09:07:09 +00:00
|
|
|
case "$host_os" in
|
|
|
|
aix3* | aix4* | aix5*)
|
|
|
|
# On AIX/PPC, the GNU linker is very broken
|
|
|
|
if test "$host_cpu" != ia64; then
|
|
|
|
ld_shlibs=no
|
|
|
|
fi
|
|
|
|
;;
|
|
|
|
amigaos*)
|
|
|
|
hardcode_libdir_flag_spec='-L$libdir'
|
|
|
|
hardcode_minus_L=yes
|
|
|
|
# Samuel A. Falvo II <kc5tja@dolphin.openprojects.net> reports
|
|
|
|
# that the semantics of dynamic libraries on AmigaOS, at least up
|
|
|
|
# to version 4, is to share data among multiple programs linked
|
|
|
|
# with the same dynamic library. Since this doesn't match the
|
2006-11-21 11:00:14 +00:00
|
|
|
# behavior of shared libraries on other platforms, we cannot use
|
2003-12-09 09:07:09 +00:00
|
|
|
# them.
|
|
|
|
ld_shlibs=no
|
|
|
|
;;
|
|
|
|
beos*)
|
2004-09-30 14:34:34 +00:00
|
|
|
if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
|
2003-12-09 09:07:09 +00:00
|
|
|
:
|
|
|
|
else
|
|
|
|
ld_shlibs=no
|
|
|
|
fi
|
|
|
|
;;
|
|
|
|
cygwin* | mingw* | pw32*)
|
|
|
|
# hardcode_libdir_flag_spec is actually meaningless, as there is
|
|
|
|
# no search path for DLLs.
|
|
|
|
hardcode_libdir_flag_spec='-L$libdir'
|
|
|
|
if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
|
|
|
|
:
|
|
|
|
else
|
|
|
|
ld_shlibs=no
|
|
|
|
fi
|
|
|
|
;;
|
2008-02-15 09:58:01 +00:00
|
|
|
interix[3-9]*)
|
2006-11-21 11:00:14 +00:00
|
|
|
hardcode_direct=no
|
|
|
|
hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
|
|
|
|
;;
|
2008-02-15 09:58:01 +00:00
|
|
|
gnu* | linux* | k*bsd*-gnu)
|
2006-11-21 11:00:14 +00:00
|
|
|
if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
|
|
|
|
:
|
|
|
|
else
|
|
|
|
ld_shlibs=no
|
|
|
|
fi
|
|
|
|
;;
|
2003-12-09 09:07:09 +00:00
|
|
|
netbsd*)
|
|
|
|
;;
|
2006-11-21 11:00:14 +00:00
|
|
|
solaris*)
|
2004-09-30 14:34:34 +00:00
|
|
|
if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then
|
2003-12-09 09:07:09 +00:00
|
|
|
ld_shlibs=no
|
2004-09-30 14:34:34 +00:00
|
|
|
elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
|
2003-12-09 09:07:09 +00:00
|
|
|
:
|
|
|
|
else
|
|
|
|
ld_shlibs=no
|
|
|
|
fi
|
|
|
|
;;
|
2006-11-21 11:00:14 +00:00
|
|
|
sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
|
|
|
|
case `$LD -v 2>&1` in
|
|
|
|
*\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*)
|
|
|
|
ld_shlibs=no
|
|
|
|
;;
|
|
|
|
*)
|
|
|
|
if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
|
|
|
|
hardcode_libdir_flag_spec='`test -z "$SCOABSPATH" && echo ${wl}-rpath,$libdir`'
|
|
|
|
else
|
|
|
|
ld_shlibs=no
|
|
|
|
fi
|
|
|
|
;;
|
|
|
|
esac
|
|
|
|
;;
|
2003-12-09 09:07:09 +00:00
|
|
|
sunos4*)
|
|
|
|
hardcode_direct=yes
|
|
|
|
;;
|
|
|
|
*)
|
2004-09-30 14:34:34 +00:00
|
|
|
if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
|
2003-12-09 09:07:09 +00:00
|
|
|
:
|
|
|
|
else
|
|
|
|
ld_shlibs=no
|
|
|
|
fi
|
|
|
|
;;
|
|
|
|
esac
|
2006-11-21 11:00:14 +00:00
|
|
|
if test "$ld_shlibs" = no; then
|
|
|
|
hardcode_libdir_flag_spec=
|
2003-12-09 09:07:09 +00:00
|
|
|
fi
|
|
|
|
else
|
|
|
|
case "$host_os" in
|
|
|
|
aix3*)
|
|
|
|
# Note: this linker hardcodes the directories in LIBPATH if there
|
|
|
|
# are no directories specified by -L.
|
|
|
|
hardcode_minus_L=yes
|
|
|
|
if test "$GCC" = yes; then
|
|
|
|
# Neither direct hardcoding nor static linking is supported with a
|
|
|
|
# broken collect2.
|
|
|
|
hardcode_direct=unsupported
|
|
|
|
fi
|
|
|
|
;;
|
|
|
|
aix4* | aix5*)
|
|
|
|
if test "$host_cpu" = ia64; then
|
|
|
|
# On IA64, the linker does run time linking by default, so we don't
|
|
|
|
# have to do anything special.
|
|
|
|
aix_use_runtimelinking=no
|
|
|
|
else
|
|
|
|
aix_use_runtimelinking=no
|
|
|
|
# Test if we are trying to use run time linking or normal
|
|
|
|
# AIX style linking. If -brtl is somewhere in LDFLAGS, we
|
|
|
|
# need to do runtime linking.
|
|
|
|
case $host_os in aix4.[23]|aix4.[23].*|aix5*)
|
|
|
|
for ld_flag in $LDFLAGS; do
|
|
|
|
if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
|
|
|
|
aix_use_runtimelinking=yes
|
|
|
|
break
|
|
|
|
fi
|
|
|
|
done
|
2006-11-21 11:00:14 +00:00
|
|
|
;;
|
2003-12-09 09:07:09 +00:00
|
|
|
esac
|
|
|
|
fi
|
|
|
|
hardcode_direct=yes
|
|
|
|
hardcode_libdir_separator=':'
|
|
|
|
if test "$GCC" = yes; then
|
|
|
|
case $host_os in aix4.[012]|aix4.[012].*)
|
|
|
|
collect2name=`${CC} -print-prog-name=collect2`
|
|
|
|
if test -f "$collect2name" && \
|
|
|
|
strings "$collect2name" | grep resolve_lib_name >/dev/null
|
|
|
|
then
|
|
|
|
# We have reworked collect2
|
2008-02-15 09:58:01 +00:00
|
|
|
:
|
2003-12-09 09:07:09 +00:00
|
|
|
else
|
|
|
|
# We have old collect2
|
|
|
|
hardcode_direct=unsupported
|
|
|
|
hardcode_minus_L=yes
|
|
|
|
hardcode_libdir_flag_spec='-L$libdir'
|
|
|
|
hardcode_libdir_separator=
|
|
|
|
fi
|
2006-11-21 11:00:14 +00:00
|
|
|
;;
|
2003-12-09 09:07:09 +00:00
|
|
|
esac
|
|
|
|
fi
|
|
|
|
# Begin _LT_AC_SYS_LIBPATH_AIX.
|
|
|
|
echo 'int main () { return 0; }' > conftest.c
|
|
|
|
${CC} ${LDFLAGS} conftest.c -o conftest
|
|
|
|
aix_libpath=`dump -H conftest 2>/dev/null | sed -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; }
|
|
|
|
}'`
|
|
|
|
if test -z "$aix_libpath"; then
|
|
|
|
aix_libpath=`dump -HX64 conftest 2>/dev/null | sed -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; }
|
|
|
|
}'`
|
|
|
|
fi
|
|
|
|
if test -z "$aix_libpath"; then
|
|
|
|
aix_libpath="/usr/lib:/lib"
|
|
|
|
fi
|
|
|
|
rm -f conftest.c conftest
|
|
|
|
# End _LT_AC_SYS_LIBPATH_AIX.
|
|
|
|
if test "$aix_use_runtimelinking" = yes; then
|
|
|
|
hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
|
|
|
|
else
|
|
|
|
if test "$host_cpu" = ia64; then
|
|
|
|
hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib'
|
|
|
|
else
|
|
|
|
hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
|
|
|
|
fi
|
|
|
|
fi
|
|
|
|
;;
|
|
|
|
amigaos*)
|
|
|
|
hardcode_libdir_flag_spec='-L$libdir'
|
|
|
|
hardcode_minus_L=yes
|
|
|
|
# see comment about different semantics on the GNU ld section
|
|
|
|
ld_shlibs=no
|
|
|
|
;;
|
2006-11-21 11:00:14 +00:00
|
|
|
bsdi[45]*)
|
2003-12-09 09:07:09 +00:00
|
|
|
;;
|
|
|
|
cygwin* | mingw* | pw32*)
|
|
|
|
# When not using gcc, we currently assume that we are using
|
|
|
|
# Microsoft Visual C++.
|
|
|
|
# hardcode_libdir_flag_spec is actually meaningless, as there is
|
|
|
|
# no search path for DLLs.
|
|
|
|
hardcode_libdir_flag_spec=' '
|
|
|
|
libext=lib
|
|
|
|
;;
|
|
|
|
darwin* | rhapsody*)
|
2006-11-21 11:00:14 +00:00
|
|
|
hardcode_direct=no
|
|
|
|
if test "$GCC" = yes ; then
|
|
|
|
:
|
|
|
|
else
|
|
|
|
case $cc_basename in
|
|
|
|
xlc*)
|
|
|
|
;;
|
|
|
|
*)
|
|
|
|
ld_shlibs=no
|
|
|
|
;;
|
|
|
|
esac
|
2003-12-09 09:07:09 +00:00
|
|
|
fi
|
|
|
|
;;
|
|
|
|
dgux*)
|
|
|
|
hardcode_libdir_flag_spec='-L$libdir'
|
|
|
|
;;
|
|
|
|
freebsd1*)
|
|
|
|
ld_shlibs=no
|
|
|
|
;;
|
|
|
|
freebsd2.2*)
|
|
|
|
hardcode_libdir_flag_spec='-R$libdir'
|
|
|
|
hardcode_direct=yes
|
|
|
|
;;
|
|
|
|
freebsd2*)
|
|
|
|
hardcode_direct=yes
|
|
|
|
hardcode_minus_L=yes
|
|
|
|
;;
|
2008-02-15 09:58:01 +00:00
|
|
|
freebsd* | dragonfly*)
|
2003-12-09 09:07:09 +00:00
|
|
|
hardcode_libdir_flag_spec='-R$libdir'
|
|
|
|
hardcode_direct=yes
|
|
|
|
;;
|
|
|
|
hpux9*)
|
|
|
|
hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
|
|
|
|
hardcode_libdir_separator=:
|
|
|
|
hardcode_direct=yes
|
|
|
|
# hardcode_minus_L: Not really in the search PATH,
|
|
|
|
# but as the default location of the library.
|
|
|
|
hardcode_minus_L=yes
|
|
|
|
;;
|
2006-11-21 11:00:14 +00:00
|
|
|
hpux10*)
|
2003-12-09 09:07:09 +00:00
|
|
|
if test "$with_gnu_ld" = no; then
|
2006-11-21 11:00:14 +00:00
|
|
|
hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
|
|
|
|
hardcode_libdir_separator=:
|
|
|
|
hardcode_direct=yes
|
|
|
|
# hardcode_minus_L: Not really in the search PATH,
|
|
|
|
# but as the default location of the library.
|
|
|
|
hardcode_minus_L=yes
|
|
|
|
fi
|
|
|
|
;;
|
|
|
|
hpux11*)
|
|
|
|
if test "$with_gnu_ld" = no; then
|
|
|
|
hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
|
|
|
|
hardcode_libdir_separator=:
|
|
|
|
case $host_cpu in
|
|
|
|
hppa*64*|ia64*)
|
2003-12-09 09:07:09 +00:00
|
|
|
hardcode_direct=no
|
|
|
|
;;
|
|
|
|
*)
|
|
|
|
hardcode_direct=yes
|
|
|
|
# hardcode_minus_L: Not really in the search PATH,
|
|
|
|
# but as the default location of the library.
|
|
|
|
hardcode_minus_L=yes
|
|
|
|
;;
|
|
|
|
esac
|
|
|
|
fi
|
|
|
|
;;
|
|
|
|
irix5* | irix6* | nonstopux*)
|
|
|
|
hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
|
|
|
|
hardcode_libdir_separator=:
|
|
|
|
;;
|
|
|
|
netbsd*)
|
|
|
|
hardcode_libdir_flag_spec='-R$libdir'
|
|
|
|
hardcode_direct=yes
|
|
|
|
;;
|
|
|
|
newsos6)
|
|
|
|
hardcode_direct=yes
|
|
|
|
hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
|
|
|
|
hardcode_libdir_separator=:
|
|
|
|
;;
|
|
|
|
openbsd*)
|
2008-02-15 09:58:01 +00:00
|
|
|
if test -f /usr/libexec/ld.so; then
|
|
|
|
hardcode_direct=yes
|
|
|
|
if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
|
|
|
|
hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
|
|
|
|
else
|
|
|
|
case "$host_os" in
|
|
|
|
openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*)
|
|
|
|
hardcode_libdir_flag_spec='-R$libdir'
|
|
|
|
;;
|
|
|
|
*)
|
|
|
|
hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
|
|
|
|
;;
|
|
|
|
esac
|
|
|
|
fi
|
2003-12-09 09:07:09 +00:00
|
|
|
else
|
2008-02-15 09:58:01 +00:00
|
|
|
ld_shlibs=no
|
2003-12-09 09:07:09 +00:00
|
|
|
fi
|
|
|
|
;;
|
|
|
|
os2*)
|
|
|
|
hardcode_libdir_flag_spec='-L$libdir'
|
|
|
|
hardcode_minus_L=yes
|
|
|
|
;;
|
|
|
|
osf3*)
|
|
|
|
hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
|
|
|
|
hardcode_libdir_separator=:
|
|
|
|
;;
|
|
|
|
osf4* | osf5*)
|
|
|
|
if test "$GCC" = yes; then
|
|
|
|
hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
|
|
|
|
else
|
|
|
|
# Both cc and cxx compiler support -rpath directly
|
|
|
|
hardcode_libdir_flag_spec='-rpath $libdir'
|
|
|
|
fi
|
|
|
|
hardcode_libdir_separator=:
|
|
|
|
;;
|
|
|
|
solaris*)
|
|
|
|
hardcode_libdir_flag_spec='-R$libdir'
|
|
|
|
;;
|
|
|
|
sunos4*)
|
|
|
|
hardcode_libdir_flag_spec='-L$libdir'
|
|
|
|
hardcode_direct=yes
|
|
|
|
hardcode_minus_L=yes
|
|
|
|
;;
|
|
|
|
sysv4)
|
|
|
|
case $host_vendor in
|
|
|
|
sni)
|
|
|
|
hardcode_direct=yes # is this really true???
|
|
|
|
;;
|
|
|
|
siemens)
|
|
|
|
hardcode_direct=no
|
|
|
|
;;
|
|
|
|
motorola)
|
|
|
|
hardcode_direct=no #Motorola manual says yes, but my tests say they lie
|
|
|
|
;;
|
|
|
|
esac
|
|
|
|
;;
|
|
|
|
sysv4.3*)
|
|
|
|
;;
|
|
|
|
sysv4*MP*)
|
|
|
|
if test -d /usr/nec; then
|
|
|
|
ld_shlibs=yes
|
|
|
|
fi
|
|
|
|
;;
|
2008-02-15 09:58:01 +00:00
|
|
|
sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
|
2003-12-09 09:07:09 +00:00
|
|
|
;;
|
2006-11-21 11:00:14 +00:00
|
|
|
sysv5* | sco3.2v5* | sco5v6*)
|
|
|
|
hardcode_libdir_flag_spec='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`'
|
|
|
|
hardcode_libdir_separator=':'
|
2003-12-09 09:07:09 +00:00
|
|
|
;;
|
|
|
|
uts4*)
|
|
|
|
hardcode_libdir_flag_spec='-L$libdir'
|
|
|
|
;;
|
|
|
|
*)
|
|
|
|
ld_shlibs=no
|
|
|
|
;;
|
|
|
|
esac
|
|
|
|
fi
|
|
|
|
|
|
|
|
# Check dynamic linker characteristics
|
|
|
|
# Code taken from libtool.m4's AC_LIBTOOL_SYS_DYNAMIC_LINKER.
|
2008-02-15 09:58:01 +00:00
|
|
|
# Unlike libtool.m4, here we don't care about _all_ names of the library, but
|
|
|
|
# only about the one the linker finds when passed -lNAME. This is the last
|
|
|
|
# element of library_names_spec in libtool.m4, or possibly two of them if the
|
|
|
|
# linker has special search rules.
|
|
|
|
library_names_spec= # the last element of library_names_spec in libtool.m4
|
2003-12-09 09:07:09 +00:00
|
|
|
libname_spec='lib$name'
|
|
|
|
case "$host_os" in
|
|
|
|
aix3*)
|
2008-02-15 09:58:01 +00:00
|
|
|
library_names_spec='$libname.a'
|
2003-12-09 09:07:09 +00:00
|
|
|
;;
|
|
|
|
aix4* | aix5*)
|
2008-02-15 09:58:01 +00:00
|
|
|
library_names_spec='$libname$shrext'
|
2003-12-09 09:07:09 +00:00
|
|
|
;;
|
|
|
|
amigaos*)
|
2008-02-15 09:58:01 +00:00
|
|
|
library_names_spec='$libname.a'
|
2003-12-09 09:07:09 +00:00
|
|
|
;;
|
|
|
|
beos*)
|
2008-02-15 09:58:01 +00:00
|
|
|
library_names_spec='$libname$shrext'
|
2003-12-09 09:07:09 +00:00
|
|
|
;;
|
2006-11-21 11:00:14 +00:00
|
|
|
bsdi[45]*)
|
2008-02-15 09:58:01 +00:00
|
|
|
library_names_spec='$libname$shrext'
|
2003-12-09 09:07:09 +00:00
|
|
|
;;
|
|
|
|
cygwin* | mingw* | pw32*)
|
|
|
|
shrext=.dll
|
2008-02-15 09:58:01 +00:00
|
|
|
library_names_spec='$libname.dll.a $libname.lib'
|
2003-12-09 09:07:09 +00:00
|
|
|
;;
|
|
|
|
darwin* | rhapsody*)
|
|
|
|
shrext=.dylib
|
2008-02-15 09:58:01 +00:00
|
|
|
library_names_spec='$libname$shrext'
|
2003-12-09 09:07:09 +00:00
|
|
|
;;
|
|
|
|
dgux*)
|
2008-02-15 09:58:01 +00:00
|
|
|
library_names_spec='$libname$shrext'
|
2003-12-09 09:07:09 +00:00
|
|
|
;;
|
|
|
|
freebsd1*)
|
|
|
|
;;
|
2006-11-21 11:00:14 +00:00
|
|
|
freebsd* | dragonfly*)
|
2008-02-15 09:58:01 +00:00
|
|
|
case "$host_os" in
|
|
|
|
freebsd[123]*)
|
|
|
|
library_names_spec='$libname$shrext$versuffix' ;;
|
|
|
|
*)
|
|
|
|
library_names_spec='$libname$shrext' ;;
|
|
|
|
esac
|
2003-12-09 09:07:09 +00:00
|
|
|
;;
|
|
|
|
gnu*)
|
2008-02-15 09:58:01 +00:00
|
|
|
library_names_spec='$libname$shrext'
|
2003-12-09 09:07:09 +00:00
|
|
|
;;
|
|
|
|
hpux9* | hpux10* | hpux11*)
|
2006-11-21 11:00:14 +00:00
|
|
|
case $host_cpu in
|
2003-12-09 09:07:09 +00:00
|
|
|
ia64*)
|
|
|
|
shrext=.so
|
|
|
|
;;
|
|
|
|
hppa*64*)
|
|
|
|
shrext=.sl
|
|
|
|
;;
|
|
|
|
*)
|
|
|
|
shrext=.sl
|
|
|
|
;;
|
|
|
|
esac
|
2008-02-15 09:58:01 +00:00
|
|
|
library_names_spec='$libname$shrext'
|
2003-12-09 09:07:09 +00:00
|
|
|
;;
|
2008-02-15 09:58:01 +00:00
|
|
|
interix[3-9]*)
|
|
|
|
library_names_spec='$libname$shrext'
|
2006-11-21 11:00:14 +00:00
|
|
|
;;
|
2003-12-09 09:07:09 +00:00
|
|
|
irix5* | irix6* | nonstopux*)
|
2008-02-15 09:58:01 +00:00
|
|
|
library_names_spec='$libname$shrext'
|
2003-12-09 09:07:09 +00:00
|
|
|
case "$host_os" in
|
|
|
|
irix5* | nonstopux*)
|
|
|
|
libsuff= shlibsuff=
|
|
|
|
;;
|
|
|
|
*)
|
|
|
|
case $LD in
|
|
|
|
*-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") libsuff= shlibsuff= ;;
|
|
|
|
*-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") libsuff=32 shlibsuff=N32 ;;
|
|
|
|
*-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") libsuff=64 shlibsuff=64 ;;
|
|
|
|
*) libsuff= shlibsuff= ;;
|
|
|
|
esac
|
|
|
|
;;
|
|
|
|
esac
|
|
|
|
;;
|
|
|
|
linux*oldld* | linux*aout* | linux*coff*)
|
|
|
|
;;
|
2008-02-15 09:58:01 +00:00
|
|
|
linux* | k*bsd*-gnu)
|
|
|
|
library_names_spec='$libname$shrext'
|
2003-12-09 09:07:09 +00:00
|
|
|
;;
|
2006-11-21 11:00:14 +00:00
|
|
|
knetbsd*-gnu)
|
2008-02-15 09:58:01 +00:00
|
|
|
library_names_spec='$libname$shrext'
|
2006-11-21 11:00:14 +00:00
|
|
|
;;
|
2003-12-09 09:07:09 +00:00
|
|
|
netbsd*)
|
2008-02-15 09:58:01 +00:00
|
|
|
library_names_spec='$libname$shrext'
|
2003-12-09 09:07:09 +00:00
|
|
|
;;
|
|
|
|
newsos6)
|
2008-02-15 09:58:01 +00:00
|
|
|
library_names_spec='$libname$shrext'
|
2003-12-09 09:07:09 +00:00
|
|
|
;;
|
2006-11-21 11:00:14 +00:00
|
|
|
nto-qnx*)
|
2008-02-15 09:58:01 +00:00
|
|
|
library_names_spec='$libname$shrext'
|
2003-12-09 09:07:09 +00:00
|
|
|
;;
|
|
|
|
openbsd*)
|
2008-02-15 09:58:01 +00:00
|
|
|
library_names_spec='$libname$shrext$versuffix'
|
2003-12-09 09:07:09 +00:00
|
|
|
;;
|
|
|
|
os2*)
|
|
|
|
libname_spec='$name'
|
|
|
|
shrext=.dll
|
2008-02-15 09:58:01 +00:00
|
|
|
library_names_spec='$libname.a'
|
2003-12-09 09:07:09 +00:00
|
|
|
;;
|
|
|
|
osf3* | osf4* | osf5*)
|
2008-02-15 09:58:01 +00:00
|
|
|
library_names_spec='$libname$shrext'
|
|
|
|
;;
|
|
|
|
rdos*)
|
2003-12-09 09:07:09 +00:00
|
|
|
;;
|
|
|
|
solaris*)
|
2008-02-15 09:58:01 +00:00
|
|
|
library_names_spec='$libname$shrext'
|
2003-12-09 09:07:09 +00:00
|
|
|
;;
|
|
|
|
sunos4*)
|
2008-02-15 09:58:01 +00:00
|
|
|
library_names_spec='$libname$shrext$versuffix'
|
2003-12-09 09:07:09 +00:00
|
|
|
;;
|
2006-11-21 11:00:14 +00:00
|
|
|
sysv4 | sysv4.3*)
|
2008-02-15 09:58:01 +00:00
|
|
|
library_names_spec='$libname$shrext'
|
2003-12-09 09:07:09 +00:00
|
|
|
;;
|
|
|
|
sysv4*MP*)
|
2008-02-15 09:58:01 +00:00
|
|
|
library_names_spec='$libname$shrext'
|
2003-12-09 09:07:09 +00:00
|
|
|
;;
|
2006-11-21 11:00:14 +00:00
|
|
|
sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
|
2008-02-15 09:58:01 +00:00
|
|
|
library_names_spec='$libname$shrext'
|
2006-11-21 11:00:14 +00:00
|
|
|
;;
|
2003-12-09 09:07:09 +00:00
|
|
|
uts4*)
|
2008-02-15 09:58:01 +00:00
|
|
|
library_names_spec='$libname$shrext'
|
2003-12-09 09:07:09 +00:00
|
|
|
;;
|
|
|
|
esac
|
|
|
|
|
|
|
|
sed_quote_subst='s/\(["`$\\]\)/\\\1/g'
|
|
|
|
escaped_wl=`echo "X$wl" | sed -e 's/^X//' -e "$sed_quote_subst"`
|
|
|
|
shlibext=`echo "$shrext" | sed -e 's,^\.,,'`
|
2008-02-15 09:58:01 +00:00
|
|
|
escaped_libname_spec=`echo "X$libname_spec" | sed -e 's/^X//' -e "$sed_quote_subst"`
|
|
|
|
escaped_library_names_spec=`echo "X$library_names_spec" | sed -e 's/^X//' -e "$sed_quote_subst"`
|
2003-12-09 09:07:09 +00:00
|
|
|
escaped_hardcode_libdir_flag_spec=`echo "X$hardcode_libdir_flag_spec" | sed -e 's/^X//' -e "$sed_quote_subst"`
|
|
|
|
|
2006-11-21 11:00:14 +00:00
|
|
|
LC_ALL=C sed -e 's/^\([a-zA-Z0-9_]*\)=/acl_cv_\1=/' <<EOF
|
2003-12-09 09:07:09 +00:00
|
|
|
|
|
|
|
# How to pass a linker flag through the compiler.
|
|
|
|
wl="$escaped_wl"
|
|
|
|
|
|
|
|
# Static library suffix (normally "a").
|
|
|
|
libext="$libext"
|
|
|
|
|
|
|
|
# Shared library suffix (normally "so").
|
|
|
|
shlibext="$shlibext"
|
|
|
|
|
2008-02-15 09:58:01 +00:00
|
|
|
# Format of library name prefix.
|
|
|
|
libname_spec="$escaped_libname_spec"
|
|
|
|
|
|
|
|
# Library names that the linker finds when passed -lNAME.
|
|
|
|
library_names_spec="$escaped_library_names_spec"
|
|
|
|
|
2003-12-09 09:07:09 +00:00
|
|
|
# Flag to hardcode \$libdir into a binary during linking.
|
|
|
|
# This must work even if \$libdir does not exist.
|
|
|
|
hardcode_libdir_flag_spec="$escaped_hardcode_libdir_flag_spec"
|
|
|
|
|
|
|
|
# Whether we need a single -rpath flag with a separated argument.
|
|
|
|
hardcode_libdir_separator="$hardcode_libdir_separator"
|
|
|
|
|
|
|
|
# Set to yes if using DIR/libNAME.so during linking hardcodes DIR into the
|
|
|
|
# resulting binary.
|
|
|
|
hardcode_direct="$hardcode_direct"
|
|
|
|
|
|
|
|
# Set to yes if using the -LDIR flag during linking hardcodes DIR into the
|
|
|
|
# resulting binary.
|
|
|
|
hardcode_minus_L="$hardcode_minus_L"
|
|
|
|
|
|
|
|
EOF
|