1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-06-11 22:31:12 +02:00

New libtool: 1.0b.

* ltconfig, ltmain.sh, config.guess: Freshly libtoolized.
* Makefile.in, aclocal.m4, configure: Regenerated, salamander-style.
This commit is contained in:
Jim Blandy 1997-08-29 04:49:54 +00:00
parent f44a9fae87
commit 553f653a3a
6 changed files with 1946 additions and 1156 deletions

View file

@ -65,7 +65,6 @@ GUILE_VERSION = @GUILE_VERSION@
LD = @LD@
LIBLOBJS = @LIBLOBJS@
LIBTOOL = @LIBTOOL@
LN_S = @LN_S@
MAINT = @MAINT@
MAKEINFO = @MAKEINFO@
PACKAGE = @PACKAGE@

95
aclocal.m4 vendored
View file

@ -242,12 +242,13 @@ done<<>>dnl>>)
changequote([,]))])
# serial 9 AM_PROG_LIBTOOL
# serial 11 AM_PROG_LIBTOOL
AC_DEFUN(AM_PROG_LIBTOOL,
[AC_REQUIRE([AC_CANONICAL_HOST])
AC_REQUIRE([AC_PROG_CC])
AC_REQUIRE([AC_PROG_RANLIB])
AC_REQUIRE([AC_PROG_CC])
AC_REQUIRE([AM_PROG_LD])
AC_REQUIRE([AM_PROG_NM])
AC_REQUIRE([AC_PROG_LN_S])
# Always use our own libtool.
@ -257,14 +258,24 @@ AC_SUBST(LIBTOOL)
dnl Allow the --disable-shared flag to stop us from building shared libs.
AC_ARG_ENABLE(shared,
[ --enable-shared build shared libraries [default=yes]],
test "$enableval" = no && libtool_shared=" --disable-shared",
libtool_shared=)
[if test "$enableval" = no; then
enable_shared=no
else
enable_shared=yes
fi])
libtool_shared=
test "$enable_shared" = no && libtool_shared=" --disable-shared"
dnl Allow the --disable-static flag to stop us from building static libs.
AC_ARG_ENABLE(static,
[ --enable-static build static libraries [default=yes]],
test "$enableval" = no && libtool_static=" --disable-static",
libtool_static=)
[if test "$enableval" = no; then
enable_static=no
else
enable_static=yes
fi])
libtool_static=
test "$enable_static" = no && libtool_static=" --disable-static"
libtool_flags="$libtool_shared$libtool_static"
test "$silent" = yes && libtool_flags="$libtool_flags --silent"
@ -275,11 +286,15 @@ test "$ac_cv_prog_gnu_ld" = yes && libtool_flags="$libtool_flags --with-gnu-ld"
# libtool support.
[case "$host" in
*-*-irix6*)
ac_save_CFLAGS="$CFLAGS"
# -n32 always needs to be added to the linker when using GCC.
test "$ac_cv_prog_gcc" = yes && CFLAGS="$CFLAGS -n32"
for f in '-32' '-64' '-cckr' '-n32' '-mips1' '-mips2' '-mips3' '-mips4'; do
if echo " $CC $CFLAGS " | egrep -e "[ ]$f[ ]" > /dev/null; then
LD="${LD-ld} $f"
fi
done
CFLAGS="$ac_save_CFLAGS"
;;
*-*-sco3.2v5*)
@ -290,7 +305,7 @@ esac]
# Actually configure libtool. ac_aux_dir is where install-sh is found.
CC="$CC" CFLAGS="$CFLAGS" CPPFLAGS="$CPPFLAGS" \
LD="$LD" RANLIB="$RANLIB" LN_S="$LN_S" \
LD="$LD" NM="$NM" RANLIB="$RANLIB" LN_S="$LN_S" \
${CONFIG_SHELL-/bin/sh} $ac_aux_dir/ltconfig \
$libtool_flags --no-verify $ac_aux_dir/ltmain.sh $host \
|| AC_MSG_ERROR([libtool configure failed])
@ -301,13 +316,32 @@ AC_DEFUN(AM_PROG_LD,
[AC_ARG_WITH(gnu-ld,
[ --with-gnu-ld assume the C compiler uses GNU ld [default=no]],
test "$withval" = no || with_gnu_ld=yes, with_gnu_ld=no)
if test "$with_gnu_ld" = yes; then
AC_REQUIRE([AC_PROG_CC])
ac_prog=ld
if test "$ac_cv_prog_gcc" = yes; then
# Check if gcc -print-prog-name=ld gives a path.
AC_MSG_CHECKING([for ld used by GCC])
ac_prog=`($CC -print-prog-name=ld) 2>&5`
case "$ac_prog" in
# Accept absolute paths.
/*) ;;
"")
# If it fails, then pretend we aren't using GCC.
ac_prog=ld
;;
*)
# If it is relative, then search for the first ld in PATH.
with_gnu_ld=unknown
;;
esac
elif test "$with_gnu_ld" = yes; then
AC_MSG_CHECKING([for GNU ld])
else
AC_MSG_CHECKING([for non-GNU ld])
fi
AC_CACHE_VAL(ac_cv_path_LD,
[case "$LD" in
[LD=${LD-$ac_prog}
case "$LD" in
/*)
ac_cv_path_LD="$LD" # Let the user override the test with a path.
;;
@ -315,13 +349,13 @@ AC_CACHE_VAL(ac_cv_path_LD,
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
for ac_dir in $PATH; do
test -z "$ac_dir" && ac_dir=.
if test -f "$ac_dir/ld"; then
ac_cv_path_LD="$ac_dir/ld"
if test -f "$ac_dir/$ac_prog"; then
ac_cv_path_LD="$ac_dir/$ac_prog"
# Check to see if the program is GNU ld. I'd rather use --version,
# but apparently some GNU ld's only accept -v.
# Break only if it was the GNU/non-GNU ld that we prefer.
if "$ac_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU ld|with BFD)' > /dev/null; then
test "$with_gnu_ld" = yes && break
if "$ac_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
test "$with_gnu_ld" != no && break
else
test "$with_gnu_ld" != yes && break
fi
@ -344,13 +378,46 @@ AM_PROG_LD_GNU
AC_DEFUN(AM_PROG_LD_GNU,
[AC_CACHE_CHECK([whether we are using GNU ld], ac_cv_prog_gnu_ld,
[# I'd rather use --version here, but apparently some GNU ld's only accept -v.
if $LD -v 2>&1 </dev/null | egrep '(GNU ld|with BFD)' > /dev/null; then
if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' > /dev/null; then
ac_cv_prog_gnu_ld=yes
else
ac_cv_prog_gnu_ld=no
fi])
])
# AM_PROG_NM - find the path to a BSD-compatible name lister
AC_DEFUN(AM_PROG_NM,
[AC_MSG_CHECKING([for BSD-compatible nm])
AC_CACHE_VAL(ac_cv_path_NM,
[case "$NM" in
/*)
ac_cv_path_NM="$NM" # Let the user override the test with a path.
;;
*)
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
for ac_dir in /usr/ucb:$PATH:/bin; do
test -z "$ac_dir" && dir=.
if test -f $ac_dir/nm; then
# Check to see if the nm accepts a BSD-compat flag.
if ($ac_dir/nm -B /dev/null 2>&1; exit 0) | grep /dev/null >/dev/null; then
ac_cv_path_NM="$ac_dir/nm -B"
elif ($ac_dir/nm -p /dev/null 2>&1; exit 0) | grep /dev/null >/dev/null; then
ac_cv_path_NM="$ac_dir/nm -p"
else
ac_cv_path_NM="$ac_dir/nm"
fi
break
fi
done
IFS="$ac_save_ifs"
test -z "$ac_cv_path_NM" && ac_cv_path_NM=nm
;;
esac])
NM="$ac_cv_path_NM"
AC_MSG_RESULT([$NM])
AC_SUBST(NM)
])
dnl
dnl CY_AC_WITH_THREADS determines which thread library the user intends
dnl to put underneath guile. Pass it the path to find the guile top-level

2
config.guess vendored
View file

@ -430,7 +430,7 @@ EOF
echo powerpcle-unknown-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
exit 0 ;;
*:GNU:*:*)
echo `echo ${UNAME_MACHINE}|sed -e 's,-.*$,,'`-unknown-gnu`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'`
echo `echo ${UNAME_MACHINE}|sed -e 's,[-/].*$,,'`-unknown-gnu`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'`
exit 0 ;;
*:Linux:*:*)
# The BFD linker knows what the default object file format is, so

439
configure vendored

File diff suppressed because it is too large Load diff

507
ltconfig
View file

@ -1,7 +1,6 @@
#! /bin/sh
# ltconfig - Create a system-specific libtool.
# When updating this script, search for LINENUM and fix line number refs.
# Generated automatically from ltconfig.in by configure.
# Copyright (C) 1996, 1997, Free Software Foundation, Inc.
# Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
@ -33,36 +32,42 @@ progname=`echo "$0" | sed 's%^.*/%%'`
# Constants:
PROGRAM=ltconfig
PACKAGE=libtool
VERSION=0.9h
VERSION=1.0b
ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.c 1>&5'
ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.c $LIBS 1>&5'
rm="rm -f"
help="Try \`$progname --help' for more information."
# Sed substitution that helps us do robust quoting. It backslashifies
# metacharacters that are still active within double-quoted strings.
sed_quote_subst='s/\([\\"$]\)/\\\1/g'
# Global variables:
can_build_shared=yes
enable_shared=yes
# All known linkers require a `.a' archive for static linking.
enable_static=yes
ltmain=NONE
ltmain=
silent=
srcdir=
ac_config_guess=
ac_config_sub=
host=NONE
nonopt=NONE
host=
nonopt=
verify_host=yes
with_gcc=no
with_gnu_ld=no
old_AR="$AR"
old_CC="$CC"
old_CFLAGS="$CFLAGS"
old_CPPFLAGS="$CPPFLAGS"
old_LD="$LD"
old_LN_S="$LN_S"
old_NM="$NM"
old_RANLIB="$RANLIB"
test -z "$AR" && AR=ar
# Parse the command line options.
args=
prev=
@ -95,6 +100,7 @@ Generate a system-specific libtool script.
--srcdir=DIR find \`config.guess' in DIR
--version output version information and exit
--with-gcc assume that the GNU C compiler will be used
--with-gnu-ld assume that the C compiler uses the GNU linker
LTMAIN is the \`ltmain.sh' shell script fragment that provides basic libtool
functionality.
@ -118,6 +124,7 @@ EOM
--version) echo "$PROGRAM (GNU $PACKAGE) $VERSION"; exit 0 ;;
--with-gcc) with_gcc=yes ;;
--with-gnu-ld) with_gnu_ld=yes ;;
-*)
echo "$progname: unrecognized option \`$option'" 1>&2
@ -126,9 +133,9 @@ EOM
;;
*)
if test "$ltmain" = NONE; then
if test -z "$ltmain"; then
ltmain="$option"
elif test "$host" = NONE; then
elif test -z "$host"; then
# FIXME This generates an unnecessary warning for sparc-sun-solaris4.1.3_U1
# if test -n "`echo $option| sed 's/[-a-z0-9.]//g'`"; then
# echo "$progname: warning \`$option' is not a valid host type" 1>&2
@ -142,7 +149,7 @@ EOM
esac
done
if test "$ltmain" = NONE; then
if test -z "$ltmain"; then
echo "$progname: you must specify a LTMAIN file" 1>&2
echo "$help" 1>&2
exit 1
@ -206,6 +213,7 @@ if test -z "$srcdir"; then
test "$srcdir" = "$ltmain" && srcdir=.
fi
trap "$rm conftest*; exit 1" 1 2 15
if test "$verify_host" = yes; then
# Check for config.guess and config.sub.
ac_aux_dir=
@ -235,7 +243,7 @@ if test "$verify_host" = yes; then
host_alias=$host
case "$host_alias" in
NONE)
"")
if host_alias=`$ac_config_guess`; then :
else
echo "$progname: cannot guess host type; you must specify one" 1>&2
@ -246,7 +254,7 @@ if test "$verify_host" = yes; then
host=`$ac_config_sub $host_alias`
echo "$ac_t""$host" 1>&6
elif test "$host" = NONE; then
elif test -z "$host"; then
echo "$progname: you must specify a host type if you use \`--no-verify'" 1>&2
echo "$help" 1>&2
exit 1
@ -268,23 +276,24 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
old_archive_cmds='$AR cru $oldlib$oldobjs'
old_postinstall_cmds='chmod 644 $oldlib'
# Set a sane default for `AR'.
test -z "$AR" && AR=ar
# If RANLIB is not set, then run the test.
if test "${RANLIB+set}" != "set"; then
result=no
echo $ac_n "checking for ranlib... $ac_c" 1>&6
if test "$result" = no; then
IFS="${IFS= }"; save_ifs="$IFS"; IFS="${IFS}:"
for dir in $PATH; do
test -z "$dir" && dir=.
if test -f $dir/ranlib; then
RANLIB="ranlib"
result="ranlib"
break
fi
done
IFS="$save_ifs"
fi
IFS="${IFS= }"; save_ifs="$IFS"; IFS="${IFS}:"
for dir in $PATH; do
test -z "$dir" && dir=.
if test -f $dir/ranlib; then
RANLIB="ranlib"
result="ranlib"
break
fi
done
IFS="$save_ifs"
echo $ac_t "$result" 1>&6
fi
@ -295,7 +304,7 @@ if test -n "$RANLIB"; then
fi
# Check to see if we are using GCC.
if test "$with_gcc" = no; then
if test "$with_gcc" != yes || test -z "$CC"; then
# If CC is not set, then try to find GCC or a usable CC.
if test -z "$CC"; then
echo $ac_n "checking for gcc... $ac_c" 1>&6
@ -364,16 +373,15 @@ if test "$with_gcc" = no; then
# Now see if the compiler is really GCC.
with_gcc=no
echo $ac_n "checking whether we are using GNU C... $ac_c" 1>&6
echo "$progname:376: checking whether we are using GNU C" >&5
trap "$rm conftest.c; exit 1" 1 2 15
$rm conftest.c
cat > conftest.c <<EOF
#ifdef __GNUC__
yes;
#endif
EOF
# LINENUM
if { ac_try='${CC-cc} -E conftest.c'; { (eval echo $progname:376: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
if { ac_try='${CC-cc} -E conftest.c'; { (eval echo $progname:384: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
with_gcc=yes
fi
$rm conftest.c
@ -390,18 +398,28 @@ profile_flag_pattern=
special_shlib_compile_flags=
wl=
link_static_flag=
no_builtin_flag=
if test "$with_gcc" = yes; then
pic_flag='-fPIC'
profile_flag_pattern='-pg?'
wl='-Wl,'
link_static_flag='-static'
no_builtin_flag=' -fno-builtin'
case "$host_os" in
irix5* | irix6*)
# PIC is the default for these OSes.
pic_flag=
;;
*)
pic_flag='-fPIC'
;;
esac
else
# PORTME Check for PIC flags for the system compiler.
case "$host_os" in
aix3* | aix4*)
# FIXME All rs/6000 code is PIC, but is there any non-rs/6000 AIX platform?
pic_flag=
link_static_flag='-bnso -bI:/lib/syscalls.exp'
;;
@ -409,7 +427,6 @@ else
# FIXME is there a better link_static_flag that works with the bundled CC?
wl='-Wl,'
link_static_flag='${wl}-a ${wl}archive'
pic_flag='+Z'
;;
irix5* | irix6*)
@ -450,15 +467,46 @@ else
fi
case "$host_cpu" in
rs6000 | powerpc | powerpcle)
alpha | rs6000 | powerpc | powerpcle)
# Yippee! All RS/6000 and PowerPC code is position-independent.
# Apparently, so is DEC alpha!
pic_flag=
;;
esac
if test -n "$pic_flag"; then
echo $ac_t "$pic_flag" 1>&6
pic_flag=" $pic_flag"
# Check to make sure the pic_flag actually works.
echo $ac_n "checking if $compiler PIC flag $pic_flag works... $ac_c" 1>&6
$rm conftest*
echo > conftest.c
save_CFLAGS="$CFLAGS"
CFLAGS="$CFLAGS $pic_flag -DPIC"
echo "$progname:486: checking if $compiler PIC flag $pic_flag works" >&5
if { (eval echo $progname:487: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>conftest.err; } && test -s conftest.o; then
# Append any errors to the config.log.
cat conftest.err 1>&5
# On HP-UX, the stripped-down bundled CC doesn't accept +Z, but also
# reports no error. So, we need to grep stderr for (Bundled).
if grep '(Bundled)' conftest.err >/dev/null; then
echo $ac_t no 1>&6
can_build_shared=no
pic_flag=
else
echo $ac_t yes 1>&6
pic_flag=" $pic_flag"
fi
else
# Append any errors to the config.log.
cat conftest.err 1>&5
can_build_shared=no
pic_flag=
echo $ac_t no 1>&6
fi
CFLAGS="$save_CFLAGS"
$rm conftest*
else
echo $ac_t none 1>&6
fi
@ -473,85 +521,101 @@ if test -n "$special_shlib_compile_flags"; then
fi
fi
# See if we are using a broken GCC collect2 program.
if test "$with_gcc" = yes; then
echo $ac_n "checking for broken GCC collect2... $ac_c" 1>&6
# FIXME: Run a test here, instead of relying on the canonical system name.
case "$host_os" in
aix3*)
can_build_shared=no
echo $ac_t yes 1>&6
echo "$progname: to build shared libraries, set the CC env variable to \`xlc' and reconfigure" 1>&2
;;
*)
echo $ac_t no 1>&6
;;
esac
fi
echo $ac_n "checking for $compiler option to statically link programs... $ac_c" 1>&6
if test -n "$link_static_flag"; then
echo $ac_n "checking if $compiler static flag $link_static_flag works... $ac_c" 1>&6
$rm conftest*
echo 'main(){return(0);}' > conftest.c
save_LDFLAGS="$LDFLAGS"
LDFLAGS="$LDFLAGS $link_static_flag"
echo "$progname:529: checking if $compiler static flag $link_static_flag works" >&5
if { (eval echo $progname:530: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
echo $ac_t "$link_static_flag" 1>&6
else
echo $ac_t none 1>&6
link_static_flag=
fi
LDFLAGS="$save_LDFLAGS"
$rm conftest*
if test -z "$LD"; then
# Find the linker that we think the C compiler uses.
echo $ac_n "checking for ld used by $compiler... $ac_c" 1>&6
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
for ac_dir in $PATH; do
test -z "$ac_dir" && ac_dir=.
if test -f "$ac_dir/ld"; then
# Check to see if the program is GNU ld. I'd rather use --version,
# but apparently some GNU ld's only accept -v.
if "$ac_dir/ld" -v 2>&1 < /dev/null | egrep '(GNU ld|with BFD)' > /dev/null; then
# If it was GNU ld, only accept it if we're using GCC.
LD="$ac_dir/ld"
test "$with_gcc" = yes && break
else
# If it was not GNU ld, and we are not using GCC, then accept it.
LD="$ac_dir/ld"
break
fi
fi
done
IFS="$ac_save_ifs"
if test -n "$CC"; then
echo "$ac_t""$LD" 1>&6
if test -z "$LN_S"; then
# Check to see if we can use ln -s, or we need hard links.
echo $ac_n "checking whether ln -s works... $ac_c" 1>&6
$rm conftestdata
if ln -s X conftestdata 2>/dev/null; then
$rm conftestdata
LN_S="ln -s"
else
echo "$ac_t""no" 1>&6
LN_S=ln
fi
if test -z "$LD"; then
echo "$progname: error: no acceptable ld found in \$PATH" 1>&2
exit 1
if test "$LN_S" = "ln -s"; then
echo "$ac_t"yes 1>&6
else
echo "$ac_t"no 1>&6
fi
fi
# See if we're really using GNU ld.
with_gnu_ld=no
# Allow LD to be a program name with arguments.
set dummy $LD
linker="$2"
echo $ac_n "checking if $LD is GNU ld... $ac_c" 1>&6
# I'd rather use --version here, but apparently some GNU ld's don't accept
# it, but do accept -v.
if $LD -v 2>&1 | egrep '(GNU ld|with BFD)' > /dev/null; then
with_gnu_ld=yes
linker="GNU ld"
fi
echo $ac_t "$with_gnu_ld" 1>&6
# Make sure LD is an absolute path.
case "$LD" in
/*) ;;
*)
ac_prog=ld
if test "$with_gcc" = yes; then
# Check if gcc -print-prog-name=ld gives a path.
echo $ac_n "checking for ld used by GCC... $ac_c" 1>&6
echo "$progname:564: checking for ld used by GCC" >&5
ac_prog=`($CC -print-prog-name=ld) 2>&5`
case "$ac_prog" in
# Accept absolute paths.
/*) ;;
"")
# If it fails, then pretend we aren't using GCC.
ac_prog=ld
;;
*)
# If it is relative, then search for the first ld in PATH.
with_gnu_ld=unknown
;;
esac
elif test "$with_gnu_ld" = yes; then
echo $ac_n "checking for GNU ld... $ac_c" 1>&6
echo "$progname:580: checking for GNU ld" >&5
else
echo $ac_n "checking for non-GNU ld""... $ac_c" 1>&6
echo "$progname:583: checking for non-GNU ld" >&5
fi
LD=${LD-$ac_prog}
case "$LD" in
/*)
ac_cv_path_LD="$LD" # Let the user override the test with a path.
;;
*)
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
for ac_dir in $PATH; do
test -z "$ac_dir" && ac_dir=.
if test -f "$ac_dir/$ac_prog"; then
LD="$ac_dir/$ac_prog"
# Check to see if the program is GNU ld. I'd rather use --version,
# but apparently some GNU ld's only accept -v.
# Break only if it was the GNU/non-GNU ld that we prefer.
if "$LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
test "$with_gnu_ld" != no && break
else
test "$with_gnu_ld" != yes && break
fi
fi
done
IFS="$ac_save_ifs"
;;
esac
echo $ac_t "$with_gnu_ld" 1>&6
;;
esac
# See if the linker supports building shared libraries.
echo $ac_n "checking if $linker supports shared libraries... $ac_c" 1>&6
echo $ac_n "checking whether the linker ($LD) supports shared libraries... $ac_c" 1>&6
allow_undefined_flag=
archive_cmds=
export_dynamic_flag=
export_dynamic_flag_spec=
hardcode_libdir_flag_spec=
hardcode_libdir_separator=
hardcode_direct=no
@ -583,24 +647,29 @@ if test "$with_gnu_ld" = yes; then
esac
if test "$ld_shlibs" = yes; then
archive_cmds='$cc -shared ${wl}-soname $wl$soname -o $lib$libobjs$deplibs'
archive_cmds='$CC -shared ${wl}-soname $wl$soname -o $lib$libobjs$deplibs'
hardcode_libdir_flag_spec='${wl}-rpath $wl$libdir'
export_dynamic_flag='${wl}-export-dynamic'
export_dynamic_flag_spec='${wl}-export-dynamic'
fi
else
# PORTME fill in a description of your system's linker (not GNU ld)
case "$host_os" in
aix3*)
allow_undefined_flag=unsupported
archive_cmds='/usr/ucb/nm$libobjs | egrep \" [BD] \" | sed \"s/^.* //\" > $lib.exp;$LD -o $objdir/$soname$libobjs -bE:$lib.exp -T512 -H512 -bM:SRE -lc$deplibs;$AR cru $lib $objdir/$soname'
archive_cmds='$NM$libobjs | $global_symbol_pipe | sed '"'s/.* //'"' > $lib.exp;$LD -o $objdir/$soname$libobjs -bE:$lib.exp -T512 -H512 -bM:SRE -lc$deplibs;$AR cru $lib $objdir/$soname'
# Note: this linker hardcodes the directories in LIBPATH if there
# are no directories specified by -L.
hardcode_minus_L=yes
if test "$with_gcc" = yes && test -z "$link_static_flag"; then
# Neither direct hardcoding nor static linking is supported with a
# broken collect2.
hardcode_direct=unsupported
fi
;;
aix4*)
allow_undefined_flag=unsupported
archive_cmds='/bin/nm -B$libobjs | egrep \" [BD] \" | sed \"s/^.* //\" > $lib.exp;$cc -o $objdir/$soname$libobjs ${wl}-bE:$lib.exp ${wl}-bM:SRE ${wl}-bnoentry$deplibs;$AR cru $lib $objdir/$soname'
archive_cmds='$NM$libobjs | $global_symbol_pipe | sed '"'s/.* //'"' > $lib.exp;$CC -o $objdir/$soname$libobjs ${wl}-bE:$lib.exp ${wl}-bM:SRE ${wl}-bnoentry$deplibs;$AR cru $lib $objdir/$soname'
hardcode_direct=yes
hardcode_minus_L=yes
;;
@ -693,6 +762,142 @@ else
fi
echo $ac_t "$ld_shlibs" 1>&6
if test -z "$NM"; then
echo $ac_n "checking for BSD-compatible nm... $ac_c" 1>&6
case "$NM" in
/*) ;; # Let the user override the test with a path.
*)
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
for ac_dir in /usr/ucb:$PATH:/bin; do
test -z "$ac_dir" && dir=.
if test -f $ac_dir/nm; then
# Check to see if the nm accepts a BSD-compat flag.
if ($ac_dir/nm -B /dev/null 2>&1; exit 0) | grep /dev/null >/dev/null; then
NM="$ac_dir/nm -B"
elif ($ac_dir/nm -p /dev/null 2>&1; exit 0) | grep /dev/null >/dev/null; then
NM="$ac_dir/nm -p"
else
NM="$ac_dir/nm"
fi
break
fi
done
IFS="$ac_save_ifs"
test -z "$NM" && NM=nm
;;
esac
echo "$ac_t$NM" 1>&6
fi
# Check for command to grab the raw symbol name followed by C symbol from nm.
echo $ac_n "checking command to parse $NM output... $ac_c" 1>&6
# This is a sane default that works on at least a few old systems.
# [It comes from Ultrix. What could be older than Ultrix?!! ;)]
global_symbol_pipe="sed -e '/^.* [BCDEGRSTU] /!d' -e 's/^.* [BCDEGRSTU] \(.*\)$/\1 \1/'"
# Take a first stab at what the pipe should be.
if $NM -V 2>&1 | egrep '(GNU|with BFD)' > /dev/null; then
# We're using GNU nm.
global_symbol_pipe="sed -e '/^.* [ABCDGISTU] /!d' -e 's/^.* [ABCDGISTU] \(.*\)$/\1 \1/'"
else
# It's the system nm.
case "$host_os" in
aix*)
# Delete symbols that begin with a dot.
global_symbol_pipe="sed -e '/^.* [BCDTU] [^.]/!d' -e 's/^.* [BCDTU] \(.*\)$/\1 \1/'"
;;
solaris2*)
global_symbol_pipe="sed -e '/^.* [BDTU] /!d' -e 's/^.* [BDTU] \(.*\)$/\1 \1/'"
;;
esac
fi
# Check to see that the pipe works correctly.
pipe_works=no
$rm conftest*
cat > conftest.c <<EOF
char nm_test_var;
void nm_test_func(){}
main(){nm_test_var='a';nm_test_func();return(0);}
EOF
echo "$progname:825: checking if global_symbol_pipe works" >&5
if { (eval echo $progname:826: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; } && test -s conftest.o; then
# Now try to grab the symbols.
nlist=conftest.nm
if { echo "$progname:829: eval \"$NM conftest.o | $global_symbol_pipe > $nlist\"" >&5; eval "$NM conftest.o | $global_symbol_pipe > $nlist 2>&5"; } && test -s "$nlist"; then
# Try sorting and uniquifying the output.
if sort "$nlist" | uniq > "$nlist"T; then
mv -f "$nlist"T "$nlist"
wcout=`wc "$nlist" 2>/dev/null`
count=`echo "$wcout" | sed 's/^[ ]*\([0-9][0-9]*\).*$/\1/'`
test "$wcout" = "$count" && count=-1
else
rm -f "$nlist"T
count=-1
fi
# Make sure that we snagged all the symbols we need.
if egrep ' nm_test_var$' "$nlist" >/dev/null; then
if egrep ' nm_test_func$' "$nlist" >/dev/null; then
# Now generate the symbol file.
sed 's/^.* \(.*\)$/extern char \1;/' < "$nlist" > conftest.c
cat <<EOF >> conftest.c
#if defined (__STDC__) && __STDC__
# define __ptr_t void *
#else
# define __ptr_t char *
#endif
/* The number of symbols in dld_preloaded_symbols, -1 if unsorted. */
int dld_preloaded_symbol_count = $count;
/* The mapping between symbol names and symbols. */
struct {
char *name;
__ptr_t address;
}
dld_preloaded_symbols[] =
{
EOF
sed 's/^\(.*\) \(.*\)$/ {"\1", \&\2},/' < "$nlist" >> conftest.c
cat <<\EOF >> conftest.c
{0},
};
EOF
# Now try linking the two files.
mv conftest.o conftestm.o
save_LIBS="$LIBS"
save_CFLAGS="$CFLAGS"
LIBS='conftestm.o'
CFLAGS="$CFLAGS$no_builtin_flag"
if { (eval echo $progname:877: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
pipe_works=yes
else
echo "$progname: failed program was:" >&5
cat conftest.c >&5
fi
LIBS="$save_LIBS"
fi
else
echo "cannot find nm_test_func in $nlist" >&5
fi
else
echo "cannot find nm_test_var in $nlist" >&5
fi
else
echo "$progname: failed program was:" >&5
cat conftest.c >&5
fi
$rm conftest*
# Don't use the global_symbol_pipe unless it works.
echo "$ac_t$pipe_works" 1>&6
test "$pipe_works" = yes || global_symbol_pipe=
# Check hardcoding attributes.
echo $ac_n "checking how to hardcode library paths into programs... $ac_c" 1>&6
hardcode_action=
@ -725,7 +930,7 @@ test "$hardcode_action" = unsupported && can_build_shared=no
reload_flag=
reload_cmds='$LD$reload_flag -o $output$reload_objs'
echo $ac_n "checking for $linker option to reload object files... $ac_c" 1>&6
echo $ac_n "checking for $LD option to reload object files... $ac_c" 1>&6
# PORTME Some linker may need a different reload flag.
reload_flag='-r'
echo $ac_t "$reload_flag"
@ -754,7 +959,7 @@ aix3* | aix4*)
freebsd2* | freebsd3*)
version_type=sunos
library_names_spec='$libname.so.$versuffix $libname.so'
finish_cmds='ldconfig -m $libdir'
finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
shlibpath_var=LD_LIBRARY_PATH
;;
@ -786,7 +991,6 @@ irix5* | irix6*)
# No shared lib support for Linux oldld, aout, or coff.
linux-gnuoldld* | linux-gnuaout* | linux-gnucoff*)
dynamic_linker=no
can_build_shared=no
;;
# This must be Linux ELF.
@ -794,14 +998,24 @@ linux-gnu*)
version_type=linux
library_names_spec='$libname.so.$versuffix $libname.so.$major $libname.so'
soname_spec='$libname.so.$major'
finish_cmds='ldconfig -n $libdir'
finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
shlibpath_var=LD_LIBRARY_PATH
if test -f /lib/ld.so.1; then
dynamic_linker='GNU ld.so'
else
# Only the GNU ld.so supports shared libraries on MkLinux.
case "$host_cpu" in
powerpc*) dynamic_linker=no ;;
*) dynamic_linker='Linux ld.so' ;;
esac
fi
;;
netbsd* | openbsd*)
version_type=sunos
library_names_spec='$libname.so.$versuffix'
finish_cmds='ldconfig -m $libdir'
finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
shlibpath_var=LD_LIBRARY_PATH
;;
@ -829,17 +1043,16 @@ solaris2*)
sunos4*)
version_type=sunos
library_names_spec='$libname.so.$versuffix'
finish_cmds='ldconfig $libdir'
finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
shlibpath_var=LD_LIBRARY_PATH
;;
*)
dynamic_linker=no
can_build_shared=no
;;
esac
echo "$ac_t""$dynamic_linker"
test "$dynamic_linker" = no && can_build_shared=no
# FIXME need to add library stripping features
# strip -x works for most platforms, though not for static libraries on NetBSD
@ -888,10 +1101,22 @@ test "$enable_shared" = yes || enable_static=yes
echo "checking whether to build static libraries... $enable_static" 1>&6
# Now quote all the things that may contain metacharacters.
for var in old_CC old_CFLAGS old_CPPFLAGS old_LD old_NM old_RANLIB \
old_LN_S AR CC LD LN_S NM reload_flag reload_cmds wl pic_flag \
link_static_flag no_builtin_flag export_dynamic_flag_spec \
profile_flag_pattern library_names_spec soname_spec RANLIB \
old_archive_cmds old_postinstall_cmds archive_cmds postinstall_cmds \
allow_undefined_flag finish_cmds global_symbol_pipe striplib old_striplib \
hardcode_libdir_flag_spec hardcode_libdir_separator; do
eval "$var=\`echo \"\$$var\" | sed \"\$sed_quote_subst\"\`"
done
ofile=libtool
trap "$rm $ofile; exit 1" 1 2 15
echo creating $ofile
rm -fr $ofile
$rm $ofile
cat <<EOF > $ofile
#! /bin/sh
@ -901,7 +1126,8 @@ cat <<EOF > $ofile
# This program was configured as follows,
# on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
#
# CC="$old_CC" CFLAGS="$old_CFLAGS" LD="$old_LD" RANLIB="$old_RANLIB" \\
# CC="$old_CC" CFLAGS="$old_CFLAGS" CPPFLAGS="$old_CPPFLAGS" \\
# LD="$old_LD" NM="$old_NM" RANLIB="$old_RANLIB" LN_S="$old_LN_S" \\
# $0$ltconfig_args
#
# Compiler and other test output produced by $progname, useful for
@ -921,58 +1147,73 @@ host_alias="$host_alias"
host="$host"
# The archiver.
AR='$AR'
AR="$AR"
# The default C compiler.
CC="$CC"
# The linker used to build libraries.
LD='$LD'
LD="$LD"
# Whether we need hard or soft links.
LN_S="$LN_S"
# A BSD-compatible nm program.
NM="$NM"
# How to create reloadable object files.
reload_flag='$reload_flag'
reload_cmds='$reload_cmds'
reload_flag="$reload_flag"
reload_cmds="$reload_cmds"
# How to pass a linker flag through the compiler.
wl='$wl'
wl="$wl"
# Additional compiler flags for building library objects.
pic_flag='$pic_flag'
pic_flag="$pic_flag"
# Compiler flag to prevent dynamic linking.
link_static_flag='$link_static_flag'
link_static_flag="$link_static_flag"
# Compiler flag to turn off builtin functions.
no_builtin_flag="$no_builtin_flag"
# Compiler flag to allow reflexive dlopens.
export_dynamic_flag='$export_dynamic_flag'
export_dynamic_flag_spec="$export_dynamic_flag_spec"
# Pattern to match compiler flags for creating libNAME_p libraries:
profile_flag_pattern='$profile_flag_pattern'
profile_flag_pattern="$profile_flag_pattern"
# Library versioning type.
version_type=$version_type
# List of archive names. First name is the real one, the rest are links.
# The last name is the one that the linker finds with -lNAME.
library_names_spec='$library_names_spec'
library_names_spec="$library_names_spec"
# The coded name of the library, if different from the real name.
soname_spec='$soname_spec'
soname_spec="$soname_spec"
# Commands used to build and install an old-style archive.
RANLIB='$RANLIB'
old_archive_cmds='$old_archive_cmds'
old_postinstall_cmds='$old_postinstall_cmds'
RANLIB="$RANLIB"
old_archive_cmds="$old_archive_cmds"
old_postinstall_cmds="$old_postinstall_cmds"
# Commands used to build and install a shared archive.
archive_cmds='$archive_cmds'
postinstall_cmds='$postinstall_cmds'
archive_cmds="$archive_cmds"
postinstall_cmds="$postinstall_cmds"
# Flag that allows shared libraries with undefined symbols to be built.
allow_undefined_flag='$allow_undefined_flag'
allow_undefined_flag="$allow_undefined_flag"
# Commands used to finish a libtool library installation in a directory.
finish_cmds='$finish_cmds'
finish_cmds="$finish_cmds"
# Take the output of nm and produce a listing of raw symbols and C names
global_symbol_pipe="$global_symbol_pipe"
# How to strip a library file.
striplib='$striplib'
old_striplib='$old_striplib'
striplib="$striplib"
old_striplib="$old_striplib"
# This is the shared library runtime path variable.
runpath_var=$runpath_var
@ -985,10 +1226,10 @@ hardcode_action=$hardcode_action
# Flag to hardcode \$libdir into a binary during linking.
# This must work even if \$libdir does not exist.
hardcode_libdir_flag_spec='$hardcode_libdir_flag_spec'
hardcode_libdir_flag_spec="$hardcode_libdir_flag_spec"
# Whether we need a single -rpath flag with a separated argument.
hardcode_libdir_separator='$hardcode_libdir_separator'
hardcode_libdir_separator="$hardcode_libdir_separator"
# Set to yes if using DIR/libNAME.so during linking hardcodes DIR into the
# resulting binary.

2058
ltmain.sh

File diff suppressed because it is too large Load diff