5982
# AC_LIBTOOL_DLOPEN - enable checks for dlopen support
5983
AC_DEFUN([AC_LIBTOOL_DLOPEN], [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])])
5985
# AC_LIBTOOL_WIN32_DLL - declare package support for building win32 dll's
5986
AC_DEFUN([AC_LIBTOOL_WIN32_DLL], [AC_BEFORE([$0], [AC_LIBTOOL_SETUP])])
5988
# AC_ENABLE_SHARED - implement the --enable-shared flag
5989
# Usage: AC_ENABLE_SHARED[(DEFAULT)]
5990
# Where DEFAULT is either `yes' or `no'. If omitted, it defaults to
5912
need_locks="$enable_libtool_lock"
5917
# AC_LIBTOOL_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
5918
# [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE])
5919
# ----------------------------------------------------------------
5920
# Check whether the given compiler option works
5921
AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION],
5922
[AC_CACHE_CHECK([$1], [$2],
5924
ifelse([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4])
5925
save_CFLAGS="$CFLAGS"
5927
echo "$lt_simple_compile_test_code" > conftest.$ac_ext
5928
if (eval $ac_compile 2>conftest.err) && test -s $ac_outfile; then
5929
# The compiler can only warn and ignore the option if not recognized
5930
# So say no if there are warnings
5931
if test -s conftest.err; then
5932
# Append any errors to the config.log.
5933
cat conftest.err 1>&AS_MESSAGE_LOG_FD
5939
CFLAGS="$save_CFLAGS"
5942
if test x"[$]$2" = xyes; then
5943
ifelse([$5], , :, [$5])
5945
ifelse([$6], , :, [$6])
5947
])# AC_LIBTOOL_COMPILER_OPTION
5950
# AC_LIBTOOL_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
5951
# [ACTION-SUCCESS], [ACTION-FAILURE])
5952
# ------------------------------------------------------------
5953
# Check whether the given compiler option works
5954
AC_DEFUN([AC_LIBTOOL_LINKER_OPTION],
5955
[AC_CACHE_CHECK([$1], [$2],
5957
save_LDFLAGS="$LDFLAGS"
5958
LDFLAGS="$LDFLAGS $3"
5959
echo "$lt_simple_link_test_code" > conftest.$ac_ext
5960
if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
5961
# The compiler can only warn and ignore the option if not recognized
5962
# So say no if there are warnings
5963
if test -s conftest.err; then
5964
# Append any errors to the config.log.
5965
cat conftest.err 1>&AS_MESSAGE_LOG_FD
5971
LDFLAGS="$save_LDFLAGS"
5974
if test x"[$]$2" = xyes; then
5975
ifelse([$4], , :, [$4])
5977
ifelse([$5], , :, [$5])
5979
])# AC_LIBTOOL_LINKER_OPTION
5982
# AC_LIBTOOL_SYS_MAX_CMD_LEN
5983
# --------------------------
5984
AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN],
5985
[# find the maximum length of command line arguments
5986
AC_MSG_CHECKING([the maximum length of command line arguments])
5987
AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl
5993
# On DJGPP, this test can blow up pretty badly due to problems in libc
5994
# (any single argument exceeding 2000 bytes causes a buffer overrun
5995
# during glob expansion). Even if it were fixed, the result of this
5996
# check would be larger than it should be.
5997
lt_cv_sys_max_cmd_len=12288; # 12K is about right
6001
# Under GNU Hurd, this test is not required because there is
6002
# no limit to the length of command line arguments.
6003
# Libtool will interpret -1 as no limit whatsoever
6004
lt_cv_sys_max_cmd_len=-1;
6008
# If test is not a shell built-in, we'll probably end up computing a
6009
# maximum length that is only half of the actual maximum length, but
6011
while (test "X"`$CONFIG_SHELL [$]0 --fallback-echo "X$testring" 2>/dev/null` \
6012
= "XX$testring") >/dev/null 2>&1 &&
6013
new_result=`expr "X$testring" : ".*" 2>&1` &&
6014
lt_cv_sys_max_cmd_len=$new_result &&
6015
test $i != 17 # 1/2 MB should be enough
6018
testring=$testring$testring
6021
# Add a significant safety factor because C++ compilers can tack on massive
6022
# amounts of additional arguments before passing them to the linker.
6023
# It appears as though 1/2 is a usable value.
6024
lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
6028
if test -n $lt_cv_sys_max_cmd_len ; then
6029
AC_MSG_RESULT($lt_cv_sys_max_cmd_len)
6033
])# AC_LIBTOOL_SYS_MAX_CMD_LEN
6036
# _LT_AC_CHECK_DLFCN
6037
# --------------------
6038
AC_DEFUN([_LT_AC_CHECK_DLFCN],
6039
[AC_CHECK_HEADERS(dlfcn.h)dnl
6040
])# _LT_AC_CHECK_DLFCN
6043
# _LT_AC_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE,
6044
# ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING)
6045
# ------------------------------------------------------------------
6046
AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF],
6047
[AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl
6048
if test "$cross_compiling" = yes; then :
6051
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
6052
lt_status=$lt_dlunknown
6053
cat > conftest.$ac_ext <<EOF
6054
[#line __oline__ "configure"
6055
#include "confdefs.h"
6064
# define LT_DLGLOBAL RTLD_GLOBAL
6067
# define LT_DLGLOBAL DL_GLOBAL
6069
# define LT_DLGLOBAL 0
6073
/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
6074
find out it does not work in some platform. */
6075
#ifndef LT_DLLAZY_OR_NOW
6077
# define LT_DLLAZY_OR_NOW RTLD_LAZY
6080
# define LT_DLLAZY_OR_NOW DL_LAZY
6083
# define LT_DLLAZY_OR_NOW RTLD_NOW
6086
# define LT_DLLAZY_OR_NOW DL_NOW
6088
# define LT_DLLAZY_OR_NOW 0
6096
extern "C" void exit (int);
6099
void fnord() { int i=42;}
6102
void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
6103
int status = $lt_dlunknown;
6107
if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
6108
else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
6109
/* dlclose (self); */
6115
if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then
6116
(./conftest; exit; ) 2>/dev/null
6119
x$lt_dlno_uscore) $1 ;;
6120
x$lt_dlneed_uscore) $2 ;;
6121
x$lt_unknown|x*) $3 ;;
6124
# compilation failed
6129
])# _LT_AC_TRY_DLOPEN_SELF
6132
# AC_LIBTOOL_DLOPEN_SELF
6133
# -------------------
6134
AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF],
6135
[AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl
6136
if test "x$enable_dlopen" != xyes; then
6137
enable_dlopen=unknown
6138
enable_dlopen_self=unknown
6139
enable_dlopen_self_static=unknown
6146
lt_cv_dlopen="load_add_on"
6148
lt_cv_dlopen_self=yes
6151
cygwin* | mingw* | pw32*)
6152
lt_cv_dlopen="LoadLibrary"
6157
AC_CHECK_FUNC([shl_load],
6158
[lt_cv_dlopen="shl_load"],
6159
[AC_CHECK_LIB([dld], [shl_load],
6160
[lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-dld"],
6161
[AC_CHECK_FUNC([dlopen],
6162
[lt_cv_dlopen="dlopen"],
6163
[AC_CHECK_LIB([dl], [dlopen],
6164
[lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],
6165
[AC_CHECK_LIB([svld], [dlopen],
6166
[lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"],
6167
[AC_CHECK_LIB([dld], [dld_link],
6168
[lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld"])
6177
if test "x$lt_cv_dlopen" != xno; then
6183
case $lt_cv_dlopen in
6185
save_CPPFLAGS="$CPPFLAGS"
6186
test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
6188
save_LDFLAGS="$LDFLAGS"
6189
eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
6192
LIBS="$lt_cv_dlopen_libs $LIBS"
6194
AC_CACHE_CHECK([whether a program can dlopen itself],
6195
lt_cv_dlopen_self, [dnl
6196
_LT_AC_TRY_DLOPEN_SELF(
6197
lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes,
6198
lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross)
6201
if test "x$lt_cv_dlopen_self" = xyes; then
6202
LDFLAGS="$LDFLAGS $link_static_flag"
6203
AC_CACHE_CHECK([whether a statically linked program can dlopen itself],
6204
lt_cv_dlopen_self_static, [dnl
6205
_LT_AC_TRY_DLOPEN_SELF(
6206
lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes,
6207
lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross)
6211
CPPFLAGS="$save_CPPFLAGS"
6212
LDFLAGS="$save_LDFLAGS"
6217
case $lt_cv_dlopen_self in
6218
yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
6219
*) enable_dlopen_self=unknown ;;
6222
case $lt_cv_dlopen_self_static in
6223
yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
6224
*) enable_dlopen_self_static=unknown ;;
6227
])# AC_LIBTOOL_DLOPEN_SELF
6230
# AC_LIBTOOL_PROG_CC_C_O([TAGNAME])
6231
# ---------------------------------
6232
# Check to see if options -c and -o are simultaneously supported by compiler
6233
AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O],
6234
[AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl
6235
AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext],
6236
[_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)],
6237
[_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no
6238
$rm -r conftest 2>/dev/null
6242
ifelse([$1],[],[save_CFLAGS="$CFLAGS"
6243
CFLAGS="$CFLAGS -o out/conftest2.$ac_objext"],
6244
[$1],[CXX],[save_CXXFLAGS="$CXXFLAGS"
6245
CXXFLAGS="$CXXFLAGS -o out/conftest2.$ac_objext"],
6246
[$1],[GCJ],[save_GCJFLAGS="$GCJFLAGS"
6247
GCJFLAGS="$GCJFLAGS -o out/conftest2.$ac_objext"])
6248
echo "$lt_simple_compile_test_code" > conftest.$ac_ext
6250
# According to Tom Tromey, Ian Lance Taylor reported there are C compilers
6251
# that will create temporary files in the current directory regardless of
6252
# the output directory. Thus, making CWD read-only will cause this test
6253
# to fail, enabling locking or at least warning the user not to do parallel
6257
if (eval $ac_compile 2>out/conftest.err) && test -s out/conftest2.$ac_objext
6259
# The compiler can only warn and ignore the option if not recognized
6260
# So say no if there are warnings
6261
if test -s out/conftest.err; then
6262
# Append any errors to the config.log.
6263
cat out/conftest.err 1>&AS_MESSAGE_LOG_FD
6265
_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
6268
ifelse([$1],[],[CFLAGS="$save_CFLAGS"],
6269
[$1],[CXX],[CXXFLAGS="$save_CXXFLAGS"],
6270
[$1],[GCJ],[GCJFLAGS="$save_GCJFLAGS"])
6278
])# AC_LIBTOOL_PROG_CC_C_O
6281
# AC_LIBTOOL_SYS_HARD_LINK_LOCKS([TAGNAME])
6282
# -----------------------------------------
6283
# Check to see if we can do hard links to lock some files if needed
6284
AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS],
6285
[AC_REQUIRE([_LT_AC_LOCK])dnl
6287
hard_links="nottested"
6288
if test "$_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then
6289
# do not overwrite the value of need_locks provided by the user
6290
AC_MSG_CHECKING([if we can lock with hard links])
6293
ln conftest.a conftest.b 2>/dev/null && hard_links=no
6295
ln conftest.a conftest.b 2>&5 || hard_links=no
6296
ln conftest.a conftest.b 2>/dev/null && hard_links=no
6297
AC_MSG_RESULT([$hard_links])
6298
if test "$hard_links" = no; then
6299
AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe])
6305
])# AC_LIBTOOL_SYS_HARD_LINK_LOCKS
6310
AC_DEFUN([AC_LIBTOOL_OBJDIR],
6311
[AC_CACHE_CHECK([for objdir], [lt_cv_objdir],
6312
[rm -f .libs 2>/dev/null
6313
mkdir .libs 2>/dev/null
6314
if test -d .libs; then
6317
# MS-DOS does not allow filenames that begin with a dot.
6320
rmdir .libs 2>/dev/null])
6321
objdir=$lt_cv_objdir
6322
])# AC_LIBTOOL_OBJDIR
6325
# AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH([TAGNAME])
6326
# ----------------------------------------------
6327
# Check hardcoding attributes.
6328
AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH],
6329
[AC_MSG_CHECKING([how to hardcode library paths into programs])
6330
_LT_AC_TAGVAR(hardcode_action, $1)=
6331
if test -n "$_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)" || \
6332
test -n "$_LT_AC_TAGVAR(runpath_var $1)"; then
6334
# We can hardcode non-existant directories.
6335
if test "$_LT_AC_TAGVAR(hardcode_direct, $1)" != no &&
6336
# If the only mechanism to avoid hardcoding is shlibpath_var, we
6337
# have to relink, otherwise we might link with an installed library
6338
# when we should be linking with a yet-to-be-installed one
6339
## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)" != no &&
6340
test "$_LT_AC_TAGVAR(hardcode_minus_L, $1)" != no; then
6341
# Linking always hardcodes the temporary library directory.
6342
_LT_AC_TAGVAR(hardcode_action, $1)=relink
6344
# We can link without hardcoding, and we can hardcode nonexisting dirs.
6345
_LT_AC_TAGVAR(hardcode_action, $1)=immediate
6348
# We cannot hardcode anything, or else we can only hardcode existing
6350
_LT_AC_TAGVAR(hardcode_action, $1)=unsupported
6352
AC_MSG_RESULT([$_LT_AC_TAGVAR(hardcode_action, $1)])
6354
if test "$_LT_AC_TAGVAR(hardcode_action, $1)" = relink; then
6355
# Fast installation is not supported
6356
enable_fast_install=no
6357
elif test "$shlibpath_overrides_runpath" = yes ||
6358
test "$enable_shared" = no; then
6359
# Fast installation is not necessary
6360
enable_fast_install=needless
6362
])# AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH
6365
# AC_LIBTOOL_SYS_LIB_STRIP
6366
# ------------------------
6367
AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP],
6370
AC_MSG_CHECKING([whether stripping libraries is possible])
6371
if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then
6372
test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
6373
test -z "$striplib" && striplib="$STRIP --strip-unneeded"
6374
AC_MSG_RESULT([yes])
6378
])# AC_LIBTOOL_SYS_LIB_STRIP
6381
# AC_LIBTOOL_SYS_DYNAMIC_LINKER
6382
# -----------------------------
6383
# PORTME Fill in your ld.so characteristics
6384
AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER],
6385
[AC_MSG_CHECKING([dynamic linker characteristics])
6387
libname_spec='lib$name'
6394
shlibpath_overrides_runpath=unknown
6396
dynamic_linker="$host_os ld.so"
6397
sys_lib_dlsearch_path_spec="/lib /usr/lib"
6398
sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
6399
need_lib_prefix=unknown
6400
hardcode_into_libs=no
6402
# when you set need_version to no, make sure it does not cause -set_version
6403
# flags to be left without arguments
6404
need_version=unknown
6409
library_names_spec='${libname}${release}.so$versuffix $libname.a'
6410
shlibpath_var=LIBPATH
6412
# AIX 3 has no versioning support, so we append a major version to the name.
6413
soname_spec='${libname}${release}.so$major'
6418
if test "$host_cpu" = ia64; then
6419
# AIX 5 supports IA64
6420
library_names_spec='${libname}${release}.so$major ${libname}${release}.so$versuffix $libname.so'
6421
shlibpath_var=LD_LIBRARY_PATH
6423
# With GCC up to 2.95.x, collect2 would create an import file
6424
# for dependence libraries. The import file would start with
6425
# the line `#! .'. This would cause the generated library to
6426
# depend on `.', always an invalid library. This was fixed in
6427
# development snapshots of GCC prior to 3.0.
6429
aix4 | aix4.[[01]] | aix4.[[01]].*)
6430
if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
6432
echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then
6439
# AIX (on Power*) has no versioning support, so currently we can not hardcode correct
6440
# soname into executable. Probably we can add versioning support to
6441
# collect2, so additional links can be useful in future.
6442
if test "$aix_use_runtimelinking" = yes; then
6443
# If using run time linking (on AIX 4.2 or later) use lib<name>.so
6444
# instead of lib<name>.a to let people know that these are not
6445
# typical AIX shared libraries.
6446
library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
6448
# We preserve .a as extension for shared libraries through AIX4.2
6449
# and later when we are not doing run time linking.
6450
library_names_spec='${libname}${release}.a $libname.a'
6451
soname_spec='${libname}${release}.so$major'
6453
shlibpath_var=LIBPATH
6458
library_names_spec='$libname.ixlibrary $libname.a'
6459
# Create ${libname}_ixlibrary.a entries in /sys/libs.
6460
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'
6464
library_names_spec='${libname}.so'
6465
dynamic_linker="$host_os ld.so"
6466
shlibpath_var=LIBRARY_PATH
6472
library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
6473
soname_spec='${libname}${release}.so$major'
6474
finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
6475
shlibpath_var=LD_LIBRARY_PATH
6476
sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
6477
sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
6478
# the default ld.so.conf also contains /usr/contrib/lib and
6479
# /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
6480
# libtool to hard-code these into programs
6483
cygwin* | mingw* | pw32*)
6484
version_type=windows
6487
case $GCC,$host_os in
6489
library_names_spec='$libname.dll.a'
6490
sys_lib_search_path_spec="/lib /lib/w32api /usr/lib /usr/local/lib"
6491
soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | sed -e 's/[[.]]/-/g'`${versuffix}.dll'
6492
postinstall_cmds='dlpath=`bash 2>&1 -c '\''. $dir/${file}i;echo \$dlname'\''`~
6493
dldir=$destdir/`dirname \$dlpath`~
6494
test -d \$dldir || mkdir -p \$dldir~
6495
$install_prog .libs/$dlname \$dldir/$dlname'
6496
postuninstall_cmds='dldll=`bash 2>&1 -c '\''. $file; echo \$dlname'\''`~
6497
dlpath=$dir/\$dldll~
6501
library_names_spec='${libname}`echo ${release} | sed -e 's/[[.]]/-/g'`${versuffix}.dll'
6502
sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | sed -e "s/^libraries://"`
6503
if echo "$sys_lib_search_path_spec" | [egrep ';[C-Z]:/' >/dev/null]; then
6504
# It is most probably a Windows format PATH printed by
6505
# mingw gcc, but we are running on Cygwin. Gcc prints its search
6506
# path with ; separators, and with drive letters. We can handle the
6507
# drive letters (cygwin fileutils understands them), so leave them,
6508
# especially as we might pass files found there to a mingw objdump,
6509
# which wouldn't understand a cygwinified path. Ahh.
6510
sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | sed -e 's/;/ /g'`
6512
sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | sed -e "s/$PATH_SEPARATOR/ /g"`
6516
library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | sed -e 's/[.]/-/g'`${versuffix}.dll'
6519
library_names_spec='${libname}`echo ${release} | sed -e 's/[[.]]/-/g'`${versuffix}.dll $libname.lib'
6522
dynamic_linker='Win32 ld.exe'
6523
# FIXME: first we should search . and the directory the executable is in
6527
darwin* | rhapsody*)
6528
dynamic_linker="$host_os dyld"
6532
# FIXME: Relying on posixy $() will cause problems for
6533
# cross-compilation, but unfortunately the echo tests do not
6534
# yet detect zsh echo's removal of \ escapes.
6535
library_names_spec='${libname}${release}${versuffix}.$(test .$module = .yes && echo so || echo dylib) ${libname}${release}${major}.$(test .$module = .yes && echo so || echo dylib) ${libname}.$(test .$module = .yes && echo so || echo dylib)'
6536
soname_spec='${libname}${release}${major}.$(test .$module = .yes && echo so || echo dylib)'
6537
shlibpath_overrides_runpath=yes
6538
shlibpath_var=DYLD_LIBRARY_PATH
6545
library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
6546
soname_spec='${libname}${release}.so$major'
6547
shlibpath_var=LD_LIBRARY_PATH
6555
objformat=`test -x /usr/bin/objformat && /usr/bin/objformat || echo aout`
6556
version_type=freebsd-$objformat
6557
case $version_type in
6559
library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so $libname.so'
6564
library_names_spec='${libname}${release}.so$versuffix $libname.so$versuffix'
6568
shlibpath_var=LD_LIBRARY_PATH
6571
shlibpath_overrides_runpath=yes
6573
freebsd3.[01]* | freebsdelf3.[01]*)
6574
shlibpath_overrides_runpath=yes
6575
hardcode_into_libs=yes
6578
shlibpath_overrides_runpath=no
6579
hardcode_into_libs=yes
6588
library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so${major} ${libname}.so'
6589
soname_spec='${libname}${release}.so$major'
6590
shlibpath_var=LD_LIBRARY_PATH
6591
hardcode_into_libs=yes
6594
hpux9* | hpux10* | hpux11*)
6595
# Give a soname corresponding to the major version so that dld.sl refuses to
6596
# link against other versions.
6600
if test "$host_cpu" = ia64; then
6601
hardcode_into_libs=yes
6602
dynamic_linker="$host_os dld.so"
6603
shlibpath_var=LD_LIBRARY_PATH
6604
shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
6605
library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
6606
soname_spec='${libname}${release}.so$major'
6607
if test "X$HPUX_IA64_MODE" = X32; then
6608
sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
6610
sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
6612
sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
6614
dynamic_linker="$host_os dld.sl"
6615
shlibpath_var=SHLIB_PATH
6616
shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
6617
library_names_spec='${libname}${release}.sl$versuffix ${libname}${release}.sl$major $libname.sl'
6618
soname_spec='${libname}${release}.sl$major'
6620
# HP-UX runs *really* slowly unless shared libraries are mode 555.
6621
postinstall_cmds='chmod 555 $lib'
6624
irix5* | irix6* | nonstopux*)
6626
nonstopux*) version_type=nonstopux ;;
6627
*) version_type=irix ;;
6631
soname_spec='${libname}${release}.so$major'
6632
library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major ${libname}${release}.so $libname.so'
6634
irix5* | nonstopux*)
6638
case $LD in # libtool.m4 will add one of these switches to LD
6639
*-32|*"-32 ") libsuff= shlibsuff= libmagic=32-bit;;
6640
*-n32|*"-n32 ") libsuff=32 shlibsuff=N32 libmagic=N32;;
6641
*-64|*"-64 ") libsuff=64 shlibsuff=64 libmagic=64-bit;;
6642
*) libsuff= shlibsuff= libmagic=never-match;;
6646
shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
6647
shlibpath_overrides_runpath=no
6648
sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
6649
sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
6652
# No shared lib support for Linux oldld, aout, or coff.
6653
linux*oldld* | linux*aout* | linux*coff*)
6657
# This must be Linux ELF.
6662
library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
6663
soname_spec='${libname}${release}.so$major'
6664
finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
6666
if test "x$LINUX_64_MODE" = x64; then
6667
# Some platforms are per default 64-bit, so there's no /lib64
6668
if test -d /lib64; then
6672
shlibpath_var=LD_LIBRARY_PATH
6673
shlibpath_overrides_runpath=no
6674
sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff}"
6675
sys_lib_search_path_spec="/lib${libsuff} /usr/lib${libsuff} /usr/local/lib${libsuff}"
6676
# This implies no fast_install, which is unacceptable.
6677
# Some rework will be needed to allow for fast_install
6678
# before this can be enabled.
6679
hardcode_into_libs=yes
6681
# We used to test for /lib/ld.so.1 and disable shared libraries on
6682
# powerpc, because MkLinux only supported shared libraries with the
6683
# GNU dynamic linker. Since this was broken with cross compilers,
6684
# most powerpc-linux boxes support dynamic linking these days and
6685
# people can always --disable-shared, the test was removed, and we
6686
# assume the GNU/Linux dynamic linker is in use.
6687
dynamic_linker='GNU/Linux ld.so'
6694
if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
6695
library_names_spec='${libname}${release}.so$versuffix ${libname}.so$versuffix'
6696
finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
6697
dynamic_linker='NetBSD (a.out) ld.so'
6699
library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major ${libname}${release}.so ${libname}.so'
6700
soname_spec='${libname}${release}.so$major'
6701
dynamic_linker='NetBSD ld.elf_so'
6703
shlibpath_var=LD_LIBRARY_PATH
6704
shlibpath_overrides_runpath=yes
6705
hardcode_into_libs=yes
6710
library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
6711
shlibpath_var=LD_LIBRARY_PATH
6712
shlibpath_overrides_runpath=yes
6719
library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
6720
soname_spec='${libname}${release}.so$major'
6721
shlibpath_var=LD_LIBRARY_PATH
6722
shlibpath_overrides_runpath=yes
6729
library_names_spec='${libname}${release}.so$versuffix ${libname}.so$versuffix'
6730
finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
6731
shlibpath_var=LD_LIBRARY_PATH
6732
if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
6734
openbsd2.[[89]] | openbsd2.[[89]].*)
6735
shlibpath_overrides_runpath=no
6738
shlibpath_overrides_runpath=yes
6742
shlibpath_overrides_runpath=yes
6747
libname_spec='$name'
6749
library_names_spec='$libname.dll $libname.a'
6750
dynamic_linker='OS/2 ld.exe'
6751
shlibpath_var=LIBPATH
6754
osf3* | osf4* | osf5*)
6758
soname_spec='${libname}${release}.so'
6759
library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so $libname.so'
6760
shlibpath_var=LD_LIBRARY_PATH
6761
sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
6762
sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
6767
soname_spec='${libname}${release}.so$major'
6768
library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
6769
shlibpath_var=LD_LIBRARY_PATH
6776
library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
6777
soname_spec='${libname}${release}.so$major'
6778
shlibpath_var=LD_LIBRARY_PATH
6779
shlibpath_overrides_runpath=yes
6780
hardcode_into_libs=yes
6781
# ldd complains unless libraries are executable
6782
postinstall_cmds='chmod +x $lib'
6787
library_names_spec='${libname}${release}.so$versuffix ${libname}.so$versuffix'
6788
finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
6789
shlibpath_var=LD_LIBRARY_PATH
6790
shlibpath_overrides_runpath=yes
6791
if test "$with_gnu_ld" = yes; then
6797
sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
6799
library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
6800
soname_spec='${libname}${release}.so$major'
6801
shlibpath_var=LD_LIBRARY_PATH
6802
case $host_vendor in
6804
shlibpath_overrides_runpath=no
6809
shlibpath_overrides_runpath=no
6810
sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
6816
if test -d /usr/nec ;then
6818
library_names_spec='$libname.so.$versuffix $libname.so.$major $libname.so'
6819
soname_spec='$libname.so.$major'
6820
shlibpath_var=LD_LIBRARY_PATH
6826
library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
6827
soname_spec='${libname}${release}.so$major'
6828
shlibpath_var=LD_LIBRARY_PATH
6835
AC_MSG_RESULT([$dynamic_linker])
6836
test "$dynamic_linker" = no && can_build_shared=no
6837
])# AC_LIBTOOL_SYS_DYNAMIC_LINKER
6842
AC_DEFUN([_LT_AC_TAGCONFIG],
6843
[AC_ARG_WITH([tags],
6844
[AC_HELP_STRING([--with-tags=TAGS],
6845
[include additional configurations @<:@CXX,GCJ@:>@])],
6846
[tagnames="$withval"],
6849
mingw*|cygwin*) tagnames="$tagnames,RC" ;;
6852
if test -f "$ltmain" && test -n "$tagnames"; then
6853
if test ! -f "${ofile}"; then
6854
AC_MSG_WARN([output file `$ofile' does not exist])
6857
if test -z "$LTCC"; then
6858
eval "`$SHELL ${ofile} --config | grep '^LTCC='`"
6859
if test -z "$LTCC"; then
6860
AC_MSG_WARN([output file `$ofile' does not look like a libtool script])
6862
AC_MSG_WARN([using `LTCC=$LTCC', extracted from `$ofile'])
6866
# Extract list of available tagged configurations in $ofile.
6867
# Note that this assumes the entire list is on one line.
6868
available_tags=`grep "^available_tags=" "${ofile}" | sed -e 's/available_tags=\(.*$\)/\1/' -e 's/\"//g'`
6870
lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
6871
for tagname in $tagnames; do
6873
# Check whether tagname contains only valid characters
6874
case `$echo "X$tagname" | $Xsed -e 's:[[-_ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890,/]]::g'` in
6876
*) AC_MSG_ERROR([invalid tag name: $tagname])
6880
if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$" < "${ofile}" > /dev/null
6882
AC_MSG_ERROR([tag name \"$tagname\" already exists])
6885
# Update the list of available tags.
6886
if test -n "$tagname"; then
6887
echo appending configuration tag \"$tagname\" to $ofile
6891
AC_LIBTOOL_LANG_CXX_CONFIG
6895
AC_LIBTOOL_LANG_GCJ_CONFIG
6899
AC_LIBTOOL_LANG_RC_CONFIG
6903
AC_MSG_ERROR([Unsupported tag name: $tagname])
6907
# Append the new tag name to the list of available tags.
6908
available_tags="$available_tags $tagname"
6913
# Now substitute the updated list of available tags.
6914
if eval "sed -e 's/^available_tags=.*\$/available_tags=\"$available_tags\"/' \"$ofile\" > \"${ofile}T\""; then
6915
mv "${ofile}T" "$ofile"
6919
AC_MSG_ERROR([unable to update list of available tagged configurations.])
6922
])# _LT_AC_TAGCONFIG
6927
# enable checks for dlopen support
6928
AC_DEFUN([AC_LIBTOOL_DLOPEN],
6929
[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])
6930
])# AC_LIBTOOL_DLOPEN
6933
# AC_LIBTOOL_WIN32_DLL
6934
# --------------------
6935
# declare package support for building win32 dll's
6936
AC_DEFUN([AC_LIBTOOL_WIN32_DLL],
6937
[AC_BEFORE([$0], [AC_LIBTOOL_SETUP])
6938
])# AC_LIBTOOL_WIN32_DLL
6941
# AC_ENABLE_SHARED([DEFAULT])
6942
# ---------------------------
6943
# implement the --enable-shared flag
6944
# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
5992
6945
AC_DEFUN([AC_ENABLE_SHARED],
5993
6946
[define([AC_ENABLE_SHARED_DEFAULT], ifelse($1, no, no, yes))dnl
5994
AC_ARG_ENABLE(shared,
5995
changequote(<<, >>)dnl
5996
<< --enable-shared[=PKGS] build shared libraries [default=>>AC_ENABLE_SHARED_DEFAULT],
5997
changequote([, ])dnl
5998
[p=${PACKAGE-default}
6000
yes) enable_shared=yes ;;
6001
no) enable_shared=no ;;
6004
# Look at the argument we got. We use all the common list separators.
6005
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
6006
for pkg in $enableval; do
6007
if test "X$pkg" = "X$p"; then
6014
enable_shared=AC_ENABLE_SHARED_DEFAULT)dnl
6017
# AC_DISABLE_SHARED - set the default shared flag to --disable-shared
6018
AC_DEFUN([AC_DISABLE_SHARED], [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
6019
AC_ENABLE_SHARED(no)])
6021
# AC_ENABLE_STATIC - implement the --enable-static flag
6022
# Usage: AC_ENABLE_STATIC[(DEFAULT)]
6023
# Where DEFAULT is either `yes' or `no'. If omitted, it defaults to
6947
AC_ARG_ENABLE([shared],
6948
[AC_HELP_STRING([--enable-shared@<:@=PKGS@:>@],
6949
[build shared libraries @<:@default=]AC_ENABLE_SHARED_DEFAULT[@:>@])],
6950
[p=${PACKAGE-default}
6952
yes) enable_shared=yes ;;
6953
no) enable_shared=no ;;
6956
# Look at the argument we got. We use all the common list separators.
6957
lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
6958
for pkg in $enableval; do
6960
if test "X$pkg" = "X$p"; then
6967
[enable_shared=]AC_ENABLE_SHARED_DEFAULT)
6968
])# AC_ENABLE_SHARED
6973
#- set the default shared flag to --disable-shared
6974
AC_DEFUN([AC_DISABLE_SHARED],
6975
[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
6976
AC_ENABLE_SHARED(no)
6977
])# AC_DISABLE_SHARED
6980
# AC_ENABLE_STATIC([DEFAULT])
6981
# ---------------------------
6982
# implement the --enable-static flag
6983
# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
6025
6984
AC_DEFUN([AC_ENABLE_STATIC],
6026
6985
[define([AC_ENABLE_STATIC_DEFAULT], ifelse($1, no, no, yes))dnl
6027
AC_ARG_ENABLE(static,
6028
changequote(<<, >>)dnl
6029
<< --enable-static[=PKGS] build static libraries [default=>>AC_ENABLE_STATIC_DEFAULT],
6030
changequote([, ])dnl
6031
[p=${PACKAGE-default}
6033
yes) enable_static=yes ;;
6034
no) enable_static=no ;;
6037
# Look at the argument we got. We use all the common list separators.
6038
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
6039
for pkg in $enableval; do
6040
if test "X$pkg" = "X$p"; then
6047
enable_static=AC_ENABLE_STATIC_DEFAULT)dnl
6050
# AC_DISABLE_STATIC - set the default static flag to --disable-static
6986
AC_ARG_ENABLE([static],
6987
[AC_HELP_STRING([--enable-static@<:@=PKGS@:>@],
6988
[build static libraries @<:@default=]AC_ENABLE_STATIC_DEFAULT[@:>@])],
6989
[p=${PACKAGE-default}
6991
yes) enable_static=yes ;;
6992
no) enable_static=no ;;
6995
# Look at the argument we got. We use all the common list separators.
6996
lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
6997
for pkg in $enableval; do
6999
if test "X$pkg" = "X$p"; then
7006
[enable_static=]AC_ENABLE_STATIC_DEFAULT)
7007
])# AC_ENABLE_STATIC
7012
# set the default static flag to --disable-static
6051
7013
AC_DEFUN([AC_DISABLE_STATIC],
6052
7014
[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
6053
AC_ENABLE_STATIC(no)])
6056
# AC_ENABLE_FAST_INSTALL - implement the --enable-fast-install flag
6057
# Usage: AC_ENABLE_FAST_INSTALL[(DEFAULT)]
6058
# Where DEFAULT is either `yes' or `no'. If omitted, it defaults to
7015
AC_ENABLE_STATIC(no)
7016
])# AC_DISABLE_STATIC
7019
# AC_ENABLE_FAST_INSTALL([DEFAULT])
7020
# ---------------------------------
7021
# implement the --enable-fast-install flag
7022
# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
6060
7023
AC_DEFUN([AC_ENABLE_FAST_INSTALL],
6061
7024
[define([AC_ENABLE_FAST_INSTALL_DEFAULT], ifelse($1, no, no, yes))dnl
6062
AC_ARG_ENABLE(fast-install,
6063
changequote(<<, >>)dnl
6064
<< --enable-fast-install[=PKGS] optimize for fast installation [default=>>AC_ENABLE_FAST_INSTALL_DEFAULT],
6065
changequote([, ])dnl
6066
[p=${PACKAGE-default}
6068
yes) enable_fast_install=yes ;;
6069
no) enable_fast_install=no ;;
6071
enable_fast_install=no
6072
# Look at the argument we got. We use all the common list separators.
6073
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
6074
for pkg in $enableval; do
6075
if test "X$pkg" = "X$p"; then
6076
enable_fast_install=yes
6082
enable_fast_install=AC_ENABLE_FAST_INSTALL_DEFAULT)dnl
6085
# AC_DISABLE_FAST_INSTALL - set the default to --disable-fast-install
7025
AC_ARG_ENABLE([fast-install],
7026
[AC_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@],
7027
[optimize for fast installation @<:@default=]AC_ENABLE_FAST_INSTALL_DEFAULT[@:>@])],
7028
[p=${PACKAGE-default}
7030
yes) enable_fast_install=yes ;;
7031
no) enable_fast_install=no ;;
7033
enable_fast_install=no
7034
# Look at the argument we got. We use all the common list separators.
7035
lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
7036
for pkg in $enableval; do
7038
if test "X$pkg" = "X$p"; then
7039
enable_fast_install=yes
7045
[enable_fast_install=]AC_ENABLE_FAST_INSTALL_DEFAULT)
7046
])# AC_ENABLE_FAST_INSTALL
7049
# AC_DISABLE_FAST_INSTALL
7050
# -----------------------
7051
# set the default to --disable-fast-install
6086
7052
AC_DEFUN([AC_DISABLE_FAST_INSTALL],
6087
7053
[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
6088
AC_ENABLE_FAST_INSTALL(no)])
6090
# AC_LIBTOOL_PICMODE - implement the --with-pic flag
6091
# Usage: AC_LIBTOOL_PICMODE[(MODE)]
6092
# Where MODE is either `yes' or `no'. If omitted, it defaults to
7054
AC_ENABLE_FAST_INSTALL(no)
7055
])# AC_DISABLE_FAST_INSTALL
7058
# AC_LIBTOOL_PICMODE([MODE])
7059
# --------------------------
7060
# implement the --with-pic flag
7061
# MODE is either `yes' or `no'. If omitted, it defaults to `both'.
6094
7062
AC_DEFUN([AC_LIBTOOL_PICMODE],
6095
7063
[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
6096
pic_mode=ifelse($#,1,$1,default)])
6099
# AC_PATH_TOOL_PREFIX - find a file program which can recognise shared library
7064
pic_mode=ifelse($#,1,$1,default)
7065
])# AC_LIBTOOL_PICMODE
7068
# AC_PATH_TOOL_PREFIX
7069
# -------------------
7070
# find a file program which can recognise shared library
6100
7071
AC_DEFUN([AC_PATH_TOOL_PREFIX],
6101
7072
[AC_MSG_CHECKING([for $1])
6102
7073
AC_CACHE_VAL(lt_cv_path_MAGIC_CMD,
6103
7074
[case $MAGIC_CMD in
7075
[[\\/*] | ?:[\\/]*])
6105
7076
lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
6108
lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a dos path.
6111
ac_save_MAGIC_CMD="$MAGIC_CMD"
6112
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
7079
lt_save_MAGIC_CMD="$MAGIC_CMD"
7080
lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
6113
7081
dnl $ac_dummy forces splitting on constant user-supplied paths.
6114
7082
dnl POSIX.2 word splitting is done only on the output of word expansions,
6115
7083
dnl not every word. This closes a longstanding sh security hole.
6116
7084
ac_dummy="ifelse([$2], , $PATH, [$2])"
6117
7085
for ac_dir in $ac_dummy; do
6118
7087
test -z "$ac_dir" && ac_dir=.
6119
7088
if test -f $ac_dir/$1; then
6120
7089
lt_cv_path_MAGIC_CMD="$ac_dir/$1"
6543
7560
if test x"$enable_ltdl_install" = x"yes"; then
6544
7561
ac_configure_args="$ac_configure_args --enable-ltdl-install"
6545
7562
LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdl.la
6546
INCLTDL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl'])
7563
LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl'])
6548
7565
ac_configure_args="$ac_configure_args --enable-ltdl-install=no"
6549
7566
LIBLTDL="-lltdl"
7569
# For backwards non-gettext consistent compatibility...
7571
])# AC_LIBLTDL_INSTALLABLE
6554
7574
# If this macro is not defined by Autoconf, define it here.
6555
7575
ifdef([AC_PROVIDE_IFELSE],
6557
7577
[define([AC_PROVIDE_IFELSE],
6558
[ifdef([AC_PROVIDE_$1],
6561
# AC_LIBTOOL_CXX - enable support for C++ libraries
6562
AC_DEFUN([AC_LIBTOOL_CXX], [AC_REQUIRE([_AC_LIBTOOL_CXX])])
6564
AC_DEFUN([_AC_LIBTOOL_CXX],
7578
[ifdef([AC_PROVIDE_$1],
7584
# enable support for C++ libraries
7585
AC_DEFUN([AC_LIBTOOL_CXX],
7586
[AC_REQUIRE([_LT_AC_LANG_CXX])
7592
AC_DEFUN([_LT_AC_LANG_CXX],
6565
7593
[AC_REQUIRE([AC_PROG_CXX])
6566
7594
AC_REQUIRE([AC_PROG_CXXCPP])
6567
LIBTOOL_DEPS=$LIBTOOL_DEPS" $ac_aux_dir/ltcf-cxx.sh"
6569
lt_save_CFLAGS="$CFLAGS"
6570
dnl Make sure LTCC is set to the C compiler, i.e. set LTCC before CC
6571
dnl is set to the C++ compiler.
6572
AR="$AR" LTCC="$CC" CC="$CXX" CXX="$CXX" CFLAGS="$CXXFLAGS" CPPFLAGS="$CPPFLAGS" \
6573
MAGIC_CMD="$MAGIC_CMD" LD="$LD" LDFLAGS="$LDFLAGS" LIBS="$LIBS" \
6574
LN_S="$LN_S" NM="$NM" RANLIB="$RANLIB" STRIP="$STRIP" \
6575
AS="$AS" DLLTOOL="$DLLTOOL" OBJDUMP="$OBJDUMP" \
6576
objext="$OBJEXT" exeext="$EXEEXT" reload_flag="$reload_flag" \
6577
deplibs_check_method="$deplibs_check_method" \
6578
file_magic_cmd="$file_magic_cmd" \
6579
${CONFIG_SHELL-/bin/sh} $ac_aux_dir/ltconfig -o libtool $libtool_flags \
6580
--build="$build" --add-tag=CXX $ac_aux_dir/ltcf-cxx.sh $host \
6581
|| AC_MSG_ERROR([libtool tag configuration failed])
6583
CFLAGS="$lt_save_CFLAGS"
6585
# Redirect the config.log output again, so that the ltconfig log is not
6586
# clobbered by the next message.
6587
exec 5>>./config.log
6590
# AC_LIBTOOL_GCJ - enable support for GCJ libraries
6591
AC_DEFUN([AC_LIBTOOL_GCJ],[AC_REQUIRE([_AC_LIBTOOL_GCJ])])
6593
AC_DEFUN([_AC_LIBTOOL_GCJ],
6594
[AC_REQUIRE([AC_PROG_LIBTOOL])
6595
AC_PROVIDE_IFELSE([AC_PROG_GCJ],[],
7600
# enable support for GCJ libraries
7601
AC_DEFUN([AC_LIBTOOL_GCJ],
7602
[AC_REQUIRE([_LT_AC_LANG_GCJ])
7608
AC_DEFUN([_LT_AC_LANG_GCJ],
7609
[AC_PROVIDE_IFELSE([AC_PROG_GCJ],[],
6596
7610
[AC_PROVIDE_IFELSE([A][M_PROG_GCJ],[],
6597
7611
[AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ],[],
6598
7612
[ifdef([AC_PROG_GCJ],[AC_REQUIRE([AC_PROG_GCJ])],
6599
[ifdef([A][M_PROG_GCJ],[AC_REQUIRE([A][M_PROG_GCJ])],
6600
[AC_REQUIRE([A][C_PROG_GCJ_OR_A][M_PROG_GCJ])])])])])])
6601
LIBTOOL_DEPS=$LIBTOOL_DEPS" $ac_aux_dir/ltcf-gcj.sh"
6603
lt_save_CFLAGS="$CFLAGS"
6604
dnl Make sure LTCC is set to the C compiler, i.e. set LTCC before CC
6605
dnl is set to the C++ compiler.
6606
AR="$AR" LTCC="$CC" CC="$GCJ" CFLAGS="$GCJFLAGS" CPPFLAGS="$CPPFLAGS" \
6607
MAGIC_CMD="$MAGIC_CMD" LD="$LD" LDFLAGS="$LDFLAGS" LIBS="$LIBS" \
6608
LN_S="$LN_S" NM="$NM" RANLIB="$RANLIB" STRIP="$STRIP" \
6609
AS="$AS" DLLTOOL="$DLLTOOL" OBJDUMP="$OBJDUMP" \
6610
objext="$OBJEXT" exeext="$EXEEXT" reload_flag="$reload_flag" \
6611
deplibs_check_method="$deplibs_check_method" \
6612
file_magic_cmd="$file_magic_cmd" \
6613
${CONFIG_SHELL-/bin/sh} $ac_aux_dir/ltconfig -o libtool $libtool_flags \
6614
--build="$build" --add-tag=GCJ $ac_aux_dir/ltcf-gcj.sh $host \
6615
|| AC_MSG_ERROR([libtool tag configuration failed])
6617
CFLAGS="$lt_save_CFLAGS"
6619
# Redirect the config.log output again, so that the ltconfig log is not
6620
# clobbered by the next message.
6621
exec 5>>./config.log
7613
[ifdef([A][M_PROG_GCJ],[AC_REQUIRE([A][M_PROG_GCJ])],
7614
[AC_REQUIRE([A][C_PROG_GCJ_OR_A][M_PROG_GCJ])])])])])])
7620
# enable support for Windows resource files
7621
AC_DEFUN([AC_LIBTOOL_RC],
7622
[AC_REQUIRE([AC_PROG_RC])
7626
# AC_LIBTOOL_LANG_C_CONFIG
7627
# ------------------------
7628
# Ensure that the configuration vars for the C compiler are
7629
# suitably defined. Those variables are subsequently used by
7630
# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
7631
AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG], [_LT_AC_LANG_C_CONFIG])
7632
AC_DEFUN([_LT_AC_LANG_C_CONFIG],
7636
# Source file extension for C test sources.
7639
# Object file extension for compiled C test sources.
7641
_LT_AC_TAGVAR(objext, $1)=$objext
7643
# Code to be used in simple compile tests
7644
lt_simple_compile_test_code="int some_variable = 0;"
7646
# Code to be used in simple link tests
7647
lt_simple_link_test_code='main(){return(0);}'
7652
# Check for any special shared library compilation flags.
7654
_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)=
7655
if test "$GCC" = no; then
7658
_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)='-belf'
7662
if test -n "$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)"; then
7663
AC_MSG_WARN([`$CC' requires `$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)' to build shared libraries])
7664
if echo "$old_CC $old_CFLAGS " | egrep -e "[[ ]]$]_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)[[[ ]]" >/dev/null; then :
7666
AC_MSG_WARN([add `$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)' to the CC or CFLAGS env variable and reconfigure])
7667
_LT_AC_TAGVAR(lt_cv_prog_cc_can_build_shared, $1)=no
7673
# Check to make sure the static flag actually works.
7675
AC_LIBTOOL_LINKER_OPTION([if $compiler static flag $_LT_AC_TAGVAR(lt_prog_compiler_static, $1) works],
7676
_LT_AC_TAGVAR(lt_prog_compiler_static_works, $1),
7677
$_LT_AC_TAGVAR(lt_prog_compiler_static, $1),
7679
[_LT_AC_TAGVAR(lt_prog_compiler_static, $1)=])
7683
## There is no encapsulation within the following macros, do not change
7684
## the running order or otherwise move them around unless you know exactly
7685
## what you are doing...
7686
AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1)
7687
AC_LIBTOOL_PROG_COMPILER_PIC($1)
7688
AC_LIBTOOL_PROG_CC_C_O($1)
7689
AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
7690
AC_LIBTOOL_PROG_LD_SHLIBS($1)
7691
AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
7692
AC_LIBTOOL_SYS_LIB_STRIP
7693
AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
7694
AC_LIBTOOL_DLOPEN_SELF($1)
7696
# Report which librarie types wil actually be built
7697
AC_MSG_CHECKING([if libtool supports shared libraries])
7698
AC_MSG_RESULT([$can_build_shared])
7700
AC_MSG_CHECKING([whether to build shared libraries])
7701
test "$can_build_shared" = "no" && enable_shared=no
7703
# On AIX, shared libraries and static libraries use the same namespace, and
7704
# are all built from PIC.
7707
test "$enable_shared" = yes && enable_static=no
7708
if test -n "$RANLIB"; then
7709
archive_cmds="$archive_cmds~\$RANLIB \$lib"
7710
postinstall_cmds='$RANLIB $lib'
7715
if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
7716
test "$enable_shared" = yes && enable_static=no
7720
AC_MSG_RESULT([$enable_shared])
7722
AC_MSG_CHECKING([whether to build static libraries])
7723
# Make sure either enable_shared or enable_static is yes.
7724
test "$enable_shared" = yes || enable_static=yes
7725
AC_MSG_RESULT([$enable_static])
7727
AC_LIBTOOL_CONFIG($1)
7731
])# AC_LIBTOOL_LANG_C_CONFIG
7734
# AC_LIBTOOL_LANG_CXX_CONFIG
7735
# --------------------------
7736
# Ensure that the configuration vars for the C compiler are
7737
# suitably defined. Those variables are subsequently used by
7738
# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
7739
AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG], [_LT_AC_LANG_CXX_CONFIG(CXX)])
7740
AC_DEFUN([_LT_AC_LANG_CXX_CONFIG],
7742
AC_REQUIRE([AC_PROG_CXX])
7743
AC_REQUIRE([AC_PROG_CXXCPP])
7745
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
7746
_LT_AC_TAGVAR(allow_undefined_flag, $1)=
7747
_LT_AC_TAGVAR(always_export_symbols, $1)=no
7748
_LT_AC_TAGVAR(archive_expsym_cmds, $1)=
7749
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
7750
_LT_AC_TAGVAR(hardcode_direct, $1)=no
7751
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
7752
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
7753
_LT_AC_TAGVAR(hardcode_minus_L, $1)=no
7754
_LT_AC_TAGVAR(link_all_deplibs, $1)=unknown
7755
_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
7756
_LT_AC_TAGVAR(no_undefined_flag, $1)=
7757
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
7759
# Dependencies to place before and after the object being linked:
7760
_LT_AC_TAGVAR(predep_objects, $1)=
7761
_LT_AC_TAGVAR(postdep_objects, $1)=
7762
_LT_AC_TAGVAR(predeps, $1)=
7763
_LT_AC_TAGVAR(postdeps, $1)=
7764
_LT_AC_TAGVAR(compiler_lib_search_path, $1)=
7766
# Source file extension for C test sources.
7769
# Object file extension for compiled C test sources.
7771
_LT_AC_TAGVAR(objext, $1)=$objext
7773
# Code to be used in simple compile tests
7774
lt_simple_compile_test_code="int some_variable = 0;"
7776
# Code to be used in simple link tests
7777
lt_simple_link_test_code='int main(int char *[]) { return(0); }'
7779
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
7782
# Allow CC to be a program name with arguments.
7787
_LT_AC_TAGVAR(compiler, $1)=$CC
7788
cc_basename=`$echo X"$compiler" | $Xsed -e 's%^.*/%%'`
7790
# We don't want -fno-exception wen compiling C++ code, so set the
7791
# no_builtin_flag separately
7792
if test "$GXX" = yes; then
7793
_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
7795
_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
7798
if test "$GXX" = yes; then
7799
# Set up default GNU C++ configuration
7801
# Check if GNU C++ uses GNU ld as the underlying linker, since the
7802
# archiving commands below assume that GNU ld is being used.
7803
if eval "`$CC -print-prog-name=ld` --version 2>&1" | \
7804
egrep 'GNU ld' > /dev/null; then
7807
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
7808
_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'
7810
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
7811
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
7813
# If archive_cmds runs LD, not CC, wlarc should be empty
7814
# XXX I think wlarc can be eliminated in ltcf-cxx, but I need to
7815
# investigate it a little bit more. (MM)
7818
# ancient GNU ld didn't support --whole-archive et. al.
7819
if eval "`$CC -print-prog-name=ld` --help 2>&1" | \
7820
egrep 'no-whole-archive' > /dev/null; then
7821
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
7823
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
7829
# A generic and very simple default shared library creation
7830
# command for GNU C++ for the case where it uses the native
7831
# linker, instead of GNU ld. If possible, this setting should
7832
# overridden to take advantage of the native linker features on
7833
# the platform it is being used on.
7834
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
7837
# Commands to make compiler produce verbose output that lists
7838
# what "hidden" libraries, object files and flags are used when
7839
# linking a shared library.
7840
output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | egrep "\-L"'
7848
# PORTME: fill in a description of your system's C++ link characteristics
7849
AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
7850
_LT_AC_TAGVAR(ld_shlibs, $1)=yes
7853
# FIXME: insert proper C++ library support
7854
_LT_AC_TAGVAR(ld_shlibs, $1)=no
7857
if test "$host_cpu" = ia64; then
7858
# On IA64, the linker does run time linking by default, so we don't
7859
# have to do anything special.
7860
aix_use_runtimelinking=no
7861
exp_sym_flag='-Bexport'
7864
# KDE requires run time linking. Make it the default.
7865
aix_use_runtimelinking=yes
7866
exp_sym_flag='-bexport'
7867
no_entry_flag='-bnoentry'
7870
# When large executables or shared objects are built, AIX ld can
7871
# have problems creating the table of contents. If linking a library
7872
# or program results in "error TOC overflow" add -mminimal-toc to
7873
# CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
7874
# enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
7876
_LT_AC_TAGVAR(archive_cmds, $1)=''
7877
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
7878
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
7879
_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
7881
if test "$GXX" = yes; then
7882
case $host_os in aix4.[012]|aix4.[012].*)
7883
# We only want to do this on AIX 4.2 and lower, the check
7884
# below for broken collect2 doesn't work under 4.3+
7885
collect2name=`${CC} -print-prog-name=collect2`
7886
if test -f "$collect2name" && \
7887
strings "$collect2name" | grep resolve_lib_name >/dev/null
7889
# We have reworked collect2
7890
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
7892
# We have old collect2
7893
_LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
7894
# It fails to find uninstalled libraries when the uninstalled
7895
# path is not listed in the libpath. Setting hardcode_minus_L
7896
# to unsupported forces relinking
7897
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
7898
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
7899
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
7902
shared_flag='-shared'
7905
if test "$host_cpu" = ia64; then
7906
# VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
7907
# chokes on -Wl,-G. The following line is correct:
7910
if test "$aix_use_runtimelinking" = yes; then
7911
shared_flag='-qmkshrobj ${wl}-G'
7913
shared_flag='-qmkshrobj'
7918
# Let the compiler handle the export list.
7919
_LT_AC_TAGVAR(always_export_symbols, $1)=no
7920
if test "$aix_use_runtimelinking" = yes; then
7921
# Warning - without using the other runtime loading flags (-brtl),
7922
# -berok will link without error, but may produce a broken library.
7923
_LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok'
7924
# Determine the default libpath from the value encoded in an empty executable.
7925
_LT_AC_SYS_LIBPATH_AIX
7926
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
7928
_LT_AC_TAGVAR(archive_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '" $shared_flag"
7929
_LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $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"
7931
if test "$host_cpu" = ia64; then
7932
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
7933
_LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
7934
_LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols"
7936
# Determine the default libpath from the value encoded in an empty executable.
7937
_LT_AC_SYS_LIBPATH_AIX
7938
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
7939
# Warning - without using the other run time loading flags,
7940
# -berok will link without error, but may produce a broken library.
7941
_LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
7942
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
7943
# -bexpall does not export symbols beginning with underscore (_)
7944
_LT_AC_TAGVAR(always_export_symbols, $1)=yes
7945
# Exported symbols can be pulled into shared objects from archives
7946
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=' '
7947
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
7948
# This is similar to how AIX traditionally builds it's shared libraries.
7949
_LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
7954
case $cc_basename in
7956
# FIXME: insert proper C++ library support
7957
_LT_AC_TAGVAR(ld_shlibs, $1)=no
7962
case $cc_basename in
7964
# FIXME: insert proper C++ library support
7965
_LT_AC_TAGVAR(ld_shlibs, $1)=no
7968
# Green Hills C++ Compiler
7969
# FIXME: insert proper C++ library support
7970
_LT_AC_TAGVAR(ld_shlibs, $1)=no
7973
# FIXME: insert proper C++ library support
7974
_LT_AC_TAGVAR(ld_shlibs, $1)=no
7979
# C++ shared libraries reported to be fairly broken before switch to ELF
7980
_LT_AC_TAGVAR(ld_shlibs, $1)=no
7983
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
7986
# FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF
7988
_LT_AC_TAGVAR(ld_shlibs, $1)=yes
7993
if test $with_gnu_ld = no; then
7994
if test "$host_cpu" = ia64; then
7995
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
7997
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
7998
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
7999
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
8002
if test "$host_cpu" = ia64; then
8003
_LT_AC_TAGVAR(hardcode_direct, $1)=no
8004
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
8006
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
8008
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
8009
# but as the default
8010
# location of the library.
8012
case $cc_basename in
8014
# FIXME: insert proper C++ library support
8015
_LT_AC_TAGVAR(ld_shlibs, $1)=no
8020
_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'
8023
if test "$host_cpu" = ia64; then
8024
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname -o $lib $linker_flags $libobjs $deplibs'
8026
_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'
8030
# Commands to make compiler produce verbose output that lists
8031
# what "hidden" libraries, object files and flags are used when
8032
# linking a shared library.
8034
# There doesn't appear to be a way to prevent this compiler from
8035
# explicitly linking system object files so we need to strip them
8036
# from the output so that they don't get included in the library
8038
output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | egrep "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
8041
if test "$GXX" = yes; then
8042
if test $with_gnu_ld = no; then
8045
_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'
8048
if test "$host_cpu" = ia64; then
8049
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname -o $lib $linker_flags $libobjs $deplibs'
8051
_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'
8057
# FIXME: insert proper C++ library support
8058
_LT_AC_TAGVAR(ld_shlibs, $1)=no
8064
case $cc_basename in
8067
_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 ${objdir}/so_locations -o $lib'
8069
# Archives containing C++ object files must be created using
8070
# "CC -ar", where "CC" is the IRIX C++ compiler. This is
8071
# necessary to make sure instantiated templates are included
8073
_LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs'
8076
if test "$GXX" = yes; then
8077
if test "$with_gnu_ld" = no; then
8078
_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}${objdir}/so_locations -o $lib'
8080
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -o $lib'
8083
_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
8086
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
8087
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
8090
case $cc_basename in
8092
# Kuck and Associates, Inc. (KAI) C++ Compiler
8094
# KCC will only create a shared library if the output file
8095
# ends with ".so" (or ".sl" for HP-UX), so rename the library
8096
# to its proper name (with version) after linking.
8097
_LT_AC_TAGVAR(archive_cmds, $1)='templib=`echo $lib | sed -e "s/\.so\..*/\.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
8098
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='templib=`echo $lib | sed -e "s/\.so\..*/\.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib ${wl}-retain-symbols-file,$export_symbols; mv \$templib $lib'
8100
# Commands to make compiler produce verbose output that lists
8101
# what "hidden" libraries, object files and flags are used when
8102
# linking a shared library.
8104
# There doesn't appear to be a way to prevent this compiler from
8105
# explicitly linking system object files so we need to strip them
8106
# from the output so that they don't get included in the library
8108
output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest.so 2>&1 | egrep "ld"`; rm -f libconftest.so; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
8110
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath,$libdir'
8111
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
8113
# Archives containing C++ object files must be created using
8114
# "CC -Bstatic", where "CC" is the KAI C++ compiler.
8115
_LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs'
8119
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
8120
_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'
8122
runpath_var=LD_RUN_PATH
8123
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
8124
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
8126
# Commands to make compiler produce verbose output that lists
8127
# what "hidden" libraries, object files and flags are used when
8128
# linking a shared library.
8130
# There doesn't appear to be a way to prevent this compiler from
8131
# explicitly linking system object files so we need to strip them
8132
# from the output so that they don't get included in the library
8134
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'
8139
# FIXME: insert proper C++ library support
8140
_LT_AC_TAGVAR(ld_shlibs, $1)=no
8143
# FIXME: insert proper C++ library support
8144
_LT_AC_TAGVAR(ld_shlibs, $1)=no
8147
case $cc_basename in
8149
# FIXME: insert proper C++ library support
8150
_LT_AC_TAGVAR(ld_shlibs, $1)=no
8153
# FIXME: insert proper C++ library support
8154
_LT_AC_TAGVAR(ld_shlibs, $1)=no
8159
# NetBSD uses g++ - do we need to do anything?
8162
case $cc_basename in
8164
# Kuck and Associates, Inc. (KAI) C++ Compiler
8166
# KCC will only create a shared library if the output file
8167
# ends with ".so" (or ".sl" for HP-UX), so rename the library
8168
# to its proper name (with version) after linking.
8169
_LT_AC_TAGVAR(archive_cmds, $1)='templib=`echo $lib | sed -e "s/\.so\..*/\.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
8171
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
8172
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
8174
# Archives containing C++ object files must be created using
8175
# "CC -Bstatic", where "CC" is the KAI C++ compiler.
8176
_LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs'
8180
# Rational C++ 2.4.1
8181
# FIXME: insert proper C++ library support
8182
_LT_AC_TAGVAR(ld_shlibs, $1)=no
8185
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
8186
_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 ${objdir}/so_locations -o $lib'
8188
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
8189
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
8191
# Commands to make compiler produce verbose output that lists
8192
# what "hidden" libraries, object files and flags are used when
8193
# linking a shared library.
8195
# There doesn't appear to be a way to prevent this compiler from
8196
# explicitly linking system object files so we need to strip them
8197
# from the output so that they don't get included in the library
8199
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'
8202
if test "$GXX" = yes && test "$with_gnu_ld" = no; then
8203
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
8204
_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}${objdir}/so_locations -o $lib'
8206
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
8207
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
8209
# Commands to make compiler produce verbose output that lists
8210
# what "hidden" libraries, object files and flags are used when
8211
# linking a shared library.
8212
output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | egrep "\-L"'
8215
# FIXME: insert proper C++ library support
8216
_LT_AC_TAGVAR(ld_shlibs, $1)=no
8222
case $cc_basename in
8224
# Kuck and Associates, Inc. (KAI) C++ Compiler
8226
# KCC will only create a shared library if the output file
8227
# ends with ".so" (or ".sl" for HP-UX), so rename the library
8228
# to its proper name (with version) after linking.
8229
_LT_AC_TAGVAR(archive_cmds, $1)='templib=`echo $lib | sed -e "s/\.so\..*/\.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
8231
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
8232
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
8234
# Archives containing C++ object files must be created using
8235
# the KAI C++ compiler.
8236
_LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs'
8239
# Rational C++ 2.4.1
8240
# FIXME: insert proper C++ library support
8241
_LT_AC_TAGVAR(ld_shlibs, $1)=no
8244
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
8245
_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 ${objdir}/so_locations -o $lib'
8246
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "-exported_symbol " >> $lib.exp; echo "\$i" >> $lib.exp; done~
8247
echo "-hidden">> $lib.exp~
8248
$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 $objdir/so_locations -o $lib~
8251
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
8252
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
8254
# Commands to make compiler produce verbose output that lists
8255
# what "hidden" libraries, object files and flags are used when
8256
# linking a shared library.
8258
# There doesn't appear to be a way to prevent this compiler from
8259
# explicitly linking system object files so we need to strip them
8260
# from the output so that they don't get included in the library
8262
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'
8265
if test "$GXX" = yes && test "$with_gnu_ld" = no; then
8266
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
8267
_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}${objdir}/so_locations -o $lib'
8269
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
8270
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
8272
# Commands to make compiler produce verbose output that lists
8273
# what "hidden" libraries, object files and flags are used when
8274
# linking a shared library.
8275
output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | egrep "\-L"'
8278
# FIXME: insert proper C++ library support
8279
_LT_AC_TAGVAR(ld_shlibs, $1)=no
8285
# FIXME: insert proper C++ library support
8286
_LT_AC_TAGVAR(ld_shlibs, $1)=no
8289
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
8290
case $cc_basename in
8292
# FIXME: insert proper C++ library support
8293
_LT_AC_TAGVAR(ld_shlibs, $1)=no
8296
# FIXME: insert proper C++ library support
8297
_LT_AC_TAGVAR(ld_shlibs, $1)=no
8302
case $cc_basename in
8305
# FIXME: insert proper C++ library support
8306
_LT_AC_TAGVAR(ld_shlibs, $1)=no
8310
# FIXME: insert proper C++ library support
8311
_LT_AC_TAGVAR(ld_shlibs, $1)=no
8314
# FIXME: insert proper C++ library support
8315
_LT_AC_TAGVAR(ld_shlibs, $1)=no
8320
case $cc_basename in
8322
# Sun C++ 4.2, 5.x and Centerline C++
8323
_LT_AC_TAGVAR(no_undefined_flag, $1)=' -zdefs'
8324
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -nolib -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
8325
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
8326
$CC -G${allow_undefined_flag} -nolib ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
8328
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
8329
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
8331
solaris2.[0-5] | solaris2.[0-5].*) ;;
8333
# The C++ compiler is used as linker so we must use $wl
8334
# flag to pass the commands to the underlying system
8336
# Supported since Solaris 2.6 (maybe 2.5.1?)
8337
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
8340
_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
8342
# Commands to make compiler produce verbose output that lists
8343
# what "hidden" libraries, object files and flags are used when
8344
# linking a shared library.
8346
# There doesn't appear to be a way to prevent this compiler from
8347
# explicitly linking system object files so we need to strip them
8348
# from the output so that they don't get included in the library
8350
output_verbose_link_cmd='templist=`$CC -G $CFLAGS -v conftest.$objext 2>&1 | egrep "\-R|\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
8352
# Archives containing C++ object files must be created using
8353
# "CC -xar", where "CC" is the Sun C++ compiler. This is
8354
# necessary to make sure instantiated templates are included
8356
_LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
8359
# Green Hills C++ Compiler
8360
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
8362
# The C++ compiler must be used to create the archive.
8363
_LT_AC_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs'
8366
# GNU C++ compiler with Solaris linker
8367
if test "$GXX" = yes && test "$with_gnu_ld" = no; then
8368
_LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs'
8369
if $CC --version | egrep -v '^2\.7' > /dev/null; then
8370
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $linker_flags ${wl}-h $wl$soname -o $lib'
8371
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
8372
$CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags~$rm $lib.exp'
8374
# Commands to make compiler produce verbose output that lists
8375
# what "hidden" libraries, object files and flags are used when
8376
# linking a shared library.
8377
output_verbose_link_cmd="$CC -shared $CFLAGS -v conftest.$objext 2>&1 | egrep \"\-L\""
8379
# g++ 2.7 appears to require `-G' NOT `-shared' on this
8381
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $linker_flags ${wl}-h $wl$soname -o $lib'
8382
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
8383
$CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags~$rm $lib.exp'
8385
# Commands to make compiler produce verbose output that lists
8386
# what "hidden" libraries, object files and flags are used when
8387
# linking a shared library.
8388
output_verbose_link_cmd="$CC -G $CFLAGS -v conftest.$objext 2>&1 | egrep \"\-L\""
8391
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir'
8396
sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[[78]]* | unixware7*)
8397
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
8400
case $cc_basename in
8402
# NonStop-UX NCC 3.20
8403
# FIXME: insert proper C++ library support
8404
_LT_AC_TAGVAR(ld_shlibs, $1)=no
8407
# FIXME: insert proper C++ library support
8408
_LT_AC_TAGVAR(ld_shlibs, $1)=no
8413
# FIXME: insert proper C++ library support
8414
_LT_AC_TAGVAR(ld_shlibs, $1)=no
8417
# FIXME: insert proper C++ library support
8418
_LT_AC_TAGVAR(ld_shlibs, $1)=no
8421
AC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)])
8422
test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
8424
# Figure out "hidden" C++ library dependencies from verbose
8425
# compiler output whening linking a shared library.
8426
cat > conftest.$ac_ext <<EOF
8430
Foo (void) { a = 0; }
8437
if AC_TRY_EVAL(ac_compile); then
8438
# Parse the compiler output and extract the necessary
8439
# objects, libraries and library flags.
8441
# Sentinel used to keep track of whether or not we are before
8442
# the conftest object file.
8443
pre_test_object_deps_done=no
8445
# The `*' in the case matches for architectures that use `case' in
8446
# $output_verbose_cmd can trigger glob expansion during the loop
8447
# eval without this substitution.
8448
output_verbose_link_cmd="`$echo \"X$output_verbose_link_cmd\" | $Xsed -e \"$no_glob_subst\"`"
8450
for p in `eval $output_verbose_link_cmd`; do
8454
# Some compilers place space between "-{L,R}" and the path.
8457
|| test $p = "-R"; then
8464
if test "$pre_test_object_deps_done" = no; then
8467
# Internal compiler library paths should come after those
8468
# provided the user. The postdeps already come after the
8469
# user supplied libs so there is no need to process them.
8470
if test -z "$_LT_AC_TAGVAR(compiler_lib_search_path, $1)"; then
8471
_LT_AC_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}"
8473
_LT_AC_TAGVAR(compiler_lib_search_path, $1)="${_LT_AC_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}"
8476
# The "-l" case would never come before the object being
8477
# linked, so don't bother handling this case.
8480
if test -z "$_LT_AC_TAGVAR(postdeps, $1)"; then
8481
_LT_AC_TAGVAR(postdeps, $1)="${prev}${p}"
8483
_LT_AC_TAGVAR(postdeps, $1)="${_LT_AC_TAGVAR(postdeps, $1)} ${prev}${p}"
8488
*.$objext|*.$libext)
8489
# This assumes that the test object file only shows up
8490
# once in the compiler output.
8491
if test "$p" = "conftest.$objext"; then
8492
pre_test_object_deps_done=yes
8496
if test "$pre_test_object_deps_done" = no; then
8497
if test -z "$_LT_AC_TAGVAR(predep_objects, $1)"; then
8498
_LT_AC_TAGVAR(predep_objects, $1)="$p"
8500
_LT_AC_TAGVAR(predep_objects, $1)="$_LT_AC_TAGVAR(predep_objects, $1) $p"
8503
if test -z "$_LT_AC_TAGVAR(postdep_objects, $1)"; then
8504
_LT_AC_TAGVAR(postdep_objects, $1)="$p"
8506
_LT_AC_TAGVAR(postdep_objects, $1)="$_LT_AC_TAGVAR(postdep_objects, $1) $p"
8511
*) ;; # Ignore the rest.
8519
echo "libtool.m4: error: problem compiling C++ test program"
8522
$rm -f confest.$objext
8524
case " $_LT_AC_TAGVAR(postdeps, $1) " in
8525
*" -lc "*) _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no ;;
8526
*) _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes ;;
8529
_LT_AC_TAGVAR(GCC, $1)="$GXX"
8530
_LT_AC_TAGVAR(LD, $1)="$LD"
8533
## There is no encapsulation within the following macros, do not change
8534
## the running order or otherwise move them around unless you know exactly
8535
## what you are doing...
8536
AC_LIBTOOL_PROG_COMPILER_PIC($1)
8537
AC_LIBTOOL_PROG_CC_C_O($1)
8538
AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
8539
AC_LIBTOOL_PROG_LD_SHLIBS($1)
8540
AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
8541
AC_LIBTOOL_SYS_LIB_STRIP
8542
AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
8543
AC_LIBTOOL_DLOPEN_SELF($1)
8545
AC_LIBTOOL_CONFIG($1)
8549
])# AC_LIBTOOL_LANG_CXX_CONFIG
8552
# AC_LIBTOOL_LANG_GCJ_CONFIG
8553
# --------------------------
8554
# Ensure that the configuration vars for the C compiler are
8555
# suitably defined. Those variables are subsequently used by
8556
# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
8557
AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG], [_LT_AC_LANG_GCJ_CONFIG(GCJ)])
8558
AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG],
8561
# Source file extension for C test sources.
8564
# Object file extension for compiled C test sources.
8566
_LT_AC_TAGVAR(objext, $1)=$objext
8568
# Code to be used in simple compile tests
8569
lt_simple_compile_test_code="class foo {}"
8571
# Code to be used in simple link tests
8572
lt_simple_link_test_code='public class conftest { public static void main(String[] argv) {}; }'
8574
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
8577
# Allow CC to be a program name with arguments.
8582
_LT_AC_TAGVAR(compiler, $1)=$CC
8584
# GCJ did not exist at the time GCC didn't implicitly link libc in.
8585
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
8588
## There is no encapsulation within the following macros, do not change
8589
## the running order or otherwise move them around unless you know exactly
8590
## what you are doing...
8591
AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1)
8592
AC_LIBTOOL_PROG_COMPILER_PIC($1)
8593
AC_LIBTOOL_PROG_CC_C_O($1)
8594
AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
8595
AC_LIBTOOL_PROG_LD_SHLIBS($1)
8596
AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
8597
AC_LIBTOOL_SYS_LIB_STRIP
8598
AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
8599
AC_LIBTOOL_DLOPEN_SELF($1)
8601
AC_LIBTOOL_CONFIG($1)
8605
])# AC_LIBTOOL_LANG_GCJ_CONFIG
8608
# AC_LIBTOOL_LANG_RC_CONFIG
8609
# --------------------------
8610
# Ensure that the configuration vars for the Windows resource compiler are
8611
# suitably defined. Those variables are subsequently used by
8612
# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
8613
AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG], [_LT_AC_LANG_RC_CONFIG(RC)])
8614
AC_DEFUN([_LT_AC_LANG_RC_CONFIG],
8617
# Source file extension for RC test sources.
8620
# Object file extension for compiled RC test sources.
8622
_LT_AC_TAGVAR(objext, $1)=$objext
8624
# Code to be used in simple compile tests
8625
lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }'
8627
# Code to be used in simple link tests
8628
lt_simple_link_test_code="$lt_simple_compile_test_code"
8630
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
8633
# Allow CC to be a program name with arguments.
8638
_LT_AC_TAGVAR(compiler, $1)=$CC
8639
_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
8641
AC_LIBTOOL_CONFIG($1)
8645
])# AC_LIBTOOL_LANG_RC_CONFIG
8648
# AC_LIBTOOL_CONFIG([TAGNAME])
8649
# ----------------------------
8650
# If TAGNAME is not passed, then create an initial libtool script
8651
# with a default configuration from the untagged config vars. Otherwise
8652
# add code to config.status for appending the configuration named by
8653
# TAGNAME from the matching tagged config vars.
8654
AC_DEFUN([AC_LIBTOOL_CONFIG],
8655
[# The else clause should only fire when bootstrapping the
8656
# libtool distribution, otherwise you forgot to ship ltmain.sh
8657
# with your package, and you will get complaints that there are
8658
# no rules to generate ltmain.sh.
8659
if test -f "$ltmain"; then
8660
# Now quote all the things that may contain metacharacters while being
8661
# careful not to overquote the AC_SUBSTed values. We take copies of the
8662
# variables and quote the copies for generation of the libtool script.
8663
for var in echo old_CC old_CFLAGS AR AR_FLAGS RANLIB LN_S LTCC NM SED SHELL \
8664
libname_spec library_names_spec soname_spec extract_expsyms_cmds \
8665
old_striplib striplib file_magic_cmd finish_cmds finish_eval \
8666
deplibs_check_method reload_flag reload_cmds need_locks \
8667
lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \
8668
lt_cv_sys_global_symbol_to_c_name_address \
8669
sys_lib_search_path_spec sys_lib_dlsearch_path_spec \
8670
old_postinstall_cmds old_postuninstall_cmds \
8671
_LT_AC_TAGVAR(compiler, $1) \
8672
_LT_AC_TAGVAR(CC, $1) \
8673
_LT_AC_TAGVAR(LD, $1) \
8674
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1) \
8675
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) \
8676
_LT_AC_TAGVAR(lt_prog_compiler_static, $1) \
8677
_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) \
8678
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1) \
8679
_LT_AC_TAGVAR(thread_safe_flag_spec, $1) \
8680
_LT_AC_TAGVAR(whole_archive_flag_spec, $1) \
8681
_LT_AC_TAGVAR(old_archive_cmds, $1) \
8682
_LT_AC_TAGVAR(old_archive_from_new_cmds, $1) \
8683
_LT_AC_TAGVAR(predep_objects, $1) \
8684
_LT_AC_TAGVAR(postdep_objects, $1) \
8685
_LT_AC_TAGVAR(predeps, $1) \
8686
_LT_AC_TAGVAR(postdeps, $1) \
8687
_LT_AC_TAGVAR(compiler_lib_search_path, $1) \
8688
_LT_AC_TAGVAR(archive_cmds, $1) \
8689
_LT_AC_TAGVAR(archive_expsym_cmds, $1) \
8690
_LT_AC_TAGVAR(postinstall_cmds, $1) \
8691
_LT_AC_TAGVAR(postuninstall_cmds, $1) \
8692
_LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) \
8693
_LT_AC_TAGVAR(allow_undefined_flag, $1) \
8694
_LT_AC_TAGVAR(no_undefined_flag, $1) \
8695
_LT_AC_TAGVAR(export_symbols_cmds, $1) \
8696
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) \
8697
_LT_AC_TAGVAR(hardcode_libdir_separator, $1) \
8698
_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1) \
8699
_LT_AC_TAGVAR(exclude_expsyms, $1) \
8700
_LT_AC_TAGVAR(include_expsyms, $1); do
8703
_LT_AC_TAGVAR(old_archive_cmds, $1) | \
8704
_LT_AC_TAGVAR(old_archive_from_new_cmds, $1) | \
8705
_LT_AC_TAGVAR(archive_cmds, $1) | \
8706
_LT_AC_TAGVAR(archive_expsym_cmds, $1) | \
8707
_LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) | \
8708
_LT_AC_TAGVAR(export_symbols_cmds, $1) | \
8709
extract_expsyms_cmds | reload_cmds | finish_cmds | \
8710
postinstall_cmds | postuninstall_cmds | \
8711
old_postinstall_cmds | old_postuninstall_cmds | \
8712
sys_lib_search_path_spec | sys_lib_dlsearch_path_spec)
8713
# Double-quote double-evaled strings.
8714
eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\""
8717
eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\""
8723
*'\[$]0 --fallback-echo"')
8724
lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\[$]0 --fallback-echo"[$]/[$]0 --fallback-echo"/'`
8729
[cfgfile="${ofile}T"
8730
trap "$rm \"$cfgfile\"; exit 1" 1 2 15
8732
AC_MSG_NOTICE([creating $ofile])],
8735
cat <<__EOF__ >> "$cfgfile"
8739
# `$echo "$cfgfile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
8740
# Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP)
8741
# NOTE: Changes made to this file will be lost: look at ltmain.sh.
8743
# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001
8744
# Free Software Foundation, Inc.
8746
# This file is part of GNU Libtool:
8747
# Originally by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
8749
# This program is free software; you can redistribute it and/or modify
8750
# it under the terms of the GNU General Public License as published by
8751
# the Free Software Foundation; either version 2 of the License, or
8752
# (at your option) any later version.
8754
# This program is distributed in the hope that it will be useful, but
8755
# WITHOUT ANY WARRANTY; without even the implied warranty of
8756
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
8757
# General Public License for more details.
8759
# You should have received a copy of the GNU General Public License
8760
# along with this program; if not, write to the Free Software
8761
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
8763
# As a special exception to the GNU General Public License, if you
8764
# distribute this file as part of a program that contains a
8765
# configuration script generated by Autoconf, you may include it under
8766
# the same distribution terms that you use for the rest of that program.
8768
# Sed that helps us avoid accidentally triggering echo(1) options like -n.
8769
Xsed="sed -e s/^X//"
8771
# The HP-UX ksh and POSIX shell print the target directory to stdout
8773
if test "X\${CDPATH+set}" = Xset; then CDPATH=:; export CDPATH; fi
8775
# The names of the tagged configurations supported by this script.
8778
# ### BEGIN LIBTOOL CONFIG],
8779
[# ### BEGIN LIBTOOL TAG CONFIG: $tagname])
8781
# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
8783
# Shell to use when invoking shell scripts.
8786
# Whether or not to build shared libraries.
8787
build_libtool_libs=$enable_shared
8789
# Whether or not to build static libraries.
8790
build_old_libs=$enable_static
8792
# Whether or not to add -lc for building shared libraries.
8793
build_libtool_need_lc=$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)
8795
# Whether or not to optimize for fast installation.
8796
fast_install=$enable_fast_install
8799
host_alias=$host_alias
8802
# An echo program that does not interpret backslashes.
8807
AR_FLAGS=$lt_AR_FLAGS
8812
# A language-specific compiler.
8813
CC=$lt_[]_LT_AC_TAGVAR(compiler, $1)
8815
# Is the compiler the GNU C compiler?
8816
with_gcc=$_LT_AC_TAGVAR(GCC, $1)
8818
# The linker used to build libraries.
8819
LD=$lt_[]_LT_AC_TAGVAR(LD, $1)
8821
# Whether we need hard or soft links.
8824
# A BSD-compatible nm program.
8827
# A sed program that does not truncate output.
8830
# A symbol stripping program
8833
# Used to examine libraries when file_magic_cmd begins "file"
8834
MAGIC_CMD=$MAGIC_CMD
8836
# Used on cygwin: DLL creation program.
8839
# Used on cygwin: object dumper.
8842
# Used on cygwin: assembler.
8845
# The name of the directory that contains temporary libtool files.
8848
# How to create reloadable object files.
8849
reload_flag=$lt_reload_flag
8850
reload_cmds=$lt_reload_cmds
8852
# How to pass a linker flag through the compiler.
8853
wl=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)
8855
# Object file suffix (normally "o").
8858
# Old archive suffix (normally "a").
8861
# Executable file suffix (normally "").
8864
# Additional compiler flags for building library objects.
8865
pic_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)
8868
# What is the maximum length of a command?
8869
max_cmd_len=$lt_cv_sys_max_cmd_len
8871
# Does compiler simultaneously support -c and -o options?
8872
compiler_c_o=$lt_[]_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)
8874
# Must we lock files when doing compilation ?
8875
need_locks=$lt_need_locks
8877
# Do we need the lib prefix for modules?
8878
need_lib_prefix=$need_lib_prefix
8880
# Do we need a version for libraries?
8881
need_version=$need_version
8883
# Whether dlopen is supported.
8884
dlopen_support=$enable_dlopen
8886
# Whether dlopen of programs is supported.
8887
dlopen_self=$enable_dlopen_self
8889
# Whether dlopen of statically linked programs is supported.
8890
dlopen_self_static=$enable_dlopen_self_static
8892
# Compiler flag to prevent dynamic linking.
8893
link_static_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_static, $1)
8895
# Compiler flag to turn off builtin functions.
8896
no_builtin_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)
8898
# Compiler flag to allow reflexive dlopens.
8899
export_dynamic_flag_spec=$lt_[]_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)
8901
# Compiler flag to generate shared objects directly from archives.
8902
whole_archive_flag_spec=$lt_[]_LT_AC_TAGVAR(whole_archive_flag_spec, $1)
8904
# Compiler flag to generate thread-safe objects.
8905
thread_safe_flag_spec=$lt_[]_LT_AC_TAGVAR(thread_safe_flag_spec, $1)
8907
# Library versioning type.
8908
version_type=$version_type
8910
# Format of library name prefix.
8911
libname_spec=$lt_libname_spec
8913
# List of archive names. First name is the real one, the rest are links.
8914
# The last name is the one that the linker finds with -lNAME.
8915
library_names_spec=$lt_library_names_spec
8917
# The coded name of the library, if different from the real name.
8918
soname_spec=$lt_soname_spec
8920
# Commands used to build and install an old-style archive.
8922
old_archive_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_cmds, $1)
8923
old_postinstall_cmds=$lt_old_postinstall_cmds
8924
old_postuninstall_cmds=$lt_old_postuninstall_cmds
8926
# Create an old-style archive from a shared archive.
8927
old_archive_from_new_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_from_new_cmds, $1)
8929
# Create a temporary old-style archive to link instead of a shared archive.
8930
old_archive_from_expsyms_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1)
8932
# Commands used to build and install a shared archive.
8933
archive_cmds=$lt_[]_LT_AC_TAGVAR(archive_cmds, $1)
8934
archive_expsym_cmds=$lt_[]_LT_AC_TAGVAR(archive_expsym_cmds, $1)
8935
postinstall_cmds=$lt_postinstall_cmds
8936
postuninstall_cmds=$lt_postuninstall_cmds
8938
# Commands to strip libraries.
8939
old_striplib=$lt_old_striplib
8940
striplib=$lt_striplib
8942
# Dependencies to place before the objects being linked to create a
8944
predep_objects=$lt_[]_LT_AC_TAGVAR(predep_objects, $1)
8946
# Dependencies to place after the objects being linked to create a
8948
postdep_objects=$lt_[]_LT_AC_TAGVAR(postdep_objects, $1)
8950
# Dependencies to place before the objects being linked to create a
8952
predeps=$lt_[]_LT_AC_TAGVAR(predeps, $1)
8954
# Dependencies to place after the objects being linked to create a
8956
postdeps=$lt_[]_LT_AC_TAGVAR(postdeps, $1)
8958
# The library search path used internally by the compiler when linking
8960
compiler_lib_search_path=$lt_[]_LT_AC_TAGVAR(compiler_lib_search_path, $1)
8962
# Method to check whether dependent libraries are shared objects.
8963
deplibs_check_method=$lt_deplibs_check_method
8965
# Command to use when deplibs_check_method == file_magic.
8966
file_magic_cmd=$lt_file_magic_cmd
8968
# Flag that allows shared libraries with undefined symbols to be built.
8969
allow_undefined_flag=$lt_[]_LT_AC_TAGVAR(allow_undefined_flag, $1)
8971
# Flag that forces no undefined symbols.
8972
no_undefined_flag=$lt_[]_LT_AC_TAGVAR(no_undefined_flag, $1)
8974
# Commands used to finish a libtool library installation in a directory.
8975
finish_cmds=$lt_finish_cmds
8977
# Same as above, but a single script fragment to be evaled but not shown.
8978
finish_eval=$lt_finish_eval
8980
# Take the output of nm and produce a listing of raw symbols and C names.
8981
global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
8983
# Transform the output of nm in a proper C declaration
8984
global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
8986
# Transform the output of nm in a C name address pair
8987
global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
8989
# This is the shared library runtime path variable.
8990
runpath_var=$runpath_var
8992
# This is the shared library path variable.
8993
shlibpath_var=$shlibpath_var
8995
# Is shlibpath searched before the hard-coded library search path?
8996
shlibpath_overrides_runpath=$shlibpath_overrides_runpath
8998
# How to hardcode a shared library path into an executable.
8999
hardcode_action=$_LT_AC_TAGVAR(hardcode_action, $1)
9001
# Whether we should hardcode library paths into libraries.
9002
hardcode_into_libs=$hardcode_into_libs
9004
# Flag to hardcode \$libdir into a binary during linking.
9005
# This must work even if \$libdir does not exist.
9006
hardcode_libdir_flag_spec=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)
9008
# Whether we need a single -rpath flag with a separated argument.
9009
hardcode_libdir_separator=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_separator, $1)
9011
# Set to yes if using DIR/libNAME.so during linking hardcodes DIR into the
9013
hardcode_direct=$_LT_AC_TAGVAR(hardcode_direct, $1)
9015
# Set to yes if using the -LDIR flag during linking hardcodes DIR into the
9017
hardcode_minus_L=$_LT_AC_TAGVAR(hardcode_minus_L, $1)
9019
# Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into
9020
# the resulting binary.
9021
hardcode_shlibpath_var=$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)
9023
# Variables whose values should be saved in libtool wrapper scripts and
9024
# restored at relink time.
9025
variables_saved_for_relink="$variables_saved_for_relink"
9027
# Whether libtool must link a program against all its dependency libraries.
9028
link_all_deplibs=$_LT_AC_TAGVAR(link_all_deplibs, $1)
9030
# Compile-time system search path for libraries
9031
sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
9033
# Run-time system search path for libraries
9034
sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
9036
# Fix the shell variable \$srcfile for the compiler.
9037
fix_srcfile_path="$_LT_AC_TAGVAR(fix_srcfile_path, $1)"
9039
# Set to yes if exported symbols are required.
9040
always_export_symbols=$_LT_AC_TAGVAR(always_export_symbols, $1)
9042
# The commands to list exported symbols.
9043
export_symbols_cmds=$lt_[]_LT_AC_TAGVAR(export_symbols_cmds, $1)
9045
# The commands to extract the exported symbol list from a shared archive.
9046
extract_expsyms_cmds=$lt_extract_expsyms_cmds
9048
# Symbols that should not be listed in the preloaded symbols.
9049
exclude_expsyms=$lt_[]_LT_AC_TAGVAR(exclude_expsyms, $1)
9051
# Symbols that must always be exported.
9052
include_expsyms=$lt_[]_LT_AC_TAGVAR(include_expsyms, $1)
9055
[# ### END LIBTOOL CONFIG],
9056
[# ### END LIBTOOL TAG CONFIG: $tagname])
9063
cat <<\EOF >> "$cfgfile"
9065
# AIX sometimes has problems with the GCC collect2 program. For some
9066
# reason, if we set the COLLECT_NAMES environment variable, the problems
9067
# vanish in a puff of smoke.
9068
if test "X${COLLECT_NAMES+set}" != Xset; then
9070
export COLLECT_NAMES
9075
cygwin* | mingw* | pw32* | os2*)
9076
cat <<'EOF' >> "$cfgfile"
9077
# This is a source program that is used to create dlls on Windows
9078
# Don't remove nor modify the starting and closing comments
9080
# This is a source program that is used to create import libraries
9081
# on Windows for dlls which lack them. Don't remove nor modify the
9082
# starting and closing comments
9083
_LT_AC_FILE_IMPGEN_C
9088
# We use sed instead of cat because bash on DJGPP gets confused if
9089
# if finds mixed CR/LF and LF-only lines. Since sed operates in
9090
# text mode, it properly converts lines to CR/LF. This bash problem
9091
# is reportedly fixed, but why not run on old versions too?
9092
sed '$q' "$ltmain" >> "$cfgfile" || (rm -f "$cfgfile"; exit 1)
9094
mv -f "$cfgfile" "$ofile" || \
9095
(rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
9099
# If there is no Makefile yet, we rely on a make rule to execute
9100
# `config.status --recheck' to rerun these tests and create the
9101
# libtool script then.
9102
test -f Makefile && make "$ltmain"
9104
])# AC_LIBTOOL_CONFIG
9107
# AC_LIBTOOL_PROG_COMPILER_NO_RTTI([TAGNAME])
9108
# -------------------------------------------
9109
AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI],
9110
[AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl
9112
_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
9114
if test "$GCC" = yes; then
9115
_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
9117
AC_LIBTOOL_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions],
9118
lt_cv_prog_compiler_rtti_exceptions,
9119
[-fno-rtti -fno-exceptions -c conftest.$ac_ext], [],
9120
[_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"])
9122
])# AC_LIBTOOL_PROG_COMPILER_NO_RTTI
9125
# AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
9126
# ---------------------------------
9127
AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE],
9128
[AC_REQUIRE([AC_CANONICAL_HOST])
9129
AC_REQUIRE([AC_PROG_NM])
9130
AC_REQUIRE([AC_OBJEXT])
9131
# Check for command to grab the raw symbol name followed by C symbol from nm.
9132
AC_MSG_CHECKING([command to parse $NM output from $compiler object])
9133
AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe],
9135
# These are sane defaults that work on at least a few old systems.
9136
# [They come from Ultrix. What could be older than Ultrix?!! ;)]
9138
# Character class describing NM global symbol codes.
9139
symcode='[[BCDEGRST]]'
9141
# Regexp to match symbols that can be accessed directly from C.
9142
sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)'
9144
# Transform the above into a raw symbol and a C symbol.
9145
symxfrm='\1 \2\3 \3'
9147
# Transform an extracted symbol line into a proper C declaration
9148
lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern int \1;/p'"
9150
# Transform an extracted symbol line into symbol name and symbol address
9151
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'"
9153
# Define system-specific variables.
9158
cygwin* | mingw* | pw32*)
9159
symcode='[[ABCDGISTW]]'
9161
hpux*) # Its linker distinguishes data from code symbols
9162
if test "$host_cpu" = ia64; then
9163
symcode='[[ABCDEGRST]]'
9165
lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
9166
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'"
9169
symcode='[[BCDEGRST]]'
9175
symcode='[[DFNSTU]]'
9179
# Handle CRLF in mingw tool chain
9183
opt_cr=`echo 'x\{0,1\}' | tr x '\015'` # option cr in regexp
9187
# If we're using GNU nm, then use its standard symbol codes.
9188
if $NM -V 2>&1 | egrep '(GNU|with BFD)' > /dev/null; then
9189
symcode='[[ABCDGISTW]]'
9192
# Try without a prefix undercore, then with it.
9193
for ac_symprfx in "" "_"; do
9195
# Write the raw and C identifiers.
9196
lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*\($ac_symprfx\)$sympat$opt_cr$/$symxfrm/p'"
9198
# Check to see that the pipe works correctly.
9202
cat > conftest.$ac_ext <<EOF
9207
void nm_test_func(){}
9211
int main(){nm_test_var='a';nm_test_func();return(0);}
9214
if AC_TRY_EVAL(ac_compile); then
9215
# Now try to grab the symbols.
9217
if AC_TRY_EVAL(NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) && test -s "$nlist"; then
9218
# Try sorting and uniquifying the output.
9219
if sort "$nlist" | uniq > "$nlist"T; then
9220
mv -f "$nlist"T "$nlist"
9225
# Make sure that we snagged all the symbols we need.
9226
if egrep ' nm_test_var$' "$nlist" >/dev/null; then
9227
if egrep ' nm_test_func$' "$nlist" >/dev/null; then
9228
cat <<EOF > conftest.$ac_ext
9234
# Now generate the symbol file.
9235
eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | grep -v main >> conftest.$ac_ext'
9237
cat <<EOF >> conftest.$ac_ext
9238
#if defined (__STDC__) && __STDC__
9239
# define lt_ptr_t void *
9241
# define lt_ptr_t char *
9245
/* The mapping between symbol names and symbols. */
9250
lt_preloaded_symbols[[]] =
9253
sed "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (lt_ptr_t) \&\2},/" < "$nlist" | grep -v main >> conftest.$ac_ext
9254
cat <<\EOF >> conftest.$ac_ext
9262
# Now try linking the two files.
9263
mv conftest.$ac_objext conftstm.$ac_objext
9264
lt_save_LIBS="$LIBS"
9265
lt_save_CFLAGS="$CFLAGS"
9266
LIBS="conftstm.$ac_objext"
9267
CFLAGS="$CFLAGS$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)"
9268
if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then
9271
LIBS="$lt_save_LIBS"
9272
CFLAGS="$lt_save_CFLAGS"
9274
echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD
9277
echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD
9280
echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD
9283
echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD
9284
cat conftest.$ac_ext >&5
9286
rm -f conftest* conftst*
9288
# Do not use the global_symbol_pipe unless it works.
9289
if test "$pipe_works" = yes; then
9292
lt_cv_sys_global_symbol_pipe=
9296
if test -z "$lt_cv_sys_global_symbol_pipe"; then
9297
lt_cv_sys_global_symbol_to_cdecl=
9299
if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
9300
AC_MSG_RESULT(failed)
9304
]) # AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
9307
# AC_LIBTOOL_PROG_COMPILER_PIC([TAGNAME])
9308
# ---------------------------------------
9309
AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC],
9310
[_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)=
9311
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
9312
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)=
9314
AC_MSG_CHECKING([for $compiler option to produce PIC])
9316
# C++ specific cases for pic, static, wl, etc.
9317
if test "$GXX" = yes; then
9318
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
9319
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
9323
# All AIX code is PIC.
9324
if test "$host_cpu" = ia64; then
9325
# AIX 5 now supports IA64 processor
9326
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
9330
# FIXME: we need at least 68020 code to build shared libraries, but
9331
# adding the `-m68020' flag to GCC prevents building anything better,
9333
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
9335
beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
9336
# PIC is the default for these OSes.
9338
cygwin* | mingw* | os2*)
9339
# This hack is so that the source file can tell whether it is being
9340
# built for inclusion in a dll (and should export symbols for example).
9341
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
9343
darwin* | rhapsody*)
9344
# PIC is the default on this platform
9345
# Common symbols not allowed in MH_DYLIB files
9346
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
9349
# DJGPP does not support shared libraries at all
9350
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
9353
if test -d /usr/nec; then
9354
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
9358
# PIC is the default for IA64 HP-UX, but not for PA HP-UX.
9359
if test "$host_cpu" != ia64; then
9360
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
9364
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
9370
# All AIX code is PIC.
9371
if test "$host_cpu" = ia64; then
9372
# AIX 5 now supports IA64 processor
9373
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
9375
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
9379
case $cc_basename in
9381
# Green Hills C++ Compiler
9382
# _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"
9387
case $cc_basename in
9389
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
9392
# Green Hills C++ Compiler
9393
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
9400
# FreeBSD uses GNU C++
9402
hpux9* | hpux10* | hpux11*)
9403
case $cc_basename in
9405
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
9406
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)="${ac_cv_prog_cc_wl}-a ${ac_cv_prog_cc_wl}archive"
9407
if test "$host_cpu" != ia64; then
9408
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
9412
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
9413
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)="${ac_cv_prog_cc_wl}-a ${ac_cv_prog_cc_wl}archive"
9414
if test "$host_cpu" != ia64; then
9415
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
9422
irix5* | irix6* | nonstopux*)
9423
case $cc_basename in
9425
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
9426
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
9427
# CC pic flag -KPIC is the default.
9434
case $cc_basename in
9437
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
9438
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
9442
# Make sure the PIC flag is empty. It appears that all Alpha
9443
# Linux and Compaq Tru64 Unix objects are PIC.
9444
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
9445
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
9456
case $cc_basename in
9458
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall'
9466
osf3* | osf4* | osf5*)
9467
case $cc_basename in
9469
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
9472
# Rational C++ 2.4.1
9473
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
9476
# Digital/Compaq C++
9477
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
9478
# Make sure the PIC flag is empty. It appears that all Alpha
9479
# Linux and Compaq Tru64 Unix objects are PIC.
9480
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
9481
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
9490
case $cc_basename in
9492
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
9499
case $cc_basename in
9501
# Sun C++ 4.2, 5.x and Centerline C++
9502
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
9503
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
9504
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
9507
# Green Hills C++ Compiler
9508
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
9515
case $cc_basename in
9518
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
9519
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
9523
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
9530
case $cc_basename in
9532
# NonStop-UX NCC 3.20
9533
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
9544
_LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
9550
if test "$GCC" = yes; then
9551
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
9552
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
9556
# All AIX code is PIC.
9557
if test "$host_cpu" = ia64; then
9558
# AIX 5 now supports IA64 processor
9559
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
9564
# FIXME: we need at least 68020 code to build shared libraries, but
9565
# adding the `-m68020' flag to GCC prevents building anything better,
9567
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
9570
beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
9571
# PIC is the default for these OSes.
9574
cygwin* | mingw* | pw32* | os2*)
9575
# This hack is so that the source file can tell whether it is being
9576
# built for inclusion in a dll (and should export symbols for example).
9577
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
9580
darwin* | rhapsody*)
9581
# PIC is the default on this platform
9582
# Common symbols not allowed in MH_DYLIB files
9583
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
9587
# Just because we use GCC doesn't mean we suddenly get shared libraries
9588
# on systems that don't support them.
9589
_LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
9594
if test -d /usr/nec; then
9595
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
9600
# PIC is the default for IA64 HP-UX, but not for PA HP-UX.
9601
if test "$host_cpu" != ia64; then
9602
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
9607
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
9611
# PORTME Check for flag to pass linker flags through the system compiler.
9614
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
9615
if test "$host_cpu" = ia64; then
9616
# AIX 5 now supports IA64 processor
9617
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
9619
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
9623
cygwin* | mingw* | pw32* | os2*)
9624
# This hack is so that the source file can tell whether it is being
9625
# built for inclusion in a dll (and should export symbols for example).
9626
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
9629
hpux9* | hpux10* | hpux11*)
9630
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
9631
if test "$host_cpu" != ia64; then
9632
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
9634
# Is there a better lt_prog_compiler_static that works with the bundled CC?
9635
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
9638
irix5* | irix6* | nonstopux*)
9639
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
9640
# PIC (with -KPIC) is the default.
9641
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
9645
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
9646
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
9649
osf3* | osf4* | osf5*)
9650
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
9651
# All OSF/1 code is PIC.
9652
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
9656
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-Kpic'
9657
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-dn'
9661
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
9662
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
9663
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
9667
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
9668
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
9669
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
9672
sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
9673
if test "x$host_vendor" = xsni; then
9674
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-LD'
9676
_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
9678
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
9679
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
9683
if test -d /usr/nec ;then
9684
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic'
9685
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
9690
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
9691
_LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
9695
_LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
9700
AC_MSG_RESULT([$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)])
9703
# Check to make sure the PIC flag actually works.
9705
if test -n "$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)"; then
9706
AC_LIBTOOL_COMPILER_OPTION([if $compiler PIC flag $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) works],
9707
_LT_AC_TAGVAR(lt_prog_compiler_pic_works, $1),
9708
[$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) -DPIC], [],
9709
[case $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) in
9711
*) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)" ;;
9713
[_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
9714
_LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no])
9717
# For platforms which do not support PIC, -DPIC is meaningless:
9719
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
9722
_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) -DPIC"
9728
# AC_LIBTOOL_PROG_LD_SHLIBS([TAGNAME])
9729
# ------------------------------------
9730
# See if the linker supports building shared libraries.
9731
AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS],
9732
[AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
9734
_LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | sed '\''s/.* //'\'' | sort | uniq > $export_symbols'
9737
# If we're using GNU nm, then we don't want the "-C" option.
9738
# -C means demangle to AIX nm, but means don't demangle with GNU nm
9739
if $NM -V 2>&1 | egrep '(GNU)' > /dev/null; then
9740
_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'
9742
_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'
9745
cygwin* | mingw* | pw32*)
9746
_LT_AC_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds"
9749
_LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | sed '\''s/.* //'\'' | sort | uniq > $export_symbols'
9754
_LT_AC_TAGVAR(allow_undefined_flag, $1)=
9756
_LT_AC_TAGVAR(archive_cmds, $1)=
9757
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=
9758
_LT_AC_TAGVAR(archive_expsym_cmds, $1)=
9759
_LT_AC_TAGVAR(old_archive_From_new_cmds, $1)=
9760
_LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1)=
9761
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
9762
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
9763
_LT_AC_TAGVAR(thread_safe_flag_spec, $1)=
9764
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
9765
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
9766
_LT_AC_TAGVAR(hardcode_direct, $1)=no
9767
_LT_AC_TAGVAR(hardcode_minus_L, $1)=no
9768
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
9769
_LT_AC_TAGVAR(link_all_deplibs, $1)=unknown
9770
_LT_AC_TAGVAR(always_export_symbols, $1)=no
9771
_LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | sed '\''s/.* //'\'' | sort | uniq > $export_symbols'
9772
# include_expsyms should be a list of space-separated symbols to be *always*
9773
# included in the symbol list
9774
_LT_AC_TAGVAR(include_expsyms, $1)=
9775
# exclude_expsyms can be an egrep regular expression of symbols to exclude
9776
# it will be wrapped by ` (' and `)$', so one must not match beginning or
9777
# end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
9778
# as well as any symbol that contains `d'.
9779
_LT_AC_TAGVAR(exclude_expsyms, $1)="_GLOBAL_OFFSET_TABLE_"
9780
# Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
9781
# platforms (ab)use it in PIC code, but their linkers get confused if
9782
# the symbol is explicitly referenced. Since portable code cannot
9783
# rely on this symbol name, it's probably fine to never include it in
9784
# preloaded symbol tables.
9785
extract_expsyms_cmds=
9788
cygwin* | mingw* | pw32*)
9789
# FIXME: the MSVC++ port hasn't been tested in a loooong time
9790
# When not using gcc, we currently assume that we are using
9791
# Microsoft Visual C++.
9792
if test "$GCC" != yes; then
9801
_LT_AC_TAGVAR(ld_shlibs, $1)=yes
9802
if test "$with_gnu_ld" = yes; then
9803
# If archive_cmds runs LD, not CC, wlarc should be empty
9806
# See if GNU ld supports shared libraries.
9808
aix3* | aix4* | aix5*)
9809
# On AIX/PPC, the GNU linker is very broken
9810
if test "$host_cpu" != ia64; then
9811
_LT_AC_TAGVAR(ld_shlibs, $1)=no
9814
*** Warning: the GNU linker, at least up to release 2.9.1, is reported
9815
*** to be unable to reliably create shared libraries on AIX.
9816
*** Therefore, libtool is disabling shared libraries support. If you
9817
*** really care for shared libraries, you may want to modify your PATH
9818
*** so that a non-GNU linker is found, and then restart.
9825
_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)'
9826
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
9827
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
9829
# Samuel A. Falvo II <kc5tja@dolphin.openprojects.net> reports
9830
# that the semantics of dynamic libraries on AmigaOS, at least up
9831
# to version 4, is to share data among multiple programs linked
9832
# with the same dynamic library. Since this doesn't match the
9833
# behavior of shared libraries on other platforms, we can't use
9835
_LT_AC_TAGVAR(ld_shlibs, $1)=no
9839
if $LD --help 2>&1 | egrep ': supported targets:.* elf' > /dev/null; then
9840
_LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
9841
# Joseph Beckenbach <jrb3@best.com> says some releases of gcc
9842
# support --undefined. This deserves some investigation. FIXME
9843
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
9845
_LT_AC_TAGVAR(ld_shlibs, $1)=no
9849
cygwin* | mingw* | pw32*)
9850
# _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, as there is
9851
# no search path for DLLs.
9852
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
9853
_LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
9854
_LT_AC_TAGVAR(always_export_symbols, $1)=yes
9856
extract_expsyms_cmds='test -f $output_objdir/impgen.c || \
9857
sed -e "/^# \/\* impgen\.c starts here \*\//,/^# \/\* impgen.c ends here \*\// { s/^# //;s/^# *$//; p; }" -e d < $''0 > $output_objdir/impgen.c~
9858
test -f $output_objdir/impgen.exe || (cd $output_objdir && \
9859
if test "x$HOST_CC" != "x" ; then $HOST_CC -o impgen impgen.c ; \
9860
else $CC -o impgen impgen.c ; fi)~
9861
$output_objdir/impgen $dir/$soroot > $output_objdir/$soname-def'
9863
_LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1)='$DLLTOOL --as=$AS --dllname $soname --def $output_objdir/$soname-def --output-lib $output_objdir/$newlib'
9865
# cygwin and mingw dlls have different entry points and sets of symbols
9867
# FIXME: what about values for MSVC?
9868
dll_entry=__cygwin_dll_entry@12
9869
dll_exclude_symbols=DllMain@12,_cygwin_dll_entry@12,_cygwin_noncygwin_dll_entry@12~
9873
dll_entry=_DllMainCRTStartup@12
9874
dll_exclude_symbols=DllMain@12,DllMainCRTStartup@12,DllEntryPoint@12~
9878
# mingw and cygwin differ, and it's simplest to just exclude the union
9879
# of the two symbol sets.
9880
dll_exclude_symbols=DllMain@12,_cygwin_dll_entry@12,_cygwin_noncygwin_dll_entry@12,DllMainCRTStartup@12,DllEntryPoint@12
9882
# recent cygwin and mingw systems supply a stub DllMain which the user
9883
# can override, but on older systems we have to supply one (in ltdll.c)
9884
if test "x$lt_cv_need_dllmain" = "xyes"; then
9885
ltdll_obj='$output_objdir/$soname-ltdll.'"$ac_objext "
9886
ltdll_cmds='test -f $output_objdir/$soname-ltdll.c || sed -e "/^# \/\* ltdll\.c starts here \*\//,/^# \/\* ltdll.c ends here \*\// { s/^# //; p; }" -e d < $''0 > $output_objdir/$soname-ltdll.c~
9887
test -f $output_objdir/$soname-ltdll.$ac_objext || (cd $output_objdir && $CC -c $soname-ltdll.c)~'
9893
# Extract the symbol export list from an `--export-all' def file,
9894
# then regenerate the def file from the symbol export list, so that
9895
# the compiled dll only exports the symbol export list.
9896
# Be careful not to strip the DATA tag left by newer dlltools.
9897
_LT_AC_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds"'
9898
$DLLTOOL --export-all --exclude-symbols '$dll_exclude_symbols' --output-def $output_objdir/$soname-def '$ltdll_obj'$libobjs $convenience~
9899
sed -e "1,/EXPORTS/d" -e "s/ @ [[0-9]]*//" -e "s/ *;.*$//" < $output_objdir/$soname-def > $export_symbols'
9901
# If the export-symbols file already is a .def file (1st line
9902
# is EXPORTS), use it as is.
9903
# If DATA tags from a recent dlltool are present, honour them!
9904
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`head -1 $export_symbols`" = xEXPORTS; then
9905
cp $export_symbols $output_objdir/$soname-def;
9907
echo EXPORTS > $output_objdir/$soname-def;
9909
cat $export_symbols | while read symbol; do
9912
2) echo " \[$]2 @ \$_lt_hint ; " >> $output_objdir/$soname-def;;
9913
*) echo " \[$]2 @ \$_lt_hint \[$]3 ; " >> $output_objdir/$soname-def;;
9915
_lt_hint=`expr 1 + \$_lt_hint`;
9919
$CC -Wl,--base-file,$output_objdir/$soname-base '$lt_cv_cc_dll_switch' -Wl,-e,'$dll_entry' -o $output_objdir/$soname '$ltdll_obj'$libobjs $deplibs $compiler_flags~
9920
$DLLTOOL --as=$AS --dllname $soname --exclude-symbols '$dll_exclude_symbols' --def $output_objdir/$soname-def --base-file $output_objdir/$soname-base --output-exp $output_objdir/$soname-exp~
9921
$CC -Wl,--base-file,$output_objdir/$soname-base $output_objdir/$soname-exp '$lt_cv_cc_dll_switch' -Wl,-e,'$dll_entry' -o $output_objdir/$soname '$ltdll_obj'$libobjs $deplibs $compiler_flags~
9922
$DLLTOOL --as=$AS --dllname $soname --exclude-symbols '$dll_exclude_symbols' --def $output_objdir/$soname-def --base-file $output_objdir/$soname-base --output-exp $output_objdir/$soname-exp --output-lib $output_objdir/$libname.dll.a~
9923
$CC $output_objdir/$soname-exp '$lt_cv_cc_dll_switch' -Wl,-e,'$dll_entry' -o $output_objdir/$soname '$ltdll_obj'$libobjs $deplibs $compiler_flags'
9927
if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
9928
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
9931
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nodefaultlibs $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
9932
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared -nodefaultlibs $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
9937
if $LD -v 2>&1 | egrep 'BFD 2\.8' > /dev/null; then
9938
_LT_AC_TAGVAR(ld_shlibs, $1)=no
9941
*** Warning: The releases 2.8.* of the GNU linker cannot reliably
9942
*** create shared libraries on Solaris systems. Therefore, libtool
9943
*** is disabling shared libraries support. We urge you to upgrade GNU
9944
*** binutils to release 2.9.1 or newer. Another option is to modify
9945
*** your PATH or compiler configuration so that the native linker is
9946
*** used, and then restart.
9949
elif $LD --help 2>&1 | egrep ': supported targets:.* elf' > /dev/null; then
9950
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
9951
_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'
9953
_LT_AC_TAGVAR(ld_shlibs, $1)=no
9958
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
9960
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
9961
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
9965
if $LD --help 2>&1 | egrep ': supported targets:.* elf' > /dev/null; then
9966
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
9967
_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'
9969
_LT_AC_TAGVAR(ld_shlibs, $1)=no
9974
if test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = yes; then
9975
runpath_var=LD_RUN_PATH
9976
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
9977
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
9979
cygwin* | mingw* | pw32*)
9980
# dlltool doesn't understand --whole-archive et. al.
9981
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
9984
# ancient GNU ld didn't support --whole-archive et. al.
9985
if $LD --help 2>&1 | egrep 'no-whole-archive' > /dev/null; then
9986
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
9988
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
9994
# PORTME fill in a description of your system's linker (not GNU ld)
9997
_LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
9998
_LT_AC_TAGVAR(always_export_symbols, $1)=yes
9999
_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'
10000
# Note: this linker hardcodes the directories in LIBPATH if there
10001
# are no directories specified by -L.
10002
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
10003
if test "$GCC" = yes && test -z "$link_static_flag"; then
10004
# Neither direct hardcoding nor static linking is supported with a
10006
_LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
10011
if test "$host_cpu" = ia64; then
10012
# On IA64, the linker does run time linking by default, so we don't
10013
# have to do anything special.
10014
aix_use_runtimelinking=no
10015
exp_sym_flag='-Bexport'
10018
# If we're using GNU nm, then we don't want the "-C" option.
10019
# -C means demangle to AIX nm, but means don't demangle with GNU nm
10020
if $NM -V 2>&1 | egrep '(GNU)' > /dev/null; then
10021
_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'
10023
_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'
10026
# KDE requires run time linking. Make it the default.
10027
aix_use_runtimelinking=yes
10028
exp_sym_flag='-bexport'
10029
no_entry_flag='-bnoentry'
10032
# When large executables or shared objects are built, AIX ld can
10033
# have problems creating the table of contents. If linking a library
10034
# or program results in "error TOC overflow" add -mminimal-toc to
10035
# CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
10036
# enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
10038
_LT_AC_TAGVAR(archive_cmds, $1)=''
10039
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
10040
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
10041
_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
10043
if test "$GCC" = yes; then
10044
case $host_os in aix4.[012]|aix4.[012].*)
10045
# We only want to do this on AIX 4.2 and lower, the check
10046
# below for broken collect2 doesn't work under 4.3+
10047
collect2name=`${CC} -print-prog-name=collect2`
10048
if test -f "$collect2name" && \
10049
strings "$collect2name" | grep resolve_lib_name >/dev/null
10051
# We have reworked collect2
10052
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
10054
# We have old collect2
10055
_LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
10056
# It fails to find uninstalled libraries when the uninstalled
10057
# path is not listed in the libpath. Setting hardcode_minus_L
10058
# to unsupported forces relinking
10059
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
10060
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
10061
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
10064
shared_flag='-shared'
10067
if test "$host_cpu" = ia64; then
10068
# VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
10069
# chokes on -Wl,-G. The following line is correct:
10072
if test "$aix_use_runtimelinking" = yes; then
10073
shared_flag='-qmkshrobj ${wl}-G'
10075
shared_flag='-qmkshrobj'
10080
# Let the compiler handle the export list.
10081
_LT_AC_TAGVAR(always_export_symbols, $1)=no
10082
if test "$aix_use_runtimelinking" = yes; then
10083
# Warning - without using the other runtime loading flags (-brtl),
10084
# -berok will link without error, but may produce a broken library.
10085
_LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok'
10086
# Determine the default libpath from the value encoded in an empty executable.
10087
_LT_AC_SYS_LIBPATH_AIX
10088
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
10089
_LT_AC_TAGVAR(archive_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '" $shared_flag"
10090
_LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $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"
10092
if test "$host_cpu" = ia64; then
10093
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
10094
_LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
10095
_LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols"
10097
# Determine the default libpath from the value encoded in an empty executable.
10098
_LT_AC_SYS_LIBPATH_AIX
10099
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
10100
# Warning - without using the other run time loading flags,
10101
# -berok will link without error, but may produce a broken library.
10102
_LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
10103
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
10104
# -bexpall does not export symbols beginning with underscore (_)
10105
_LT_AC_TAGVAR(always_export_symbols, $1)=yes
10106
# Exported symbols can be pulled into shared objects from archives
10107
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=' '
10108
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
10109
# This is similar to how AIX traditionally builds it's shared libraries.
10110
_LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
10116
_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)'
10117
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
10118
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
10119
# see comment about different semantics on the GNU ld section
10120
_LT_AC_TAGVAR(ld_shlibs, $1)=no
10124
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic
10127
cygwin* | mingw* | pw32*)
10128
# When not using gcc, we currently assume that we are using
10129
# Microsoft Visual C++.
10130
# hardcode_libdir_flag_spec is actually meaningless, as there is
10131
# no search path for DLLs.
10132
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
10133
_LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
10134
# Tell ltmain to make .lib files, not .a files.
10136
# FIXME: Setting linknames here is a bad hack.
10137
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | sed -e '\''s/ -lc$//'\''` -link -dll~linknames='
10138
# The linker will automatically build a .lib file if we build a DLL.
10139
_LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='true'
10140
# FIXME: Should let the user specify the lib program.
10141
_LT_AC_TAGVAR(old_archive_cmds, $1)='lib /OUT:$oldlib$oldobjs$old_deplibs'
10142
fix_srcfile_path='`cygpath -w "$srcfile"`'
10145
darwin* | rhapsody*)
10147
rhapsody* | darwin1.[[012]])
10148
_LT_AC_TAGVAR(allow_undefined_flag, $1)='-undefined suppress'
10151
_LT_AC_TAGVAR(allow_undefined_flag, $1)='-flat_namespace -undefined suppress'
10155
# FIXME: Relying on posixy $() will cause problems for
10156
# cross-compilation, but unfortunately the echo tests do not
10157
# yet detect zsh echo's removal of \ escapes. Also zsh mangles
10158
# `"' quotes if we put them in here... so don't!
10159
_LT_AC_TAGVAR(archive_cmds, $1)='$CC $(test .$module = .yes && echo -bundle || echo -dynamiclib) $allow_undefined_flag -o $lib $libobjs $deplibs$linker_flags -install_name $rpath/$soname $verstring'
10160
# We need to add '_' to the symbols in $export_symbols first
10161
#_LT_AC_TAGVAR(archive_expsym_cmds, $1)="$_LT_AC_TAGVAR(archive_cmds, $1)"' && strip -s $export_symbols'
10162
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
10163
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
10164
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-all_load $convenience'
10168
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
10169
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
10170
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
10174
_LT_AC_TAGVAR(ld_shlibs, $1)=no
10177
# FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
10178
# support. Future versions do this automatically, but an explicit c++rt0.o
10179
# does not break anything, and helps significantly (at the cost of a little
10182
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
10183
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
10184
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
10185
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
10188
# Unfortunately, older versions of FreeBSD 2 do not have this feature.
10190
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
10191
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
10192
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
10193
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
10196
# FreeBSD 3 and greater uses gcc -shared to do shared libraries.
10198
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
10199
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
10200
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
10201
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
10204
hpux9* | hpux10* | hpux11*)
10205
if test "$GCC" = yes; then
10208
_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'
10211
if test "$host_cpu" = ia64; then
10212
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
10214
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
10221
_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'
10224
if test "$host_cpu" = ia64; then
10225
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname -o $lib $libobjs $deplibs $linker_flags'
10227
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
10232
if test "$host_cpu" = ia64; then
10233
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
10234
_LT_AC_TAGVAR(hardcode_direct, $1)=no
10235
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
10237
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
10238
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
10239
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
10241
# hardcode_minus_L: Not really in the search PATH,
10242
# but as the default location of the library.
10243
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
10244
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
10247
irix5* | irix6* | nonstopux*)
10248
if test "$GCC" = yes; then
10249
_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'
10251
_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'
10253
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
10254
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
10255
_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
10259
if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
10260
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
10262
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF
10264
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
10265
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
10266
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
10270
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
10271
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
10272
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
10273
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
10274
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
10278
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
10279
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
10281
if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
10282
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $linker_flags'
10283
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
10284
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
10287
openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*)
10288
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
10289
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
10292
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $linker_flags'
10293
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
10300
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
10301
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
10302
_LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
10303
_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'
10304
_LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
10308
if test "$GCC" = yes; then
10309
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
10310
_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'
10312
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
10313
_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'
10315
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
10316
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
10319
osf4* | osf5*) # as osf3* with the addition of -msym flag
10320
if test "$GCC" = yes; then
10321
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
10322
_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'
10323
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
10325
_LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
10326
_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'
10327
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "-exported_symbol " >> $lib.exp; echo "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~
10328
$LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${objdir}/so_locations -o $lib~$rm $lib.exp'
10330
# Both c and cxx compiler support -rpath directly
10331
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
10333
_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
10337
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
10338
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
10339
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
10340
runpath_var=LD_RUN_PATH
10341
hardcode_runpath_var=yes
10345
_LT_AC_TAGVAR(no_undefined_flag, $1)=' -z text'
10346
if test "$GCC" = yes; then
10347
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
10348
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
10349
$CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp'
10351
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
10352
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
10353
$LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
10355
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
10356
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
10358
solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
10359
*) # Supported since Solaris 2.6 (maybe 2.5.1?)
10360
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' ;;
10362
_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
10366
if test "x$host_vendor" = xsequent; then
10367
# Use $CC to link under sequent, because it throws in some extra .o
10368
# files that make .init and .fini sections work.
10369
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
10371
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
10373
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
10374
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
10375
_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
10376
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
10380
if test "x$host_vendor" = xsni; then
10381
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -Bsymbolic -h $soname -o $lib $libobjs $deplibs $linker_flags'
10382
_LT_AC_TAGVAR(hardcode_direct, $1)=yes # is this really true???
10384
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
10385
_LT_AC_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie
10387
runpath_var='LD_RUN_PATH'
10388
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
10392
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
10393
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
10394
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport'
10398
if test -d /usr/nec; then
10399
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
10400
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
10401
runpath_var=LD_RUN_PATH
10402
hardcode_runpath_var=yes
10403
_LT_AC_TAGVAR(ld_shlibs, $1)=yes
10408
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags'
10409
_LT_AC_TAGVAR(hardcode_direct, $1)=yes
10410
_LT_AC_TAGVAR(hardcode_minus_L, $1)=no
10411
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
10412
hardcode_runpath_var=yes
10413
runpath_var=LD_RUN_PATH
10416
sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[[78]]* | unixware7*)
10417
_LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z ${wl}text'
10418
if test "$GCC" = yes; then
10419
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
10421
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
10423
runpath_var='LD_RUN_PATH'
10424
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
10428
_LT_AC_TAGVAR(no_undefined_flag, $1)=' -z text'
10429
# $CC -shared without GNU ld will not create a library from C++
10430
# object files and a static libstdc++, better avoid it by now
10431
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
10432
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
10433
$LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
10434
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
10435
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
10436
runpath_var='LD_RUN_PATH'
10440
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
10441
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
10442
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
10446
_LT_AC_TAGVAR(ld_shlibs, $1)=no
10451
AC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)])
10452
test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
10454
variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
10455
if test "$GCC" = yes; then
10456
variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
10460
# Do we need to explicitly link libc?
10462
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
10463
if test "$enable_shared" = yes && test "$GCC" = yes; then
10464
case $_LT_AC_TAGVAR(archive_cmds, $1) in
10466
# FIXME: we may have to deal with multi-command sequences.
10469
# Test whether the compiler implicitly links with -lc since on some
10470
# systems, -lgcc has to come before -lc. If gcc already passes -lc
10471
# to ld, don't add -lc before -lgcc.
10472
AC_MSG_CHECKING([whether -lc should be explicitly linked in])
10474
echo 'static int dummy;' > conftest.$ac_ext
10476
if AC_TRY_EVAL(ac_compile) 2>conftest.err; then
10479
libobjs=conftest.$ac_objext
10481
wl=$_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)
10487
lt_save_allow_undefined_flag=$_LT_AC_TAGVAR(allow_undefined_flag, $1)
10488
_LT_AC_TAGVAR(allow_undefined_flag, $1)=
10489
if AC_TRY_EVAL(_LT_AC_TAGVAR(archive_cmds, $1) 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1)
10491
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
10493
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
10495
_LT_AC_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag
10497
cat conftest.err 1>&5
10500
AC_MSG_RESULT([$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)])
10504
])# AC_LIBTOOL_PROG_LD_SHLIBS
10507
# _LT_AC_FILE_LTDLL_C
10508
# -------------------
10509
# Be careful that the start marker always follows a newline.
10510
AC_DEFUN([_LT_AC_FILE_LTDLL_C], [
10511
# /* ltdll.c starts here */
10512
# #define WIN32_LEAN_AND_MEAN
10513
# #include <windows.h>
10514
# #undef WIN32_LEAN_AND_MEAN
10515
# #include <stdio.h>
10517
# #ifndef __CYGWIN__
10518
# # ifdef __CYGWIN32__
10519
# # define __CYGWIN__ __CYGWIN32__
10523
# #ifdef __cplusplus
10526
# BOOL APIENTRY DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved);
10527
# #ifdef __cplusplus
10531
# #ifdef __CYGWIN__
10532
# #include <cygwin/cygwin_dll.h>
10533
# DECLARE_CYGWIN_DLL( DllMain );
10535
# HINSTANCE __hDllInstance_base;
10538
# DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved)
10540
# __hDllInstance_base = hInst;
10543
# /* ltdll.c ends here */
10544
])# _LT_AC_FILE_LTDLL_C
10547
# _LT_AC_FILE_IMPGEN_C
10548
# --------------------
10549
# Be careful that the start marker always follows a newline.
10550
AC_DEFUN([_LT_AC_FILE_IMPGEN_C], [
10551
# /* impgen.c starts here */
10552
# /* Copyright (C) 1999, 2000, 2001 Free Software Foundation, Inc.
10554
# This file is part of GNU libtool.
10556
# This program is free software; you can redistribute it and/or modify
10557
# it under the terms of the GNU General Public License as published by
10558
# the Free Software Foundation; either version 2 of the License, or
10559
# (at your option) any later version.
10561
# This program is distributed in the hope that it will be useful,
10562
# but WITHOUT ANY WARRANTY; without even the implied warranty of
10563
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
10564
# GNU General Public License for more details.
10566
# You should have received a copy of the GNU General Public License
10567
# along with this program; if not, write to the Free Software
10568
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
10571
# #include <stdio.h> /* for printf() */
10572
# #include <unistd.h> /* for open(), lseek(), read() */
10573
# #include <fcntl.h> /* for O_RDONLY, O_BINARY */
10574
# #include <string.h> /* for strdup() */
10576
# /* O_BINARY isn't required (or even defined sometimes) under Unix */
10578
# #define O_BINARY 0
10581
# static unsigned int
10582
# pe_get16 (fd, offset)
10586
# unsigned char b[2];
10587
# lseek (fd, offset, SEEK_SET);
10589
# return b[0] + (b[1]<<8);
10592
# static unsigned int
10593
# pe_get32 (fd, offset)
10597
# unsigned char b[4];
10598
# lseek (fd, offset, SEEK_SET);
10600
# return b[0] + (b[1]<<8) + (b[2]<<16) + (b[3]<<24);
10603
# static unsigned int
10607
# unsigned char *b = ptr;
10608
# return b[0] + (b[1]<<8) + (b[2]<<16) + (b[3]<<24);
10612
# main (argc, argv)
10617
# unsigned long pe_header_offset, opthdr_ofs, num_entries, i;
10618
# unsigned long export_rva, export_size, nsections, secptr, expptr;
10619
# unsigned long name_rvas, nexp;
10620
# unsigned char *expdata, *erva;
10621
# char *filename, *dll_name;
10623
# filename = argv[1];
10625
# dll = open(filename, O_RDONLY|O_BINARY);
10629
# dll_name = filename;
10631
# for (i=0; filename[i]; i++)
10632
# if (filename[i] == '/' || filename[i] == '\\' || filename[i] == ':')
10633
# dll_name = filename + i +1;
10635
# pe_header_offset = pe_get32 (dll, 0x3c);
10636
# opthdr_ofs = pe_header_offset + 4 + 20;
10637
# num_entries = pe_get32 (dll, opthdr_ofs + 92);
10639
# if (num_entries < 1) /* no exports */
10642
# export_rva = pe_get32 (dll, opthdr_ofs + 96);
10643
# export_size = pe_get32 (dll, opthdr_ofs + 100);
10644
# nsections = pe_get16 (dll, pe_header_offset + 4 +2);
10645
# secptr = (pe_header_offset + 4 + 20 +
10646
# pe_get16 (dll, pe_header_offset + 4 + 16));
10649
# for (i = 0; i < nsections; i++)
10652
# unsigned long secptr1 = secptr + 40 * i;
10653
# unsigned long vaddr = pe_get32 (dll, secptr1 + 12);
10654
# unsigned long vsize = pe_get32 (dll, secptr1 + 16);
10655
# unsigned long fptr = pe_get32 (dll, secptr1 + 20);
10656
# lseek(dll, secptr1, SEEK_SET);
10657
# read(dll, sname, 8);
10658
# if (vaddr <= export_rva && vaddr+vsize > export_rva)
10660
# expptr = fptr + (export_rva - vaddr);
10661
# if (export_rva + export_size > vaddr + vsize)
10662
# export_size = vsize - (export_rva - vaddr);
10667
# expdata = (unsigned char*)malloc(export_size);
10668
# lseek (dll, expptr, SEEK_SET);
10669
# read (dll, expdata, export_size);
10670
# erva = expdata - export_rva;
10672
# nexp = pe_as32 (expdata+24);
10673
# name_rvas = pe_as32 (expdata+32);
10675
# printf ("EXPORTS\n");
10676
# for (i = 0; i<nexp; i++)
10678
# unsigned long name_rva = pe_as32 (erva+name_rvas+i*4);
10679
# printf ("\t%s @ %ld ;\n", erva+name_rva, 1+ i);
10684
# /* impgen.c ends here */
10685
])# _LT_AC_FILE_IMPGEN_C
10687
# _LT_AC_TAGVAR(VARNAME, [TAGNAME])
10688
# ---------------------------------
10689
AC_DEFUN([_LT_AC_TAGVAR], [ifelse([$2], [], [$1], [$1_$2])])
6625
10693
AC_DEFUN([AM_PROG_LIBTOOL], [AC_PROG_LIBTOOL])
6626
10694
AC_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)])
6627
10695
AC_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)])