929
929
AC_SUBST([am__untar])
930
930
]) # _AM_PROG_TAR
932
# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
934
# serial 52 Debian 1.5.26-4 AC_PROG_LIBTOOL
937
# AC_PROVIDE_IFELSE(MACRO-NAME, IF-PROVIDED, IF-NOT-PROVIDED)
938
# -----------------------------------------------------------
939
# If this macro is not defined by Autoconf, define it here.
940
m4_ifdef([AC_PROVIDE_IFELSE],
942
[m4_define([AC_PROVIDE_IFELSE],
943
[m4_ifdef([AC_PROVIDE_$1],
949
AC_DEFUN([AC_PROG_LIBTOOL],
950
[AC_REQUIRE([_AC_PROG_LIBTOOL])dnl
951
dnl If AC_PROG_CXX has already been expanded, run AC_LIBTOOL_CXX
952
dnl immediately, otherwise, hook it in at the end of AC_PROG_CXX.
953
AC_PROVIDE_IFELSE([AC_PROG_CXX],
955
[define([AC_PROG_CXX], defn([AC_PROG_CXX])[AC_LIBTOOL_CXX
957
dnl And a similar setup for Fortran 77 support
958
AC_PROVIDE_IFELSE([AC_PROG_F77],
960
[define([AC_PROG_F77], defn([AC_PROG_F77])[AC_LIBTOOL_F77
963
dnl Quote A][M_PROG_GCJ so that aclocal doesn't bring it in needlessly.
964
dnl If either AC_PROG_GCJ or A][M_PROG_GCJ have already been expanded, run
965
dnl AC_LIBTOOL_GCJ immediately, otherwise, hook it in at the end of both.
966
AC_PROVIDE_IFELSE([AC_PROG_GCJ],
968
[AC_PROVIDE_IFELSE([A][M_PROG_GCJ],
970
[AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ],
972
[ifdef([AC_PROG_GCJ],
973
[define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[AC_LIBTOOL_GCJ])])
974
ifdef([A][M_PROG_GCJ],
975
[define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[AC_LIBTOOL_GCJ])])
976
ifdef([LT_AC_PROG_GCJ],
977
[define([LT_AC_PROG_GCJ],
978
defn([LT_AC_PROG_GCJ])[AC_LIBTOOL_GCJ])])])])
979
])])# AC_PROG_LIBTOOL
984
AC_DEFUN([_AC_PROG_LIBTOOL],
985
[AC_REQUIRE([AC_LIBTOOL_SETUP])dnl
986
AC_BEFORE([$0],[AC_LIBTOOL_CXX])dnl
987
AC_BEFORE([$0],[AC_LIBTOOL_F77])dnl
988
AC_BEFORE([$0],[AC_LIBTOOL_GCJ])dnl
990
# This can be used to rebuild libtool when needed
991
LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh"
993
# Always use our own libtool.
994
LIBTOOL='$(SHELL) $(top_builddir)/libtool'
997
# Prevent multiple expansion
998
define([AC_PROG_LIBTOOL], [])
1004
AC_DEFUN([AC_LIBTOOL_SETUP],
1006
AC_REQUIRE([AC_ENABLE_SHARED])dnl
1007
AC_REQUIRE([AC_ENABLE_STATIC])dnl
1008
AC_REQUIRE([AC_ENABLE_FAST_INSTALL])dnl
1009
AC_REQUIRE([AC_CANONICAL_HOST])dnl
1010
AC_REQUIRE([AC_CANONICAL_BUILD])dnl
1011
AC_REQUIRE([AC_PROG_CC])dnl
1012
AC_REQUIRE([AC_PROG_LD])dnl
1013
AC_REQUIRE([AC_PROG_LD_RELOAD_FLAG])dnl
1014
AC_REQUIRE([AC_PROG_NM])dnl
1016
AC_REQUIRE([AC_PROG_LN_S])dnl
1017
AC_REQUIRE([AC_DEPLIBS_CHECK_METHOD])dnl
1018
# Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers!
1019
AC_REQUIRE([AC_OBJEXT])dnl
1020
AC_REQUIRE([AC_EXEEXT])dnl
1022
AC_LIBTOOL_SYS_MAX_CMD_LEN
1023
AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
1026
AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl
1027
_LT_AC_PROG_ECHO_BACKSLASH
1031
# AIX sometimes has problems with the GCC collect2 program. For some
1032
# reason, if we set the COLLECT_NAMES environment variable, the problems
1033
# vanish in a puff of smoke.
1034
if test "X${COLLECT_NAMES+set}" != Xset; then
1036
export COLLECT_NAMES
1041
# Sed substitution that helps us do robust quoting. It backslashifies
1042
# metacharacters that are still active within double-quoted strings.
1043
Xsed='sed -e 1s/^X//'
1044
[sed_quote_subst='s/\([\\"\\`$\\\\]\)/\\\1/g']
1046
# Same as above, but do not quote variable references.
1047
[double_quote_subst='s/\([\\"\\`\\\\]\)/\\\1/g']
1049
# Sed substitution to delay expansion of an escaped shell variable in a
1050
# double_quote_subst'ed string.
1051
delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
1053
# Sed substitution to avoid accidental globbing in evaled expressions
1054
no_glob_subst='s/\*/\\\*/g'
1060
default_ofile=libtool
1061
can_build_shared=yes
1063
# All known linkers require a `.a' archive for static linking (except MSVC,
1064
# which needs '.lib').
1066
ltmain="$ac_aux_dir/ltmain.sh"
1067
ofile="$default_ofile"
1068
with_gnu_ld="$lt_cv_prog_gnu_ld"
1070
AC_CHECK_TOOL(AR, ar, false)
1071
AC_CHECK_TOOL(RANLIB, ranlib, :)
1072
AC_CHECK_TOOL(STRIP, strip, :)
1075
old_CFLAGS="$CFLAGS"
1077
# Set sane defaults for various variables
1078
test -z "$AR" && AR=ar
1079
test -z "$AR_FLAGS" && AR_FLAGS=cru
1080
test -z "$AS" && AS=as
1081
test -z "$CC" && CC=cc
1082
test -z "$LTCC" && LTCC=$CC
1083
test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
1084
test -z "$DLLTOOL" && DLLTOOL=dlltool
1085
test -z "$LD" && LD=ld
1086
test -z "$LN_S" && LN_S="ln -s"
1087
test -z "$MAGIC_CMD" && MAGIC_CMD=file
1088
test -z "$NM" && NM=nm
1089
test -z "$SED" && SED=sed
1090
test -z "$OBJDUMP" && OBJDUMP=objdump
1091
test -z "$RANLIB" && RANLIB=:
1092
test -z "$STRIP" && STRIP=:
1093
test -z "$ac_objext" && ac_objext=o
1095
# Determine commands to create old-style static archives.
1096
old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
1097
old_postinstall_cmds='chmod 644 $oldlib'
1098
old_postuninstall_cmds=
1100
if test -n "$RANLIB"; then
1103
old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib"
1106
old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib"
1109
old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
1112
_LT_CC_BASENAME([$compiler])
1114
# Only perform the check for file, if the check method requires it
1115
case $deplibs_check_method in
1117
if test "$file_magic_cmd" = '$MAGIC_CMD'; then
1123
_LT_REQUIRED_DARWIN_CHECKS
1125
AC_PROVIDE_IFELSE([AC_LIBTOOL_DLOPEN], enable_dlopen=yes, enable_dlopen=no)
1126
AC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL],
1127
enable_win32_dll=yes, enable_win32_dll=no)
1129
AC_ARG_ENABLE([libtool-lock],
1130
[AC_HELP_STRING([--disable-libtool-lock],
1131
[avoid locking (might break parallel builds)])])
1132
test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
1135
[AC_HELP_STRING([--with-pic],
1136
[try to use only PIC/non-PIC objects @<:@default=use both@:>@])],
1137
[pic_mode="$withval"],
1139
test -z "$pic_mode" && pic_mode=default
1141
# Use C for the default configuration in the libtool script
1143
AC_LIBTOOL_LANG_C_CONFIG
1145
])# AC_LIBTOOL_SETUP
1148
# _LT_AC_SYS_COMPILER
1149
# -------------------
1150
AC_DEFUN([_LT_AC_SYS_COMPILER],
1151
[AC_REQUIRE([AC_PROG_CC])dnl
1153
# If no C compiler was specified, use CC.
1156
# If no C compiler flags were specified, use CFLAGS.
1157
LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
1159
# Allow CC to be a program name with arguments.
1161
])# _LT_AC_SYS_COMPILER
1164
# _LT_CC_BASENAME(CC)
1165
# -------------------
1166
# Calculate cc_basename. Skip known compiler wrappers and cross-prefix.
1167
AC_DEFUN([_LT_CC_BASENAME],
1168
[for cc_temp in $1""; do
1170
compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;;
1171
distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;;
1176
cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
1180
# _LT_COMPILER_BOILERPLATE
1181
# ------------------------
1182
# Check for compiler boilerplate output or warnings with
1183
# the simple compiler test code.
1184
AC_DEFUN([_LT_COMPILER_BOILERPLATE],
1185
[AC_REQUIRE([LT_AC_PROG_SED])dnl
1186
ac_outfile=conftest.$ac_objext
1187
echo "$lt_simple_compile_test_code" >conftest.$ac_ext
1188
eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
1189
_lt_compiler_boilerplate=`cat conftest.err`
1191
])# _LT_COMPILER_BOILERPLATE
1194
# _LT_LINKER_BOILERPLATE
1195
# ----------------------
1196
# Check for linker boilerplate output or warnings with
1197
# the simple link test code.
1198
AC_DEFUN([_LT_LINKER_BOILERPLATE],
1199
[AC_REQUIRE([LT_AC_PROG_SED])dnl
1200
ac_outfile=conftest.$ac_objext
1201
echo "$lt_simple_link_test_code" >conftest.$ac_ext
1202
eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
1203
_lt_linker_boilerplate=`cat conftest.err`
1205
])# _LT_LINKER_BOILERPLATE
1207
# _LT_REQUIRED_DARWIN_CHECKS
1208
# --------------------------
1209
# Check for some things on darwin
1210
AC_DEFUN([_LT_REQUIRED_DARWIN_CHECKS],[
1212
rhapsody* | darwin*)
1213
AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:])
1214
AC_CHECK_TOOL([NMEDIT], [nmedit], [:])
1216
AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod],
1217
[lt_cv_apple_cc_single_mod=no
1218
if test -z "${LT_MULTI_MODULE}"; then
1219
# By default we will add the -single_module flag. You can override
1220
# by either setting the environment variable LT_MULTI_MODULE
1221
# non-empty at configure time, or by adding -multi_module to the
1223
echo "int foo(void){return 1;}" > conftest.c
1224
$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
1225
-dynamiclib ${wl}-single_module conftest.c
1226
if test -f libconftest.dylib; then
1227
lt_cv_apple_cc_single_mod=yes
1228
rm -rf libconftest.dylib*
1232
AC_CACHE_CHECK([for -exported_symbols_list linker flag],
1233
[lt_cv_ld_exported_symbols_list],
1234
[lt_cv_ld_exported_symbols_list=no
1235
save_LDFLAGS=$LDFLAGS
1236
echo "_main" > conftest.sym
1237
LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
1238
AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
1239
[lt_cv_ld_exported_symbols_list=yes],
1240
[lt_cv_ld_exported_symbols_list=no])
1241
LDFLAGS="$save_LDFLAGS"
1244
rhapsody* | darwin1.[[0123]])
1245
_lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
1247
_lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
1249
# if running on 10.5 or later, the deployment target defaults
1250
# to the OS version, if on x86, and 10.4, the deployment
1251
# target defaults to 10.4. Don't you love it?
1252
case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
1253
10.0,*86*-darwin8*|10.0,*-darwin[[91]]*)
1254
_lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
1256
_lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
1258
_lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
1262
if test "$lt_cv_apple_cc_single_mod" = "yes"; then
1263
_lt_dar_single_mod='$single_module'
1265
if test "$lt_cv_ld_exported_symbols_list" = "yes"; then
1266
_lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym'
1268
_lt_dar_export_syms="~$NMEDIT -s \$output_objdir/\${libname}-symbols.expsym \${lib}"
1270
if test "$DSYMUTIL" != ":"; then
1271
_lt_dsymutil="~$DSYMUTIL \$lib || :"
1279
# _LT_AC_SYS_LIBPATH_AIX
1280
# ----------------------
1281
# Links a minimal program and checks the executable
1282
# for the system default hardcoded library path. In most cases,
1283
# this is /usr/lib:/lib, but when the MPI compilers are used
1284
# the location of the communication and MPI libs are included too.
1285
# If we don't find anything, use the default library path according
1286
# to the aix ld manual.
1287
AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX],
1288
[AC_REQUIRE([LT_AC_PROG_SED])dnl
1289
AC_LINK_IFELSE(AC_LANG_PROGRAM,[
1290
lt_aix_libpath_sed='
1291
/Import File Strings/,/^$/ {
1297
aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
1298
# Check for a 64-bit object if we didn't find anything.
1299
if test -z "$aix_libpath"; then
1300
aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
1302
if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
1303
])# _LT_AC_SYS_LIBPATH_AIX
1306
# _LT_AC_SHELL_INIT(ARG)
1307
# ----------------------
1308
AC_DEFUN([_LT_AC_SHELL_INIT],
1309
[ifdef([AC_DIVERSION_NOTICE],
1310
[AC_DIVERT_PUSH(AC_DIVERSION_NOTICE)],
1311
[AC_DIVERT_PUSH(NOTICE)])
1314
])# _LT_AC_SHELL_INIT
1317
# _LT_AC_PROG_ECHO_BACKSLASH
1318
# --------------------------
1319
# Add some code to the start of the generated configure script which
1320
# will find an echo command which doesn't interpret backslashes.
1321
AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH],
1322
[_LT_AC_SHELL_INIT([
1323
# Check that we are running under the correct shell.
1324
SHELL=${CONFIG_SHELL-/bin/sh}
1328
# Remove one level of quotation (which was required for Make).
1329
ECHO=`echo "$ECHO" | sed 's,\\\\\[$]\\[$]0,'[$]0','`
1334
if test "X[$]1" = X--no-reexec; then
1335
# Discard the --no-reexec flag, and continue.
1337
elif test "X[$]1" = X--fallback-echo; then
1338
# Avoid inline document here, it may be left over
1340
elif test "X`($echo '\t') 2>/dev/null`" = 'X\t' ; then
1341
# Yippee, $echo works!
1344
# Restart under the correct shell.
1345
exec $SHELL "[$]0" --no-reexec ${1+"[$]@"}
1348
if test "X[$]1" = X--fallback-echo; then
1349
# used as fallback echo
1357
# The HP-UX ksh and POSIX shell print the target directory to stdout
1359
(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
1361
if test -z "$ECHO"; then
1362
if test "X${echo_test_string+set}" != Xset; then
1363
# find a string as large as possible, as long as the shell can cope with it
1364
for cmd in 'sed 50q "[$]0"' 'sed 20q "[$]0"' 'sed 10q "[$]0"' 'sed 2q "[$]0"' 'echo test'; do
1365
# expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ...
1366
if (echo_test_string=`eval $cmd`) 2>/dev/null &&
1367
echo_test_string=`eval $cmd` &&
1368
(test "X$echo_test_string" = "X$echo_test_string") 2>/dev/null
1375
if test "X`($echo '\t') 2>/dev/null`" = 'X\t' &&
1376
echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` &&
1377
test "X$echo_testing_string" = "X$echo_test_string"; then
1380
# The Solaris, AIX, and Digital Unix default echo programs unquote
1381
# backslashes. This makes it impossible to quote backslashes using
1382
# echo "$something" | sed 's/\\/\\\\/g'
1384
# So, first we look for a working echo in the user's PATH.
1386
lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
1387
for dir in $PATH /usr/ucb; do
1389
if (test -f $dir/echo || test -f $dir/echo$ac_exeext) &&
1390
test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' &&
1391
echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` &&
1392
test "X$echo_testing_string" = "X$echo_test_string"; then
1399
if test "X$echo" = Xecho; then
1400
# We didn't find a better echo, so look for alternatives.
1401
if test "X`(print -r '\t') 2>/dev/null`" = 'X\t' &&
1402
echo_testing_string=`(print -r "$echo_test_string") 2>/dev/null` &&
1403
test "X$echo_testing_string" = "X$echo_test_string"; then
1404
# This shell has a builtin print -r that does the trick.
1406
elif (test -f /bin/ksh || test -f /bin/ksh$ac_exeext) &&
1407
test "X$CONFIG_SHELL" != X/bin/ksh; then
1408
# If we have ksh, try running configure again with it.
1409
ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh}
1410
export ORIGINAL_CONFIG_SHELL
1411
CONFIG_SHELL=/bin/ksh
1413
exec $CONFIG_SHELL "[$]0" --no-reexec ${1+"[$]@"}
1417
if test "X`($echo '\t') 2>/dev/null`" = 'X\t' &&
1418
echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` &&
1419
test "X$echo_testing_string" = "X$echo_test_string"; then
1420
# Cool, printf works
1422
elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
1423
test "X$echo_testing_string" = 'X\t' &&
1424
echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
1425
test "X$echo_testing_string" = "X$echo_test_string"; then
1426
CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL
1428
SHELL="$CONFIG_SHELL"
1430
echo="$CONFIG_SHELL [$]0 --fallback-echo"
1431
elif echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
1432
test "X$echo_testing_string" = 'X\t' &&
1433
echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
1434
test "X$echo_testing_string" = "X$echo_test_string"; then
1435
echo="$CONFIG_SHELL [$]0 --fallback-echo"
1437
# maybe with a smaller string...
1440
for cmd in 'echo test' 'sed 2q "[$]0"' 'sed 10q "[$]0"' 'sed 20q "[$]0"' 'sed 50q "[$]0"'; do
1441
if (test "X$echo_test_string" = "X`eval $cmd`") 2>/dev/null
1448
if test "$prev" != 'sed 50q "[$]0"'; then
1449
echo_test_string=`eval $prev`
1450
export echo_test_string
1451
exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "[$]0" ${1+"[$]@"}
1453
# Oops. We lost completely, so just stick with echo.
1462
# Copy echo and quote the copy suitably for passing to libtool from
1463
# the Makefile, instead of quoting the original, which is used later.
1465
if test "X$ECHO" = "X$CONFIG_SHELL [$]0 --fallback-echo"; then
1466
ECHO="$CONFIG_SHELL \\\$\[$]0 --fallback-echo"
1470
])])# _LT_AC_PROG_ECHO_BACKSLASH
1475
AC_DEFUN([_LT_AC_LOCK],
1476
[AC_ARG_ENABLE([libtool-lock],
1477
[AC_HELP_STRING([--disable-libtool-lock],
1478
[avoid locking (might break parallel builds)])])
1479
test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
1481
# Some flags need to be propagated to the compiler or linker for good
1485
# Find out which ABI we are using.
1486
echo 'int i;' > conftest.$ac_ext
1487
if AC_TRY_EVAL(ac_compile); then
1488
case `/usr/bin/file conftest.$ac_objext` in
1500
# Find out which ABI we are using.
1501
echo '[#]line __oline__ "configure"' > conftest.$ac_ext
1502
if AC_TRY_EVAL(ac_compile); then
1503
if test "$lt_cv_prog_gnu_ld" = yes; then
1504
case `/usr/bin/file conftest.$ac_objext` in
1506
LD="${LD-ld} -melf32bsmip"
1509
LD="${LD-ld} -melf32bmipn32"
1512
LD="${LD-ld} -melf64bmip"
1516
case `/usr/bin/file conftest.$ac_objext` in
1532
x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \
1533
s390*-*linux*|sparc*-*linux*)
1534
# Find out which ABI we are using.
1535
echo 'int i;' > conftest.$ac_ext
1536
if AC_TRY_EVAL(ac_compile); then
1537
case `/usr/bin/file conftest.o` in
1540
x86_64-*kfreebsd*-gnu)
1541
LD="${LD-ld} -m elf_i386_fbsd"
1544
LD="${LD-ld} -m elf_i386"
1546
ppc64-*linux*|powerpc64-*linux*)
1547
LD="${LD-ld} -m elf32ppclinux"
1550
LD="${LD-ld} -m elf_s390"
1553
LD="${LD-ld} -m elf32_sparc"
1559
x86_64-*kfreebsd*-gnu)
1560
LD="${LD-ld} -m elf_x86_64_fbsd"
1563
LD="${LD-ld} -m elf_x86_64"
1565
ppc*-*linux*|powerpc*-*linux*)
1566
LD="${LD-ld} -m elf64ppc"
1569
LD="${LD-ld} -m elf64_s390"
1572
LD="${LD-ld} -m elf64_sparc"
1582
# On SCO OpenServer 5, we need -belf to get full-featured binaries.
1583
SAVE_CFLAGS="$CFLAGS"
1584
CFLAGS="$CFLAGS -belf"
1585
AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf,
1587
AC_TRY_LINK([],[],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no])
1589
if test x"$lt_cv_cc_needs_belf" != x"yes"; then
1590
# this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
1591
CFLAGS="$SAVE_CFLAGS"
1595
# Find out which ABI we are using.
1596
echo 'int i;' > conftest.$ac_ext
1597
if AC_TRY_EVAL(ac_compile); then
1598
case `/usr/bin/file conftest.o` in
1600
case $lt_cv_prog_gnu_ld in
1601
yes*) LD="${LD-ld} -m elf64_sparc" ;;
1603
if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
1614
AC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL],
1615
[*-*-cygwin* | *-*-mingw* | *-*-pw32*)
1616
AC_CHECK_TOOL(DLLTOOL, dlltool, false)
1617
AC_CHECK_TOOL(AS, as, false)
1618
AC_CHECK_TOOL(OBJDUMP, objdump, false)
1623
need_locks="$enable_libtool_lock"
1628
# AC_LIBTOOL_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
1629
# [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE])
1630
# ----------------------------------------------------------------
1631
# Check whether the given compiler option works
1632
AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION],
1633
[AC_REQUIRE([LT_AC_PROG_SED])
1634
AC_CACHE_CHECK([$1], [$2],
1636
ifelse([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4])
1637
echo "$lt_simple_compile_test_code" > conftest.$ac_ext
1638
lt_compiler_flag="$3"
1639
# Insert the option either (1) after the last *FLAGS variable, or
1640
# (2) before a word containing "conftest.", or (3) at the end.
1641
# Note that $ac_compile itself does not contain backslashes and begins
1642
# with a dollar sign (not a hyphen), so the echo should work correctly.
1643
# The option is referenced via a variable to avoid confusing sed.
1644
lt_compile=`echo "$ac_compile" | $SED \
1645
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
1646
-e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
1647
-e 's:$: $lt_compiler_flag:'`
1648
(eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
1649
(eval "$lt_compile" 2>conftest.err)
1651
cat conftest.err >&AS_MESSAGE_LOG_FD
1652
echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
1653
if (exit $ac_status) && test -s "$ac_outfile"; then
1654
# The compiler can only warn and ignore the option if not recognized
1655
# So say no if there are warnings other than the usual output.
1656
$echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
1657
$SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
1658
if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
1665
if test x"[$]$2" = xyes; then
1666
ifelse([$5], , :, [$5])
1668
ifelse([$6], , :, [$6])
1670
])# AC_LIBTOOL_COMPILER_OPTION
1673
# AC_LIBTOOL_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
1674
# [ACTION-SUCCESS], [ACTION-FAILURE])
1675
# ------------------------------------------------------------
1676
# Check whether the given compiler option works
1677
AC_DEFUN([AC_LIBTOOL_LINKER_OPTION],
1678
[AC_REQUIRE([LT_AC_PROG_SED])dnl
1679
AC_CACHE_CHECK([$1], [$2],
1681
save_LDFLAGS="$LDFLAGS"
1682
LDFLAGS="$LDFLAGS $3"
1683
echo "$lt_simple_link_test_code" > conftest.$ac_ext
1684
if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
1685
# The linker can only warn and ignore the option if not recognized
1686
# So say no if there are warnings
1687
if test -s conftest.err; then
1688
# Append any errors to the config.log.
1689
cat conftest.err 1>&AS_MESSAGE_LOG_FD
1690
$echo "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp
1691
$SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
1692
if diff conftest.exp conftest.er2 >/dev/null; then
1700
LDFLAGS="$save_LDFLAGS"
1703
if test x"[$]$2" = xyes; then
1704
ifelse([$4], , :, [$4])
1706
ifelse([$5], , :, [$5])
1708
])# AC_LIBTOOL_LINKER_OPTION
1711
# AC_LIBTOOL_SYS_MAX_CMD_LEN
1712
# --------------------------
1713
AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN],
1714
[# find the maximum length of command line arguments
1715
AC_MSG_CHECKING([the maximum length of command line arguments])
1716
AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl
1722
# On DJGPP, this test can blow up pretty badly due to problems in libc
1723
# (any single argument exceeding 2000 bytes causes a buffer overrun
1724
# during glob expansion). Even if it were fixed, the result of this
1725
# check would be larger than it should be.
1726
lt_cv_sys_max_cmd_len=12288; # 12K is about right
1730
# Under GNU Hurd, this test is not required because there is
1731
# no limit to the length of command line arguments.
1732
# Libtool will interpret -1 as no limit whatsoever
1733
lt_cv_sys_max_cmd_len=-1;
1737
# On Win9x/ME, this test blows up -- it succeeds, but takes
1738
# about 5 minutes as the teststring grows exponentially.
1739
# Worse, since 9x/ME are not pre-emptively multitasking,
1740
# you end up with a "frozen" computer, even though with patience
1741
# the test eventually succeeds (with a max line length of 256k).
1742
# Instead, let's just punt: use the minimum linelength reported by
1743
# all of the supported platforms: 8192 (on NT/2K/XP).
1744
lt_cv_sys_max_cmd_len=8192;
1748
# On AmigaOS with pdksh, this test takes hours, literally.
1749
# So we just punt and use a minimum line length of 8192.
1750
lt_cv_sys_max_cmd_len=8192;
1753
netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
1754
# This has been around since 386BSD, at least. Likely further.
1755
if test -x /sbin/sysctl; then
1756
lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
1757
elif test -x /usr/sbin/sysctl; then
1758
lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
1760
lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs
1762
# And add a safety zone
1763
lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
1764
lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
1768
# We know the value 262144 and hardcode it with a safety zone (like BSD)
1769
lt_cv_sys_max_cmd_len=196608
1773
# Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
1774
# due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
1775
# nice to cause kernel panics so lets avoid the loop below.
1776
# First set a reasonable default.
1777
lt_cv_sys_max_cmd_len=16384
1779
if test -x /sbin/sysconfig; then
1780
case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
1781
*1*) lt_cv_sys_max_cmd_len=-1 ;;
1786
lt_cv_sys_max_cmd_len=102400
1788
sysv5* | sco5v6* | sysv4.2uw2*)
1789
kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
1790
if test -n "$kargmax"; then
1791
lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'`
1793
lt_cv_sys_max_cmd_len=32768
1797
lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
1798
if test -n "$lt_cv_sys_max_cmd_len"; then
1799
lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
1800
lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
1802
SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
1803
while (test "X"`$SHELL [$]0 --fallback-echo "X$teststring" 2>/dev/null` \
1804
= "XX$teststring") >/dev/null 2>&1 &&
1805
new_result=`expr "X$teststring" : ".*" 2>&1` &&
1806
lt_cv_sys_max_cmd_len=$new_result &&
1807
test $i != 17 # 1/2 MB should be enough
1810
teststring=$teststring$teststring
1813
# Add a significant safety factor because C++ compilers can tack on massive
1814
# amounts of additional arguments before passing them to the linker.
1815
# It appears as though 1/2 is a usable value.
1816
lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
1821
if test -n $lt_cv_sys_max_cmd_len ; then
1822
AC_MSG_RESULT($lt_cv_sys_max_cmd_len)
1826
])# AC_LIBTOOL_SYS_MAX_CMD_LEN
1829
# _LT_AC_CHECK_DLFCN
1830
# ------------------
1831
AC_DEFUN([_LT_AC_CHECK_DLFCN],
1832
[AC_CHECK_HEADERS(dlfcn.h)dnl
1833
])# _LT_AC_CHECK_DLFCN
1836
# _LT_AC_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE,
1837
# ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING)
1838
# ---------------------------------------------------------------------
1839
AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF],
1840
[AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl
1841
if test "$cross_compiling" = yes; then :
1844
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
1845
lt_status=$lt_dlunknown
1846
cat > conftest.$ac_ext <<EOF
1847
[#line __oline__ "configure"
1848
#include "confdefs.h"
1857
# define LT_DLGLOBAL RTLD_GLOBAL
1860
# define LT_DLGLOBAL DL_GLOBAL
1862
# define LT_DLGLOBAL 0
1866
/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
1867
find out it does not work in some platform. */
1868
#ifndef LT_DLLAZY_OR_NOW
1870
# define LT_DLLAZY_OR_NOW RTLD_LAZY
1873
# define LT_DLLAZY_OR_NOW DL_LAZY
1876
# define LT_DLLAZY_OR_NOW RTLD_NOW
1879
# define LT_DLLAZY_OR_NOW DL_NOW
1881
# define LT_DLLAZY_OR_NOW 0
1889
extern "C" void exit (int);
1892
void fnord() { int i=42;}
1895
void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
1896
int status = $lt_dlunknown;
1900
if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
1901
else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
1902
/* dlclose (self); */
1910
if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then
1911
(./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null
1914
x$lt_dlno_uscore) $1 ;;
1915
x$lt_dlneed_uscore) $2 ;;
1916
x$lt_dlunknown|x*) $3 ;;
1919
# compilation failed
1924
])# _LT_AC_TRY_DLOPEN_SELF
1927
# AC_LIBTOOL_DLOPEN_SELF
1928
# ----------------------
1929
AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF],
1930
[AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl
1931
if test "x$enable_dlopen" != xyes; then
1932
enable_dlopen=unknown
1933
enable_dlopen_self=unknown
1934
enable_dlopen_self_static=unknown
1941
lt_cv_dlopen="load_add_on"
1943
lt_cv_dlopen_self=yes
1947
lt_cv_dlopen="LoadLibrary"
1952
lt_cv_dlopen="dlopen"
1957
# if libdl is installed we need to link against it
1958
AC_CHECK_LIB([dl], [dlopen],
1959
[lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[
1962
lt_cv_dlopen_self=yes
1967
AC_CHECK_FUNC([shl_load],
1968
[lt_cv_dlopen="shl_load"],
1969
[AC_CHECK_LIB([dld], [shl_load],
1970
[lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"],
1971
[AC_CHECK_FUNC([dlopen],
1972
[lt_cv_dlopen="dlopen"],
1973
[AC_CHECK_LIB([dl], [dlopen],
1974
[lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],
1975
[AC_CHECK_LIB([svld], [dlopen],
1976
[lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"],
1977
[AC_CHECK_LIB([dld], [dld_link],
1978
[lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"])
1987
if test "x$lt_cv_dlopen" != xno; then
1993
case $lt_cv_dlopen in
1995
save_CPPFLAGS="$CPPFLAGS"
1996
test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
1998
save_LDFLAGS="$LDFLAGS"
1999
wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
2002
LIBS="$lt_cv_dlopen_libs $LIBS"
2004
AC_CACHE_CHECK([whether a program can dlopen itself],
2005
lt_cv_dlopen_self, [dnl
2006
_LT_AC_TRY_DLOPEN_SELF(
2007
lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes,
2008
lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross)
2011
if test "x$lt_cv_dlopen_self" = xyes; then
2012
wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
2013
AC_CACHE_CHECK([whether a statically linked program can dlopen itself],
2014
lt_cv_dlopen_self_static, [dnl
2015
_LT_AC_TRY_DLOPEN_SELF(
2016
lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes,
2017
lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross)
2021
CPPFLAGS="$save_CPPFLAGS"
2022
LDFLAGS="$save_LDFLAGS"
2027
case $lt_cv_dlopen_self in
2028
yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
2029
*) enable_dlopen_self=unknown ;;
2032
case $lt_cv_dlopen_self_static in
2033
yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
2034
*) enable_dlopen_self_static=unknown ;;
2037
])# AC_LIBTOOL_DLOPEN_SELF
2040
# AC_LIBTOOL_PROG_CC_C_O([TAGNAME])
2041
# ---------------------------------
2042
# Check to see if options -c and -o are simultaneously supported by compiler
2043
AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O],
2044
[AC_REQUIRE([LT_AC_PROG_SED])dnl
2045
AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl
2046
AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext],
2047
[_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)],
2048
[_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no
2049
$rm -r conftest 2>/dev/null
2053
echo "$lt_simple_compile_test_code" > conftest.$ac_ext
2055
lt_compiler_flag="-o out/conftest2.$ac_objext"
2056
# Insert the option either (1) after the last *FLAGS variable, or
2057
# (2) before a word containing "conftest.", or (3) at the end.
2058
# Note that $ac_compile itself does not contain backslashes and begins
2059
# with a dollar sign (not a hyphen), so the echo should work correctly.
2060
lt_compile=`echo "$ac_compile" | $SED \
2061
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
2062
-e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
2063
-e 's:$: $lt_compiler_flag:'`
2064
(eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
2065
(eval "$lt_compile" 2>out/conftest.err)
2067
cat out/conftest.err >&AS_MESSAGE_LOG_FD
2068
echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
2069
if (exit $ac_status) && test -s out/conftest2.$ac_objext
2071
# The compiler can only warn and ignore the option if not recognized
2072
# So say no if there are warnings
2073
$echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp
2074
$SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
2075
if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
2076
_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
2079
chmod u+w . 2>&AS_MESSAGE_LOG_FD
2081
# SGI C++ compiler will create directory out/ii_files/ for
2082
# template instantiation
2083
test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files
2084
$rm out/* && rmdir out
2089
])# AC_LIBTOOL_PROG_CC_C_O
2092
# AC_LIBTOOL_SYS_HARD_LINK_LOCKS([TAGNAME])
2093
# -----------------------------------------
2094
# Check to see if we can do hard links to lock some files if needed
2095
AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS],
2096
[AC_REQUIRE([_LT_AC_LOCK])dnl
2098
hard_links="nottested"
2099
if test "$_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then
2100
# do not overwrite the value of need_locks provided by the user
2101
AC_MSG_CHECKING([if we can lock with hard links])
2104
ln conftest.a conftest.b 2>/dev/null && hard_links=no
2106
ln conftest.a conftest.b 2>&5 || hard_links=no
2107
ln conftest.a conftest.b 2>/dev/null && hard_links=no
2108
AC_MSG_RESULT([$hard_links])
2109
if test "$hard_links" = no; then
2110
AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe])
2116
])# AC_LIBTOOL_SYS_HARD_LINK_LOCKS
2121
AC_DEFUN([AC_LIBTOOL_OBJDIR],
2122
[AC_CACHE_CHECK([for objdir], [lt_cv_objdir],
2123
[rm -f .libs 2>/dev/null
2124
mkdir .libs 2>/dev/null
2125
if test -d .libs; then
2128
# MS-DOS does not allow filenames that begin with a dot.
2131
rmdir .libs 2>/dev/null])
2132
objdir=$lt_cv_objdir
2133
])# AC_LIBTOOL_OBJDIR
2136
# AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH([TAGNAME])
2137
# ----------------------------------------------
2138
# Check hardcoding attributes.
2139
AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH],
2140
[AC_MSG_CHECKING([how to hardcode library paths into programs])
2141
_LT_AC_TAGVAR(hardcode_action, $1)=
2142
if test -n "$_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)" || \
2143
test -n "$_LT_AC_TAGVAR(runpath_var, $1)" || \
2144
test "X$_LT_AC_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then
2146
# We can hardcode non-existant directories.
2147
if test "$_LT_AC_TAGVAR(hardcode_direct, $1)" != no &&
2148
# If the only mechanism to avoid hardcoding is shlibpath_var, we
2149
# have to relink, otherwise we might link with an installed library
2150
# when we should be linking with a yet-to-be-installed one
2151
## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)" != no &&
2152
test "$_LT_AC_TAGVAR(hardcode_minus_L, $1)" != no; then
2153
# Linking always hardcodes the temporary library directory.
2154
_LT_AC_TAGVAR(hardcode_action, $1)=relink
2156
# We can link without hardcoding, and we can hardcode nonexisting dirs.
2157
_LT_AC_TAGVAR(hardcode_action, $1)=immediate
2160
# We cannot hardcode anything, or else we can only hardcode existing
2162
_LT_AC_TAGVAR(hardcode_action, $1)=unsupported
2164
AC_MSG_RESULT([$_LT_AC_TAGVAR(hardcode_action, $1)])
2166
if test "$_LT_AC_TAGVAR(hardcode_action, $1)" = relink; then
2167
# Fast installation is not supported
2168
enable_fast_install=no
2169
elif test "$shlibpath_overrides_runpath" = yes ||
2170
test "$enable_shared" = no; then
2171
# Fast installation is not necessary
2172
enable_fast_install=needless
2174
])# AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH
2177
# AC_LIBTOOL_SYS_LIB_STRIP
2178
# ------------------------
2179
AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP],
2182
AC_MSG_CHECKING([whether stripping libraries is possible])
2183
if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then
2184
test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
2185
test -z "$striplib" && striplib="$STRIP --strip-unneeded"
2186
AC_MSG_RESULT([yes])
2188
# FIXME - insert some real tests, host_os isn't really good enough
2191
if test -n "$STRIP" ; then
2192
striplib="$STRIP -x"
2193
old_striplib="$STRIP -S"
2194
AC_MSG_RESULT([yes])
2204
])# AC_LIBTOOL_SYS_LIB_STRIP
2207
# AC_LIBTOOL_SYS_DYNAMIC_LINKER
2208
# -----------------------------
2209
# PORTME Fill in your ld.so characteristics
2210
AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER],
2211
[AC_REQUIRE([LT_AC_PROG_SED])dnl
2212
AC_MSG_CHECKING([dynamic linker characteristics])
2214
libname_spec='lib$name'
2222
shlibpath_overrides_runpath=unknown
2224
dynamic_linker="$host_os ld.so"
2225
sys_lib_dlsearch_path_spec="/lib /usr/lib"
2227
if test "$GCC" = yes; then
2229
darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
2230
*) lt_awk_arg="/^libraries:/" ;;
2232
lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e "s,=/,/,g"`
2233
if echo "$lt_search_path_spec" | grep ';' >/dev/null ; then
2234
# if the path contains ";" then we assume it to be the separator
2235
# otherwise default to the standard path separator (i.e. ":") - it is
2236
# assumed that no part of a normal pathname contains ";" but that should
2237
# okay in the real world where ";" in dirpaths is itself problematic.
2238
lt_search_path_spec=`echo "$lt_search_path_spec" | $SED -e 's/;/ /g'`
2240
lt_search_path_spec=`echo "$lt_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
2242
# Ok, now we have the path, separated by spaces, we can step through it
2243
# and add multilib dir if necessary.
2244
lt_tmp_lt_search_path_spec=
2245
lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
2246
for lt_sys_path in $lt_search_path_spec; do
2247
if test -d "$lt_sys_path/$lt_multi_os_dir"; then
2248
lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
2250
test -d "$lt_sys_path" && \
2251
lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
2254
lt_search_path_spec=`echo $lt_tmp_lt_search_path_spec | awk '
2255
BEGIN {RS=" "; FS="/|\n";} {
2258
for (lt_i = NF; lt_i > 0; lt_i--) {
2259
if ($lt_i != "" && $lt_i != ".") {
2260
if ($lt_i == "..") {
2263
if (lt_count == 0) {
2264
lt_foo="/" $lt_i lt_foo;
2271
if (lt_foo != "") { lt_freq[[lt_foo]]++; }
2272
if (lt_freq[[lt_foo]] == 1) { print lt_foo; }
2274
sys_lib_search_path_spec=`echo $lt_search_path_spec`
2276
sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
2278
need_lib_prefix=unknown
2279
hardcode_into_libs=no
2281
# when you set need_version to no, make sure it does not cause -set_version
2282
# flags to be left without arguments
2283
need_version=unknown
2288
library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
2289
shlibpath_var=LIBPATH
2291
# AIX 3 has no versioning support, so we append a major version to the name.
2292
soname_spec='${libname}${release}${shared_ext}$major'
2299
hardcode_into_libs=yes
2300
if test "$host_cpu" = ia64; then
2301
# AIX 5 supports IA64
2302
library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
2303
shlibpath_var=LD_LIBRARY_PATH
2305
# With GCC up to 2.95.x, collect2 would create an import file
2306
# for dependence libraries. The import file would start with
2307
# the line `#! .'. This would cause the generated library to
2308
# depend on `.', always an invalid library. This was fixed in
2309
# development snapshots of GCC prior to 3.0.
2311
aix4 | aix4.[[01]] | aix4.[[01]].*)
2312
if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
2314
echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then
2321
# AIX (on Power*) has no versioning support, so currently we can not hardcode correct
2322
# soname into executable. Probably we can add versioning support to
2323
# collect2, so additional links can be useful in future.
2324
if test "$aix_use_runtimelinking" = yes; then
2325
# If using run time linking (on AIX 4.2 or later) use lib<name>.so
2326
# instead of lib<name>.a to let people know that these are not
2327
# typical AIX shared libraries.
2328
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2330
# We preserve .a as extension for shared libraries through AIX4.2
2331
# and later when we are not doing run time linking.
2332
library_names_spec='${libname}${release}.a $libname.a'
2333
soname_spec='${libname}${release}${shared_ext}$major'
2335
shlibpath_var=LIBPATH
2340
library_names_spec='$libname.ixlibrary $libname.a'
2341
# Create ${libname}_ixlibrary.a entries in /sys/libs.
2342
finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
2346
library_names_spec='${libname}${shared_ext}'
2347
dynamic_linker="$host_os ld.so"
2348
shlibpath_var=LIBRARY_PATH
2354
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2355
soname_spec='${libname}${release}${shared_ext}$major'
2356
finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
2357
shlibpath_var=LD_LIBRARY_PATH
2358
sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
2359
sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
2360
# the default ld.so.conf also contains /usr/contrib/lib and
2361
# /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
2362
# libtool to hard-code these into programs
2365
cygwin* | mingw* | pw32*)
2366
version_type=windows
2371
case $GCC,$host_os in
2372
yes,cygwin* | yes,mingw* | yes,pw32*)
2373
library_names_spec='$libname.dll.a'
2374
# DLL is installed to $(libdir)/../bin by postinstall_cmds
2375
postinstall_cmds='base_file=`basename \${file}`~
2376
dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~
2377
dldir=$destdir/`dirname \$dlpath`~
2378
test -d \$dldir || mkdir -p \$dldir~
2379
$install_prog $dir/$dlname \$dldir/$dlname~
2380
chmod a+x \$dldir/$dlname'
2381
postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
2382
dlpath=$dir/\$dldll~
2384
shlibpath_overrides_runpath=yes
2388
# Cygwin DLLs use 'cyg' prefix rather than 'lib'
2389
soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
2390
sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
2393
# MinGW DLLs use traditional 'lib' prefix
2394
soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
2395
sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
2396
if echo "$sys_lib_search_path_spec" | [grep ';[c-zC-Z]:/' >/dev/null]; then
2397
# It is most probably a Windows format PATH printed by
2398
# mingw gcc, but we are running on Cygwin. Gcc prints its search
2399
# path with ; separators, and with drive letters. We can handle the
2400
# drive letters (cygwin fileutils understands them), so leave them,
2401
# especially as we might pass files found there to a mingw objdump,
2402
# which wouldn't understand a cygwinified path. Ahh.
2403
sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
2405
sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
2409
# pw32 DLLs use 'pw' prefix rather than 'lib'
2410
library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
2416
library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib'
2419
dynamic_linker='Win32 ld.exe'
2420
# FIXME: first we should search . and the directory the executable is in
2424
darwin* | rhapsody*)
2425
dynamic_linker="$host_os dyld"
2429
library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext'
2430
soname_spec='${libname}${release}${major}$shared_ext'
2431
shlibpath_overrides_runpath=yes
2432
shlibpath_var=DYLD_LIBRARY_PATH
2433
shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
2435
sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"])
2436
sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
2443
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
2444
soname_spec='${libname}${release}${shared_ext}$major'
2445
shlibpath_var=LD_LIBRARY_PATH
2452
freebsd* | dragonfly*)
2453
# DragonFly does not have aout. When/if they implement a new
2454
# versioning mechanism, adjust this.
2455
if test -x /usr/bin/objformat; then
2456
objformat=`/usr/bin/objformat`
2459
freebsd[[123]]*) objformat=aout ;;
2463
version_type=freebsd-$objformat
2464
case $version_type in
2466
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
2471
library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
2475
shlibpath_var=LD_LIBRARY_PATH
2478
shlibpath_overrides_runpath=yes
2480
freebsd3.[[01]]* | freebsdelf3.[[01]]*)
2481
shlibpath_overrides_runpath=yes
2482
hardcode_into_libs=yes
2484
freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \
2485
freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1)
2486
shlibpath_overrides_runpath=no
2487
hardcode_into_libs=yes
2489
*) # from 4.6 on, and DragonFly
2490
shlibpath_overrides_runpath=yes
2491
hardcode_into_libs=yes
2500
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
2501
soname_spec='${libname}${release}${shared_ext}$major'
2502
shlibpath_var=LD_LIBRARY_PATH
2503
hardcode_into_libs=yes
2506
hpux9* | hpux10* | hpux11*)
2507
# Give a soname corresponding to the major version so that dld.sl refuses to
2508
# link against other versions.
2515
hardcode_into_libs=yes
2516
dynamic_linker="$host_os dld.so"
2517
shlibpath_var=LD_LIBRARY_PATH
2518
shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
2519
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2520
soname_spec='${libname}${release}${shared_ext}$major'
2521
if test "X$HPUX_IA64_MODE" = X32; then
2522
sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
2524
sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
2526
sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
2530
hardcode_into_libs=yes
2531
dynamic_linker="$host_os dld.sl"
2532
shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
2533
shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
2534
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2535
soname_spec='${libname}${release}${shared_ext}$major'
2536
sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
2537
sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
2541
dynamic_linker="$host_os dld.sl"
2542
shlibpath_var=SHLIB_PATH
2543
shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
2544
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2545
soname_spec='${libname}${release}${shared_ext}$major'
2548
# HP-UX runs *really* slowly unless shared libraries are mode 555.
2549
postinstall_cmds='chmod 555 $lib'
2556
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
2557
soname_spec='${libname}${release}${shared_ext}$major'
2558
dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
2559
shlibpath_var=LD_LIBRARY_PATH
2560
shlibpath_overrides_runpath=no
2561
hardcode_into_libs=yes
2564
irix5* | irix6* | nonstopux*)
2566
nonstopux*) version_type=nonstopux ;;
2568
if test "$lt_cv_prog_gnu_ld" = yes; then
2576
soname_spec='${libname}${release}${shared_ext}$major'
2577
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
2579
irix5* | nonstopux*)
2583
case $LD in # libtool.m4 will add one of these switches to LD
2584
*-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
2585
libsuff= shlibsuff= libmagic=32-bit;;
2586
*-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
2587
libsuff=32 shlibsuff=N32 libmagic=N32;;
2588
*-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
2589
libsuff=64 shlibsuff=64 libmagic=64-bit;;
2590
*) libsuff= shlibsuff= libmagic=never-match;;
2594
shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
2595
shlibpath_overrides_runpath=no
2596
sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
2597
sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
2598
hardcode_into_libs=yes
2601
# No shared lib support for Linux oldld, aout, or coff.
2602
linux*oldld* | linux*aout* | linux*coff*)
2606
# This must be Linux ELF.
2607
linux* | k*bsd*-gnu)
2611
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2612
soname_spec='${libname}${release}${shared_ext}$major'
2613
finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
2614
shlibpath_var=LD_LIBRARY_PATH
2615
shlibpath_overrides_runpath=no
2616
# This implies no fast_install, which is unacceptable.
2617
# Some rework will be needed to allow for fast_install
2618
# before this can be enabled.
2619
hardcode_into_libs=yes
2621
# Append ld.so.conf contents to the search path
2622
if test -f /etc/ld.so.conf; then
2623
lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '`
2624
sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
2627
# We used to test for /lib/ld.so.1 and disable shared libraries on
2628
# powerpc, because MkLinux only supported shared libraries with the
2629
# GNU dynamic linker. Since this was broken with cross compilers,
2630
# most powerpc-linux boxes support dynamic linking these days and
2631
# people can always --disable-shared, the test was removed, and we
2632
# assume the GNU/Linux dynamic linker is in use.
2633
dynamic_linker='GNU/Linux ld.so'
2640
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
2641
soname_spec='${libname}${release}${shared_ext}$major'
2642
shlibpath_var=LD_LIBRARY_PATH
2643
shlibpath_overrides_runpath=no
2644
hardcode_into_libs=yes
2645
dynamic_linker='NetBSD ld.elf_so'
2652
if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
2653
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
2654
finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
2655
dynamic_linker='NetBSD (a.out) ld.so'
2657
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
2658
soname_spec='${libname}${release}${shared_ext}$major'
2659
dynamic_linker='NetBSD ld.elf_so'
2661
shlibpath_var=LD_LIBRARY_PATH
2662
shlibpath_overrides_runpath=yes
2663
hardcode_into_libs=yes
2668
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2669
shlibpath_var=LD_LIBRARY_PATH
2670
shlibpath_overrides_runpath=yes
2677
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2678
soname_spec='${libname}${release}${shared_ext}$major'
2679
shlibpath_var=LD_LIBRARY_PATH
2680
shlibpath_overrides_runpath=yes
2685
sys_lib_dlsearch_path_spec="/usr/lib"
2687
# Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
2689
openbsd3.3 | openbsd3.3.*) need_version=yes ;;
2690
*) need_version=no ;;
2692
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
2693
finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
2694
shlibpath_var=LD_LIBRARY_PATH
2695
if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
2697
openbsd2.[[89]] | openbsd2.[[89]].*)
2698
shlibpath_overrides_runpath=no
2701
shlibpath_overrides_runpath=yes
2705
shlibpath_overrides_runpath=yes
2710
libname_spec='$name'
2713
library_names_spec='$libname${shared_ext} $libname.a'
2714
dynamic_linker='OS/2 ld.exe'
2715
shlibpath_var=LIBPATH
2718
osf3* | osf4* | osf5*)
2722
soname_spec='${libname}${release}${shared_ext}$major'
2723
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2724
shlibpath_var=LD_LIBRARY_PATH
2725
sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
2726
sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
2737
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2738
soname_spec='${libname}${release}${shared_ext}$major'
2739
shlibpath_var=LD_LIBRARY_PATH
2740
shlibpath_overrides_runpath=yes
2741
hardcode_into_libs=yes
2742
# ldd complains unless libraries are executable
2743
postinstall_cmds='chmod +x $lib'
2748
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
2749
finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
2750
shlibpath_var=LD_LIBRARY_PATH
2751
shlibpath_overrides_runpath=yes
2752
if test "$with_gnu_ld" = yes; then
2760
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2761
soname_spec='${libname}${release}${shared_ext}$major'
2762
shlibpath_var=LD_LIBRARY_PATH
2763
case $host_vendor in
2765
shlibpath_overrides_runpath=no
2767
export_dynamic_flag_spec='${wl}-Blargedynsym'
2768
runpath_var=LD_RUN_PATH
2776
shlibpath_overrides_runpath=no
2777
sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
2783
if test -d /usr/nec ;then
2785
library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
2786
soname_spec='$libname${shared_ext}.$major'
2787
shlibpath_var=LD_LIBRARY_PATH
2791
sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
2792
version_type=freebsd-elf
2795
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
2796
soname_spec='${libname}${release}${shared_ext}$major'
2797
shlibpath_var=LD_LIBRARY_PATH
2798
hardcode_into_libs=yes
2799
if test "$with_gnu_ld" = yes; then
2800
sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
2801
shlibpath_overrides_runpath=no
2803
sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
2804
shlibpath_overrides_runpath=yes
2807
sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
2811
sys_lib_dlsearch_path_spec='/usr/lib'
2816
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2817
soname_spec='${libname}${release}${shared_ext}$major'
2818
shlibpath_var=LD_LIBRARY_PATH
2825
AC_MSG_RESULT([$dynamic_linker])
2826
test "$dynamic_linker" = no && can_build_shared=no
2828
AC_CACHE_VAL([lt_cv_sys_lib_search_path_spec],
2829
[lt_cv_sys_lib_search_path_spec="$sys_lib_search_path_spec"])
2830
sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
2831
AC_CACHE_VAL([lt_cv_sys_lib_dlsearch_path_spec],
2832
[lt_cv_sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec"])
2833
sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
2835
variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
2836
if test "$GCC" = yes; then
2837
variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
2839
])# AC_LIBTOOL_SYS_DYNAMIC_LINKER
2844
AC_DEFUN([_LT_AC_TAGCONFIG],
2845
[AC_REQUIRE([LT_AC_PROG_SED])dnl
2847
[AC_HELP_STRING([--with-tags@<:@=TAGS@:>@],
2848
[include additional configurations @<:@automatic@:>@])],
2849
[tagnames="$withval"])
2851
if test -f "$ltmain" && test -n "$tagnames"; then
2852
if test ! -f "${ofile}"; then
2853
AC_MSG_WARN([output file `$ofile' does not exist])
2856
if test -z "$LTCC"; then
2857
eval "`$SHELL ${ofile} --config | grep '^LTCC='`"
2858
if test -z "$LTCC"; then
2859
AC_MSG_WARN([output file `$ofile' does not look like a libtool script])
2861
AC_MSG_WARN([using `LTCC=$LTCC', extracted from `$ofile'])
2864
if test -z "$LTCFLAGS"; then
2865
eval "`$SHELL ${ofile} --config | grep '^LTCFLAGS='`"
2868
# Extract list of available tagged configurations in $ofile.
2869
# Note that this assumes the entire list is on one line.
2870
available_tags=`grep "^available_tags=" "${ofile}" | $SED -e 's/available_tags=\(.*$\)/\1/' -e 's/\"//g'`
2872
lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
2873
for tagname in $tagnames; do
2875
# Check whether tagname contains only valid characters
2876
case `$echo "X$tagname" | $Xsed -e 's:[[-_ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890,/]]::g'` in
2878
*) AC_MSG_ERROR([invalid tag name: $tagname])
2882
if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$" < "${ofile}" > /dev/null
2884
AC_MSG_ERROR([tag name \"$tagname\" already exists])
2887
# Update the list of available tags.
2888
if test -n "$tagname"; then
2889
echo appending configuration tag \"$tagname\" to $ofile
2893
if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
2894
( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
2895
(test "X$CXX" != "Xg++"))) ; then
2896
AC_LIBTOOL_LANG_CXX_CONFIG
2903
if test -n "$F77" && test "X$F77" != "Xno"; then
2904
AC_LIBTOOL_LANG_F77_CONFIG
2911
if test -n "$GCJ" && test "X$GCJ" != "Xno"; then
2912
AC_LIBTOOL_LANG_GCJ_CONFIG
2919
AC_LIBTOOL_LANG_RC_CONFIG
2923
AC_MSG_ERROR([Unsupported tag name: $tagname])
2927
# Append the new tag name to the list of available tags.
2928
if test -n "$tagname" ; then
2929
available_tags="$available_tags $tagname"
2935
# Now substitute the updated list of available tags.
2936
if eval "sed -e 's/^available_tags=.*\$/available_tags=\"$available_tags\"/' \"$ofile\" > \"${ofile}T\""; then
2937
mv "${ofile}T" "$ofile"
2941
AC_MSG_ERROR([unable to update list of available tagged configurations.])
2944
])# _LT_AC_TAGCONFIG
2949
# enable checks for dlopen support
2950
AC_DEFUN([AC_LIBTOOL_DLOPEN],
2951
[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])
2952
])# AC_LIBTOOL_DLOPEN
2955
# AC_LIBTOOL_WIN32_DLL
2956
# --------------------
2957
# declare package support for building win32 DLLs
2958
AC_DEFUN([AC_LIBTOOL_WIN32_DLL],
2959
[AC_BEFORE([$0], [AC_LIBTOOL_SETUP])
2960
])# AC_LIBTOOL_WIN32_DLL
2963
# AC_ENABLE_SHARED([DEFAULT])
2964
# ---------------------------
2965
# implement the --enable-shared flag
2966
# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
2967
AC_DEFUN([AC_ENABLE_SHARED],
2968
[define([AC_ENABLE_SHARED_DEFAULT], ifelse($1, no, no, yes))dnl
2969
AC_ARG_ENABLE([shared],
2970
[AC_HELP_STRING([--enable-shared@<:@=PKGS@:>@],
2971
[build shared libraries @<:@default=]AC_ENABLE_SHARED_DEFAULT[@:>@])],
2972
[p=${PACKAGE-default}
2974
yes) enable_shared=yes ;;
2975
no) enable_shared=no ;;
2978
# Look at the argument we got. We use all the common list separators.
2979
lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
2980
for pkg in $enableval; do
2982
if test "X$pkg" = "X$p"; then
2989
[enable_shared=]AC_ENABLE_SHARED_DEFAULT)
2990
])# AC_ENABLE_SHARED
2995
# set the default shared flag to --disable-shared
2996
AC_DEFUN([AC_DISABLE_SHARED],
2997
[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
2998
AC_ENABLE_SHARED(no)
2999
])# AC_DISABLE_SHARED
3002
# AC_ENABLE_STATIC([DEFAULT])
3003
# ---------------------------
3004
# implement the --enable-static flag
3005
# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
3006
AC_DEFUN([AC_ENABLE_STATIC],
3007
[define([AC_ENABLE_STATIC_DEFAULT], ifelse($1, no, no, yes))dnl
3008
AC_ARG_ENABLE([static],
3009
[AC_HELP_STRING([--enable-static@<:@=PKGS@:>@],
3010
[build static libraries @<:@default=]AC_ENABLE_STATIC_DEFAULT[@:>@])],
3011
[p=${PACKAGE-default}
3013
yes) enable_static=yes ;;
3014
no) enable_static=no ;;
3017
# Look at the argument we got. We use all the common list separators.
3018
lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
3019
for pkg in $enableval; do
3021
if test "X$pkg" = "X$p"; then
3028
[enable_static=]AC_ENABLE_STATIC_DEFAULT)
3029
])# AC_ENABLE_STATIC
3034
# set the default static flag to --disable-static
3035
AC_DEFUN([AC_DISABLE_STATIC],
3036
[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
3037
AC_ENABLE_STATIC(no)
3038
])# AC_DISABLE_STATIC
3041
# AC_ENABLE_FAST_INSTALL([DEFAULT])
3042
# ---------------------------------
3043
# implement the --enable-fast-install flag
3044
# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
3045
AC_DEFUN([AC_ENABLE_FAST_INSTALL],
3046
[define([AC_ENABLE_FAST_INSTALL_DEFAULT], ifelse($1, no, no, yes))dnl
3047
AC_ARG_ENABLE([fast-install],
3048
[AC_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@],
3049
[optimize for fast installation @<:@default=]AC_ENABLE_FAST_INSTALL_DEFAULT[@:>@])],
3050
[p=${PACKAGE-default}
3052
yes) enable_fast_install=yes ;;
3053
no) enable_fast_install=no ;;
3055
enable_fast_install=no
3056
# Look at the argument we got. We use all the common list separators.
3057
lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
3058
for pkg in $enableval; do
3060
if test "X$pkg" = "X$p"; then
3061
enable_fast_install=yes
3067
[enable_fast_install=]AC_ENABLE_FAST_INSTALL_DEFAULT)
3068
])# AC_ENABLE_FAST_INSTALL
3071
# AC_DISABLE_FAST_INSTALL
3072
# -----------------------
3073
# set the default to --disable-fast-install
3074
AC_DEFUN([AC_DISABLE_FAST_INSTALL],
3075
[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
3076
AC_ENABLE_FAST_INSTALL(no)
3077
])# AC_DISABLE_FAST_INSTALL
3080
# AC_LIBTOOL_PICMODE([MODE])
3081
# --------------------------
3082
# implement the --with-pic flag
3083
# MODE is either `yes' or `no'. If omitted, it defaults to `both'.
3084
AC_DEFUN([AC_LIBTOOL_PICMODE],
3085
[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
3086
pic_mode=ifelse($#,1,$1,default)
3087
])# AC_LIBTOOL_PICMODE
3092
# This is predefined starting with Autoconf 2.54, so this conditional
3093
# definition can be removed once we require Autoconf 2.54 or later.
3094
m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP],
3095
[AC_CACHE_CHECK([for egrep], [ac_cv_prog_egrep],
3096
[if echo a | (grep -E '(a|b)') >/dev/null 2>&1
3097
then ac_cv_prog_egrep='grep -E'
3098
else ac_cv_prog_egrep='egrep'
3100
EGREP=$ac_cv_prog_egrep
3105
# AC_PATH_TOOL_PREFIX
3106
# -------------------
3107
# find a file program which can recognize shared library
3108
AC_DEFUN([AC_PATH_TOOL_PREFIX],
3109
[AC_REQUIRE([AC_PROG_EGREP])dnl
3110
AC_MSG_CHECKING([for $1])
3111
AC_CACHE_VAL(lt_cv_path_MAGIC_CMD,
3113
[[\\/*] | ?:[\\/]*])
3114
lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
3117
lt_save_MAGIC_CMD="$MAGIC_CMD"
3118
lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
3119
dnl $ac_dummy forces splitting on constant user-supplied paths.
3120
dnl POSIX.2 word splitting is done only on the output of word expansions,
3121
dnl not every word. This closes a longstanding sh security hole.
3122
ac_dummy="ifelse([$2], , $PATH, [$2])"
3123
for ac_dir in $ac_dummy; do
3125
test -z "$ac_dir" && ac_dir=.
3126
if test -f $ac_dir/$1; then
3127
lt_cv_path_MAGIC_CMD="$ac_dir/$1"
3128
if test -n "$file_magic_test_file"; then
3129
case $deplibs_check_method in
3131
file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
3132
MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
3133
if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
3134
$EGREP "$file_magic_regex" > /dev/null; then
3139
*** Warning: the command libtool uses to detect shared libraries,
3140
*** $file_magic_cmd, produces output that libtool cannot recognize.
3141
*** The result is that libtool may fail to recognize shared libraries
3142
*** as such. This will affect the creation of libtool libraries that
3143
*** depend on shared libraries, but programs linked with such libtool
3144
*** libraries will work regardless of this problem. Nevertheless, you
3145
*** may want to report the problem to your system manager and/or to
3146
*** bug-libtool@gnu.org
3156
MAGIC_CMD="$lt_save_MAGIC_CMD"
3159
MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
3160
if test -n "$MAGIC_CMD"; then
3161
AC_MSG_RESULT($MAGIC_CMD)
3165
])# AC_PATH_TOOL_PREFIX
3170
# find a file program which can recognize a shared library
3171
AC_DEFUN([AC_PATH_MAGIC],
3172
[AC_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH)
3173
if test -z "$lt_cv_path_MAGIC_CMD"; then
3174
if test -n "$ac_tool_prefix"; then
3175
AC_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH)
3185
# find the pathname to the GNU or non-GNU linker
3186
AC_DEFUN([AC_PROG_LD],
3187
[AC_ARG_WITH([gnu-ld],
3188
[AC_HELP_STRING([--with-gnu-ld],
3189
[assume the C compiler uses GNU ld @<:@default=no@:>@])],
3190
[test "$withval" = no || with_gnu_ld=yes],
3192
AC_REQUIRE([LT_AC_PROG_SED])dnl
3193
AC_REQUIRE([AC_PROG_CC])dnl
3194
AC_REQUIRE([AC_CANONICAL_HOST])dnl
3195
AC_REQUIRE([AC_CANONICAL_BUILD])dnl
3197
if test "$GCC" = yes; then
3198
# Check if gcc -print-prog-name=ld gives a path.
3199
AC_MSG_CHECKING([for ld used by $CC])
3202
# gcc leaves a trailing carriage return which upsets mingw
3203
ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
3205
ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
3208
# Accept absolute paths.
3209
[[\\/]]* | ?:[[\\/]]*)
3210
re_direlt='/[[^/]][[^/]]*/\.\./'
3211
# Canonicalize the pathname of ld
3212
ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'`
3213
while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
3214
ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"`
3216
test -z "$LD" && LD="$ac_prog"
3219
# If it fails, then pretend we aren't using GCC.
3223
# If it is relative, then search for the first ld in PATH.
3227
elif test "$with_gnu_ld" = yes; then
3228
AC_MSG_CHECKING([for GNU ld])
3230
AC_MSG_CHECKING([for non-GNU ld])
3232
AC_CACHE_VAL(lt_cv_path_LD,
3233
[if test -z "$LD"; then
3234
lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
3235
for ac_dir in $PATH; do
3237
test -z "$ac_dir" && ac_dir=.
3238
if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
3239
lt_cv_path_LD="$ac_dir/$ac_prog"
3240
# Check to see if the program is GNU ld. I'd rather use --version,
3241
# but apparently some variants of GNU ld only accept -v.
3242
# Break only if it was the GNU/non-GNU ld that we prefer.
3243
case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
3244
*GNU* | *'with BFD'*)
3245
test "$with_gnu_ld" != no && break
3248
test "$with_gnu_ld" != yes && break
3255
lt_cv_path_LD="$LD" # Let the user override the test with a path.
3258
if test -n "$LD"; then
3263
test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH])
3270
AC_DEFUN([AC_PROG_LD_GNU],
3271
[AC_REQUIRE([AC_PROG_EGREP])dnl
3272
AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld,
3273
[# I'd rather use --version here, but apparently some GNU lds only accept -v.
3274
case `$LD -v 2>&1 </dev/null` in
3275
*GNU* | *'with BFD'*)
3276
lt_cv_prog_gnu_ld=yes
3279
lt_cv_prog_gnu_ld=no
3282
with_gnu_ld=$lt_cv_prog_gnu_ld
3286
# AC_PROG_LD_RELOAD_FLAG
3287
# ----------------------
3288
# find reload flag for linker
3289
# -- PORTME Some linkers may need a different reload flag.
3290
AC_DEFUN([AC_PROG_LD_RELOAD_FLAG],
3291
[AC_CACHE_CHECK([for $LD option to reload object files],
3292
lt_cv_ld_reload_flag,
3293
[lt_cv_ld_reload_flag='-r'])
3294
reload_flag=$lt_cv_ld_reload_flag
3295
case $reload_flag in
3297
*) reload_flag=" $reload_flag" ;;
3299
reload_cmds='$LD$reload_flag -o $output$reload_objs'
3302
if test "$GCC" = yes; then
3303
reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
3305
reload_cmds='$LD$reload_flag -o $output$reload_objs'
3309
])# AC_PROG_LD_RELOAD_FLAG
3312
# AC_DEPLIBS_CHECK_METHOD
3313
# -----------------------
3314
# how to check for library dependencies
3315
# -- PORTME fill in with the dynamic library characteristics
3316
AC_DEFUN([AC_DEPLIBS_CHECK_METHOD],
3317
[AC_CACHE_CHECK([how to recognize dependent libraries],
3318
lt_cv_deplibs_check_method,
3319
[lt_cv_file_magic_cmd='$MAGIC_CMD'
3320
lt_cv_file_magic_test_file=
3321
lt_cv_deplibs_check_method='unknown'
3322
# Need to set the preceding variable on all platforms that support
3323
# interlibrary dependencies.
3324
# 'none' -- dependencies not supported.
3325
# `unknown' -- same as none, but documents that we really don't know.
3326
# 'pass_all' -- all dependencies passed with no checks.
3327
# 'test_compile' -- check by making test program.
3328
# 'file_magic [[regex]]' -- check by looking for files in library path
3329
# which responds to the $file_magic_cmd with a given extended regex.
3330
# If you have `file' or equivalent on your system and you're not sure
3331
# whether `pass_all' will *always* work, you probably want this one.
3335
lt_cv_deplibs_check_method=pass_all
3339
lt_cv_deplibs_check_method=pass_all
3343
lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)'
3344
lt_cv_file_magic_cmd='/usr/bin/file -L'
3345
lt_cv_file_magic_test_file=/shlib/libc.so
3349
# func_win32_libid is a shell function defined in ltmain.sh
3350
lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
3351
lt_cv_file_magic_cmd='func_win32_libid'
3355
# Base MSYS/MinGW do not provide the 'file' command needed by
3356
# func_win32_libid shell function, so use a weaker test based on 'objdump',
3357
# unless we find 'file', for example because we are cross-compiling.
3358
if ( file / ) >/dev/null 2>&1; then
3359
lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
3360
lt_cv_file_magic_cmd='func_win32_libid'
3362
lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
3363
lt_cv_file_magic_cmd='$OBJDUMP -f'
3367
darwin* | rhapsody*)
3368
lt_cv_deplibs_check_method=pass_all
3371
freebsd* | dragonfly*)
3372
if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
3375
# Not sure whether the presence of OpenBSD here was a mistake.
3376
# Let's accept both of them until this is cleared up.
3377
lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library'
3378
lt_cv_file_magic_cmd=/usr/bin/file
3379
lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
3383
lt_cv_deplibs_check_method=pass_all
3388
lt_cv_deplibs_check_method=pass_all
3391
hpux10.20* | hpux11*)
3392
lt_cv_file_magic_cmd=/usr/bin/file
3395
lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64'
3396
lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
3399
[lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - PA-RISC [0-9].[0-9]']
3400
lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
3403
lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]].[[0-9]]) shared library'
3404
lt_cv_file_magic_test_file=/usr/lib/libc.sl
3410
# PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
3411
lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$'
3414
irix5* | irix6* | nonstopux*)
3416
*-32|*"-32 ") libmagic=32-bit;;
3417
*-n32|*"-n32 ") libmagic=N32;;
3418
*-64|*"-64 ") libmagic=64-bit;;
3419
*) libmagic=never-match;;
3421
lt_cv_deplibs_check_method=pass_all
3424
# This must be Linux ELF.
3425
linux* | k*bsd*-gnu)
3426
lt_cv_deplibs_check_method=pass_all
3429
netbsd* | netbsdelf*-gnu)
3430
if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
3431
lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
3433
lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$'
3438
lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)'
3439
lt_cv_file_magic_cmd=/usr/bin/file
3440
lt_cv_file_magic_test_file=/usr/lib/libnls.so
3444
lt_cv_deplibs_check_method=unknown
3448
if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
3449
lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$'
3451
lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
3455
osf3* | osf4* | osf5*)
3456
lt_cv_deplibs_check_method=pass_all
3460
lt_cv_deplibs_check_method=pass_all
3464
lt_cv_deplibs_check_method=pass_all
3468
case $host_vendor in
3470
lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib) M[[0-9]][[0-9]]* Version [[0-9]]'
3471
lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
3474
lt_cv_deplibs_check_method=pass_all
3477
lt_cv_file_magic_cmd='/bin/file'
3478
lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )'
3481
lt_cv_file_magic_cmd='/bin/file'
3482
lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib"
3483
lt_cv_file_magic_test_file=/lib/libc.so
3486
lt_cv_deplibs_check_method=pass_all
3489
lt_cv_deplibs_check_method=pass_all
3494
sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
3495
lt_cv_deplibs_check_method=pass_all
3499
file_magic_cmd=$lt_cv_file_magic_cmd
3500
deplibs_check_method=$lt_cv_deplibs_check_method
3501
test -z "$deplibs_check_method" && deplibs_check_method=unknown
3502
])# AC_DEPLIBS_CHECK_METHOD
3507
# find the pathname to a BSD-compatible name lister
3508
AC_DEFUN([AC_PROG_NM],
3509
[AC_CACHE_CHECK([for BSD-compatible nm], lt_cv_path_NM,
3510
[if test -n "$NM"; then
3511
# Let the user override the test.
3514
lt_nm_to_check="${ac_tool_prefix}nm"
3515
if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
3516
lt_nm_to_check="$lt_nm_to_check nm"
3518
for lt_tmp_nm in $lt_nm_to_check; do
3519
lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
3520
for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
3522
test -z "$ac_dir" && ac_dir=.
3523
tmp_nm="$ac_dir/$lt_tmp_nm"
3524
if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
3525
# Check to see if the nm accepts a BSD-compat flag.
3526
# Adding the `sed 1q' prevents false positives on HP-UX, which says:
3527
# nm: unknown option "B" ignored
3528
# Tru64's nm complains that /dev/null is an invalid object file
3529
case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
3530
*/dev/null* | *'Invalid file or object type'*)
3531
lt_cv_path_NM="$tmp_nm -B"
3535
case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
3537
lt_cv_path_NM="$tmp_nm -p"
3541
lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
3542
continue # so that we can try to find one that supports BSD flags
3551
test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm
3559
# check for math library
3560
AC_DEFUN([AC_CHECK_LIBM],
3561
[AC_REQUIRE([AC_CANONICAL_HOST])dnl
3564
*-*-beos* | *-*-cygwin* | *-*-pw32* | *-*-darwin*)
3565
# These system don't have libm, or don't need it
3568
AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw")
3569
AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm")
3572
AC_CHECK_LIB(m, cos, LIBM="-lm")
3578
# AC_LIBLTDL_CONVENIENCE([DIRECTORY])
3579
# -----------------------------------
3580
# sets LIBLTDL to the link flags for the libltdl convenience library and
3581
# LTDLINCL to the include flags for the libltdl header and adds
3582
# --enable-ltdl-convenience to the configure arguments. Note that
3583
# AC_CONFIG_SUBDIRS is not called here. If DIRECTORY is not provided,
3584
# it is assumed to be `libltdl'. LIBLTDL will be prefixed with
3585
# '${top_builddir}/' and LTDLINCL will be prefixed with '${top_srcdir}/'
3586
# (note the single quotes!). If your package is not flat and you're not
3587
# using automake, define top_builddir and top_srcdir appropriately in
3589
AC_DEFUN([AC_LIBLTDL_CONVENIENCE],
3590
[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
3591
case $enable_ltdl_convenience in
3592
no) AC_MSG_ERROR([this package needs a convenience libltdl]) ;;
3593
"") enable_ltdl_convenience=yes
3594
ac_configure_args="$ac_configure_args --enable-ltdl-convenience" ;;
3596
LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdlc.la
3597
LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl'])
3598
# For backwards non-gettext consistent compatibility...
3600
])# AC_LIBLTDL_CONVENIENCE
3603
# AC_LIBLTDL_INSTALLABLE([DIRECTORY])
3604
# -----------------------------------
3605
# sets LIBLTDL to the link flags for the libltdl installable library and
3606
# LTDLINCL to the include flags for the libltdl header and adds
3607
# --enable-ltdl-install to the configure arguments. Note that
3608
# AC_CONFIG_SUBDIRS is not called here. If DIRECTORY is not provided,
3609
# and an installed libltdl is not found, it is assumed to be `libltdl'.
3610
# LIBLTDL will be prefixed with '${top_builddir}/'# and LTDLINCL with
3611
# '${top_srcdir}/' (note the single quotes!). If your package is not
3612
# flat and you're not using automake, define top_builddir and top_srcdir
3613
# appropriately in the Makefiles.
3614
# In the future, this macro may have to be called after AC_PROG_LIBTOOL.
3615
AC_DEFUN([AC_LIBLTDL_INSTALLABLE],
3616
[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
3617
AC_CHECK_LIB(ltdl, lt_dlinit,
3618
[test x"$enable_ltdl_install" != xyes && enable_ltdl_install=no],
3619
[if test x"$enable_ltdl_install" = xno; then
3620
AC_MSG_WARN([libltdl not installed, but installation disabled])
3622
enable_ltdl_install=yes
3625
if test x"$enable_ltdl_install" = x"yes"; then
3626
ac_configure_args="$ac_configure_args --enable-ltdl-install"
3627
LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdl.la
3628
LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl'])
3630
ac_configure_args="$ac_configure_args --enable-ltdl-install=no"
3634
# For backwards non-gettext consistent compatibility...
3636
])# AC_LIBLTDL_INSTALLABLE
3641
# enable support for C++ libraries
3642
AC_DEFUN([AC_LIBTOOL_CXX],
3643
[AC_REQUIRE([_LT_AC_LANG_CXX])
3649
AC_DEFUN([_LT_AC_LANG_CXX],
3650
[AC_REQUIRE([AC_PROG_CXX])
3651
AC_REQUIRE([_LT_AC_PROG_CXXCPP])
3652
_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}CXX])
3655
# _LT_AC_PROG_CXXCPP
3656
# ------------------
3657
AC_DEFUN([_LT_AC_PROG_CXXCPP],
3659
AC_REQUIRE([AC_PROG_CXX])
3660
if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
3661
( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
3662
(test "X$CXX" != "Xg++"))) ; then
3665
])# _LT_AC_PROG_CXXCPP
3669
# enable support for Fortran 77 libraries
3670
AC_DEFUN([AC_LIBTOOL_F77],
3671
[AC_REQUIRE([_LT_AC_LANG_F77])
3677
AC_DEFUN([_LT_AC_LANG_F77],
3678
[AC_REQUIRE([AC_PROG_F77])
3679
_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}F77])
3685
# enable support for GCJ libraries
3686
AC_DEFUN([AC_LIBTOOL_GCJ],
3687
[AC_REQUIRE([_LT_AC_LANG_GCJ])
3693
AC_DEFUN([_LT_AC_LANG_GCJ],
3694
[AC_PROVIDE_IFELSE([AC_PROG_GCJ],[],
3695
[AC_PROVIDE_IFELSE([A][M_PROG_GCJ],[],
3696
[AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ],[],
3697
[ifdef([AC_PROG_GCJ],[AC_REQUIRE([AC_PROG_GCJ])],
3698
[ifdef([A][M_PROG_GCJ],[AC_REQUIRE([A][M_PROG_GCJ])],
3699
[AC_REQUIRE([A][C_PROG_GCJ_OR_A][M_PROG_GCJ])])])])])])
3700
_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}GCJ])
3706
# enable support for Windows resource files
3707
AC_DEFUN([AC_LIBTOOL_RC],
3708
[AC_REQUIRE([LT_AC_PROG_RC])
3709
_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}RC])
3713
# AC_LIBTOOL_LANG_C_CONFIG
3714
# ------------------------
3715
# Ensure that the configuration vars for the C compiler are
3716
# suitably defined. Those variables are subsequently used by
3717
# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
3718
AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG], [_LT_AC_LANG_C_CONFIG])
3719
AC_DEFUN([_LT_AC_LANG_C_CONFIG],
3723
# Source file extension for C test sources.
3726
# Object file extension for compiled C test sources.
3728
_LT_AC_TAGVAR(objext, $1)=$objext
3730
# Code to be used in simple compile tests
3731
lt_simple_compile_test_code="int some_variable = 0;"
3733
# Code to be used in simple link tests
3734
lt_simple_link_test_code='int main(){return(0);}'
3738
# save warnings/boilerplate of simple test code
3739
_LT_COMPILER_BOILERPLATE
3740
_LT_LINKER_BOILERPLATE
3742
AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1)
3743
AC_LIBTOOL_PROG_COMPILER_PIC($1)
3744
AC_LIBTOOL_PROG_CC_C_O($1)
3745
AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
3746
AC_LIBTOOL_PROG_LD_SHLIBS($1)
3747
AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
3748
AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
3749
AC_LIBTOOL_SYS_LIB_STRIP
3750
AC_LIBTOOL_DLOPEN_SELF
3752
# Report which library types will actually be built
3753
AC_MSG_CHECKING([if libtool supports shared libraries])
3754
AC_MSG_RESULT([$can_build_shared])
3756
AC_MSG_CHECKING([whether to build shared libraries])
3757
test "$can_build_shared" = "no" && enable_shared=no
3759
# On AIX, shared libraries and static libraries use the same namespace, and
3760
# are all built from PIC.
3763
test "$enable_shared" = yes && enable_static=no
3764
if test -n "$RANLIB"; then
3765
archive_cmds="$archive_cmds~\$RANLIB \$lib"
3766
postinstall_cmds='$RANLIB $lib'
3771
if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
3772
test "$enable_shared" = yes && enable_static=no
3776
AC_MSG_RESULT([$enable_shared])
3778
AC_MSG_CHECKING([whether to build static libraries])
3779
# Make sure either enable_shared or enable_static is yes.
3780
test "$enable_shared" = yes || enable_static=yes
3781
AC_MSG_RESULT([$enable_static])
3783
AC_LIBTOOL_CONFIG($1)
3787
])# AC_LIBTOOL_LANG_C_CONFIG
3790
# AC_LIBTOOL_LANG_CXX_CONFIG
3791
# --------------------------
3792
# Ensure that the configuration vars for the C compiler are
3793
# suitably defined. Those variables are subsequently used by
3794
# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
3795
AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG], [_LT_AC_LANG_CXX_CONFIG(CXX)])
3796
AC_DEFUN([_LT_AC_LANG_CXX_CONFIG],
3798
AC_REQUIRE([AC_PROG_CXX])
3799
AC_REQUIRE([_LT_AC_PROG_CXXCPP])
3801
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
3802
_LT_AC_TAGVAR(allow_undefined_flag, $1)=
3803
_LT_AC_TAGVAR(always_export_symbols, $1)=no
3804
_LT_AC_TAGVAR(archive_expsym_cmds, $1)=
3805
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
3806
_LT_AC_TAGVAR(hardcode_direct, $1)=no
3807
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
3808
_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
3809
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
3810
_LT_AC_TAGVAR(hardcode_minus_L, $1)=no
3811
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
3812
_LT_AC_TAGVAR(hardcode_automatic, $1)=no
3813
_LT_AC_TAGVAR(module_cmds, $1)=
3814
_LT_AC_TAGVAR(module_expsym_cmds, $1)=
3815
_LT_AC_TAGVAR(link_all_deplibs, $1)=unknown
3816
_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
3817
_LT_AC_TAGVAR(no_undefined_flag, $1)=
3818
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
3819
_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no
3821
# Dependencies to place before and after the object being linked:
3822
_LT_AC_TAGVAR(predep_objects, $1)=
3823
_LT_AC_TAGVAR(postdep_objects, $1)=
3824
_LT_AC_TAGVAR(predeps, $1)=
3825
_LT_AC_TAGVAR(postdeps, $1)=
3826
_LT_AC_TAGVAR(compiler_lib_search_path, $1)=
3827
_LT_AC_TAGVAR(compiler_lib_search_dirs, $1)=
3829
# Source file extension for C++ test sources.
3832
# Object file extension for compiled C++ test sources.
3834
_LT_AC_TAGVAR(objext, $1)=$objext
3836
# Code to be used in simple compile tests
3837
lt_simple_compile_test_code="int some_variable = 0;"
3839
# Code to be used in simple link tests
3840
lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }'
3842
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
3845
# save warnings/boilerplate of simple test code
3846
_LT_COMPILER_BOILERPLATE
3847
_LT_LINKER_BOILERPLATE
3849
# Allow CC to be a program name with arguments.
3854
lt_save_with_gnu_ld=$with_gnu_ld
3855
lt_save_path_LD=$lt_cv_path_LD
3856
if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then
3857
lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx
3859
$as_unset lt_cv_prog_gnu_ld
3861
if test -n "${lt_cv_path_LDCXX+set}"; then
3862
lt_cv_path_LD=$lt_cv_path_LDCXX
3864
$as_unset lt_cv_path_LD
3866
test -z "${LDCXX+set}" || LD=$LDCXX
3869
_LT_AC_TAGVAR(compiler, $1)=$CC
3870
_LT_CC_BASENAME([$compiler])
3872
# We don't want -fno-exception wen compiling C++ code, so set the
3873
# no_builtin_flag separately
3874
if test "$GXX" = yes; then
3875
_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
3877
_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
3880
if test "$GXX" = yes; then
3881
# Set up default GNU C++ configuration
3885
# Check if GNU C++ uses GNU ld as the underlying linker, since the
3886
# archiving commands below assume that GNU ld is being used.
3887
if test "$with_gnu_ld" = yes; then
3888
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
3889
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
3891
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
3892
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
3894
# If archive_cmds runs LD, not CC, wlarc should be empty
3895
# XXX I think wlarc can be eliminated in ltcf-cxx, but I need to
3896
# investigate it a little bit more. (MM)
3899
# ancient GNU ld didn't support --whole-archive et. al.
3900
if eval "`$CC -print-prog-name=ld` --help 2>&1" | \
3901
grep 'no-whole-archive' > /dev/null; then
3902
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
3904
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
3910
# A generic and very simple default shared library creation
3911
# command for GNU C++ for the case where it uses the native
3912
# linker, instead of GNU ld. If possible, this setting should
3913
# overridden to take advantage of the native linker features on
3914
# the platform it is being used on.
3915
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
3918
# Commands to make compiler produce verbose output that lists
3919
# what "hidden" libraries, object files and flags are used when
3920
# linking a shared library.
3921
output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"'
3929
# PORTME: fill in a description of your system's C++ link characteristics
3930
AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
3931
_LT_AC_TAGVAR(ld_shlibs, $1)=yes
3934
# FIXME: insert proper C++ library support
3935
_LT_AC_TAGVAR(ld_shlibs, $1)=no
3938
if test "$host_cpu" = ia64; then
3939
# On IA64, the linker does run time linking by default, so we don't
3940
# have to do anything special.
3941
aix_use_runtimelinking=no
3942
exp_sym_flag='-Bexport'
3945
aix_use_runtimelinking=no
3947
# Test if we are trying to use run time linking or normal
3948
# AIX style linking. If -brtl is somewhere in LDFLAGS, we
3949
# need to do runtime linking.
3950
case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
3951
for ld_flag in $LDFLAGS; do
3954
aix_use_runtimelinking=yes
3962
exp_sym_flag='-bexport'
3963
no_entry_flag='-bnoentry'
3966
# When large executables or shared objects are built, AIX ld can
3967
# have problems creating the table of contents. If linking a library
3968
# or program results in "error TOC overflow" add -mminimal-toc to
3969
# CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
3970
# enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
3972
_LT_AC_TAGVAR(archive_cmds, $1)=''
3973
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
3974
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
3975
_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
3977
if test "$GXX" = yes; then
3978
case $host_os in aix4.[[012]]|aix4.[[012]].*)
3979
# We only want to do this on AIX 4.2 and lower, the check
3980
# below for broken collect2 doesn't work under 4.3+
3981
collect2name=`${CC} -print-prog-name=collect2`
3982
if test -f "$collect2name" && \
3983
strings "$collect2name" | grep resolve_lib_name >/dev/null
3985
# We have reworked collect2
3988
# We have old collect2
3989
_LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
3990
# It fails to find uninstalled libraries when the uninstalled
3991
# path is not listed in the libpath. Setting hardcode_minus_L
3992
# to unsupported forces relinking
3993
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
3994
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
3995
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
3999
shared_flag='-shared'
4000
if test "$aix_use_runtimelinking" = yes; then
4001
shared_flag="$shared_flag "'${wl}-G'
4005
if test "$host_cpu" = ia64; then
4006
# VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
4007
# chokes on -Wl,-G. The following line is correct:
4010
if test "$aix_use_runtimelinking" = yes; then
4011
shared_flag='${wl}-G'
4013
shared_flag='${wl}-bM:SRE'
4018
# It seems that -bexpall does not export symbols beginning with
4019
# underscore (_), so it is better to generate a list of symbols to export.
4020
_LT_AC_TAGVAR(always_export_symbols, $1)=yes
4021
if test "$aix_use_runtimelinking" = yes; then
4022
# Warning - without using the other runtime loading flags (-brtl),
4023
# -berok will link without error, but may produce a broken library.
4024
_LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok'
4025
# Determine the default libpath from the value encoded in an empty executable.
4026
_LT_AC_SYS_LIBPATH_AIX
4027
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
4029
_LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
4031
if test "$host_cpu" = ia64; then
4032
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
4033
_LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
4034
_LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
4036
# Determine the default libpath from the value encoded in an empty executable.
4037
_LT_AC_SYS_LIBPATH_AIX
4038
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
4039
# Warning - without using the other run time loading flags,
4040
# -berok will link without error, but may produce a broken library.
4041
_LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
4042
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
4043
# Exported symbols can be pulled into shared objects from archives
4044
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
4045
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
4046
# This is similar to how AIX traditionally builds its shared libraries.
4047
_LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
4053
if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
4054
_LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
4055
# Joseph Beckenbach <jrb3@best.com> says some releases of gcc
4056
# support --undefined. This deserves some investigation. FIXME
4057
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4059
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4064
case $cc_basename in
4066
# FIXME: insert proper C++ library support
4067
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4072
cygwin* | mingw* | pw32*)
4073
# _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
4074
# as there is no search path for DLLs.
4075
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
4076
_LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
4077
_LT_AC_TAGVAR(always_export_symbols, $1)=no
4078
_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
4080
if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
4081
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
4082
# If the export-symbols file already is a .def file (1st line
4083
# is EXPORTS), use it as is; otherwise, prepend...
4084
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
4085
cp $export_symbols $output_objdir/$soname.def;
4087
echo EXPORTS > $output_objdir/$soname.def;
4088
cat $export_symbols >> $output_objdir/$soname.def;
4090
$CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
4092
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4095
darwin* | rhapsody*)
4096
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
4097
_LT_AC_TAGVAR(hardcode_direct, $1)=no
4098
_LT_AC_TAGVAR(hardcode_automatic, $1)=yes
4099
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
4100
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=''
4101
_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
4102
_LT_AC_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined"
4103
if test "$GXX" = yes ; then
4104
output_verbose_link_cmd='echo'
4105
_LT_AC_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
4106
_LT_AC_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
4107
_LT_AC_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}"
4108
_LT_AC_TAGVAR(module_expsym_cmds, $1)="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}"
4109
if test "$lt_cv_apple_cc_single_mod" != "yes"; then
4110
_LT_AC_TAGVAR(archive_cmds, $1)="\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dsymutil}"
4111
_LT_AC_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dar_export_syms}${_lt_dsymutil}"
4114
case $cc_basename in
4116
output_verbose_link_cmd='echo'
4117
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring'
4118
_LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
4119
# Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
4120
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
4121
_LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
4124
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4131
case $cc_basename in
4133
# FIXME: insert proper C++ library support
4134
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4137
# Green Hills C++ Compiler
4138
# FIXME: insert proper C++ library support
4139
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4142
# FIXME: insert proper C++ library support
4143
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4148
# C++ shared libraries reported to be fairly broken before switch to ELF
4149
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4152
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
4154
freebsd* | dragonfly*)
4155
# FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF
4157
_LT_AC_TAGVAR(ld_shlibs, $1)=yes
4162
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
4163
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4164
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
4165
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
4166
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
4167
# but as the default
4168
# location of the library.
4170
case $cc_basename in
4172
# FIXME: insert proper C++ library support
4173
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4176
_LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
4177
# Commands to make compiler produce verbose output that lists
4178
# what "hidden" libraries, object files and flags are used when
4179
# linking a shared library.
4181
# There doesn't appear to be a way to prevent this compiler from
4182
# explicitly linking system object files so we need to strip them
4183
# from the output so that they don't get included in the library
4185
output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | grep "[[-]]L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
4188
if test "$GXX" = yes; then
4189
_LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$CC -shared -nostdlib -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
4191
# FIXME: insert proper C++ library support
4192
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4198
if test $with_gnu_ld = no; then
4199
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
4200
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4205
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
4211
_LT_AC_TAGVAR(hardcode_direct, $1)=no
4212
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
4215
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
4216
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
4217
# but as the default
4218
# location of the library.
4222
case $cc_basename in
4224
# FIXME: insert proper C++ library support
4225
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4230
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
4233
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
4236
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
4239
# Commands to make compiler produce verbose output that lists
4240
# what "hidden" libraries, object files and flags are used when
4241
# linking a shared library.
4243
# There doesn't appear to be a way to prevent this compiler from
4244
# explicitly linking system object files so we need to strip them
4245
# from the output so that they don't get included in the library
4247
output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | grep "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
4250
if test "$GXX" = yes; then
4251
if test $with_gnu_ld = no; then
4254
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
4257
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
4260
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
4265
# FIXME: insert proper C++ library support
4266
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4272
_LT_AC_TAGVAR(hardcode_direct, $1)=no
4273
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
4274
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
4275
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
4276
# Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
4277
# Instead, shared libraries are loaded at an image base (0x10000000 by
4278
# default) and relocated if they conflict, which is a slow very memory
4279
# consuming and fragmenting process. To avoid this, we pick a random,
4280
# 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
4281
# time. Moving up from 0x10000000 also allows more sbrk(2) space.
4282
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
4283
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
4286
case $cc_basename in
4289
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
4291
# Archives containing C++ object files must be created using
4292
# "CC -ar", where "CC" is the IRIX C++ compiler. This is
4293
# necessary to make sure instantiated templates are included
4295
_LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs'
4298
if test "$GXX" = yes; then
4299
if test "$with_gnu_ld" = no; then
4300
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
4302
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` -o $lib'
4305
_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
4308
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
4309
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4311
linux* | k*bsd*-gnu)
4312
case $cc_basename in
4314
# Kuck and Associates, Inc. (KAI) C++ Compiler
4316
# KCC will only create a shared library if the output file
4317
# ends with ".so" (or ".sl" for HP-UX), so rename the library
4318
# to its proper name (with version) after linking.
4319
_LT_AC_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
4320
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib ${wl}-retain-symbols-file,$export_symbols; mv \$templib $lib'
4321
# Commands to make compiler produce verbose output that lists
4322
# what "hidden" libraries, object files and flags are used when
4323
# linking a shared library.
4325
# There doesn't appear to be a way to prevent this compiler from
4326
# explicitly linking system object files so we need to strip them
4327
# from the output so that they don't get included in the library
4329
output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | grep "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
4331
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath,$libdir'
4332
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
4334
# Archives containing C++ object files must be created using
4335
# "CC -Bstatic", where "CC" is the KAI C++ compiler.
4336
_LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs'
4341
# version 8.0 and above of icpc choke on multiply defined symbols
4342
# if we add $predep_objects and $postdep_objects, however 7.1 and
4343
# earlier do not add the objects themselves.
4344
case `$CC -V 2>&1` in
4346
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
4347
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
4349
*) # Version 8.0 or newer
4352
ia64*) tmp_idyn=' -i_dynamic';;
4354
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4355
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
4358
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
4359
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
4360
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
4361
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
4364
# Portland Group C++ compiler
4365
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
4366
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
4368
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
4369
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
4370
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
4374
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
4375
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib ${wl}-retain-symbols-file $wl$export_symbols'
4377
runpath_var=LD_RUN_PATH
4378
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
4379
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4381
# Commands to make compiler produce verbose output that lists
4382
# what "hidden" libraries, object files and flags are used when
4383
# linking a shared library.
4385
# There doesn't appear to be a way to prevent this compiler from
4386
# explicitly linking system object files so we need to strip them
4387
# from the output so that they don't get included in the library
4389
output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
4392
case `$CC -V 2>&1 | sed 5q` in
4395
_LT_AC_TAGVAR(no_undefined_flag, $1)=' -zdefs'
4396
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
4397
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols'
4398
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
4399
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
4401
# Not sure whether something based on
4402
# $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1
4404
output_verbose_link_cmd='echo'
4406
# Archives containing C++ object files must be created using
4407
# "CC -xar", where "CC" is the Sun C++ compiler. This is
4408
# necessary to make sure instantiated templates are included
4410
_LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
4417
# FIXME: insert proper C++ library support
4418
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4421
# FIXME: insert proper C++ library support
4422
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4425
case $cc_basename in
4427
# FIXME: insert proper C++ library support
4428
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4431
# FIXME: insert proper C++ library support
4432
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4436
netbsd* | netbsdelf*-gnu)
4437
if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
4438
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags'
4440
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
4441
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
4442
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
4444
# Workaround some broken pre-1.5 toolchains
4445
output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"'
4448
# C++ shared libraries are fairly broken
4449
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4452
if test -f /usr/libexec/ld.so; then
4453
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
4454
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
4455
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
4456
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
4457
if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
4458
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib'
4459
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
4460
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
4462
output_verbose_link_cmd='echo'
4464
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4468
case $cc_basename in
4470
# Kuck and Associates, Inc. (KAI) C++ Compiler
4472
# KCC will only create a shared library if the output file
4473
# ends with ".so" (or ".sl" for HP-UX), so rename the library
4474
# to its proper name (with version) after linking.
4475
_LT_AC_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
4477
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
4478
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4480
# Archives containing C++ object files must be created using
4481
# "CC -Bstatic", where "CC" is the KAI C++ compiler.
4482
_LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs'
4486
# Rational C++ 2.4.1
4487
# FIXME: insert proper C++ library support
4488
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4491
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
4492
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && echo ${wl}-set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
4494
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
4495
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4497
# Commands to make compiler produce verbose output that lists
4498
# what "hidden" libraries, object files and flags are used when
4499
# linking a shared library.
4501
# There doesn't appear to be a way to prevent this compiler from
4502
# explicitly linking system object files so we need to strip them
4503
# from the output so that they don't get included in the library
4505
output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld" | grep -v "ld:"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
4508
if test "$GXX" = yes && test "$with_gnu_ld" = no; then
4509
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
4510
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
4512
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
4513
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4515
# Commands to make compiler produce verbose output that lists
4516
# what "hidden" libraries, object files and flags are used when
4517
# linking a shared library.
4518
output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"'
4521
# FIXME: insert proper C++ library support
4522
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4528
case $cc_basename in
4530
# Kuck and Associates, Inc. (KAI) C++ Compiler
4532
# KCC will only create a shared library if the output file
4533
# ends with ".so" (or ".sl" for HP-UX), so rename the library
4534
# to its proper name (with version) after linking.
4535
_LT_AC_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
4537
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
4538
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4540
# Archives containing C++ object files must be created using
4541
# the KAI C++ compiler.
4542
_LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs'
4545
# Rational C++ 2.4.1
4546
# FIXME: insert proper C++ library support
4547
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4550
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
4551
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
4552
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~
4553
echo "-hidden">> $lib.exp~
4554
$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname -Wl,-input -Wl,$lib.exp `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~
4557
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
4558
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4560
# Commands to make compiler produce verbose output that lists
4561
# what "hidden" libraries, object files and flags are used when
4562
# linking a shared library.
4564
# There doesn't appear to be a way to prevent this compiler from
4565
# explicitly linking system object files so we need to strip them
4566
# from the output so that they don't get included in the library
4568
output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld" | grep -v "ld:"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
4571
if test "$GXX" = yes && test "$with_gnu_ld" = no; then
4572
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
4573
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
4575
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
4576
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
4578
# Commands to make compiler produce verbose output that lists
4579
# what "hidden" libraries, object files and flags are used when
4580
# linking a shared library.
4581
output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"'
4584
# FIXME: insert proper C++ library support
4585
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4591
# FIXME: insert proper C++ library support
4592
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4595
case $cc_basename in
4598
# FIXME: insert proper C++ library support
4599
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4603
# FIXME: insert proper C++ library support
4604
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4607
# FIXME: insert proper C++ library support
4608
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4613
case $cc_basename in
4615
# Sun C++ 4.2, 5.x and Centerline C++
4616
_LT_AC_TAGVAR(archive_cmds_need_lc,$1)=yes
4617
_LT_AC_TAGVAR(no_undefined_flag, $1)=' -zdefs'
4618
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
4619
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
4620
$CC -G${allow_undefined_flag} ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
4622
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
4623
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
4625
solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
4627
# The compiler driver will combine and reorder linker options,
4628
# but understands `-z linker_flag'.
4629
# Supported since Solaris 2.6 (maybe 2.5.1?)
4630
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
4633
_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
4635
output_verbose_link_cmd='echo'
4637
# Archives containing C++ object files must be created using
4638
# "CC -xar", where "CC" is the Sun C++ compiler. This is
4639
# necessary to make sure instantiated templates are included
4641
_LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
4644
# Green Hills C++ Compiler
4645
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
4647
# The C++ compiler must be used to create the archive.
4648
_LT_AC_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs'
4651
# GNU C++ compiler with Solaris linker
4652
if test "$GXX" = yes && test "$with_gnu_ld" = no; then
4653
_LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs'
4654
if $CC --version | grep -v '^2\.7' > /dev/null; then
4655
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
4656
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
4657
$CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
4659
# Commands to make compiler produce verbose output that lists
4660
# what "hidden" libraries, object files and flags are used when
4661
# linking a shared library.
4662
output_verbose_link_cmd="$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\""
4664
# g++ 2.7 appears to require `-G' NOT `-shared' on this
4666
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
4667
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
4668
$CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
4670
# Commands to make compiler produce verbose output that lists
4671
# what "hidden" libraries, object files and flags are used when
4672
# linking a shared library.
4673
output_verbose_link_cmd="$CC -G $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\""
4676
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir'
4678
solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
4680
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
4687
sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
4688
_LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
4689
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
4690
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
4691
runpath_var='LD_RUN_PATH'
4693
case $cc_basename in
4695
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
4696
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
4699
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
4700
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
4704
sysv5* | sco3.2v5* | sco5v6*)
4705
# Note: We can NOT use -z defs as we might desire, because we do not
4706
# link with -lc, and that would cause any symbols used from libc to
4707
# always be unresolved, which means just about no library would
4708
# ever link correctly. If we're not using GNU ld we use -z text
4709
# though, which does catch some bad symbols but isn't as heavy-handed
4711
# For security reasons, it is highly recommended that you always
4712
# use absolute paths for naming shared libraries, and exclude the
4713
# DT_RUNPATH tag from executables and libraries. But doing so
4714
# requires that you compile everything twice, which is a pain.
4715
# So that behaviour is only enabled if SCOABSPATH is set to a
4716
# non-empty value in the environment. Most likely only useful for
4717
# creating official distributions of packages.
4718
# This is a hack until libtool officially supports absolute path
4719
# names for shared libraries.
4720
_LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
4721
_LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
4722
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
4723
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
4724
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`'
4725
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
4726
_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
4727
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
4728
runpath_var='LD_RUN_PATH'
4730
case $cc_basename in
4732
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
4733
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
4736
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
4737
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
4742
case $cc_basename in
4744
# NonStop-UX NCC 3.20
4745
# FIXME: insert proper C++ library support
4746
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4749
# FIXME: insert proper C++ library support
4750
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4755
# FIXME: insert proper C++ library support
4756
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4759
# FIXME: insert proper C++ library support
4760
_LT_AC_TAGVAR(ld_shlibs, $1)=no
4763
AC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)])
4764
test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
4766
_LT_AC_TAGVAR(GCC, $1)="$GXX"
4767
_LT_AC_TAGVAR(LD, $1)="$LD"
4769
AC_LIBTOOL_POSTDEP_PREDEP($1)
4770
AC_LIBTOOL_PROG_COMPILER_PIC($1)
4771
AC_LIBTOOL_PROG_CC_C_O($1)
4772
AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
4773
AC_LIBTOOL_PROG_LD_SHLIBS($1)
4774
AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
4775
AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
4777
AC_LIBTOOL_CONFIG($1)
4784
with_gnu_ldcxx=$with_gnu_ld
4785
with_gnu_ld=$lt_save_with_gnu_ld
4786
lt_cv_path_LDCXX=$lt_cv_path_LD
4787
lt_cv_path_LD=$lt_save_path_LD
4788
lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld
4789
lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld
4790
])# AC_LIBTOOL_LANG_CXX_CONFIG
4792
# AC_LIBTOOL_POSTDEP_PREDEP([TAGNAME])
4793
# ------------------------------------
4794
# Figure out "hidden" library dependencies from verbose
4795
# compiler output when linking a shared library.
4796
# Parse the compiler output and extract the necessary
4797
# objects, libraries and library flags.
4798
AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP],
4799
[AC_REQUIRE([LT_AC_PROG_SED])dnl
4800
dnl we can't use the lt_simple_compile_test_code here,
4801
dnl because it contains code intended for an executable,
4802
dnl not a library. It's possible we should let each
4803
dnl tag define a new lt_????_link_test_code variable,
4804
dnl but it's only used here...
4805
ifelse([$1],[],[cat > conftest.$ac_ext <<EOF
4807
void foo (void) { a = 0; }
4809
],[$1],[CXX],[cat > conftest.$ac_ext <<EOF
4813
Foo (void) { a = 0; }
4818
],[$1],[F77],[cat > conftest.$ac_ext <<EOF
4826
],[$1],[GCJ],[cat > conftest.$ac_ext <<EOF
4829
public void bar (void) {
4835
dnl Parse the compiler output and extract the necessary
4836
dnl objects, libraries and library flags.
4837
if AC_TRY_EVAL(ac_compile); then
4838
# Parse the compiler output and extract the necessary
4839
# objects, libraries and library flags.
4841
# Sentinel used to keep track of whether or not we are before
4842
# the conftest object file.
4843
pre_test_object_deps_done=no
4845
# The `*' in the case matches for architectures that use `case' in
4846
# $output_verbose_cmd can trigger glob expansion during the loop
4847
# eval without this substitution.
4848
output_verbose_link_cmd=`$echo "X$output_verbose_link_cmd" | $Xsed -e "$no_glob_subst"`
4850
for p in `eval $output_verbose_link_cmd`; do
4854
# Some compilers place space between "-{L,R}" and the path.
4857
|| test $p = "-R"; then
4864
if test "$pre_test_object_deps_done" = no; then
4867
# Internal compiler library paths should come after those
4868
# provided the user. The postdeps already come after the
4869
# user supplied libs so there is no need to process them.
4870
if test -z "$_LT_AC_TAGVAR(compiler_lib_search_path, $1)"; then
4871
_LT_AC_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}"
4873
_LT_AC_TAGVAR(compiler_lib_search_path, $1)="${_LT_AC_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}"
4876
# The "-l" case would never come before the object being
4877
# linked, so don't bother handling this case.
4880
if test -z "$_LT_AC_TAGVAR(postdeps, $1)"; then
4881
_LT_AC_TAGVAR(postdeps, $1)="${prev}${p}"
4883
_LT_AC_TAGVAR(postdeps, $1)="${_LT_AC_TAGVAR(postdeps, $1)} ${prev}${p}"
4889
# This assumes that the test object file only shows up
4890
# once in the compiler output.
4891
if test "$p" = "conftest.$objext"; then
4892
pre_test_object_deps_done=yes
4896
if test "$pre_test_object_deps_done" = no; then
4897
if test -z "$_LT_AC_TAGVAR(predep_objects, $1)"; then
4898
_LT_AC_TAGVAR(predep_objects, $1)="$p"
4900
_LT_AC_TAGVAR(predep_objects, $1)="$_LT_AC_TAGVAR(predep_objects, $1) $p"
4903
if test -z "$_LT_AC_TAGVAR(postdep_objects, $1)"; then
4904
_LT_AC_TAGVAR(postdep_objects, $1)="$p"
4906
_LT_AC_TAGVAR(postdep_objects, $1)="$_LT_AC_TAGVAR(postdep_objects, $1) $p"
4911
*) ;; # Ignore the rest.
4919
echo "libtool.m4: error: problem compiling $1 test program"
4922
$rm -f confest.$objext
4924
_LT_AC_TAGVAR(compiler_lib_search_dirs, $1)=
4925
if test -n "$_LT_AC_TAGVAR(compiler_lib_search_path, $1)"; then
4926
_LT_AC_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_AC_TAGVAR(compiler_lib_search_path, $1)}" | ${SED} -e 's! -L! !g' -e 's!^ !!'`
4929
# PORTME: override above test on systems where it is broken
4933
# Interix 3.5 installs completely hosed .la files for C++, so rather than
4934
# hack all around it, let's just trust "g++" to DTRT.
4935
_LT_AC_TAGVAR(predep_objects,$1)=
4936
_LT_AC_TAGVAR(postdep_objects,$1)=
4937
_LT_AC_TAGVAR(postdeps,$1)=
4941
case `$CC -V 2>&1 | sed 5q` in
4945
# The more standards-conforming stlport4 library is
4946
# incompatible with the Cstd library. Avoid specifying
4947
# it if it's in CXXFLAGS. Ignore libCrun as
4948
# -library=stlport4 depends on it.
4949
case " $CXX $CXXFLAGS " in
4950
*" -library=stlport4 "*)
4951
solaris_use_stlport4=yes
4954
if test "$solaris_use_stlport4" != yes; then
4955
_LT_AC_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
4962
case $cc_basename in
4964
# The more standards-conforming stlport4 library is
4965
# incompatible with the Cstd library. Avoid specifying
4966
# it if it's in CXXFLAGS. Ignore libCrun as
4967
# -library=stlport4 depends on it.
4968
case " $CXX $CXXFLAGS " in
4969
*" -library=stlport4 "*)
4970
solaris_use_stlport4=yes
4974
# Adding this requires a known-good setup of shared libraries for
4975
# Sun compiler versions before 5.6, else PIC objects from an old
4976
# archive will be linked into the output, leading to subtle bugs.
4977
if test "$solaris_use_stlport4" != yes; then
4978
_LT_AC_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
4985
case " $_LT_AC_TAGVAR(postdeps, $1) " in
4986
*" -lc "*) _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no ;;
4988
])# AC_LIBTOOL_POSTDEP_PREDEP
4990
# AC_LIBTOOL_LANG_F77_CONFIG
4991
# --------------------------
4992
# Ensure that the configuration vars for the C compiler are
4993
# suitably defined. Those variables are subsequently used by
4994
# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
4995
AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG], [_LT_AC_LANG_F77_CONFIG(F77)])
4996
AC_DEFUN([_LT_AC_LANG_F77_CONFIG],
4997
[AC_REQUIRE([AC_PROG_F77])
4998
AC_LANG_PUSH(Fortran 77)
5000
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
5001
_LT_AC_TAGVAR(allow_undefined_flag, $1)=
5002
_LT_AC_TAGVAR(always_export_symbols, $1)=no
5003
_LT_AC_TAGVAR(archive_expsym_cmds, $1)=
5004
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
5005
_LT_AC_TAGVAR(hardcode_direct, $1)=no
5006
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
5007
_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
5008
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
5009
_LT_AC_TAGVAR(hardcode_minus_L, $1)=no
5010
_LT_AC_TAGVAR(hardcode_automatic, $1)=no
5011
_LT_AC_TAGVAR(module_cmds, $1)=
5012
_LT_AC_TAGVAR(module_expsym_cmds, $1)=
5013
_LT_AC_TAGVAR(link_all_deplibs, $1)=unknown
5014
_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
5015
_LT_AC_TAGVAR(no_undefined_flag, $1)=
5016
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
5017
_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no
5019
# Source file extension for f77 test sources.
5022
# Object file extension for compiled f77 test sources.
5024
_LT_AC_TAGVAR(objext, $1)=$objext
5026
# Code to be used in simple compile tests
5027
lt_simple_compile_test_code="\
5033
# Code to be used in simple link tests
5034
lt_simple_link_test_code="\
5039
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
5042
# save warnings/boilerplate of simple test code
5043
_LT_COMPILER_BOILERPLATE
5044
_LT_LINKER_BOILERPLATE
5046
# Allow CC to be a program name with arguments.
5050
_LT_AC_TAGVAR(compiler, $1)=$CC
5051
_LT_CC_BASENAME([$compiler])
5053
AC_MSG_CHECKING([if libtool supports shared libraries])
5054
AC_MSG_RESULT([$can_build_shared])
5056
AC_MSG_CHECKING([whether to build shared libraries])
5057
test "$can_build_shared" = "no" && enable_shared=no
5059
# On AIX, shared libraries and static libraries use the same namespace, and
5060
# are all built from PIC.
5063
test "$enable_shared" = yes && enable_static=no
5064
if test -n "$RANLIB"; then
5065
archive_cmds="$archive_cmds~\$RANLIB \$lib"
5066
postinstall_cmds='$RANLIB $lib'
5070
if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
5071
test "$enable_shared" = yes && enable_static=no
5075
AC_MSG_RESULT([$enable_shared])
5077
AC_MSG_CHECKING([whether to build static libraries])
5078
# Make sure either enable_shared or enable_static is yes.
5079
test "$enable_shared" = yes || enable_static=yes
5080
AC_MSG_RESULT([$enable_static])
5082
_LT_AC_TAGVAR(GCC, $1)="$G77"
5083
_LT_AC_TAGVAR(LD, $1)="$LD"
5085
AC_LIBTOOL_PROG_COMPILER_PIC($1)
5086
AC_LIBTOOL_PROG_CC_C_O($1)
5087
AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
5088
AC_LIBTOOL_PROG_LD_SHLIBS($1)
5089
AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
5090
AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
5092
AC_LIBTOOL_CONFIG($1)
5096
])# AC_LIBTOOL_LANG_F77_CONFIG
5099
# AC_LIBTOOL_LANG_GCJ_CONFIG
5100
# --------------------------
5101
# Ensure that the configuration vars for the C compiler are
5102
# suitably defined. Those variables are subsequently used by
5103
# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
5104
AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG], [_LT_AC_LANG_GCJ_CONFIG(GCJ)])
5105
AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG],
5108
# Source file extension for Java test sources.
5111
# Object file extension for compiled Java test sources.
5113
_LT_AC_TAGVAR(objext, $1)=$objext
5115
# Code to be used in simple compile tests
5116
lt_simple_compile_test_code="class foo {}"
5118
# Code to be used in simple link tests
5119
lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }'
5121
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
5124
# save warnings/boilerplate of simple test code
5125
_LT_COMPILER_BOILERPLATE
5126
_LT_LINKER_BOILERPLATE
5128
# Allow CC to be a program name with arguments.
5132
_LT_AC_TAGVAR(compiler, $1)=$CC
5133
_LT_CC_BASENAME([$compiler])
5135
# GCJ did not exist at the time GCC didn't implicitly link libc in.
5136
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
5138
_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
5140
AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1)
5141
AC_LIBTOOL_PROG_COMPILER_PIC($1)
5142
AC_LIBTOOL_PROG_CC_C_O($1)
5143
AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
5144
AC_LIBTOOL_PROG_LD_SHLIBS($1)
5145
AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
5146
AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
5148
AC_LIBTOOL_CONFIG($1)
5152
])# AC_LIBTOOL_LANG_GCJ_CONFIG
5155
# AC_LIBTOOL_LANG_RC_CONFIG
5156
# -------------------------
5157
# Ensure that the configuration vars for the Windows resource compiler are
5158
# suitably defined. Those variables are subsequently used by
5159
# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
5160
AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG], [_LT_AC_LANG_RC_CONFIG(RC)])
5161
AC_DEFUN([_LT_AC_LANG_RC_CONFIG],
5164
# Source file extension for RC test sources.
5167
# Object file extension for compiled RC test sources.
5169
_LT_AC_TAGVAR(objext, $1)=$objext
5171
# Code to be used in simple compile tests
5172
lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }'
5174
# Code to be used in simple link tests
5175
lt_simple_link_test_code="$lt_simple_compile_test_code"
5177
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
5180
# save warnings/boilerplate of simple test code
5181
_LT_COMPILER_BOILERPLATE
5182
_LT_LINKER_BOILERPLATE
5184
# Allow CC to be a program name with arguments.
5188
_LT_AC_TAGVAR(compiler, $1)=$CC
5189
_LT_CC_BASENAME([$compiler])
5190
_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
5192
AC_LIBTOOL_CONFIG($1)
5196
])# AC_LIBTOOL_LANG_RC_CONFIG
5199
# AC_LIBTOOL_CONFIG([TAGNAME])
5200
# ----------------------------
5201
# If TAGNAME is not passed, then create an initial libtool script
5202
# with a default configuration from the untagged config vars. Otherwise
5203
# add code to config.status for appending the configuration named by
5204
# TAGNAME from the matching tagged config vars.
5205
AC_DEFUN([AC_LIBTOOL_CONFIG],
5206
[# The else clause should only fire when bootstrapping the
5207
# libtool distribution, otherwise you forgot to ship ltmain.sh
5208
# with your package, and you will get complaints that there are
5209
# no rules to generate ltmain.sh.
5210
if test -f "$ltmain"; then
5211
# See if we are running on zsh, and set the options which allow our commands through
5212
# without removal of \ escapes.
5213
if test -n "${ZSH_VERSION+set}" ; then
5214
setopt NO_GLOB_SUBST
5216
# Now quote all the things that may contain metacharacters while being
5217
# careful not to overquote the AC_SUBSTed values. We take copies of the
5218
# variables and quote the copies for generation of the libtool script.
5219
for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC LTCFLAGS NM \
5221
libname_spec library_names_spec soname_spec extract_expsyms_cmds \
5222
old_striplib striplib file_magic_cmd finish_cmds finish_eval \
5223
deplibs_check_method reload_flag reload_cmds need_locks \
5224
lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \
5225
lt_cv_sys_global_symbol_to_c_name_address \
5226
sys_lib_search_path_spec sys_lib_dlsearch_path_spec \
5227
old_postinstall_cmds old_postuninstall_cmds \
5228
_LT_AC_TAGVAR(compiler, $1) \
5229
_LT_AC_TAGVAR(CC, $1) \
5230
_LT_AC_TAGVAR(LD, $1) \
5231
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1) \
5232
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) \
5233
_LT_AC_TAGVAR(lt_prog_compiler_static, $1) \
5234
_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) \
5235
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1) \
5236
_LT_AC_TAGVAR(thread_safe_flag_spec, $1) \
5237
_LT_AC_TAGVAR(whole_archive_flag_spec, $1) \
5238
_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1) \
5239
_LT_AC_TAGVAR(old_archive_cmds, $1) \
5240
_LT_AC_TAGVAR(old_archive_from_new_cmds, $1) \
5241
_LT_AC_TAGVAR(predep_objects, $1) \
5242
_LT_AC_TAGVAR(postdep_objects, $1) \
5243
_LT_AC_TAGVAR(predeps, $1) \
5244
_LT_AC_TAGVAR(postdeps, $1) \
5245
_LT_AC_TAGVAR(compiler_lib_search_path, $1) \
5246
_LT_AC_TAGVAR(compiler_lib_search_dirs, $1) \
5247
_LT_AC_TAGVAR(archive_cmds, $1) \
5248
_LT_AC_TAGVAR(archive_expsym_cmds, $1) \
5249
_LT_AC_TAGVAR(postinstall_cmds, $1) \
5250
_LT_AC_TAGVAR(postuninstall_cmds, $1) \
5251
_LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) \
5252
_LT_AC_TAGVAR(allow_undefined_flag, $1) \
5253
_LT_AC_TAGVAR(no_undefined_flag, $1) \
5254
_LT_AC_TAGVAR(export_symbols_cmds, $1) \
5255
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) \
5256
_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1) \
5257
_LT_AC_TAGVAR(hardcode_libdir_separator, $1) \
5258
_LT_AC_TAGVAR(hardcode_automatic, $1) \
5259
_LT_AC_TAGVAR(module_cmds, $1) \
5260
_LT_AC_TAGVAR(module_expsym_cmds, $1) \
5261
_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1) \
5262
_LT_AC_TAGVAR(fix_srcfile_path, $1) \
5263
_LT_AC_TAGVAR(exclude_expsyms, $1) \
5264
_LT_AC_TAGVAR(include_expsyms, $1); do
5267
_LT_AC_TAGVAR(old_archive_cmds, $1) | \
5268
_LT_AC_TAGVAR(old_archive_from_new_cmds, $1) | \
5269
_LT_AC_TAGVAR(archive_cmds, $1) | \
5270
_LT_AC_TAGVAR(archive_expsym_cmds, $1) | \
5271
_LT_AC_TAGVAR(module_cmds, $1) | \
5272
_LT_AC_TAGVAR(module_expsym_cmds, $1) | \
5273
_LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) | \
5274
_LT_AC_TAGVAR(export_symbols_cmds, $1) | \
5275
extract_expsyms_cmds | reload_cmds | finish_cmds | \
5276
postinstall_cmds | postuninstall_cmds | \
5277
old_postinstall_cmds | old_postuninstall_cmds | \
5278
sys_lib_search_path_spec | sys_lib_dlsearch_path_spec)
5279
# Double-quote double-evaled strings.
5280
eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\""
5283
eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\""
5289
*'\[$]0 --fallback-echo"')
5290
lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\[$]0 --fallback-echo"[$]/[$]0 --fallback-echo"/'`
5295
[cfgfile="${ofile}T"
5296
trap "$rm \"$cfgfile\"; exit 1" 1 2 15
5298
AC_MSG_NOTICE([creating $ofile])],
5301
cat <<__EOF__ >> "$cfgfile"
5305
# `$echo "$cfgfile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
5306
# Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP)
5307
# NOTE: Changes made to this file will be lost: look at ltmain.sh.
5309
# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
5310
# Free Software Foundation, Inc.
5312
# This file is part of GNU Libtool:
5313
# Originally by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
5315
# This program is free software; you can redistribute it and/or modify
5316
# it under the terms of the GNU General Public License as published by
5317
# the Free Software Foundation; either version 2 of the License, or
5318
# (at your option) any later version.
5320
# This program is distributed in the hope that it will be useful, but
5321
# WITHOUT ANY WARRANTY; without even the implied warranty of
5322
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
5323
# General Public License for more details.
5325
# You should have received a copy of the GNU General Public License
5326
# along with this program; if not, write to the Free Software
5327
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
5329
# As a special exception to the GNU General Public License, if you
5330
# distribute this file as part of a program that contains a
5331
# configuration script generated by Autoconf, you may include it under
5332
# the same distribution terms that you use for the rest of that program.
5334
# A sed program that does not truncate output.
5337
# Sed that helps us avoid accidentally triggering echo(1) options like -n.
5338
Xsed="$SED -e 1s/^X//"
5340
# The HP-UX ksh and POSIX shell print the target directory to stdout
5342
(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
5344
# The names of the tagged configurations supported by this script.
5347
# ### BEGIN LIBTOOL CONFIG],
5348
[# ### BEGIN LIBTOOL TAG CONFIG: $tagname])
5350
# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
5352
# Shell to use when invoking shell scripts.
5355
# Whether or not to build shared libraries.
5356
build_libtool_libs=$enable_shared
5358
# Whether or not to build static libraries.
5359
build_old_libs=$enable_static
5361
# Whether or not to add -lc for building shared libraries.
5362
build_libtool_need_lc=$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)
5364
# Whether or not to disallow shared libs when runtime libs are static
5365
allow_libtool_libs_with_static_runtimes=$_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)
5367
# Whether or not to optimize for fast installation.
5368
fast_install=$enable_fast_install
5371
host_alias=$host_alias
5376
build_alias=$build_alias
5380
# An echo program that does not interpret backslashes.
5385
AR_FLAGS=$lt_AR_FLAGS
5390
# LTCC compiler flags.
5391
LTCFLAGS=$lt_LTCFLAGS
5393
# A language-specific compiler.
5394
CC=$lt_[]_LT_AC_TAGVAR(compiler, $1)
5396
# Is the compiler the GNU C compiler?
5397
with_gcc=$_LT_AC_TAGVAR(GCC, $1)
5402
# The linker used to build libraries.
5403
LD=$lt_[]_LT_AC_TAGVAR(LD, $1)
5405
# Whether we need hard or soft links.
5408
# A BSD-compatible nm program.
5411
# A symbol stripping program
5414
# Used to examine libraries when file_magic_cmd begins "file"
5415
MAGIC_CMD=$MAGIC_CMD
5417
# Used on cygwin: DLL creation program.
5420
# Used on cygwin: object dumper.
5423
# Used on cygwin: assembler.
5426
# The name of the directory that contains temporary libtool files.
5429
# How to create reloadable object files.
5430
reload_flag=$lt_reload_flag
5431
reload_cmds=$lt_reload_cmds
5433
# How to pass a linker flag through the compiler.
5434
wl=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)
5436
# Object file suffix (normally "o").
5439
# Old archive suffix (normally "a").
5442
# Shared library suffix (normally ".so").
5443
shrext_cmds='$shrext_cmds'
5445
# Executable file suffix (normally "").
5448
# Additional compiler flags for building library objects.
5449
pic_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)
5452
# What is the maximum length of a command?
5453
max_cmd_len=$lt_cv_sys_max_cmd_len
5455
# Does compiler simultaneously support -c and -o options?
5456
compiler_c_o=$lt_[]_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)
5458
# Must we lock files when doing compilation?
5459
need_locks=$lt_need_locks
5461
# Do we need the lib prefix for modules?
5462
need_lib_prefix=$need_lib_prefix
5464
# Do we need a version for libraries?
5465
need_version=$need_version
5467
# Whether dlopen is supported.
5468
dlopen_support=$enable_dlopen
5470
# Whether dlopen of programs is supported.
5471
dlopen_self=$enable_dlopen_self
5473
# Whether dlopen of statically linked programs is supported.
5474
dlopen_self_static=$enable_dlopen_self_static
5476
# Compiler flag to prevent dynamic linking.
5477
link_static_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_static, $1)
5479
# Compiler flag to turn off builtin functions.
5480
no_builtin_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)
5482
# Compiler flag to allow reflexive dlopens.
5483
export_dynamic_flag_spec=$lt_[]_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)
5485
# Compiler flag to generate shared objects directly from archives.
5486
whole_archive_flag_spec=$lt_[]_LT_AC_TAGVAR(whole_archive_flag_spec, $1)
5488
# Compiler flag to generate thread-safe objects.
5489
thread_safe_flag_spec=$lt_[]_LT_AC_TAGVAR(thread_safe_flag_spec, $1)
5491
# Library versioning type.
5492
version_type=$version_type
5494
# Format of library name prefix.
5495
libname_spec=$lt_libname_spec
5497
# List of archive names. First name is the real one, the rest are links.
5498
# The last name is the one that the linker finds with -lNAME.
5499
library_names_spec=$lt_library_names_spec
5501
# The coded name of the library, if different from the real name.
5502
soname_spec=$lt_soname_spec
5504
# Commands used to build and install an old-style archive.
5506
old_archive_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_cmds, $1)
5507
old_postinstall_cmds=$lt_old_postinstall_cmds
5508
old_postuninstall_cmds=$lt_old_postuninstall_cmds
5510
# Create an old-style archive from a shared archive.
5511
old_archive_from_new_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_from_new_cmds, $1)
5513
# Create a temporary old-style archive to link instead of a shared archive.
5514
old_archive_from_expsyms_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1)
5516
# Commands used to build and install a shared archive.
5517
archive_cmds=$lt_[]_LT_AC_TAGVAR(archive_cmds, $1)
5518
archive_expsym_cmds=$lt_[]_LT_AC_TAGVAR(archive_expsym_cmds, $1)
5519
postinstall_cmds=$lt_postinstall_cmds
5520
postuninstall_cmds=$lt_postuninstall_cmds
5522
# Commands used to build a loadable module (assumed same as above if empty)
5523
module_cmds=$lt_[]_LT_AC_TAGVAR(module_cmds, $1)
5524
module_expsym_cmds=$lt_[]_LT_AC_TAGVAR(module_expsym_cmds, $1)
5526
# Commands to strip libraries.
5527
old_striplib=$lt_old_striplib
5528
striplib=$lt_striplib
5530
# Dependencies to place before the objects being linked to create a
5532
predep_objects=$lt_[]_LT_AC_TAGVAR(predep_objects, $1)
5534
# Dependencies to place after the objects being linked to create a
5536
postdep_objects=$lt_[]_LT_AC_TAGVAR(postdep_objects, $1)
5538
# Dependencies to place before the objects being linked to create a
5540
predeps=$lt_[]_LT_AC_TAGVAR(predeps, $1)
5542
# Dependencies to place after the objects being linked to create a
5544
postdeps=$lt_[]_LT_AC_TAGVAR(postdeps, $1)
5546
# The directories searched by this compiler when creating a shared
5548
compiler_lib_search_dirs=$lt_[]_LT_AC_TAGVAR(compiler_lib_search_dirs, $1)
5550
# The library search path used internally by the compiler when linking
5552
compiler_lib_search_path=$lt_[]_LT_AC_TAGVAR(compiler_lib_search_path, $1)
5554
# Method to check whether dependent libraries are shared objects.
5555
deplibs_check_method=$lt_deplibs_check_method
5557
# Command to use when deplibs_check_method == file_magic.
5558
file_magic_cmd=$lt_file_magic_cmd
5560
# Flag that allows shared libraries with undefined symbols to be built.
5561
allow_undefined_flag=$lt_[]_LT_AC_TAGVAR(allow_undefined_flag, $1)
5563
# Flag that forces no undefined symbols.
5564
no_undefined_flag=$lt_[]_LT_AC_TAGVAR(no_undefined_flag, $1)
5566
# Commands used to finish a libtool library installation in a directory.
5567
finish_cmds=$lt_finish_cmds
5569
# Same as above, but a single script fragment to be evaled but not shown.
5570
finish_eval=$lt_finish_eval
5572
# Take the output of nm and produce a listing of raw symbols and C names.
5573
global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
5575
# Transform the output of nm in a proper C declaration
5576
global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
5578
# Transform the output of nm in a C name address pair
5579
global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
5581
# This is the shared library runtime path variable.
5582
runpath_var=$runpath_var
5584
# This is the shared library path variable.
5585
shlibpath_var=$shlibpath_var
5587
# Is shlibpath searched before the hard-coded library search path?
5588
shlibpath_overrides_runpath=$shlibpath_overrides_runpath
5590
# How to hardcode a shared library path into an executable.
5591
hardcode_action=$_LT_AC_TAGVAR(hardcode_action, $1)
5593
# Whether we should hardcode library paths into libraries.
5594
hardcode_into_libs=$hardcode_into_libs
5596
# Flag to hardcode \$libdir into a binary during linking.
5597
# This must work even if \$libdir does not exist.
5598
hardcode_libdir_flag_spec=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)
5600
# If ld is used when linking, flag to hardcode \$libdir into
5601
# a binary during linking. This must work even if \$libdir does
5603
hardcode_libdir_flag_spec_ld=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)
5605
# Whether we need a single -rpath flag with a separated argument.
5606
hardcode_libdir_separator=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_separator, $1)
5608
# Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the
5610
hardcode_direct=$_LT_AC_TAGVAR(hardcode_direct, $1)
5612
# Set to yes if using the -LDIR flag during linking hardcodes DIR into the
5614
hardcode_minus_L=$_LT_AC_TAGVAR(hardcode_minus_L, $1)
5616
# Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into
5617
# the resulting binary.
5618
hardcode_shlibpath_var=$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)
5620
# Set to yes if building a shared library automatically hardcodes DIR into the library
5621
# and all subsequent libraries and executables linked against it.
5622
hardcode_automatic=$_LT_AC_TAGVAR(hardcode_automatic, $1)
5624
# Variables whose values should be saved in libtool wrapper scripts and
5625
# restored at relink time.
5626
variables_saved_for_relink="$variables_saved_for_relink"
5628
# Whether libtool must link a program against all its dependency libraries.
5629
link_all_deplibs=$_LT_AC_TAGVAR(link_all_deplibs, $1)
5631
# Compile-time system search path for libraries
5632
sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
5634
# Run-time system search path for libraries
5635
sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
5637
# Fix the shell variable \$srcfile for the compiler.
5638
fix_srcfile_path=$lt_fix_srcfile_path
5640
# Set to yes if exported symbols are required.
5641
always_export_symbols=$_LT_AC_TAGVAR(always_export_symbols, $1)
5643
# The commands to list exported symbols.
5644
export_symbols_cmds=$lt_[]_LT_AC_TAGVAR(export_symbols_cmds, $1)
5646
# The commands to extract the exported symbol list from a shared archive.
5647
extract_expsyms_cmds=$lt_extract_expsyms_cmds
5649
# Symbols that should not be listed in the preloaded symbols.
5650
exclude_expsyms=$lt_[]_LT_AC_TAGVAR(exclude_expsyms, $1)
5652
# Symbols that must always be exported.
5653
include_expsyms=$lt_[]_LT_AC_TAGVAR(include_expsyms, $1)
5656
[# ### END LIBTOOL CONFIG],
5657
[# ### END LIBTOOL TAG CONFIG: $tagname])
5664
cat <<\EOF >> "$cfgfile"
5666
# AIX sometimes has problems with the GCC collect2 program. For some
5667
# reason, if we set the COLLECT_NAMES environment variable, the problems
5668
# vanish in a puff of smoke.
5669
if test "X${COLLECT_NAMES+set}" != Xset; then
5671
export COLLECT_NAMES
5677
# We use sed instead of cat because bash on DJGPP gets confused if
5678
# if finds mixed CR/LF and LF-only lines. Since sed operates in
5679
# text mode, it properly converts lines to CR/LF. This bash problem
5680
# is reportedly fixed, but why not run on old versions too?
5681
sed '$q' "$ltmain" >> "$cfgfile" || (rm -f "$cfgfile"; exit 1)
5683
mv -f "$cfgfile" "$ofile" || \
5684
(rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
5688
# If there is no Makefile yet, we rely on a make rule to execute
5689
# `config.status --recheck' to rerun these tests and create the
5690
# libtool script then.
5691
ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'`
5692
if test -f "$ltmain_in"; then
5693
test -f Makefile && make "$ltmain"
5696
])# AC_LIBTOOL_CONFIG
5699
# AC_LIBTOOL_PROG_COMPILER_NO_RTTI([TAGNAME])
5700
# -------------------------------------------
5701
AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI],
5702
[AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl
5704
_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
5706
if test "$GCC" = yes; then
5707
_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
5709
AC_LIBTOOL_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions],
5710
lt_cv_prog_compiler_rtti_exceptions,
5711
[-fno-rtti -fno-exceptions], [],
5712
[_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"])
5714
])# AC_LIBTOOL_PROG_COMPILER_NO_RTTI
5717
# AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
5718
# ---------------------------------
5719
AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE],
5720
[AC_REQUIRE([AC_CANONICAL_HOST])
5721
AC_REQUIRE([LT_AC_PROG_SED])
5722
AC_REQUIRE([AC_PROG_NM])
5723
AC_REQUIRE([AC_OBJEXT])
5724
# Check for command to grab the raw symbol name followed by C symbol from nm.
5725
AC_MSG_CHECKING([command to parse $NM output from $compiler object])
5726
AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe],
5728
# These are sane defaults that work on at least a few old systems.
5729
# [They come from Ultrix. What could be older than Ultrix?!! ;)]
5731
# Character class describing NM global symbol codes.
5732
symcode='[[BCDEGRST]]'
5734
# Regexp to match symbols that can be accessed directly from C.
5735
sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)'
5737
# Transform an extracted symbol line into a proper C declaration
5738
lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern int \1;/p'"
5740
# Transform an extracted symbol line into symbol name and symbol address
5741
lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'"
5743
# Define system-specific variables.
5748
cygwin* | mingw* | pw32*)
5749
symcode='[[ABCDGISTW]]'
5751
hpux*) # Its linker distinguishes data from code symbols
5752
if test "$host_cpu" = ia64; then
5753
symcode='[[ABCDEGRST]]'
5755
lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
5756
lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'"
5758
linux* | k*bsd*-gnu)
5759
if test "$host_cpu" = ia64; then
5760
symcode='[[ABCDGIRSTW]]'
5761
lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
5762
lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'"
5766
symcode='[[BCDEGRST]]'
5769
symcode='[[BCDEGQRST]]'
5780
sysv5* | sco5v6* | unixware* | OpenUNIX*)
5784
symcode='[[DFNSTU]]'
5788
# Handle CRLF in mingw tool chain
5792
opt_cr=`echo 'x\{0,1\}' | tr x '\015'` # option cr in regexp
5796
# If we're using GNU nm, then use its standard symbol codes.
5797
case `$NM -V 2>&1` in
5798
*GNU* | *'with BFD'*)
5799
symcode='[[ABCDGIRSTW]]' ;;
5802
# Try without a prefix undercore, then with it.
5803
for ac_symprfx in "" "_"; do
5805
# Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
5806
symxfrm="\\1 $ac_symprfx\\2 \\2"
5808
# Write the raw and C identifiers.
5809
lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
5811
# Check to see that the pipe works correctly.
5815
cat > conftest.$ac_ext <<EOF
5820
void nm_test_func(){}
5824
int main(){nm_test_var='a';nm_test_func();return(0);}
5827
if AC_TRY_EVAL(ac_compile); then
5828
# Now try to grab the symbols.
5830
if AC_TRY_EVAL(NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) && test -s "$nlist"; then
5831
# Try sorting and uniquifying the output.
5832
if sort "$nlist" | uniq > "$nlist"T; then
5833
mv -f "$nlist"T "$nlist"
5838
# Make sure that we snagged all the symbols we need.
5839
if grep ' nm_test_var$' "$nlist" >/dev/null; then
5840
if grep ' nm_test_func$' "$nlist" >/dev/null; then
5841
cat <<EOF > conftest.$ac_ext
5847
# Now generate the symbol file.
5848
eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | grep -v main >> conftest.$ac_ext'
5850
cat <<EOF >> conftest.$ac_ext
5851
#if defined (__STDC__) && __STDC__
5852
# define lt_ptr_t void *
5854
# define lt_ptr_t char *
5858
/* The mapping between symbol names and symbols. */
5863
lt_preloaded_symbols[[]] =
5866
$SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (lt_ptr_t) \&\2},/" < "$nlist" | grep -v main >> conftest.$ac_ext
5867
cat <<\EOF >> conftest.$ac_ext
5875
# Now try linking the two files.
5876
mv conftest.$ac_objext conftstm.$ac_objext
5877
lt_save_LIBS="$LIBS"
5878
lt_save_CFLAGS="$CFLAGS"
5879
LIBS="conftstm.$ac_objext"
5880
CFLAGS="$CFLAGS$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)"
5881
if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then
5884
LIBS="$lt_save_LIBS"
5885
CFLAGS="$lt_save_CFLAGS"
5887
echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD
5890
echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD
5893
echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD
5896
echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD
5897
cat conftest.$ac_ext >&5
5899
rm -rf conftest* conftst*
5901
# Do not use the global_symbol_pipe unless it works.
5902
if test "$pipe_works" = yes; then
5905
lt_cv_sys_global_symbol_pipe=
5909
if test -z "$lt_cv_sys_global_symbol_pipe"; then
5910
lt_cv_sys_global_symbol_to_cdecl=
5912
if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
5913
AC_MSG_RESULT(failed)
5917
]) # AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
5920
# AC_LIBTOOL_PROG_COMPILER_PIC([TAGNAME])
5921
# ---------------------------------------
5922
AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC],
5923
[_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)=
5924
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
5925
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)=
5927
AC_MSG_CHECKING([for $compiler option to produce PIC])
5929
# C++ specific cases for pic, static, wl, etc.
5930
if test "$GXX" = yes; then
5931
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
5932
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
5936
# All AIX code is PIC.
5937
if test "$host_cpu" = ia64; then
5938
# AIX 5 now supports IA64 processor
5939
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
5943
# FIXME: we need at least 68020 code to build shared libraries, but
5944
# adding the `-m68020' flag to GCC prevents building anything better,
5946
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
5948
beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
5949
# PIC is the default for these OSes.
5951
mingw* | cygwin* | os2* | pw32*)
5952
# This hack is so that the source file can tell whether it is being
5953
# built for inclusion in a dll (and should export symbols for example).
5954
# Although the cygwin gcc ignores -fPIC, still need this for old-style
5955
# (--disable-auto-import) libraries
5956
m4_if([$1], [GCJ], [],
5957
[_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
5959
darwin* | rhapsody*)
5960
# PIC is the default on this platform
5961
# Common symbols not allowed in MH_DYLIB files
5962
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
5965
# DJGPP does not support shared libraries at all
5966
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
5969
# Interix 3.x gcc -fpic/-fPIC options generate broken code.
5970
# Instead, we relocate shared libraries at runtime.
5973
if test -d /usr/nec; then
5974
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
5978
# PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
5984
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5989
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
5995
# All AIX code is PIC.
5996
if test "$host_cpu" = ia64; then
5997
# AIX 5 now supports IA64 processor
5998
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6000
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
6004
case $cc_basename in
6006
# Green Hills C++ Compiler
6007
# _LT_AC_TAGVAR(lt_prog_compiler_static, $1)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a"
6012
# PIC is the default on this platform
6013
# Common symbols not allowed in MH_DYLIB files
6014
case $cc_basename in
6016
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-qnocommon'
6017
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6022
case $cc_basename in
6024
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6027
# Green Hills C++ Compiler
6028
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
6034
freebsd* | dragonfly*)
6035
# FreeBSD uses GNU C++
6037
hpux9* | hpux10* | hpux11*)
6038
case $cc_basename in
6040
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6041
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
6042
if test "$host_cpu" != ia64; then
6043
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
6047
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6048
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
6054
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
6063
# This is c89, which is MS Visual C++ (no shared libs)
6064
# Anyone wants to do a port?
6066
irix5* | irix6* | nonstopux*)
6067
case $cc_basename in
6069
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6070
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
6071
# CC pic flag -KPIC is the default.
6077
linux* | k*bsd*-gnu)
6078
case $cc_basename in
6081
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
6082
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
6086
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6087
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6088
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
6091
# Portland Group C++ compiler.
6092
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6093
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
6094
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6098
# Make sure the PIC flag is empty. It appears that all Alpha
6099
# Linux and Compaq Tru64 Unix objects are PIC.
6100
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
6101
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
6104
case `$CC -V 2>&1 | sed 5q` in
6107
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6108
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6109
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
6120
case $cc_basename in
6122
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall'
6128
netbsd* | netbsdelf*-gnu)
6130
osf3* | osf4* | osf5*)
6131
case $cc_basename in
6133
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
6136
# Rational C++ 2.4.1
6137
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
6140
# Digital/Compaq C++
6141
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6142
# Make sure the PIC flag is empty. It appears that all Alpha
6143
# Linux and Compaq Tru64 Unix objects are PIC.
6144
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
6145
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
6154
case $cc_basename in
6156
# Sun C++ 4.2, 5.x and Centerline C++
6157
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6158
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6159
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
6162
# Green Hills C++ Compiler
6163
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
6170
case $cc_basename in
6173
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
6174
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6178
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
6185
case $cc_basename in
6187
# NonStop-UX NCC 3.20
6188
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6194
sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
6195
case $cc_basename in
6197
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6198
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6199
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6206
_LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
6212
if test "$GCC" = yes; then
6213
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6214
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
6218
# All AIX code is PIC.
6219
if test "$host_cpu" = ia64; then
6220
# AIX 5 now supports IA64 processor
6221
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6226
# FIXME: we need at least 68020 code to build shared libraries, but
6227
# adding the `-m68020' flag to GCC prevents building anything better,
6229
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
6232
beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
6233
# PIC is the default for these OSes.
6236
mingw* | cygwin* | pw32* | os2*)
6237
# This hack is so that the source file can tell whether it is being
6238
# built for inclusion in a dll (and should export symbols for example).
6239
# Although the cygwin gcc ignores -fPIC, still need this for old-style
6240
# (--disable-auto-import) libraries
6241
m4_if([$1], [GCJ], [],
6242
[_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
6245
darwin* | rhapsody*)
6246
# PIC is the default on this platform
6247
# Common symbols not allowed in MH_DYLIB files
6248
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
6252
# Interix 3.x gcc -fpic/-fPIC options generate broken code.
6253
# Instead, we relocate shared libraries at runtime.
6257
# Just because we use GCC doesn't mean we suddenly get shared libraries
6258
# on systems that don't support them.
6259
_LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
6264
if test -d /usr/nec; then
6265
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
6270
# PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
6277
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
6283
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
6287
# PORTME Check for flag to pass linker flags through the system compiler.
6290
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6291
if test "$host_cpu" = ia64; then
6292
# AIX 5 now supports IA64 processor
6293
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6295
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
6299
# PIC is the default on this platform
6300
# Common symbols not allowed in MH_DYLIB files
6301
case $cc_basename in
6303
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-qnocommon'
6304
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6309
mingw* | cygwin* | pw32* | os2*)
6310
# This hack is so that the source file can tell whether it is being
6311
# built for inclusion in a dll (and should export symbols for example).
6312
m4_if([$1], [GCJ], [],
6313
[_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
6316
hpux9* | hpux10* | hpux11*)
6317
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6318
# PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
6325
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
6328
# Is there a better lt_prog_compiler_static that works with the bundled CC?
6329
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
6332
irix5* | irix6* | nonstopux*)
6333
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6334
# PIC (with -KPIC) is the default.
6335
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
6339
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6340
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6343
linux* | k*bsd*-gnu)
6344
case $cc_basename in
6346
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6347
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6348
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
6350
pgcc* | pgf77* | pgf90* | pgf95*)
6351
# Portland Group compilers (*not* the Pentium gcc compiler,
6352
# which looks to be a dead project)
6353
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6354
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
6355
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6358
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6359
# All Alpha code is PIC.
6360
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
6363
case `$CC -V 2>&1 | sed 5q` in
6366
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6367
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6368
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6371
# Sun Fortran 8.3 passes all unrecognized flags to the linker
6372
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6373
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6374
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)=''
6381
osf3* | osf4* | osf5*)
6382
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6383
# All OSF/1 code is PIC.
6384
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
6388
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
6392
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6393
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6394
case $cc_basename in
6396
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';;
6398
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';;
6403
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
6404
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
6405
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6408
sysv4 | sysv4.2uw2* | sysv4.3*)
6409
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6410
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6411
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6415
if test -d /usr/nec ;then
6416
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic'
6417
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6421
sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
6422
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6423
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
6424
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6428
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
6429
_LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
6433
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
6434
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
6438
_LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
6443
AC_MSG_RESULT([$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)])
6446
# Check to make sure the PIC flag actually works.
6448
if test -n "$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)"; then
6449
AC_LIBTOOL_COMPILER_OPTION([if $compiler PIC flag $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) works],
6450
_LT_AC_TAGVAR(lt_cv_prog_compiler_pic_works, $1),
6451
[$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])], [],
6452
[case $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) in
6454
*) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)" ;;
6456
[_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
6457
_LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no])
6460
# For platforms which do not support PIC, -DPIC is meaningless:
6462
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
6465
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])"
6470
# Check to make sure the static flag actually works.
6472
wl=$_LT_AC_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_AC_TAGVAR(lt_prog_compiler_static, $1)\"
6473
AC_LIBTOOL_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works],
6474
_LT_AC_TAGVAR(lt_cv_prog_compiler_static_works, $1),
6475
$lt_tmp_static_flag,
6477
[_LT_AC_TAGVAR(lt_prog_compiler_static, $1)=])
6481
# AC_LIBTOOL_PROG_LD_SHLIBS([TAGNAME])
6482
# ------------------------------------
6483
# See if the linker supports building shared libraries.
6484
AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS],
6485
[AC_REQUIRE([LT_AC_PROG_SED])dnl
6486
AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
6488
_LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
6491
# If we're using GNU nm, then we don't want the "-C" option.
6492
# -C means demangle to AIX nm, but means don't demangle with GNU nm
6493
if $NM -V 2>&1 | grep 'GNU' > /dev/null; then
6494
_LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols'
6496
_LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols'
6500
_LT_AC_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds"
6503
_LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;/^.*[[ ]]__nm__/s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols'
6505
linux* | k*bsd*-gnu)
6506
_LT_AC_TAGVAR(link_all_deplibs, $1)=no
6509
_LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
6512
_LT_AC_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
6515
_LT_AC_TAGVAR(allow_undefined_flag, $1)=
6516
_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no
6517
_LT_AC_TAGVAR(archive_cmds, $1)=
6518
_LT_AC_TAGVAR(archive_expsym_cmds, $1)=
6519
_LT_AC_TAGVAR(old_archive_From_new_cmds, $1)=
6520
_LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1)=
6521
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
6522
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
6523
_LT_AC_TAGVAR(thread_safe_flag_spec, $1)=
6524
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
6525
_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
6526
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
6527
_LT_AC_TAGVAR(hardcode_direct, $1)=no
6528
_LT_AC_TAGVAR(hardcode_minus_L, $1)=no
6529
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
6530
_LT_AC_TAGVAR(link_all_deplibs, $1)=unknown
6531
_LT_AC_TAGVAR(hardcode_automatic, $1)=no
6532
_LT_AC_TAGVAR(module_cmds, $1)=
6533
_LT_AC_TAGVAR(module_expsym_cmds, $1)=
6534
_LT_AC_TAGVAR(always_export_symbols, $1)=no
6535
_LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
6536
# include_expsyms should be a list of space-separated symbols to be *always*
6537
# included in the symbol list
6538
_LT_AC_TAGVAR(include_expsyms, $1)=
6539
# exclude_expsyms can be an extended regexp of symbols to exclude
6540
# it will be wrapped by ` (' and `)$', so one must not match beginning or
6541
# end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
6542
# as well as any symbol that contains `d'.
6543
_LT_AC_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
6544
# Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
6545
# platforms (ab)use it in PIC code, but their linkers get confused if
6546
# the symbol is explicitly referenced. Since portable code cannot
6547
# rely on this symbol name, it's probably fine to never include it in
6548
# preloaded symbol tables.
6549
# Exclude shared library initialization/finalization symbols.
6550
dnl Note also adjust exclude_expsyms for C++ above.
6551
extract_expsyms_cmds=
6552
# Just being paranoid about ensuring that cc_basename is set.
6553
_LT_CC_BASENAME([$compiler])
6555
cygwin* | mingw* | pw32*)
6556
# FIXME: the MSVC++ port hasn't been tested in a loooong time
6557
# When not using gcc, we currently assume that we are using
6558
# Microsoft Visual C++.
6559
if test "$GCC" != yes; then
6564
# we just hope/assume this is gcc and not c89 (= MSVC++)
6572
_LT_AC_TAGVAR(ld_shlibs, $1)=yes
6573
if test "$with_gnu_ld" = yes; then
6574
# If archive_cmds runs LD, not CC, wlarc should be empty
6577
# Set some defaults for GNU ld with shared library support. These
6578
# are reset later if shared libraries are not supported. Putting them
6579
# here allows them to be overridden if necessary.
6580
runpath_var=LD_RUN_PATH
6581
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
6582
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
6583
# ancient GNU ld didn't support --whole-archive et. al.
6584
if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then
6585
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
6587
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
6589
supports_anon_versioning=no
6590
case `$LD -v 2>/dev/null` in
6591
*\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11
6592
*\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
6593
*\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
6594
*\ 2.11.*) ;; # other 2.11 versions
6595
*) supports_anon_versioning=yes ;;
6598
# See if GNU ld supports shared libraries.
6601
# On AIX/PPC, the GNU linker is very broken
6602
if test "$host_cpu" != ia64; then
6603
_LT_AC_TAGVAR(ld_shlibs, $1)=no
6606
*** Warning: the GNU linker, at least up to release 2.9.1, is reported
6607
*** to be unable to reliably create shared libraries on AIX.
6608
*** Therefore, libtool is disabling shared libraries support. If you
6609
*** really care for shared libraries, you may want to modify your PATH
6610
*** so that a non-GNU linker is found, and then restart.
6617
_LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
6618
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6619
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6621
# Samuel A. Falvo II <kc5tja@dolphin.openprojects.net> reports
6622
# that the semantics of dynamic libraries on AmigaOS, at least up
6623
# to version 4, is to share data among multiple programs linked
6624
# with the same dynamic library. Since this doesn't match the
6625
# behavior of shared libraries on other platforms, we can't use
6627
_LT_AC_TAGVAR(ld_shlibs, $1)=no
6631
if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
6632
_LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
6633
# Joseph Beckenbach <jrb3@best.com> says some releases of gcc
6634
# support --undefined. This deserves some investigation. FIXME
6635
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6637
_LT_AC_TAGVAR(ld_shlibs, $1)=no
6641
cygwin* | mingw* | pw32*)
6642
# _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
6643
# as there is no search path for DLLs.
6644
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6645
_LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
6646
_LT_AC_TAGVAR(always_export_symbols, $1)=no
6647
_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
6648
_LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/'\'' -e '\''/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols'
6650
if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
6651
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
6652
# If the export-symbols file already is a .def file (1st line
6653
# is EXPORTS), use it as is; otherwise, prepend...
6654
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
6655
cp $export_symbols $output_objdir/$soname.def;
6657
echo EXPORTS > $output_objdir/$soname.def;
6658
cat $export_symbols >> $output_objdir/$soname.def;
6660
$CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
6662
_LT_AC_TAGVAR(ld_shlibs, $1)=no
6667
_LT_AC_TAGVAR(hardcode_direct, $1)=no
6668
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6669
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6670
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6671
# Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
6672
# Instead, shared libraries are loaded at an image base (0x10000000 by
6673
# default) and relocated if they conflict, which is a slow very memory
6674
# consuming and fragmenting process. To avoid this, we pick a random,
6675
# 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
6676
# time. Moving up from 0x10000000 also allows more sbrk(2) space.
6677
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
6678
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
6681
gnu* | linux* | k*bsd*-gnu)
6682
if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
6684
case $cc_basename,$host_cpu in
6685
pgcc*) # Portland Group C compiler
6686
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
6687
tmp_addflag=' $pic_flag'
6689
pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers
6690
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
6691
tmp_addflag=' $pic_flag -Mnomain' ;;
6692
ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64
6693
tmp_addflag=' -i_dynamic' ;;
6694
efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64
6695
tmp_addflag=' -i_dynamic -nofor_main' ;;
6696
ifc* | ifort*) # Intel Fortran compiler
6697
tmp_addflag=' -nofor_main' ;;
6699
case `$CC -V 2>&1 | sed 5q` in
6700
*Sun\ C*) # Sun C 5.9
6701
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
6702
tmp_sharedflag='-G' ;;
6703
*Sun\ F*) # Sun Fortran 8.3
6704
tmp_sharedflag='-G' ;;
6706
tmp_sharedflag='-shared' ;;
6708
_LT_AC_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6710
if test $supports_anon_versioning = yes; then
6711
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $output_objdir/$libname.ver~
6712
cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
6713
$echo "local: *; };" >> $output_objdir/$libname.ver~
6714
$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
6716
_LT_AC_TAGVAR(link_all_deplibs, $1)=no
6718
_LT_AC_TAGVAR(ld_shlibs, $1)=no
6722
netbsd* | netbsdelf*-gnu)
6723
if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
6724
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
6727
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6728
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
6733
if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then
6734
_LT_AC_TAGVAR(ld_shlibs, $1)=no
6737
*** Warning: The releases 2.8.* of the GNU linker cannot reliably
6738
*** create shared libraries on Solaris systems. Therefore, libtool
6739
*** is disabling shared libraries support. We urge you to upgrade GNU
6740
*** binutils to release 2.9.1 or newer. Another option is to modify
6741
*** your PATH or compiler configuration so that the native linker is
6742
*** used, and then restart.
6745
elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
6746
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6747
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
6749
_LT_AC_TAGVAR(ld_shlibs, $1)=no
6753
sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
6754
case `$LD -v 2>&1` in
6755
*\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*)
6756
_LT_AC_TAGVAR(ld_shlibs, $1)=no
6759
*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
6760
*** reliably create shared libraries on SCO systems. Therefore, libtool
6761
*** is disabling shared libraries support. We urge you to upgrade GNU
6762
*** binutils to release 2.16.91.0.3 or newer. Another option is to modify
6763
*** your PATH or compiler configuration so that the native linker is
6764
*** used, and then restart.
6769
if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
6770
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-rpath,$libdir`'
6771
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib'
6772
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname,-retain-symbols-file,$export_symbols -o $lib'
6774
_LT_AC_TAGVAR(ld_shlibs, $1)=no
6781
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
6783
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
6784
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
6788
if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
6789
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6790
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
6792
_LT_AC_TAGVAR(ld_shlibs, $1)=no
6797
if test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no; then
6799
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
6800
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
6801
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
6804
# PORTME fill in a description of your system's linker (not GNU ld)
6807
_LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
6808
_LT_AC_TAGVAR(always_export_symbols, $1)=yes
6809
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname'
6810
# Note: this linker hardcodes the directories in LIBPATH if there
6811
# are no directories specified by -L.
6812
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6813
if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
6814
# Neither direct hardcoding nor static linking is supported with a
6816
_LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
6821
if test "$host_cpu" = ia64; then
6822
# On IA64, the linker does run time linking by default, so we don't
6823
# have to do anything special.
6824
aix_use_runtimelinking=no
6825
exp_sym_flag='-Bexport'
6828
# If we're using GNU nm, then we don't want the "-C" option.
6829
# -C means demangle to AIX nm, but means don't demangle with GNU nm
6830
if $NM -V 2>&1 | grep 'GNU' > /dev/null; then
6831
_LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols'
6833
_LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols'
6835
aix_use_runtimelinking=no
6837
# Test if we are trying to use run time linking or normal
6838
# AIX style linking. If -brtl is somewhere in LDFLAGS, we
6839
# need to do runtime linking.
6840
case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
6841
for ld_flag in $LDFLAGS; do
6842
if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
6843
aix_use_runtimelinking=yes
6850
exp_sym_flag='-bexport'
6851
no_entry_flag='-bnoentry'
6854
# When large executables or shared objects are built, AIX ld can
6855
# have problems creating the table of contents. If linking a library
6856
# or program results in "error TOC overflow" add -mminimal-toc to
6857
# CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
6858
# enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
6860
_LT_AC_TAGVAR(archive_cmds, $1)=''
6861
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
6862
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
6863
_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
6865
if test "$GCC" = yes; then
6866
case $host_os in aix4.[[012]]|aix4.[[012]].*)
6867
# We only want to do this on AIX 4.2 and lower, the check
6868
# below for broken collect2 doesn't work under 4.3+
6869
collect2name=`${CC} -print-prog-name=collect2`
6870
if test -f "$collect2name" && \
6871
strings "$collect2name" | grep resolve_lib_name >/dev/null
6873
# We have reworked collect2
6876
# We have old collect2
6877
_LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
6878
# It fails to find uninstalled libraries when the uninstalled
6879
# path is not listed in the libpath. Setting hardcode_minus_L
6880
# to unsupported forces relinking
6881
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6882
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6883
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
6887
shared_flag='-shared'
6888
if test "$aix_use_runtimelinking" = yes; then
6889
shared_flag="$shared_flag "'${wl}-G'
6893
if test "$host_cpu" = ia64; then
6894
# VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
6895
# chokes on -Wl,-G. The following line is correct:
6898
if test "$aix_use_runtimelinking" = yes; then
6899
shared_flag='${wl}-G'
6901
shared_flag='${wl}-bM:SRE'
6906
# It seems that -bexpall does not export symbols beginning with
6907
# underscore (_), so it is better to generate a list of symbols to export.
6908
_LT_AC_TAGVAR(always_export_symbols, $1)=yes
6909
if test "$aix_use_runtimelinking" = yes; then
6910
# Warning - without using the other runtime loading flags (-brtl),
6911
# -berok will link without error, but may produce a broken library.
6912
_LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok'
6913
# Determine the default libpath from the value encoded in an empty executable.
6914
_LT_AC_SYS_LIBPATH_AIX
6915
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
6916
_LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
6918
if test "$host_cpu" = ia64; then
6919
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
6920
_LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
6921
_LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
6923
# Determine the default libpath from the value encoded in an empty executable.
6924
_LT_AC_SYS_LIBPATH_AIX
6925
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
6926
# Warning - without using the other run time loading flags,
6927
# -berok will link without error, but may produce a broken library.
6928
_LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
6929
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
6930
# Exported symbols can be pulled into shared objects from archives
6931
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
6932
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
6933
# This is similar to how AIX traditionally builds its shared libraries.
6934
_LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
6940
_LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
6941
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6942
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
6943
# see comment about different semantics on the GNU ld section
6944
_LT_AC_TAGVAR(ld_shlibs, $1)=no
6948
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic
6951
cygwin* | mingw* | pw32*)
6952
# When not using gcc, we currently assume that we are using
6953
# Microsoft Visual C++.
6954
# hardcode_libdir_flag_spec is actually meaningless, as there is
6955
# no search path for DLLs.
6956
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
6957
_LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
6958
# Tell ltmain to make .lib files, not .a files.
6960
# Tell ltmain to make .dll files, not .so files.
6962
# FIXME: Setting linknames here is a bad hack.
6963
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames='
6964
# The linker will automatically build a .lib file if we build a DLL.
6965
_LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='true'
6966
# FIXME: Should let the user specify the lib program.
6967
_LT_AC_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs'
6968
_LT_AC_TAGVAR(fix_srcfile_path, $1)='`cygpath -w "$srcfile"`'
6969
_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
6972
darwin* | rhapsody*)
6974
rhapsody* | darwin1.[[012]])
6975
_LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}suppress'
6978
if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then
6979
_LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
6981
case ${MACOSX_DEPLOYMENT_TARGET} in
6983
_LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
6986
_LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}dynamic_lookup'
6992
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
6993
_LT_AC_TAGVAR(hardcode_direct, $1)=no
6994
_LT_AC_TAGVAR(hardcode_automatic, $1)=yes
6995
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
6996
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=''
6997
_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
6998
if test "$GCC" = yes ; then
6999
output_verbose_link_cmd='echo'
7000
_LT_AC_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
7001
_LT_AC_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
7002
_LT_AC_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}"
7003
_LT_AC_TAGVAR(module_expsym_cmds, $1)="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}"
7005
case $cc_basename in
7007
output_verbose_link_cmd='echo'
7008
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring'
7009
_LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
7010
# Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
7011
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
7012
_LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
7015
_LT_AC_TAGVAR(ld_shlibs, $1)=no
7022
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
7023
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
7024
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
7028
_LT_AC_TAGVAR(ld_shlibs, $1)=no
7031
# FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
7032
# support. Future versions do this automatically, but an explicit c++rt0.o
7033
# does not break anything, and helps significantly (at the cost of a little
7036
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
7037
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
7038
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
7039
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
7042
# Unfortunately, older versions of FreeBSD 2 do not have this feature.
7044
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
7045
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
7046
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
7047
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
7050
# FreeBSD 3 and greater uses gcc -shared to do shared libraries.
7051
freebsd* | dragonfly*)
7052
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
7053
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
7054
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
7055
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
7059
if test "$GCC" = yes; then
7060
_LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
7062
_LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
7064
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
7065
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
7066
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
7068
# hardcode_minus_L: Not really in the search PATH,
7069
# but as the default location of the library.
7070
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
7071
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
7075
if test "$GCC" = yes -a "$with_gnu_ld" = no; then
7076
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
7078
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
7080
if test "$with_gnu_ld" = no; then
7081
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
7082
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
7084
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
7085
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
7087
# hardcode_minus_L: Not really in the search PATH,
7088
# but as the default location of the library.
7089
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
7094
if test "$GCC" = yes -a "$with_gnu_ld" = no; then
7097
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
7100
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
7103
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
7109
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
7112
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
7115
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
7119
if test "$with_gnu_ld" = no; then
7120
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
7121
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
7125
_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir'
7126
_LT_AC_TAGVAR(hardcode_direct, $1)=no
7127
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
7130
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
7131
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
7133
# hardcode_minus_L: Not really in the search PATH,
7134
# but as the default location of the library.
7135
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
7141
irix5* | irix6* | nonstopux*)
7142
if test "$GCC" = yes; then
7143
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
7145
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
7146
_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='-rpath $libdir'
7148
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
7149
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
7150
_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
7153
netbsd* | netbsdelf*-gnu)
7154
if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
7155
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
7157
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF
7159
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
7160
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
7161
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
7165
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
7166
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
7167
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
7168
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
7169
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
7173
if test -f /usr/libexec/ld.so; then
7174
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
7175
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
7176
if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
7177
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
7178
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
7179
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
7180
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
7183
openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*)
7184
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
7185
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
7188
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
7189
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
7194
_LT_AC_TAGVAR(ld_shlibs, $1)=no
7199
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
7200
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
7201
_LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
7202
_LT_AC_TAGVAR(archive_cmds, $1)='$echo "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$echo "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$echo DATA >> $output_objdir/$libname.def~$echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~$echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
7203
_LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
7207
if test "$GCC" = yes; then
7208
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
7209
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
7211
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
7212
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
7214
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
7215
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
7218
osf4* | osf5*) # as osf3* with the addition of -msym flag
7219
if test "$GCC" = yes; then
7220
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
7221
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
7222
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
7224
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
7225
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
7226
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~
7227
$LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~$rm $lib.exp'
7229
# Both c and cxx compiler support -rpath directly
7230
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
7232
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
7236
_LT_AC_TAGVAR(no_undefined_flag, $1)=' -z text'
7237
if test "$GCC" = yes; then
7239
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
7240
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
7241
$CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp'
7244
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
7245
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
7246
$LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
7248
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
7249
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
7251
solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
7253
# The compiler driver will combine and reorder linker options,
7254
# but understands `-z linker_flag'. GCC discards it without `$wl',
7255
# but is careful enough not to reorder.
7256
# Supported since Solaris 2.6 (maybe 2.5.1?)
7257
if test "$GCC" = yes; then
7258
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
7260
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
7264
_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
7268
if test "x$host_vendor" = xsequent; then
7269
# Use $CC to link under sequent, because it throws in some extra .o
7270
# files that make .init and .fini sections work.
7271
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
7273
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
7275
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
7276
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
7277
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
7278
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
7282
case $host_vendor in
7284
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
7285
_LT_AC_TAGVAR(hardcode_direct, $1)=yes # is this really true???
7288
## LD is ld it makes a PLAMLIB
7289
## CC just makes a GrossModule.
7290
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags'
7291
_LT_AC_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs'
7292
_LT_AC_TAGVAR(hardcode_direct, $1)=no
7295
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
7296
_LT_AC_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie
7299
runpath_var='LD_RUN_PATH'
7300
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
7304
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
7305
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
7306
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport'
7310
if test -d /usr/nec; then
7311
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
7312
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
7313
runpath_var=LD_RUN_PATH
7314
hardcode_runpath_var=yes
7315
_LT_AC_TAGVAR(ld_shlibs, $1)=yes
7319
sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
7320
_LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
7321
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
7322
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
7323
runpath_var='LD_RUN_PATH'
7325
if test "$GCC" = yes; then
7326
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7327
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7329
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7330
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7334
sysv5* | sco3.2v5* | sco5v6*)
7335
# Note: We can NOT use -z defs as we might desire, because we do not
7336
# link with -lc, and that would cause any symbols used from libc to
7337
# always be unresolved, which means just about no library would
7338
# ever link correctly. If we're not using GNU ld we use -z text
7339
# though, which does catch some bad symbols but isn't as heavy-handed
7341
_LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
7342
_LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
7343
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
7344
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
7345
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`'
7346
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
7347
_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
7348
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
7349
runpath_var='LD_RUN_PATH'
7351
if test "$GCC" = yes; then
7352
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
7353
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
7355
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
7356
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
7361
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
7362
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
7363
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
7367
_LT_AC_TAGVAR(ld_shlibs, $1)=no
7372
AC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)])
7373
test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
7376
# Do we need to explicitly link libc?
7378
case "x$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)" in
7380
# Assume -lc should be added
7381
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
7383
if test "$enable_shared" = yes && test "$GCC" = yes; then
7384
case $_LT_AC_TAGVAR(archive_cmds, $1) in
7386
# FIXME: we may have to deal with multi-command sequences.
7389
# Test whether the compiler implicitly links with -lc since on some
7390
# systems, -lgcc has to come before -lc. If gcc already passes -lc
7391
# to ld, don't add -lc before -lgcc.
7392
AC_MSG_CHECKING([whether -lc should be explicitly linked in])
7394
echo "$lt_simple_compile_test_code" > conftest.$ac_ext
7396
if AC_TRY_EVAL(ac_compile) 2>conftest.err; then
7399
libobjs=conftest.$ac_objext
7401
wl=$_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)
7402
pic_flag=$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)
7408
lt_save_allow_undefined_flag=$_LT_AC_TAGVAR(allow_undefined_flag, $1)
7409
_LT_AC_TAGVAR(allow_undefined_flag, $1)=
7410
if AC_TRY_EVAL(_LT_AC_TAGVAR(archive_cmds, $1) 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1)
7412
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
7414
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
7416
_LT_AC_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag
7418
cat conftest.err 1>&5
7421
AC_MSG_RESULT([$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)])
7427
])# AC_LIBTOOL_PROG_LD_SHLIBS
7430
# _LT_AC_FILE_LTDLL_C
7431
# -------------------
7432
# Be careful that the start marker always follows a newline.
7433
AC_DEFUN([_LT_AC_FILE_LTDLL_C], [
7434
# /* ltdll.c starts here */
7435
# #define WIN32_LEAN_AND_MEAN
7436
# #include <windows.h>
7437
# #undef WIN32_LEAN_AND_MEAN
7438
# #include <stdio.h>
7440
# #ifndef __CYGWIN__
7441
# # ifdef __CYGWIN32__
7442
# # define __CYGWIN__ __CYGWIN32__
7446
# #ifdef __cplusplus
7449
# BOOL APIENTRY DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved);
7450
# #ifdef __cplusplus
7455
# #include <cygwin/cygwin_dll.h>
7456
# DECLARE_CYGWIN_DLL( DllMain );
7458
# HINSTANCE __hDllInstance_base;
7461
# DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved)
7463
# __hDllInstance_base = hInst;
7466
# /* ltdll.c ends here */
7467
])# _LT_AC_FILE_LTDLL_C
7470
# _LT_AC_TAGVAR(VARNAME, [TAGNAME])
7471
# ---------------------------------
7472
AC_DEFUN([_LT_AC_TAGVAR], [ifelse([$2], [], [$1], [$1_$2])])
7476
AC_DEFUN([AM_PROG_LIBTOOL], [AC_PROG_LIBTOOL])
7477
AC_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)])
7478
AC_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)])
7479
AC_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)])
7480
AC_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)])
7481
AC_DEFUN([AM_PROG_LD], [AC_PROG_LD])
7482
AC_DEFUN([AM_PROG_NM], [AC_PROG_NM])
7484
# This is just to silence aclocal about the macro not being used
7485
ifelse([AC_DISABLE_FAST_INSTALL])
7487
AC_DEFUN([LT_AC_PROG_GCJ],
7488
[AC_CHECK_TOOL(GCJ, gcj, no)
7489
test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2"
7493
AC_DEFUN([LT_AC_PROG_RC],
7494
[AC_CHECK_TOOL(RC, windres, no)
7498
# Cheap backport of AS_EXECUTABLE_P and required macros
7499
# from Autoconf 2.59; we should not use $as_executable_p directly.
7503
m4_ifndef([_AS_TEST_PREPARE],
7504
[m4_defun([_AS_TEST_PREPARE],
7505
[if test -x / >/dev/null 2>&1; then
7506
as_executable_p='test -x'
7508
as_executable_p='test -f'
7510
])])# _AS_TEST_PREPARE
7514
# Check whether a file is executable.
7515
m4_ifndef([AS_EXECUTABLE_P],
7516
[m4_defun([AS_EXECUTABLE_P],
7517
[AS_REQUIRE([_AS_TEST_PREPARE])dnl
7518
$as_executable_p $1[]dnl
7519
])])# AS_EXECUTABLE_P
7521
# NOTE: This macro has been submitted for inclusion into #
7522
# GNU Autoconf as AC_PROG_SED. When it is available in #
7523
# a released version of Autoconf we should remove this #
7524
# macro and use it instead. #
7527
# Check for a fully-functional sed program, that truncates
7528
# as few characters as possible. Prefer GNU sed if found.
7529
AC_DEFUN([LT_AC_PROG_SED],
7530
[AC_MSG_CHECKING([for a sed that does not truncate output])
7531
AC_CACHE_VAL(lt_cv_path_SED,
7532
[# Loop through the user's path and test for sed and gsed.
7533
# Then use that list of sed's as ones to test for truncation.
7534
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7538
test -z "$as_dir" && as_dir=.
7539
for lt_ac_prog in sed gsed; do
7540
for ac_exec_ext in '' $ac_executable_extensions; do
7541
if AS_EXECUTABLE_P(["$as_dir/$lt_ac_prog$ac_exec_ext"]); then
7542
lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext"
7550
# Add /usr/xpg4/bin/sed as it is typically found on Solaris
7551
# along with /bin/sed that truncates output.
7552
for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do
7553
test ! -f $lt_ac_sed && continue
7554
cat /dev/null > conftest.in
7556
echo $ECHO_N "0123456789$ECHO_C" >conftest.in
7557
# Check for GNU sed and select it if it is found.
7558
if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then
7559
lt_cv_path_SED=$lt_ac_sed
7563
cat conftest.in conftest.in >conftest.tmp
7564
mv conftest.tmp conftest.in
7565
cp conftest.in conftest.nl
7567
$lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break
7568
cmp -s conftest.out conftest.nl || break
7569
# 10000 chars as input seems more than enough
7570
test $lt_ac_count -gt 10 && break
7571
lt_ac_count=`expr $lt_ac_count + 1`
7572
if test $lt_ac_count -gt $lt_ac_max; then
7573
lt_ac_max=$lt_ac_count
7574
lt_cv_path_SED=$lt_ac_sed
7581
AC_MSG_RESULT([$SED])
7584
932
# pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*-
7586
934
# Copyright © 2004 Scott James Remnant <scott@netsplit.com>.