aclocal.m4 revision 9bd41f2c
19bd41f2cSmrg# generated automatically by aclocal 1.10 -*- Autoconf -*- 29bd41f2cSmrg 39bd41f2cSmrg# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 49bd41f2cSmrg# 2005, 2006 Free Software Foundation, Inc. 59bd41f2cSmrg# This file is free software; the Free Software Foundation 69bd41f2cSmrg# gives unlimited permission to copy and/or distribute it, 79bd41f2cSmrg# with or without modifications, as long as this notice is preserved. 89bd41f2cSmrg 99bd41f2cSmrg# This program is distributed in the hope that it will be useful, 109bd41f2cSmrg# but WITHOUT ANY WARRANTY, to the extent permitted by law; without 119bd41f2cSmrg# even the implied warranty of MERCHANTABILITY or FITNESS FOR A 129bd41f2cSmrg# PARTICULAR PURPOSE. 139bd41f2cSmrg 149bd41f2cSmrgm4_if(m4_PACKAGE_VERSION, [2.61],, 159bd41f2cSmrg[m4_fatal([this file was generated for autoconf 2.61. 169bd41f2cSmrgYou have another version of autoconf. If you want to use that, 179bd41f2cSmrgyou should regenerate the build system entirely.], [63])]) 189bd41f2cSmrg 199bd41f2cSmrg# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*- 209bd41f2cSmrg 219bd41f2cSmrg# serial 51 AC_PROG_LIBTOOL 229bd41f2cSmrg 239bd41f2cSmrg 249bd41f2cSmrg# AC_PROVIDE_IFELSE(MACRO-NAME, IF-PROVIDED, IF-NOT-PROVIDED) 259bd41f2cSmrg# ----------------------------------------------------------- 269bd41f2cSmrg# If this macro is not defined by Autoconf, define it here. 279bd41f2cSmrgm4_ifdef([AC_PROVIDE_IFELSE], 289bd41f2cSmrg [], 299bd41f2cSmrg [m4_define([AC_PROVIDE_IFELSE], 309bd41f2cSmrg [m4_ifdef([AC_PROVIDE_$1], 319bd41f2cSmrg [$2], [$3])])]) 329bd41f2cSmrg 339bd41f2cSmrg 349bd41f2cSmrg# AC_PROG_LIBTOOL 359bd41f2cSmrg# --------------- 369bd41f2cSmrgAC_DEFUN([AC_PROG_LIBTOOL], 379bd41f2cSmrg[AC_REQUIRE([_AC_PROG_LIBTOOL])dnl 389bd41f2cSmrgdnl If AC_PROG_CXX has already been expanded, run AC_LIBTOOL_CXX 399bd41f2cSmrgdnl immediately, otherwise, hook it in at the end of AC_PROG_CXX. 409bd41f2cSmrg AC_PROVIDE_IFELSE([AC_PROG_CXX], 419bd41f2cSmrg [AC_LIBTOOL_CXX], 429bd41f2cSmrg [define([AC_PROG_CXX], defn([AC_PROG_CXX])[AC_LIBTOOL_CXX 439bd41f2cSmrg ])]) 449bd41f2cSmrgdnl And a similar setup for Fortran 77 support 459bd41f2cSmrg AC_PROVIDE_IFELSE([AC_PROG_F77], 469bd41f2cSmrg [AC_LIBTOOL_F77], 479bd41f2cSmrg [define([AC_PROG_F77], defn([AC_PROG_F77])[AC_LIBTOOL_F77 489bd41f2cSmrg])]) 499bd41f2cSmrg 509bd41f2cSmrgdnl Quote A][M_PROG_GCJ so that aclocal doesn't bring it in needlessly. 519bd41f2cSmrgdnl If either AC_PROG_GCJ or A][M_PROG_GCJ have already been expanded, run 529bd41f2cSmrgdnl AC_LIBTOOL_GCJ immediately, otherwise, hook it in at the end of both. 539bd41f2cSmrg AC_PROVIDE_IFELSE([AC_PROG_GCJ], 549bd41f2cSmrg [AC_LIBTOOL_GCJ], 559bd41f2cSmrg [AC_PROVIDE_IFELSE([A][M_PROG_GCJ], 569bd41f2cSmrg [AC_LIBTOOL_GCJ], 579bd41f2cSmrg [AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ], 589bd41f2cSmrg [AC_LIBTOOL_GCJ], 599bd41f2cSmrg [ifdef([AC_PROG_GCJ], 609bd41f2cSmrg [define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[AC_LIBTOOL_GCJ])]) 619bd41f2cSmrg ifdef([A][M_PROG_GCJ], 629bd41f2cSmrg [define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[AC_LIBTOOL_GCJ])]) 639bd41f2cSmrg ifdef([LT_AC_PROG_GCJ], 649bd41f2cSmrg [define([LT_AC_PROG_GCJ], 659bd41f2cSmrg defn([LT_AC_PROG_GCJ])[AC_LIBTOOL_GCJ])])])]) 669bd41f2cSmrg])])# AC_PROG_LIBTOOL 679bd41f2cSmrg 689bd41f2cSmrg 699bd41f2cSmrg# _AC_PROG_LIBTOOL 709bd41f2cSmrg# ---------------- 719bd41f2cSmrgAC_DEFUN([_AC_PROG_LIBTOOL], 729bd41f2cSmrg[AC_REQUIRE([AC_LIBTOOL_SETUP])dnl 739bd41f2cSmrgAC_BEFORE([$0],[AC_LIBTOOL_CXX])dnl 749bd41f2cSmrgAC_BEFORE([$0],[AC_LIBTOOL_F77])dnl 759bd41f2cSmrgAC_BEFORE([$0],[AC_LIBTOOL_GCJ])dnl 769bd41f2cSmrg 779bd41f2cSmrg# This can be used to rebuild libtool when needed 789bd41f2cSmrgLIBTOOL_DEPS="$ac_aux_dir/ltmain.sh" 799bd41f2cSmrg 809bd41f2cSmrg# Always use our own libtool. 819bd41f2cSmrgLIBTOOL='$(SHELL) $(top_builddir)/libtool' 829bd41f2cSmrgAC_SUBST(LIBTOOL)dnl 839bd41f2cSmrg 849bd41f2cSmrg# Prevent multiple expansion 859bd41f2cSmrgdefine([AC_PROG_LIBTOOL], []) 869bd41f2cSmrg])# _AC_PROG_LIBTOOL 879bd41f2cSmrg 889bd41f2cSmrg 899bd41f2cSmrg# AC_LIBTOOL_SETUP 909bd41f2cSmrg# ---------------- 919bd41f2cSmrgAC_DEFUN([AC_LIBTOOL_SETUP], 929bd41f2cSmrg[AC_PREREQ(2.50)dnl 939bd41f2cSmrgAC_REQUIRE([AC_ENABLE_SHARED])dnl 949bd41f2cSmrgAC_REQUIRE([AC_ENABLE_STATIC])dnl 959bd41f2cSmrgAC_REQUIRE([AC_ENABLE_FAST_INSTALL])dnl 969bd41f2cSmrgAC_REQUIRE([AC_CANONICAL_HOST])dnl 979bd41f2cSmrgAC_REQUIRE([AC_CANONICAL_BUILD])dnl 989bd41f2cSmrgAC_REQUIRE([AC_PROG_CC])dnl 999bd41f2cSmrgAC_REQUIRE([AC_PROG_LD])dnl 1009bd41f2cSmrgAC_REQUIRE([AC_PROG_LD_RELOAD_FLAG])dnl 1019bd41f2cSmrgAC_REQUIRE([AC_PROG_NM])dnl 1029bd41f2cSmrg 1039bd41f2cSmrgAC_REQUIRE([AC_PROG_LN_S])dnl 1049bd41f2cSmrgAC_REQUIRE([AC_DEPLIBS_CHECK_METHOD])dnl 1059bd41f2cSmrg# Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers! 1069bd41f2cSmrgAC_REQUIRE([AC_OBJEXT])dnl 1079bd41f2cSmrgAC_REQUIRE([AC_EXEEXT])dnl 1089bd41f2cSmrgdnl 1099bd41f2cSmrg 1109bd41f2cSmrgAC_LIBTOOL_SYS_MAX_CMD_LEN 1119bd41f2cSmrgAC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE 1129bd41f2cSmrgAC_LIBTOOL_OBJDIR 1139bd41f2cSmrg 1149bd41f2cSmrgAC_REQUIRE([_LT_AC_SYS_COMPILER])dnl 1159bd41f2cSmrg_LT_AC_PROG_ECHO_BACKSLASH 1169bd41f2cSmrg 1179bd41f2cSmrgcase $host_os in 1189bd41f2cSmrgaix3*) 1199bd41f2cSmrg # AIX sometimes has problems with the GCC collect2 program. For some 1209bd41f2cSmrg # reason, if we set the COLLECT_NAMES environment variable, the problems 1219bd41f2cSmrg # vanish in a puff of smoke. 1229bd41f2cSmrg if test "X${COLLECT_NAMES+set}" != Xset; then 1239bd41f2cSmrg COLLECT_NAMES= 1249bd41f2cSmrg export COLLECT_NAMES 1259bd41f2cSmrg fi 1269bd41f2cSmrg ;; 1279bd41f2cSmrgesac 1289bd41f2cSmrg 1299bd41f2cSmrg# Sed substitution that helps us do robust quoting. It backslashifies 1309bd41f2cSmrg# metacharacters that are still active within double-quoted strings. 1319bd41f2cSmrgXsed='sed -e 1s/^X//' 1329bd41f2cSmrg[sed_quote_subst='s/\([\\"\\`$\\\\]\)/\\\1/g'] 1339bd41f2cSmrg 1349bd41f2cSmrg# Same as above, but do not quote variable references. 1359bd41f2cSmrg[double_quote_subst='s/\([\\"\\`\\\\]\)/\\\1/g'] 1369bd41f2cSmrg 1379bd41f2cSmrg# Sed substitution to delay expansion of an escaped shell variable in a 1389bd41f2cSmrg# double_quote_subst'ed string. 1399bd41f2cSmrgdelay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' 1409bd41f2cSmrg 1419bd41f2cSmrg# Sed substitution to avoid accidental globbing in evaled expressions 1429bd41f2cSmrgno_glob_subst='s/\*/\\\*/g' 1439bd41f2cSmrg 1449bd41f2cSmrg# Constants: 1459bd41f2cSmrgrm="rm -f" 1469bd41f2cSmrg 1479bd41f2cSmrg# Global variables: 1489bd41f2cSmrgdefault_ofile=libtool 1499bd41f2cSmrgcan_build_shared=yes 1509bd41f2cSmrg 1519bd41f2cSmrg# All known linkers require a `.a' archive for static linking (except MSVC, 1529bd41f2cSmrg# which needs '.lib'). 1539bd41f2cSmrglibext=a 1549bd41f2cSmrgltmain="$ac_aux_dir/ltmain.sh" 1559bd41f2cSmrgofile="$default_ofile" 1569bd41f2cSmrgwith_gnu_ld="$lt_cv_prog_gnu_ld" 1579bd41f2cSmrg 1589bd41f2cSmrgAC_CHECK_TOOL(AR, ar, false) 1599bd41f2cSmrgAC_CHECK_TOOL(RANLIB, ranlib, :) 1609bd41f2cSmrgAC_CHECK_TOOL(STRIP, strip, :) 1619bd41f2cSmrg 1629bd41f2cSmrgold_CC="$CC" 1639bd41f2cSmrgold_CFLAGS="$CFLAGS" 1649bd41f2cSmrg 1659bd41f2cSmrg# Set sane defaults for various variables 1669bd41f2cSmrgtest -z "$AR" && AR=ar 1679bd41f2cSmrgtest -z "$AR_FLAGS" && AR_FLAGS=cru 1689bd41f2cSmrgtest -z "$AS" && AS=as 1699bd41f2cSmrgtest -z "$CC" && CC=cc 1709bd41f2cSmrgtest -z "$LTCC" && LTCC=$CC 1719bd41f2cSmrgtest -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS 1729bd41f2cSmrgtest -z "$DLLTOOL" && DLLTOOL=dlltool 1739bd41f2cSmrgtest -z "$LD" && LD=ld 1749bd41f2cSmrgtest -z "$LN_S" && LN_S="ln -s" 1759bd41f2cSmrgtest -z "$MAGIC_CMD" && MAGIC_CMD=file 1769bd41f2cSmrgtest -z "$NM" && NM=nm 1779bd41f2cSmrgtest -z "$SED" && SED=sed 1789bd41f2cSmrgtest -z "$OBJDUMP" && OBJDUMP=objdump 1799bd41f2cSmrgtest -z "$RANLIB" && RANLIB=: 1809bd41f2cSmrgtest -z "$STRIP" && STRIP=: 1819bd41f2cSmrgtest -z "$ac_objext" && ac_objext=o 1829bd41f2cSmrg 1839bd41f2cSmrg# Determine commands to create old-style static archives. 1849bd41f2cSmrgold_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' 1859bd41f2cSmrgold_postinstall_cmds='chmod 644 $oldlib' 1869bd41f2cSmrgold_postuninstall_cmds= 1879bd41f2cSmrg 1889bd41f2cSmrgif test -n "$RANLIB"; then 1899bd41f2cSmrg case $host_os in 1909bd41f2cSmrg openbsd*) 1919bd41f2cSmrg old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib" 1929bd41f2cSmrg ;; 1939bd41f2cSmrg *) 1949bd41f2cSmrg old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib" 1959bd41f2cSmrg ;; 1969bd41f2cSmrg esac 1979bd41f2cSmrg old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib" 1989bd41f2cSmrgfi 1999bd41f2cSmrg 2009bd41f2cSmrg_LT_CC_BASENAME([$compiler]) 2019bd41f2cSmrg 2029bd41f2cSmrg# Only perform the check for file, if the check method requires it 2039bd41f2cSmrgcase $deplibs_check_method in 2049bd41f2cSmrgfile_magic*) 2059bd41f2cSmrg if test "$file_magic_cmd" = '$MAGIC_CMD'; then 2069bd41f2cSmrg AC_PATH_MAGIC 2079bd41f2cSmrg fi 2089bd41f2cSmrg ;; 2099bd41f2cSmrgesac 2109bd41f2cSmrg 2119bd41f2cSmrgAC_PROVIDE_IFELSE([AC_LIBTOOL_DLOPEN], enable_dlopen=yes, enable_dlopen=no) 2129bd41f2cSmrgAC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL], 2139bd41f2cSmrgenable_win32_dll=yes, enable_win32_dll=no) 2149bd41f2cSmrg 2159bd41f2cSmrgAC_ARG_ENABLE([libtool-lock], 2169bd41f2cSmrg [AC_HELP_STRING([--disable-libtool-lock], 2179bd41f2cSmrg [avoid locking (might break parallel builds)])]) 2189bd41f2cSmrgtest "x$enable_libtool_lock" != xno && enable_libtool_lock=yes 2199bd41f2cSmrg 2209bd41f2cSmrgAC_ARG_WITH([pic], 2219bd41f2cSmrg [AC_HELP_STRING([--with-pic], 2229bd41f2cSmrg [try to use only PIC/non-PIC objects @<:@default=use both@:>@])], 2239bd41f2cSmrg [pic_mode="$withval"], 2249bd41f2cSmrg [pic_mode=default]) 2259bd41f2cSmrgtest -z "$pic_mode" && pic_mode=default 2269bd41f2cSmrg 2279bd41f2cSmrg# Use C for the default configuration in the libtool script 2289bd41f2cSmrgtagname= 2299bd41f2cSmrgAC_LIBTOOL_LANG_C_CONFIG 2309bd41f2cSmrg_LT_AC_TAGCONFIG 2319bd41f2cSmrg])# AC_LIBTOOL_SETUP 2329bd41f2cSmrg 2339bd41f2cSmrg 2349bd41f2cSmrg# _LT_AC_SYS_COMPILER 2359bd41f2cSmrg# ------------------- 2369bd41f2cSmrgAC_DEFUN([_LT_AC_SYS_COMPILER], 2379bd41f2cSmrg[AC_REQUIRE([AC_PROG_CC])dnl 2389bd41f2cSmrg 2399bd41f2cSmrg# If no C compiler was specified, use CC. 2409bd41f2cSmrgLTCC=${LTCC-"$CC"} 2419bd41f2cSmrg 2429bd41f2cSmrg# If no C compiler flags were specified, use CFLAGS. 2439bd41f2cSmrgLTCFLAGS=${LTCFLAGS-"$CFLAGS"} 2449bd41f2cSmrg 2459bd41f2cSmrg# Allow CC to be a program name with arguments. 2469bd41f2cSmrgcompiler=$CC 2479bd41f2cSmrg])# _LT_AC_SYS_COMPILER 2489bd41f2cSmrg 2499bd41f2cSmrg 2509bd41f2cSmrg# _LT_CC_BASENAME(CC) 2519bd41f2cSmrg# ------------------- 2529bd41f2cSmrg# Calculate cc_basename. Skip known compiler wrappers and cross-prefix. 2539bd41f2cSmrgAC_DEFUN([_LT_CC_BASENAME], 2549bd41f2cSmrg[for cc_temp in $1""; do 2559bd41f2cSmrg case $cc_temp in 2569bd41f2cSmrg compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;; 2579bd41f2cSmrg distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;; 2589bd41f2cSmrg \-*) ;; 2599bd41f2cSmrg *) break;; 2609bd41f2cSmrg esac 2619bd41f2cSmrgdone 2629bd41f2cSmrgcc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` 2639bd41f2cSmrg]) 2649bd41f2cSmrg 2659bd41f2cSmrg 2669bd41f2cSmrg# _LT_COMPILER_BOILERPLATE 2679bd41f2cSmrg# ------------------------ 2689bd41f2cSmrg# Check for compiler boilerplate output or warnings with 2699bd41f2cSmrg# the simple compiler test code. 2709bd41f2cSmrgAC_DEFUN([_LT_COMPILER_BOILERPLATE], 2719bd41f2cSmrg[AC_REQUIRE([LT_AC_PROG_SED])dnl 2729bd41f2cSmrgac_outfile=conftest.$ac_objext 2739bd41f2cSmrgecho "$lt_simple_compile_test_code" >conftest.$ac_ext 2749bd41f2cSmrgeval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err 2759bd41f2cSmrg_lt_compiler_boilerplate=`cat conftest.err` 2769bd41f2cSmrg$rm conftest* 2779bd41f2cSmrg])# _LT_COMPILER_BOILERPLATE 2789bd41f2cSmrg 2799bd41f2cSmrg 2809bd41f2cSmrg# _LT_LINKER_BOILERPLATE 2819bd41f2cSmrg# ---------------------- 2829bd41f2cSmrg# Check for linker boilerplate output or warnings with 2839bd41f2cSmrg# the simple link test code. 2849bd41f2cSmrgAC_DEFUN([_LT_LINKER_BOILERPLATE], 2859bd41f2cSmrg[AC_REQUIRE([LT_AC_PROG_SED])dnl 2869bd41f2cSmrgac_outfile=conftest.$ac_objext 2879bd41f2cSmrgecho "$lt_simple_link_test_code" >conftest.$ac_ext 2889bd41f2cSmrgeval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err 2899bd41f2cSmrg_lt_linker_boilerplate=`cat conftest.err` 2909bd41f2cSmrg$rm conftest* 2919bd41f2cSmrg])# _LT_LINKER_BOILERPLATE 2929bd41f2cSmrg 2939bd41f2cSmrg 2949bd41f2cSmrg# _LT_AC_SYS_LIBPATH_AIX 2959bd41f2cSmrg# ---------------------- 2969bd41f2cSmrg# Links a minimal program and checks the executable 2979bd41f2cSmrg# for the system default hardcoded library path. In most cases, 2989bd41f2cSmrg# this is /usr/lib:/lib, but when the MPI compilers are used 2999bd41f2cSmrg# the location of the communication and MPI libs are included too. 3009bd41f2cSmrg# If we don't find anything, use the default library path according 3019bd41f2cSmrg# to the aix ld manual. 3029bd41f2cSmrgAC_DEFUN([_LT_AC_SYS_LIBPATH_AIX], 3039bd41f2cSmrg[AC_REQUIRE([LT_AC_PROG_SED])dnl 3049bd41f2cSmrgAC_LINK_IFELSE(AC_LANG_PROGRAM,[ 3059bd41f2cSmrglt_aix_libpath_sed=' 3069bd41f2cSmrg /Import File Strings/,/^$/ { 3079bd41f2cSmrg /^0/ { 3089bd41f2cSmrg s/^0 *\(.*\)$/\1/ 3099bd41f2cSmrg p 3109bd41f2cSmrg } 3119bd41f2cSmrg }' 3129bd41f2cSmrgaix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` 3139bd41f2cSmrg# Check for a 64-bit object if we didn't find anything. 3149bd41f2cSmrgif test -z "$aix_libpath"; then 3159bd41f2cSmrg aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` 3169bd41f2cSmrgfi],[]) 3179bd41f2cSmrgif test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi 3189bd41f2cSmrg])# _LT_AC_SYS_LIBPATH_AIX 3199bd41f2cSmrg 3209bd41f2cSmrg 3219bd41f2cSmrg# _LT_AC_SHELL_INIT(ARG) 3229bd41f2cSmrg# ---------------------- 3239bd41f2cSmrgAC_DEFUN([_LT_AC_SHELL_INIT], 3249bd41f2cSmrg[ifdef([AC_DIVERSION_NOTICE], 3259bd41f2cSmrg [AC_DIVERT_PUSH(AC_DIVERSION_NOTICE)], 3269bd41f2cSmrg [AC_DIVERT_PUSH(NOTICE)]) 3279bd41f2cSmrg$1 3289bd41f2cSmrgAC_DIVERT_POP 3299bd41f2cSmrg])# _LT_AC_SHELL_INIT 3309bd41f2cSmrg 3319bd41f2cSmrg 3329bd41f2cSmrg# _LT_AC_PROG_ECHO_BACKSLASH 3339bd41f2cSmrg# -------------------------- 3349bd41f2cSmrg# Add some code to the start of the generated configure script which 3359bd41f2cSmrg# will find an echo command which doesn't interpret backslashes. 3369bd41f2cSmrgAC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH], 3379bd41f2cSmrg[_LT_AC_SHELL_INIT([ 3389bd41f2cSmrg# Check that we are running under the correct shell. 3399bd41f2cSmrgSHELL=${CONFIG_SHELL-/bin/sh} 3409bd41f2cSmrg 3419bd41f2cSmrgcase X$ECHO in 3429bd41f2cSmrgX*--fallback-echo) 3439bd41f2cSmrg # Remove one level of quotation (which was required for Make). 3449bd41f2cSmrg ECHO=`echo "$ECHO" | sed 's,\\\\\[$]\\[$]0,'[$]0','` 3459bd41f2cSmrg ;; 3469bd41f2cSmrgesac 3479bd41f2cSmrg 3489bd41f2cSmrgecho=${ECHO-echo} 3499bd41f2cSmrgif test "X[$]1" = X--no-reexec; then 3509bd41f2cSmrg # Discard the --no-reexec flag, and continue. 3519bd41f2cSmrg shift 3529bd41f2cSmrgelif test "X[$]1" = X--fallback-echo; then 3539bd41f2cSmrg # Avoid inline document here, it may be left over 3549bd41f2cSmrg : 3559bd41f2cSmrgelif test "X`($echo '\t') 2>/dev/null`" = 'X\t' ; then 3569bd41f2cSmrg # Yippee, $echo works! 3579bd41f2cSmrg : 3589bd41f2cSmrgelse 3599bd41f2cSmrg # Restart under the correct shell. 3609bd41f2cSmrg exec $SHELL "[$]0" --no-reexec ${1+"[$]@"} 3619bd41f2cSmrgfi 3629bd41f2cSmrg 3639bd41f2cSmrgif test "X[$]1" = X--fallback-echo; then 3649bd41f2cSmrg # used as fallback echo 3659bd41f2cSmrg shift 3669bd41f2cSmrg cat <<EOF 3679bd41f2cSmrg[$]* 3689bd41f2cSmrgEOF 3699bd41f2cSmrg exit 0 3709bd41f2cSmrgfi 3719bd41f2cSmrg 3729bd41f2cSmrg# The HP-UX ksh and POSIX shell print the target directory to stdout 3739bd41f2cSmrg# if CDPATH is set. 3749bd41f2cSmrg(unset CDPATH) >/dev/null 2>&1 && unset CDPATH 3759bd41f2cSmrg 3769bd41f2cSmrgif test -z "$ECHO"; then 3779bd41f2cSmrgif test "X${echo_test_string+set}" != Xset; then 3789bd41f2cSmrg# find a string as large as possible, as long as the shell can cope with it 3799bd41f2cSmrg for cmd in 'sed 50q "[$]0"' 'sed 20q "[$]0"' 'sed 10q "[$]0"' 'sed 2q "[$]0"' 'echo test'; do 3809bd41f2cSmrg # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ... 3819bd41f2cSmrg if (echo_test_string=`eval $cmd`) 2>/dev/null && 3829bd41f2cSmrg echo_test_string=`eval $cmd` && 3839bd41f2cSmrg (test "X$echo_test_string" = "X$echo_test_string") 2>/dev/null 3849bd41f2cSmrg then 3859bd41f2cSmrg break 3869bd41f2cSmrg fi 3879bd41f2cSmrg done 3889bd41f2cSmrgfi 3899bd41f2cSmrg 3909bd41f2cSmrgif test "X`($echo '\t') 2>/dev/null`" = 'X\t' && 3919bd41f2cSmrg echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` && 3929bd41f2cSmrg test "X$echo_testing_string" = "X$echo_test_string"; then 3939bd41f2cSmrg : 3949bd41f2cSmrgelse 3959bd41f2cSmrg # The Solaris, AIX, and Digital Unix default echo programs unquote 3969bd41f2cSmrg # backslashes. This makes it impossible to quote backslashes using 3979bd41f2cSmrg # echo "$something" | sed 's/\\/\\\\/g' 3989bd41f2cSmrg # 3999bd41f2cSmrg # So, first we look for a working echo in the user's PATH. 4009bd41f2cSmrg 4019bd41f2cSmrg lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR 4029bd41f2cSmrg for dir in $PATH /usr/ucb; do 4039bd41f2cSmrg IFS="$lt_save_ifs" 4049bd41f2cSmrg if (test -f $dir/echo || test -f $dir/echo$ac_exeext) && 4059bd41f2cSmrg test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' && 4069bd41f2cSmrg echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` && 4079bd41f2cSmrg test "X$echo_testing_string" = "X$echo_test_string"; then 4089bd41f2cSmrg echo="$dir/echo" 4099bd41f2cSmrg break 4109bd41f2cSmrg fi 4119bd41f2cSmrg done 4129bd41f2cSmrg IFS="$lt_save_ifs" 4139bd41f2cSmrg 4149bd41f2cSmrg if test "X$echo" = Xecho; then 4159bd41f2cSmrg # We didn't find a better echo, so look for alternatives. 4169bd41f2cSmrg if test "X`(print -r '\t') 2>/dev/null`" = 'X\t' && 4179bd41f2cSmrg echo_testing_string=`(print -r "$echo_test_string") 2>/dev/null` && 4189bd41f2cSmrg test "X$echo_testing_string" = "X$echo_test_string"; then 4199bd41f2cSmrg # This shell has a builtin print -r that does the trick. 4209bd41f2cSmrg echo='print -r' 4219bd41f2cSmrg elif (test -f /bin/ksh || test -f /bin/ksh$ac_exeext) && 4229bd41f2cSmrg test "X$CONFIG_SHELL" != X/bin/ksh; then 4239bd41f2cSmrg # If we have ksh, try running configure again with it. 4249bd41f2cSmrg ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh} 4259bd41f2cSmrg export ORIGINAL_CONFIG_SHELL 4269bd41f2cSmrg CONFIG_SHELL=/bin/ksh 4279bd41f2cSmrg export CONFIG_SHELL 4289bd41f2cSmrg exec $CONFIG_SHELL "[$]0" --no-reexec ${1+"[$]@"} 4299bd41f2cSmrg else 4309bd41f2cSmrg # Try using printf. 4319bd41f2cSmrg echo='printf %s\n' 4329bd41f2cSmrg if test "X`($echo '\t') 2>/dev/null`" = 'X\t' && 4339bd41f2cSmrg echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` && 4349bd41f2cSmrg test "X$echo_testing_string" = "X$echo_test_string"; then 4359bd41f2cSmrg # Cool, printf works 4369bd41f2cSmrg : 4379bd41f2cSmrg elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` && 4389bd41f2cSmrg test "X$echo_testing_string" = 'X\t' && 4399bd41f2cSmrg echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` && 4409bd41f2cSmrg test "X$echo_testing_string" = "X$echo_test_string"; then 4419bd41f2cSmrg CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL 4429bd41f2cSmrg export CONFIG_SHELL 4439bd41f2cSmrg SHELL="$CONFIG_SHELL" 4449bd41f2cSmrg export SHELL 4459bd41f2cSmrg echo="$CONFIG_SHELL [$]0 --fallback-echo" 4469bd41f2cSmrg elif echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` && 4479bd41f2cSmrg test "X$echo_testing_string" = 'X\t' && 4489bd41f2cSmrg echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` && 4499bd41f2cSmrg test "X$echo_testing_string" = "X$echo_test_string"; then 4509bd41f2cSmrg echo="$CONFIG_SHELL [$]0 --fallback-echo" 4519bd41f2cSmrg else 4529bd41f2cSmrg # maybe with a smaller string... 4539bd41f2cSmrg prev=: 4549bd41f2cSmrg 4559bd41f2cSmrg for cmd in 'echo test' 'sed 2q "[$]0"' 'sed 10q "[$]0"' 'sed 20q "[$]0"' 'sed 50q "[$]0"'; do 4569bd41f2cSmrg if (test "X$echo_test_string" = "X`eval $cmd`") 2>/dev/null 4579bd41f2cSmrg then 4589bd41f2cSmrg break 4599bd41f2cSmrg fi 4609bd41f2cSmrg prev="$cmd" 4619bd41f2cSmrg done 4629bd41f2cSmrg 4639bd41f2cSmrg if test "$prev" != 'sed 50q "[$]0"'; then 4649bd41f2cSmrg echo_test_string=`eval $prev` 4659bd41f2cSmrg export echo_test_string 4669bd41f2cSmrg exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "[$]0" ${1+"[$]@"} 4679bd41f2cSmrg else 4689bd41f2cSmrg # Oops. We lost completely, so just stick with echo. 4699bd41f2cSmrg echo=echo 4709bd41f2cSmrg fi 4719bd41f2cSmrg fi 4729bd41f2cSmrg fi 4739bd41f2cSmrg fi 4749bd41f2cSmrgfi 4759bd41f2cSmrgfi 4769bd41f2cSmrg 4779bd41f2cSmrg# Copy echo and quote the copy suitably for passing to libtool from 4789bd41f2cSmrg# the Makefile, instead of quoting the original, which is used later. 4799bd41f2cSmrgECHO=$echo 4809bd41f2cSmrgif test "X$ECHO" = "X$CONFIG_SHELL [$]0 --fallback-echo"; then 4819bd41f2cSmrg ECHO="$CONFIG_SHELL \\\$\[$]0 --fallback-echo" 4829bd41f2cSmrgfi 4839bd41f2cSmrg 4849bd41f2cSmrgAC_SUBST(ECHO) 4859bd41f2cSmrg])])# _LT_AC_PROG_ECHO_BACKSLASH 4869bd41f2cSmrg 4879bd41f2cSmrg 4889bd41f2cSmrg# _LT_AC_LOCK 4899bd41f2cSmrg# ----------- 4909bd41f2cSmrgAC_DEFUN([_LT_AC_LOCK], 4919bd41f2cSmrg[AC_ARG_ENABLE([libtool-lock], 4929bd41f2cSmrg [AC_HELP_STRING([--disable-libtool-lock], 4939bd41f2cSmrg [avoid locking (might break parallel builds)])]) 4949bd41f2cSmrgtest "x$enable_libtool_lock" != xno && enable_libtool_lock=yes 4959bd41f2cSmrg 4969bd41f2cSmrg# Some flags need to be propagated to the compiler or linker for good 4979bd41f2cSmrg# libtool support. 4989bd41f2cSmrgcase $host in 4999bd41f2cSmrgia64-*-hpux*) 5009bd41f2cSmrg # Find out which ABI we are using. 5019bd41f2cSmrg echo 'int i;' > conftest.$ac_ext 5029bd41f2cSmrg if AC_TRY_EVAL(ac_compile); then 5039bd41f2cSmrg case `/usr/bin/file conftest.$ac_objext` in 5049bd41f2cSmrg *ELF-32*) 5059bd41f2cSmrg HPUX_IA64_MODE="32" 5069bd41f2cSmrg ;; 5079bd41f2cSmrg *ELF-64*) 5089bd41f2cSmrg HPUX_IA64_MODE="64" 5099bd41f2cSmrg ;; 5109bd41f2cSmrg esac 5119bd41f2cSmrg fi 5129bd41f2cSmrg rm -rf conftest* 5139bd41f2cSmrg ;; 5149bd41f2cSmrg*-*-irix6*) 5159bd41f2cSmrg # Find out which ABI we are using. 5169bd41f2cSmrg echo '[#]line __oline__ "configure"' > conftest.$ac_ext 5179bd41f2cSmrg if AC_TRY_EVAL(ac_compile); then 5189bd41f2cSmrg if test "$lt_cv_prog_gnu_ld" = yes; then 5199bd41f2cSmrg case `/usr/bin/file conftest.$ac_objext` in 5209bd41f2cSmrg *32-bit*) 5219bd41f2cSmrg LD="${LD-ld} -melf32bsmip" 5229bd41f2cSmrg ;; 5239bd41f2cSmrg *N32*) 5249bd41f2cSmrg LD="${LD-ld} -melf32bmipn32" 5259bd41f2cSmrg ;; 5269bd41f2cSmrg *64-bit*) 5279bd41f2cSmrg LD="${LD-ld} -melf64bmip" 5289bd41f2cSmrg ;; 5299bd41f2cSmrg esac 5309bd41f2cSmrg else 5319bd41f2cSmrg case `/usr/bin/file conftest.$ac_objext` in 5329bd41f2cSmrg *32-bit*) 5339bd41f2cSmrg LD="${LD-ld} -32" 5349bd41f2cSmrg ;; 5359bd41f2cSmrg *N32*) 5369bd41f2cSmrg LD="${LD-ld} -n32" 5379bd41f2cSmrg ;; 5389bd41f2cSmrg *64-bit*) 5399bd41f2cSmrg LD="${LD-ld} -64" 5409bd41f2cSmrg ;; 5419bd41f2cSmrg esac 5429bd41f2cSmrg fi 5439bd41f2cSmrg fi 5449bd41f2cSmrg rm -rf conftest* 5459bd41f2cSmrg ;; 5469bd41f2cSmrg 5479bd41f2cSmrgx86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \ 5489bd41f2cSmrgs390*-*linux*|sparc*-*linux*) 5499bd41f2cSmrg # Find out which ABI we are using. 5509bd41f2cSmrg echo 'int i;' > conftest.$ac_ext 5519bd41f2cSmrg if AC_TRY_EVAL(ac_compile); then 5529bd41f2cSmrg case `/usr/bin/file conftest.o` in 5539bd41f2cSmrg *32-bit*) 5549bd41f2cSmrg case $host in 5559bd41f2cSmrg x86_64-*kfreebsd*-gnu) 5569bd41f2cSmrg LD="${LD-ld} -m elf_i386_fbsd" 5579bd41f2cSmrg ;; 5589bd41f2cSmrg x86_64-*linux*) 5599bd41f2cSmrg LD="${LD-ld} -m elf_i386" 5609bd41f2cSmrg ;; 5619bd41f2cSmrg ppc64-*linux*|powerpc64-*linux*) 5629bd41f2cSmrg LD="${LD-ld} -m elf32ppclinux" 5639bd41f2cSmrg ;; 5649bd41f2cSmrg s390x-*linux*) 5659bd41f2cSmrg LD="${LD-ld} -m elf_s390" 5669bd41f2cSmrg ;; 5679bd41f2cSmrg sparc64-*linux*) 5689bd41f2cSmrg LD="${LD-ld} -m elf32_sparc" 5699bd41f2cSmrg ;; 5709bd41f2cSmrg esac 5719bd41f2cSmrg ;; 5729bd41f2cSmrg *64-bit*) 5739bd41f2cSmrg libsuff=64 5749bd41f2cSmrg case $host in 5759bd41f2cSmrg x86_64-*kfreebsd*-gnu) 5769bd41f2cSmrg LD="${LD-ld} -m elf_x86_64_fbsd" 5779bd41f2cSmrg ;; 5789bd41f2cSmrg x86_64-*linux*) 5799bd41f2cSmrg LD="${LD-ld} -m elf_x86_64" 5809bd41f2cSmrg ;; 5819bd41f2cSmrg ppc*-*linux*|powerpc*-*linux*) 5829bd41f2cSmrg LD="${LD-ld} -m elf64ppc" 5839bd41f2cSmrg ;; 5849bd41f2cSmrg s390*-*linux*) 5859bd41f2cSmrg LD="${LD-ld} -m elf64_s390" 5869bd41f2cSmrg ;; 5879bd41f2cSmrg sparc*-*linux*) 5889bd41f2cSmrg LD="${LD-ld} -m elf64_sparc" 5899bd41f2cSmrg ;; 5909bd41f2cSmrg esac 5919bd41f2cSmrg ;; 5929bd41f2cSmrg esac 5939bd41f2cSmrg fi 5949bd41f2cSmrg rm -rf conftest* 5959bd41f2cSmrg ;; 5969bd41f2cSmrg 5979bd41f2cSmrg*-*-sco3.2v5*) 5989bd41f2cSmrg # On SCO OpenServer 5, we need -belf to get full-featured binaries. 5999bd41f2cSmrg SAVE_CFLAGS="$CFLAGS" 6009bd41f2cSmrg CFLAGS="$CFLAGS -belf" 6019bd41f2cSmrg AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf, 6029bd41f2cSmrg [AC_LANG_PUSH(C) 6039bd41f2cSmrg AC_TRY_LINK([],[],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no]) 6049bd41f2cSmrg AC_LANG_POP]) 6059bd41f2cSmrg if test x"$lt_cv_cc_needs_belf" != x"yes"; then 6069bd41f2cSmrg # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf 6079bd41f2cSmrg CFLAGS="$SAVE_CFLAGS" 6089bd41f2cSmrg fi 6099bd41f2cSmrg ;; 6109bd41f2cSmrgsparc*-*solaris*) 6119bd41f2cSmrg # Find out which ABI we are using. 6129bd41f2cSmrg echo 'int i;' > conftest.$ac_ext 6139bd41f2cSmrg if AC_TRY_EVAL(ac_compile); then 6149bd41f2cSmrg case `/usr/bin/file conftest.o` in 6159bd41f2cSmrg *64-bit*) 6169bd41f2cSmrg case $lt_cv_prog_gnu_ld in 6179bd41f2cSmrg yes*) LD="${LD-ld} -m elf64_sparc" ;; 6189bd41f2cSmrg *) LD="${LD-ld} -64" ;; 6199bd41f2cSmrg esac 6209bd41f2cSmrg ;; 6219bd41f2cSmrg esac 6229bd41f2cSmrg fi 6239bd41f2cSmrg rm -rf conftest* 6249bd41f2cSmrg ;; 6259bd41f2cSmrg 6269bd41f2cSmrgAC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL], 6279bd41f2cSmrg[*-*-cygwin* | *-*-mingw* | *-*-pw32*) 6289bd41f2cSmrg AC_CHECK_TOOL(DLLTOOL, dlltool, false) 6299bd41f2cSmrg AC_CHECK_TOOL(AS, as, false) 6309bd41f2cSmrg AC_CHECK_TOOL(OBJDUMP, objdump, false) 6319bd41f2cSmrg ;; 6329bd41f2cSmrg ]) 6339bd41f2cSmrgesac 6349bd41f2cSmrg 6359bd41f2cSmrgneed_locks="$enable_libtool_lock" 6369bd41f2cSmrg 6379bd41f2cSmrg])# _LT_AC_LOCK 6389bd41f2cSmrg 6399bd41f2cSmrg 6409bd41f2cSmrg# AC_LIBTOOL_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, 6419bd41f2cSmrg# [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE]) 6429bd41f2cSmrg# ---------------------------------------------------------------- 6439bd41f2cSmrg# Check whether the given compiler option works 6449bd41f2cSmrgAC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], 6459bd41f2cSmrg[AC_REQUIRE([LT_AC_PROG_SED]) 6469bd41f2cSmrgAC_CACHE_CHECK([$1], [$2], 6479bd41f2cSmrg [$2=no 6489bd41f2cSmrg ifelse([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4]) 6499bd41f2cSmrg echo "$lt_simple_compile_test_code" > conftest.$ac_ext 6509bd41f2cSmrg lt_compiler_flag="$3" 6519bd41f2cSmrg # Insert the option either (1) after the last *FLAGS variable, or 6529bd41f2cSmrg # (2) before a word containing "conftest.", or (3) at the end. 6539bd41f2cSmrg # Note that $ac_compile itself does not contain backslashes and begins 6549bd41f2cSmrg # with a dollar sign (not a hyphen), so the echo should work correctly. 6559bd41f2cSmrg # The option is referenced via a variable to avoid confusing sed. 6569bd41f2cSmrg lt_compile=`echo "$ac_compile" | $SED \ 6579bd41f2cSmrg -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ 6589bd41f2cSmrg -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ 6599bd41f2cSmrg -e 's:$: $lt_compiler_flag:'` 6609bd41f2cSmrg (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD) 6619bd41f2cSmrg (eval "$lt_compile" 2>conftest.err) 6629bd41f2cSmrg ac_status=$? 6639bd41f2cSmrg cat conftest.err >&AS_MESSAGE_LOG_FD 6649bd41f2cSmrg echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD 6659bd41f2cSmrg if (exit $ac_status) && test -s "$ac_outfile"; then 6669bd41f2cSmrg # The compiler can only warn and ignore the option if not recognized 6679bd41f2cSmrg # So say no if there are warnings other than the usual output. 6689bd41f2cSmrg $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp 6699bd41f2cSmrg $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 6709bd41f2cSmrg if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then 6719bd41f2cSmrg $2=yes 6729bd41f2cSmrg fi 6739bd41f2cSmrg fi 6749bd41f2cSmrg $rm conftest* 6759bd41f2cSmrg]) 6769bd41f2cSmrg 6779bd41f2cSmrgif test x"[$]$2" = xyes; then 6789bd41f2cSmrg ifelse([$5], , :, [$5]) 6799bd41f2cSmrgelse 6809bd41f2cSmrg ifelse([$6], , :, [$6]) 6819bd41f2cSmrgfi 6829bd41f2cSmrg])# AC_LIBTOOL_COMPILER_OPTION 6839bd41f2cSmrg 6849bd41f2cSmrg 6859bd41f2cSmrg# AC_LIBTOOL_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, 6869bd41f2cSmrg# [ACTION-SUCCESS], [ACTION-FAILURE]) 6879bd41f2cSmrg# ------------------------------------------------------------ 6889bd41f2cSmrg# Check whether the given compiler option works 6899bd41f2cSmrgAC_DEFUN([AC_LIBTOOL_LINKER_OPTION], 6909bd41f2cSmrg[AC_REQUIRE([LT_AC_PROG_SED])dnl 6919bd41f2cSmrgAC_CACHE_CHECK([$1], [$2], 6929bd41f2cSmrg [$2=no 6939bd41f2cSmrg save_LDFLAGS="$LDFLAGS" 6949bd41f2cSmrg LDFLAGS="$LDFLAGS $3" 6959bd41f2cSmrg echo "$lt_simple_link_test_code" > conftest.$ac_ext 6969bd41f2cSmrg if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then 6979bd41f2cSmrg # The linker can only warn and ignore the option if not recognized 6989bd41f2cSmrg # So say no if there are warnings 6999bd41f2cSmrg if test -s conftest.err; then 7009bd41f2cSmrg # Append any errors to the config.log. 7019bd41f2cSmrg cat conftest.err 1>&AS_MESSAGE_LOG_FD 7029bd41f2cSmrg $echo "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp 7039bd41f2cSmrg $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 7049bd41f2cSmrg if diff conftest.exp conftest.er2 >/dev/null; then 7059bd41f2cSmrg $2=yes 7069bd41f2cSmrg fi 7079bd41f2cSmrg else 7089bd41f2cSmrg $2=yes 7099bd41f2cSmrg fi 7109bd41f2cSmrg fi 7119bd41f2cSmrg $rm conftest* 7129bd41f2cSmrg LDFLAGS="$save_LDFLAGS" 7139bd41f2cSmrg]) 7149bd41f2cSmrg 7159bd41f2cSmrgif test x"[$]$2" = xyes; then 7169bd41f2cSmrg ifelse([$4], , :, [$4]) 7179bd41f2cSmrgelse 7189bd41f2cSmrg ifelse([$5], , :, [$5]) 7199bd41f2cSmrgfi 7209bd41f2cSmrg])# AC_LIBTOOL_LINKER_OPTION 7219bd41f2cSmrg 7229bd41f2cSmrg 7239bd41f2cSmrg# AC_LIBTOOL_SYS_MAX_CMD_LEN 7249bd41f2cSmrg# -------------------------- 7259bd41f2cSmrgAC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], 7269bd41f2cSmrg[# find the maximum length of command line arguments 7279bd41f2cSmrgAC_MSG_CHECKING([the maximum length of command line arguments]) 7289bd41f2cSmrgAC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl 7299bd41f2cSmrg i=0 7309bd41f2cSmrg teststring="ABCD" 7319bd41f2cSmrg 7329bd41f2cSmrg case $build_os in 7339bd41f2cSmrg msdosdjgpp*) 7349bd41f2cSmrg # On DJGPP, this test can blow up pretty badly due to problems in libc 7359bd41f2cSmrg # (any single argument exceeding 2000 bytes causes a buffer overrun 7369bd41f2cSmrg # during glob expansion). Even if it were fixed, the result of this 7379bd41f2cSmrg # check would be larger than it should be. 7389bd41f2cSmrg lt_cv_sys_max_cmd_len=12288; # 12K is about right 7399bd41f2cSmrg ;; 7409bd41f2cSmrg 7419bd41f2cSmrg gnu*) 7429bd41f2cSmrg # Under GNU Hurd, this test is not required because there is 7439bd41f2cSmrg # no limit to the length of command line arguments. 7449bd41f2cSmrg # Libtool will interpret -1 as no limit whatsoever 7459bd41f2cSmrg lt_cv_sys_max_cmd_len=-1; 7469bd41f2cSmrg ;; 7479bd41f2cSmrg 7489bd41f2cSmrg cygwin* | mingw*) 7499bd41f2cSmrg # On Win9x/ME, this test blows up -- it succeeds, but takes 7509bd41f2cSmrg # about 5 minutes as the teststring grows exponentially. 7519bd41f2cSmrg # Worse, since 9x/ME are not pre-emptively multitasking, 7529bd41f2cSmrg # you end up with a "frozen" computer, even though with patience 7539bd41f2cSmrg # the test eventually succeeds (with a max line length of 256k). 7549bd41f2cSmrg # Instead, let's just punt: use the minimum linelength reported by 7559bd41f2cSmrg # all of the supported platforms: 8192 (on NT/2K/XP). 7569bd41f2cSmrg lt_cv_sys_max_cmd_len=8192; 7579bd41f2cSmrg ;; 7589bd41f2cSmrg 7599bd41f2cSmrg amigaos*) 7609bd41f2cSmrg # On AmigaOS with pdksh, this test takes hours, literally. 7619bd41f2cSmrg # So we just punt and use a minimum line length of 8192. 7629bd41f2cSmrg lt_cv_sys_max_cmd_len=8192; 7639bd41f2cSmrg ;; 7649bd41f2cSmrg 7659bd41f2cSmrg netbsd* | freebsd* | openbsd* | darwin* | dragonfly*) 7669bd41f2cSmrg # This has been around since 386BSD, at least. Likely further. 7679bd41f2cSmrg if test -x /sbin/sysctl; then 7689bd41f2cSmrg lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` 7699bd41f2cSmrg elif test -x /usr/sbin/sysctl; then 7709bd41f2cSmrg lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` 7719bd41f2cSmrg else 7729bd41f2cSmrg lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs 7739bd41f2cSmrg fi 7749bd41f2cSmrg # And add a safety zone 7759bd41f2cSmrg lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` 7769bd41f2cSmrg lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` 7779bd41f2cSmrg ;; 7789bd41f2cSmrg 7799bd41f2cSmrg interix*) 7809bd41f2cSmrg # We know the value 262144 and hardcode it with a safety zone (like BSD) 7819bd41f2cSmrg lt_cv_sys_max_cmd_len=196608 7829bd41f2cSmrg ;; 7839bd41f2cSmrg 7849bd41f2cSmrg osf*) 7859bd41f2cSmrg # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure 7869bd41f2cSmrg # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not 7879bd41f2cSmrg # nice to cause kernel panics so lets avoid the loop below. 7889bd41f2cSmrg # First set a reasonable default. 7899bd41f2cSmrg lt_cv_sys_max_cmd_len=16384 7909bd41f2cSmrg # 7919bd41f2cSmrg if test -x /sbin/sysconfig; then 7929bd41f2cSmrg case `/sbin/sysconfig -q proc exec_disable_arg_limit` in 7939bd41f2cSmrg *1*) lt_cv_sys_max_cmd_len=-1 ;; 7949bd41f2cSmrg esac 7959bd41f2cSmrg fi 7969bd41f2cSmrg ;; 7979bd41f2cSmrg sco3.2v5*) 7989bd41f2cSmrg lt_cv_sys_max_cmd_len=102400 7999bd41f2cSmrg ;; 8009bd41f2cSmrg sysv5* | sco5v6* | sysv4.2uw2*) 8019bd41f2cSmrg kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` 8029bd41f2cSmrg if test -n "$kargmax"; then 8039bd41f2cSmrg lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'` 8049bd41f2cSmrg else 8059bd41f2cSmrg lt_cv_sys_max_cmd_len=32768 8069bd41f2cSmrg fi 8079bd41f2cSmrg ;; 8089bd41f2cSmrg *) 8099bd41f2cSmrg lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` 8109bd41f2cSmrg if test -n "$lt_cv_sys_max_cmd_len"; then 8119bd41f2cSmrg lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` 8129bd41f2cSmrg lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` 8139bd41f2cSmrg else 8149bd41f2cSmrg SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} 8159bd41f2cSmrg while (test "X"`$SHELL [$]0 --fallback-echo "X$teststring" 2>/dev/null` \ 8169bd41f2cSmrg = "XX$teststring") >/dev/null 2>&1 && 8179bd41f2cSmrg new_result=`expr "X$teststring" : ".*" 2>&1` && 8189bd41f2cSmrg lt_cv_sys_max_cmd_len=$new_result && 8199bd41f2cSmrg test $i != 17 # 1/2 MB should be enough 8209bd41f2cSmrg do 8219bd41f2cSmrg i=`expr $i + 1` 8229bd41f2cSmrg teststring=$teststring$teststring 8239bd41f2cSmrg done 8249bd41f2cSmrg teststring= 8259bd41f2cSmrg # Add a significant safety factor because C++ compilers can tack on massive 8269bd41f2cSmrg # amounts of additional arguments before passing them to the linker. 8279bd41f2cSmrg # It appears as though 1/2 is a usable value. 8289bd41f2cSmrg lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` 8299bd41f2cSmrg fi 8309bd41f2cSmrg ;; 8319bd41f2cSmrg esac 8329bd41f2cSmrg]) 8339bd41f2cSmrgif test -n $lt_cv_sys_max_cmd_len ; then 8349bd41f2cSmrg AC_MSG_RESULT($lt_cv_sys_max_cmd_len) 8359bd41f2cSmrgelse 8369bd41f2cSmrg AC_MSG_RESULT(none) 8379bd41f2cSmrgfi 8389bd41f2cSmrg])# AC_LIBTOOL_SYS_MAX_CMD_LEN 8399bd41f2cSmrg 8409bd41f2cSmrg 8419bd41f2cSmrg# _LT_AC_CHECK_DLFCN 8429bd41f2cSmrg# ------------------ 8439bd41f2cSmrgAC_DEFUN([_LT_AC_CHECK_DLFCN], 8449bd41f2cSmrg[AC_CHECK_HEADERS(dlfcn.h)dnl 8459bd41f2cSmrg])# _LT_AC_CHECK_DLFCN 8469bd41f2cSmrg 8479bd41f2cSmrg 8489bd41f2cSmrg# _LT_AC_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE, 8499bd41f2cSmrg# ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING) 8509bd41f2cSmrg# --------------------------------------------------------------------- 8519bd41f2cSmrgAC_DEFUN([_LT_AC_TRY_DLOPEN_SELF], 8529bd41f2cSmrg[AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl 8539bd41f2cSmrgif test "$cross_compiling" = yes; then : 8549bd41f2cSmrg [$4] 8559bd41f2cSmrgelse 8569bd41f2cSmrg lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 8579bd41f2cSmrg lt_status=$lt_dlunknown 8589bd41f2cSmrg cat > conftest.$ac_ext <<EOF 8599bd41f2cSmrg[#line __oline__ "configure" 8609bd41f2cSmrg#include "confdefs.h" 8619bd41f2cSmrg 8629bd41f2cSmrg#if HAVE_DLFCN_H 8639bd41f2cSmrg#include <dlfcn.h> 8649bd41f2cSmrg#endif 8659bd41f2cSmrg 8669bd41f2cSmrg#include <stdio.h> 8679bd41f2cSmrg 8689bd41f2cSmrg#ifdef RTLD_GLOBAL 8699bd41f2cSmrg# define LT_DLGLOBAL RTLD_GLOBAL 8709bd41f2cSmrg#else 8719bd41f2cSmrg# ifdef DL_GLOBAL 8729bd41f2cSmrg# define LT_DLGLOBAL DL_GLOBAL 8739bd41f2cSmrg# else 8749bd41f2cSmrg# define LT_DLGLOBAL 0 8759bd41f2cSmrg# endif 8769bd41f2cSmrg#endif 8779bd41f2cSmrg 8789bd41f2cSmrg/* We may have to define LT_DLLAZY_OR_NOW in the command line if we 8799bd41f2cSmrg find out it does not work in some platform. */ 8809bd41f2cSmrg#ifndef LT_DLLAZY_OR_NOW 8819bd41f2cSmrg# ifdef RTLD_LAZY 8829bd41f2cSmrg# define LT_DLLAZY_OR_NOW RTLD_LAZY 8839bd41f2cSmrg# else 8849bd41f2cSmrg# ifdef DL_LAZY 8859bd41f2cSmrg# define LT_DLLAZY_OR_NOW DL_LAZY 8869bd41f2cSmrg# else 8879bd41f2cSmrg# ifdef RTLD_NOW 8889bd41f2cSmrg# define LT_DLLAZY_OR_NOW RTLD_NOW 8899bd41f2cSmrg# else 8909bd41f2cSmrg# ifdef DL_NOW 8919bd41f2cSmrg# define LT_DLLAZY_OR_NOW DL_NOW 8929bd41f2cSmrg# else 8939bd41f2cSmrg# define LT_DLLAZY_OR_NOW 0 8949bd41f2cSmrg# endif 8959bd41f2cSmrg# endif 8969bd41f2cSmrg# endif 8979bd41f2cSmrg# endif 8989bd41f2cSmrg#endif 8999bd41f2cSmrg 9009bd41f2cSmrg#ifdef __cplusplus 9019bd41f2cSmrgextern "C" void exit (int); 9029bd41f2cSmrg#endif 9039bd41f2cSmrg 9049bd41f2cSmrgvoid fnord() { int i=42;} 9059bd41f2cSmrgint main () 9069bd41f2cSmrg{ 9079bd41f2cSmrg void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); 9089bd41f2cSmrg int status = $lt_dlunknown; 9099bd41f2cSmrg 9109bd41f2cSmrg if (self) 9119bd41f2cSmrg { 9129bd41f2cSmrg if (dlsym (self,"fnord")) status = $lt_dlno_uscore; 9139bd41f2cSmrg else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; 9149bd41f2cSmrg /* dlclose (self); */ 9159bd41f2cSmrg } 9169bd41f2cSmrg else 9179bd41f2cSmrg puts (dlerror ()); 9189bd41f2cSmrg 9199bd41f2cSmrg exit (status); 9209bd41f2cSmrg}] 9219bd41f2cSmrgEOF 9229bd41f2cSmrg if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then 9239bd41f2cSmrg (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null 9249bd41f2cSmrg lt_status=$? 9259bd41f2cSmrg case x$lt_status in 9269bd41f2cSmrg x$lt_dlno_uscore) $1 ;; 9279bd41f2cSmrg x$lt_dlneed_uscore) $2 ;; 9289bd41f2cSmrg x$lt_dlunknown|x*) $3 ;; 9299bd41f2cSmrg esac 9309bd41f2cSmrg else : 9319bd41f2cSmrg # compilation failed 9329bd41f2cSmrg $3 9339bd41f2cSmrg fi 9349bd41f2cSmrgfi 9359bd41f2cSmrgrm -fr conftest* 9369bd41f2cSmrg])# _LT_AC_TRY_DLOPEN_SELF 9379bd41f2cSmrg 9389bd41f2cSmrg 9399bd41f2cSmrg# AC_LIBTOOL_DLOPEN_SELF 9409bd41f2cSmrg# ---------------------- 9419bd41f2cSmrgAC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], 9429bd41f2cSmrg[AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl 9439bd41f2cSmrgif test "x$enable_dlopen" != xyes; then 9449bd41f2cSmrg enable_dlopen=unknown 9459bd41f2cSmrg enable_dlopen_self=unknown 9469bd41f2cSmrg enable_dlopen_self_static=unknown 9479bd41f2cSmrgelse 9489bd41f2cSmrg lt_cv_dlopen=no 9499bd41f2cSmrg lt_cv_dlopen_libs= 9509bd41f2cSmrg 9519bd41f2cSmrg case $host_os in 9529bd41f2cSmrg beos*) 9539bd41f2cSmrg lt_cv_dlopen="load_add_on" 9549bd41f2cSmrg lt_cv_dlopen_libs= 9559bd41f2cSmrg lt_cv_dlopen_self=yes 9569bd41f2cSmrg ;; 9579bd41f2cSmrg 9589bd41f2cSmrg mingw* | pw32*) 9599bd41f2cSmrg lt_cv_dlopen="LoadLibrary" 9609bd41f2cSmrg lt_cv_dlopen_libs= 9619bd41f2cSmrg ;; 9629bd41f2cSmrg 9639bd41f2cSmrg cygwin*) 9649bd41f2cSmrg lt_cv_dlopen="dlopen" 9659bd41f2cSmrg lt_cv_dlopen_libs= 9669bd41f2cSmrg ;; 9679bd41f2cSmrg 9689bd41f2cSmrg darwin*) 9699bd41f2cSmrg # if libdl is installed we need to link against it 9709bd41f2cSmrg AC_CHECK_LIB([dl], [dlopen], 9719bd41f2cSmrg [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[ 9729bd41f2cSmrg lt_cv_dlopen="dyld" 9739bd41f2cSmrg lt_cv_dlopen_libs= 9749bd41f2cSmrg lt_cv_dlopen_self=yes 9759bd41f2cSmrg ]) 9769bd41f2cSmrg ;; 9779bd41f2cSmrg 9789bd41f2cSmrg *) 9799bd41f2cSmrg AC_CHECK_FUNC([shl_load], 9809bd41f2cSmrg [lt_cv_dlopen="shl_load"], 9819bd41f2cSmrg [AC_CHECK_LIB([dld], [shl_load], 9829bd41f2cSmrg [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-dld"], 9839bd41f2cSmrg [AC_CHECK_FUNC([dlopen], 9849bd41f2cSmrg [lt_cv_dlopen="dlopen"], 9859bd41f2cSmrg [AC_CHECK_LIB([dl], [dlopen], 9869bd41f2cSmrg [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"], 9879bd41f2cSmrg [AC_CHECK_LIB([svld], [dlopen], 9889bd41f2cSmrg [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"], 9899bd41f2cSmrg [AC_CHECK_LIB([dld], [dld_link], 9909bd41f2cSmrg [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld"]) 9919bd41f2cSmrg ]) 9929bd41f2cSmrg ]) 9939bd41f2cSmrg ]) 9949bd41f2cSmrg ]) 9959bd41f2cSmrg ]) 9969bd41f2cSmrg ;; 9979bd41f2cSmrg esac 9989bd41f2cSmrg 9999bd41f2cSmrg if test "x$lt_cv_dlopen" != xno; then 10009bd41f2cSmrg enable_dlopen=yes 10019bd41f2cSmrg else 10029bd41f2cSmrg enable_dlopen=no 10039bd41f2cSmrg fi 10049bd41f2cSmrg 10059bd41f2cSmrg case $lt_cv_dlopen in 10069bd41f2cSmrg dlopen) 10079bd41f2cSmrg save_CPPFLAGS="$CPPFLAGS" 10089bd41f2cSmrg test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" 10099bd41f2cSmrg 10109bd41f2cSmrg save_LDFLAGS="$LDFLAGS" 10119bd41f2cSmrg wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" 10129bd41f2cSmrg 10139bd41f2cSmrg save_LIBS="$LIBS" 10149bd41f2cSmrg LIBS="$lt_cv_dlopen_libs $LIBS" 10159bd41f2cSmrg 10169bd41f2cSmrg AC_CACHE_CHECK([whether a program can dlopen itself], 10179bd41f2cSmrg lt_cv_dlopen_self, [dnl 10189bd41f2cSmrg _LT_AC_TRY_DLOPEN_SELF( 10199bd41f2cSmrg lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes, 10209bd41f2cSmrg lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross) 10219bd41f2cSmrg ]) 10229bd41f2cSmrg 10239bd41f2cSmrg if test "x$lt_cv_dlopen_self" = xyes; then 10249bd41f2cSmrg wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" 10259bd41f2cSmrg AC_CACHE_CHECK([whether a statically linked program can dlopen itself], 10269bd41f2cSmrg lt_cv_dlopen_self_static, [dnl 10279bd41f2cSmrg _LT_AC_TRY_DLOPEN_SELF( 10289bd41f2cSmrg lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes, 10299bd41f2cSmrg lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross) 10309bd41f2cSmrg ]) 10319bd41f2cSmrg fi 10329bd41f2cSmrg 10339bd41f2cSmrg CPPFLAGS="$save_CPPFLAGS" 10349bd41f2cSmrg LDFLAGS="$save_LDFLAGS" 10359bd41f2cSmrg LIBS="$save_LIBS" 10369bd41f2cSmrg ;; 10379bd41f2cSmrg esac 10389bd41f2cSmrg 10399bd41f2cSmrg case $lt_cv_dlopen_self in 10409bd41f2cSmrg yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; 10419bd41f2cSmrg *) enable_dlopen_self=unknown ;; 10429bd41f2cSmrg esac 10439bd41f2cSmrg 10449bd41f2cSmrg case $lt_cv_dlopen_self_static in 10459bd41f2cSmrg yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; 10469bd41f2cSmrg *) enable_dlopen_self_static=unknown ;; 10479bd41f2cSmrg esac 10489bd41f2cSmrgfi 10499bd41f2cSmrg])# AC_LIBTOOL_DLOPEN_SELF 10509bd41f2cSmrg 10519bd41f2cSmrg 10529bd41f2cSmrg# AC_LIBTOOL_PROG_CC_C_O([TAGNAME]) 10539bd41f2cSmrg# --------------------------------- 10549bd41f2cSmrg# Check to see if options -c and -o are simultaneously supported by compiler 10559bd41f2cSmrgAC_DEFUN([AC_LIBTOOL_PROG_CC_C_O], 10569bd41f2cSmrg[AC_REQUIRE([LT_AC_PROG_SED])dnl 10579bd41f2cSmrgAC_REQUIRE([_LT_AC_SYS_COMPILER])dnl 10589bd41f2cSmrgAC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext], 10599bd41f2cSmrg [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)], 10609bd41f2cSmrg [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no 10619bd41f2cSmrg $rm -r conftest 2>/dev/null 10629bd41f2cSmrg mkdir conftest 10639bd41f2cSmrg cd conftest 10649bd41f2cSmrg mkdir out 10659bd41f2cSmrg echo "$lt_simple_compile_test_code" > conftest.$ac_ext 10669bd41f2cSmrg 10679bd41f2cSmrg lt_compiler_flag="-o out/conftest2.$ac_objext" 10689bd41f2cSmrg # Insert the option either (1) after the last *FLAGS variable, or 10699bd41f2cSmrg # (2) before a word containing "conftest.", or (3) at the end. 10709bd41f2cSmrg # Note that $ac_compile itself does not contain backslashes and begins 10719bd41f2cSmrg # with a dollar sign (not a hyphen), so the echo should work correctly. 10729bd41f2cSmrg lt_compile=`echo "$ac_compile" | $SED \ 10739bd41f2cSmrg -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ 10749bd41f2cSmrg -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ 10759bd41f2cSmrg -e 's:$: $lt_compiler_flag:'` 10769bd41f2cSmrg (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD) 10779bd41f2cSmrg (eval "$lt_compile" 2>out/conftest.err) 10789bd41f2cSmrg ac_status=$? 10799bd41f2cSmrg cat out/conftest.err >&AS_MESSAGE_LOG_FD 10809bd41f2cSmrg echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD 10819bd41f2cSmrg if (exit $ac_status) && test -s out/conftest2.$ac_objext 10829bd41f2cSmrg then 10839bd41f2cSmrg # The compiler can only warn and ignore the option if not recognized 10849bd41f2cSmrg # So say no if there are warnings 10859bd41f2cSmrg $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp 10869bd41f2cSmrg $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 10879bd41f2cSmrg if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then 10889bd41f2cSmrg _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes 10899bd41f2cSmrg fi 10909bd41f2cSmrg fi 10919bd41f2cSmrg chmod u+w . 2>&AS_MESSAGE_LOG_FD 10929bd41f2cSmrg $rm conftest* 10939bd41f2cSmrg # SGI C++ compiler will create directory out/ii_files/ for 10949bd41f2cSmrg # template instantiation 10959bd41f2cSmrg test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files 10969bd41f2cSmrg $rm out/* && rmdir out 10979bd41f2cSmrg cd .. 10989bd41f2cSmrg rmdir conftest 10999bd41f2cSmrg $rm conftest* 11009bd41f2cSmrg]) 11019bd41f2cSmrg])# AC_LIBTOOL_PROG_CC_C_O 11029bd41f2cSmrg 11039bd41f2cSmrg 11049bd41f2cSmrg# AC_LIBTOOL_SYS_HARD_LINK_LOCKS([TAGNAME]) 11059bd41f2cSmrg# ----------------------------------------- 11069bd41f2cSmrg# Check to see if we can do hard links to lock some files if needed 11079bd41f2cSmrgAC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], 11089bd41f2cSmrg[AC_REQUIRE([_LT_AC_LOCK])dnl 11099bd41f2cSmrg 11109bd41f2cSmrghard_links="nottested" 11119bd41f2cSmrgif test "$_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then 11129bd41f2cSmrg # do not overwrite the value of need_locks provided by the user 11139bd41f2cSmrg AC_MSG_CHECKING([if we can lock with hard links]) 11149bd41f2cSmrg hard_links=yes 11159bd41f2cSmrg $rm conftest* 11169bd41f2cSmrg ln conftest.a conftest.b 2>/dev/null && hard_links=no 11179bd41f2cSmrg touch conftest.a 11189bd41f2cSmrg ln conftest.a conftest.b 2>&5 || hard_links=no 11199bd41f2cSmrg ln conftest.a conftest.b 2>/dev/null && hard_links=no 11209bd41f2cSmrg AC_MSG_RESULT([$hard_links]) 11219bd41f2cSmrg if test "$hard_links" = no; then 11229bd41f2cSmrg AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe]) 11239bd41f2cSmrg need_locks=warn 11249bd41f2cSmrg fi 11259bd41f2cSmrgelse 11269bd41f2cSmrg need_locks=no 11279bd41f2cSmrgfi 11289bd41f2cSmrg])# AC_LIBTOOL_SYS_HARD_LINK_LOCKS 11299bd41f2cSmrg 11309bd41f2cSmrg 11319bd41f2cSmrg# AC_LIBTOOL_OBJDIR 11329bd41f2cSmrg# ----------------- 11339bd41f2cSmrgAC_DEFUN([AC_LIBTOOL_OBJDIR], 11349bd41f2cSmrg[AC_CACHE_CHECK([for objdir], [lt_cv_objdir], 11359bd41f2cSmrg[rm -f .libs 2>/dev/null 11369bd41f2cSmrgmkdir .libs 2>/dev/null 11379bd41f2cSmrgif test -d .libs; then 11389bd41f2cSmrg lt_cv_objdir=.libs 11399bd41f2cSmrgelse 11409bd41f2cSmrg # MS-DOS does not allow filenames that begin with a dot. 11419bd41f2cSmrg lt_cv_objdir=_libs 11429bd41f2cSmrgfi 11439bd41f2cSmrgrmdir .libs 2>/dev/null]) 11449bd41f2cSmrgobjdir=$lt_cv_objdir 11459bd41f2cSmrg])# AC_LIBTOOL_OBJDIR 11469bd41f2cSmrg 11479bd41f2cSmrg 11489bd41f2cSmrg# AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH([TAGNAME]) 11499bd41f2cSmrg# ---------------------------------------------- 11509bd41f2cSmrg# Check hardcoding attributes. 11519bd41f2cSmrgAC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], 11529bd41f2cSmrg[AC_MSG_CHECKING([how to hardcode library paths into programs]) 11539bd41f2cSmrg_LT_AC_TAGVAR(hardcode_action, $1)= 11549bd41f2cSmrgif test -n "$_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)" || \ 11559bd41f2cSmrg test -n "$_LT_AC_TAGVAR(runpath_var, $1)" || \ 11569bd41f2cSmrg test "X$_LT_AC_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then 11579bd41f2cSmrg 11589bd41f2cSmrg # We can hardcode non-existant directories. 11599bd41f2cSmrg if test "$_LT_AC_TAGVAR(hardcode_direct, $1)" != no && 11609bd41f2cSmrg # If the only mechanism to avoid hardcoding is shlibpath_var, we 11619bd41f2cSmrg # have to relink, otherwise we might link with an installed library 11629bd41f2cSmrg # when we should be linking with a yet-to-be-installed one 11639bd41f2cSmrg ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)" != no && 11649bd41f2cSmrg test "$_LT_AC_TAGVAR(hardcode_minus_L, $1)" != no; then 11659bd41f2cSmrg # Linking always hardcodes the temporary library directory. 11669bd41f2cSmrg _LT_AC_TAGVAR(hardcode_action, $1)=relink 11679bd41f2cSmrg else 11689bd41f2cSmrg # We can link without hardcoding, and we can hardcode nonexisting dirs. 11699bd41f2cSmrg _LT_AC_TAGVAR(hardcode_action, $1)=immediate 11709bd41f2cSmrg fi 11719bd41f2cSmrgelse 11729bd41f2cSmrg # We cannot hardcode anything, or else we can only hardcode existing 11739bd41f2cSmrg # directories. 11749bd41f2cSmrg _LT_AC_TAGVAR(hardcode_action, $1)=unsupported 11759bd41f2cSmrgfi 11769bd41f2cSmrgAC_MSG_RESULT([$_LT_AC_TAGVAR(hardcode_action, $1)]) 11779bd41f2cSmrg 11789bd41f2cSmrgif test "$_LT_AC_TAGVAR(hardcode_action, $1)" = relink; then 11799bd41f2cSmrg # Fast installation is not supported 11809bd41f2cSmrg enable_fast_install=no 11819bd41f2cSmrgelif test "$shlibpath_overrides_runpath" = yes || 11829bd41f2cSmrg test "$enable_shared" = no; then 11839bd41f2cSmrg # Fast installation is not necessary 11849bd41f2cSmrg enable_fast_install=needless 11859bd41f2cSmrgfi 11869bd41f2cSmrg])# AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH 11879bd41f2cSmrg 11889bd41f2cSmrg 11899bd41f2cSmrg# AC_LIBTOOL_SYS_LIB_STRIP 11909bd41f2cSmrg# ------------------------ 11919bd41f2cSmrgAC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP], 11929bd41f2cSmrg[striplib= 11939bd41f2cSmrgold_striplib= 11949bd41f2cSmrgAC_MSG_CHECKING([whether stripping libraries is possible]) 11959bd41f2cSmrgif test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then 11969bd41f2cSmrg test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" 11979bd41f2cSmrg test -z "$striplib" && striplib="$STRIP --strip-unneeded" 11989bd41f2cSmrg AC_MSG_RESULT([yes]) 11999bd41f2cSmrgelse 12009bd41f2cSmrg# FIXME - insert some real tests, host_os isn't really good enough 12019bd41f2cSmrg case $host_os in 12029bd41f2cSmrg darwin*) 12039bd41f2cSmrg if test -n "$STRIP" ; then 12049bd41f2cSmrg striplib="$STRIP -x" 12059bd41f2cSmrg old_striplib="$STRIP -S" 12069bd41f2cSmrg AC_MSG_RESULT([yes]) 12079bd41f2cSmrg else 12089bd41f2cSmrg AC_MSG_RESULT([no]) 12099bd41f2cSmrgfi 12109bd41f2cSmrg ;; 12119bd41f2cSmrg *) 12129bd41f2cSmrg AC_MSG_RESULT([no]) 12139bd41f2cSmrg ;; 12149bd41f2cSmrg esac 12159bd41f2cSmrgfi 12169bd41f2cSmrg])# AC_LIBTOOL_SYS_LIB_STRIP 12179bd41f2cSmrg 12189bd41f2cSmrg 12199bd41f2cSmrg# AC_LIBTOOL_SYS_DYNAMIC_LINKER 12209bd41f2cSmrg# ----------------------------- 12219bd41f2cSmrg# PORTME Fill in your ld.so characteristics 12229bd41f2cSmrgAC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER], 12239bd41f2cSmrg[AC_REQUIRE([LT_AC_PROG_SED])dnl 12249bd41f2cSmrgAC_MSG_CHECKING([dynamic linker characteristics]) 12259bd41f2cSmrglibrary_names_spec= 12269bd41f2cSmrglibname_spec='lib$name' 12279bd41f2cSmrgsoname_spec= 12289bd41f2cSmrgshrext_cmds=".so" 12299bd41f2cSmrgpostinstall_cmds= 12309bd41f2cSmrgpostuninstall_cmds= 12319bd41f2cSmrgfinish_cmds= 12329bd41f2cSmrgfinish_eval= 12339bd41f2cSmrgshlibpath_var= 12349bd41f2cSmrgshlibpath_overrides_runpath=unknown 12359bd41f2cSmrgversion_type=none 12369bd41f2cSmrgdynamic_linker="$host_os ld.so" 12379bd41f2cSmrgsys_lib_dlsearch_path_spec="/lib /usr/lib" 12389bd41f2cSmrgm4_if($1,[],[ 12399bd41f2cSmrgif test "$GCC" = yes; then 12409bd41f2cSmrg case $host_os in 12419bd41f2cSmrg darwin*) lt_awk_arg="/^libraries:/,/LR/" ;; 12429bd41f2cSmrg *) lt_awk_arg="/^libraries:/" ;; 12439bd41f2cSmrg esac 12449bd41f2cSmrg lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e "s,=/,/,g"` 12459bd41f2cSmrg if echo "$lt_search_path_spec" | grep ';' >/dev/null ; then 12469bd41f2cSmrg # if the path contains ";" then we assume it to be the separator 12479bd41f2cSmrg # otherwise default to the standard path separator (i.e. ":") - it is 12489bd41f2cSmrg # assumed that no part of a normal pathname contains ";" but that should 12499bd41f2cSmrg # okay in the real world where ";" in dirpaths is itself problematic. 12509bd41f2cSmrg lt_search_path_spec=`echo "$lt_search_path_spec" | $SED -e 's/;/ /g'` 12519bd41f2cSmrg else 12529bd41f2cSmrg lt_search_path_spec=`echo "$lt_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` 12539bd41f2cSmrg fi 12549bd41f2cSmrg # Ok, now we have the path, separated by spaces, we can step through it 12559bd41f2cSmrg # and add multilib dir if necessary. 12569bd41f2cSmrg lt_tmp_lt_search_path_spec= 12579bd41f2cSmrg lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` 12589bd41f2cSmrg for lt_sys_path in $lt_search_path_spec; do 12599bd41f2cSmrg if test -d "$lt_sys_path/$lt_multi_os_dir"; then 12609bd41f2cSmrg lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir" 12619bd41f2cSmrg else 12629bd41f2cSmrg test -d "$lt_sys_path" && \ 12639bd41f2cSmrg lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" 12649bd41f2cSmrg fi 12659bd41f2cSmrg done 12669bd41f2cSmrg lt_search_path_spec=`echo $lt_tmp_lt_search_path_spec | awk ' 12679bd41f2cSmrgBEGIN {RS=" "; FS="/|\n";} { 12689bd41f2cSmrg lt_foo=""; 12699bd41f2cSmrg lt_count=0; 12709bd41f2cSmrg for (lt_i = NF; lt_i > 0; lt_i--) { 12719bd41f2cSmrg if ($lt_i != "" && $lt_i != ".") { 12729bd41f2cSmrg if ($lt_i == "..") { 12739bd41f2cSmrg lt_count++; 12749bd41f2cSmrg } else { 12759bd41f2cSmrg if (lt_count == 0) { 12769bd41f2cSmrg lt_foo="/" $lt_i lt_foo; 12779bd41f2cSmrg } else { 12789bd41f2cSmrg lt_count--; 12799bd41f2cSmrg } 12809bd41f2cSmrg } 12819bd41f2cSmrg } 12829bd41f2cSmrg } 12839bd41f2cSmrg if (lt_foo != "") { lt_freq[[lt_foo]]++; } 12849bd41f2cSmrg if (lt_freq[[lt_foo]] == 1) { print lt_foo; } 12859bd41f2cSmrg}'` 12869bd41f2cSmrg sys_lib_search_path_spec=`echo $lt_search_path_spec` 12879bd41f2cSmrgelse 12889bd41f2cSmrg sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" 12899bd41f2cSmrgfi]) 12909bd41f2cSmrgneed_lib_prefix=unknown 12919bd41f2cSmrghardcode_into_libs=no 12929bd41f2cSmrg 12939bd41f2cSmrg# when you set need_version to no, make sure it does not cause -set_version 12949bd41f2cSmrg# flags to be left without arguments 12959bd41f2cSmrgneed_version=unknown 12969bd41f2cSmrg 12979bd41f2cSmrgcase $host_os in 12989bd41f2cSmrgaix3*) 12999bd41f2cSmrg version_type=linux 13009bd41f2cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' 13019bd41f2cSmrg shlibpath_var=LIBPATH 13029bd41f2cSmrg 13039bd41f2cSmrg # AIX 3 has no versioning support, so we append a major version to the name. 13049bd41f2cSmrg soname_spec='${libname}${release}${shared_ext}$major' 13059bd41f2cSmrg ;; 13069bd41f2cSmrg 13079bd41f2cSmrgaix4* | aix5*) 13089bd41f2cSmrg version_type=linux 13099bd41f2cSmrg need_lib_prefix=no 13109bd41f2cSmrg need_version=no 13119bd41f2cSmrg hardcode_into_libs=yes 13129bd41f2cSmrg if test "$host_cpu" = ia64; then 13139bd41f2cSmrg # AIX 5 supports IA64 13149bd41f2cSmrg library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' 13159bd41f2cSmrg shlibpath_var=LD_LIBRARY_PATH 13169bd41f2cSmrg else 13179bd41f2cSmrg # With GCC up to 2.95.x, collect2 would create an import file 13189bd41f2cSmrg # for dependence libraries. The import file would start with 13199bd41f2cSmrg # the line `#! .'. This would cause the generated library to 13209bd41f2cSmrg # depend on `.', always an invalid library. This was fixed in 13219bd41f2cSmrg # development snapshots of GCC prior to 3.0. 13229bd41f2cSmrg case $host_os in 13239bd41f2cSmrg aix4 | aix4.[[01]] | aix4.[[01]].*) 13249bd41f2cSmrg if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' 13259bd41f2cSmrg echo ' yes ' 13269bd41f2cSmrg echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then 13279bd41f2cSmrg : 13289bd41f2cSmrg else 13299bd41f2cSmrg can_build_shared=no 13309bd41f2cSmrg fi 13319bd41f2cSmrg ;; 13329bd41f2cSmrg esac 13339bd41f2cSmrg # AIX (on Power*) has no versioning support, so currently we can not hardcode correct 13349bd41f2cSmrg # soname into executable. Probably we can add versioning support to 13359bd41f2cSmrg # collect2, so additional links can be useful in future. 13369bd41f2cSmrg if test "$aix_use_runtimelinking" = yes; then 13379bd41f2cSmrg # If using run time linking (on AIX 4.2 or later) use lib<name>.so 13389bd41f2cSmrg # instead of lib<name>.a to let people know that these are not 13399bd41f2cSmrg # typical AIX shared libraries. 13409bd41f2cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 13419bd41f2cSmrg else 13429bd41f2cSmrg # We preserve .a as extension for shared libraries through AIX4.2 13439bd41f2cSmrg # and later when we are not doing run time linking. 13449bd41f2cSmrg library_names_spec='${libname}${release}.a $libname.a' 13459bd41f2cSmrg soname_spec='${libname}${release}${shared_ext}$major' 13469bd41f2cSmrg fi 13479bd41f2cSmrg shlibpath_var=LIBPATH 13489bd41f2cSmrg fi 13499bd41f2cSmrg ;; 13509bd41f2cSmrg 13519bd41f2cSmrgamigaos*) 13529bd41f2cSmrg library_names_spec='$libname.ixlibrary $libname.a' 13539bd41f2cSmrg # Create ${libname}_ixlibrary.a entries in /sys/libs. 13549bd41f2cSmrg 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' 13559bd41f2cSmrg ;; 13569bd41f2cSmrg 13579bd41f2cSmrgbeos*) 13589bd41f2cSmrg library_names_spec='${libname}${shared_ext}' 13599bd41f2cSmrg dynamic_linker="$host_os ld.so" 13609bd41f2cSmrg shlibpath_var=LIBRARY_PATH 13619bd41f2cSmrg ;; 13629bd41f2cSmrg 13639bd41f2cSmrgbsdi[[45]]*) 13649bd41f2cSmrg version_type=linux 13659bd41f2cSmrg need_version=no 13669bd41f2cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 13679bd41f2cSmrg soname_spec='${libname}${release}${shared_ext}$major' 13689bd41f2cSmrg finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' 13699bd41f2cSmrg shlibpath_var=LD_LIBRARY_PATH 13709bd41f2cSmrg sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" 13719bd41f2cSmrg sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" 13729bd41f2cSmrg # the default ld.so.conf also contains /usr/contrib/lib and 13739bd41f2cSmrg # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow 13749bd41f2cSmrg # libtool to hard-code these into programs 13759bd41f2cSmrg ;; 13769bd41f2cSmrg 13779bd41f2cSmrgcygwin* | mingw* | pw32*) 13789bd41f2cSmrg version_type=windows 13799bd41f2cSmrg shrext_cmds=".dll" 13809bd41f2cSmrg need_version=no 13819bd41f2cSmrg need_lib_prefix=no 13829bd41f2cSmrg 13839bd41f2cSmrg case $GCC,$host_os in 13849bd41f2cSmrg yes,cygwin* | yes,mingw* | yes,pw32*) 13859bd41f2cSmrg library_names_spec='$libname.dll.a' 13869bd41f2cSmrg # DLL is installed to $(libdir)/../bin by postinstall_cmds 13879bd41f2cSmrg postinstall_cmds='base_file=`basename \${file}`~ 13889bd41f2cSmrg dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~ 13899bd41f2cSmrg dldir=$destdir/`dirname \$dlpath`~ 13909bd41f2cSmrg test -d \$dldir || mkdir -p \$dldir~ 13919bd41f2cSmrg $install_prog $dir/$dlname \$dldir/$dlname~ 13929bd41f2cSmrg chmod a+x \$dldir/$dlname' 13939bd41f2cSmrg postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ 13949bd41f2cSmrg dlpath=$dir/\$dldll~ 13959bd41f2cSmrg $rm \$dlpath' 13969bd41f2cSmrg shlibpath_overrides_runpath=yes 13979bd41f2cSmrg 13989bd41f2cSmrg case $host_os in 13999bd41f2cSmrg cygwin*) 14009bd41f2cSmrg # Cygwin DLLs use 'cyg' prefix rather than 'lib' 14019bd41f2cSmrg soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' 14029bd41f2cSmrg sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib" 14039bd41f2cSmrg ;; 14049bd41f2cSmrg mingw*) 14059bd41f2cSmrg # MinGW DLLs use traditional 'lib' prefix 14069bd41f2cSmrg soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' 14079bd41f2cSmrg sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` 14089bd41f2cSmrg if echo "$sys_lib_search_path_spec" | [grep ';[c-zC-Z]:/' >/dev/null]; then 14099bd41f2cSmrg # It is most probably a Windows format PATH printed by 14109bd41f2cSmrg # mingw gcc, but we are running on Cygwin. Gcc prints its search 14119bd41f2cSmrg # path with ; separators, and with drive letters. We can handle the 14129bd41f2cSmrg # drive letters (cygwin fileutils understands them), so leave them, 14139bd41f2cSmrg # especially as we might pass files found there to a mingw objdump, 14149bd41f2cSmrg # which wouldn't understand a cygwinified path. Ahh. 14159bd41f2cSmrg sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` 14169bd41f2cSmrg else 14179bd41f2cSmrg sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` 14189bd41f2cSmrg fi 14199bd41f2cSmrg ;; 14209bd41f2cSmrg pw32*) 14219bd41f2cSmrg # pw32 DLLs use 'pw' prefix rather than 'lib' 14229bd41f2cSmrg library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' 14239bd41f2cSmrg ;; 14249bd41f2cSmrg esac 14259bd41f2cSmrg ;; 14269bd41f2cSmrg 14279bd41f2cSmrg *) 14289bd41f2cSmrg library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib' 14299bd41f2cSmrg ;; 14309bd41f2cSmrg esac 14319bd41f2cSmrg dynamic_linker='Win32 ld.exe' 14329bd41f2cSmrg # FIXME: first we should search . and the directory the executable is in 14339bd41f2cSmrg shlibpath_var=PATH 14349bd41f2cSmrg ;; 14359bd41f2cSmrg 14369bd41f2cSmrgdarwin* | rhapsody*) 14379bd41f2cSmrg dynamic_linker="$host_os dyld" 14389bd41f2cSmrg version_type=darwin 14399bd41f2cSmrg need_lib_prefix=no 14409bd41f2cSmrg need_version=no 14419bd41f2cSmrg library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext' 14429bd41f2cSmrg soname_spec='${libname}${release}${major}$shared_ext' 14439bd41f2cSmrg shlibpath_overrides_runpath=yes 14449bd41f2cSmrg shlibpath_var=DYLD_LIBRARY_PATH 14459bd41f2cSmrg shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' 14469bd41f2cSmrg m4_if([$1], [],[ 14479bd41f2cSmrg sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"]) 14489bd41f2cSmrg sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' 14499bd41f2cSmrg ;; 14509bd41f2cSmrg 14519bd41f2cSmrgdgux*) 14529bd41f2cSmrg version_type=linux 14539bd41f2cSmrg need_lib_prefix=no 14549bd41f2cSmrg need_version=no 14559bd41f2cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' 14569bd41f2cSmrg soname_spec='${libname}${release}${shared_ext}$major' 14579bd41f2cSmrg shlibpath_var=LD_LIBRARY_PATH 14589bd41f2cSmrg ;; 14599bd41f2cSmrg 14609bd41f2cSmrgfreebsd1*) 14619bd41f2cSmrg dynamic_linker=no 14629bd41f2cSmrg ;; 14639bd41f2cSmrg 14649bd41f2cSmrgfreebsd* | dragonfly*) 14659bd41f2cSmrg # DragonFly does not have aout. When/if they implement a new 14669bd41f2cSmrg # versioning mechanism, adjust this. 14679bd41f2cSmrg if test -x /usr/bin/objformat; then 14689bd41f2cSmrg objformat=`/usr/bin/objformat` 14699bd41f2cSmrg else 14709bd41f2cSmrg case $host_os in 14719bd41f2cSmrg freebsd[[123]]*) objformat=aout ;; 14729bd41f2cSmrg *) objformat=elf ;; 14739bd41f2cSmrg esac 14749bd41f2cSmrg fi 14759bd41f2cSmrg version_type=freebsd-$objformat 14769bd41f2cSmrg case $version_type in 14779bd41f2cSmrg freebsd-elf*) 14789bd41f2cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' 14799bd41f2cSmrg need_version=no 14809bd41f2cSmrg need_lib_prefix=no 14819bd41f2cSmrg ;; 14829bd41f2cSmrg freebsd-*) 14839bd41f2cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' 14849bd41f2cSmrg need_version=yes 14859bd41f2cSmrg ;; 14869bd41f2cSmrg esac 14879bd41f2cSmrg shlibpath_var=LD_LIBRARY_PATH 14889bd41f2cSmrg case $host_os in 14899bd41f2cSmrg freebsd2*) 14909bd41f2cSmrg shlibpath_overrides_runpath=yes 14919bd41f2cSmrg ;; 14929bd41f2cSmrg freebsd3.[[01]]* | freebsdelf3.[[01]]*) 14939bd41f2cSmrg shlibpath_overrides_runpath=yes 14949bd41f2cSmrg hardcode_into_libs=yes 14959bd41f2cSmrg ;; 14969bd41f2cSmrg freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \ 14979bd41f2cSmrg freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1) 14989bd41f2cSmrg shlibpath_overrides_runpath=no 14999bd41f2cSmrg hardcode_into_libs=yes 15009bd41f2cSmrg ;; 15019bd41f2cSmrg *) # from 4.6 on, and DragonFly 15029bd41f2cSmrg shlibpath_overrides_runpath=yes 15039bd41f2cSmrg hardcode_into_libs=yes 15049bd41f2cSmrg ;; 15059bd41f2cSmrg esac 15069bd41f2cSmrg ;; 15079bd41f2cSmrg 15089bd41f2cSmrggnu*) 15099bd41f2cSmrg version_type=linux 15109bd41f2cSmrg need_lib_prefix=no 15119bd41f2cSmrg need_version=no 15129bd41f2cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' 15139bd41f2cSmrg soname_spec='${libname}${release}${shared_ext}$major' 15149bd41f2cSmrg shlibpath_var=LD_LIBRARY_PATH 15159bd41f2cSmrg hardcode_into_libs=yes 15169bd41f2cSmrg ;; 15179bd41f2cSmrg 15189bd41f2cSmrghpux9* | hpux10* | hpux11*) 15199bd41f2cSmrg # Give a soname corresponding to the major version so that dld.sl refuses to 15209bd41f2cSmrg # link against other versions. 15219bd41f2cSmrg version_type=sunos 15229bd41f2cSmrg need_lib_prefix=no 15239bd41f2cSmrg need_version=no 15249bd41f2cSmrg case $host_cpu in 15259bd41f2cSmrg ia64*) 15269bd41f2cSmrg shrext_cmds='.so' 15279bd41f2cSmrg hardcode_into_libs=yes 15289bd41f2cSmrg dynamic_linker="$host_os dld.so" 15299bd41f2cSmrg shlibpath_var=LD_LIBRARY_PATH 15309bd41f2cSmrg shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. 15319bd41f2cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 15329bd41f2cSmrg soname_spec='${libname}${release}${shared_ext}$major' 15339bd41f2cSmrg if test "X$HPUX_IA64_MODE" = X32; then 15349bd41f2cSmrg sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" 15359bd41f2cSmrg else 15369bd41f2cSmrg sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" 15379bd41f2cSmrg fi 15389bd41f2cSmrg sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec 15399bd41f2cSmrg ;; 15409bd41f2cSmrg hppa*64*) 15419bd41f2cSmrg shrext_cmds='.sl' 15429bd41f2cSmrg hardcode_into_libs=yes 15439bd41f2cSmrg dynamic_linker="$host_os dld.sl" 15449bd41f2cSmrg shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH 15459bd41f2cSmrg shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. 15469bd41f2cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 15479bd41f2cSmrg soname_spec='${libname}${release}${shared_ext}$major' 15489bd41f2cSmrg sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" 15499bd41f2cSmrg sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec 15509bd41f2cSmrg ;; 15519bd41f2cSmrg *) 15529bd41f2cSmrg shrext_cmds='.sl' 15539bd41f2cSmrg dynamic_linker="$host_os dld.sl" 15549bd41f2cSmrg shlibpath_var=SHLIB_PATH 15559bd41f2cSmrg shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH 15569bd41f2cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 15579bd41f2cSmrg soname_spec='${libname}${release}${shared_ext}$major' 15589bd41f2cSmrg ;; 15599bd41f2cSmrg esac 15609bd41f2cSmrg # HP-UX runs *really* slowly unless shared libraries are mode 555. 15619bd41f2cSmrg postinstall_cmds='chmod 555 $lib' 15629bd41f2cSmrg ;; 15639bd41f2cSmrg 15649bd41f2cSmrginterix[[3-9]]*) 15659bd41f2cSmrg version_type=linux 15669bd41f2cSmrg need_lib_prefix=no 15679bd41f2cSmrg need_version=no 15689bd41f2cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' 15699bd41f2cSmrg soname_spec='${libname}${release}${shared_ext}$major' 15709bd41f2cSmrg dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' 15719bd41f2cSmrg shlibpath_var=LD_LIBRARY_PATH 15729bd41f2cSmrg shlibpath_overrides_runpath=no 15739bd41f2cSmrg hardcode_into_libs=yes 15749bd41f2cSmrg ;; 15759bd41f2cSmrg 15769bd41f2cSmrgirix5* | irix6* | nonstopux*) 15779bd41f2cSmrg case $host_os in 15789bd41f2cSmrg nonstopux*) version_type=nonstopux ;; 15799bd41f2cSmrg *) 15809bd41f2cSmrg if test "$lt_cv_prog_gnu_ld" = yes; then 15819bd41f2cSmrg version_type=linux 15829bd41f2cSmrg else 15839bd41f2cSmrg version_type=irix 15849bd41f2cSmrg fi ;; 15859bd41f2cSmrg esac 15869bd41f2cSmrg need_lib_prefix=no 15879bd41f2cSmrg need_version=no 15889bd41f2cSmrg soname_spec='${libname}${release}${shared_ext}$major' 15899bd41f2cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' 15909bd41f2cSmrg case $host_os in 15919bd41f2cSmrg irix5* | nonstopux*) 15929bd41f2cSmrg libsuff= shlibsuff= 15939bd41f2cSmrg ;; 15949bd41f2cSmrg *) 15959bd41f2cSmrg case $LD in # libtool.m4 will add one of these switches to LD 15969bd41f2cSmrg *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") 15979bd41f2cSmrg libsuff= shlibsuff= libmagic=32-bit;; 15989bd41f2cSmrg *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") 15999bd41f2cSmrg libsuff=32 shlibsuff=N32 libmagic=N32;; 16009bd41f2cSmrg *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") 16019bd41f2cSmrg libsuff=64 shlibsuff=64 libmagic=64-bit;; 16029bd41f2cSmrg *) libsuff= shlibsuff= libmagic=never-match;; 16039bd41f2cSmrg esac 16049bd41f2cSmrg ;; 16059bd41f2cSmrg esac 16069bd41f2cSmrg shlibpath_var=LD_LIBRARY${shlibsuff}_PATH 16079bd41f2cSmrg shlibpath_overrides_runpath=no 16089bd41f2cSmrg sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" 16099bd41f2cSmrg sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" 16109bd41f2cSmrg hardcode_into_libs=yes 16119bd41f2cSmrg ;; 16129bd41f2cSmrg 16139bd41f2cSmrg# No shared lib support for Linux oldld, aout, or coff. 16149bd41f2cSmrglinux*oldld* | linux*aout* | linux*coff*) 16159bd41f2cSmrg dynamic_linker=no 16169bd41f2cSmrg ;; 16179bd41f2cSmrg 16189bd41f2cSmrg# This must be Linux ELF. 16199bd41f2cSmrglinux* | k*bsd*-gnu) 16209bd41f2cSmrg version_type=linux 16219bd41f2cSmrg need_lib_prefix=no 16229bd41f2cSmrg need_version=no 16239bd41f2cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 16249bd41f2cSmrg soname_spec='${libname}${release}${shared_ext}$major' 16259bd41f2cSmrg finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' 16269bd41f2cSmrg shlibpath_var=LD_LIBRARY_PATH 16279bd41f2cSmrg shlibpath_overrides_runpath=no 16289bd41f2cSmrg # This implies no fast_install, which is unacceptable. 16299bd41f2cSmrg # Some rework will be needed to allow for fast_install 16309bd41f2cSmrg # before this can be enabled. 16319bd41f2cSmrg hardcode_into_libs=yes 16329bd41f2cSmrg sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" 16339bd41f2cSmrg sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" 16349bd41f2cSmrg 16359bd41f2cSmrg # Append ld.so.conf contents to the search path 16369bd41f2cSmrg if test -f /etc/ld.so.conf; then 16379bd41f2cSmrg lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '` 16389bd41f2cSmrg sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec $lt_ld_extra" 16399bd41f2cSmrg fi 16409bd41f2cSmrg 16419bd41f2cSmrg # We used to test for /lib/ld.so.1 and disable shared libraries on 16429bd41f2cSmrg # powerpc, because MkLinux only supported shared libraries with the 16439bd41f2cSmrg # GNU dynamic linker. Since this was broken with cross compilers, 16449bd41f2cSmrg # most powerpc-linux boxes support dynamic linking these days and 16459bd41f2cSmrg # people can always --disable-shared, the test was removed, and we 16469bd41f2cSmrg # assume the GNU/Linux dynamic linker is in use. 16479bd41f2cSmrg dynamic_linker='GNU/Linux ld.so' 16489bd41f2cSmrg ;; 16499bd41f2cSmrg 16509bd41f2cSmrgnetbsd*) 16519bd41f2cSmrg version_type=sunos 16529bd41f2cSmrg need_lib_prefix=no 16539bd41f2cSmrg need_version=no 16549bd41f2cSmrg if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then 16559bd41f2cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' 16569bd41f2cSmrg finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' 16579bd41f2cSmrg dynamic_linker='NetBSD (a.out) ld.so' 16589bd41f2cSmrg else 16599bd41f2cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' 16609bd41f2cSmrg soname_spec='${libname}${release}${shared_ext}$major' 16619bd41f2cSmrg dynamic_linker='NetBSD ld.elf_so' 16629bd41f2cSmrg fi 16639bd41f2cSmrg shlibpath_var=LD_LIBRARY_PATH 16649bd41f2cSmrg shlibpath_overrides_runpath=yes 16659bd41f2cSmrg hardcode_into_libs=yes 16669bd41f2cSmrg ;; 16679bd41f2cSmrg 16689bd41f2cSmrgnewsos6) 16699bd41f2cSmrg version_type=linux 16709bd41f2cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 16719bd41f2cSmrg shlibpath_var=LD_LIBRARY_PATH 16729bd41f2cSmrg shlibpath_overrides_runpath=yes 16739bd41f2cSmrg ;; 16749bd41f2cSmrg 16759bd41f2cSmrgnto-qnx*) 16769bd41f2cSmrg version_type=linux 16779bd41f2cSmrg need_lib_prefix=no 16789bd41f2cSmrg need_version=no 16799bd41f2cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 16809bd41f2cSmrg soname_spec='${libname}${release}${shared_ext}$major' 16819bd41f2cSmrg shlibpath_var=LD_LIBRARY_PATH 16829bd41f2cSmrg shlibpath_overrides_runpath=yes 16839bd41f2cSmrg ;; 16849bd41f2cSmrg 16859bd41f2cSmrgopenbsd*) 16869bd41f2cSmrg version_type=sunos 16879bd41f2cSmrg sys_lib_dlsearch_path_spec="/usr/lib" 16889bd41f2cSmrg need_lib_prefix=no 16899bd41f2cSmrg # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. 16909bd41f2cSmrg case $host_os in 16919bd41f2cSmrg openbsd3.3 | openbsd3.3.*) need_version=yes ;; 16929bd41f2cSmrg *) need_version=no ;; 16939bd41f2cSmrg esac 16949bd41f2cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' 16959bd41f2cSmrg finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' 16969bd41f2cSmrg shlibpath_var=LD_LIBRARY_PATH 16979bd41f2cSmrg if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then 16989bd41f2cSmrg case $host_os in 16999bd41f2cSmrg openbsd2.[[89]] | openbsd2.[[89]].*) 17009bd41f2cSmrg shlibpath_overrides_runpath=no 17019bd41f2cSmrg ;; 17029bd41f2cSmrg *) 17039bd41f2cSmrg shlibpath_overrides_runpath=yes 17049bd41f2cSmrg ;; 17059bd41f2cSmrg esac 17069bd41f2cSmrg else 17079bd41f2cSmrg shlibpath_overrides_runpath=yes 17089bd41f2cSmrg fi 17099bd41f2cSmrg ;; 17109bd41f2cSmrg 17119bd41f2cSmrgos2*) 17129bd41f2cSmrg libname_spec='$name' 17139bd41f2cSmrg shrext_cmds=".dll" 17149bd41f2cSmrg need_lib_prefix=no 17159bd41f2cSmrg library_names_spec='$libname${shared_ext} $libname.a' 17169bd41f2cSmrg dynamic_linker='OS/2 ld.exe' 17179bd41f2cSmrg shlibpath_var=LIBPATH 17189bd41f2cSmrg ;; 17199bd41f2cSmrg 17209bd41f2cSmrgosf3* | osf4* | osf5*) 17219bd41f2cSmrg version_type=osf 17229bd41f2cSmrg need_lib_prefix=no 17239bd41f2cSmrg need_version=no 17249bd41f2cSmrg soname_spec='${libname}${release}${shared_ext}$major' 17259bd41f2cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 17269bd41f2cSmrg shlibpath_var=LD_LIBRARY_PATH 17279bd41f2cSmrg sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" 17289bd41f2cSmrg sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" 17299bd41f2cSmrg ;; 17309bd41f2cSmrg 17319bd41f2cSmrgrdos*) 17329bd41f2cSmrg dynamic_linker=no 17339bd41f2cSmrg ;; 17349bd41f2cSmrg 17359bd41f2cSmrgsolaris*) 17369bd41f2cSmrg version_type=linux 17379bd41f2cSmrg need_lib_prefix=no 17389bd41f2cSmrg need_version=no 17399bd41f2cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 17409bd41f2cSmrg soname_spec='${libname}${release}${shared_ext}$major' 17419bd41f2cSmrg shlibpath_var=LD_LIBRARY_PATH 17429bd41f2cSmrg shlibpath_overrides_runpath=yes 17439bd41f2cSmrg hardcode_into_libs=yes 17449bd41f2cSmrg # ldd complains unless libraries are executable 17459bd41f2cSmrg postinstall_cmds='chmod +x $lib' 17469bd41f2cSmrg ;; 17479bd41f2cSmrg 17489bd41f2cSmrgsunos4*) 17499bd41f2cSmrg version_type=sunos 17509bd41f2cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' 17519bd41f2cSmrg finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' 17529bd41f2cSmrg shlibpath_var=LD_LIBRARY_PATH 17539bd41f2cSmrg shlibpath_overrides_runpath=yes 17549bd41f2cSmrg if test "$with_gnu_ld" = yes; then 17559bd41f2cSmrg need_lib_prefix=no 17569bd41f2cSmrg fi 17579bd41f2cSmrg need_version=yes 17589bd41f2cSmrg ;; 17599bd41f2cSmrg 17609bd41f2cSmrgsysv4 | sysv4.3*) 17619bd41f2cSmrg version_type=linux 17629bd41f2cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 17639bd41f2cSmrg soname_spec='${libname}${release}${shared_ext}$major' 17649bd41f2cSmrg shlibpath_var=LD_LIBRARY_PATH 17659bd41f2cSmrg case $host_vendor in 17669bd41f2cSmrg sni) 17679bd41f2cSmrg shlibpath_overrides_runpath=no 17689bd41f2cSmrg need_lib_prefix=no 17699bd41f2cSmrg export_dynamic_flag_spec='${wl}-Blargedynsym' 17709bd41f2cSmrg runpath_var=LD_RUN_PATH 17719bd41f2cSmrg ;; 17729bd41f2cSmrg siemens) 17739bd41f2cSmrg need_lib_prefix=no 17749bd41f2cSmrg ;; 17759bd41f2cSmrg motorola) 17769bd41f2cSmrg need_lib_prefix=no 17779bd41f2cSmrg need_version=no 17789bd41f2cSmrg shlibpath_overrides_runpath=no 17799bd41f2cSmrg sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' 17809bd41f2cSmrg ;; 17819bd41f2cSmrg esac 17829bd41f2cSmrg ;; 17839bd41f2cSmrg 17849bd41f2cSmrgsysv4*MP*) 17859bd41f2cSmrg if test -d /usr/nec ;then 17869bd41f2cSmrg version_type=linux 17879bd41f2cSmrg library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' 17889bd41f2cSmrg soname_spec='$libname${shared_ext}.$major' 17899bd41f2cSmrg shlibpath_var=LD_LIBRARY_PATH 17909bd41f2cSmrg fi 17919bd41f2cSmrg ;; 17929bd41f2cSmrg 17939bd41f2cSmrgsysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) 17949bd41f2cSmrg version_type=freebsd-elf 17959bd41f2cSmrg need_lib_prefix=no 17969bd41f2cSmrg need_version=no 17979bd41f2cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' 17989bd41f2cSmrg soname_spec='${libname}${release}${shared_ext}$major' 17999bd41f2cSmrg shlibpath_var=LD_LIBRARY_PATH 18009bd41f2cSmrg hardcode_into_libs=yes 18019bd41f2cSmrg if test "$with_gnu_ld" = yes; then 18029bd41f2cSmrg sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' 18039bd41f2cSmrg shlibpath_overrides_runpath=no 18049bd41f2cSmrg else 18059bd41f2cSmrg sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' 18069bd41f2cSmrg shlibpath_overrides_runpath=yes 18079bd41f2cSmrg case $host_os in 18089bd41f2cSmrg sco3.2v5*) 18099bd41f2cSmrg sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" 18109bd41f2cSmrg ;; 18119bd41f2cSmrg esac 18129bd41f2cSmrg fi 18139bd41f2cSmrg sys_lib_dlsearch_path_spec='/usr/lib' 18149bd41f2cSmrg ;; 18159bd41f2cSmrg 18169bd41f2cSmrguts4*) 18179bd41f2cSmrg version_type=linux 18189bd41f2cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 18199bd41f2cSmrg soname_spec='${libname}${release}${shared_ext}$major' 18209bd41f2cSmrg shlibpath_var=LD_LIBRARY_PATH 18219bd41f2cSmrg ;; 18229bd41f2cSmrg 18239bd41f2cSmrg*) 18249bd41f2cSmrg dynamic_linker=no 18259bd41f2cSmrg ;; 18269bd41f2cSmrgesac 18279bd41f2cSmrgAC_MSG_RESULT([$dynamic_linker]) 18289bd41f2cSmrgtest "$dynamic_linker" = no && can_build_shared=no 18299bd41f2cSmrg 18309bd41f2cSmrgvariables_saved_for_relink="PATH $shlibpath_var $runpath_var" 18319bd41f2cSmrgif test "$GCC" = yes; then 18329bd41f2cSmrg variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" 18339bd41f2cSmrgfi 18349bd41f2cSmrg])# AC_LIBTOOL_SYS_DYNAMIC_LINKER 18359bd41f2cSmrg 18369bd41f2cSmrg 18379bd41f2cSmrg# _LT_AC_TAGCONFIG 18389bd41f2cSmrg# ---------------- 18399bd41f2cSmrgAC_DEFUN([_LT_AC_TAGCONFIG], 18409bd41f2cSmrg[AC_REQUIRE([LT_AC_PROG_SED])dnl 18419bd41f2cSmrgAC_ARG_WITH([tags], 18429bd41f2cSmrg [AC_HELP_STRING([--with-tags@<:@=TAGS@:>@], 18439bd41f2cSmrg [include additional configurations @<:@automatic@:>@])], 18449bd41f2cSmrg [tagnames="$withval"]) 18459bd41f2cSmrg 18469bd41f2cSmrgif test -f "$ltmain" && test -n "$tagnames"; then 18479bd41f2cSmrg if test ! -f "${ofile}"; then 18489bd41f2cSmrg AC_MSG_WARN([output file `$ofile' does not exist]) 18499bd41f2cSmrg fi 18509bd41f2cSmrg 18519bd41f2cSmrg if test -z "$LTCC"; then 18529bd41f2cSmrg eval "`$SHELL ${ofile} --config | grep '^LTCC='`" 18539bd41f2cSmrg if test -z "$LTCC"; then 18549bd41f2cSmrg AC_MSG_WARN([output file `$ofile' does not look like a libtool script]) 18559bd41f2cSmrg else 18569bd41f2cSmrg AC_MSG_WARN([using `LTCC=$LTCC', extracted from `$ofile']) 18579bd41f2cSmrg fi 18589bd41f2cSmrg fi 18599bd41f2cSmrg if test -z "$LTCFLAGS"; then 18609bd41f2cSmrg eval "`$SHELL ${ofile} --config | grep '^LTCFLAGS='`" 18619bd41f2cSmrg fi 18629bd41f2cSmrg 18639bd41f2cSmrg # Extract list of available tagged configurations in $ofile. 18649bd41f2cSmrg # Note that this assumes the entire list is on one line. 18659bd41f2cSmrg available_tags=`grep "^available_tags=" "${ofile}" | $SED -e 's/available_tags=\(.*$\)/\1/' -e 's/\"//g'` 18669bd41f2cSmrg 18679bd41f2cSmrg lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," 18689bd41f2cSmrg for tagname in $tagnames; do 18699bd41f2cSmrg IFS="$lt_save_ifs" 18709bd41f2cSmrg # Check whether tagname contains only valid characters 18719bd41f2cSmrg case `$echo "X$tagname" | $Xsed -e 's:[[-_ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890,/]]::g'` in 18729bd41f2cSmrg "") ;; 18739bd41f2cSmrg *) AC_MSG_ERROR([invalid tag name: $tagname]) 18749bd41f2cSmrg ;; 18759bd41f2cSmrg esac 18769bd41f2cSmrg 18779bd41f2cSmrg if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$" < "${ofile}" > /dev/null 18789bd41f2cSmrg then 18799bd41f2cSmrg AC_MSG_ERROR([tag name \"$tagname\" already exists]) 18809bd41f2cSmrg fi 18819bd41f2cSmrg 18829bd41f2cSmrg # Update the list of available tags. 18839bd41f2cSmrg if test -n "$tagname"; then 18849bd41f2cSmrg echo appending configuration tag \"$tagname\" to $ofile 18859bd41f2cSmrg 18869bd41f2cSmrg case $tagname in 18879bd41f2cSmrg CXX) 18889bd41f2cSmrg if test -n "$CXX" && ( test "X$CXX" != "Xno" && 18899bd41f2cSmrg ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || 18909bd41f2cSmrg (test "X$CXX" != "Xg++"))) ; then 18919bd41f2cSmrg AC_LIBTOOL_LANG_CXX_CONFIG 18929bd41f2cSmrg else 18939bd41f2cSmrg tagname="" 18949bd41f2cSmrg fi 18959bd41f2cSmrg ;; 18969bd41f2cSmrg 18979bd41f2cSmrg F77) 18989bd41f2cSmrg if test -n "$F77" && test "X$F77" != "Xno"; then 18999bd41f2cSmrg AC_LIBTOOL_LANG_F77_CONFIG 19009bd41f2cSmrg else 19019bd41f2cSmrg tagname="" 19029bd41f2cSmrg fi 19039bd41f2cSmrg ;; 19049bd41f2cSmrg 19059bd41f2cSmrg GCJ) 19069bd41f2cSmrg if test -n "$GCJ" && test "X$GCJ" != "Xno"; then 19079bd41f2cSmrg AC_LIBTOOL_LANG_GCJ_CONFIG 19089bd41f2cSmrg else 19099bd41f2cSmrg tagname="" 19109bd41f2cSmrg fi 19119bd41f2cSmrg ;; 19129bd41f2cSmrg 19139bd41f2cSmrg RC) 19149bd41f2cSmrg AC_LIBTOOL_LANG_RC_CONFIG 19159bd41f2cSmrg ;; 19169bd41f2cSmrg 19179bd41f2cSmrg *) 19189bd41f2cSmrg AC_MSG_ERROR([Unsupported tag name: $tagname]) 19199bd41f2cSmrg ;; 19209bd41f2cSmrg esac 19219bd41f2cSmrg 19229bd41f2cSmrg # Append the new tag name to the list of available tags. 19239bd41f2cSmrg if test -n "$tagname" ; then 19249bd41f2cSmrg available_tags="$available_tags $tagname" 19259bd41f2cSmrg fi 19269bd41f2cSmrg fi 19279bd41f2cSmrg done 19289bd41f2cSmrg IFS="$lt_save_ifs" 19299bd41f2cSmrg 19309bd41f2cSmrg # Now substitute the updated list of available tags. 19319bd41f2cSmrg if eval "sed -e 's/^available_tags=.*\$/available_tags=\"$available_tags\"/' \"$ofile\" > \"${ofile}T\""; then 19329bd41f2cSmrg mv "${ofile}T" "$ofile" 19339bd41f2cSmrg chmod +x "$ofile" 19349bd41f2cSmrg else 19359bd41f2cSmrg rm -f "${ofile}T" 19369bd41f2cSmrg AC_MSG_ERROR([unable to update list of available tagged configurations.]) 19379bd41f2cSmrg fi 19389bd41f2cSmrgfi 19399bd41f2cSmrg])# _LT_AC_TAGCONFIG 19409bd41f2cSmrg 19419bd41f2cSmrg 19429bd41f2cSmrg# AC_LIBTOOL_DLOPEN 19439bd41f2cSmrg# ----------------- 19449bd41f2cSmrg# enable checks for dlopen support 19459bd41f2cSmrgAC_DEFUN([AC_LIBTOOL_DLOPEN], 19469bd41f2cSmrg [AC_BEFORE([$0],[AC_LIBTOOL_SETUP]) 19479bd41f2cSmrg])# AC_LIBTOOL_DLOPEN 19489bd41f2cSmrg 19499bd41f2cSmrg 19509bd41f2cSmrg# AC_LIBTOOL_WIN32_DLL 19519bd41f2cSmrg# -------------------- 19529bd41f2cSmrg# declare package support for building win32 DLLs 19539bd41f2cSmrgAC_DEFUN([AC_LIBTOOL_WIN32_DLL], 19549bd41f2cSmrg[AC_BEFORE([$0], [AC_LIBTOOL_SETUP]) 19559bd41f2cSmrg])# AC_LIBTOOL_WIN32_DLL 19569bd41f2cSmrg 19579bd41f2cSmrg 19589bd41f2cSmrg# AC_ENABLE_SHARED([DEFAULT]) 19599bd41f2cSmrg# --------------------------- 19609bd41f2cSmrg# implement the --enable-shared flag 19619bd41f2cSmrg# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. 19629bd41f2cSmrgAC_DEFUN([AC_ENABLE_SHARED], 19639bd41f2cSmrg[define([AC_ENABLE_SHARED_DEFAULT], ifelse($1, no, no, yes))dnl 19649bd41f2cSmrgAC_ARG_ENABLE([shared], 19659bd41f2cSmrg [AC_HELP_STRING([--enable-shared@<:@=PKGS@:>@], 19669bd41f2cSmrg [build shared libraries @<:@default=]AC_ENABLE_SHARED_DEFAULT[@:>@])], 19679bd41f2cSmrg [p=${PACKAGE-default} 19689bd41f2cSmrg case $enableval in 19699bd41f2cSmrg yes) enable_shared=yes ;; 19709bd41f2cSmrg no) enable_shared=no ;; 19719bd41f2cSmrg *) 19729bd41f2cSmrg enable_shared=no 19739bd41f2cSmrg # Look at the argument we got. We use all the common list separators. 19749bd41f2cSmrg lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," 19759bd41f2cSmrg for pkg in $enableval; do 19769bd41f2cSmrg IFS="$lt_save_ifs" 19779bd41f2cSmrg if test "X$pkg" = "X$p"; then 19789bd41f2cSmrg enable_shared=yes 19799bd41f2cSmrg fi 19809bd41f2cSmrg done 19819bd41f2cSmrg IFS="$lt_save_ifs" 19829bd41f2cSmrg ;; 19839bd41f2cSmrg esac], 19849bd41f2cSmrg [enable_shared=]AC_ENABLE_SHARED_DEFAULT) 19859bd41f2cSmrg])# AC_ENABLE_SHARED 19869bd41f2cSmrg 19879bd41f2cSmrg 19889bd41f2cSmrg# AC_DISABLE_SHARED 19899bd41f2cSmrg# ----------------- 19909bd41f2cSmrg# set the default shared flag to --disable-shared 19919bd41f2cSmrgAC_DEFUN([AC_DISABLE_SHARED], 19929bd41f2cSmrg[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl 19939bd41f2cSmrgAC_ENABLE_SHARED(no) 19949bd41f2cSmrg])# AC_DISABLE_SHARED 19959bd41f2cSmrg 19969bd41f2cSmrg 19979bd41f2cSmrg# AC_ENABLE_STATIC([DEFAULT]) 19989bd41f2cSmrg# --------------------------- 19999bd41f2cSmrg# implement the --enable-static flag 20009bd41f2cSmrg# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. 20019bd41f2cSmrgAC_DEFUN([AC_ENABLE_STATIC], 20029bd41f2cSmrg[define([AC_ENABLE_STATIC_DEFAULT], ifelse($1, no, no, yes))dnl 20039bd41f2cSmrgAC_ARG_ENABLE([static], 20049bd41f2cSmrg [AC_HELP_STRING([--enable-static@<:@=PKGS@:>@], 20059bd41f2cSmrg [build static libraries @<:@default=]AC_ENABLE_STATIC_DEFAULT[@:>@])], 20069bd41f2cSmrg [p=${PACKAGE-default} 20079bd41f2cSmrg case $enableval in 20089bd41f2cSmrg yes) enable_static=yes ;; 20099bd41f2cSmrg no) enable_static=no ;; 20109bd41f2cSmrg *) 20119bd41f2cSmrg enable_static=no 20129bd41f2cSmrg # Look at the argument we got. We use all the common list separators. 20139bd41f2cSmrg lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," 20149bd41f2cSmrg for pkg in $enableval; do 20159bd41f2cSmrg IFS="$lt_save_ifs" 20169bd41f2cSmrg if test "X$pkg" = "X$p"; then 20179bd41f2cSmrg enable_static=yes 20189bd41f2cSmrg fi 20199bd41f2cSmrg done 20209bd41f2cSmrg IFS="$lt_save_ifs" 20219bd41f2cSmrg ;; 20229bd41f2cSmrg esac], 20239bd41f2cSmrg [enable_static=]AC_ENABLE_STATIC_DEFAULT) 20249bd41f2cSmrg])# AC_ENABLE_STATIC 20259bd41f2cSmrg 20269bd41f2cSmrg 20279bd41f2cSmrg# AC_DISABLE_STATIC 20289bd41f2cSmrg# ----------------- 20299bd41f2cSmrg# set the default static flag to --disable-static 20309bd41f2cSmrgAC_DEFUN([AC_DISABLE_STATIC], 20319bd41f2cSmrg[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl 20329bd41f2cSmrgAC_ENABLE_STATIC(no) 20339bd41f2cSmrg])# AC_DISABLE_STATIC 20349bd41f2cSmrg 20359bd41f2cSmrg 20369bd41f2cSmrg# AC_ENABLE_FAST_INSTALL([DEFAULT]) 20379bd41f2cSmrg# --------------------------------- 20389bd41f2cSmrg# implement the --enable-fast-install flag 20399bd41f2cSmrg# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. 20409bd41f2cSmrgAC_DEFUN([AC_ENABLE_FAST_INSTALL], 20419bd41f2cSmrg[define([AC_ENABLE_FAST_INSTALL_DEFAULT], ifelse($1, no, no, yes))dnl 20429bd41f2cSmrgAC_ARG_ENABLE([fast-install], 20439bd41f2cSmrg [AC_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@], 20449bd41f2cSmrg [optimize for fast installation @<:@default=]AC_ENABLE_FAST_INSTALL_DEFAULT[@:>@])], 20459bd41f2cSmrg [p=${PACKAGE-default} 20469bd41f2cSmrg case $enableval in 20479bd41f2cSmrg yes) enable_fast_install=yes ;; 20489bd41f2cSmrg no) enable_fast_install=no ;; 20499bd41f2cSmrg *) 20509bd41f2cSmrg enable_fast_install=no 20519bd41f2cSmrg # Look at the argument we got. We use all the common list separators. 20529bd41f2cSmrg lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," 20539bd41f2cSmrg for pkg in $enableval; do 20549bd41f2cSmrg IFS="$lt_save_ifs" 20559bd41f2cSmrg if test "X$pkg" = "X$p"; then 20569bd41f2cSmrg enable_fast_install=yes 20579bd41f2cSmrg fi 20589bd41f2cSmrg done 20599bd41f2cSmrg IFS="$lt_save_ifs" 20609bd41f2cSmrg ;; 20619bd41f2cSmrg esac], 20629bd41f2cSmrg [enable_fast_install=]AC_ENABLE_FAST_INSTALL_DEFAULT) 20639bd41f2cSmrg])# AC_ENABLE_FAST_INSTALL 20649bd41f2cSmrg 20659bd41f2cSmrg 20669bd41f2cSmrg# AC_DISABLE_FAST_INSTALL 20679bd41f2cSmrg# ----------------------- 20689bd41f2cSmrg# set the default to --disable-fast-install 20699bd41f2cSmrgAC_DEFUN([AC_DISABLE_FAST_INSTALL], 20709bd41f2cSmrg[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl 20719bd41f2cSmrgAC_ENABLE_FAST_INSTALL(no) 20729bd41f2cSmrg])# AC_DISABLE_FAST_INSTALL 20739bd41f2cSmrg 20749bd41f2cSmrg 20759bd41f2cSmrg# AC_LIBTOOL_PICMODE([MODE]) 20769bd41f2cSmrg# -------------------------- 20779bd41f2cSmrg# implement the --with-pic flag 20789bd41f2cSmrg# MODE is either `yes' or `no'. If omitted, it defaults to `both'. 20799bd41f2cSmrgAC_DEFUN([AC_LIBTOOL_PICMODE], 20809bd41f2cSmrg[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl 20819bd41f2cSmrgpic_mode=ifelse($#,1,$1,default) 20829bd41f2cSmrg])# AC_LIBTOOL_PICMODE 20839bd41f2cSmrg 20849bd41f2cSmrg 20859bd41f2cSmrg# AC_PROG_EGREP 20869bd41f2cSmrg# ------------- 20879bd41f2cSmrg# This is predefined starting with Autoconf 2.54, so this conditional 20889bd41f2cSmrg# definition can be removed once we require Autoconf 2.54 or later. 20899bd41f2cSmrgm4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP], 20909bd41f2cSmrg[AC_CACHE_CHECK([for egrep], [ac_cv_prog_egrep], 20919bd41f2cSmrg [if echo a | (grep -E '(a|b)') >/dev/null 2>&1 20929bd41f2cSmrg then ac_cv_prog_egrep='grep -E' 20939bd41f2cSmrg else ac_cv_prog_egrep='egrep' 20949bd41f2cSmrg fi]) 20959bd41f2cSmrg EGREP=$ac_cv_prog_egrep 20969bd41f2cSmrg AC_SUBST([EGREP]) 20979bd41f2cSmrg])]) 20989bd41f2cSmrg 20999bd41f2cSmrg 21009bd41f2cSmrg# AC_PATH_TOOL_PREFIX 21019bd41f2cSmrg# ------------------- 21029bd41f2cSmrg# find a file program which can recognize shared library 21039bd41f2cSmrgAC_DEFUN([AC_PATH_TOOL_PREFIX], 21049bd41f2cSmrg[AC_REQUIRE([AC_PROG_EGREP])dnl 21059bd41f2cSmrgAC_MSG_CHECKING([for $1]) 21069bd41f2cSmrgAC_CACHE_VAL(lt_cv_path_MAGIC_CMD, 21079bd41f2cSmrg[case $MAGIC_CMD in 21089bd41f2cSmrg[[\\/*] | ?:[\\/]*]) 21099bd41f2cSmrg lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. 21109bd41f2cSmrg ;; 21119bd41f2cSmrg*) 21129bd41f2cSmrg lt_save_MAGIC_CMD="$MAGIC_CMD" 21139bd41f2cSmrg lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR 21149bd41f2cSmrgdnl $ac_dummy forces splitting on constant user-supplied paths. 21159bd41f2cSmrgdnl POSIX.2 word splitting is done only on the output of word expansions, 21169bd41f2cSmrgdnl not every word. This closes a longstanding sh security hole. 21179bd41f2cSmrg ac_dummy="ifelse([$2], , $PATH, [$2])" 21189bd41f2cSmrg for ac_dir in $ac_dummy; do 21199bd41f2cSmrg IFS="$lt_save_ifs" 21209bd41f2cSmrg test -z "$ac_dir" && ac_dir=. 21219bd41f2cSmrg if test -f $ac_dir/$1; then 21229bd41f2cSmrg lt_cv_path_MAGIC_CMD="$ac_dir/$1" 21239bd41f2cSmrg if test -n "$file_magic_test_file"; then 21249bd41f2cSmrg case $deplibs_check_method in 21259bd41f2cSmrg "file_magic "*) 21269bd41f2cSmrg file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` 21279bd41f2cSmrg MAGIC_CMD="$lt_cv_path_MAGIC_CMD" 21289bd41f2cSmrg if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | 21299bd41f2cSmrg $EGREP "$file_magic_regex" > /dev/null; then 21309bd41f2cSmrg : 21319bd41f2cSmrg else 21329bd41f2cSmrg cat <<EOF 1>&2 21339bd41f2cSmrg 21349bd41f2cSmrg*** Warning: the command libtool uses to detect shared libraries, 21359bd41f2cSmrg*** $file_magic_cmd, produces output that libtool cannot recognize. 21369bd41f2cSmrg*** The result is that libtool may fail to recognize shared libraries 21379bd41f2cSmrg*** as such. This will affect the creation of libtool libraries that 21389bd41f2cSmrg*** depend on shared libraries, but programs linked with such libtool 21399bd41f2cSmrg*** libraries will work regardless of this problem. Nevertheless, you 21409bd41f2cSmrg*** may want to report the problem to your system manager and/or to 21419bd41f2cSmrg*** bug-libtool@gnu.org 21429bd41f2cSmrg 21439bd41f2cSmrgEOF 21449bd41f2cSmrg fi ;; 21459bd41f2cSmrg esac 21469bd41f2cSmrg fi 21479bd41f2cSmrg break 21489bd41f2cSmrg fi 21499bd41f2cSmrg done 21509bd41f2cSmrg IFS="$lt_save_ifs" 21519bd41f2cSmrg MAGIC_CMD="$lt_save_MAGIC_CMD" 21529bd41f2cSmrg ;; 21539bd41f2cSmrgesac]) 21549bd41f2cSmrgMAGIC_CMD="$lt_cv_path_MAGIC_CMD" 21559bd41f2cSmrgif test -n "$MAGIC_CMD"; then 21569bd41f2cSmrg AC_MSG_RESULT($MAGIC_CMD) 21579bd41f2cSmrgelse 21589bd41f2cSmrg AC_MSG_RESULT(no) 21599bd41f2cSmrgfi 21609bd41f2cSmrg])# AC_PATH_TOOL_PREFIX 21619bd41f2cSmrg 21629bd41f2cSmrg 21639bd41f2cSmrg# AC_PATH_MAGIC 21649bd41f2cSmrg# ------------- 21659bd41f2cSmrg# find a file program which can recognize a shared library 21669bd41f2cSmrgAC_DEFUN([AC_PATH_MAGIC], 21679bd41f2cSmrg[AC_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH) 21689bd41f2cSmrgif test -z "$lt_cv_path_MAGIC_CMD"; then 21699bd41f2cSmrg if test -n "$ac_tool_prefix"; then 21709bd41f2cSmrg AC_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH) 21719bd41f2cSmrg else 21729bd41f2cSmrg MAGIC_CMD=: 21739bd41f2cSmrg fi 21749bd41f2cSmrgfi 21759bd41f2cSmrg])# AC_PATH_MAGIC 21769bd41f2cSmrg 21779bd41f2cSmrg 21789bd41f2cSmrg# AC_PROG_LD 21799bd41f2cSmrg# ---------- 21809bd41f2cSmrg# find the pathname to the GNU or non-GNU linker 21819bd41f2cSmrgAC_DEFUN([AC_PROG_LD], 21829bd41f2cSmrg[AC_ARG_WITH([gnu-ld], 21839bd41f2cSmrg [AC_HELP_STRING([--with-gnu-ld], 21849bd41f2cSmrg [assume the C compiler uses GNU ld @<:@default=no@:>@])], 21859bd41f2cSmrg [test "$withval" = no || with_gnu_ld=yes], 21869bd41f2cSmrg [with_gnu_ld=no]) 21879bd41f2cSmrgAC_REQUIRE([LT_AC_PROG_SED])dnl 21889bd41f2cSmrgAC_REQUIRE([AC_PROG_CC])dnl 21899bd41f2cSmrgAC_REQUIRE([AC_CANONICAL_HOST])dnl 21909bd41f2cSmrgAC_REQUIRE([AC_CANONICAL_BUILD])dnl 21919bd41f2cSmrgac_prog=ld 21929bd41f2cSmrgif test "$GCC" = yes; then 21939bd41f2cSmrg # Check if gcc -print-prog-name=ld gives a path. 21949bd41f2cSmrg AC_MSG_CHECKING([for ld used by $CC]) 21959bd41f2cSmrg case $host in 21969bd41f2cSmrg *-*-mingw*) 21979bd41f2cSmrg # gcc leaves a trailing carriage return which upsets mingw 21989bd41f2cSmrg ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; 21999bd41f2cSmrg *) 22009bd41f2cSmrg ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; 22019bd41f2cSmrg esac 22029bd41f2cSmrg case $ac_prog in 22039bd41f2cSmrg # Accept absolute paths. 22049bd41f2cSmrg [[\\/]]* | ?:[[\\/]]*) 22059bd41f2cSmrg re_direlt='/[[^/]][[^/]]*/\.\./' 22069bd41f2cSmrg # Canonicalize the pathname of ld 22079bd41f2cSmrg ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'` 22089bd41f2cSmrg while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do 22099bd41f2cSmrg ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"` 22109bd41f2cSmrg done 22119bd41f2cSmrg test -z "$LD" && LD="$ac_prog" 22129bd41f2cSmrg ;; 22139bd41f2cSmrg "") 22149bd41f2cSmrg # If it fails, then pretend we aren't using GCC. 22159bd41f2cSmrg ac_prog=ld 22169bd41f2cSmrg ;; 22179bd41f2cSmrg *) 22189bd41f2cSmrg # If it is relative, then search for the first ld in PATH. 22199bd41f2cSmrg with_gnu_ld=unknown 22209bd41f2cSmrg ;; 22219bd41f2cSmrg esac 22229bd41f2cSmrgelif test "$with_gnu_ld" = yes; then 22239bd41f2cSmrg AC_MSG_CHECKING([for GNU ld]) 22249bd41f2cSmrgelse 22259bd41f2cSmrg AC_MSG_CHECKING([for non-GNU ld]) 22269bd41f2cSmrgfi 22279bd41f2cSmrgAC_CACHE_VAL(lt_cv_path_LD, 22289bd41f2cSmrg[if test -z "$LD"; then 22299bd41f2cSmrg lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR 22309bd41f2cSmrg for ac_dir in $PATH; do 22319bd41f2cSmrg IFS="$lt_save_ifs" 22329bd41f2cSmrg test -z "$ac_dir" && ac_dir=. 22339bd41f2cSmrg if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then 22349bd41f2cSmrg lt_cv_path_LD="$ac_dir/$ac_prog" 22359bd41f2cSmrg # Check to see if the program is GNU ld. I'd rather use --version, 22369bd41f2cSmrg # but apparently some variants of GNU ld only accept -v. 22379bd41f2cSmrg # Break only if it was the GNU/non-GNU ld that we prefer. 22389bd41f2cSmrg case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in 22399bd41f2cSmrg *GNU* | *'with BFD'*) 22409bd41f2cSmrg test "$with_gnu_ld" != no && break 22419bd41f2cSmrg ;; 22429bd41f2cSmrg *) 22439bd41f2cSmrg test "$with_gnu_ld" != yes && break 22449bd41f2cSmrg ;; 22459bd41f2cSmrg esac 22469bd41f2cSmrg fi 22479bd41f2cSmrg done 22489bd41f2cSmrg IFS="$lt_save_ifs" 22499bd41f2cSmrgelse 22509bd41f2cSmrg lt_cv_path_LD="$LD" # Let the user override the test with a path. 22519bd41f2cSmrgfi]) 22529bd41f2cSmrgLD="$lt_cv_path_LD" 22539bd41f2cSmrgif test -n "$LD"; then 22549bd41f2cSmrg AC_MSG_RESULT($LD) 22559bd41f2cSmrgelse 22569bd41f2cSmrg AC_MSG_RESULT(no) 22579bd41f2cSmrgfi 22589bd41f2cSmrgtest -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH]) 22599bd41f2cSmrgAC_PROG_LD_GNU 22609bd41f2cSmrg])# AC_PROG_LD 22619bd41f2cSmrg 22629bd41f2cSmrg 22639bd41f2cSmrg# AC_PROG_LD_GNU 22649bd41f2cSmrg# -------------- 22659bd41f2cSmrgAC_DEFUN([AC_PROG_LD_GNU], 22669bd41f2cSmrg[AC_REQUIRE([AC_PROG_EGREP])dnl 22679bd41f2cSmrgAC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld, 22689bd41f2cSmrg[# I'd rather use --version here, but apparently some GNU lds only accept -v. 22699bd41f2cSmrgcase `$LD -v 2>&1 </dev/null` in 22709bd41f2cSmrg*GNU* | *'with BFD'*) 22719bd41f2cSmrg lt_cv_prog_gnu_ld=yes 22729bd41f2cSmrg ;; 22739bd41f2cSmrg*) 22749bd41f2cSmrg lt_cv_prog_gnu_ld=no 22759bd41f2cSmrg ;; 22769bd41f2cSmrgesac]) 22779bd41f2cSmrgwith_gnu_ld=$lt_cv_prog_gnu_ld 22789bd41f2cSmrg])# AC_PROG_LD_GNU 22799bd41f2cSmrg 22809bd41f2cSmrg 22819bd41f2cSmrg# AC_PROG_LD_RELOAD_FLAG 22829bd41f2cSmrg# ---------------------- 22839bd41f2cSmrg# find reload flag for linker 22849bd41f2cSmrg# -- PORTME Some linkers may need a different reload flag. 22859bd41f2cSmrgAC_DEFUN([AC_PROG_LD_RELOAD_FLAG], 22869bd41f2cSmrg[AC_CACHE_CHECK([for $LD option to reload object files], 22879bd41f2cSmrg lt_cv_ld_reload_flag, 22889bd41f2cSmrg [lt_cv_ld_reload_flag='-r']) 22899bd41f2cSmrgreload_flag=$lt_cv_ld_reload_flag 22909bd41f2cSmrgcase $reload_flag in 22919bd41f2cSmrg"" | " "*) ;; 22929bd41f2cSmrg*) reload_flag=" $reload_flag" ;; 22939bd41f2cSmrgesac 22949bd41f2cSmrgreload_cmds='$LD$reload_flag -o $output$reload_objs' 22959bd41f2cSmrgcase $host_os in 22969bd41f2cSmrg darwin*) 22979bd41f2cSmrg if test "$GCC" = yes; then 22989bd41f2cSmrg reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs' 22999bd41f2cSmrg else 23009bd41f2cSmrg reload_cmds='$LD$reload_flag -o $output$reload_objs' 23019bd41f2cSmrg fi 23029bd41f2cSmrg ;; 23039bd41f2cSmrgesac 23049bd41f2cSmrg])# AC_PROG_LD_RELOAD_FLAG 23059bd41f2cSmrg 23069bd41f2cSmrg 23079bd41f2cSmrg# AC_DEPLIBS_CHECK_METHOD 23089bd41f2cSmrg# ----------------------- 23099bd41f2cSmrg# how to check for library dependencies 23109bd41f2cSmrg# -- PORTME fill in with the dynamic library characteristics 23119bd41f2cSmrgAC_DEFUN([AC_DEPLIBS_CHECK_METHOD], 23129bd41f2cSmrg[AC_CACHE_CHECK([how to recognize dependent libraries], 23139bd41f2cSmrglt_cv_deplibs_check_method, 23149bd41f2cSmrg[lt_cv_file_magic_cmd='$MAGIC_CMD' 23159bd41f2cSmrglt_cv_file_magic_test_file= 23169bd41f2cSmrglt_cv_deplibs_check_method='unknown' 23179bd41f2cSmrg# Need to set the preceding variable on all platforms that support 23189bd41f2cSmrg# interlibrary dependencies. 23199bd41f2cSmrg# 'none' -- dependencies not supported. 23209bd41f2cSmrg# `unknown' -- same as none, but documents that we really don't know. 23219bd41f2cSmrg# 'pass_all' -- all dependencies passed with no checks. 23229bd41f2cSmrg# 'test_compile' -- check by making test program. 23239bd41f2cSmrg# 'file_magic [[regex]]' -- check by looking for files in library path 23249bd41f2cSmrg# which responds to the $file_magic_cmd with a given extended regex. 23259bd41f2cSmrg# If you have `file' or equivalent on your system and you're not sure 23269bd41f2cSmrg# whether `pass_all' will *always* work, you probably want this one. 23279bd41f2cSmrg 23289bd41f2cSmrgcase $host_os in 23299bd41f2cSmrgaix4* | aix5*) 23309bd41f2cSmrg lt_cv_deplibs_check_method=pass_all 23319bd41f2cSmrg ;; 23329bd41f2cSmrg 23339bd41f2cSmrgbeos*) 23349bd41f2cSmrg lt_cv_deplibs_check_method=pass_all 23359bd41f2cSmrg ;; 23369bd41f2cSmrg 23379bd41f2cSmrgbsdi[[45]]*) 23389bd41f2cSmrg lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)' 23399bd41f2cSmrg lt_cv_file_magic_cmd='/usr/bin/file -L' 23409bd41f2cSmrg lt_cv_file_magic_test_file=/shlib/libc.so 23419bd41f2cSmrg ;; 23429bd41f2cSmrg 23439bd41f2cSmrgcygwin*) 23449bd41f2cSmrg # func_win32_libid is a shell function defined in ltmain.sh 23459bd41f2cSmrg lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' 23469bd41f2cSmrg lt_cv_file_magic_cmd='func_win32_libid' 23479bd41f2cSmrg ;; 23489bd41f2cSmrg 23499bd41f2cSmrgmingw* | pw32*) 23509bd41f2cSmrg # Base MSYS/MinGW do not provide the 'file' command needed by 23519bd41f2cSmrg # func_win32_libid shell function, so use a weaker test based on 'objdump', 23529bd41f2cSmrg # unless we find 'file', for example because we are cross-compiling. 23539bd41f2cSmrg if ( file / ) >/dev/null 2>&1; then 23549bd41f2cSmrg lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' 23559bd41f2cSmrg lt_cv_file_magic_cmd='func_win32_libid' 23569bd41f2cSmrg else 23579bd41f2cSmrg lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?' 23589bd41f2cSmrg lt_cv_file_magic_cmd='$OBJDUMP -f' 23599bd41f2cSmrg fi 23609bd41f2cSmrg ;; 23619bd41f2cSmrg 23629bd41f2cSmrgdarwin* | rhapsody*) 23639bd41f2cSmrg lt_cv_deplibs_check_method=pass_all 23649bd41f2cSmrg ;; 23659bd41f2cSmrg 23669bd41f2cSmrgfreebsd* | dragonfly*) 23679bd41f2cSmrg if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then 23689bd41f2cSmrg case $host_cpu in 23699bd41f2cSmrg i*86 ) 23709bd41f2cSmrg # Not sure whether the presence of OpenBSD here was a mistake. 23719bd41f2cSmrg # Let's accept both of them until this is cleared up. 23729bd41f2cSmrg lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library' 23739bd41f2cSmrg lt_cv_file_magic_cmd=/usr/bin/file 23749bd41f2cSmrg lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` 23759bd41f2cSmrg ;; 23769bd41f2cSmrg esac 23779bd41f2cSmrg else 23789bd41f2cSmrg lt_cv_deplibs_check_method=pass_all 23799bd41f2cSmrg fi 23809bd41f2cSmrg ;; 23819bd41f2cSmrg 23829bd41f2cSmrggnu*) 23839bd41f2cSmrg lt_cv_deplibs_check_method=pass_all 23849bd41f2cSmrg ;; 23859bd41f2cSmrg 23869bd41f2cSmrghpux10.20* | hpux11*) 23879bd41f2cSmrg lt_cv_file_magic_cmd=/usr/bin/file 23889bd41f2cSmrg case $host_cpu in 23899bd41f2cSmrg ia64*) 23909bd41f2cSmrg lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64' 23919bd41f2cSmrg lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so 23929bd41f2cSmrg ;; 23939bd41f2cSmrg hppa*64*) 23949bd41f2cSmrg [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - PA-RISC [0-9].[0-9]'] 23959bd41f2cSmrg lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl 23969bd41f2cSmrg ;; 23979bd41f2cSmrg *) 23989bd41f2cSmrg lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]].[[0-9]]) shared library' 23999bd41f2cSmrg lt_cv_file_magic_test_file=/usr/lib/libc.sl 24009bd41f2cSmrg ;; 24019bd41f2cSmrg esac 24029bd41f2cSmrg ;; 24039bd41f2cSmrg 24049bd41f2cSmrginterix[[3-9]]*) 24059bd41f2cSmrg # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here 24069bd41f2cSmrg lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$' 24079bd41f2cSmrg ;; 24089bd41f2cSmrg 24099bd41f2cSmrgirix5* | irix6* | nonstopux*) 24109bd41f2cSmrg case $LD in 24119bd41f2cSmrg *-32|*"-32 ") libmagic=32-bit;; 24129bd41f2cSmrg *-n32|*"-n32 ") libmagic=N32;; 24139bd41f2cSmrg *-64|*"-64 ") libmagic=64-bit;; 24149bd41f2cSmrg *) libmagic=never-match;; 24159bd41f2cSmrg esac 24169bd41f2cSmrg lt_cv_deplibs_check_method=pass_all 24179bd41f2cSmrg ;; 24189bd41f2cSmrg 24199bd41f2cSmrg# This must be Linux ELF. 24209bd41f2cSmrglinux* | k*bsd*-gnu) 24219bd41f2cSmrg lt_cv_deplibs_check_method=pass_all 24229bd41f2cSmrg ;; 24239bd41f2cSmrg 24249bd41f2cSmrgnetbsd*) 24259bd41f2cSmrg if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then 24269bd41f2cSmrg lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' 24279bd41f2cSmrg else 24289bd41f2cSmrg lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$' 24299bd41f2cSmrg fi 24309bd41f2cSmrg ;; 24319bd41f2cSmrg 24329bd41f2cSmrgnewos6*) 24339bd41f2cSmrg lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)' 24349bd41f2cSmrg lt_cv_file_magic_cmd=/usr/bin/file 24359bd41f2cSmrg lt_cv_file_magic_test_file=/usr/lib/libnls.so 24369bd41f2cSmrg ;; 24379bd41f2cSmrg 24389bd41f2cSmrgnto-qnx*) 24399bd41f2cSmrg lt_cv_deplibs_check_method=unknown 24409bd41f2cSmrg ;; 24419bd41f2cSmrg 24429bd41f2cSmrgopenbsd*) 24439bd41f2cSmrg if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then 24449bd41f2cSmrg lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$' 24459bd41f2cSmrg else 24469bd41f2cSmrg lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' 24479bd41f2cSmrg fi 24489bd41f2cSmrg ;; 24499bd41f2cSmrg 24509bd41f2cSmrgosf3* | osf4* | osf5*) 24519bd41f2cSmrg lt_cv_deplibs_check_method=pass_all 24529bd41f2cSmrg ;; 24539bd41f2cSmrg 24549bd41f2cSmrgrdos*) 24559bd41f2cSmrg lt_cv_deplibs_check_method=pass_all 24569bd41f2cSmrg ;; 24579bd41f2cSmrg 24589bd41f2cSmrgsolaris*) 24599bd41f2cSmrg lt_cv_deplibs_check_method=pass_all 24609bd41f2cSmrg ;; 24619bd41f2cSmrg 24629bd41f2cSmrgsysv4 | sysv4.3*) 24639bd41f2cSmrg case $host_vendor in 24649bd41f2cSmrg motorola) 24659bd41f2cSmrg lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib) M[[0-9]][[0-9]]* Version [[0-9]]' 24669bd41f2cSmrg lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` 24679bd41f2cSmrg ;; 24689bd41f2cSmrg ncr) 24699bd41f2cSmrg lt_cv_deplibs_check_method=pass_all 24709bd41f2cSmrg ;; 24719bd41f2cSmrg sequent) 24729bd41f2cSmrg lt_cv_file_magic_cmd='/bin/file' 24739bd41f2cSmrg lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )' 24749bd41f2cSmrg ;; 24759bd41f2cSmrg sni) 24769bd41f2cSmrg lt_cv_file_magic_cmd='/bin/file' 24779bd41f2cSmrg lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib" 24789bd41f2cSmrg lt_cv_file_magic_test_file=/lib/libc.so 24799bd41f2cSmrg ;; 24809bd41f2cSmrg siemens) 24819bd41f2cSmrg lt_cv_deplibs_check_method=pass_all 24829bd41f2cSmrg ;; 24839bd41f2cSmrg pc) 24849bd41f2cSmrg lt_cv_deplibs_check_method=pass_all 24859bd41f2cSmrg ;; 24869bd41f2cSmrg esac 24879bd41f2cSmrg ;; 24889bd41f2cSmrg 24899bd41f2cSmrgsysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) 24909bd41f2cSmrg lt_cv_deplibs_check_method=pass_all 24919bd41f2cSmrg ;; 24929bd41f2cSmrgesac 24939bd41f2cSmrg]) 24949bd41f2cSmrgfile_magic_cmd=$lt_cv_file_magic_cmd 24959bd41f2cSmrgdeplibs_check_method=$lt_cv_deplibs_check_method 24969bd41f2cSmrgtest -z "$deplibs_check_method" && deplibs_check_method=unknown 24979bd41f2cSmrg])# AC_DEPLIBS_CHECK_METHOD 24989bd41f2cSmrg 24999bd41f2cSmrg 25009bd41f2cSmrg# AC_PROG_NM 25019bd41f2cSmrg# ---------- 25029bd41f2cSmrg# find the pathname to a BSD-compatible name lister 25039bd41f2cSmrgAC_DEFUN([AC_PROG_NM], 25049bd41f2cSmrg[AC_CACHE_CHECK([for BSD-compatible nm], lt_cv_path_NM, 25059bd41f2cSmrg[if test -n "$NM"; then 25069bd41f2cSmrg # Let the user override the test. 25079bd41f2cSmrg lt_cv_path_NM="$NM" 25089bd41f2cSmrgelse 25099bd41f2cSmrg lt_nm_to_check="${ac_tool_prefix}nm" 25109bd41f2cSmrg if test -n "$ac_tool_prefix" && test "$build" = "$host"; then 25119bd41f2cSmrg lt_nm_to_check="$lt_nm_to_check nm" 25129bd41f2cSmrg fi 25139bd41f2cSmrg for lt_tmp_nm in $lt_nm_to_check; do 25149bd41f2cSmrg lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR 25159bd41f2cSmrg for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do 25169bd41f2cSmrg IFS="$lt_save_ifs" 25179bd41f2cSmrg test -z "$ac_dir" && ac_dir=. 25189bd41f2cSmrg tmp_nm="$ac_dir/$lt_tmp_nm" 25199bd41f2cSmrg if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then 25209bd41f2cSmrg # Check to see if the nm accepts a BSD-compat flag. 25219bd41f2cSmrg # Adding the `sed 1q' prevents false positives on HP-UX, which says: 25229bd41f2cSmrg # nm: unknown option "B" ignored 25239bd41f2cSmrg # Tru64's nm complains that /dev/null is an invalid object file 25249bd41f2cSmrg case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in 25259bd41f2cSmrg */dev/null* | *'Invalid file or object type'*) 25269bd41f2cSmrg lt_cv_path_NM="$tmp_nm -B" 25279bd41f2cSmrg break 25289bd41f2cSmrg ;; 25299bd41f2cSmrg *) 25309bd41f2cSmrg case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in 25319bd41f2cSmrg */dev/null*) 25329bd41f2cSmrg lt_cv_path_NM="$tmp_nm -p" 25339bd41f2cSmrg break 25349bd41f2cSmrg ;; 25359bd41f2cSmrg *) 25369bd41f2cSmrg lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but 25379bd41f2cSmrg continue # so that we can try to find one that supports BSD flags 25389bd41f2cSmrg ;; 25399bd41f2cSmrg esac 25409bd41f2cSmrg ;; 25419bd41f2cSmrg esac 25429bd41f2cSmrg fi 25439bd41f2cSmrg done 25449bd41f2cSmrg IFS="$lt_save_ifs" 25459bd41f2cSmrg done 25469bd41f2cSmrg test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm 25479bd41f2cSmrgfi]) 25489bd41f2cSmrgNM="$lt_cv_path_NM" 25499bd41f2cSmrg])# AC_PROG_NM 25509bd41f2cSmrg 25519bd41f2cSmrg 25529bd41f2cSmrg# AC_CHECK_LIBM 25539bd41f2cSmrg# ------------- 25549bd41f2cSmrg# check for math library 25559bd41f2cSmrgAC_DEFUN([AC_CHECK_LIBM], 25569bd41f2cSmrg[AC_REQUIRE([AC_CANONICAL_HOST])dnl 25579bd41f2cSmrgLIBM= 25589bd41f2cSmrgcase $host in 25599bd41f2cSmrg*-*-beos* | *-*-cygwin* | *-*-pw32* | *-*-darwin*) 25609bd41f2cSmrg # These system don't have libm, or don't need it 25619bd41f2cSmrg ;; 25629bd41f2cSmrg*-ncr-sysv4.3*) 25639bd41f2cSmrg AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw") 25649bd41f2cSmrg AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm") 25659bd41f2cSmrg ;; 25669bd41f2cSmrg*) 25679bd41f2cSmrg AC_CHECK_LIB(m, cos, LIBM="-lm") 25689bd41f2cSmrg ;; 25699bd41f2cSmrgesac 25709bd41f2cSmrg])# AC_CHECK_LIBM 25719bd41f2cSmrg 25729bd41f2cSmrg 25739bd41f2cSmrg# AC_LIBLTDL_CONVENIENCE([DIRECTORY]) 25749bd41f2cSmrg# ----------------------------------- 25759bd41f2cSmrg# sets LIBLTDL to the link flags for the libltdl convenience library and 25769bd41f2cSmrg# LTDLINCL to the include flags for the libltdl header and adds 25779bd41f2cSmrg# --enable-ltdl-convenience to the configure arguments. Note that 25789bd41f2cSmrg# AC_CONFIG_SUBDIRS is not called here. If DIRECTORY is not provided, 25799bd41f2cSmrg# it is assumed to be `libltdl'. LIBLTDL will be prefixed with 25809bd41f2cSmrg# '${top_builddir}/' and LTDLINCL will be prefixed with '${top_srcdir}/' 25819bd41f2cSmrg# (note the single quotes!). If your package is not flat and you're not 25829bd41f2cSmrg# using automake, define top_builddir and top_srcdir appropriately in 25839bd41f2cSmrg# the Makefiles. 25849bd41f2cSmrgAC_DEFUN([AC_LIBLTDL_CONVENIENCE], 25859bd41f2cSmrg[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl 25869bd41f2cSmrg case $enable_ltdl_convenience in 25879bd41f2cSmrg no) AC_MSG_ERROR([this package needs a convenience libltdl]) ;; 25889bd41f2cSmrg "") enable_ltdl_convenience=yes 25899bd41f2cSmrg ac_configure_args="$ac_configure_args --enable-ltdl-convenience" ;; 25909bd41f2cSmrg esac 25919bd41f2cSmrg LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdlc.la 25929bd41f2cSmrg LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl']) 25939bd41f2cSmrg # For backwards non-gettext consistent compatibility... 25949bd41f2cSmrg INCLTDL="$LTDLINCL" 25959bd41f2cSmrg])# AC_LIBLTDL_CONVENIENCE 25969bd41f2cSmrg 25979bd41f2cSmrg 25989bd41f2cSmrg# AC_LIBLTDL_INSTALLABLE([DIRECTORY]) 25999bd41f2cSmrg# ----------------------------------- 26009bd41f2cSmrg# sets LIBLTDL to the link flags for the libltdl installable library and 26019bd41f2cSmrg# LTDLINCL to the include flags for the libltdl header and adds 26029bd41f2cSmrg# --enable-ltdl-install to the configure arguments. Note that 26039bd41f2cSmrg# AC_CONFIG_SUBDIRS is not called here. If DIRECTORY is not provided, 26049bd41f2cSmrg# and an installed libltdl is not found, it is assumed to be `libltdl'. 26059bd41f2cSmrg# LIBLTDL will be prefixed with '${top_builddir}/'# and LTDLINCL with 26069bd41f2cSmrg# '${top_srcdir}/' (note the single quotes!). If your package is not 26079bd41f2cSmrg# flat and you're not using automake, define top_builddir and top_srcdir 26089bd41f2cSmrg# appropriately in the Makefiles. 26099bd41f2cSmrg# In the future, this macro may have to be called after AC_PROG_LIBTOOL. 26109bd41f2cSmrgAC_DEFUN([AC_LIBLTDL_INSTALLABLE], 26119bd41f2cSmrg[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl 26129bd41f2cSmrg AC_CHECK_LIB(ltdl, lt_dlinit, 26139bd41f2cSmrg [test x"$enable_ltdl_install" != xyes && enable_ltdl_install=no], 26149bd41f2cSmrg [if test x"$enable_ltdl_install" = xno; then 26159bd41f2cSmrg AC_MSG_WARN([libltdl not installed, but installation disabled]) 26169bd41f2cSmrg else 26179bd41f2cSmrg enable_ltdl_install=yes 26189bd41f2cSmrg fi 26199bd41f2cSmrg ]) 26209bd41f2cSmrg if test x"$enable_ltdl_install" = x"yes"; then 26219bd41f2cSmrg ac_configure_args="$ac_configure_args --enable-ltdl-install" 26229bd41f2cSmrg LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdl.la 26239bd41f2cSmrg LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl']) 26249bd41f2cSmrg else 26259bd41f2cSmrg ac_configure_args="$ac_configure_args --enable-ltdl-install=no" 26269bd41f2cSmrg LIBLTDL="-lltdl" 26279bd41f2cSmrg LTDLINCL= 26289bd41f2cSmrg fi 26299bd41f2cSmrg # For backwards non-gettext consistent compatibility... 26309bd41f2cSmrg INCLTDL="$LTDLINCL" 26319bd41f2cSmrg])# AC_LIBLTDL_INSTALLABLE 26329bd41f2cSmrg 26339bd41f2cSmrg 26349bd41f2cSmrg# AC_LIBTOOL_CXX 26359bd41f2cSmrg# -------------- 26369bd41f2cSmrg# enable support for C++ libraries 26379bd41f2cSmrgAC_DEFUN([AC_LIBTOOL_CXX], 26389bd41f2cSmrg[AC_REQUIRE([_LT_AC_LANG_CXX]) 26399bd41f2cSmrg])# AC_LIBTOOL_CXX 26409bd41f2cSmrg 26419bd41f2cSmrg 26429bd41f2cSmrg# _LT_AC_LANG_CXX 26439bd41f2cSmrg# --------------- 26449bd41f2cSmrgAC_DEFUN([_LT_AC_LANG_CXX], 26459bd41f2cSmrg[AC_REQUIRE([AC_PROG_CXX]) 26469bd41f2cSmrgAC_REQUIRE([_LT_AC_PROG_CXXCPP]) 26479bd41f2cSmrg_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}CXX]) 26489bd41f2cSmrg])# _LT_AC_LANG_CXX 26499bd41f2cSmrg 26509bd41f2cSmrg# _LT_AC_PROG_CXXCPP 26519bd41f2cSmrg# ------------------ 26529bd41f2cSmrgAC_DEFUN([_LT_AC_PROG_CXXCPP], 26539bd41f2cSmrg[ 26549bd41f2cSmrgAC_REQUIRE([AC_PROG_CXX]) 26559bd41f2cSmrgif test -n "$CXX" && ( test "X$CXX" != "Xno" && 26569bd41f2cSmrg ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || 26579bd41f2cSmrg (test "X$CXX" != "Xg++"))) ; then 26589bd41f2cSmrg AC_PROG_CXXCPP 26599bd41f2cSmrgfi 26609bd41f2cSmrg])# _LT_AC_PROG_CXXCPP 26619bd41f2cSmrg 26629bd41f2cSmrg# AC_LIBTOOL_F77 26639bd41f2cSmrg# -------------- 26649bd41f2cSmrg# enable support for Fortran 77 libraries 26659bd41f2cSmrgAC_DEFUN([AC_LIBTOOL_F77], 26669bd41f2cSmrg[AC_REQUIRE([_LT_AC_LANG_F77]) 26679bd41f2cSmrg])# AC_LIBTOOL_F77 26689bd41f2cSmrg 26699bd41f2cSmrg 26709bd41f2cSmrg# _LT_AC_LANG_F77 26719bd41f2cSmrg# --------------- 26729bd41f2cSmrgAC_DEFUN([_LT_AC_LANG_F77], 26739bd41f2cSmrg[AC_REQUIRE([AC_PROG_F77]) 26749bd41f2cSmrg_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}F77]) 26759bd41f2cSmrg])# _LT_AC_LANG_F77 26769bd41f2cSmrg 26779bd41f2cSmrg 26789bd41f2cSmrg# AC_LIBTOOL_GCJ 26799bd41f2cSmrg# -------------- 26809bd41f2cSmrg# enable support for GCJ libraries 26819bd41f2cSmrgAC_DEFUN([AC_LIBTOOL_GCJ], 26829bd41f2cSmrg[AC_REQUIRE([_LT_AC_LANG_GCJ]) 26839bd41f2cSmrg])# AC_LIBTOOL_GCJ 26849bd41f2cSmrg 26859bd41f2cSmrg 26869bd41f2cSmrg# _LT_AC_LANG_GCJ 26879bd41f2cSmrg# --------------- 26889bd41f2cSmrgAC_DEFUN([_LT_AC_LANG_GCJ], 26899bd41f2cSmrg[AC_PROVIDE_IFELSE([AC_PROG_GCJ],[], 26909bd41f2cSmrg [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],[], 26919bd41f2cSmrg [AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ],[], 26929bd41f2cSmrg [ifdef([AC_PROG_GCJ],[AC_REQUIRE([AC_PROG_GCJ])], 26939bd41f2cSmrg [ifdef([A][M_PROG_GCJ],[AC_REQUIRE([A][M_PROG_GCJ])], 26949bd41f2cSmrg [AC_REQUIRE([A][C_PROG_GCJ_OR_A][M_PROG_GCJ])])])])])]) 26959bd41f2cSmrg_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}GCJ]) 26969bd41f2cSmrg])# _LT_AC_LANG_GCJ 26979bd41f2cSmrg 26989bd41f2cSmrg 26999bd41f2cSmrg# AC_LIBTOOL_RC 27009bd41f2cSmrg# ------------- 27019bd41f2cSmrg# enable support for Windows resource files 27029bd41f2cSmrgAC_DEFUN([AC_LIBTOOL_RC], 27039bd41f2cSmrg[AC_REQUIRE([LT_AC_PROG_RC]) 27049bd41f2cSmrg_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}RC]) 27059bd41f2cSmrg])# AC_LIBTOOL_RC 27069bd41f2cSmrg 27079bd41f2cSmrg 27089bd41f2cSmrg# AC_LIBTOOL_LANG_C_CONFIG 27099bd41f2cSmrg# ------------------------ 27109bd41f2cSmrg# Ensure that the configuration vars for the C compiler are 27119bd41f2cSmrg# suitably defined. Those variables are subsequently used by 27129bd41f2cSmrg# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'. 27139bd41f2cSmrgAC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG], [_LT_AC_LANG_C_CONFIG]) 27149bd41f2cSmrgAC_DEFUN([_LT_AC_LANG_C_CONFIG], 27159bd41f2cSmrg[lt_save_CC="$CC" 27169bd41f2cSmrgAC_LANG_PUSH(C) 27179bd41f2cSmrg 27189bd41f2cSmrg# Source file extension for C test sources. 27199bd41f2cSmrgac_ext=c 27209bd41f2cSmrg 27219bd41f2cSmrg# Object file extension for compiled C test sources. 27229bd41f2cSmrgobjext=o 27239bd41f2cSmrg_LT_AC_TAGVAR(objext, $1)=$objext 27249bd41f2cSmrg 27259bd41f2cSmrg# Code to be used in simple compile tests 27269bd41f2cSmrglt_simple_compile_test_code="int some_variable = 0;" 27279bd41f2cSmrg 27289bd41f2cSmrg# Code to be used in simple link tests 27299bd41f2cSmrglt_simple_link_test_code='int main(){return(0);}' 27309bd41f2cSmrg 27319bd41f2cSmrg_LT_AC_SYS_COMPILER 27329bd41f2cSmrg 27339bd41f2cSmrg# save warnings/boilerplate of simple test code 27349bd41f2cSmrg_LT_COMPILER_BOILERPLATE 27359bd41f2cSmrg_LT_LINKER_BOILERPLATE 27369bd41f2cSmrg 27379bd41f2cSmrgAC_LIBTOOL_PROG_COMPILER_NO_RTTI($1) 27389bd41f2cSmrgAC_LIBTOOL_PROG_COMPILER_PIC($1) 27399bd41f2cSmrgAC_LIBTOOL_PROG_CC_C_O($1) 27409bd41f2cSmrgAC_LIBTOOL_SYS_HARD_LINK_LOCKS($1) 27419bd41f2cSmrgAC_LIBTOOL_PROG_LD_SHLIBS($1) 27429bd41f2cSmrgAC_LIBTOOL_SYS_DYNAMIC_LINKER($1) 27439bd41f2cSmrgAC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1) 27449bd41f2cSmrgAC_LIBTOOL_SYS_LIB_STRIP 27459bd41f2cSmrgAC_LIBTOOL_DLOPEN_SELF 27469bd41f2cSmrg 27479bd41f2cSmrg# Report which library types will actually be built 27489bd41f2cSmrgAC_MSG_CHECKING([if libtool supports shared libraries]) 27499bd41f2cSmrgAC_MSG_RESULT([$can_build_shared]) 27509bd41f2cSmrg 27519bd41f2cSmrgAC_MSG_CHECKING([whether to build shared libraries]) 27529bd41f2cSmrgtest "$can_build_shared" = "no" && enable_shared=no 27539bd41f2cSmrg 27549bd41f2cSmrg# On AIX, shared libraries and static libraries use the same namespace, and 27559bd41f2cSmrg# are all built from PIC. 27569bd41f2cSmrgcase $host_os in 27579bd41f2cSmrgaix3*) 27589bd41f2cSmrg test "$enable_shared" = yes && enable_static=no 27599bd41f2cSmrg if test -n "$RANLIB"; then 27609bd41f2cSmrg archive_cmds="$archive_cmds~\$RANLIB \$lib" 27619bd41f2cSmrg postinstall_cmds='$RANLIB $lib' 27629bd41f2cSmrg fi 27639bd41f2cSmrg ;; 27649bd41f2cSmrg 27659bd41f2cSmrgaix4* | aix5*) 27669bd41f2cSmrg if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then 27679bd41f2cSmrg test "$enable_shared" = yes && enable_static=no 27689bd41f2cSmrg fi 27699bd41f2cSmrg ;; 27709bd41f2cSmrgesac 27719bd41f2cSmrgAC_MSG_RESULT([$enable_shared]) 27729bd41f2cSmrg 27739bd41f2cSmrgAC_MSG_CHECKING([whether to build static libraries]) 27749bd41f2cSmrg# Make sure either enable_shared or enable_static is yes. 27759bd41f2cSmrgtest "$enable_shared" = yes || enable_static=yes 27769bd41f2cSmrgAC_MSG_RESULT([$enable_static]) 27779bd41f2cSmrg 27789bd41f2cSmrgAC_LIBTOOL_CONFIG($1) 27799bd41f2cSmrg 27809bd41f2cSmrgAC_LANG_POP 27819bd41f2cSmrgCC="$lt_save_CC" 27829bd41f2cSmrg])# AC_LIBTOOL_LANG_C_CONFIG 27839bd41f2cSmrg 27849bd41f2cSmrg 27859bd41f2cSmrg# AC_LIBTOOL_LANG_CXX_CONFIG 27869bd41f2cSmrg# -------------------------- 27879bd41f2cSmrg# Ensure that the configuration vars for the C compiler are 27889bd41f2cSmrg# suitably defined. Those variables are subsequently used by 27899bd41f2cSmrg# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'. 27909bd41f2cSmrgAC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG], [_LT_AC_LANG_CXX_CONFIG(CXX)]) 27919bd41f2cSmrgAC_DEFUN([_LT_AC_LANG_CXX_CONFIG], 27929bd41f2cSmrg[AC_LANG_PUSH(C++) 27939bd41f2cSmrgAC_REQUIRE([AC_PROG_CXX]) 27949bd41f2cSmrgAC_REQUIRE([_LT_AC_PROG_CXXCPP]) 27959bd41f2cSmrg 27969bd41f2cSmrg_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no 27979bd41f2cSmrg_LT_AC_TAGVAR(allow_undefined_flag, $1)= 27989bd41f2cSmrg_LT_AC_TAGVAR(always_export_symbols, $1)=no 27999bd41f2cSmrg_LT_AC_TAGVAR(archive_expsym_cmds, $1)= 28009bd41f2cSmrg_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)= 28019bd41f2cSmrg_LT_AC_TAGVAR(hardcode_direct, $1)=no 28029bd41f2cSmrg_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)= 28039bd41f2cSmrg_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= 28049bd41f2cSmrg_LT_AC_TAGVAR(hardcode_libdir_separator, $1)= 28059bd41f2cSmrg_LT_AC_TAGVAR(hardcode_minus_L, $1)=no 28069bd41f2cSmrg_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported 28079bd41f2cSmrg_LT_AC_TAGVAR(hardcode_automatic, $1)=no 28089bd41f2cSmrg_LT_AC_TAGVAR(module_cmds, $1)= 28099bd41f2cSmrg_LT_AC_TAGVAR(module_expsym_cmds, $1)= 28109bd41f2cSmrg_LT_AC_TAGVAR(link_all_deplibs, $1)=unknown 28119bd41f2cSmrg_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 28129bd41f2cSmrg_LT_AC_TAGVAR(no_undefined_flag, $1)= 28139bd41f2cSmrg_LT_AC_TAGVAR(whole_archive_flag_spec, $1)= 28149bd41f2cSmrg_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no 28159bd41f2cSmrg 28169bd41f2cSmrg# Dependencies to place before and after the object being linked: 28179bd41f2cSmrg_LT_AC_TAGVAR(predep_objects, $1)= 28189bd41f2cSmrg_LT_AC_TAGVAR(postdep_objects, $1)= 28199bd41f2cSmrg_LT_AC_TAGVAR(predeps, $1)= 28209bd41f2cSmrg_LT_AC_TAGVAR(postdeps, $1)= 28219bd41f2cSmrg_LT_AC_TAGVAR(compiler_lib_search_path, $1)= 28229bd41f2cSmrg 28239bd41f2cSmrg# Source file extension for C++ test sources. 28249bd41f2cSmrgac_ext=cpp 28259bd41f2cSmrg 28269bd41f2cSmrg# Object file extension for compiled C++ test sources. 28279bd41f2cSmrgobjext=o 28289bd41f2cSmrg_LT_AC_TAGVAR(objext, $1)=$objext 28299bd41f2cSmrg 28309bd41f2cSmrg# Code to be used in simple compile tests 28319bd41f2cSmrglt_simple_compile_test_code="int some_variable = 0;" 28329bd41f2cSmrg 28339bd41f2cSmrg# Code to be used in simple link tests 28349bd41f2cSmrglt_simple_link_test_code='int main(int, char *[[]]) { return(0); }' 28359bd41f2cSmrg 28369bd41f2cSmrg# ltmain only uses $CC for tagged configurations so make sure $CC is set. 28379bd41f2cSmrg_LT_AC_SYS_COMPILER 28389bd41f2cSmrg 28399bd41f2cSmrg# save warnings/boilerplate of simple test code 28409bd41f2cSmrg_LT_COMPILER_BOILERPLATE 28419bd41f2cSmrg_LT_LINKER_BOILERPLATE 28429bd41f2cSmrg 28439bd41f2cSmrg# Allow CC to be a program name with arguments. 28449bd41f2cSmrglt_save_CC=$CC 28459bd41f2cSmrglt_save_LD=$LD 28469bd41f2cSmrglt_save_GCC=$GCC 28479bd41f2cSmrgGCC=$GXX 28489bd41f2cSmrglt_save_with_gnu_ld=$with_gnu_ld 28499bd41f2cSmrglt_save_path_LD=$lt_cv_path_LD 28509bd41f2cSmrgif test -n "${lt_cv_prog_gnu_ldcxx+set}"; then 28519bd41f2cSmrg lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx 28529bd41f2cSmrgelse 28539bd41f2cSmrg $as_unset lt_cv_prog_gnu_ld 28549bd41f2cSmrgfi 28559bd41f2cSmrgif test -n "${lt_cv_path_LDCXX+set}"; then 28569bd41f2cSmrg lt_cv_path_LD=$lt_cv_path_LDCXX 28579bd41f2cSmrgelse 28589bd41f2cSmrg $as_unset lt_cv_path_LD 28599bd41f2cSmrgfi 28609bd41f2cSmrgtest -z "${LDCXX+set}" || LD=$LDCXX 28619bd41f2cSmrgCC=${CXX-"c++"} 28629bd41f2cSmrgcompiler=$CC 28639bd41f2cSmrg_LT_AC_TAGVAR(compiler, $1)=$CC 28649bd41f2cSmrg_LT_CC_BASENAME([$compiler]) 28659bd41f2cSmrg 28669bd41f2cSmrg# We don't want -fno-exception wen compiling C++ code, so set the 28679bd41f2cSmrg# no_builtin_flag separately 28689bd41f2cSmrgif test "$GXX" = yes; then 28699bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' 28709bd41f2cSmrgelse 28719bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= 28729bd41f2cSmrgfi 28739bd41f2cSmrg 28749bd41f2cSmrgif test "$GXX" = yes; then 28759bd41f2cSmrg # Set up default GNU C++ configuration 28769bd41f2cSmrg 28779bd41f2cSmrg AC_PROG_LD 28789bd41f2cSmrg 28799bd41f2cSmrg # Check if GNU C++ uses GNU ld as the underlying linker, since the 28809bd41f2cSmrg # archiving commands below assume that GNU ld is being used. 28819bd41f2cSmrg if test "$with_gnu_ld" = yes; then 28829bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' 28839bd41f2cSmrg _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' 28849bd41f2cSmrg 28859bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir' 28869bd41f2cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 28879bd41f2cSmrg 28889bd41f2cSmrg # If archive_cmds runs LD, not CC, wlarc should be empty 28899bd41f2cSmrg # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to 28909bd41f2cSmrg # investigate it a little bit more. (MM) 28919bd41f2cSmrg wlarc='${wl}' 28929bd41f2cSmrg 28939bd41f2cSmrg # ancient GNU ld didn't support --whole-archive et. al. 28949bd41f2cSmrg if eval "`$CC -print-prog-name=ld` --help 2>&1" | \ 28959bd41f2cSmrg grep 'no-whole-archive' > /dev/null; then 28969bd41f2cSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' 28979bd41f2cSmrg else 28989bd41f2cSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)= 28999bd41f2cSmrg fi 29009bd41f2cSmrg else 29019bd41f2cSmrg with_gnu_ld=no 29029bd41f2cSmrg wlarc= 29039bd41f2cSmrg 29049bd41f2cSmrg # A generic and very simple default shared library creation 29059bd41f2cSmrg # command for GNU C++ for the case where it uses the native 29069bd41f2cSmrg # linker, instead of GNU ld. If possible, this setting should 29079bd41f2cSmrg # overridden to take advantage of the native linker features on 29089bd41f2cSmrg # the platform it is being used on. 29099bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' 29109bd41f2cSmrg fi 29119bd41f2cSmrg 29129bd41f2cSmrg # Commands to make compiler produce verbose output that lists 29139bd41f2cSmrg # what "hidden" libraries, object files and flags are used when 29149bd41f2cSmrg # linking a shared library. 29159bd41f2cSmrg output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"' 29169bd41f2cSmrg 29179bd41f2cSmrgelse 29189bd41f2cSmrg GXX=no 29199bd41f2cSmrg with_gnu_ld=no 29209bd41f2cSmrg wlarc= 29219bd41f2cSmrgfi 29229bd41f2cSmrg 29239bd41f2cSmrg# PORTME: fill in a description of your system's C++ link characteristics 29249bd41f2cSmrgAC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) 29259bd41f2cSmrg_LT_AC_TAGVAR(ld_shlibs, $1)=yes 29269bd41f2cSmrgcase $host_os in 29279bd41f2cSmrg aix3*) 29289bd41f2cSmrg # FIXME: insert proper C++ library support 29299bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 29309bd41f2cSmrg ;; 29319bd41f2cSmrg aix4* | aix5*) 29329bd41f2cSmrg if test "$host_cpu" = ia64; then 29339bd41f2cSmrg # On IA64, the linker does run time linking by default, so we don't 29349bd41f2cSmrg # have to do anything special. 29359bd41f2cSmrg aix_use_runtimelinking=no 29369bd41f2cSmrg exp_sym_flag='-Bexport' 29379bd41f2cSmrg no_entry_flag="" 29389bd41f2cSmrg else 29399bd41f2cSmrg aix_use_runtimelinking=no 29409bd41f2cSmrg 29419bd41f2cSmrg # Test if we are trying to use run time linking or normal 29429bd41f2cSmrg # AIX style linking. If -brtl is somewhere in LDFLAGS, we 29439bd41f2cSmrg # need to do runtime linking. 29449bd41f2cSmrg case $host_os in aix4.[[23]]|aix4.[[23]].*|aix5*) 29459bd41f2cSmrg for ld_flag in $LDFLAGS; do 29469bd41f2cSmrg case $ld_flag in 29479bd41f2cSmrg *-brtl*) 29489bd41f2cSmrg aix_use_runtimelinking=yes 29499bd41f2cSmrg break 29509bd41f2cSmrg ;; 29519bd41f2cSmrg esac 29529bd41f2cSmrg done 29539bd41f2cSmrg ;; 29549bd41f2cSmrg esac 29559bd41f2cSmrg 29569bd41f2cSmrg exp_sym_flag='-bexport' 29579bd41f2cSmrg no_entry_flag='-bnoentry' 29589bd41f2cSmrg fi 29599bd41f2cSmrg 29609bd41f2cSmrg # When large executables or shared objects are built, AIX ld can 29619bd41f2cSmrg # have problems creating the table of contents. If linking a library 29629bd41f2cSmrg # or program results in "error TOC overflow" add -mminimal-toc to 29639bd41f2cSmrg # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not 29649bd41f2cSmrg # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. 29659bd41f2cSmrg 29669bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='' 29679bd41f2cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=yes 29689bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':' 29699bd41f2cSmrg _LT_AC_TAGVAR(link_all_deplibs, $1)=yes 29709bd41f2cSmrg 29719bd41f2cSmrg if test "$GXX" = yes; then 29729bd41f2cSmrg case $host_os in aix4.[[012]]|aix4.[[012]].*) 29739bd41f2cSmrg # We only want to do this on AIX 4.2 and lower, the check 29749bd41f2cSmrg # below for broken collect2 doesn't work under 4.3+ 29759bd41f2cSmrg collect2name=`${CC} -print-prog-name=collect2` 29769bd41f2cSmrg if test -f "$collect2name" && \ 29779bd41f2cSmrg strings "$collect2name" | grep resolve_lib_name >/dev/null 29789bd41f2cSmrg then 29799bd41f2cSmrg # We have reworked collect2 29809bd41f2cSmrg : 29819bd41f2cSmrg else 29829bd41f2cSmrg # We have old collect2 29839bd41f2cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported 29849bd41f2cSmrg # It fails to find uninstalled libraries when the uninstalled 29859bd41f2cSmrg # path is not listed in the libpath. Setting hardcode_minus_L 29869bd41f2cSmrg # to unsupported forces relinking 29879bd41f2cSmrg _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes 29889bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 29899bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)= 29909bd41f2cSmrg fi 29919bd41f2cSmrg ;; 29929bd41f2cSmrg esac 29939bd41f2cSmrg shared_flag='-shared' 29949bd41f2cSmrg if test "$aix_use_runtimelinking" = yes; then 29959bd41f2cSmrg shared_flag="$shared_flag "'${wl}-G' 29969bd41f2cSmrg fi 29979bd41f2cSmrg else 29989bd41f2cSmrg # not using gcc 29999bd41f2cSmrg if test "$host_cpu" = ia64; then 30009bd41f2cSmrg # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release 30019bd41f2cSmrg # chokes on -Wl,-G. The following line is correct: 30029bd41f2cSmrg shared_flag='-G' 30039bd41f2cSmrg else 30049bd41f2cSmrg if test "$aix_use_runtimelinking" = yes; then 30059bd41f2cSmrg shared_flag='${wl}-G' 30069bd41f2cSmrg else 30079bd41f2cSmrg shared_flag='${wl}-bM:SRE' 30089bd41f2cSmrg fi 30099bd41f2cSmrg fi 30109bd41f2cSmrg fi 30119bd41f2cSmrg 30129bd41f2cSmrg # It seems that -bexpall does not export symbols beginning with 30139bd41f2cSmrg # underscore (_), so it is better to generate a list of symbols to export. 30149bd41f2cSmrg _LT_AC_TAGVAR(always_export_symbols, $1)=yes 30159bd41f2cSmrg if test "$aix_use_runtimelinking" = yes; then 30169bd41f2cSmrg # Warning - without using the other runtime loading flags (-brtl), 30179bd41f2cSmrg # -berok will link without error, but may produce a broken library. 30189bd41f2cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok' 30199bd41f2cSmrg # Determine the default libpath from the value encoded in an empty executable. 30209bd41f2cSmrg _LT_AC_SYS_LIBPATH_AIX 30219bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" 30229bd41f2cSmrg 30239bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" 30249bd41f2cSmrg else 30259bd41f2cSmrg if test "$host_cpu" = ia64; then 30269bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' 30279bd41f2cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs" 30289bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" 30299bd41f2cSmrg else 30309bd41f2cSmrg # Determine the default libpath from the value encoded in an empty executable. 30319bd41f2cSmrg _LT_AC_SYS_LIBPATH_AIX 30329bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" 30339bd41f2cSmrg # Warning - without using the other run time loading flags, 30349bd41f2cSmrg # -berok will link without error, but may produce a broken library. 30359bd41f2cSmrg _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' 30369bd41f2cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' 30379bd41f2cSmrg # Exported symbols can be pulled into shared objects from archives 30389bd41f2cSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='$convenience' 30399bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes 30409bd41f2cSmrg # This is similar to how AIX traditionally builds its shared libraries. 30419bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' 30429bd41f2cSmrg fi 30439bd41f2cSmrg fi 30449bd41f2cSmrg ;; 30459bd41f2cSmrg 30469bd41f2cSmrg beos*) 30479bd41f2cSmrg if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then 30489bd41f2cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported 30499bd41f2cSmrg # Joseph Beckenbach <jrb3@best.com> says some releases of gcc 30509bd41f2cSmrg # support --undefined. This deserves some investigation. FIXME 30519bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 30529bd41f2cSmrg else 30539bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 30549bd41f2cSmrg fi 30559bd41f2cSmrg ;; 30569bd41f2cSmrg 30579bd41f2cSmrg chorus*) 30589bd41f2cSmrg case $cc_basename in 30599bd41f2cSmrg *) 30609bd41f2cSmrg # FIXME: insert proper C++ library support 30619bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 30629bd41f2cSmrg ;; 30639bd41f2cSmrg esac 30649bd41f2cSmrg ;; 30659bd41f2cSmrg 30669bd41f2cSmrg cygwin* | mingw* | pw32*) 30679bd41f2cSmrg # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, 30689bd41f2cSmrg # as there is no search path for DLLs. 30699bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 30709bd41f2cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported 30719bd41f2cSmrg _LT_AC_TAGVAR(always_export_symbols, $1)=no 30729bd41f2cSmrg _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 30739bd41f2cSmrg 30749bd41f2cSmrg if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then 30759bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' 30769bd41f2cSmrg # If the export-symbols file already is a .def file (1st line 30779bd41f2cSmrg # is EXPORTS), use it as is; otherwise, prepend... 30789bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then 30799bd41f2cSmrg cp $export_symbols $output_objdir/$soname.def; 30809bd41f2cSmrg else 30819bd41f2cSmrg echo EXPORTS > $output_objdir/$soname.def; 30829bd41f2cSmrg cat $export_symbols >> $output_objdir/$soname.def; 30839bd41f2cSmrg fi~ 30849bd41f2cSmrg $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' 30859bd41f2cSmrg else 30869bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 30879bd41f2cSmrg fi 30889bd41f2cSmrg ;; 30899bd41f2cSmrg darwin* | rhapsody*) 30909bd41f2cSmrg case $host_os in 30919bd41f2cSmrg rhapsody* | darwin1.[[012]]) 30929bd41f2cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}suppress' 30939bd41f2cSmrg ;; 30949bd41f2cSmrg *) # Darwin 1.3 on 30959bd41f2cSmrg if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then 30969bd41f2cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' 30979bd41f2cSmrg else 30989bd41f2cSmrg case ${MACOSX_DEPLOYMENT_TARGET} in 30999bd41f2cSmrg 10.[[012]]) 31009bd41f2cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' 31019bd41f2cSmrg ;; 31029bd41f2cSmrg 10.*) 31039bd41f2cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}dynamic_lookup' 31049bd41f2cSmrg ;; 31059bd41f2cSmrg esac 31069bd41f2cSmrg fi 31079bd41f2cSmrg ;; 31089bd41f2cSmrg esac 31099bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no 31109bd41f2cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=no 31119bd41f2cSmrg _LT_AC_TAGVAR(hardcode_automatic, $1)=yes 31129bd41f2cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported 31139bd41f2cSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='' 31149bd41f2cSmrg _LT_AC_TAGVAR(link_all_deplibs, $1)=yes 31159bd41f2cSmrg 31169bd41f2cSmrg if test "$GXX" = yes ; then 31179bd41f2cSmrg lt_int_apple_cc_single_mod=no 31189bd41f2cSmrg output_verbose_link_cmd='echo' 31199bd41f2cSmrg if $CC -dumpspecs 2>&1 | $EGREP 'single_module' >/dev/null ; then 31209bd41f2cSmrg lt_int_apple_cc_single_mod=yes 31219bd41f2cSmrg fi 31229bd41f2cSmrg if test "X$lt_int_apple_cc_single_mod" = Xyes ; then 31239bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring' 31249bd41f2cSmrg else 31259bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -r -keep_private_externs -nostdlib -o ${lib}-master.o $libobjs~$CC -dynamiclib $allow_undefined_flag -o $lib ${lib}-master.o $deplibs $compiler_flags -install_name $rpath/$soname $verstring' 31269bd41f2cSmrg fi 31279bd41f2cSmrg _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' 31289bd41f2cSmrg # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds 31299bd41f2cSmrg if test "X$lt_int_apple_cc_single_mod" = Xyes ; then 31309bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' 31319bd41f2cSmrg else 31329bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -r -keep_private_externs -nostdlib -o ${lib}-master.o $libobjs~$CC -dynamiclib $allow_undefined_flag -o $lib ${lib}-master.o $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' 31339bd41f2cSmrg fi 31349bd41f2cSmrg _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' 31359bd41f2cSmrg else 31369bd41f2cSmrg case $cc_basename in 31379bd41f2cSmrg xlc*) 31389bd41f2cSmrg output_verbose_link_cmd='echo' 31399bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring' 31409bd41f2cSmrg _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' 31419bd41f2cSmrg # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds 31429bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' 31439bd41f2cSmrg _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' 31449bd41f2cSmrg ;; 31459bd41f2cSmrg *) 31469bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 31479bd41f2cSmrg ;; 31489bd41f2cSmrg esac 31499bd41f2cSmrg fi 31509bd41f2cSmrg ;; 31519bd41f2cSmrg 31529bd41f2cSmrg dgux*) 31539bd41f2cSmrg case $cc_basename in 31549bd41f2cSmrg ec++*) 31559bd41f2cSmrg # FIXME: insert proper C++ library support 31569bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 31579bd41f2cSmrg ;; 31589bd41f2cSmrg ghcx*) 31599bd41f2cSmrg # Green Hills C++ Compiler 31609bd41f2cSmrg # FIXME: insert proper C++ library support 31619bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 31629bd41f2cSmrg ;; 31639bd41f2cSmrg *) 31649bd41f2cSmrg # FIXME: insert proper C++ library support 31659bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 31669bd41f2cSmrg ;; 31679bd41f2cSmrg esac 31689bd41f2cSmrg ;; 31699bd41f2cSmrg freebsd[[12]]*) 31709bd41f2cSmrg # C++ shared libraries reported to be fairly broken before switch to ELF 31719bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 31729bd41f2cSmrg ;; 31739bd41f2cSmrg freebsd-elf*) 31749bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no 31759bd41f2cSmrg ;; 31769bd41f2cSmrg freebsd* | dragonfly*) 31779bd41f2cSmrg # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF 31789bd41f2cSmrg # conventions 31799bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=yes 31809bd41f2cSmrg ;; 31819bd41f2cSmrg gnu*) 31829bd41f2cSmrg ;; 31839bd41f2cSmrg hpux9*) 31849bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 31859bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 31869bd41f2cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 31879bd41f2cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=yes 31889bd41f2cSmrg _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, 31899bd41f2cSmrg # but as the default 31909bd41f2cSmrg # location of the library. 31919bd41f2cSmrg 31929bd41f2cSmrg case $cc_basename in 31939bd41f2cSmrg CC*) 31949bd41f2cSmrg # FIXME: insert proper C++ library support 31959bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 31969bd41f2cSmrg ;; 31979bd41f2cSmrg aCC*) 31989bd41f2cSmrg _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' 31999bd41f2cSmrg # Commands to make compiler produce verbose output that lists 32009bd41f2cSmrg # what "hidden" libraries, object files and flags are used when 32019bd41f2cSmrg # linking a shared library. 32029bd41f2cSmrg # 32039bd41f2cSmrg # There doesn't appear to be a way to prevent this compiler from 32049bd41f2cSmrg # explicitly linking system object files so we need to strip them 32059bd41f2cSmrg # from the output so that they don't get included in the library 32069bd41f2cSmrg # dependencies. 32079bd41f2cSmrg output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | grep "[[-]]L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' 32089bd41f2cSmrg ;; 32099bd41f2cSmrg *) 32109bd41f2cSmrg if test "$GXX" = yes; then 32119bd41f2cSmrg _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' 32129bd41f2cSmrg else 32139bd41f2cSmrg # FIXME: insert proper C++ library support 32149bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 32159bd41f2cSmrg fi 32169bd41f2cSmrg ;; 32179bd41f2cSmrg esac 32189bd41f2cSmrg ;; 32199bd41f2cSmrg hpux10*|hpux11*) 32209bd41f2cSmrg if test $with_gnu_ld = no; then 32219bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 32229bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 32239bd41f2cSmrg 32249bd41f2cSmrg case $host_cpu in 32259bd41f2cSmrg hppa*64*|ia64*) ;; 32269bd41f2cSmrg *) 32279bd41f2cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 32289bd41f2cSmrg ;; 32299bd41f2cSmrg esac 32309bd41f2cSmrg fi 32319bd41f2cSmrg case $host_cpu in 32329bd41f2cSmrg hppa*64*|ia64*) 32339bd41f2cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=no 32349bd41f2cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 32359bd41f2cSmrg ;; 32369bd41f2cSmrg *) 32379bd41f2cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=yes 32389bd41f2cSmrg _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, 32399bd41f2cSmrg # but as the default 32409bd41f2cSmrg # location of the library. 32419bd41f2cSmrg ;; 32429bd41f2cSmrg esac 32439bd41f2cSmrg 32449bd41f2cSmrg case $cc_basename in 32459bd41f2cSmrg CC*) 32469bd41f2cSmrg # FIXME: insert proper C++ library support 32479bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 32489bd41f2cSmrg ;; 32499bd41f2cSmrg aCC*) 32509bd41f2cSmrg case $host_cpu in 32519bd41f2cSmrg hppa*64*) 32529bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 32539bd41f2cSmrg ;; 32549bd41f2cSmrg ia64*) 32559bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 32569bd41f2cSmrg ;; 32579bd41f2cSmrg *) 32589bd41f2cSmrg _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' 32599bd41f2cSmrg ;; 32609bd41f2cSmrg esac 32619bd41f2cSmrg # Commands to make compiler produce verbose output that lists 32629bd41f2cSmrg # what "hidden" libraries, object files and flags are used when 32639bd41f2cSmrg # linking a shared library. 32649bd41f2cSmrg # 32659bd41f2cSmrg # There doesn't appear to be a way to prevent this compiler from 32669bd41f2cSmrg # explicitly linking system object files so we need to strip them 32679bd41f2cSmrg # from the output so that they don't get included in the library 32689bd41f2cSmrg # dependencies. 32699bd41f2cSmrg output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | grep "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' 32709bd41f2cSmrg ;; 32719bd41f2cSmrg *) 32729bd41f2cSmrg if test "$GXX" = yes; then 32739bd41f2cSmrg if test $with_gnu_ld = no; then 32749bd41f2cSmrg case $host_cpu in 32759bd41f2cSmrg hppa*64*) 32769bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 32779bd41f2cSmrg ;; 32789bd41f2cSmrg ia64*) 32799bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 32809bd41f2cSmrg ;; 32819bd41f2cSmrg *) 32829bd41f2cSmrg _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' 32839bd41f2cSmrg ;; 32849bd41f2cSmrg esac 32859bd41f2cSmrg fi 32869bd41f2cSmrg else 32879bd41f2cSmrg # FIXME: insert proper C++ library support 32889bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 32899bd41f2cSmrg fi 32909bd41f2cSmrg ;; 32919bd41f2cSmrg esac 32929bd41f2cSmrg ;; 32939bd41f2cSmrg interix[[3-9]]*) 32949bd41f2cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=no 32959bd41f2cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 32969bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 32979bd41f2cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 32989bd41f2cSmrg # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. 32999bd41f2cSmrg # Instead, shared libraries are loaded at an image base (0x10000000 by 33009bd41f2cSmrg # default) and relocated if they conflict, which is a slow very memory 33019bd41f2cSmrg # consuming and fragmenting process. To avoid this, we pick a random, 33029bd41f2cSmrg # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link 33039bd41f2cSmrg # time. Moving up from 0x10000000 also allows more sbrk(2) space. 33049bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' 33059bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' 33069bd41f2cSmrg ;; 33079bd41f2cSmrg irix5* | irix6*) 33089bd41f2cSmrg case $cc_basename in 33099bd41f2cSmrg CC*) 33109bd41f2cSmrg # SGI C++ 33119bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' 33129bd41f2cSmrg 33139bd41f2cSmrg # Archives containing C++ object files must be created using 33149bd41f2cSmrg # "CC -ar", where "CC" is the IRIX C++ compiler. This is 33159bd41f2cSmrg # necessary to make sure instantiated templates are included 33169bd41f2cSmrg # in the archive. 33179bd41f2cSmrg _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs' 33189bd41f2cSmrg ;; 33199bd41f2cSmrg *) 33209bd41f2cSmrg if test "$GXX" = yes; then 33219bd41f2cSmrg if test "$with_gnu_ld" = no; then 33229bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' 33239bd41f2cSmrg else 33249bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` -o $lib' 33259bd41f2cSmrg fi 33269bd41f2cSmrg fi 33279bd41f2cSmrg _LT_AC_TAGVAR(link_all_deplibs, $1)=yes 33289bd41f2cSmrg ;; 33299bd41f2cSmrg esac 33309bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 33319bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 33329bd41f2cSmrg ;; 33339bd41f2cSmrg linux* | k*bsd*-gnu) 33349bd41f2cSmrg case $cc_basename in 33359bd41f2cSmrg KCC*) 33369bd41f2cSmrg # Kuck and Associates, Inc. (KAI) C++ Compiler 33379bd41f2cSmrg 33389bd41f2cSmrg # KCC will only create a shared library if the output file 33399bd41f2cSmrg # ends with ".so" (or ".sl" for HP-UX), so rename the library 33409bd41f2cSmrg # to its proper name (with version) after linking. 33419bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' 33429bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib ${wl}-retain-symbols-file,$export_symbols; mv \$templib $lib' 33439bd41f2cSmrg # Commands to make compiler produce verbose output that lists 33449bd41f2cSmrg # what "hidden" libraries, object files and flags are used when 33459bd41f2cSmrg # linking a shared library. 33469bd41f2cSmrg # 33479bd41f2cSmrg # There doesn't appear to be a way to prevent this compiler from 33489bd41f2cSmrg # explicitly linking system object files so we need to strip them 33499bd41f2cSmrg # from the output so that they don't get included in the library 33509bd41f2cSmrg # dependencies. 33519bd41f2cSmrg output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | grep "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' 33529bd41f2cSmrg 33539bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath,$libdir' 33549bd41f2cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 33559bd41f2cSmrg 33569bd41f2cSmrg # Archives containing C++ object files must be created using 33579bd41f2cSmrg # "CC -Bstatic", where "CC" is the KAI C++ compiler. 33589bd41f2cSmrg _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' 33599bd41f2cSmrg ;; 33609bd41f2cSmrg icpc*) 33619bd41f2cSmrg # Intel C++ 33629bd41f2cSmrg with_gnu_ld=yes 33639bd41f2cSmrg # version 8.0 and above of icpc choke on multiply defined symbols 33649bd41f2cSmrg # if we add $predep_objects and $postdep_objects, however 7.1 and 33659bd41f2cSmrg # earlier do not add the objects themselves. 33669bd41f2cSmrg case `$CC -V 2>&1` in 33679bd41f2cSmrg *"Version 7."*) 33689bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' 33699bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' 33709bd41f2cSmrg ;; 33719bd41f2cSmrg *) # Version 8.0 or newer 33729bd41f2cSmrg tmp_idyn= 33739bd41f2cSmrg case $host_cpu in 33749bd41f2cSmrg ia64*) tmp_idyn=' -i_dynamic';; 33759bd41f2cSmrg esac 33769bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 33779bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' 33789bd41f2cSmrg ;; 33799bd41f2cSmrg esac 33809bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no 33819bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 33829bd41f2cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 33839bd41f2cSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' 33849bd41f2cSmrg ;; 33859bd41f2cSmrg pgCC*) 33869bd41f2cSmrg # Portland Group C++ compiler 33879bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' 33889bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib' 33899bd41f2cSmrg 33909bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir' 33919bd41f2cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 33929bd41f2cSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' 33939bd41f2cSmrg ;; 33949bd41f2cSmrg cxx*) 33959bd41f2cSmrg # Compaq C++ 33969bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' 33979bd41f2cSmrg _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' 33989bd41f2cSmrg 33999bd41f2cSmrg runpath_var=LD_RUN_PATH 34009bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' 34019bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 34029bd41f2cSmrg 34039bd41f2cSmrg # Commands to make compiler produce verbose output that lists 34049bd41f2cSmrg # what "hidden" libraries, object files and flags are used when 34059bd41f2cSmrg # linking a shared library. 34069bd41f2cSmrg # 34079bd41f2cSmrg # There doesn't appear to be a way to prevent this compiler from 34089bd41f2cSmrg # explicitly linking system object files so we need to strip them 34099bd41f2cSmrg # from the output so that they don't get included in the library 34109bd41f2cSmrg # dependencies. 34119bd41f2cSmrg 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' 34129bd41f2cSmrg ;; 34139bd41f2cSmrg *) 34149bd41f2cSmrg case `$CC -V 2>&1 | sed 5q` in 34159bd41f2cSmrg *Sun\ C*) 34169bd41f2cSmrg # Sun C++ 5.9 34179bd41f2cSmrg _LT_AC_TAGVAR(no_undefined_flag, $1)=' -zdefs' 34189bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 34199bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols' 34209bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 34219bd41f2cSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' 34229bd41f2cSmrg 34239bd41f2cSmrg # Not sure whether something based on 34249bd41f2cSmrg # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 34259bd41f2cSmrg # would be better. 34269bd41f2cSmrg output_verbose_link_cmd='echo' 34279bd41f2cSmrg 34289bd41f2cSmrg # Archives containing C++ object files must be created using 34299bd41f2cSmrg # "CC -xar", where "CC" is the Sun C++ compiler. This is 34309bd41f2cSmrg # necessary to make sure instantiated templates are included 34319bd41f2cSmrg # in the archive. 34329bd41f2cSmrg _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' 34339bd41f2cSmrg ;; 34349bd41f2cSmrg esac 34359bd41f2cSmrg ;; 34369bd41f2cSmrg esac 34379bd41f2cSmrg ;; 34389bd41f2cSmrg lynxos*) 34399bd41f2cSmrg # FIXME: insert proper C++ library support 34409bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 34419bd41f2cSmrg ;; 34429bd41f2cSmrg m88k*) 34439bd41f2cSmrg # FIXME: insert proper C++ library support 34449bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 34459bd41f2cSmrg ;; 34469bd41f2cSmrg mvs*) 34479bd41f2cSmrg case $cc_basename in 34489bd41f2cSmrg cxx*) 34499bd41f2cSmrg # FIXME: insert proper C++ library support 34509bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 34519bd41f2cSmrg ;; 34529bd41f2cSmrg *) 34539bd41f2cSmrg # FIXME: insert proper C++ library support 34549bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 34559bd41f2cSmrg ;; 34569bd41f2cSmrg esac 34579bd41f2cSmrg ;; 34589bd41f2cSmrg netbsd*) 34599bd41f2cSmrg if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then 34609bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' 34619bd41f2cSmrg wlarc= 34629bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 34639bd41f2cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=yes 34649bd41f2cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 34659bd41f2cSmrg fi 34669bd41f2cSmrg # Workaround some broken pre-1.5 toolchains 34679bd41f2cSmrg output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' 34689bd41f2cSmrg ;; 34699bd41f2cSmrg openbsd2*) 34709bd41f2cSmrg # C++ shared libraries are fairly broken 34719bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 34729bd41f2cSmrg ;; 34739bd41f2cSmrg openbsd*) 34749bd41f2cSmrg if test -f /usr/libexec/ld.so; then 34759bd41f2cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=yes 34769bd41f2cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 34779bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' 34789bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 34799bd41f2cSmrg if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then 34809bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib' 34819bd41f2cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 34829bd41f2cSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' 34839bd41f2cSmrg fi 34849bd41f2cSmrg output_verbose_link_cmd='echo' 34859bd41f2cSmrg else 34869bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 34879bd41f2cSmrg fi 34889bd41f2cSmrg ;; 34899bd41f2cSmrg osf3*) 34909bd41f2cSmrg case $cc_basename in 34919bd41f2cSmrg KCC*) 34929bd41f2cSmrg # Kuck and Associates, Inc. (KAI) C++ Compiler 34939bd41f2cSmrg 34949bd41f2cSmrg # KCC will only create a shared library if the output file 34959bd41f2cSmrg # ends with ".so" (or ".sl" for HP-UX), so rename the library 34969bd41f2cSmrg # to its proper name (with version) after linking. 34979bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' 34989bd41f2cSmrg 34999bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 35009bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 35019bd41f2cSmrg 35029bd41f2cSmrg # Archives containing C++ object files must be created using 35039bd41f2cSmrg # "CC -Bstatic", where "CC" is the KAI C++ compiler. 35049bd41f2cSmrg _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' 35059bd41f2cSmrg 35069bd41f2cSmrg ;; 35079bd41f2cSmrg RCC*) 35089bd41f2cSmrg # Rational C++ 2.4.1 35099bd41f2cSmrg # FIXME: insert proper C++ library support 35109bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 35119bd41f2cSmrg ;; 35129bd41f2cSmrg cxx*) 35139bd41f2cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' 35149bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && echo ${wl}-set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' 35159bd41f2cSmrg 35169bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 35179bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 35189bd41f2cSmrg 35199bd41f2cSmrg # Commands to make compiler produce verbose output that lists 35209bd41f2cSmrg # what "hidden" libraries, object files and flags are used when 35219bd41f2cSmrg # linking a shared library. 35229bd41f2cSmrg # 35239bd41f2cSmrg # There doesn't appear to be a way to prevent this compiler from 35249bd41f2cSmrg # explicitly linking system object files so we need to strip them 35259bd41f2cSmrg # from the output so that they don't get included in the library 35269bd41f2cSmrg # dependencies. 35279bd41f2cSmrg 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' 35289bd41f2cSmrg ;; 35299bd41f2cSmrg *) 35309bd41f2cSmrg if test "$GXX" = yes && test "$with_gnu_ld" = no; then 35319bd41f2cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' 35329bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' 35339bd41f2cSmrg 35349bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 35359bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 35369bd41f2cSmrg 35379bd41f2cSmrg # Commands to make compiler produce verbose output that lists 35389bd41f2cSmrg # what "hidden" libraries, object files and flags are used when 35399bd41f2cSmrg # linking a shared library. 35409bd41f2cSmrg output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"' 35419bd41f2cSmrg 35429bd41f2cSmrg else 35439bd41f2cSmrg # FIXME: insert proper C++ library support 35449bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 35459bd41f2cSmrg fi 35469bd41f2cSmrg ;; 35479bd41f2cSmrg esac 35489bd41f2cSmrg ;; 35499bd41f2cSmrg osf4* | osf5*) 35509bd41f2cSmrg case $cc_basename in 35519bd41f2cSmrg KCC*) 35529bd41f2cSmrg # Kuck and Associates, Inc. (KAI) C++ Compiler 35539bd41f2cSmrg 35549bd41f2cSmrg # KCC will only create a shared library if the output file 35559bd41f2cSmrg # ends with ".so" (or ".sl" for HP-UX), so rename the library 35569bd41f2cSmrg # to its proper name (with version) after linking. 35579bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' 35589bd41f2cSmrg 35599bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 35609bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 35619bd41f2cSmrg 35629bd41f2cSmrg # Archives containing C++ object files must be created using 35639bd41f2cSmrg # the KAI C++ compiler. 35649bd41f2cSmrg _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' 35659bd41f2cSmrg ;; 35669bd41f2cSmrg RCC*) 35679bd41f2cSmrg # Rational C++ 2.4.1 35689bd41f2cSmrg # FIXME: insert proper C++ library support 35699bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 35709bd41f2cSmrg ;; 35719bd41f2cSmrg cxx*) 35729bd41f2cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' 35739bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' 35749bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ 35759bd41f2cSmrg echo "-hidden">> $lib.exp~ 35769bd41f2cSmrg $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname -Wl,-input -Wl,$lib.exp `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~ 35779bd41f2cSmrg $rm $lib.exp' 35789bd41f2cSmrg 35799bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' 35809bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 35819bd41f2cSmrg 35829bd41f2cSmrg # Commands to make compiler produce verbose output that lists 35839bd41f2cSmrg # what "hidden" libraries, object files and flags are used when 35849bd41f2cSmrg # linking a shared library. 35859bd41f2cSmrg # 35869bd41f2cSmrg # There doesn't appear to be a way to prevent this compiler from 35879bd41f2cSmrg # explicitly linking system object files so we need to strip them 35889bd41f2cSmrg # from the output so that they don't get included in the library 35899bd41f2cSmrg # dependencies. 35909bd41f2cSmrg 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' 35919bd41f2cSmrg ;; 35929bd41f2cSmrg *) 35939bd41f2cSmrg if test "$GXX" = yes && test "$with_gnu_ld" = no; then 35949bd41f2cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' 35959bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' 35969bd41f2cSmrg 35979bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 35989bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 35999bd41f2cSmrg 36009bd41f2cSmrg # Commands to make compiler produce verbose output that lists 36019bd41f2cSmrg # what "hidden" libraries, object files and flags are used when 36029bd41f2cSmrg # linking a shared library. 36039bd41f2cSmrg output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"' 36049bd41f2cSmrg 36059bd41f2cSmrg else 36069bd41f2cSmrg # FIXME: insert proper C++ library support 36079bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 36089bd41f2cSmrg fi 36099bd41f2cSmrg ;; 36109bd41f2cSmrg esac 36119bd41f2cSmrg ;; 36129bd41f2cSmrg psos*) 36139bd41f2cSmrg # FIXME: insert proper C++ library support 36149bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 36159bd41f2cSmrg ;; 36169bd41f2cSmrg sunos4*) 36179bd41f2cSmrg case $cc_basename in 36189bd41f2cSmrg CC*) 36199bd41f2cSmrg # Sun C++ 4.x 36209bd41f2cSmrg # FIXME: insert proper C++ library support 36219bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 36229bd41f2cSmrg ;; 36239bd41f2cSmrg lcc*) 36249bd41f2cSmrg # Lucid 36259bd41f2cSmrg # FIXME: insert proper C++ library support 36269bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 36279bd41f2cSmrg ;; 36289bd41f2cSmrg *) 36299bd41f2cSmrg # FIXME: insert proper C++ library support 36309bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 36319bd41f2cSmrg ;; 36329bd41f2cSmrg esac 36339bd41f2cSmrg ;; 36349bd41f2cSmrg solaris*) 36359bd41f2cSmrg case $cc_basename in 36369bd41f2cSmrg CC*) 36379bd41f2cSmrg # Sun C++ 4.2, 5.x and Centerline C++ 36389bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds_need_lc,$1)=yes 36399bd41f2cSmrg _LT_AC_TAGVAR(no_undefined_flag, $1)=' -zdefs' 36409bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 36419bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ 36429bd41f2cSmrg $CC -G${allow_undefined_flag} ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp' 36439bd41f2cSmrg 36449bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 36459bd41f2cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 36469bd41f2cSmrg case $host_os in 36479bd41f2cSmrg solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; 36489bd41f2cSmrg *) 36499bd41f2cSmrg # The compiler driver will combine and reorder linker options, 36509bd41f2cSmrg # but understands `-z linker_flag'. 36519bd41f2cSmrg # Supported since Solaris 2.6 (maybe 2.5.1?) 36529bd41f2cSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' 36539bd41f2cSmrg ;; 36549bd41f2cSmrg esac 36559bd41f2cSmrg _LT_AC_TAGVAR(link_all_deplibs, $1)=yes 36569bd41f2cSmrg 36579bd41f2cSmrg output_verbose_link_cmd='echo' 36589bd41f2cSmrg 36599bd41f2cSmrg # Archives containing C++ object files must be created using 36609bd41f2cSmrg # "CC -xar", where "CC" is the Sun C++ compiler. This is 36619bd41f2cSmrg # necessary to make sure instantiated templates are included 36629bd41f2cSmrg # in the archive. 36639bd41f2cSmrg _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' 36649bd41f2cSmrg ;; 36659bd41f2cSmrg gcx*) 36669bd41f2cSmrg # Green Hills C++ Compiler 36679bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' 36689bd41f2cSmrg 36699bd41f2cSmrg # The C++ compiler must be used to create the archive. 36709bd41f2cSmrg _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs' 36719bd41f2cSmrg ;; 36729bd41f2cSmrg *) 36739bd41f2cSmrg # GNU C++ compiler with Solaris linker 36749bd41f2cSmrg if test "$GXX" = yes && test "$with_gnu_ld" = no; then 36759bd41f2cSmrg _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs' 36769bd41f2cSmrg if $CC --version | grep -v '^2\.7' > /dev/null; then 36779bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' 36789bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ 36799bd41f2cSmrg $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp' 36809bd41f2cSmrg 36819bd41f2cSmrg # Commands to make compiler produce verbose output that lists 36829bd41f2cSmrg # what "hidden" libraries, object files and flags are used when 36839bd41f2cSmrg # linking a shared library. 36849bd41f2cSmrg output_verbose_link_cmd="$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\"" 36859bd41f2cSmrg else 36869bd41f2cSmrg # g++ 2.7 appears to require `-G' NOT `-shared' on this 36879bd41f2cSmrg # platform. 36889bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' 36899bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ 36909bd41f2cSmrg $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp' 36919bd41f2cSmrg 36929bd41f2cSmrg # Commands to make compiler produce verbose output that lists 36939bd41f2cSmrg # what "hidden" libraries, object files and flags are used when 36949bd41f2cSmrg # linking a shared library. 36959bd41f2cSmrg output_verbose_link_cmd="$CC -G $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\"" 36969bd41f2cSmrg fi 36979bd41f2cSmrg 36989bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir' 36999bd41f2cSmrg case $host_os in 37009bd41f2cSmrg solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; 37019bd41f2cSmrg *) 37029bd41f2cSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' 37039bd41f2cSmrg ;; 37049bd41f2cSmrg esac 37059bd41f2cSmrg fi 37069bd41f2cSmrg ;; 37079bd41f2cSmrg esac 37089bd41f2cSmrg ;; 37099bd41f2cSmrg sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) 37109bd41f2cSmrg _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' 37119bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no 37129bd41f2cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 37139bd41f2cSmrg runpath_var='LD_RUN_PATH' 37149bd41f2cSmrg 37159bd41f2cSmrg case $cc_basename in 37169bd41f2cSmrg CC*) 37179bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 37189bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 37199bd41f2cSmrg ;; 37209bd41f2cSmrg *) 37219bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 37229bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 37239bd41f2cSmrg ;; 37249bd41f2cSmrg esac 37259bd41f2cSmrg ;; 37269bd41f2cSmrg sysv5* | sco3.2v5* | sco5v6*) 37279bd41f2cSmrg # Note: We can NOT use -z defs as we might desire, because we do not 37289bd41f2cSmrg # link with -lc, and that would cause any symbols used from libc to 37299bd41f2cSmrg # always be unresolved, which means just about no library would 37309bd41f2cSmrg # ever link correctly. If we're not using GNU ld we use -z text 37319bd41f2cSmrg # though, which does catch some bad symbols but isn't as heavy-handed 37329bd41f2cSmrg # as -z defs. 37339bd41f2cSmrg # For security reasons, it is highly recommended that you always 37349bd41f2cSmrg # use absolute paths for naming shared libraries, and exclude the 37359bd41f2cSmrg # DT_RUNPATH tag from executables and libraries. But doing so 37369bd41f2cSmrg # requires that you compile everything twice, which is a pain. 37379bd41f2cSmrg # So that behaviour is only enabled if SCOABSPATH is set to a 37389bd41f2cSmrg # non-empty value in the environment. Most likely only useful for 37399bd41f2cSmrg # creating official distributions of packages. 37409bd41f2cSmrg # This is a hack until libtool officially supports absolute path 37419bd41f2cSmrg # names for shared libraries. 37429bd41f2cSmrg _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' 37439bd41f2cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs' 37449bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no 37459bd41f2cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 37469bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`' 37479bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':' 37489bd41f2cSmrg _LT_AC_TAGVAR(link_all_deplibs, $1)=yes 37499bd41f2cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' 37509bd41f2cSmrg runpath_var='LD_RUN_PATH' 37519bd41f2cSmrg 37529bd41f2cSmrg case $cc_basename in 37539bd41f2cSmrg CC*) 37549bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' 37559bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' 37569bd41f2cSmrg ;; 37579bd41f2cSmrg *) 37589bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' 37599bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' 37609bd41f2cSmrg ;; 37619bd41f2cSmrg esac 37629bd41f2cSmrg ;; 37639bd41f2cSmrg tandem*) 37649bd41f2cSmrg case $cc_basename in 37659bd41f2cSmrg NCC*) 37669bd41f2cSmrg # NonStop-UX NCC 3.20 37679bd41f2cSmrg # FIXME: insert proper C++ library support 37689bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 37699bd41f2cSmrg ;; 37709bd41f2cSmrg *) 37719bd41f2cSmrg # FIXME: insert proper C++ library support 37729bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 37739bd41f2cSmrg ;; 37749bd41f2cSmrg esac 37759bd41f2cSmrg ;; 37769bd41f2cSmrg vxworks*) 37779bd41f2cSmrg # FIXME: insert proper C++ library support 37789bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 37799bd41f2cSmrg ;; 37809bd41f2cSmrg *) 37819bd41f2cSmrg # FIXME: insert proper C++ library support 37829bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 37839bd41f2cSmrg ;; 37849bd41f2cSmrgesac 37859bd41f2cSmrgAC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)]) 37869bd41f2cSmrgtest "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no 37879bd41f2cSmrg 37889bd41f2cSmrg_LT_AC_TAGVAR(GCC, $1)="$GXX" 37899bd41f2cSmrg_LT_AC_TAGVAR(LD, $1)="$LD" 37909bd41f2cSmrg 37919bd41f2cSmrgAC_LIBTOOL_POSTDEP_PREDEP($1) 37929bd41f2cSmrgAC_LIBTOOL_PROG_COMPILER_PIC($1) 37939bd41f2cSmrgAC_LIBTOOL_PROG_CC_C_O($1) 37949bd41f2cSmrgAC_LIBTOOL_SYS_HARD_LINK_LOCKS($1) 37959bd41f2cSmrgAC_LIBTOOL_PROG_LD_SHLIBS($1) 37969bd41f2cSmrgAC_LIBTOOL_SYS_DYNAMIC_LINKER($1) 37979bd41f2cSmrgAC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1) 37989bd41f2cSmrg 37999bd41f2cSmrgAC_LIBTOOL_CONFIG($1) 38009bd41f2cSmrg 38019bd41f2cSmrgAC_LANG_POP 38029bd41f2cSmrgCC=$lt_save_CC 38039bd41f2cSmrgLDCXX=$LD 38049bd41f2cSmrgLD=$lt_save_LD 38059bd41f2cSmrgGCC=$lt_save_GCC 38069bd41f2cSmrgwith_gnu_ldcxx=$with_gnu_ld 38079bd41f2cSmrgwith_gnu_ld=$lt_save_with_gnu_ld 38089bd41f2cSmrglt_cv_path_LDCXX=$lt_cv_path_LD 38099bd41f2cSmrglt_cv_path_LD=$lt_save_path_LD 38109bd41f2cSmrglt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld 38119bd41f2cSmrglt_cv_prog_gnu_ld=$lt_save_with_gnu_ld 38129bd41f2cSmrg])# AC_LIBTOOL_LANG_CXX_CONFIG 38139bd41f2cSmrg 38149bd41f2cSmrg# AC_LIBTOOL_POSTDEP_PREDEP([TAGNAME]) 38159bd41f2cSmrg# ------------------------------------ 38169bd41f2cSmrg# Figure out "hidden" library dependencies from verbose 38179bd41f2cSmrg# compiler output when linking a shared library. 38189bd41f2cSmrg# Parse the compiler output and extract the necessary 38199bd41f2cSmrg# objects, libraries and library flags. 38209bd41f2cSmrgAC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP],[ 38219bd41f2cSmrgdnl we can't use the lt_simple_compile_test_code here, 38229bd41f2cSmrgdnl because it contains code intended for an executable, 38239bd41f2cSmrgdnl not a library. It's possible we should let each 38249bd41f2cSmrgdnl tag define a new lt_????_link_test_code variable, 38259bd41f2cSmrgdnl but it's only used here... 38269bd41f2cSmrgifelse([$1],[],[cat > conftest.$ac_ext <<EOF 38279bd41f2cSmrgint a; 38289bd41f2cSmrgvoid foo (void) { a = 0; } 38299bd41f2cSmrgEOF 38309bd41f2cSmrg],[$1],[CXX],[cat > conftest.$ac_ext <<EOF 38319bd41f2cSmrgclass Foo 38329bd41f2cSmrg{ 38339bd41f2cSmrgpublic: 38349bd41f2cSmrg Foo (void) { a = 0; } 38359bd41f2cSmrgprivate: 38369bd41f2cSmrg int a; 38379bd41f2cSmrg}; 38389bd41f2cSmrgEOF 38399bd41f2cSmrg],[$1],[F77],[cat > conftest.$ac_ext <<EOF 38409bd41f2cSmrg subroutine foo 38419bd41f2cSmrg implicit none 38429bd41f2cSmrg integer*4 a 38439bd41f2cSmrg a=0 38449bd41f2cSmrg return 38459bd41f2cSmrg end 38469bd41f2cSmrgEOF 38479bd41f2cSmrg],[$1],[GCJ],[cat > conftest.$ac_ext <<EOF 38489bd41f2cSmrgpublic class foo { 38499bd41f2cSmrg private int a; 38509bd41f2cSmrg public void bar (void) { 38519bd41f2cSmrg a = 0; 38529bd41f2cSmrg } 38539bd41f2cSmrg}; 38549bd41f2cSmrgEOF 38559bd41f2cSmrg]) 38569bd41f2cSmrgdnl Parse the compiler output and extract the necessary 38579bd41f2cSmrgdnl objects, libraries and library flags. 38589bd41f2cSmrgif AC_TRY_EVAL(ac_compile); then 38599bd41f2cSmrg # Parse the compiler output and extract the necessary 38609bd41f2cSmrg # objects, libraries and library flags. 38619bd41f2cSmrg 38629bd41f2cSmrg # Sentinel used to keep track of whether or not we are before 38639bd41f2cSmrg # the conftest object file. 38649bd41f2cSmrg pre_test_object_deps_done=no 38659bd41f2cSmrg 38669bd41f2cSmrg # The `*' in the case matches for architectures that use `case' in 38679bd41f2cSmrg # $output_verbose_cmd can trigger glob expansion during the loop 38689bd41f2cSmrg # eval without this substitution. 38699bd41f2cSmrg output_verbose_link_cmd=`$echo "X$output_verbose_link_cmd" | $Xsed -e "$no_glob_subst"` 38709bd41f2cSmrg 38719bd41f2cSmrg for p in `eval $output_verbose_link_cmd`; do 38729bd41f2cSmrg case $p in 38739bd41f2cSmrg 38749bd41f2cSmrg -L* | -R* | -l*) 38759bd41f2cSmrg # Some compilers place space between "-{L,R}" and the path. 38769bd41f2cSmrg # Remove the space. 38779bd41f2cSmrg if test $p = "-L" \ 38789bd41f2cSmrg || test $p = "-R"; then 38799bd41f2cSmrg prev=$p 38809bd41f2cSmrg continue 38819bd41f2cSmrg else 38829bd41f2cSmrg prev= 38839bd41f2cSmrg fi 38849bd41f2cSmrg 38859bd41f2cSmrg if test "$pre_test_object_deps_done" = no; then 38869bd41f2cSmrg case $p in 38879bd41f2cSmrg -L* | -R*) 38889bd41f2cSmrg # Internal compiler library paths should come after those 38899bd41f2cSmrg # provided the user. The postdeps already come after the 38909bd41f2cSmrg # user supplied libs so there is no need to process them. 38919bd41f2cSmrg if test -z "$_LT_AC_TAGVAR(compiler_lib_search_path, $1)"; then 38929bd41f2cSmrg _LT_AC_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}" 38939bd41f2cSmrg else 38949bd41f2cSmrg _LT_AC_TAGVAR(compiler_lib_search_path, $1)="${_LT_AC_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}" 38959bd41f2cSmrg fi 38969bd41f2cSmrg ;; 38979bd41f2cSmrg # The "-l" case would never come before the object being 38989bd41f2cSmrg # linked, so don't bother handling this case. 38999bd41f2cSmrg esac 39009bd41f2cSmrg else 39019bd41f2cSmrg if test -z "$_LT_AC_TAGVAR(postdeps, $1)"; then 39029bd41f2cSmrg _LT_AC_TAGVAR(postdeps, $1)="${prev}${p}" 39039bd41f2cSmrg else 39049bd41f2cSmrg _LT_AC_TAGVAR(postdeps, $1)="${_LT_AC_TAGVAR(postdeps, $1)} ${prev}${p}" 39059bd41f2cSmrg fi 39069bd41f2cSmrg fi 39079bd41f2cSmrg ;; 39089bd41f2cSmrg 39099bd41f2cSmrg *.$objext) 39109bd41f2cSmrg # This assumes that the test object file only shows up 39119bd41f2cSmrg # once in the compiler output. 39129bd41f2cSmrg if test "$p" = "conftest.$objext"; then 39139bd41f2cSmrg pre_test_object_deps_done=yes 39149bd41f2cSmrg continue 39159bd41f2cSmrg fi 39169bd41f2cSmrg 39179bd41f2cSmrg if test "$pre_test_object_deps_done" = no; then 39189bd41f2cSmrg if test -z "$_LT_AC_TAGVAR(predep_objects, $1)"; then 39199bd41f2cSmrg _LT_AC_TAGVAR(predep_objects, $1)="$p" 39209bd41f2cSmrg else 39219bd41f2cSmrg _LT_AC_TAGVAR(predep_objects, $1)="$_LT_AC_TAGVAR(predep_objects, $1) $p" 39229bd41f2cSmrg fi 39239bd41f2cSmrg else 39249bd41f2cSmrg if test -z "$_LT_AC_TAGVAR(postdep_objects, $1)"; then 39259bd41f2cSmrg _LT_AC_TAGVAR(postdep_objects, $1)="$p" 39269bd41f2cSmrg else 39279bd41f2cSmrg _LT_AC_TAGVAR(postdep_objects, $1)="$_LT_AC_TAGVAR(postdep_objects, $1) $p" 39289bd41f2cSmrg fi 39299bd41f2cSmrg fi 39309bd41f2cSmrg ;; 39319bd41f2cSmrg 39329bd41f2cSmrg *) ;; # Ignore the rest. 39339bd41f2cSmrg 39349bd41f2cSmrg esac 39359bd41f2cSmrg done 39369bd41f2cSmrg 39379bd41f2cSmrg # Clean up. 39389bd41f2cSmrg rm -f a.out a.exe 39399bd41f2cSmrgelse 39409bd41f2cSmrg echo "libtool.m4: error: problem compiling $1 test program" 39419bd41f2cSmrgfi 39429bd41f2cSmrg 39439bd41f2cSmrg$rm -f confest.$objext 39449bd41f2cSmrg 39459bd41f2cSmrg# PORTME: override above test on systems where it is broken 39469bd41f2cSmrgifelse([$1],[CXX], 39479bd41f2cSmrg[case $host_os in 39489bd41f2cSmrginterix[[3-9]]*) 39499bd41f2cSmrg # Interix 3.5 installs completely hosed .la files for C++, so rather than 39509bd41f2cSmrg # hack all around it, let's just trust "g++" to DTRT. 39519bd41f2cSmrg _LT_AC_TAGVAR(predep_objects,$1)= 39529bd41f2cSmrg _LT_AC_TAGVAR(postdep_objects,$1)= 39539bd41f2cSmrg _LT_AC_TAGVAR(postdeps,$1)= 39549bd41f2cSmrg ;; 39559bd41f2cSmrg 39569bd41f2cSmrglinux*) 39579bd41f2cSmrg case `$CC -V 2>&1 | sed 5q` in 39589bd41f2cSmrg *Sun\ C*) 39599bd41f2cSmrg # Sun C++ 5.9 39609bd41f2cSmrg # 39619bd41f2cSmrg # The more standards-conforming stlport4 library is 39629bd41f2cSmrg # incompatible with the Cstd library. Avoid specifying 39639bd41f2cSmrg # it if it's in CXXFLAGS. Ignore libCrun as 39649bd41f2cSmrg # -library=stlport4 depends on it. 39659bd41f2cSmrg case " $CXX $CXXFLAGS " in 39669bd41f2cSmrg *" -library=stlport4 "*) 39679bd41f2cSmrg solaris_use_stlport4=yes 39689bd41f2cSmrg ;; 39699bd41f2cSmrg esac 39709bd41f2cSmrg if test "$solaris_use_stlport4" != yes; then 39719bd41f2cSmrg _LT_AC_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun' 39729bd41f2cSmrg fi 39739bd41f2cSmrg ;; 39749bd41f2cSmrg esac 39759bd41f2cSmrg ;; 39769bd41f2cSmrg 39779bd41f2cSmrgsolaris*) 39789bd41f2cSmrg case $cc_basename in 39799bd41f2cSmrg CC*) 39809bd41f2cSmrg # The more standards-conforming stlport4 library is 39819bd41f2cSmrg # incompatible with the Cstd library. Avoid specifying 39829bd41f2cSmrg # it if it's in CXXFLAGS. Ignore libCrun as 39839bd41f2cSmrg # -library=stlport4 depends on it. 39849bd41f2cSmrg case " $CXX $CXXFLAGS " in 39859bd41f2cSmrg *" -library=stlport4 "*) 39869bd41f2cSmrg solaris_use_stlport4=yes 39879bd41f2cSmrg ;; 39889bd41f2cSmrg esac 39899bd41f2cSmrg 39909bd41f2cSmrg # Adding this requires a known-good setup of shared libraries for 39919bd41f2cSmrg # Sun compiler versions before 5.6, else PIC objects from an old 39929bd41f2cSmrg # archive will be linked into the output, leading to subtle bugs. 39939bd41f2cSmrg if test "$solaris_use_stlport4" != yes; then 39949bd41f2cSmrg _LT_AC_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun' 39959bd41f2cSmrg fi 39969bd41f2cSmrg ;; 39979bd41f2cSmrg esac 39989bd41f2cSmrg ;; 39999bd41f2cSmrgesac 40009bd41f2cSmrg]) 40019bd41f2cSmrg 40029bd41f2cSmrgcase " $_LT_AC_TAGVAR(postdeps, $1) " in 40039bd41f2cSmrg*" -lc "*) _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no ;; 40049bd41f2cSmrgesac 40059bd41f2cSmrg])# AC_LIBTOOL_POSTDEP_PREDEP 40069bd41f2cSmrg 40079bd41f2cSmrg# AC_LIBTOOL_LANG_F77_CONFIG 40089bd41f2cSmrg# -------------------------- 40099bd41f2cSmrg# Ensure that the configuration vars for the C compiler are 40109bd41f2cSmrg# suitably defined. Those variables are subsequently used by 40119bd41f2cSmrg# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'. 40129bd41f2cSmrgAC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG], [_LT_AC_LANG_F77_CONFIG(F77)]) 40139bd41f2cSmrgAC_DEFUN([_LT_AC_LANG_F77_CONFIG], 40149bd41f2cSmrg[AC_REQUIRE([AC_PROG_F77]) 40159bd41f2cSmrgAC_LANG_PUSH(Fortran 77) 40169bd41f2cSmrg 40179bd41f2cSmrg_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no 40189bd41f2cSmrg_LT_AC_TAGVAR(allow_undefined_flag, $1)= 40199bd41f2cSmrg_LT_AC_TAGVAR(always_export_symbols, $1)=no 40209bd41f2cSmrg_LT_AC_TAGVAR(archive_expsym_cmds, $1)= 40219bd41f2cSmrg_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)= 40229bd41f2cSmrg_LT_AC_TAGVAR(hardcode_direct, $1)=no 40239bd41f2cSmrg_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)= 40249bd41f2cSmrg_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= 40259bd41f2cSmrg_LT_AC_TAGVAR(hardcode_libdir_separator, $1)= 40269bd41f2cSmrg_LT_AC_TAGVAR(hardcode_minus_L, $1)=no 40279bd41f2cSmrg_LT_AC_TAGVAR(hardcode_automatic, $1)=no 40289bd41f2cSmrg_LT_AC_TAGVAR(module_cmds, $1)= 40299bd41f2cSmrg_LT_AC_TAGVAR(module_expsym_cmds, $1)= 40309bd41f2cSmrg_LT_AC_TAGVAR(link_all_deplibs, $1)=unknown 40319bd41f2cSmrg_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 40329bd41f2cSmrg_LT_AC_TAGVAR(no_undefined_flag, $1)= 40339bd41f2cSmrg_LT_AC_TAGVAR(whole_archive_flag_spec, $1)= 40349bd41f2cSmrg_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no 40359bd41f2cSmrg 40369bd41f2cSmrg# Source file extension for f77 test sources. 40379bd41f2cSmrgac_ext=f 40389bd41f2cSmrg 40399bd41f2cSmrg# Object file extension for compiled f77 test sources. 40409bd41f2cSmrgobjext=o 40419bd41f2cSmrg_LT_AC_TAGVAR(objext, $1)=$objext 40429bd41f2cSmrg 40439bd41f2cSmrg# Code to be used in simple compile tests 40449bd41f2cSmrglt_simple_compile_test_code="\ 40459bd41f2cSmrg subroutine t 40469bd41f2cSmrg return 40479bd41f2cSmrg end 40489bd41f2cSmrg" 40499bd41f2cSmrg 40509bd41f2cSmrg# Code to be used in simple link tests 40519bd41f2cSmrglt_simple_link_test_code="\ 40529bd41f2cSmrg program t 40539bd41f2cSmrg end 40549bd41f2cSmrg" 40559bd41f2cSmrg 40569bd41f2cSmrg# ltmain only uses $CC for tagged configurations so make sure $CC is set. 40579bd41f2cSmrg_LT_AC_SYS_COMPILER 40589bd41f2cSmrg 40599bd41f2cSmrg# save warnings/boilerplate of simple test code 40609bd41f2cSmrg_LT_COMPILER_BOILERPLATE 40619bd41f2cSmrg_LT_LINKER_BOILERPLATE 40629bd41f2cSmrg 40639bd41f2cSmrg# Allow CC to be a program name with arguments. 40649bd41f2cSmrglt_save_CC="$CC" 40659bd41f2cSmrgCC=${F77-"f77"} 40669bd41f2cSmrgcompiler=$CC 40679bd41f2cSmrg_LT_AC_TAGVAR(compiler, $1)=$CC 40689bd41f2cSmrg_LT_CC_BASENAME([$compiler]) 40699bd41f2cSmrg 40709bd41f2cSmrgAC_MSG_CHECKING([if libtool supports shared libraries]) 40719bd41f2cSmrgAC_MSG_RESULT([$can_build_shared]) 40729bd41f2cSmrg 40739bd41f2cSmrgAC_MSG_CHECKING([whether to build shared libraries]) 40749bd41f2cSmrgtest "$can_build_shared" = "no" && enable_shared=no 40759bd41f2cSmrg 40769bd41f2cSmrg# On AIX, shared libraries and static libraries use the same namespace, and 40779bd41f2cSmrg# are all built from PIC. 40789bd41f2cSmrgcase $host_os in 40799bd41f2cSmrgaix3*) 40809bd41f2cSmrg test "$enable_shared" = yes && enable_static=no 40819bd41f2cSmrg if test -n "$RANLIB"; then 40829bd41f2cSmrg archive_cmds="$archive_cmds~\$RANLIB \$lib" 40839bd41f2cSmrg postinstall_cmds='$RANLIB $lib' 40849bd41f2cSmrg fi 40859bd41f2cSmrg ;; 40869bd41f2cSmrgaix4* | aix5*) 40879bd41f2cSmrg if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then 40889bd41f2cSmrg test "$enable_shared" = yes && enable_static=no 40899bd41f2cSmrg fi 40909bd41f2cSmrg ;; 40919bd41f2cSmrgesac 40929bd41f2cSmrgAC_MSG_RESULT([$enable_shared]) 40939bd41f2cSmrg 40949bd41f2cSmrgAC_MSG_CHECKING([whether to build static libraries]) 40959bd41f2cSmrg# Make sure either enable_shared or enable_static is yes. 40969bd41f2cSmrgtest "$enable_shared" = yes || enable_static=yes 40979bd41f2cSmrgAC_MSG_RESULT([$enable_static]) 40989bd41f2cSmrg 40999bd41f2cSmrg_LT_AC_TAGVAR(GCC, $1)="$G77" 41009bd41f2cSmrg_LT_AC_TAGVAR(LD, $1)="$LD" 41019bd41f2cSmrg 41029bd41f2cSmrgAC_LIBTOOL_PROG_COMPILER_PIC($1) 41039bd41f2cSmrgAC_LIBTOOL_PROG_CC_C_O($1) 41049bd41f2cSmrgAC_LIBTOOL_SYS_HARD_LINK_LOCKS($1) 41059bd41f2cSmrgAC_LIBTOOL_PROG_LD_SHLIBS($1) 41069bd41f2cSmrgAC_LIBTOOL_SYS_DYNAMIC_LINKER($1) 41079bd41f2cSmrgAC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1) 41089bd41f2cSmrg 41099bd41f2cSmrgAC_LIBTOOL_CONFIG($1) 41109bd41f2cSmrg 41119bd41f2cSmrgAC_LANG_POP 41129bd41f2cSmrgCC="$lt_save_CC" 41139bd41f2cSmrg])# AC_LIBTOOL_LANG_F77_CONFIG 41149bd41f2cSmrg 41159bd41f2cSmrg 41169bd41f2cSmrg# AC_LIBTOOL_LANG_GCJ_CONFIG 41179bd41f2cSmrg# -------------------------- 41189bd41f2cSmrg# Ensure that the configuration vars for the C compiler are 41199bd41f2cSmrg# suitably defined. Those variables are subsequently used by 41209bd41f2cSmrg# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'. 41219bd41f2cSmrgAC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG], [_LT_AC_LANG_GCJ_CONFIG(GCJ)]) 41229bd41f2cSmrgAC_DEFUN([_LT_AC_LANG_GCJ_CONFIG], 41239bd41f2cSmrg[AC_LANG_SAVE 41249bd41f2cSmrg 41259bd41f2cSmrg# Source file extension for Java test sources. 41269bd41f2cSmrgac_ext=java 41279bd41f2cSmrg 41289bd41f2cSmrg# Object file extension for compiled Java test sources. 41299bd41f2cSmrgobjext=o 41309bd41f2cSmrg_LT_AC_TAGVAR(objext, $1)=$objext 41319bd41f2cSmrg 41329bd41f2cSmrg# Code to be used in simple compile tests 41339bd41f2cSmrglt_simple_compile_test_code="class foo {}" 41349bd41f2cSmrg 41359bd41f2cSmrg# Code to be used in simple link tests 41369bd41f2cSmrglt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }' 41379bd41f2cSmrg 41389bd41f2cSmrg# ltmain only uses $CC for tagged configurations so make sure $CC is set. 41399bd41f2cSmrg_LT_AC_SYS_COMPILER 41409bd41f2cSmrg 41419bd41f2cSmrg# save warnings/boilerplate of simple test code 41429bd41f2cSmrg_LT_COMPILER_BOILERPLATE 41439bd41f2cSmrg_LT_LINKER_BOILERPLATE 41449bd41f2cSmrg 41459bd41f2cSmrg# Allow CC to be a program name with arguments. 41469bd41f2cSmrglt_save_CC="$CC" 41479bd41f2cSmrgCC=${GCJ-"gcj"} 41489bd41f2cSmrgcompiler=$CC 41499bd41f2cSmrg_LT_AC_TAGVAR(compiler, $1)=$CC 41509bd41f2cSmrg_LT_CC_BASENAME([$compiler]) 41519bd41f2cSmrg 41529bd41f2cSmrg# GCJ did not exist at the time GCC didn't implicitly link libc in. 41539bd41f2cSmrg_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no 41549bd41f2cSmrg 41559bd41f2cSmrg_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 41569bd41f2cSmrg 41579bd41f2cSmrgAC_LIBTOOL_PROG_COMPILER_NO_RTTI($1) 41589bd41f2cSmrgAC_LIBTOOL_PROG_COMPILER_PIC($1) 41599bd41f2cSmrgAC_LIBTOOL_PROG_CC_C_O($1) 41609bd41f2cSmrgAC_LIBTOOL_SYS_HARD_LINK_LOCKS($1) 41619bd41f2cSmrgAC_LIBTOOL_PROG_LD_SHLIBS($1) 41629bd41f2cSmrgAC_LIBTOOL_SYS_DYNAMIC_LINKER($1) 41639bd41f2cSmrgAC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1) 41649bd41f2cSmrg 41659bd41f2cSmrgAC_LIBTOOL_CONFIG($1) 41669bd41f2cSmrg 41679bd41f2cSmrgAC_LANG_RESTORE 41689bd41f2cSmrgCC="$lt_save_CC" 41699bd41f2cSmrg])# AC_LIBTOOL_LANG_GCJ_CONFIG 41709bd41f2cSmrg 41719bd41f2cSmrg 41729bd41f2cSmrg# AC_LIBTOOL_LANG_RC_CONFIG 41739bd41f2cSmrg# ------------------------- 41749bd41f2cSmrg# Ensure that the configuration vars for the Windows resource compiler are 41759bd41f2cSmrg# suitably defined. Those variables are subsequently used by 41769bd41f2cSmrg# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'. 41779bd41f2cSmrgAC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG], [_LT_AC_LANG_RC_CONFIG(RC)]) 41789bd41f2cSmrgAC_DEFUN([_LT_AC_LANG_RC_CONFIG], 41799bd41f2cSmrg[AC_LANG_SAVE 41809bd41f2cSmrg 41819bd41f2cSmrg# Source file extension for RC test sources. 41829bd41f2cSmrgac_ext=rc 41839bd41f2cSmrg 41849bd41f2cSmrg# Object file extension for compiled RC test sources. 41859bd41f2cSmrgobjext=o 41869bd41f2cSmrg_LT_AC_TAGVAR(objext, $1)=$objext 41879bd41f2cSmrg 41889bd41f2cSmrg# Code to be used in simple compile tests 41899bd41f2cSmrglt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }' 41909bd41f2cSmrg 41919bd41f2cSmrg# Code to be used in simple link tests 41929bd41f2cSmrglt_simple_link_test_code="$lt_simple_compile_test_code" 41939bd41f2cSmrg 41949bd41f2cSmrg# ltmain only uses $CC for tagged configurations so make sure $CC is set. 41959bd41f2cSmrg_LT_AC_SYS_COMPILER 41969bd41f2cSmrg 41979bd41f2cSmrg# save warnings/boilerplate of simple test code 41989bd41f2cSmrg_LT_COMPILER_BOILERPLATE 41999bd41f2cSmrg_LT_LINKER_BOILERPLATE 42009bd41f2cSmrg 42019bd41f2cSmrg# Allow CC to be a program name with arguments. 42029bd41f2cSmrglt_save_CC="$CC" 42039bd41f2cSmrgCC=${RC-"windres"} 42049bd41f2cSmrgcompiler=$CC 42059bd41f2cSmrg_LT_AC_TAGVAR(compiler, $1)=$CC 42069bd41f2cSmrg_LT_CC_BASENAME([$compiler]) 42079bd41f2cSmrg_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes 42089bd41f2cSmrg 42099bd41f2cSmrgAC_LIBTOOL_CONFIG($1) 42109bd41f2cSmrg 42119bd41f2cSmrgAC_LANG_RESTORE 42129bd41f2cSmrgCC="$lt_save_CC" 42139bd41f2cSmrg])# AC_LIBTOOL_LANG_RC_CONFIG 42149bd41f2cSmrg 42159bd41f2cSmrg 42169bd41f2cSmrg# AC_LIBTOOL_CONFIG([TAGNAME]) 42179bd41f2cSmrg# ---------------------------- 42189bd41f2cSmrg# If TAGNAME is not passed, then create an initial libtool script 42199bd41f2cSmrg# with a default configuration from the untagged config vars. Otherwise 42209bd41f2cSmrg# add code to config.status for appending the configuration named by 42219bd41f2cSmrg# TAGNAME from the matching tagged config vars. 42229bd41f2cSmrgAC_DEFUN([AC_LIBTOOL_CONFIG], 42239bd41f2cSmrg[# The else clause should only fire when bootstrapping the 42249bd41f2cSmrg# libtool distribution, otherwise you forgot to ship ltmain.sh 42259bd41f2cSmrg# with your package, and you will get complaints that there are 42269bd41f2cSmrg# no rules to generate ltmain.sh. 42279bd41f2cSmrgif test -f "$ltmain"; then 42289bd41f2cSmrg # See if we are running on zsh, and set the options which allow our commands through 42299bd41f2cSmrg # without removal of \ escapes. 42309bd41f2cSmrg if test -n "${ZSH_VERSION+set}" ; then 42319bd41f2cSmrg setopt NO_GLOB_SUBST 42329bd41f2cSmrg fi 42339bd41f2cSmrg # Now quote all the things that may contain metacharacters while being 42349bd41f2cSmrg # careful not to overquote the AC_SUBSTed values. We take copies of the 42359bd41f2cSmrg # variables and quote the copies for generation of the libtool script. 42369bd41f2cSmrg for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC LTCFLAGS NM \ 42379bd41f2cSmrg SED SHELL STRIP \ 42389bd41f2cSmrg libname_spec library_names_spec soname_spec extract_expsyms_cmds \ 42399bd41f2cSmrg old_striplib striplib file_magic_cmd finish_cmds finish_eval \ 42409bd41f2cSmrg deplibs_check_method reload_flag reload_cmds need_locks \ 42419bd41f2cSmrg lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \ 42429bd41f2cSmrg lt_cv_sys_global_symbol_to_c_name_address \ 42439bd41f2cSmrg sys_lib_search_path_spec sys_lib_dlsearch_path_spec \ 42449bd41f2cSmrg old_postinstall_cmds old_postuninstall_cmds \ 42459bd41f2cSmrg _LT_AC_TAGVAR(compiler, $1) \ 42469bd41f2cSmrg _LT_AC_TAGVAR(CC, $1) \ 42479bd41f2cSmrg _LT_AC_TAGVAR(LD, $1) \ 42489bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1) \ 42499bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1) \ 42509bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1) \ 42519bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) \ 42529bd41f2cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1) \ 42539bd41f2cSmrg _LT_AC_TAGVAR(thread_safe_flag_spec, $1) \ 42549bd41f2cSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1) \ 42559bd41f2cSmrg _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1) \ 42569bd41f2cSmrg _LT_AC_TAGVAR(old_archive_cmds, $1) \ 42579bd41f2cSmrg _LT_AC_TAGVAR(old_archive_from_new_cmds, $1) \ 42589bd41f2cSmrg _LT_AC_TAGVAR(predep_objects, $1) \ 42599bd41f2cSmrg _LT_AC_TAGVAR(postdep_objects, $1) \ 42609bd41f2cSmrg _LT_AC_TAGVAR(predeps, $1) \ 42619bd41f2cSmrg _LT_AC_TAGVAR(postdeps, $1) \ 42629bd41f2cSmrg _LT_AC_TAGVAR(compiler_lib_search_path, $1) \ 42639bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1) \ 42649bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1) \ 42659bd41f2cSmrg _LT_AC_TAGVAR(postinstall_cmds, $1) \ 42669bd41f2cSmrg _LT_AC_TAGVAR(postuninstall_cmds, $1) \ 42679bd41f2cSmrg _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) \ 42689bd41f2cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1) \ 42699bd41f2cSmrg _LT_AC_TAGVAR(no_undefined_flag, $1) \ 42709bd41f2cSmrg _LT_AC_TAGVAR(export_symbols_cmds, $1) \ 42719bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) \ 42729bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1) \ 42739bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1) \ 42749bd41f2cSmrg _LT_AC_TAGVAR(hardcode_automatic, $1) \ 42759bd41f2cSmrg _LT_AC_TAGVAR(module_cmds, $1) \ 42769bd41f2cSmrg _LT_AC_TAGVAR(module_expsym_cmds, $1) \ 42779bd41f2cSmrg _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1) \ 42789bd41f2cSmrg _LT_AC_TAGVAR(fix_srcfile_path, $1) \ 42799bd41f2cSmrg _LT_AC_TAGVAR(exclude_expsyms, $1) \ 42809bd41f2cSmrg _LT_AC_TAGVAR(include_expsyms, $1); do 42819bd41f2cSmrg 42829bd41f2cSmrg case $var in 42839bd41f2cSmrg _LT_AC_TAGVAR(old_archive_cmds, $1) | \ 42849bd41f2cSmrg _LT_AC_TAGVAR(old_archive_from_new_cmds, $1) | \ 42859bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1) | \ 42869bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1) | \ 42879bd41f2cSmrg _LT_AC_TAGVAR(module_cmds, $1) | \ 42889bd41f2cSmrg _LT_AC_TAGVAR(module_expsym_cmds, $1) | \ 42899bd41f2cSmrg _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) | \ 42909bd41f2cSmrg _LT_AC_TAGVAR(export_symbols_cmds, $1) | \ 42919bd41f2cSmrg extract_expsyms_cmds | reload_cmds | finish_cmds | \ 42929bd41f2cSmrg postinstall_cmds | postuninstall_cmds | \ 42939bd41f2cSmrg old_postinstall_cmds | old_postuninstall_cmds | \ 42949bd41f2cSmrg sys_lib_search_path_spec | sys_lib_dlsearch_path_spec) 42959bd41f2cSmrg # Double-quote double-evaled strings. 42969bd41f2cSmrg eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\"" 42979bd41f2cSmrg ;; 42989bd41f2cSmrg *) 42999bd41f2cSmrg eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\"" 43009bd41f2cSmrg ;; 43019bd41f2cSmrg esac 43029bd41f2cSmrg done 43039bd41f2cSmrg 43049bd41f2cSmrg case $lt_echo in 43059bd41f2cSmrg *'\[$]0 --fallback-echo"') 43069bd41f2cSmrg lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\[$]0 --fallback-echo"[$]/[$]0 --fallback-echo"/'` 43079bd41f2cSmrg ;; 43089bd41f2cSmrg esac 43099bd41f2cSmrg 43109bd41f2cSmrgifelse([$1], [], 43119bd41f2cSmrg [cfgfile="${ofile}T" 43129bd41f2cSmrg trap "$rm \"$cfgfile\"; exit 1" 1 2 15 43139bd41f2cSmrg $rm -f "$cfgfile" 43149bd41f2cSmrg AC_MSG_NOTICE([creating $ofile])], 43159bd41f2cSmrg [cfgfile="$ofile"]) 43169bd41f2cSmrg 43179bd41f2cSmrg cat <<__EOF__ >> "$cfgfile" 43189bd41f2cSmrgifelse([$1], [], 43199bd41f2cSmrg[#! $SHELL 43209bd41f2cSmrg 43219bd41f2cSmrg# `$echo "$cfgfile" | sed 's%^.*/%%'` - Provide generalized library-building support services. 43229bd41f2cSmrg# Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP) 43239bd41f2cSmrg# NOTE: Changes made to this file will be lost: look at ltmain.sh. 43249bd41f2cSmrg# 43259bd41f2cSmrg# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007 43269bd41f2cSmrg# Free Software Foundation, Inc. 43279bd41f2cSmrg# 43289bd41f2cSmrg# This file is part of GNU Libtool: 43299bd41f2cSmrg# Originally by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996 43309bd41f2cSmrg# 43319bd41f2cSmrg# This program is free software; you can redistribute it and/or modify 43329bd41f2cSmrg# it under the terms of the GNU General Public License as published by 43339bd41f2cSmrg# the Free Software Foundation; either version 2 of the License, or 43349bd41f2cSmrg# (at your option) any later version. 43359bd41f2cSmrg# 43369bd41f2cSmrg# This program is distributed in the hope that it will be useful, but 43379bd41f2cSmrg# WITHOUT ANY WARRANTY; without even the implied warranty of 43389bd41f2cSmrg# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 43399bd41f2cSmrg# General Public License for more details. 43409bd41f2cSmrg# 43419bd41f2cSmrg# You should have received a copy of the GNU General Public License 43429bd41f2cSmrg# along with this program; if not, write to the Free Software 43439bd41f2cSmrg# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 43449bd41f2cSmrg# 43459bd41f2cSmrg# As a special exception to the GNU General Public License, if you 43469bd41f2cSmrg# distribute this file as part of a program that contains a 43479bd41f2cSmrg# configuration script generated by Autoconf, you may include it under 43489bd41f2cSmrg# the same distribution terms that you use for the rest of that program. 43499bd41f2cSmrg 43509bd41f2cSmrg# A sed program that does not truncate output. 43519bd41f2cSmrgSED=$lt_SED 43529bd41f2cSmrg 43539bd41f2cSmrg# Sed that helps us avoid accidentally triggering echo(1) options like -n. 43549bd41f2cSmrgXsed="$SED -e 1s/^X//" 43559bd41f2cSmrg 43569bd41f2cSmrg# The HP-UX ksh and POSIX shell print the target directory to stdout 43579bd41f2cSmrg# if CDPATH is set. 43589bd41f2cSmrg(unset CDPATH) >/dev/null 2>&1 && unset CDPATH 43599bd41f2cSmrg 43609bd41f2cSmrg# The names of the tagged configurations supported by this script. 43619bd41f2cSmrgavailable_tags= 43629bd41f2cSmrg 43639bd41f2cSmrg# ### BEGIN LIBTOOL CONFIG], 43649bd41f2cSmrg[# ### BEGIN LIBTOOL TAG CONFIG: $tagname]) 43659bd41f2cSmrg 43669bd41f2cSmrg# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: 43679bd41f2cSmrg 43689bd41f2cSmrg# Shell to use when invoking shell scripts. 43699bd41f2cSmrgSHELL=$lt_SHELL 43709bd41f2cSmrg 43719bd41f2cSmrg# Whether or not to build shared libraries. 43729bd41f2cSmrgbuild_libtool_libs=$enable_shared 43739bd41f2cSmrg 43749bd41f2cSmrg# Whether or not to build static libraries. 43759bd41f2cSmrgbuild_old_libs=$enable_static 43769bd41f2cSmrg 43779bd41f2cSmrg# Whether or not to add -lc for building shared libraries. 43789bd41f2cSmrgbuild_libtool_need_lc=$_LT_AC_TAGVAR(archive_cmds_need_lc, $1) 43799bd41f2cSmrg 43809bd41f2cSmrg# Whether or not to disallow shared libs when runtime libs are static 43819bd41f2cSmrgallow_libtool_libs_with_static_runtimes=$_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1) 43829bd41f2cSmrg 43839bd41f2cSmrg# Whether or not to optimize for fast installation. 43849bd41f2cSmrgfast_install=$enable_fast_install 43859bd41f2cSmrg 43869bd41f2cSmrg# The host system. 43879bd41f2cSmrghost_alias=$host_alias 43889bd41f2cSmrghost=$host 43899bd41f2cSmrghost_os=$host_os 43909bd41f2cSmrg 43919bd41f2cSmrg# The build system. 43929bd41f2cSmrgbuild_alias=$build_alias 43939bd41f2cSmrgbuild=$build 43949bd41f2cSmrgbuild_os=$build_os 43959bd41f2cSmrg 43969bd41f2cSmrg# An echo program that does not interpret backslashes. 43979bd41f2cSmrgecho=$lt_echo 43989bd41f2cSmrg 43999bd41f2cSmrg# The archiver. 44009bd41f2cSmrgAR=$lt_AR 44019bd41f2cSmrgAR_FLAGS=$lt_AR_FLAGS 44029bd41f2cSmrg 44039bd41f2cSmrg# A C compiler. 44049bd41f2cSmrgLTCC=$lt_LTCC 44059bd41f2cSmrg 44069bd41f2cSmrg# LTCC compiler flags. 44079bd41f2cSmrgLTCFLAGS=$lt_LTCFLAGS 44089bd41f2cSmrg 44099bd41f2cSmrg# A language-specific compiler. 44109bd41f2cSmrgCC=$lt_[]_LT_AC_TAGVAR(compiler, $1) 44119bd41f2cSmrg 44129bd41f2cSmrg# Is the compiler the GNU C compiler? 44139bd41f2cSmrgwith_gcc=$_LT_AC_TAGVAR(GCC, $1) 44149bd41f2cSmrg 44159bd41f2cSmrg# An ERE matcher. 44169bd41f2cSmrgEGREP=$lt_EGREP 44179bd41f2cSmrg 44189bd41f2cSmrg# The linker used to build libraries. 44199bd41f2cSmrgLD=$lt_[]_LT_AC_TAGVAR(LD, $1) 44209bd41f2cSmrg 44219bd41f2cSmrg# Whether we need hard or soft links. 44229bd41f2cSmrgLN_S=$lt_LN_S 44239bd41f2cSmrg 44249bd41f2cSmrg# A BSD-compatible nm program. 44259bd41f2cSmrgNM=$lt_NM 44269bd41f2cSmrg 44279bd41f2cSmrg# A symbol stripping program 44289bd41f2cSmrgSTRIP=$lt_STRIP 44299bd41f2cSmrg 44309bd41f2cSmrg# Used to examine libraries when file_magic_cmd begins "file" 44319bd41f2cSmrgMAGIC_CMD=$MAGIC_CMD 44329bd41f2cSmrg 44339bd41f2cSmrg# Used on cygwin: DLL creation program. 44349bd41f2cSmrgDLLTOOL="$DLLTOOL" 44359bd41f2cSmrg 44369bd41f2cSmrg# Used on cygwin: object dumper. 44379bd41f2cSmrgOBJDUMP="$OBJDUMP" 44389bd41f2cSmrg 44399bd41f2cSmrg# Used on cygwin: assembler. 44409bd41f2cSmrgAS="$AS" 44419bd41f2cSmrg 44429bd41f2cSmrg# The name of the directory that contains temporary libtool files. 44439bd41f2cSmrgobjdir=$objdir 44449bd41f2cSmrg 44459bd41f2cSmrg# How to create reloadable object files. 44469bd41f2cSmrgreload_flag=$lt_reload_flag 44479bd41f2cSmrgreload_cmds=$lt_reload_cmds 44489bd41f2cSmrg 44499bd41f2cSmrg# How to pass a linker flag through the compiler. 44509bd41f2cSmrgwl=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_wl, $1) 44519bd41f2cSmrg 44529bd41f2cSmrg# Object file suffix (normally "o"). 44539bd41f2cSmrgobjext="$ac_objext" 44549bd41f2cSmrg 44559bd41f2cSmrg# Old archive suffix (normally "a"). 44569bd41f2cSmrglibext="$libext" 44579bd41f2cSmrg 44589bd41f2cSmrg# Shared library suffix (normally ".so"). 44599bd41f2cSmrgshrext_cmds='$shrext_cmds' 44609bd41f2cSmrg 44619bd41f2cSmrg# Executable file suffix (normally ""). 44629bd41f2cSmrgexeext="$exeext" 44639bd41f2cSmrg 44649bd41f2cSmrg# Additional compiler flags for building library objects. 44659bd41f2cSmrgpic_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) 44669bd41f2cSmrgpic_mode=$pic_mode 44679bd41f2cSmrg 44689bd41f2cSmrg# What is the maximum length of a command? 44699bd41f2cSmrgmax_cmd_len=$lt_cv_sys_max_cmd_len 44709bd41f2cSmrg 44719bd41f2cSmrg# Does compiler simultaneously support -c and -o options? 44729bd41f2cSmrgcompiler_c_o=$lt_[]_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1) 44739bd41f2cSmrg 44749bd41f2cSmrg# Must we lock files when doing compilation? 44759bd41f2cSmrgneed_locks=$lt_need_locks 44769bd41f2cSmrg 44779bd41f2cSmrg# Do we need the lib prefix for modules? 44789bd41f2cSmrgneed_lib_prefix=$need_lib_prefix 44799bd41f2cSmrg 44809bd41f2cSmrg# Do we need a version for libraries? 44819bd41f2cSmrgneed_version=$need_version 44829bd41f2cSmrg 44839bd41f2cSmrg# Whether dlopen is supported. 44849bd41f2cSmrgdlopen_support=$enable_dlopen 44859bd41f2cSmrg 44869bd41f2cSmrg# Whether dlopen of programs is supported. 44879bd41f2cSmrgdlopen_self=$enable_dlopen_self 44889bd41f2cSmrg 44899bd41f2cSmrg# Whether dlopen of statically linked programs is supported. 44909bd41f2cSmrgdlopen_self_static=$enable_dlopen_self_static 44919bd41f2cSmrg 44929bd41f2cSmrg# Compiler flag to prevent dynamic linking. 44939bd41f2cSmrglink_static_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_static, $1) 44949bd41f2cSmrg 44959bd41f2cSmrg# Compiler flag to turn off builtin functions. 44969bd41f2cSmrgno_builtin_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) 44979bd41f2cSmrg 44989bd41f2cSmrg# Compiler flag to allow reflexive dlopens. 44999bd41f2cSmrgexport_dynamic_flag_spec=$lt_[]_LT_AC_TAGVAR(export_dynamic_flag_spec, $1) 45009bd41f2cSmrg 45019bd41f2cSmrg# Compiler flag to generate shared objects directly from archives. 45029bd41f2cSmrgwhole_archive_flag_spec=$lt_[]_LT_AC_TAGVAR(whole_archive_flag_spec, $1) 45039bd41f2cSmrg 45049bd41f2cSmrg# Compiler flag to generate thread-safe objects. 45059bd41f2cSmrgthread_safe_flag_spec=$lt_[]_LT_AC_TAGVAR(thread_safe_flag_spec, $1) 45069bd41f2cSmrg 45079bd41f2cSmrg# Library versioning type. 45089bd41f2cSmrgversion_type=$version_type 45099bd41f2cSmrg 45109bd41f2cSmrg# Format of library name prefix. 45119bd41f2cSmrglibname_spec=$lt_libname_spec 45129bd41f2cSmrg 45139bd41f2cSmrg# List of archive names. First name is the real one, the rest are links. 45149bd41f2cSmrg# The last name is the one that the linker finds with -lNAME. 45159bd41f2cSmrglibrary_names_spec=$lt_library_names_spec 45169bd41f2cSmrg 45179bd41f2cSmrg# The coded name of the library, if different from the real name. 45189bd41f2cSmrgsoname_spec=$lt_soname_spec 45199bd41f2cSmrg 45209bd41f2cSmrg# Commands used to build and install an old-style archive. 45219bd41f2cSmrgRANLIB=$lt_RANLIB 45229bd41f2cSmrgold_archive_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_cmds, $1) 45239bd41f2cSmrgold_postinstall_cmds=$lt_old_postinstall_cmds 45249bd41f2cSmrgold_postuninstall_cmds=$lt_old_postuninstall_cmds 45259bd41f2cSmrg 45269bd41f2cSmrg# Create an old-style archive from a shared archive. 45279bd41f2cSmrgold_archive_from_new_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_from_new_cmds, $1) 45289bd41f2cSmrg 45299bd41f2cSmrg# Create a temporary old-style archive to link instead of a shared archive. 45309bd41f2cSmrgold_archive_from_expsyms_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) 45319bd41f2cSmrg 45329bd41f2cSmrg# Commands used to build and install a shared archive. 45339bd41f2cSmrgarchive_cmds=$lt_[]_LT_AC_TAGVAR(archive_cmds, $1) 45349bd41f2cSmrgarchive_expsym_cmds=$lt_[]_LT_AC_TAGVAR(archive_expsym_cmds, $1) 45359bd41f2cSmrgpostinstall_cmds=$lt_postinstall_cmds 45369bd41f2cSmrgpostuninstall_cmds=$lt_postuninstall_cmds 45379bd41f2cSmrg 45389bd41f2cSmrg# Commands used to build a loadable module (assumed same as above if empty) 45399bd41f2cSmrgmodule_cmds=$lt_[]_LT_AC_TAGVAR(module_cmds, $1) 45409bd41f2cSmrgmodule_expsym_cmds=$lt_[]_LT_AC_TAGVAR(module_expsym_cmds, $1) 45419bd41f2cSmrg 45429bd41f2cSmrg# Commands to strip libraries. 45439bd41f2cSmrgold_striplib=$lt_old_striplib 45449bd41f2cSmrgstriplib=$lt_striplib 45459bd41f2cSmrg 45469bd41f2cSmrg# Dependencies to place before the objects being linked to create a 45479bd41f2cSmrg# shared library. 45489bd41f2cSmrgpredep_objects=$lt_[]_LT_AC_TAGVAR(predep_objects, $1) 45499bd41f2cSmrg 45509bd41f2cSmrg# Dependencies to place after the objects being linked to create a 45519bd41f2cSmrg# shared library. 45529bd41f2cSmrgpostdep_objects=$lt_[]_LT_AC_TAGVAR(postdep_objects, $1) 45539bd41f2cSmrg 45549bd41f2cSmrg# Dependencies to place before the objects being linked to create a 45559bd41f2cSmrg# shared library. 45569bd41f2cSmrgpredeps=$lt_[]_LT_AC_TAGVAR(predeps, $1) 45579bd41f2cSmrg 45589bd41f2cSmrg# Dependencies to place after the objects being linked to create a 45599bd41f2cSmrg# shared library. 45609bd41f2cSmrgpostdeps=$lt_[]_LT_AC_TAGVAR(postdeps, $1) 45619bd41f2cSmrg 45629bd41f2cSmrg# The library search path used internally by the compiler when linking 45639bd41f2cSmrg# a shared library. 45649bd41f2cSmrgcompiler_lib_search_path=$lt_[]_LT_AC_TAGVAR(compiler_lib_search_path, $1) 45659bd41f2cSmrg 45669bd41f2cSmrg# Method to check whether dependent libraries are shared objects. 45679bd41f2cSmrgdeplibs_check_method=$lt_deplibs_check_method 45689bd41f2cSmrg 45699bd41f2cSmrg# Command to use when deplibs_check_method == file_magic. 45709bd41f2cSmrgfile_magic_cmd=$lt_file_magic_cmd 45719bd41f2cSmrg 45729bd41f2cSmrg# Flag that allows shared libraries with undefined symbols to be built. 45739bd41f2cSmrgallow_undefined_flag=$lt_[]_LT_AC_TAGVAR(allow_undefined_flag, $1) 45749bd41f2cSmrg 45759bd41f2cSmrg# Flag that forces no undefined symbols. 45769bd41f2cSmrgno_undefined_flag=$lt_[]_LT_AC_TAGVAR(no_undefined_flag, $1) 45779bd41f2cSmrg 45789bd41f2cSmrg# Commands used to finish a libtool library installation in a directory. 45799bd41f2cSmrgfinish_cmds=$lt_finish_cmds 45809bd41f2cSmrg 45819bd41f2cSmrg# Same as above, but a single script fragment to be evaled but not shown. 45829bd41f2cSmrgfinish_eval=$lt_finish_eval 45839bd41f2cSmrg 45849bd41f2cSmrg# Take the output of nm and produce a listing of raw symbols and C names. 45859bd41f2cSmrgglobal_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe 45869bd41f2cSmrg 45879bd41f2cSmrg# Transform the output of nm in a proper C declaration 45889bd41f2cSmrgglobal_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl 45899bd41f2cSmrg 45909bd41f2cSmrg# Transform the output of nm in a C name address pair 45919bd41f2cSmrgglobal_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address 45929bd41f2cSmrg 45939bd41f2cSmrg# This is the shared library runtime path variable. 45949bd41f2cSmrgrunpath_var=$runpath_var 45959bd41f2cSmrg 45969bd41f2cSmrg# This is the shared library path variable. 45979bd41f2cSmrgshlibpath_var=$shlibpath_var 45989bd41f2cSmrg 45999bd41f2cSmrg# Is shlibpath searched before the hard-coded library search path? 46009bd41f2cSmrgshlibpath_overrides_runpath=$shlibpath_overrides_runpath 46019bd41f2cSmrg 46029bd41f2cSmrg# How to hardcode a shared library path into an executable. 46039bd41f2cSmrghardcode_action=$_LT_AC_TAGVAR(hardcode_action, $1) 46049bd41f2cSmrg 46059bd41f2cSmrg# Whether we should hardcode library paths into libraries. 46069bd41f2cSmrghardcode_into_libs=$hardcode_into_libs 46079bd41f2cSmrg 46089bd41f2cSmrg# Flag to hardcode \$libdir into a binary during linking. 46099bd41f2cSmrg# This must work even if \$libdir does not exist. 46109bd41f2cSmrghardcode_libdir_flag_spec=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) 46119bd41f2cSmrg 46129bd41f2cSmrg# If ld is used when linking, flag to hardcode \$libdir into 46139bd41f2cSmrg# a binary during linking. This must work even if \$libdir does 46149bd41f2cSmrg# not exist. 46159bd41f2cSmrghardcode_libdir_flag_spec_ld=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1) 46169bd41f2cSmrg 46179bd41f2cSmrg# Whether we need a single -rpath flag with a separated argument. 46189bd41f2cSmrghardcode_libdir_separator=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_separator, $1) 46199bd41f2cSmrg 46209bd41f2cSmrg# Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the 46219bd41f2cSmrg# resulting binary. 46229bd41f2cSmrghardcode_direct=$_LT_AC_TAGVAR(hardcode_direct, $1) 46239bd41f2cSmrg 46249bd41f2cSmrg# Set to yes if using the -LDIR flag during linking hardcodes DIR into the 46259bd41f2cSmrg# resulting binary. 46269bd41f2cSmrghardcode_minus_L=$_LT_AC_TAGVAR(hardcode_minus_L, $1) 46279bd41f2cSmrg 46289bd41f2cSmrg# Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into 46299bd41f2cSmrg# the resulting binary. 46309bd41f2cSmrghardcode_shlibpath_var=$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1) 46319bd41f2cSmrg 46329bd41f2cSmrg# Set to yes if building a shared library automatically hardcodes DIR into the library 46339bd41f2cSmrg# and all subsequent libraries and executables linked against it. 46349bd41f2cSmrghardcode_automatic=$_LT_AC_TAGVAR(hardcode_automatic, $1) 46359bd41f2cSmrg 46369bd41f2cSmrg# Variables whose values should be saved in libtool wrapper scripts and 46379bd41f2cSmrg# restored at relink time. 46389bd41f2cSmrgvariables_saved_for_relink="$variables_saved_for_relink" 46399bd41f2cSmrg 46409bd41f2cSmrg# Whether libtool must link a program against all its dependency libraries. 46419bd41f2cSmrglink_all_deplibs=$_LT_AC_TAGVAR(link_all_deplibs, $1) 46429bd41f2cSmrg 46439bd41f2cSmrg# Compile-time system search path for libraries 46449bd41f2cSmrgsys_lib_search_path_spec=$lt_sys_lib_search_path_spec 46459bd41f2cSmrg 46469bd41f2cSmrg# Run-time system search path for libraries 46479bd41f2cSmrgsys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec 46489bd41f2cSmrg 46499bd41f2cSmrg# Fix the shell variable \$srcfile for the compiler. 46509bd41f2cSmrgfix_srcfile_path=$lt_fix_srcfile_path 46519bd41f2cSmrg 46529bd41f2cSmrg# Set to yes if exported symbols are required. 46539bd41f2cSmrgalways_export_symbols=$_LT_AC_TAGVAR(always_export_symbols, $1) 46549bd41f2cSmrg 46559bd41f2cSmrg# The commands to list exported symbols. 46569bd41f2cSmrgexport_symbols_cmds=$lt_[]_LT_AC_TAGVAR(export_symbols_cmds, $1) 46579bd41f2cSmrg 46589bd41f2cSmrg# The commands to extract the exported symbol list from a shared archive. 46599bd41f2cSmrgextract_expsyms_cmds=$lt_extract_expsyms_cmds 46609bd41f2cSmrg 46619bd41f2cSmrg# Symbols that should not be listed in the preloaded symbols. 46629bd41f2cSmrgexclude_expsyms=$lt_[]_LT_AC_TAGVAR(exclude_expsyms, $1) 46639bd41f2cSmrg 46649bd41f2cSmrg# Symbols that must always be exported. 46659bd41f2cSmrginclude_expsyms=$lt_[]_LT_AC_TAGVAR(include_expsyms, $1) 46669bd41f2cSmrg 46679bd41f2cSmrgifelse([$1],[], 46689bd41f2cSmrg[# ### END LIBTOOL CONFIG], 46699bd41f2cSmrg[# ### END LIBTOOL TAG CONFIG: $tagname]) 46709bd41f2cSmrg 46719bd41f2cSmrg__EOF__ 46729bd41f2cSmrg 46739bd41f2cSmrgifelse([$1],[], [ 46749bd41f2cSmrg case $host_os in 46759bd41f2cSmrg aix3*) 46769bd41f2cSmrg cat <<\EOF >> "$cfgfile" 46779bd41f2cSmrg 46789bd41f2cSmrg# AIX sometimes has problems with the GCC collect2 program. For some 46799bd41f2cSmrg# reason, if we set the COLLECT_NAMES environment variable, the problems 46809bd41f2cSmrg# vanish in a puff of smoke. 46819bd41f2cSmrgif test "X${COLLECT_NAMES+set}" != Xset; then 46829bd41f2cSmrg COLLECT_NAMES= 46839bd41f2cSmrg export COLLECT_NAMES 46849bd41f2cSmrgfi 46859bd41f2cSmrgEOF 46869bd41f2cSmrg ;; 46879bd41f2cSmrg esac 46889bd41f2cSmrg 46899bd41f2cSmrg # We use sed instead of cat because bash on DJGPP gets confused if 46909bd41f2cSmrg # if finds mixed CR/LF and LF-only lines. Since sed operates in 46919bd41f2cSmrg # text mode, it properly converts lines to CR/LF. This bash problem 46929bd41f2cSmrg # is reportedly fixed, but why not run on old versions too? 46939bd41f2cSmrg sed '$q' "$ltmain" >> "$cfgfile" || (rm -f "$cfgfile"; exit 1) 46949bd41f2cSmrg 46959bd41f2cSmrg mv -f "$cfgfile" "$ofile" || \ 46969bd41f2cSmrg (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") 46979bd41f2cSmrg chmod +x "$ofile" 46989bd41f2cSmrg]) 46999bd41f2cSmrgelse 47009bd41f2cSmrg # If there is no Makefile yet, we rely on a make rule to execute 47019bd41f2cSmrg # `config.status --recheck' to rerun these tests and create the 47029bd41f2cSmrg # libtool script then. 47039bd41f2cSmrg ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'` 47049bd41f2cSmrg if test -f "$ltmain_in"; then 47059bd41f2cSmrg test -f Makefile && make "$ltmain" 47069bd41f2cSmrg fi 47079bd41f2cSmrgfi 47089bd41f2cSmrg])# AC_LIBTOOL_CONFIG 47099bd41f2cSmrg 47109bd41f2cSmrg 47119bd41f2cSmrg# AC_LIBTOOL_PROG_COMPILER_NO_RTTI([TAGNAME]) 47129bd41f2cSmrg# ------------------------------------------- 47139bd41f2cSmrgAC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], 47149bd41f2cSmrg[AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl 47159bd41f2cSmrg 47169bd41f2cSmrg_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= 47179bd41f2cSmrg 47189bd41f2cSmrgif test "$GCC" = yes; then 47199bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' 47209bd41f2cSmrg 47219bd41f2cSmrg AC_LIBTOOL_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions], 47229bd41f2cSmrg lt_cv_prog_compiler_rtti_exceptions, 47239bd41f2cSmrg [-fno-rtti -fno-exceptions], [], 47249bd41f2cSmrg [_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"]) 47259bd41f2cSmrgfi 47269bd41f2cSmrg])# AC_LIBTOOL_PROG_COMPILER_NO_RTTI 47279bd41f2cSmrg 47289bd41f2cSmrg 47299bd41f2cSmrg# AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE 47309bd41f2cSmrg# --------------------------------- 47319bd41f2cSmrgAC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], 47329bd41f2cSmrg[AC_REQUIRE([AC_CANONICAL_HOST]) 47339bd41f2cSmrgAC_REQUIRE([LT_AC_PROG_SED]) 47349bd41f2cSmrgAC_REQUIRE([AC_PROG_NM]) 47359bd41f2cSmrgAC_REQUIRE([AC_OBJEXT]) 47369bd41f2cSmrg# Check for command to grab the raw symbol name followed by C symbol from nm. 47379bd41f2cSmrgAC_MSG_CHECKING([command to parse $NM output from $compiler object]) 47389bd41f2cSmrgAC_CACHE_VAL([lt_cv_sys_global_symbol_pipe], 47399bd41f2cSmrg[ 47409bd41f2cSmrg# These are sane defaults that work on at least a few old systems. 47419bd41f2cSmrg# [They come from Ultrix. What could be older than Ultrix?!! ;)] 47429bd41f2cSmrg 47439bd41f2cSmrg# Character class describing NM global symbol codes. 47449bd41f2cSmrgsymcode='[[BCDEGRST]]' 47459bd41f2cSmrg 47469bd41f2cSmrg# Regexp to match symbols that can be accessed directly from C. 47479bd41f2cSmrgsympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)' 47489bd41f2cSmrg 47499bd41f2cSmrg# Transform an extracted symbol line into a proper C declaration 47509bd41f2cSmrglt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern int \1;/p'" 47519bd41f2cSmrg 47529bd41f2cSmrg# Transform an extracted symbol line into symbol name and symbol address 47539bd41f2cSmrglt_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'" 47549bd41f2cSmrg 47559bd41f2cSmrg# Define system-specific variables. 47569bd41f2cSmrgcase $host_os in 47579bd41f2cSmrgaix*) 47589bd41f2cSmrg symcode='[[BCDT]]' 47599bd41f2cSmrg ;; 47609bd41f2cSmrgcygwin* | mingw* | pw32*) 47619bd41f2cSmrg symcode='[[ABCDGISTW]]' 47629bd41f2cSmrg ;; 47639bd41f2cSmrghpux*) # Its linker distinguishes data from code symbols 47649bd41f2cSmrg if test "$host_cpu" = ia64; then 47659bd41f2cSmrg symcode='[[ABCDEGRST]]' 47669bd41f2cSmrg fi 47679bd41f2cSmrg lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" 47689bd41f2cSmrg 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'" 47699bd41f2cSmrg ;; 47709bd41f2cSmrglinux* | k*bsd*-gnu) 47719bd41f2cSmrg if test "$host_cpu" = ia64; then 47729bd41f2cSmrg symcode='[[ABCDGIRSTW]]' 47739bd41f2cSmrg lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" 47749bd41f2cSmrg 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'" 47759bd41f2cSmrg fi 47769bd41f2cSmrg ;; 47779bd41f2cSmrgirix* | nonstopux*) 47789bd41f2cSmrg symcode='[[BCDEGRST]]' 47799bd41f2cSmrg ;; 47809bd41f2cSmrgosf*) 47819bd41f2cSmrg symcode='[[BCDEGQRST]]' 47829bd41f2cSmrg ;; 47839bd41f2cSmrgsolaris*) 47849bd41f2cSmrg symcode='[[BDRT]]' 47859bd41f2cSmrg ;; 47869bd41f2cSmrgsco3.2v5*) 47879bd41f2cSmrg symcode='[[DT]]' 47889bd41f2cSmrg ;; 47899bd41f2cSmrgsysv4.2uw2*) 47909bd41f2cSmrg symcode='[[DT]]' 47919bd41f2cSmrg ;; 47929bd41f2cSmrgsysv5* | sco5v6* | unixware* | OpenUNIX*) 47939bd41f2cSmrg symcode='[[ABDT]]' 47949bd41f2cSmrg ;; 47959bd41f2cSmrgsysv4) 47969bd41f2cSmrg symcode='[[DFNSTU]]' 47979bd41f2cSmrg ;; 47989bd41f2cSmrgesac 47999bd41f2cSmrg 48009bd41f2cSmrg# Handle CRLF in mingw tool chain 48019bd41f2cSmrgopt_cr= 48029bd41f2cSmrgcase $build_os in 48039bd41f2cSmrgmingw*) 48049bd41f2cSmrg opt_cr=`echo 'x\{0,1\}' | tr x '\015'` # option cr in regexp 48059bd41f2cSmrg ;; 48069bd41f2cSmrgesac 48079bd41f2cSmrg 48089bd41f2cSmrg# If we're using GNU nm, then use its standard symbol codes. 48099bd41f2cSmrgcase `$NM -V 2>&1` in 48109bd41f2cSmrg*GNU* | *'with BFD'*) 48119bd41f2cSmrg symcode='[[ABCDGIRSTW]]' ;; 48129bd41f2cSmrgesac 48139bd41f2cSmrg 48149bd41f2cSmrg# Try without a prefix undercore, then with it. 48159bd41f2cSmrgfor ac_symprfx in "" "_"; do 48169bd41f2cSmrg 48179bd41f2cSmrg # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. 48189bd41f2cSmrg symxfrm="\\1 $ac_symprfx\\2 \\2" 48199bd41f2cSmrg 48209bd41f2cSmrg # Write the raw and C identifiers. 48219bd41f2cSmrg lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" 48229bd41f2cSmrg 48239bd41f2cSmrg # Check to see that the pipe works correctly. 48249bd41f2cSmrg pipe_works=no 48259bd41f2cSmrg 48269bd41f2cSmrg rm -f conftest* 48279bd41f2cSmrg cat > conftest.$ac_ext <<EOF 48289bd41f2cSmrg#ifdef __cplusplus 48299bd41f2cSmrgextern "C" { 48309bd41f2cSmrg#endif 48319bd41f2cSmrgchar nm_test_var; 48329bd41f2cSmrgvoid nm_test_func(){} 48339bd41f2cSmrg#ifdef __cplusplus 48349bd41f2cSmrg} 48359bd41f2cSmrg#endif 48369bd41f2cSmrgint main(){nm_test_var='a';nm_test_func();return(0);} 48379bd41f2cSmrgEOF 48389bd41f2cSmrg 48399bd41f2cSmrg if AC_TRY_EVAL(ac_compile); then 48409bd41f2cSmrg # Now try to grab the symbols. 48419bd41f2cSmrg nlist=conftest.nm 48429bd41f2cSmrg if AC_TRY_EVAL(NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) && test -s "$nlist"; then 48439bd41f2cSmrg # Try sorting and uniquifying the output. 48449bd41f2cSmrg if sort "$nlist" | uniq > "$nlist"T; then 48459bd41f2cSmrg mv -f "$nlist"T "$nlist" 48469bd41f2cSmrg else 48479bd41f2cSmrg rm -f "$nlist"T 48489bd41f2cSmrg fi 48499bd41f2cSmrg 48509bd41f2cSmrg # Make sure that we snagged all the symbols we need. 48519bd41f2cSmrg if grep ' nm_test_var$' "$nlist" >/dev/null; then 48529bd41f2cSmrg if grep ' nm_test_func$' "$nlist" >/dev/null; then 48539bd41f2cSmrg cat <<EOF > conftest.$ac_ext 48549bd41f2cSmrg#ifdef __cplusplus 48559bd41f2cSmrgextern "C" { 48569bd41f2cSmrg#endif 48579bd41f2cSmrg 48589bd41f2cSmrgEOF 48599bd41f2cSmrg # Now generate the symbol file. 48609bd41f2cSmrg eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | grep -v main >> conftest.$ac_ext' 48619bd41f2cSmrg 48629bd41f2cSmrg cat <<EOF >> conftest.$ac_ext 48639bd41f2cSmrg#if defined (__STDC__) && __STDC__ 48649bd41f2cSmrg# define lt_ptr_t void * 48659bd41f2cSmrg#else 48669bd41f2cSmrg# define lt_ptr_t char * 48679bd41f2cSmrg# define const 48689bd41f2cSmrg#endif 48699bd41f2cSmrg 48709bd41f2cSmrg/* The mapping between symbol names and symbols. */ 48719bd41f2cSmrgconst struct { 48729bd41f2cSmrg const char *name; 48739bd41f2cSmrg lt_ptr_t address; 48749bd41f2cSmrg} 48759bd41f2cSmrglt_preloaded_symbols[[]] = 48769bd41f2cSmrg{ 48779bd41f2cSmrgEOF 48789bd41f2cSmrg $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (lt_ptr_t) \&\2},/" < "$nlist" | grep -v main >> conftest.$ac_ext 48799bd41f2cSmrg cat <<\EOF >> conftest.$ac_ext 48809bd41f2cSmrg {0, (lt_ptr_t) 0} 48819bd41f2cSmrg}; 48829bd41f2cSmrg 48839bd41f2cSmrg#ifdef __cplusplus 48849bd41f2cSmrg} 48859bd41f2cSmrg#endif 48869bd41f2cSmrgEOF 48879bd41f2cSmrg # Now try linking the two files. 48889bd41f2cSmrg mv conftest.$ac_objext conftstm.$ac_objext 48899bd41f2cSmrg lt_save_LIBS="$LIBS" 48909bd41f2cSmrg lt_save_CFLAGS="$CFLAGS" 48919bd41f2cSmrg LIBS="conftstm.$ac_objext" 48929bd41f2cSmrg CFLAGS="$CFLAGS$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)" 48939bd41f2cSmrg if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then 48949bd41f2cSmrg pipe_works=yes 48959bd41f2cSmrg fi 48969bd41f2cSmrg LIBS="$lt_save_LIBS" 48979bd41f2cSmrg CFLAGS="$lt_save_CFLAGS" 48989bd41f2cSmrg else 48999bd41f2cSmrg echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD 49009bd41f2cSmrg fi 49019bd41f2cSmrg else 49029bd41f2cSmrg echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD 49039bd41f2cSmrg fi 49049bd41f2cSmrg else 49059bd41f2cSmrg echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD 49069bd41f2cSmrg fi 49079bd41f2cSmrg else 49089bd41f2cSmrg echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD 49099bd41f2cSmrg cat conftest.$ac_ext >&5 49109bd41f2cSmrg fi 49119bd41f2cSmrg rm -f conftest* conftst* 49129bd41f2cSmrg 49139bd41f2cSmrg # Do not use the global_symbol_pipe unless it works. 49149bd41f2cSmrg if test "$pipe_works" = yes; then 49159bd41f2cSmrg break 49169bd41f2cSmrg else 49179bd41f2cSmrg lt_cv_sys_global_symbol_pipe= 49189bd41f2cSmrg fi 49199bd41f2cSmrgdone 49209bd41f2cSmrg]) 49219bd41f2cSmrgif test -z "$lt_cv_sys_global_symbol_pipe"; then 49229bd41f2cSmrg lt_cv_sys_global_symbol_to_cdecl= 49239bd41f2cSmrgfi 49249bd41f2cSmrgif test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then 49259bd41f2cSmrg AC_MSG_RESULT(failed) 49269bd41f2cSmrgelse 49279bd41f2cSmrg AC_MSG_RESULT(ok) 49289bd41f2cSmrgfi 49299bd41f2cSmrg]) # AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE 49309bd41f2cSmrg 49319bd41f2cSmrg 49329bd41f2cSmrg# AC_LIBTOOL_PROG_COMPILER_PIC([TAGNAME]) 49339bd41f2cSmrg# --------------------------------------- 49349bd41f2cSmrgAC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC], 49359bd41f2cSmrg[_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)= 49369bd41f2cSmrg_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= 49379bd41f2cSmrg_LT_AC_TAGVAR(lt_prog_compiler_static, $1)= 49389bd41f2cSmrg 49399bd41f2cSmrgAC_MSG_CHECKING([for $compiler option to produce PIC]) 49409bd41f2cSmrg ifelse([$1],[CXX],[ 49419bd41f2cSmrg # C++ specific cases for pic, static, wl, etc. 49429bd41f2cSmrg if test "$GXX" = yes; then 49439bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 49449bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static' 49459bd41f2cSmrg 49469bd41f2cSmrg case $host_os in 49479bd41f2cSmrg aix*) 49489bd41f2cSmrg # All AIX code is PIC. 49499bd41f2cSmrg if test "$host_cpu" = ia64; then 49509bd41f2cSmrg # AIX 5 now supports IA64 processor 49519bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 49529bd41f2cSmrg fi 49539bd41f2cSmrg ;; 49549bd41f2cSmrg amigaos*) 49559bd41f2cSmrg # FIXME: we need at least 68020 code to build shared libraries, but 49569bd41f2cSmrg # adding the `-m68020' flag to GCC prevents building anything better, 49579bd41f2cSmrg # like `-m68040'. 49589bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' 49599bd41f2cSmrg ;; 49609bd41f2cSmrg beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) 49619bd41f2cSmrg # PIC is the default for these OSes. 49629bd41f2cSmrg ;; 49639bd41f2cSmrg mingw* | cygwin* | os2* | pw32*) 49649bd41f2cSmrg # This hack is so that the source file can tell whether it is being 49659bd41f2cSmrg # built for inclusion in a dll (and should export symbols for example). 49669bd41f2cSmrg # Although the cygwin gcc ignores -fPIC, still need this for old-style 49679bd41f2cSmrg # (--disable-auto-import) libraries 49689bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT' 49699bd41f2cSmrg ;; 49709bd41f2cSmrg darwin* | rhapsody*) 49719bd41f2cSmrg # PIC is the default on this platform 49729bd41f2cSmrg # Common symbols not allowed in MH_DYLIB files 49739bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' 49749bd41f2cSmrg ;; 49759bd41f2cSmrg *djgpp*) 49769bd41f2cSmrg # DJGPP does not support shared libraries at all 49779bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= 49789bd41f2cSmrg ;; 49799bd41f2cSmrg interix[[3-9]]*) 49809bd41f2cSmrg # Interix 3.x gcc -fpic/-fPIC options generate broken code. 49819bd41f2cSmrg # Instead, we relocate shared libraries at runtime. 49829bd41f2cSmrg ;; 49839bd41f2cSmrg sysv4*MP*) 49849bd41f2cSmrg if test -d /usr/nec; then 49859bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic 49869bd41f2cSmrg fi 49879bd41f2cSmrg ;; 49889bd41f2cSmrg hpux*) 49899bd41f2cSmrg # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but 49909bd41f2cSmrg # not for PA HP-UX. 49919bd41f2cSmrg case $host_cpu in 49929bd41f2cSmrg hppa*64*|ia64*) 49939bd41f2cSmrg ;; 49949bd41f2cSmrg *) 49959bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 49969bd41f2cSmrg ;; 49979bd41f2cSmrg esac 49989bd41f2cSmrg ;; 49999bd41f2cSmrg *) 50009bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 50019bd41f2cSmrg ;; 50029bd41f2cSmrg esac 50039bd41f2cSmrg else 50049bd41f2cSmrg case $host_os in 50059bd41f2cSmrg aix4* | aix5*) 50069bd41f2cSmrg # All AIX code is PIC. 50079bd41f2cSmrg if test "$host_cpu" = ia64; then 50089bd41f2cSmrg # AIX 5 now supports IA64 processor 50099bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 50109bd41f2cSmrg else 50119bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' 50129bd41f2cSmrg fi 50139bd41f2cSmrg ;; 50149bd41f2cSmrg chorus*) 50159bd41f2cSmrg case $cc_basename in 50169bd41f2cSmrg cxch68*) 50179bd41f2cSmrg # Green Hills C++ Compiler 50189bd41f2cSmrg # _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" 50199bd41f2cSmrg ;; 50209bd41f2cSmrg esac 50219bd41f2cSmrg ;; 50229bd41f2cSmrg darwin*) 50239bd41f2cSmrg # PIC is the default on this platform 50249bd41f2cSmrg # Common symbols not allowed in MH_DYLIB files 50259bd41f2cSmrg case $cc_basename in 50269bd41f2cSmrg xlc*) 50279bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-qnocommon' 50289bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 50299bd41f2cSmrg ;; 50309bd41f2cSmrg esac 50319bd41f2cSmrg ;; 50329bd41f2cSmrg dgux*) 50339bd41f2cSmrg case $cc_basename in 50349bd41f2cSmrg ec++*) 50359bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 50369bd41f2cSmrg ;; 50379bd41f2cSmrg ghcx*) 50389bd41f2cSmrg # Green Hills C++ Compiler 50399bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 50409bd41f2cSmrg ;; 50419bd41f2cSmrg *) 50429bd41f2cSmrg ;; 50439bd41f2cSmrg esac 50449bd41f2cSmrg ;; 50459bd41f2cSmrg freebsd* | dragonfly*) 50469bd41f2cSmrg # FreeBSD uses GNU C++ 50479bd41f2cSmrg ;; 50489bd41f2cSmrg hpux9* | hpux10* | hpux11*) 50499bd41f2cSmrg case $cc_basename in 50509bd41f2cSmrg CC*) 50519bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 50529bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' 50539bd41f2cSmrg if test "$host_cpu" != ia64; then 50549bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z' 50559bd41f2cSmrg fi 50569bd41f2cSmrg ;; 50579bd41f2cSmrg aCC*) 50589bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 50599bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' 50609bd41f2cSmrg case $host_cpu in 50619bd41f2cSmrg hppa*64*|ia64*) 50629bd41f2cSmrg # +Z the default 50639bd41f2cSmrg ;; 50649bd41f2cSmrg *) 50659bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z' 50669bd41f2cSmrg ;; 50679bd41f2cSmrg esac 50689bd41f2cSmrg ;; 50699bd41f2cSmrg *) 50709bd41f2cSmrg ;; 50719bd41f2cSmrg esac 50729bd41f2cSmrg ;; 50739bd41f2cSmrg interix*) 50749bd41f2cSmrg # This is c89, which is MS Visual C++ (no shared libs) 50759bd41f2cSmrg # Anyone wants to do a port? 50769bd41f2cSmrg ;; 50779bd41f2cSmrg irix5* | irix6* | nonstopux*) 50789bd41f2cSmrg case $cc_basename in 50799bd41f2cSmrg CC*) 50809bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 50819bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 50829bd41f2cSmrg # CC pic flag -KPIC is the default. 50839bd41f2cSmrg ;; 50849bd41f2cSmrg *) 50859bd41f2cSmrg ;; 50869bd41f2cSmrg esac 50879bd41f2cSmrg ;; 50889bd41f2cSmrg linux* | k*bsd*-gnu) 50899bd41f2cSmrg case $cc_basename in 50909bd41f2cSmrg KCC*) 50919bd41f2cSmrg # KAI C++ Compiler 50929bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' 50939bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 50949bd41f2cSmrg ;; 50959bd41f2cSmrg icpc* | ecpc*) 50969bd41f2cSmrg # Intel C++ 50979bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 50989bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 50999bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static' 51009bd41f2cSmrg ;; 51019bd41f2cSmrg pgCC*) 51029bd41f2cSmrg # Portland Group C++ compiler. 51039bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 51049bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' 51059bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 51069bd41f2cSmrg ;; 51079bd41f2cSmrg cxx*) 51089bd41f2cSmrg # Compaq C++ 51099bd41f2cSmrg # Make sure the PIC flag is empty. It appears that all Alpha 51109bd41f2cSmrg # Linux and Compaq Tru64 Unix objects are PIC. 51119bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= 51129bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 51139bd41f2cSmrg ;; 51149bd41f2cSmrg *) 51159bd41f2cSmrg case `$CC -V 2>&1 | sed 5q` in 51169bd41f2cSmrg *Sun\ C*) 51179bd41f2cSmrg # Sun C++ 5.9 51189bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 51199bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 51209bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' 51219bd41f2cSmrg ;; 51229bd41f2cSmrg esac 51239bd41f2cSmrg ;; 51249bd41f2cSmrg esac 51259bd41f2cSmrg ;; 51269bd41f2cSmrg lynxos*) 51279bd41f2cSmrg ;; 51289bd41f2cSmrg m88k*) 51299bd41f2cSmrg ;; 51309bd41f2cSmrg mvs*) 51319bd41f2cSmrg case $cc_basename in 51329bd41f2cSmrg cxx*) 51339bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall' 51349bd41f2cSmrg ;; 51359bd41f2cSmrg *) 51369bd41f2cSmrg ;; 51379bd41f2cSmrg esac 51389bd41f2cSmrg ;; 51399bd41f2cSmrg netbsd*) 51409bd41f2cSmrg ;; 51419bd41f2cSmrg osf3* | osf4* | osf5*) 51429bd41f2cSmrg case $cc_basename in 51439bd41f2cSmrg KCC*) 51449bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' 51459bd41f2cSmrg ;; 51469bd41f2cSmrg RCC*) 51479bd41f2cSmrg # Rational C++ 2.4.1 51489bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 51499bd41f2cSmrg ;; 51509bd41f2cSmrg cxx*) 51519bd41f2cSmrg # Digital/Compaq C++ 51529bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 51539bd41f2cSmrg # Make sure the PIC flag is empty. It appears that all Alpha 51549bd41f2cSmrg # Linux and Compaq Tru64 Unix objects are PIC. 51559bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= 51569bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 51579bd41f2cSmrg ;; 51589bd41f2cSmrg *) 51599bd41f2cSmrg ;; 51609bd41f2cSmrg esac 51619bd41f2cSmrg ;; 51629bd41f2cSmrg psos*) 51639bd41f2cSmrg ;; 51649bd41f2cSmrg solaris*) 51659bd41f2cSmrg case $cc_basename in 51669bd41f2cSmrg CC*) 51679bd41f2cSmrg # Sun C++ 4.2, 5.x and Centerline C++ 51689bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 51699bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 51709bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' 51719bd41f2cSmrg ;; 51729bd41f2cSmrg gcx*) 51739bd41f2cSmrg # Green Hills C++ Compiler 51749bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' 51759bd41f2cSmrg ;; 51769bd41f2cSmrg *) 51779bd41f2cSmrg ;; 51789bd41f2cSmrg esac 51799bd41f2cSmrg ;; 51809bd41f2cSmrg sunos4*) 51819bd41f2cSmrg case $cc_basename in 51829bd41f2cSmrg CC*) 51839bd41f2cSmrg # Sun C++ 4.x 51849bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 51859bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 51869bd41f2cSmrg ;; 51879bd41f2cSmrg lcc*) 51889bd41f2cSmrg # Lucid 51899bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 51909bd41f2cSmrg ;; 51919bd41f2cSmrg *) 51929bd41f2cSmrg ;; 51939bd41f2cSmrg esac 51949bd41f2cSmrg ;; 51959bd41f2cSmrg tandem*) 51969bd41f2cSmrg case $cc_basename in 51979bd41f2cSmrg NCC*) 51989bd41f2cSmrg # NonStop-UX NCC 3.20 51999bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 52009bd41f2cSmrg ;; 52019bd41f2cSmrg *) 52029bd41f2cSmrg ;; 52039bd41f2cSmrg esac 52049bd41f2cSmrg ;; 52059bd41f2cSmrg sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) 52069bd41f2cSmrg case $cc_basename in 52079bd41f2cSmrg CC*) 52089bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 52099bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 52109bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 52119bd41f2cSmrg ;; 52129bd41f2cSmrg esac 52139bd41f2cSmrg ;; 52149bd41f2cSmrg vxworks*) 52159bd41f2cSmrg ;; 52169bd41f2cSmrg *) 52179bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 52189bd41f2cSmrg ;; 52199bd41f2cSmrg esac 52209bd41f2cSmrg fi 52219bd41f2cSmrg], 52229bd41f2cSmrg[ 52239bd41f2cSmrg if test "$GCC" = yes; then 52249bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 52259bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static' 52269bd41f2cSmrg 52279bd41f2cSmrg case $host_os in 52289bd41f2cSmrg aix*) 52299bd41f2cSmrg # All AIX code is PIC. 52309bd41f2cSmrg if test "$host_cpu" = ia64; then 52319bd41f2cSmrg # AIX 5 now supports IA64 processor 52329bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 52339bd41f2cSmrg fi 52349bd41f2cSmrg ;; 52359bd41f2cSmrg 52369bd41f2cSmrg amigaos*) 52379bd41f2cSmrg # FIXME: we need at least 68020 code to build shared libraries, but 52389bd41f2cSmrg # adding the `-m68020' flag to GCC prevents building anything better, 52399bd41f2cSmrg # like `-m68040'. 52409bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' 52419bd41f2cSmrg ;; 52429bd41f2cSmrg 52439bd41f2cSmrg beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) 52449bd41f2cSmrg # PIC is the default for these OSes. 52459bd41f2cSmrg ;; 52469bd41f2cSmrg 52479bd41f2cSmrg mingw* | cygwin* | pw32* | os2*) 52489bd41f2cSmrg # This hack is so that the source file can tell whether it is being 52499bd41f2cSmrg # built for inclusion in a dll (and should export symbols for example). 52509bd41f2cSmrg # Although the cygwin gcc ignores -fPIC, still need this for old-style 52519bd41f2cSmrg # (--disable-auto-import) libraries 52529bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT' 52539bd41f2cSmrg ;; 52549bd41f2cSmrg 52559bd41f2cSmrg darwin* | rhapsody*) 52569bd41f2cSmrg # PIC is the default on this platform 52579bd41f2cSmrg # Common symbols not allowed in MH_DYLIB files 52589bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' 52599bd41f2cSmrg ;; 52609bd41f2cSmrg 52619bd41f2cSmrg interix[[3-9]]*) 52629bd41f2cSmrg # Interix 3.x gcc -fpic/-fPIC options generate broken code. 52639bd41f2cSmrg # Instead, we relocate shared libraries at runtime. 52649bd41f2cSmrg ;; 52659bd41f2cSmrg 52669bd41f2cSmrg msdosdjgpp*) 52679bd41f2cSmrg # Just because we use GCC doesn't mean we suddenly get shared libraries 52689bd41f2cSmrg # on systems that don't support them. 52699bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 52709bd41f2cSmrg enable_shared=no 52719bd41f2cSmrg ;; 52729bd41f2cSmrg 52739bd41f2cSmrg sysv4*MP*) 52749bd41f2cSmrg if test -d /usr/nec; then 52759bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic 52769bd41f2cSmrg fi 52779bd41f2cSmrg ;; 52789bd41f2cSmrg 52799bd41f2cSmrg hpux*) 52809bd41f2cSmrg # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but 52819bd41f2cSmrg # not for PA HP-UX. 52829bd41f2cSmrg case $host_cpu in 52839bd41f2cSmrg hppa*64*|ia64*) 52849bd41f2cSmrg # +Z the default 52859bd41f2cSmrg ;; 52869bd41f2cSmrg *) 52879bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 52889bd41f2cSmrg ;; 52899bd41f2cSmrg esac 52909bd41f2cSmrg ;; 52919bd41f2cSmrg 52929bd41f2cSmrg *) 52939bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 52949bd41f2cSmrg ;; 52959bd41f2cSmrg esac 52969bd41f2cSmrg else 52979bd41f2cSmrg # PORTME Check for flag to pass linker flags through the system compiler. 52989bd41f2cSmrg case $host_os in 52999bd41f2cSmrg aix*) 53009bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 53019bd41f2cSmrg if test "$host_cpu" = ia64; then 53029bd41f2cSmrg # AIX 5 now supports IA64 processor 53039bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 53049bd41f2cSmrg else 53059bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' 53069bd41f2cSmrg fi 53079bd41f2cSmrg ;; 53089bd41f2cSmrg darwin*) 53099bd41f2cSmrg # PIC is the default on this platform 53109bd41f2cSmrg # Common symbols not allowed in MH_DYLIB files 53119bd41f2cSmrg case $cc_basename in 53129bd41f2cSmrg xlc*) 53139bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-qnocommon' 53149bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 53159bd41f2cSmrg ;; 53169bd41f2cSmrg esac 53179bd41f2cSmrg ;; 53189bd41f2cSmrg 53199bd41f2cSmrg mingw* | cygwin* | pw32* | os2*) 53209bd41f2cSmrg # This hack is so that the source file can tell whether it is being 53219bd41f2cSmrg # built for inclusion in a dll (and should export symbols for example). 53229bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT' 53239bd41f2cSmrg ;; 53249bd41f2cSmrg 53259bd41f2cSmrg hpux9* | hpux10* | hpux11*) 53269bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 53279bd41f2cSmrg # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but 53289bd41f2cSmrg # not for PA HP-UX. 53299bd41f2cSmrg case $host_cpu in 53309bd41f2cSmrg hppa*64*|ia64*) 53319bd41f2cSmrg # +Z the default 53329bd41f2cSmrg ;; 53339bd41f2cSmrg *) 53349bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z' 53359bd41f2cSmrg ;; 53369bd41f2cSmrg esac 53379bd41f2cSmrg # Is there a better lt_prog_compiler_static that works with the bundled CC? 53389bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' 53399bd41f2cSmrg ;; 53409bd41f2cSmrg 53419bd41f2cSmrg irix5* | irix6* | nonstopux*) 53429bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 53439bd41f2cSmrg # PIC (with -KPIC) is the default. 53449bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 53459bd41f2cSmrg ;; 53469bd41f2cSmrg 53479bd41f2cSmrg newsos6) 53489bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 53499bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 53509bd41f2cSmrg ;; 53519bd41f2cSmrg 53529bd41f2cSmrg linux* | k*bsd*-gnu) 53539bd41f2cSmrg case $cc_basename in 53549bd41f2cSmrg icc* | ecc*) 53559bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 53569bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 53579bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static' 53589bd41f2cSmrg ;; 53599bd41f2cSmrg pgcc* | pgf77* | pgf90* | pgf95*) 53609bd41f2cSmrg # Portland Group compilers (*not* the Pentium gcc compiler, 53619bd41f2cSmrg # which looks to be a dead project) 53629bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 53639bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' 53649bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 53659bd41f2cSmrg ;; 53669bd41f2cSmrg ccc*) 53679bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 53689bd41f2cSmrg # All Alpha code is PIC. 53699bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 53709bd41f2cSmrg ;; 53719bd41f2cSmrg *) 53729bd41f2cSmrg case `$CC -V 2>&1 | sed 5q` in 53739bd41f2cSmrg *Sun\ C*) 53749bd41f2cSmrg # Sun C 5.9 53759bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 53769bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 53779bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 53789bd41f2cSmrg ;; 53799bd41f2cSmrg *Sun\ F*) 53809bd41f2cSmrg # Sun Fortran 8.3 passes all unrecognized flags to the linker 53819bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 53829bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 53839bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='' 53849bd41f2cSmrg ;; 53859bd41f2cSmrg esac 53869bd41f2cSmrg ;; 53879bd41f2cSmrg esac 53889bd41f2cSmrg ;; 53899bd41f2cSmrg 53909bd41f2cSmrg osf3* | osf4* | osf5*) 53919bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 53929bd41f2cSmrg # All OSF/1 code is PIC. 53939bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 53949bd41f2cSmrg ;; 53959bd41f2cSmrg 53969bd41f2cSmrg rdos*) 53979bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 53989bd41f2cSmrg ;; 53999bd41f2cSmrg 54009bd41f2cSmrg solaris*) 54019bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 54029bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 54039bd41f2cSmrg case $cc_basename in 54049bd41f2cSmrg f77* | f90* | f95*) 54059bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';; 54069bd41f2cSmrg *) 54079bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';; 54089bd41f2cSmrg esac 54099bd41f2cSmrg ;; 54109bd41f2cSmrg 54119bd41f2cSmrg sunos4*) 54129bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' 54139bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' 54149bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 54159bd41f2cSmrg ;; 54169bd41f2cSmrg 54179bd41f2cSmrg sysv4 | sysv4.2uw2* | sysv4.3*) 54189bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 54199bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 54209bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 54219bd41f2cSmrg ;; 54229bd41f2cSmrg 54239bd41f2cSmrg sysv4*MP*) 54249bd41f2cSmrg if test -d /usr/nec ;then 54259bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic' 54269bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 54279bd41f2cSmrg fi 54289bd41f2cSmrg ;; 54299bd41f2cSmrg 54309bd41f2cSmrg sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) 54319bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 54329bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 54339bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 54349bd41f2cSmrg ;; 54359bd41f2cSmrg 54369bd41f2cSmrg unicos*) 54379bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 54389bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 54399bd41f2cSmrg ;; 54409bd41f2cSmrg 54419bd41f2cSmrg uts4*) 54429bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 54439bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 54449bd41f2cSmrg ;; 54459bd41f2cSmrg 54469bd41f2cSmrg *) 54479bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 54489bd41f2cSmrg ;; 54499bd41f2cSmrg esac 54509bd41f2cSmrg fi 54519bd41f2cSmrg]) 54529bd41f2cSmrgAC_MSG_RESULT([$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)]) 54539bd41f2cSmrg 54549bd41f2cSmrg# 54559bd41f2cSmrg# Check to make sure the PIC flag actually works. 54569bd41f2cSmrg# 54579bd41f2cSmrgif test -n "$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)"; then 54589bd41f2cSmrg AC_LIBTOOL_COMPILER_OPTION([if $compiler PIC flag $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) works], 54599bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic_works, $1), 54609bd41f2cSmrg [$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])], [], 54619bd41f2cSmrg [case $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) in 54629bd41f2cSmrg "" | " "*) ;; 54639bd41f2cSmrg *) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)" ;; 54649bd41f2cSmrg esac], 54659bd41f2cSmrg [_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= 54669bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no]) 54679bd41f2cSmrgfi 54689bd41f2cSmrgcase $host_os in 54699bd41f2cSmrg # For platforms which do not support PIC, -DPIC is meaningless: 54709bd41f2cSmrg *djgpp*) 54719bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= 54729bd41f2cSmrg ;; 54739bd41f2cSmrg *) 54749bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])" 54759bd41f2cSmrg ;; 54769bd41f2cSmrgesac 54779bd41f2cSmrg 54789bd41f2cSmrg# 54799bd41f2cSmrg# Check to make sure the static flag actually works. 54809bd41f2cSmrg# 54819bd41f2cSmrgwl=$_LT_AC_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_AC_TAGVAR(lt_prog_compiler_static, $1)\" 54829bd41f2cSmrgAC_LIBTOOL_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works], 54839bd41f2cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static_works, $1), 54849bd41f2cSmrg $lt_tmp_static_flag, 54859bd41f2cSmrg [], 54869bd41f2cSmrg [_LT_AC_TAGVAR(lt_prog_compiler_static, $1)=]) 54879bd41f2cSmrg]) 54889bd41f2cSmrg 54899bd41f2cSmrg 54909bd41f2cSmrg# AC_LIBTOOL_PROG_LD_SHLIBS([TAGNAME]) 54919bd41f2cSmrg# ------------------------------------ 54929bd41f2cSmrg# See if the linker supports building shared libraries. 54939bd41f2cSmrgAC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS], 54949bd41f2cSmrg[AC_REQUIRE([LT_AC_PROG_SED])dnl 54959bd41f2cSmrgAC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) 54969bd41f2cSmrgifelse([$1],[CXX],[ 54979bd41f2cSmrg _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' 54989bd41f2cSmrg case $host_os in 54999bd41f2cSmrg aix4* | aix5*) 55009bd41f2cSmrg # If we're using GNU nm, then we don't want the "-C" option. 55019bd41f2cSmrg # -C means demangle to AIX nm, but means don't demangle with GNU nm 55029bd41f2cSmrg if $NM -V 2>&1 | grep 'GNU' > /dev/null; then 55039bd41f2cSmrg _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' 55049bd41f2cSmrg else 55059bd41f2cSmrg _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' 55069bd41f2cSmrg fi 55079bd41f2cSmrg ;; 55089bd41f2cSmrg pw32*) 55099bd41f2cSmrg _LT_AC_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds" 55109bd41f2cSmrg ;; 55119bd41f2cSmrg cygwin* | mingw*) 55129bd41f2cSmrg _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;/^.*[[ ]]__nm__/s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols' 55139bd41f2cSmrg ;; 55149bd41f2cSmrg *) 55159bd41f2cSmrg _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' 55169bd41f2cSmrg ;; 55179bd41f2cSmrg esac 55189bd41f2cSmrg],[ 55199bd41f2cSmrg runpath_var= 55209bd41f2cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)= 55219bd41f2cSmrg _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no 55229bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)= 55239bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)= 55249bd41f2cSmrg _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)= 55259bd41f2cSmrg _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1)= 55269bd41f2cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)= 55279bd41f2cSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)= 55289bd41f2cSmrg _LT_AC_TAGVAR(thread_safe_flag_spec, $1)= 55299bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)= 55309bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= 55319bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)= 55329bd41f2cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=no 55339bd41f2cSmrg _LT_AC_TAGVAR(hardcode_minus_L, $1)=no 55349bd41f2cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported 55359bd41f2cSmrg _LT_AC_TAGVAR(link_all_deplibs, $1)=unknown 55369bd41f2cSmrg _LT_AC_TAGVAR(hardcode_automatic, $1)=no 55379bd41f2cSmrg _LT_AC_TAGVAR(module_cmds, $1)= 55389bd41f2cSmrg _LT_AC_TAGVAR(module_expsym_cmds, $1)= 55399bd41f2cSmrg _LT_AC_TAGVAR(always_export_symbols, $1)=no 55409bd41f2cSmrg _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' 55419bd41f2cSmrg # include_expsyms should be a list of space-separated symbols to be *always* 55429bd41f2cSmrg # included in the symbol list 55439bd41f2cSmrg _LT_AC_TAGVAR(include_expsyms, $1)= 55449bd41f2cSmrg # exclude_expsyms can be an extended regexp of symbols to exclude 55459bd41f2cSmrg # it will be wrapped by ` (' and `)$', so one must not match beginning or 55469bd41f2cSmrg # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', 55479bd41f2cSmrg # as well as any symbol that contains `d'. 55489bd41f2cSmrg _LT_AC_TAGVAR(exclude_expsyms, $1)="_GLOBAL_OFFSET_TABLE_" 55499bd41f2cSmrg # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out 55509bd41f2cSmrg # platforms (ab)use it in PIC code, but their linkers get confused if 55519bd41f2cSmrg # the symbol is explicitly referenced. Since portable code cannot 55529bd41f2cSmrg # rely on this symbol name, it's probably fine to never include it in 55539bd41f2cSmrg # preloaded symbol tables. 55549bd41f2cSmrg extract_expsyms_cmds= 55559bd41f2cSmrg # Just being paranoid about ensuring that cc_basename is set. 55569bd41f2cSmrg _LT_CC_BASENAME([$compiler]) 55579bd41f2cSmrg case $host_os in 55589bd41f2cSmrg cygwin* | mingw* | pw32*) 55599bd41f2cSmrg # FIXME: the MSVC++ port hasn't been tested in a loooong time 55609bd41f2cSmrg # When not using gcc, we currently assume that we are using 55619bd41f2cSmrg # Microsoft Visual C++. 55629bd41f2cSmrg if test "$GCC" != yes; then 55639bd41f2cSmrg with_gnu_ld=no 55649bd41f2cSmrg fi 55659bd41f2cSmrg ;; 55669bd41f2cSmrg interix*) 55679bd41f2cSmrg # we just hope/assume this is gcc and not c89 (= MSVC++) 55689bd41f2cSmrg with_gnu_ld=yes 55699bd41f2cSmrg ;; 55709bd41f2cSmrg openbsd*) 55719bd41f2cSmrg with_gnu_ld=no 55729bd41f2cSmrg ;; 55739bd41f2cSmrg esac 55749bd41f2cSmrg 55759bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=yes 55769bd41f2cSmrg if test "$with_gnu_ld" = yes; then 55779bd41f2cSmrg # If archive_cmds runs LD, not CC, wlarc should be empty 55789bd41f2cSmrg wlarc='${wl}' 55799bd41f2cSmrg 55809bd41f2cSmrg # Set some defaults for GNU ld with shared library support. These 55819bd41f2cSmrg # are reset later if shared libraries are not supported. Putting them 55829bd41f2cSmrg # here allows them to be overridden if necessary. 55839bd41f2cSmrg runpath_var=LD_RUN_PATH 55849bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir' 55859bd41f2cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 55869bd41f2cSmrg # ancient GNU ld didn't support --whole-archive et. al. 55879bd41f2cSmrg if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then 55889bd41f2cSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' 55899bd41f2cSmrg else 55909bd41f2cSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)= 55919bd41f2cSmrg fi 55929bd41f2cSmrg supports_anon_versioning=no 55939bd41f2cSmrg case `$LD -v 2>/dev/null` in 55949bd41f2cSmrg *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11 55959bd41f2cSmrg *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... 55969bd41f2cSmrg *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... 55979bd41f2cSmrg *\ 2.11.*) ;; # other 2.11 versions 55989bd41f2cSmrg *) supports_anon_versioning=yes ;; 55999bd41f2cSmrg esac 56009bd41f2cSmrg 56019bd41f2cSmrg # See if GNU ld supports shared libraries. 56029bd41f2cSmrg case $host_os in 56039bd41f2cSmrg aix3* | aix4* | aix5*) 56049bd41f2cSmrg # On AIX/PPC, the GNU linker is very broken 56059bd41f2cSmrg if test "$host_cpu" != ia64; then 56069bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 56079bd41f2cSmrg cat <<EOF 1>&2 56089bd41f2cSmrg 56099bd41f2cSmrg*** Warning: the GNU linker, at least up to release 2.9.1, is reported 56109bd41f2cSmrg*** to be unable to reliably create shared libraries on AIX. 56119bd41f2cSmrg*** Therefore, libtool is disabling shared libraries support. If you 56129bd41f2cSmrg*** really care for shared libraries, you may want to modify your PATH 56139bd41f2cSmrg*** so that a non-GNU linker is found, and then restart. 56149bd41f2cSmrg 56159bd41f2cSmrgEOF 56169bd41f2cSmrg fi 56179bd41f2cSmrg ;; 56189bd41f2cSmrg 56199bd41f2cSmrg amigaos*) 56209bd41f2cSmrg _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)' 56219bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 56229bd41f2cSmrg _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes 56239bd41f2cSmrg 56249bd41f2cSmrg # Samuel A. Falvo II <kc5tja@dolphin.openprojects.net> reports 56259bd41f2cSmrg # that the semantics of dynamic libraries on AmigaOS, at least up 56269bd41f2cSmrg # to version 4, is to share data among multiple programs linked 56279bd41f2cSmrg # with the same dynamic library. Since this doesn't match the 56289bd41f2cSmrg # behavior of shared libraries on other platforms, we can't use 56299bd41f2cSmrg # them. 56309bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 56319bd41f2cSmrg ;; 56329bd41f2cSmrg 56339bd41f2cSmrg beos*) 56349bd41f2cSmrg if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then 56359bd41f2cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported 56369bd41f2cSmrg # Joseph Beckenbach <jrb3@best.com> says some releases of gcc 56379bd41f2cSmrg # support --undefined. This deserves some investigation. FIXME 56389bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 56399bd41f2cSmrg else 56409bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 56419bd41f2cSmrg fi 56429bd41f2cSmrg ;; 56439bd41f2cSmrg 56449bd41f2cSmrg cygwin* | mingw* | pw32*) 56459bd41f2cSmrg # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, 56469bd41f2cSmrg # as there is no search path for DLLs. 56479bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 56489bd41f2cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported 56499bd41f2cSmrg _LT_AC_TAGVAR(always_export_symbols, $1)=no 56509bd41f2cSmrg _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 56519bd41f2cSmrg _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/'\'' -e '\''/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols' 56529bd41f2cSmrg 56539bd41f2cSmrg if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then 56549bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' 56559bd41f2cSmrg # If the export-symbols file already is a .def file (1st line 56569bd41f2cSmrg # is EXPORTS), use it as is; otherwise, prepend... 56579bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then 56589bd41f2cSmrg cp $export_symbols $output_objdir/$soname.def; 56599bd41f2cSmrg else 56609bd41f2cSmrg echo EXPORTS > $output_objdir/$soname.def; 56619bd41f2cSmrg cat $export_symbols >> $output_objdir/$soname.def; 56629bd41f2cSmrg fi~ 56639bd41f2cSmrg $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' 56649bd41f2cSmrg else 56659bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 56669bd41f2cSmrg fi 56679bd41f2cSmrg ;; 56689bd41f2cSmrg 56699bd41f2cSmrg interix[[3-9]]*) 56709bd41f2cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=no 56719bd41f2cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 56729bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 56739bd41f2cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 56749bd41f2cSmrg # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. 56759bd41f2cSmrg # Instead, shared libraries are loaded at an image base (0x10000000 by 56769bd41f2cSmrg # default) and relocated if they conflict, which is a slow very memory 56779bd41f2cSmrg # consuming and fragmenting process. To avoid this, we pick a random, 56789bd41f2cSmrg # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link 56799bd41f2cSmrg # time. Moving up from 0x10000000 also allows more sbrk(2) space. 56809bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' 56819bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' 56829bd41f2cSmrg ;; 56839bd41f2cSmrg 56849bd41f2cSmrg gnu* | linux* | k*bsd*-gnu) 56859bd41f2cSmrg if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then 56869bd41f2cSmrg tmp_addflag= 56879bd41f2cSmrg case $cc_basename,$host_cpu in 56889bd41f2cSmrg pgcc*) # Portland Group C compiler 56899bd41f2cSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' 56909bd41f2cSmrg tmp_addflag=' $pic_flag' 56919bd41f2cSmrg ;; 56929bd41f2cSmrg pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers 56939bd41f2cSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' 56949bd41f2cSmrg tmp_addflag=' $pic_flag -Mnomain' ;; 56959bd41f2cSmrg ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 56969bd41f2cSmrg tmp_addflag=' -i_dynamic' ;; 56979bd41f2cSmrg efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 56989bd41f2cSmrg tmp_addflag=' -i_dynamic -nofor_main' ;; 56999bd41f2cSmrg ifc* | ifort*) # Intel Fortran compiler 57009bd41f2cSmrg tmp_addflag=' -nofor_main' ;; 57019bd41f2cSmrg esac 57029bd41f2cSmrg case `$CC -V 2>&1 | sed 5q` in 57039bd41f2cSmrg *Sun\ C*) # Sun C 5.9 57049bd41f2cSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' 57059bd41f2cSmrg tmp_sharedflag='-G' ;; 57069bd41f2cSmrg *Sun\ F*) # Sun Fortran 8.3 57079bd41f2cSmrg tmp_sharedflag='-G' ;; 57089bd41f2cSmrg *) 57099bd41f2cSmrg tmp_sharedflag='-shared' ;; 57109bd41f2cSmrg esac 57119bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 57129bd41f2cSmrg 57139bd41f2cSmrg if test $supports_anon_versioning = yes; then 57149bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $output_objdir/$libname.ver~ 57159bd41f2cSmrg cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ 57169bd41f2cSmrg $echo "local: *; };" >> $output_objdir/$libname.ver~ 57179bd41f2cSmrg $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' 57189bd41f2cSmrg fi 57199bd41f2cSmrg else 57209bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 57219bd41f2cSmrg fi 57229bd41f2cSmrg ;; 57239bd41f2cSmrg 57249bd41f2cSmrg netbsd*) 57259bd41f2cSmrg if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then 57269bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' 57279bd41f2cSmrg wlarc= 57289bd41f2cSmrg else 57299bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 57309bd41f2cSmrg _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' 57319bd41f2cSmrg fi 57329bd41f2cSmrg ;; 57339bd41f2cSmrg 57349bd41f2cSmrg solaris*) 57359bd41f2cSmrg if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then 57369bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 57379bd41f2cSmrg cat <<EOF 1>&2 57389bd41f2cSmrg 57399bd41f2cSmrg*** Warning: The releases 2.8.* of the GNU linker cannot reliably 57409bd41f2cSmrg*** create shared libraries on Solaris systems. Therefore, libtool 57419bd41f2cSmrg*** is disabling shared libraries support. We urge you to upgrade GNU 57429bd41f2cSmrg*** binutils to release 2.9.1 or newer. Another option is to modify 57439bd41f2cSmrg*** your PATH or compiler configuration so that the native linker is 57449bd41f2cSmrg*** used, and then restart. 57459bd41f2cSmrg 57469bd41f2cSmrgEOF 57479bd41f2cSmrg elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then 57489bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 57499bd41f2cSmrg _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' 57509bd41f2cSmrg else 57519bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 57529bd41f2cSmrg fi 57539bd41f2cSmrg ;; 57549bd41f2cSmrg 57559bd41f2cSmrg sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) 57569bd41f2cSmrg case `$LD -v 2>&1` in 57579bd41f2cSmrg *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*) 57589bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 57599bd41f2cSmrg cat <<_LT_EOF 1>&2 57609bd41f2cSmrg 57619bd41f2cSmrg*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not 57629bd41f2cSmrg*** reliably create shared libraries on SCO systems. Therefore, libtool 57639bd41f2cSmrg*** is disabling shared libraries support. We urge you to upgrade GNU 57649bd41f2cSmrg*** binutils to release 2.16.91.0.3 or newer. Another option is to modify 57659bd41f2cSmrg*** your PATH or compiler configuration so that the native linker is 57669bd41f2cSmrg*** used, and then restart. 57679bd41f2cSmrg 57689bd41f2cSmrg_LT_EOF 57699bd41f2cSmrg ;; 57709bd41f2cSmrg *) 57719bd41f2cSmrg if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then 57729bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-rpath,$libdir`' 57739bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib' 57749bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname,-retain-symbols-file,$export_symbols -o $lib' 57759bd41f2cSmrg else 57769bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 57779bd41f2cSmrg fi 57789bd41f2cSmrg ;; 57799bd41f2cSmrg esac 57809bd41f2cSmrg ;; 57819bd41f2cSmrg 57829bd41f2cSmrg sunos4*) 57839bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' 57849bd41f2cSmrg wlarc= 57859bd41f2cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=yes 57869bd41f2cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 57879bd41f2cSmrg ;; 57889bd41f2cSmrg 57899bd41f2cSmrg *) 57909bd41f2cSmrg if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then 57919bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 57929bd41f2cSmrg _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' 57939bd41f2cSmrg else 57949bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 57959bd41f2cSmrg fi 57969bd41f2cSmrg ;; 57979bd41f2cSmrg esac 57989bd41f2cSmrg 57999bd41f2cSmrg if test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no; then 58009bd41f2cSmrg runpath_var= 58019bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)= 58029bd41f2cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)= 58039bd41f2cSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)= 58049bd41f2cSmrg fi 58059bd41f2cSmrg else 58069bd41f2cSmrg # PORTME fill in a description of your system's linker (not GNU ld) 58079bd41f2cSmrg case $host_os in 58089bd41f2cSmrg aix3*) 58099bd41f2cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported 58109bd41f2cSmrg _LT_AC_TAGVAR(always_export_symbols, $1)=yes 58119bd41f2cSmrg _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' 58129bd41f2cSmrg # Note: this linker hardcodes the directories in LIBPATH if there 58139bd41f2cSmrg # are no directories specified by -L. 58149bd41f2cSmrg _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes 58159bd41f2cSmrg if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then 58169bd41f2cSmrg # Neither direct hardcoding nor static linking is supported with a 58179bd41f2cSmrg # broken collect2. 58189bd41f2cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported 58199bd41f2cSmrg fi 58209bd41f2cSmrg ;; 58219bd41f2cSmrg 58229bd41f2cSmrg aix4* | aix5*) 58239bd41f2cSmrg if test "$host_cpu" = ia64; then 58249bd41f2cSmrg # On IA64, the linker does run time linking by default, so we don't 58259bd41f2cSmrg # have to do anything special. 58269bd41f2cSmrg aix_use_runtimelinking=no 58279bd41f2cSmrg exp_sym_flag='-Bexport' 58289bd41f2cSmrg no_entry_flag="" 58299bd41f2cSmrg else 58309bd41f2cSmrg # If we're using GNU nm, then we don't want the "-C" option. 58319bd41f2cSmrg # -C means demangle to AIX nm, but means don't demangle with GNU nm 58329bd41f2cSmrg if $NM -V 2>&1 | grep 'GNU' > /dev/null; then 58339bd41f2cSmrg _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' 58349bd41f2cSmrg else 58359bd41f2cSmrg _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' 58369bd41f2cSmrg fi 58379bd41f2cSmrg aix_use_runtimelinking=no 58389bd41f2cSmrg 58399bd41f2cSmrg # Test if we are trying to use run time linking or normal 58409bd41f2cSmrg # AIX style linking. If -brtl is somewhere in LDFLAGS, we 58419bd41f2cSmrg # need to do runtime linking. 58429bd41f2cSmrg case $host_os in aix4.[[23]]|aix4.[[23]].*|aix5*) 58439bd41f2cSmrg for ld_flag in $LDFLAGS; do 58449bd41f2cSmrg if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then 58459bd41f2cSmrg aix_use_runtimelinking=yes 58469bd41f2cSmrg break 58479bd41f2cSmrg fi 58489bd41f2cSmrg done 58499bd41f2cSmrg ;; 58509bd41f2cSmrg esac 58519bd41f2cSmrg 58529bd41f2cSmrg exp_sym_flag='-bexport' 58539bd41f2cSmrg no_entry_flag='-bnoentry' 58549bd41f2cSmrg fi 58559bd41f2cSmrg 58569bd41f2cSmrg # When large executables or shared objects are built, AIX ld can 58579bd41f2cSmrg # have problems creating the table of contents. If linking a library 58589bd41f2cSmrg # or program results in "error TOC overflow" add -mminimal-toc to 58599bd41f2cSmrg # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not 58609bd41f2cSmrg # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. 58619bd41f2cSmrg 58629bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='' 58639bd41f2cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=yes 58649bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':' 58659bd41f2cSmrg _LT_AC_TAGVAR(link_all_deplibs, $1)=yes 58669bd41f2cSmrg 58679bd41f2cSmrg if test "$GCC" = yes; then 58689bd41f2cSmrg case $host_os in aix4.[[012]]|aix4.[[012]].*) 58699bd41f2cSmrg # We only want to do this on AIX 4.2 and lower, the check 58709bd41f2cSmrg # below for broken collect2 doesn't work under 4.3+ 58719bd41f2cSmrg collect2name=`${CC} -print-prog-name=collect2` 58729bd41f2cSmrg if test -f "$collect2name" && \ 58739bd41f2cSmrg strings "$collect2name" | grep resolve_lib_name >/dev/null 58749bd41f2cSmrg then 58759bd41f2cSmrg # We have reworked collect2 58769bd41f2cSmrg : 58779bd41f2cSmrg else 58789bd41f2cSmrg # We have old collect2 58799bd41f2cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported 58809bd41f2cSmrg # It fails to find uninstalled libraries when the uninstalled 58819bd41f2cSmrg # path is not listed in the libpath. Setting hardcode_minus_L 58829bd41f2cSmrg # to unsupported forces relinking 58839bd41f2cSmrg _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes 58849bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 58859bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)= 58869bd41f2cSmrg fi 58879bd41f2cSmrg ;; 58889bd41f2cSmrg esac 58899bd41f2cSmrg shared_flag='-shared' 58909bd41f2cSmrg if test "$aix_use_runtimelinking" = yes; then 58919bd41f2cSmrg shared_flag="$shared_flag "'${wl}-G' 58929bd41f2cSmrg fi 58939bd41f2cSmrg else 58949bd41f2cSmrg # not using gcc 58959bd41f2cSmrg if test "$host_cpu" = ia64; then 58969bd41f2cSmrg # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release 58979bd41f2cSmrg # chokes on -Wl,-G. The following line is correct: 58989bd41f2cSmrg shared_flag='-G' 58999bd41f2cSmrg else 59009bd41f2cSmrg if test "$aix_use_runtimelinking" = yes; then 59019bd41f2cSmrg shared_flag='${wl}-G' 59029bd41f2cSmrg else 59039bd41f2cSmrg shared_flag='${wl}-bM:SRE' 59049bd41f2cSmrg fi 59059bd41f2cSmrg fi 59069bd41f2cSmrg fi 59079bd41f2cSmrg 59089bd41f2cSmrg # It seems that -bexpall does not export symbols beginning with 59099bd41f2cSmrg # underscore (_), so it is better to generate a list of symbols to export. 59109bd41f2cSmrg _LT_AC_TAGVAR(always_export_symbols, $1)=yes 59119bd41f2cSmrg if test "$aix_use_runtimelinking" = yes; then 59129bd41f2cSmrg # Warning - without using the other runtime loading flags (-brtl), 59139bd41f2cSmrg # -berok will link without error, but may produce a broken library. 59149bd41f2cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok' 59159bd41f2cSmrg # Determine the default libpath from the value encoded in an empty executable. 59169bd41f2cSmrg _LT_AC_SYS_LIBPATH_AIX 59179bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" 59189bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" 59199bd41f2cSmrg else 59209bd41f2cSmrg if test "$host_cpu" = ia64; then 59219bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' 59229bd41f2cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs" 59239bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" 59249bd41f2cSmrg else 59259bd41f2cSmrg # Determine the default libpath from the value encoded in an empty executable. 59269bd41f2cSmrg _LT_AC_SYS_LIBPATH_AIX 59279bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" 59289bd41f2cSmrg # Warning - without using the other run time loading flags, 59299bd41f2cSmrg # -berok will link without error, but may produce a broken library. 59309bd41f2cSmrg _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' 59319bd41f2cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' 59329bd41f2cSmrg # Exported symbols can be pulled into shared objects from archives 59339bd41f2cSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='$convenience' 59349bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes 59359bd41f2cSmrg # This is similar to how AIX traditionally builds its shared libraries. 59369bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' 59379bd41f2cSmrg fi 59389bd41f2cSmrg fi 59399bd41f2cSmrg ;; 59409bd41f2cSmrg 59419bd41f2cSmrg amigaos*) 59429bd41f2cSmrg _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)' 59439bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 59449bd41f2cSmrg _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes 59459bd41f2cSmrg # see comment about different semantics on the GNU ld section 59469bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 59479bd41f2cSmrg ;; 59489bd41f2cSmrg 59499bd41f2cSmrg bsdi[[45]]*) 59509bd41f2cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic 59519bd41f2cSmrg ;; 59529bd41f2cSmrg 59539bd41f2cSmrg cygwin* | mingw* | pw32*) 59549bd41f2cSmrg # When not using gcc, we currently assume that we are using 59559bd41f2cSmrg # Microsoft Visual C++. 59569bd41f2cSmrg # hardcode_libdir_flag_spec is actually meaningless, as there is 59579bd41f2cSmrg # no search path for DLLs. 59589bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' 59599bd41f2cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported 59609bd41f2cSmrg # Tell ltmain to make .lib files, not .a files. 59619bd41f2cSmrg libext=lib 59629bd41f2cSmrg # Tell ltmain to make .dll files, not .so files. 59639bd41f2cSmrg shrext_cmds=".dll" 59649bd41f2cSmrg # FIXME: Setting linknames here is a bad hack. 59659bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames=' 59669bd41f2cSmrg # The linker will automatically build a .lib file if we build a DLL. 59679bd41f2cSmrg _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='true' 59689bd41f2cSmrg # FIXME: Should let the user specify the lib program. 59699bd41f2cSmrg _LT_AC_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs' 59709bd41f2cSmrg _LT_AC_TAGVAR(fix_srcfile_path, $1)='`cygpath -w "$srcfile"`' 59719bd41f2cSmrg _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 59729bd41f2cSmrg ;; 59739bd41f2cSmrg 59749bd41f2cSmrg darwin* | rhapsody*) 59759bd41f2cSmrg case $host_os in 59769bd41f2cSmrg rhapsody* | darwin1.[[012]]) 59779bd41f2cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}suppress' 59789bd41f2cSmrg ;; 59799bd41f2cSmrg *) # Darwin 1.3 on 59809bd41f2cSmrg if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then 59819bd41f2cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' 59829bd41f2cSmrg else 59839bd41f2cSmrg case ${MACOSX_DEPLOYMENT_TARGET} in 59849bd41f2cSmrg 10.[[012]]) 59859bd41f2cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' 59869bd41f2cSmrg ;; 59879bd41f2cSmrg 10.*) 59889bd41f2cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}dynamic_lookup' 59899bd41f2cSmrg ;; 59909bd41f2cSmrg esac 59919bd41f2cSmrg fi 59929bd41f2cSmrg ;; 59939bd41f2cSmrg esac 59949bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no 59959bd41f2cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=no 59969bd41f2cSmrg _LT_AC_TAGVAR(hardcode_automatic, $1)=yes 59979bd41f2cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported 59989bd41f2cSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='' 59999bd41f2cSmrg _LT_AC_TAGVAR(link_all_deplibs, $1)=yes 60009bd41f2cSmrg if test "$GCC" = yes ; then 60019bd41f2cSmrg output_verbose_link_cmd='echo' 60029bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring' 60039bd41f2cSmrg _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' 60049bd41f2cSmrg # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds 60059bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' 60069bd41f2cSmrg _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' 60079bd41f2cSmrg else 60089bd41f2cSmrg case $cc_basename in 60099bd41f2cSmrg xlc*) 60109bd41f2cSmrg output_verbose_link_cmd='echo' 60119bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring' 60129bd41f2cSmrg _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' 60139bd41f2cSmrg # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds 60149bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' 60159bd41f2cSmrg _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' 60169bd41f2cSmrg ;; 60179bd41f2cSmrg *) 60189bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 60199bd41f2cSmrg ;; 60209bd41f2cSmrg esac 60219bd41f2cSmrg fi 60229bd41f2cSmrg ;; 60239bd41f2cSmrg 60249bd41f2cSmrg dgux*) 60259bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 60269bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 60279bd41f2cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 60289bd41f2cSmrg ;; 60299bd41f2cSmrg 60309bd41f2cSmrg freebsd1*) 60319bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 60329bd41f2cSmrg ;; 60339bd41f2cSmrg 60349bd41f2cSmrg # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor 60359bd41f2cSmrg # support. Future versions do this automatically, but an explicit c++rt0.o 60369bd41f2cSmrg # does not break anything, and helps significantly (at the cost of a little 60379bd41f2cSmrg # extra space). 60389bd41f2cSmrg freebsd2.2*) 60399bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' 60409bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 60419bd41f2cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=yes 60429bd41f2cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 60439bd41f2cSmrg ;; 60449bd41f2cSmrg 60459bd41f2cSmrg # Unfortunately, older versions of FreeBSD 2 do not have this feature. 60469bd41f2cSmrg freebsd2*) 60479bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' 60489bd41f2cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=yes 60499bd41f2cSmrg _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes 60509bd41f2cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 60519bd41f2cSmrg ;; 60529bd41f2cSmrg 60539bd41f2cSmrg # FreeBSD 3 and greater uses gcc -shared to do shared libraries. 60549bd41f2cSmrg freebsd* | dragonfly*) 60559bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' 60569bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 60579bd41f2cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=yes 60589bd41f2cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 60599bd41f2cSmrg ;; 60609bd41f2cSmrg 60619bd41f2cSmrg hpux9*) 60629bd41f2cSmrg if test "$GCC" = yes; then 60639bd41f2cSmrg _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' 60649bd41f2cSmrg else 60659bd41f2cSmrg _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' 60669bd41f2cSmrg fi 60679bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 60689bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 60699bd41f2cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=yes 60709bd41f2cSmrg 60719bd41f2cSmrg # hardcode_minus_L: Not really in the search PATH, 60729bd41f2cSmrg # but as the default location of the library. 60739bd41f2cSmrg _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes 60749bd41f2cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 60759bd41f2cSmrg ;; 60769bd41f2cSmrg 60779bd41f2cSmrg hpux10*) 60789bd41f2cSmrg if test "$GCC" = yes -a "$with_gnu_ld" = no; then 60799bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' 60809bd41f2cSmrg else 60819bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' 60829bd41f2cSmrg fi 60839bd41f2cSmrg if test "$with_gnu_ld" = no; then 60849bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 60859bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 60869bd41f2cSmrg 60879bd41f2cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=yes 60889bd41f2cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 60899bd41f2cSmrg 60909bd41f2cSmrg # hardcode_minus_L: Not really in the search PATH, 60919bd41f2cSmrg # but as the default location of the library. 60929bd41f2cSmrg _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes 60939bd41f2cSmrg fi 60949bd41f2cSmrg ;; 60959bd41f2cSmrg 60969bd41f2cSmrg hpux11*) 60979bd41f2cSmrg if test "$GCC" = yes -a "$with_gnu_ld" = no; then 60989bd41f2cSmrg case $host_cpu in 60999bd41f2cSmrg hppa*64*) 61009bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' 61019bd41f2cSmrg ;; 61029bd41f2cSmrg ia64*) 61039bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' 61049bd41f2cSmrg ;; 61059bd41f2cSmrg *) 61069bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' 61079bd41f2cSmrg ;; 61089bd41f2cSmrg esac 61099bd41f2cSmrg else 61109bd41f2cSmrg case $host_cpu in 61119bd41f2cSmrg hppa*64*) 61129bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' 61139bd41f2cSmrg ;; 61149bd41f2cSmrg ia64*) 61159bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' 61169bd41f2cSmrg ;; 61179bd41f2cSmrg *) 61189bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' 61199bd41f2cSmrg ;; 61209bd41f2cSmrg esac 61219bd41f2cSmrg fi 61229bd41f2cSmrg if test "$with_gnu_ld" = no; then 61239bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 61249bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 61259bd41f2cSmrg 61269bd41f2cSmrg case $host_cpu in 61279bd41f2cSmrg hppa*64*|ia64*) 61289bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir' 61299bd41f2cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=no 61309bd41f2cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 61319bd41f2cSmrg ;; 61329bd41f2cSmrg *) 61339bd41f2cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=yes 61349bd41f2cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 61359bd41f2cSmrg 61369bd41f2cSmrg # hardcode_minus_L: Not really in the search PATH, 61379bd41f2cSmrg # but as the default location of the library. 61389bd41f2cSmrg _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes 61399bd41f2cSmrg ;; 61409bd41f2cSmrg esac 61419bd41f2cSmrg fi 61429bd41f2cSmrg ;; 61439bd41f2cSmrg 61449bd41f2cSmrg irix5* | irix6* | nonstopux*) 61459bd41f2cSmrg if test "$GCC" = yes; then 61469bd41f2cSmrg _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' 61479bd41f2cSmrg else 61489bd41f2cSmrg _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' 61499bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='-rpath $libdir' 61509bd41f2cSmrg fi 61519bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 61529bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 61539bd41f2cSmrg _LT_AC_TAGVAR(link_all_deplibs, $1)=yes 61549bd41f2cSmrg ;; 61559bd41f2cSmrg 61569bd41f2cSmrg netbsd*) 61579bd41f2cSmrg if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then 61589bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out 61599bd41f2cSmrg else 61609bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF 61619bd41f2cSmrg fi 61629bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 61639bd41f2cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=yes 61649bd41f2cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 61659bd41f2cSmrg ;; 61669bd41f2cSmrg 61679bd41f2cSmrg newsos6) 61689bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 61699bd41f2cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=yes 61709bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 61719bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 61729bd41f2cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 61739bd41f2cSmrg ;; 61749bd41f2cSmrg 61759bd41f2cSmrg openbsd*) 61769bd41f2cSmrg if test -f /usr/libexec/ld.so; then 61779bd41f2cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=yes 61789bd41f2cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 61799bd41f2cSmrg if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then 61809bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' 61819bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' 61829bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 61839bd41f2cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 61849bd41f2cSmrg else 61859bd41f2cSmrg case $host_os in 61869bd41f2cSmrg openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*) 61879bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' 61889bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 61899bd41f2cSmrg ;; 61909bd41f2cSmrg *) 61919bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' 61929bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 61939bd41f2cSmrg ;; 61949bd41f2cSmrg esac 61959bd41f2cSmrg fi 61969bd41f2cSmrg else 61979bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 61989bd41f2cSmrg fi 61999bd41f2cSmrg ;; 62009bd41f2cSmrg 62019bd41f2cSmrg os2*) 62029bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 62039bd41f2cSmrg _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes 62049bd41f2cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported 62059bd41f2cSmrg _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' 62069bd41f2cSmrg _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' 62079bd41f2cSmrg ;; 62089bd41f2cSmrg 62099bd41f2cSmrg osf3*) 62109bd41f2cSmrg if test "$GCC" = yes; then 62119bd41f2cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' 62129bd41f2cSmrg _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' 62139bd41f2cSmrg else 62149bd41f2cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' 62159bd41f2cSmrg _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' 62169bd41f2cSmrg fi 62179bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 62189bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 62199bd41f2cSmrg ;; 62209bd41f2cSmrg 62219bd41f2cSmrg osf4* | osf5*) # as osf3* with the addition of -msym flag 62229bd41f2cSmrg if test "$GCC" = yes; then 62239bd41f2cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' 62249bd41f2cSmrg _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' 62259bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 62269bd41f2cSmrg else 62279bd41f2cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' 62289bd41f2cSmrg _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' 62299bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~ 62309bd41f2cSmrg $LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~$rm $lib.exp' 62319bd41f2cSmrg 62329bd41f2cSmrg # Both c and cxx compiler support -rpath directly 62339bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' 62349bd41f2cSmrg fi 62359bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 62369bd41f2cSmrg ;; 62379bd41f2cSmrg 62389bd41f2cSmrg solaris*) 62399bd41f2cSmrg _LT_AC_TAGVAR(no_undefined_flag, $1)=' -z text' 62409bd41f2cSmrg if test "$GCC" = yes; then 62419bd41f2cSmrg wlarc='${wl}' 62429bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' 62439bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ 62449bd41f2cSmrg $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp' 62459bd41f2cSmrg else 62469bd41f2cSmrg wlarc='' 62479bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' 62489bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ 62499bd41f2cSmrg $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp' 62509bd41f2cSmrg fi 62519bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 62529bd41f2cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 62539bd41f2cSmrg case $host_os in 62549bd41f2cSmrg solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; 62559bd41f2cSmrg *) 62569bd41f2cSmrg # The compiler driver will combine and reorder linker options, 62579bd41f2cSmrg # but understands `-z linker_flag'. GCC discards it without `$wl', 62589bd41f2cSmrg # but is careful enough not to reorder. 62599bd41f2cSmrg # Supported since Solaris 2.6 (maybe 2.5.1?) 62609bd41f2cSmrg if test "$GCC" = yes; then 62619bd41f2cSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' 62629bd41f2cSmrg else 62639bd41f2cSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' 62649bd41f2cSmrg fi 62659bd41f2cSmrg ;; 62669bd41f2cSmrg esac 62679bd41f2cSmrg _LT_AC_TAGVAR(link_all_deplibs, $1)=yes 62689bd41f2cSmrg ;; 62699bd41f2cSmrg 62709bd41f2cSmrg sunos4*) 62719bd41f2cSmrg if test "x$host_vendor" = xsequent; then 62729bd41f2cSmrg # Use $CC to link under sequent, because it throws in some extra .o 62739bd41f2cSmrg # files that make .init and .fini sections work. 62749bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' 62759bd41f2cSmrg else 62769bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' 62779bd41f2cSmrg fi 62789bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 62799bd41f2cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=yes 62809bd41f2cSmrg _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes 62819bd41f2cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 62829bd41f2cSmrg ;; 62839bd41f2cSmrg 62849bd41f2cSmrg sysv4) 62859bd41f2cSmrg case $host_vendor in 62869bd41f2cSmrg sni) 62879bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 62889bd41f2cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=yes # is this really true??? 62899bd41f2cSmrg ;; 62909bd41f2cSmrg siemens) 62919bd41f2cSmrg ## LD is ld it makes a PLAMLIB 62929bd41f2cSmrg ## CC just makes a GrossModule. 62939bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags' 62949bd41f2cSmrg _LT_AC_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs' 62959bd41f2cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=no 62969bd41f2cSmrg ;; 62979bd41f2cSmrg motorola) 62989bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 62999bd41f2cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie 63009bd41f2cSmrg ;; 63019bd41f2cSmrg esac 63029bd41f2cSmrg runpath_var='LD_RUN_PATH' 63039bd41f2cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 63049bd41f2cSmrg ;; 63059bd41f2cSmrg 63069bd41f2cSmrg sysv4.3*) 63079bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 63089bd41f2cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 63099bd41f2cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport' 63109bd41f2cSmrg ;; 63119bd41f2cSmrg 63129bd41f2cSmrg sysv4*MP*) 63139bd41f2cSmrg if test -d /usr/nec; then 63149bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 63159bd41f2cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 63169bd41f2cSmrg runpath_var=LD_RUN_PATH 63179bd41f2cSmrg hardcode_runpath_var=yes 63189bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=yes 63199bd41f2cSmrg fi 63209bd41f2cSmrg ;; 63219bd41f2cSmrg 63229bd41f2cSmrg sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) 63239bd41f2cSmrg _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' 63249bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no 63259bd41f2cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 63269bd41f2cSmrg runpath_var='LD_RUN_PATH' 63279bd41f2cSmrg 63289bd41f2cSmrg if test "$GCC" = yes; then 63299bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 63309bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 63319bd41f2cSmrg else 63329bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 63339bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 63349bd41f2cSmrg fi 63359bd41f2cSmrg ;; 63369bd41f2cSmrg 63379bd41f2cSmrg sysv5* | sco3.2v5* | sco5v6*) 63389bd41f2cSmrg # Note: We can NOT use -z defs as we might desire, because we do not 63399bd41f2cSmrg # link with -lc, and that would cause any symbols used from libc to 63409bd41f2cSmrg # always be unresolved, which means just about no library would 63419bd41f2cSmrg # ever link correctly. If we're not using GNU ld we use -z text 63429bd41f2cSmrg # though, which does catch some bad symbols but isn't as heavy-handed 63439bd41f2cSmrg # as -z defs. 63449bd41f2cSmrg _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' 63459bd41f2cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs' 63469bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no 63479bd41f2cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 63489bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`' 63499bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':' 63509bd41f2cSmrg _LT_AC_TAGVAR(link_all_deplibs, $1)=yes 63519bd41f2cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' 63529bd41f2cSmrg runpath_var='LD_RUN_PATH' 63539bd41f2cSmrg 63549bd41f2cSmrg if test "$GCC" = yes; then 63559bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' 63569bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' 63579bd41f2cSmrg else 63589bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' 63599bd41f2cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' 63609bd41f2cSmrg fi 63619bd41f2cSmrg ;; 63629bd41f2cSmrg 63639bd41f2cSmrg uts4*) 63649bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 63659bd41f2cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 63669bd41f2cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 63679bd41f2cSmrg ;; 63689bd41f2cSmrg 63699bd41f2cSmrg *) 63709bd41f2cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 63719bd41f2cSmrg ;; 63729bd41f2cSmrg esac 63739bd41f2cSmrg fi 63749bd41f2cSmrg]) 63759bd41f2cSmrgAC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)]) 63769bd41f2cSmrgtest "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no 63779bd41f2cSmrg 63789bd41f2cSmrg# 63799bd41f2cSmrg# Do we need to explicitly link libc? 63809bd41f2cSmrg# 63819bd41f2cSmrgcase "x$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)" in 63829bd41f2cSmrgx|xyes) 63839bd41f2cSmrg # Assume -lc should be added 63849bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes 63859bd41f2cSmrg 63869bd41f2cSmrg if test "$enable_shared" = yes && test "$GCC" = yes; then 63879bd41f2cSmrg case $_LT_AC_TAGVAR(archive_cmds, $1) in 63889bd41f2cSmrg *'~'*) 63899bd41f2cSmrg # FIXME: we may have to deal with multi-command sequences. 63909bd41f2cSmrg ;; 63919bd41f2cSmrg '$CC '*) 63929bd41f2cSmrg # Test whether the compiler implicitly links with -lc since on some 63939bd41f2cSmrg # systems, -lgcc has to come before -lc. If gcc already passes -lc 63949bd41f2cSmrg # to ld, don't add -lc before -lgcc. 63959bd41f2cSmrg AC_MSG_CHECKING([whether -lc should be explicitly linked in]) 63969bd41f2cSmrg $rm conftest* 63979bd41f2cSmrg echo "$lt_simple_compile_test_code" > conftest.$ac_ext 63989bd41f2cSmrg 63999bd41f2cSmrg if AC_TRY_EVAL(ac_compile) 2>conftest.err; then 64009bd41f2cSmrg soname=conftest 64019bd41f2cSmrg lib=conftest 64029bd41f2cSmrg libobjs=conftest.$ac_objext 64039bd41f2cSmrg deplibs= 64049bd41f2cSmrg wl=$_LT_AC_TAGVAR(lt_prog_compiler_wl, $1) 64059bd41f2cSmrg pic_flag=$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) 64069bd41f2cSmrg compiler_flags=-v 64079bd41f2cSmrg linker_flags=-v 64089bd41f2cSmrg verstring= 64099bd41f2cSmrg output_objdir=. 64109bd41f2cSmrg libname=conftest 64119bd41f2cSmrg lt_save_allow_undefined_flag=$_LT_AC_TAGVAR(allow_undefined_flag, $1) 64129bd41f2cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)= 64139bd41f2cSmrg if AC_TRY_EVAL(_LT_AC_TAGVAR(archive_cmds, $1) 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 64149bd41f2cSmrg then 64159bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no 64169bd41f2cSmrg else 64179bd41f2cSmrg _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes 64189bd41f2cSmrg fi 64199bd41f2cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag 64209bd41f2cSmrg else 64219bd41f2cSmrg cat conftest.err 1>&5 64229bd41f2cSmrg fi 64239bd41f2cSmrg $rm conftest* 64249bd41f2cSmrg AC_MSG_RESULT([$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)]) 64259bd41f2cSmrg ;; 64269bd41f2cSmrg esac 64279bd41f2cSmrg fi 64289bd41f2cSmrg ;; 64299bd41f2cSmrgesac 64309bd41f2cSmrg])# AC_LIBTOOL_PROG_LD_SHLIBS 64319bd41f2cSmrg 64329bd41f2cSmrg 64339bd41f2cSmrg# _LT_AC_FILE_LTDLL_C 64349bd41f2cSmrg# ------------------- 64359bd41f2cSmrg# Be careful that the start marker always follows a newline. 64369bd41f2cSmrgAC_DEFUN([_LT_AC_FILE_LTDLL_C], [ 64379bd41f2cSmrg# /* ltdll.c starts here */ 64389bd41f2cSmrg# #define WIN32_LEAN_AND_MEAN 64399bd41f2cSmrg# #include <windows.h> 64409bd41f2cSmrg# #undef WIN32_LEAN_AND_MEAN 64419bd41f2cSmrg# #include <stdio.h> 64429bd41f2cSmrg# 64439bd41f2cSmrg# #ifndef __CYGWIN__ 64449bd41f2cSmrg# # ifdef __CYGWIN32__ 64459bd41f2cSmrg# # define __CYGWIN__ __CYGWIN32__ 64469bd41f2cSmrg# # endif 64479bd41f2cSmrg# #endif 64489bd41f2cSmrg# 64499bd41f2cSmrg# #ifdef __cplusplus 64509bd41f2cSmrg# extern "C" { 64519bd41f2cSmrg# #endif 64529bd41f2cSmrg# BOOL APIENTRY DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved); 64539bd41f2cSmrg# #ifdef __cplusplus 64549bd41f2cSmrg# } 64559bd41f2cSmrg# #endif 64569bd41f2cSmrg# 64579bd41f2cSmrg# #ifdef __CYGWIN__ 64589bd41f2cSmrg# #include <cygwin/cygwin_dll.h> 64599bd41f2cSmrg# DECLARE_CYGWIN_DLL( DllMain ); 64609bd41f2cSmrg# #endif 64619bd41f2cSmrg# HINSTANCE __hDllInstance_base; 64629bd41f2cSmrg# 64639bd41f2cSmrg# BOOL APIENTRY 64649bd41f2cSmrg# DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved) 64659bd41f2cSmrg# { 64669bd41f2cSmrg# __hDllInstance_base = hInst; 64679bd41f2cSmrg# return TRUE; 64689bd41f2cSmrg# } 64699bd41f2cSmrg# /* ltdll.c ends here */ 64709bd41f2cSmrg])# _LT_AC_FILE_LTDLL_C 64719bd41f2cSmrg 64729bd41f2cSmrg 64739bd41f2cSmrg# _LT_AC_TAGVAR(VARNAME, [TAGNAME]) 64749bd41f2cSmrg# --------------------------------- 64759bd41f2cSmrgAC_DEFUN([_LT_AC_TAGVAR], [ifelse([$2], [], [$1], [$1_$2])]) 64769bd41f2cSmrg 64779bd41f2cSmrg 64789bd41f2cSmrg# old names 64799bd41f2cSmrgAC_DEFUN([AM_PROG_LIBTOOL], [AC_PROG_LIBTOOL]) 64809bd41f2cSmrgAC_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)]) 64819bd41f2cSmrgAC_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)]) 64829bd41f2cSmrgAC_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)]) 64839bd41f2cSmrgAC_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)]) 64849bd41f2cSmrgAC_DEFUN([AM_PROG_LD], [AC_PROG_LD]) 64859bd41f2cSmrgAC_DEFUN([AM_PROG_NM], [AC_PROG_NM]) 64869bd41f2cSmrg 64879bd41f2cSmrg# This is just to silence aclocal about the macro not being used 64889bd41f2cSmrgifelse([AC_DISABLE_FAST_INSTALL]) 64899bd41f2cSmrg 64909bd41f2cSmrgAC_DEFUN([LT_AC_PROG_GCJ], 64919bd41f2cSmrg[AC_CHECK_TOOL(GCJ, gcj, no) 64929bd41f2cSmrg test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2" 64939bd41f2cSmrg AC_SUBST(GCJFLAGS) 64949bd41f2cSmrg]) 64959bd41f2cSmrg 64969bd41f2cSmrgAC_DEFUN([LT_AC_PROG_RC], 64979bd41f2cSmrg[AC_CHECK_TOOL(RC, windres, no) 64989bd41f2cSmrg]) 64999bd41f2cSmrg 65009bd41f2cSmrg 65019bd41f2cSmrg# Cheap backport of AS_EXECUTABLE_P and required macros 65029bd41f2cSmrg# from Autoconf 2.59; we should not use $as_executable_p directly. 65039bd41f2cSmrg 65049bd41f2cSmrg# _AS_TEST_PREPARE 65059bd41f2cSmrg# ---------------- 65069bd41f2cSmrgm4_ifndef([_AS_TEST_PREPARE], 65079bd41f2cSmrg[m4_defun([_AS_TEST_PREPARE], 65089bd41f2cSmrg[if test -x / >/dev/null 2>&1; then 65099bd41f2cSmrg as_executable_p='test -x' 65109bd41f2cSmrgelse 65119bd41f2cSmrg as_executable_p='test -f' 65129bd41f2cSmrgfi 65139bd41f2cSmrg])])# _AS_TEST_PREPARE 65149bd41f2cSmrg 65159bd41f2cSmrg# AS_EXECUTABLE_P 65169bd41f2cSmrg# --------------- 65179bd41f2cSmrg# Check whether a file is executable. 65189bd41f2cSmrgm4_ifndef([AS_EXECUTABLE_P], 65199bd41f2cSmrg[m4_defun([AS_EXECUTABLE_P], 65209bd41f2cSmrg[AS_REQUIRE([_AS_TEST_PREPARE])dnl 65219bd41f2cSmrg$as_executable_p $1[]dnl 65229bd41f2cSmrg])])# AS_EXECUTABLE_P 65239bd41f2cSmrg 65249bd41f2cSmrg# NOTE: This macro has been submitted for inclusion into # 65259bd41f2cSmrg# GNU Autoconf as AC_PROG_SED. When it is available in # 65269bd41f2cSmrg# a released version of Autoconf we should remove this # 65279bd41f2cSmrg# macro and use it instead. # 65289bd41f2cSmrg# LT_AC_PROG_SED 65299bd41f2cSmrg# -------------- 65309bd41f2cSmrg# Check for a fully-functional sed program, that truncates 65319bd41f2cSmrg# as few characters as possible. Prefer GNU sed if found. 65329bd41f2cSmrgAC_DEFUN([LT_AC_PROG_SED], 65339bd41f2cSmrg[AC_MSG_CHECKING([for a sed that does not truncate output]) 65349bd41f2cSmrgAC_CACHE_VAL(lt_cv_path_SED, 65359bd41f2cSmrg[# Loop through the user's path and test for sed and gsed. 65369bd41f2cSmrg# Then use that list of sed's as ones to test for truncation. 65379bd41f2cSmrgas_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65389bd41f2cSmrgfor as_dir in $PATH 65399bd41f2cSmrgdo 65409bd41f2cSmrg IFS=$as_save_IFS 65419bd41f2cSmrg test -z "$as_dir" && as_dir=. 65429bd41f2cSmrg for lt_ac_prog in sed gsed; do 65439bd41f2cSmrg for ac_exec_ext in '' $ac_executable_extensions; do 65449bd41f2cSmrg if AS_EXECUTABLE_P(["$as_dir/$lt_ac_prog$ac_exec_ext"]); then 65459bd41f2cSmrg lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext" 65469bd41f2cSmrg fi 65479bd41f2cSmrg done 65489bd41f2cSmrg done 65499bd41f2cSmrgdone 65509bd41f2cSmrgIFS=$as_save_IFS 65519bd41f2cSmrglt_ac_max=0 65529bd41f2cSmrglt_ac_count=0 65539bd41f2cSmrg# Add /usr/xpg4/bin/sed as it is typically found on Solaris 65549bd41f2cSmrg# along with /bin/sed that truncates output. 65559bd41f2cSmrgfor lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do 65569bd41f2cSmrg test ! -f $lt_ac_sed && continue 65579bd41f2cSmrg cat /dev/null > conftest.in 65589bd41f2cSmrg lt_ac_count=0 65599bd41f2cSmrg echo $ECHO_N "0123456789$ECHO_C" >conftest.in 65609bd41f2cSmrg # Check for GNU sed and select it if it is found. 65619bd41f2cSmrg if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then 65629bd41f2cSmrg lt_cv_path_SED=$lt_ac_sed 65639bd41f2cSmrg break 65649bd41f2cSmrg fi 65659bd41f2cSmrg while true; do 65669bd41f2cSmrg cat conftest.in conftest.in >conftest.tmp 65679bd41f2cSmrg mv conftest.tmp conftest.in 65689bd41f2cSmrg cp conftest.in conftest.nl 65699bd41f2cSmrg echo >>conftest.nl 65709bd41f2cSmrg $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break 65719bd41f2cSmrg cmp -s conftest.out conftest.nl || break 65729bd41f2cSmrg # 10000 chars as input seems more than enough 65739bd41f2cSmrg test $lt_ac_count -gt 10 && break 65749bd41f2cSmrg lt_ac_count=`expr $lt_ac_count + 1` 65759bd41f2cSmrg if test $lt_ac_count -gt $lt_ac_max; then 65769bd41f2cSmrg lt_ac_max=$lt_ac_count 65779bd41f2cSmrg lt_cv_path_SED=$lt_ac_sed 65789bd41f2cSmrg fi 65799bd41f2cSmrg done 65809bd41f2cSmrgdone 65819bd41f2cSmrg]) 65829bd41f2cSmrgSED=$lt_cv_path_SED 65839bd41f2cSmrgAC_SUBST([SED]) 65849bd41f2cSmrgAC_MSG_RESULT([$SED]) 65859bd41f2cSmrg]) 65869bd41f2cSmrg 65879bd41f2cSmrg# pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*- 65889bd41f2cSmrg# 65899bd41f2cSmrg# Copyright © 2004 Scott James Remnant <scott@netsplit.com>. 65909bd41f2cSmrg# 65919bd41f2cSmrg# This program is free software; you can redistribute it and/or modify 65929bd41f2cSmrg# it under the terms of the GNU General Public License as published by 65939bd41f2cSmrg# the Free Software Foundation; either version 2 of the License, or 65949bd41f2cSmrg# (at your option) any later version. 65959bd41f2cSmrg# 65969bd41f2cSmrg# This program is distributed in the hope that it will be useful, but 65979bd41f2cSmrg# WITHOUT ANY WARRANTY; without even the implied warranty of 65989bd41f2cSmrg# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 65999bd41f2cSmrg# General Public License for more details. 66009bd41f2cSmrg# 66019bd41f2cSmrg# You should have received a copy of the GNU General Public License 66029bd41f2cSmrg# along with this program; if not, write to the Free Software 66039bd41f2cSmrg# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 66049bd41f2cSmrg# 66059bd41f2cSmrg# As a special exception to the GNU General Public License, if you 66069bd41f2cSmrg# distribute this file as part of a program that contains a 66079bd41f2cSmrg# configuration script generated by Autoconf, you may include it under 66089bd41f2cSmrg# the same distribution terms that you use for the rest of that program. 66099bd41f2cSmrg 66109bd41f2cSmrg# PKG_PROG_PKG_CONFIG([MIN-VERSION]) 66119bd41f2cSmrg# ---------------------------------- 66129bd41f2cSmrgAC_DEFUN([PKG_PROG_PKG_CONFIG], 66139bd41f2cSmrg[m4_pattern_forbid([^_?PKG_[A-Z_]+$]) 66149bd41f2cSmrgm4_pattern_allow([^PKG_CONFIG(_PATH)?$]) 66159bd41f2cSmrgAC_ARG_VAR([PKG_CONFIG], [path to pkg-config utility])dnl 66169bd41f2cSmrgif test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then 66179bd41f2cSmrg AC_PATH_TOOL([PKG_CONFIG], [pkg-config]) 66189bd41f2cSmrgfi 66199bd41f2cSmrgif test -n "$PKG_CONFIG"; then 66209bd41f2cSmrg _pkg_min_version=m4_default([$1], [0.9.0]) 66219bd41f2cSmrg AC_MSG_CHECKING([pkg-config is at least version $_pkg_min_version]) 66229bd41f2cSmrg if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then 66239bd41f2cSmrg AC_MSG_RESULT([yes]) 66249bd41f2cSmrg else 66259bd41f2cSmrg AC_MSG_RESULT([no]) 66269bd41f2cSmrg PKG_CONFIG="" 66279bd41f2cSmrg fi 66289bd41f2cSmrg 66299bd41f2cSmrgfi[]dnl 66309bd41f2cSmrg])# PKG_PROG_PKG_CONFIG 66319bd41f2cSmrg 66329bd41f2cSmrg# PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) 66339bd41f2cSmrg# 66349bd41f2cSmrg# Check to see whether a particular set of modules exists. Similar 66359bd41f2cSmrg# to PKG_CHECK_MODULES(), but does not set variables or print errors. 66369bd41f2cSmrg# 66379bd41f2cSmrg# 66389bd41f2cSmrg# Similar to PKG_CHECK_MODULES, make sure that the first instance of 66399bd41f2cSmrg# this or PKG_CHECK_MODULES is called, or make sure to call 66409bd41f2cSmrg# PKG_CHECK_EXISTS manually 66419bd41f2cSmrg# -------------------------------------------------------------- 66429bd41f2cSmrgAC_DEFUN([PKG_CHECK_EXISTS], 66439bd41f2cSmrg[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl 66449bd41f2cSmrgif test -n "$PKG_CONFIG" && \ 66459bd41f2cSmrg AC_RUN_LOG([$PKG_CONFIG --exists --print-errors "$1"]); then 66469bd41f2cSmrg m4_ifval([$2], [$2], [:]) 66479bd41f2cSmrgm4_ifvaln([$3], [else 66489bd41f2cSmrg $3])dnl 66499bd41f2cSmrgfi]) 66509bd41f2cSmrg 66519bd41f2cSmrg 66529bd41f2cSmrg# _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES]) 66539bd41f2cSmrg# --------------------------------------------- 66549bd41f2cSmrgm4_define([_PKG_CONFIG], 66559bd41f2cSmrg[if test -n "$PKG_CONFIG"; then 66569bd41f2cSmrg if test -n "$$1"; then 66579bd41f2cSmrg pkg_cv_[]$1="$$1" 66589bd41f2cSmrg else 66599bd41f2cSmrg PKG_CHECK_EXISTS([$3], 66609bd41f2cSmrg [pkg_cv_[]$1=`$PKG_CONFIG --[]$2 "$3" 2>/dev/null`], 66619bd41f2cSmrg [pkg_failed=yes]) 66629bd41f2cSmrg fi 66639bd41f2cSmrgelse 66649bd41f2cSmrg pkg_failed=untried 66659bd41f2cSmrgfi[]dnl 66669bd41f2cSmrg])# _PKG_CONFIG 66679bd41f2cSmrg 66689bd41f2cSmrg# _PKG_SHORT_ERRORS_SUPPORTED 66699bd41f2cSmrg# ----------------------------- 66709bd41f2cSmrgAC_DEFUN([_PKG_SHORT_ERRORS_SUPPORTED], 66719bd41f2cSmrg[AC_REQUIRE([PKG_PROG_PKG_CONFIG]) 66729bd41f2cSmrgif $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 66739bd41f2cSmrg _pkg_short_errors_supported=yes 66749bd41f2cSmrgelse 66759bd41f2cSmrg _pkg_short_errors_supported=no 66769bd41f2cSmrgfi[]dnl 66779bd41f2cSmrg])# _PKG_SHORT_ERRORS_SUPPORTED 66789bd41f2cSmrg 66799bd41f2cSmrg 66809bd41f2cSmrg# PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND], 66819bd41f2cSmrg# [ACTION-IF-NOT-FOUND]) 66829bd41f2cSmrg# 66839bd41f2cSmrg# 66849bd41f2cSmrg# Note that if there is a possibility the first call to 66859bd41f2cSmrg# PKG_CHECK_MODULES might not happen, you should be sure to include an 66869bd41f2cSmrg# explicit call to PKG_PROG_PKG_CONFIG in your configure.ac 66879bd41f2cSmrg# 66889bd41f2cSmrg# 66899bd41f2cSmrg# -------------------------------------------------------------- 66909bd41f2cSmrgAC_DEFUN([PKG_CHECK_MODULES], 66919bd41f2cSmrg[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl 66929bd41f2cSmrgAC_ARG_VAR([$1][_CFLAGS], [C compiler flags for $1, overriding pkg-config])dnl 66939bd41f2cSmrgAC_ARG_VAR([$1][_LIBS], [linker flags for $1, overriding pkg-config])dnl 66949bd41f2cSmrg 66959bd41f2cSmrgpkg_failed=no 66969bd41f2cSmrgAC_MSG_CHECKING([for $1]) 66979bd41f2cSmrg 66989bd41f2cSmrg_PKG_CONFIG([$1][_CFLAGS], [cflags], [$2]) 66999bd41f2cSmrg_PKG_CONFIG([$1][_LIBS], [libs], [$2]) 67009bd41f2cSmrg 67019bd41f2cSmrgm4_define([_PKG_TEXT], [Alternatively, you may set the environment variables $1[]_CFLAGS 67029bd41f2cSmrgand $1[]_LIBS to avoid the need to call pkg-config. 67039bd41f2cSmrgSee the pkg-config man page for more details.]) 67049bd41f2cSmrg 67059bd41f2cSmrgif test $pkg_failed = yes; then 67069bd41f2cSmrg _PKG_SHORT_ERRORS_SUPPORTED 67079bd41f2cSmrg if test $_pkg_short_errors_supported = yes; then 67089bd41f2cSmrg $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors "$2"` 67099bd41f2cSmrg else 67109bd41f2cSmrg $1[]_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$2"` 67119bd41f2cSmrg fi 67129bd41f2cSmrg # Put the nasty error message in config.log where it belongs 67139bd41f2cSmrg echo "$$1[]_PKG_ERRORS" >&AS_MESSAGE_LOG_FD 67149bd41f2cSmrg 67159bd41f2cSmrg ifelse([$4], , [AC_MSG_ERROR(dnl 67169bd41f2cSmrg[Package requirements ($2) were not met: 67179bd41f2cSmrg 67189bd41f2cSmrg$$1_PKG_ERRORS 67199bd41f2cSmrg 67209bd41f2cSmrgConsider adjusting the PKG_CONFIG_PATH environment variable if you 67219bd41f2cSmrginstalled software in a non-standard prefix. 67229bd41f2cSmrg 67239bd41f2cSmrg_PKG_TEXT 67249bd41f2cSmrg])], 67259bd41f2cSmrg [AC_MSG_RESULT([no]) 67269bd41f2cSmrg $4]) 67279bd41f2cSmrgelif test $pkg_failed = untried; then 67289bd41f2cSmrg ifelse([$4], , [AC_MSG_FAILURE(dnl 67299bd41f2cSmrg[The pkg-config script could not be found or is too old. Make sure it 67309bd41f2cSmrgis in your PATH or set the PKG_CONFIG environment variable to the full 67319bd41f2cSmrgpath to pkg-config. 67329bd41f2cSmrg 67339bd41f2cSmrg_PKG_TEXT 67349bd41f2cSmrg 67359bd41f2cSmrgTo get pkg-config, see <http://pkg-config.freedesktop.org/>.])], 67369bd41f2cSmrg [$4]) 67379bd41f2cSmrgelse 67389bd41f2cSmrg $1[]_CFLAGS=$pkg_cv_[]$1[]_CFLAGS 67399bd41f2cSmrg $1[]_LIBS=$pkg_cv_[]$1[]_LIBS 67409bd41f2cSmrg AC_MSG_RESULT([yes]) 67419bd41f2cSmrg ifelse([$3], , :, [$3]) 67429bd41f2cSmrgfi[]dnl 67439bd41f2cSmrg])# PKG_CHECK_MODULES 67449bd41f2cSmrg 67459bd41f2cSmrgdnl 67469bd41f2cSmrgdnl Copyright 2005-2006 Sun Microsystems, Inc. All rights reserved. 67479bd41f2cSmrgdnl 67489bd41f2cSmrgdnl Permission is hereby granted, free of charge, to any person obtaining a 67499bd41f2cSmrgdnl copy of this software and associated documentation files (the 67509bd41f2cSmrgdnl "Software"), to deal in the Software without restriction, including 67519bd41f2cSmrgdnl without limitation the rights to use, copy, modify, merge, publish, 67529bd41f2cSmrgdnl distribute, and/or sell copies of the Software, and to permit persons 67539bd41f2cSmrgdnl to whom the Software is furnished to do so, provided that the above 67549bd41f2cSmrgdnl copyright notice(s) and this permission notice appear in all copies of 67559bd41f2cSmrgdnl the Software and that both the above copyright notice(s) and this 67569bd41f2cSmrgdnl permission notice appear in supporting documentation. 67579bd41f2cSmrgdnl 67589bd41f2cSmrgdnl THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS 67599bd41f2cSmrgdnl OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 67609bd41f2cSmrgdnl MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT 67619bd41f2cSmrgdnl OF THIRD PARTY RIGHTS. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR 67629bd41f2cSmrgdnl HOLDERS INCLUDED IN THIS NOTICE BE LIABLE FOR ANY CLAIM, OR ANY SPECIAL 67639bd41f2cSmrgdnl INDIRECT OR CONSEQUENTIAL DAMAGES, OR ANY DAMAGES WHATSOEVER RESULTING 67649bd41f2cSmrgdnl FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, 67659bd41f2cSmrgdnl NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION 67669bd41f2cSmrgdnl WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. 67679bd41f2cSmrgdnl 67689bd41f2cSmrgdnl Except as contained in this notice, the name of a copyright holder 67699bd41f2cSmrgdnl shall not be used in advertising or otherwise to promote the sale, use 67709bd41f2cSmrgdnl or other dealings in this Software without prior written authorization 67719bd41f2cSmrgdnl of the copyright holder. 67729bd41f2cSmrg 67739bd41f2cSmrg# XORG_MACROS_VERSION(required-version) 67749bd41f2cSmrg# ------------------------------------- 67759bd41f2cSmrg# Minimum version: 1.1.0 67769bd41f2cSmrg# 67779bd41f2cSmrg# If you're using a macro added in Version 1.1 or newer, include this in 67789bd41f2cSmrg# your configure.ac with the minimum required version, such as: 67799bd41f2cSmrg# XORG_MACROS_VERSION(1.1) 67809bd41f2cSmrg# 67819bd41f2cSmrg# To force at least a version with this macro defined, also add: 67829bd41f2cSmrg# m4_ifndef([XORG_MACROS_VERSION], [AC_FATAL([must install xorg-macros 1.1 or later before running autoconf/autogen])]) 67839bd41f2cSmrg# 67849bd41f2cSmrg# 67859bd41f2cSmrg# See the "minimum version" comment for each macro you use to see what 67869bd41f2cSmrg# version you require. 67879bd41f2cSmrgAC_DEFUN([XORG_MACROS_VERSION],[ 67889bd41f2cSmrg [XORG_MACROS_needed_version=$1 67899bd41f2cSmrg XORG_MACROS_needed_major=`echo $XORG_MACROS_needed_version | sed 's/\..*$//'` 67909bd41f2cSmrg XORG_MACROS_needed_minor=`echo $XORG_MACROS_needed_version | sed -e 's/^[0-9]*\.//' -e 's/\..*$//'`] 67919bd41f2cSmrg AC_MSG_CHECKING([if xorg-macros used to generate configure is at least ${XORG_MACROS_needed_major}.${XORG_MACROS_needed_minor}]) 67929bd41f2cSmrg [XORG_MACROS_version=1.1.6 67939bd41f2cSmrg XORG_MACROS_major=`echo $XORG_MACROS_version | sed 's/\..*$//'` 67949bd41f2cSmrg XORG_MACROS_minor=`echo $XORG_MACROS_version | sed -e 's/^[0-9]*\.//' -e 's/\..*$//'`] 67959bd41f2cSmrg if test $XORG_MACROS_major -ne $XORG_MACROS_needed_major ; then 67969bd41f2cSmrg AC_MSG_ERROR([configure built with incompatible version of xorg-macros.m4 - requires version ${XORG_MACROS_major}.x]) 67979bd41f2cSmrg fi 67989bd41f2cSmrg if test $XORG_MACROS_minor -lt $XORG_MACROS_needed_minor ; then 67999bd41f2cSmrg AC_MSG_ERROR([configure built with too old of a version of xorg-macros.m4 - requires version ${XORG_MACROS_major}.${XORG_MACROS_minor}.0 or newer]) 68009bd41f2cSmrg fi 68019bd41f2cSmrg AC_MSG_RESULT([yes, $XORG_MACROS_version]) 68029bd41f2cSmrg]) # XORG_MACROS_VERSION 68039bd41f2cSmrg 68049bd41f2cSmrg# XORG_PROG_RAWCPP() 68059bd41f2cSmrg# ------------------ 68069bd41f2cSmrg# Minimum version: 1.0.0 68079bd41f2cSmrg# 68089bd41f2cSmrg# Find cpp program and necessary flags for use in pre-processing text files 68099bd41f2cSmrg# such as man pages and config files 68109bd41f2cSmrgAC_DEFUN([XORG_PROG_RAWCPP],[ 68119bd41f2cSmrgAC_REQUIRE([AC_PROG_CPP]) 68129bd41f2cSmrgAC_PATH_PROGS(RAWCPP, [cpp], [${CPP}], 68139bd41f2cSmrg [$PATH:/bin:/usr/bin:/usr/lib:/usr/libexec:/usr/ccs/lib:/usr/ccs/lbin:/lib]) 68149bd41f2cSmrg 68159bd41f2cSmrg# Check for flag to avoid builtin definitions - assumes unix is predefined, 68169bd41f2cSmrg# which is not the best choice for supporting other OS'es, but covers most 68179bd41f2cSmrg# of the ones we need for now. 68189bd41f2cSmrgAC_MSG_CHECKING([if $RAWCPP requires -undef]) 68199bd41f2cSmrgAC_LANG_CONFTEST([Does cpp redefine unix ?]) 68209bd41f2cSmrgif test `${RAWCPP} < conftest.$ac_ext | grep -c 'unix'` -eq 1 ; then 68219bd41f2cSmrg AC_MSG_RESULT([no]) 68229bd41f2cSmrgelse 68239bd41f2cSmrg if test `${RAWCPP} -undef < conftest.$ac_ext | grep -c 'unix'` -eq 1 ; then 68249bd41f2cSmrg RAWCPPFLAGS=-undef 68259bd41f2cSmrg AC_MSG_RESULT([yes]) 68269bd41f2cSmrg else 68279bd41f2cSmrg AC_MSG_ERROR([${RAWCPP} defines unix with or without -undef. I don't know what to do.]) 68289bd41f2cSmrg fi 68299bd41f2cSmrgfi 68309bd41f2cSmrgrm -f conftest.$ac_ext 68319bd41f2cSmrg 68329bd41f2cSmrgAC_MSG_CHECKING([if $RAWCPP requires -traditional]) 68339bd41f2cSmrgAC_LANG_CONFTEST([Does cpp preserve "whitespace"?]) 68349bd41f2cSmrgif test `${RAWCPP} < conftest.$ac_ext | grep -c 'preserve \"'` -eq 1 ; then 68359bd41f2cSmrg AC_MSG_RESULT([no]) 68369bd41f2cSmrgelse 68379bd41f2cSmrg if test `${RAWCPP} -traditional < conftest.$ac_ext | grep -c 'preserve \"'` -eq 1 ; then 68389bd41f2cSmrg RAWCPPFLAGS="${RAWCPPFLAGS} -traditional" 68399bd41f2cSmrg AC_MSG_RESULT([yes]) 68409bd41f2cSmrg else 68419bd41f2cSmrg AC_MSG_ERROR([${RAWCPP} does not preserve whitespace with or without -traditional. I don't know what to do.]) 68429bd41f2cSmrg fi 68439bd41f2cSmrgfi 68449bd41f2cSmrgrm -f conftest.$ac_ext 68459bd41f2cSmrgAC_SUBST(RAWCPPFLAGS) 68469bd41f2cSmrg]) # XORG_PROG_RAWCPP 68479bd41f2cSmrg 68489bd41f2cSmrg# XORG_MANPAGE_SECTIONS() 68499bd41f2cSmrg# ----------------------- 68509bd41f2cSmrg# Minimum version: 1.0.0 68519bd41f2cSmrg# 68529bd41f2cSmrg# Determine which sections man pages go in for the different man page types 68539bd41f2cSmrg# on this OS - replaces *ManSuffix settings in old Imake *.cf per-os files. 68549bd41f2cSmrg# Not sure if there's any better way than just hardcoding by OS name. 68559bd41f2cSmrg# Override default settings by setting environment variables 68569bd41f2cSmrg 68579bd41f2cSmrgAC_DEFUN([XORG_MANPAGE_SECTIONS],[ 68589bd41f2cSmrgAC_REQUIRE([AC_CANONICAL_HOST]) 68599bd41f2cSmrg 68609bd41f2cSmrgif test x$APP_MAN_SUFFIX = x ; then 68619bd41f2cSmrg APP_MAN_SUFFIX=1 68629bd41f2cSmrgfi 68639bd41f2cSmrgif test x$APP_MAN_DIR = x ; then 68649bd41f2cSmrg APP_MAN_DIR='$(mandir)/man$(APP_MAN_SUFFIX)' 68659bd41f2cSmrgfi 68669bd41f2cSmrg 68679bd41f2cSmrgif test x$LIB_MAN_SUFFIX = x ; then 68689bd41f2cSmrg LIB_MAN_SUFFIX=3 68699bd41f2cSmrgfi 68709bd41f2cSmrgif test x$LIB_MAN_DIR = x ; then 68719bd41f2cSmrg LIB_MAN_DIR='$(mandir)/man$(LIB_MAN_SUFFIX)' 68729bd41f2cSmrgfi 68739bd41f2cSmrg 68749bd41f2cSmrgif test x$FILE_MAN_SUFFIX = x ; then 68759bd41f2cSmrg case $host_os in 68769bd41f2cSmrg solaris*) FILE_MAN_SUFFIX=4 ;; 68779bd41f2cSmrg *) FILE_MAN_SUFFIX=5 ;; 68789bd41f2cSmrg esac 68799bd41f2cSmrgfi 68809bd41f2cSmrgif test x$FILE_MAN_DIR = x ; then 68819bd41f2cSmrg FILE_MAN_DIR='$(mandir)/man$(FILE_MAN_SUFFIX)' 68829bd41f2cSmrgfi 68839bd41f2cSmrg 68849bd41f2cSmrgif test x$MISC_MAN_SUFFIX = x ; then 68859bd41f2cSmrg case $host_os in 68869bd41f2cSmrg solaris*) MISC_MAN_SUFFIX=5 ;; 68879bd41f2cSmrg *) MISC_MAN_SUFFIX=7 ;; 68889bd41f2cSmrg esac 68899bd41f2cSmrgfi 68909bd41f2cSmrgif test x$MISC_MAN_DIR = x ; then 68919bd41f2cSmrg MISC_MAN_DIR='$(mandir)/man$(MISC_MAN_SUFFIX)' 68929bd41f2cSmrgfi 68939bd41f2cSmrg 68949bd41f2cSmrgif test x$DRIVER_MAN_SUFFIX = x ; then 68959bd41f2cSmrg case $host_os in 68969bd41f2cSmrg solaris*) DRIVER_MAN_SUFFIX=7 ;; 68979bd41f2cSmrg *) DRIVER_MAN_SUFFIX=4 ;; 68989bd41f2cSmrg esac 68999bd41f2cSmrgfi 69009bd41f2cSmrgif test x$DRIVER_MAN_DIR = x ; then 69019bd41f2cSmrg DRIVER_MAN_DIR='$(mandir)/man$(DRIVER_MAN_SUFFIX)' 69029bd41f2cSmrgfi 69039bd41f2cSmrg 69049bd41f2cSmrgif test x$ADMIN_MAN_SUFFIX = x ; then 69059bd41f2cSmrg case $host_os in 69069bd41f2cSmrg solaris*) ADMIN_MAN_SUFFIX=1m ;; 69079bd41f2cSmrg *) ADMIN_MAN_SUFFIX=8 ;; 69089bd41f2cSmrg esac 69099bd41f2cSmrgfi 69109bd41f2cSmrgif test x$ADMIN_MAN_DIR = x ; then 69119bd41f2cSmrg ADMIN_MAN_DIR='$(mandir)/man$(ADMIN_MAN_SUFFIX)' 69129bd41f2cSmrgfi 69139bd41f2cSmrg 69149bd41f2cSmrg 69159bd41f2cSmrgAC_SUBST([APP_MAN_SUFFIX]) 69169bd41f2cSmrgAC_SUBST([LIB_MAN_SUFFIX]) 69179bd41f2cSmrgAC_SUBST([FILE_MAN_SUFFIX]) 69189bd41f2cSmrgAC_SUBST([MISC_MAN_SUFFIX]) 69199bd41f2cSmrgAC_SUBST([DRIVER_MAN_SUFFIX]) 69209bd41f2cSmrgAC_SUBST([ADMIN_MAN_SUFFIX]) 69219bd41f2cSmrgAC_SUBST([APP_MAN_DIR]) 69229bd41f2cSmrgAC_SUBST([LIB_MAN_DIR]) 69239bd41f2cSmrgAC_SUBST([FILE_MAN_DIR]) 69249bd41f2cSmrgAC_SUBST([MISC_MAN_DIR]) 69259bd41f2cSmrgAC_SUBST([DRIVER_MAN_DIR]) 69269bd41f2cSmrgAC_SUBST([ADMIN_MAN_DIR]) 69279bd41f2cSmrg]) # XORG_MANPAGE_SECTIONS 69289bd41f2cSmrg 69299bd41f2cSmrg# XORG_CHECK_LINUXDOC 69309bd41f2cSmrg# ------------------- 69319bd41f2cSmrg# Minimum version: 1.0.0 69329bd41f2cSmrg# 69339bd41f2cSmrg# Defines the variable MAKE_TEXT if the necessary tools and 69349bd41f2cSmrg# files are found. $(MAKE_TEXT) blah.sgml will then produce blah.txt. 69359bd41f2cSmrg# Whether or not the necessary tools and files are found can be checked 69369bd41f2cSmrg# with the AM_CONDITIONAL "BUILD_LINUXDOC" 69379bd41f2cSmrgAC_DEFUN([XORG_CHECK_LINUXDOC],[ 69389bd41f2cSmrgXORG_SGML_PATH=$prefix/share/sgml 69399bd41f2cSmrgHAVE_DEFS_ENT= 69409bd41f2cSmrg 69419bd41f2cSmrgif test x"$cross_compiling" = x"yes" ; then 69429bd41f2cSmrg HAVE_DEFS_ENT=no 69439bd41f2cSmrgelse 69449bd41f2cSmrg AC_CHECK_FILE([$XORG_SGML_PATH/X11/defs.ent], [HAVE_DEFS_ENT=yes]) 69459bd41f2cSmrgfi 69469bd41f2cSmrg 69479bd41f2cSmrgAC_PATH_PROG(LINUXDOC, linuxdoc) 69489bd41f2cSmrgAC_PATH_PROG(PS2PDF, ps2pdf) 69499bd41f2cSmrg 69509bd41f2cSmrgAC_MSG_CHECKING([Whether to build documentation]) 69519bd41f2cSmrg 69529bd41f2cSmrgif test x$HAVE_DEFS_ENT != x && test x$LINUXDOC != x ; then 69539bd41f2cSmrg BUILDDOC=yes 69549bd41f2cSmrgelse 69559bd41f2cSmrg BUILDDOC=no 69569bd41f2cSmrgfi 69579bd41f2cSmrg 69589bd41f2cSmrgAM_CONDITIONAL(BUILD_LINUXDOC, [test x$BUILDDOC = xyes]) 69599bd41f2cSmrg 69609bd41f2cSmrgAC_MSG_RESULT([$BUILDDOC]) 69619bd41f2cSmrg 69629bd41f2cSmrgAC_MSG_CHECKING([Whether to build pdf documentation]) 69639bd41f2cSmrg 69649bd41f2cSmrgif test x$PS2PDF != x && test x$BUILD_PDFDOC != xno; then 69659bd41f2cSmrg BUILDPDFDOC=yes 69669bd41f2cSmrgelse 69679bd41f2cSmrg BUILDPDFDOC=no 69689bd41f2cSmrgfi 69699bd41f2cSmrg 69709bd41f2cSmrgAM_CONDITIONAL(BUILD_PDFDOC, [test x$BUILDPDFDOC = xyes]) 69719bd41f2cSmrg 69729bd41f2cSmrgAC_MSG_RESULT([$BUILDPDFDOC]) 69739bd41f2cSmrg 69749bd41f2cSmrgMAKE_TEXT="SGML_SEARCH_PATH=$XORG_SGML_PATH GROFF_NO_SGR=y $LINUXDOC -B txt" 69759bd41f2cSmrgMAKE_PS="SGML_SEARCH_PATH=$XORG_SGML_PATH $LINUXDOC -B latex --papersize=letter --output=ps" 69769bd41f2cSmrgMAKE_PDF="$PS2PDF" 69779bd41f2cSmrgMAKE_HTML="SGML_SEARCH_PATH=$XORG_SGML_PATH $LINUXDOC -B html --split=0" 69789bd41f2cSmrg 69799bd41f2cSmrgAC_SUBST(MAKE_TEXT) 69809bd41f2cSmrgAC_SUBST(MAKE_PS) 69819bd41f2cSmrgAC_SUBST(MAKE_PDF) 69829bd41f2cSmrgAC_SUBST(MAKE_HTML) 69839bd41f2cSmrg]) # XORG_CHECK_LINUXDOC 69849bd41f2cSmrg 69859bd41f2cSmrg# XORG_CHECK_DOCBOOK 69869bd41f2cSmrg# ------------------- 69879bd41f2cSmrg# Minimum version: 1.0.0 69889bd41f2cSmrg# 69899bd41f2cSmrg# Checks for the ability to build output formats from SGML DocBook source. 69909bd41f2cSmrg# For XXX in {TXT, PDF, PS, HTML}, the AM_CONDITIONAL "BUILD_XXXDOC" 69919bd41f2cSmrg# indicates whether the necessary tools and files are found and, if set, 69929bd41f2cSmrg# $(MAKE_XXX) blah.sgml will produce blah.xxx. 69939bd41f2cSmrgAC_DEFUN([XORG_CHECK_DOCBOOK],[ 69949bd41f2cSmrgXORG_SGML_PATH=$prefix/share/sgml 69959bd41f2cSmrgHAVE_DEFS_ENT= 69969bd41f2cSmrgBUILDTXTDOC=no 69979bd41f2cSmrgBUILDPDFDOC=no 69989bd41f2cSmrgBUILDPSDOC=no 69999bd41f2cSmrgBUILDHTMLDOC=no 70009bd41f2cSmrg 70019bd41f2cSmrgAC_CHECK_FILE([$XORG_SGML_PATH/X11/defs.ent], [HAVE_DEFS_ENT=yes]) 70029bd41f2cSmrg 70039bd41f2cSmrgAC_PATH_PROG(DOCBOOKPS, docbook2ps) 70049bd41f2cSmrgAC_PATH_PROG(DOCBOOKPDF, docbook2pdf) 70059bd41f2cSmrgAC_PATH_PROG(DOCBOOKHTML, docbook2html) 70069bd41f2cSmrgAC_PATH_PROG(DOCBOOKTXT, docbook2txt) 70079bd41f2cSmrg 70089bd41f2cSmrgAC_MSG_CHECKING([Whether to build text documentation]) 70099bd41f2cSmrgif test x$HAVE_DEFS_ENT != x && test x$DOCBOOKTXT != x && 70109bd41f2cSmrg test x$BUILD_TXTDOC != xno; then 70119bd41f2cSmrg BUILDTXTDOC=yes 70129bd41f2cSmrgfi 70139bd41f2cSmrgAM_CONDITIONAL(BUILD_TXTDOC, [test x$BUILDTXTDOC = xyes]) 70149bd41f2cSmrgAC_MSG_RESULT([$BUILDTXTDOC]) 70159bd41f2cSmrg 70169bd41f2cSmrgAC_MSG_CHECKING([Whether to build PDF documentation]) 70179bd41f2cSmrgif test x$HAVE_DEFS_ENT != x && test x$DOCBOOKPDF != x && 70189bd41f2cSmrg test x$BUILD_PDFDOC != xno; then 70199bd41f2cSmrg BUILDPDFDOC=yes 70209bd41f2cSmrgfi 70219bd41f2cSmrgAM_CONDITIONAL(BUILD_PDFDOC, [test x$BUILDPDFDOC = xyes]) 70229bd41f2cSmrgAC_MSG_RESULT([$BUILDPDFDOC]) 70239bd41f2cSmrg 70249bd41f2cSmrgAC_MSG_CHECKING([Whether to build PostScript documentation]) 70259bd41f2cSmrgif test x$HAVE_DEFS_ENT != x && test x$DOCBOOKPS != x && 70269bd41f2cSmrg test x$BUILD_PSDOC != xno; then 70279bd41f2cSmrg BUILDPSDOC=yes 70289bd41f2cSmrgfi 70299bd41f2cSmrgAM_CONDITIONAL(BUILD_PSDOC, [test x$BUILDPSDOC = xyes]) 70309bd41f2cSmrgAC_MSG_RESULT([$BUILDPSDOC]) 70319bd41f2cSmrg 70329bd41f2cSmrgAC_MSG_CHECKING([Whether to build HTML documentation]) 70339bd41f2cSmrgif test x$HAVE_DEFS_ENT != x && test x$DOCBOOKHTML != x && 70349bd41f2cSmrg test x$BUILD_HTMLDOC != xno; then 70359bd41f2cSmrg BUILDHTMLDOC=yes 70369bd41f2cSmrgfi 70379bd41f2cSmrgAM_CONDITIONAL(BUILD_HTMLDOC, [test x$BUILDHTMLDOC = xyes]) 70389bd41f2cSmrgAC_MSG_RESULT([$BUILDHTMLDOC]) 70399bd41f2cSmrg 70409bd41f2cSmrgMAKE_TEXT="SGML_SEARCH_PATH=$XORG_SGML_PATH $DOCBOOKTXT" 70419bd41f2cSmrgMAKE_PS="SGML_SEARCH_PATH=$XORG_SGML_PATH $DOCBOOKPS" 70429bd41f2cSmrgMAKE_PDF="SGML_SEARCH_PATH=$XORG_SGML_PATH $DOCBOOKPDF" 70439bd41f2cSmrgMAKE_HTML="SGML_SEARCH_PATH=$XORG_SGML_PATH $DOCBOOKHTML" 70449bd41f2cSmrg 70459bd41f2cSmrgAC_SUBST(MAKE_TEXT) 70469bd41f2cSmrgAC_SUBST(MAKE_PS) 70479bd41f2cSmrgAC_SUBST(MAKE_PDF) 70489bd41f2cSmrgAC_SUBST(MAKE_HTML) 70499bd41f2cSmrg]) # XORG_CHECK_DOCBOOK 70509bd41f2cSmrg 70519bd41f2cSmrg# XORG_CHECK_MALLOC_ZERO 70529bd41f2cSmrg# ---------------------- 70539bd41f2cSmrg# Minimum version: 1.0.0 70549bd41f2cSmrg# 70559bd41f2cSmrg# Defines {MALLOC,XMALLOC,XTMALLOC}_ZERO_CFLAGS appropriately if 70569bd41f2cSmrg# malloc(0) returns NULL. Packages should add one of these cflags to 70579bd41f2cSmrg# their AM_CFLAGS (or other appropriate *_CFLAGS) to use them. 70589bd41f2cSmrgAC_DEFUN([XORG_CHECK_MALLOC_ZERO],[ 70599bd41f2cSmrgAC_ARG_ENABLE(malloc0returnsnull, 70609bd41f2cSmrg AC_HELP_STRING([--enable-malloc0returnsnull], 70619bd41f2cSmrg [malloc(0) returns NULL (default: auto)]), 70629bd41f2cSmrg [MALLOC_ZERO_RETURNS_NULL=$enableval], 70639bd41f2cSmrg [MALLOC_ZERO_RETURNS_NULL=auto]) 70649bd41f2cSmrg 70659bd41f2cSmrgAC_MSG_CHECKING([whether malloc(0) returns NULL]) 70669bd41f2cSmrgif test "x$MALLOC_ZERO_RETURNS_NULL" = xauto; then 70679bd41f2cSmrg AC_RUN_IFELSE([ 70689bd41f2cSmrgchar *malloc(); 70699bd41f2cSmrgchar *realloc(); 70709bd41f2cSmrgchar *calloc(); 70719bd41f2cSmrgmain() { 70729bd41f2cSmrg char *m0, *r0, *c0, *p; 70739bd41f2cSmrg m0 = malloc(0); 70749bd41f2cSmrg p = malloc(10); 70759bd41f2cSmrg r0 = realloc(p,0); 70769bd41f2cSmrg c0 = calloc(0); 70779bd41f2cSmrg exit(m0 == 0 || r0 == 0 || c0 == 0 ? 0 : 1); 70789bd41f2cSmrg}], 70799bd41f2cSmrg [MALLOC_ZERO_RETURNS_NULL=yes], 70809bd41f2cSmrg [MALLOC_ZERO_RETURNS_NULL=no]) 70819bd41f2cSmrgfi 70829bd41f2cSmrgAC_MSG_RESULT([$MALLOC_ZERO_RETURNS_NULL]) 70839bd41f2cSmrg 70849bd41f2cSmrgif test "x$MALLOC_ZERO_RETURNS_NULL" = xyes; then 70859bd41f2cSmrg MALLOC_ZERO_CFLAGS="-DMALLOC_0_RETURNS_NULL" 70869bd41f2cSmrg XMALLOC_ZERO_CFLAGS=$MALLOC_ZERO_CFLAGS 70879bd41f2cSmrg XTMALLOC_ZERO_CFLAGS="$MALLOC_ZERO_CFLAGS -DXTMALLOC_BC" 70889bd41f2cSmrgelse 70899bd41f2cSmrg MALLOC_ZERO_CFLAGS="" 70909bd41f2cSmrg XMALLOC_ZERO_CFLAGS="" 70919bd41f2cSmrg XTMALLOC_ZERO_CFLAGS="" 70929bd41f2cSmrgfi 70939bd41f2cSmrg 70949bd41f2cSmrgAC_SUBST([MALLOC_ZERO_CFLAGS]) 70959bd41f2cSmrgAC_SUBST([XMALLOC_ZERO_CFLAGS]) 70969bd41f2cSmrgAC_SUBST([XTMALLOC_ZERO_CFLAGS]) 70979bd41f2cSmrg]) # XORG_CHECK_MALLOC_ZERO 70989bd41f2cSmrg 70999bd41f2cSmrg# XORG_WITH_LINT() 71009bd41f2cSmrg# ---------------- 71019bd41f2cSmrg# Minimum version: 1.1.0 71029bd41f2cSmrg# 71039bd41f2cSmrg# Sets up flags for source checkers such as lint and sparse if --with-lint 71049bd41f2cSmrg# is specified. (Use --with-lint=sparse for sparse.) 71059bd41f2cSmrg# Sets $LINT to name of source checker passed with --with-lint (default: lint) 71069bd41f2cSmrg# Sets $LINT_FLAGS to flags to pass to source checker 71079bd41f2cSmrg# Sets LINT automake conditional if enabled (default: disabled) 71089bd41f2cSmrg# 71099bd41f2cSmrgAC_DEFUN([XORG_WITH_LINT],[ 71109bd41f2cSmrg 71119bd41f2cSmrg# Allow checking code with lint, sparse, etc. 71129bd41f2cSmrgAC_ARG_WITH(lint, [AC_HELP_STRING([--with-lint], 71139bd41f2cSmrg [Use a lint-style source code checker (default: disabled)])], 71149bd41f2cSmrg [use_lint=$withval], [use_lint=no]) 71159bd41f2cSmrgif test "x$use_lint" = "xyes" ; then 71169bd41f2cSmrg LINT="lint" 71179bd41f2cSmrgelse 71189bd41f2cSmrg LINT="$use_lint" 71199bd41f2cSmrgfi 71209bd41f2cSmrgif test "x$LINT_FLAGS" = "x" -a "x$LINT" != "xno" ; then 71219bd41f2cSmrg case $LINT in 71229bd41f2cSmrg lint|*/lint) 71239bd41f2cSmrg case $host_os in 71249bd41f2cSmrg solaris*) 71259bd41f2cSmrg LINT_FLAGS="-u -b -h -erroff=E_INDISTING_FROM_TRUNC2" 71269bd41f2cSmrg ;; 71279bd41f2cSmrg esac 71289bd41f2cSmrg ;; 71299bd41f2cSmrg esac 71309bd41f2cSmrgfi 71319bd41f2cSmrg 71329bd41f2cSmrgAC_SUBST(LINT) 71339bd41f2cSmrgAC_SUBST(LINT_FLAGS) 71349bd41f2cSmrgAM_CONDITIONAL(LINT, [test x$LINT != xno]) 71359bd41f2cSmrg 71369bd41f2cSmrg]) # XORG_WITH_LINT 71379bd41f2cSmrg 71389bd41f2cSmrg# XORG_LINT_LIBRARY(LIBNAME) 71399bd41f2cSmrg# -------------------------- 71409bd41f2cSmrg# Minimum version: 1.1.0 71419bd41f2cSmrg# 71429bd41f2cSmrg# Sets up flags for building lint libraries for checking programs that call 71439bd41f2cSmrg# functions in the library. 71449bd41f2cSmrg# Disabled by default, enable with --enable-lint-library 71459bd41f2cSmrg# Sets: 71469bd41f2cSmrg# @LINTLIB@ - name of lint library file to make 71479bd41f2cSmrg# MAKE_LINT_LIB - automake conditional 71489bd41f2cSmrg# 71499bd41f2cSmrg 71509bd41f2cSmrgAC_DEFUN([XORG_LINT_LIBRARY],[ 71519bd41f2cSmrgAC_REQUIRE([XORG_WITH_LINT]) 71529bd41f2cSmrg# Build lint "library" for more indepth checks of programs calling this library 71539bd41f2cSmrgAC_ARG_ENABLE(lint-library, [AC_HELP_STRING([--enable-lint-library], 71549bd41f2cSmrg [Create lint library (default: disabled)])], 71559bd41f2cSmrg [make_lint_lib=$enableval], [make_lint_lib=no]) 71569bd41f2cSmrgif test "x$make_lint_lib" != "xno" ; then 71579bd41f2cSmrg if test "x$LINT" = "xno" ; then 71589bd41f2cSmrg AC_MSG_ERROR([Cannot make lint library without --with-lint]) 71599bd41f2cSmrg fi 71609bd41f2cSmrg if test "x$make_lint_lib" = "xyes" ; then 71619bd41f2cSmrg LINTLIB=llib-l$1.ln 71629bd41f2cSmrg else 71639bd41f2cSmrg LINTLIB=$make_lint_lib 71649bd41f2cSmrg fi 71659bd41f2cSmrgfi 71669bd41f2cSmrgAC_SUBST(LINTLIB) 71679bd41f2cSmrgAM_CONDITIONAL(MAKE_LINT_LIB, [test x$make_lint_lib != xno]) 71689bd41f2cSmrg 71699bd41f2cSmrg]) # XORG_LINT_LIBRARY 71709bd41f2cSmrg 71719bd41f2cSmrgdnl Copyright 2005 Red Hat, Inc 71729bd41f2cSmrgdnl 71739bd41f2cSmrgdnl Permission to use, copy, modify, distribute, and sell this software and its 71749bd41f2cSmrgdnl documentation for any purpose is hereby granted without fee, provided that 71759bd41f2cSmrgdnl the above copyright notice appear in all copies and that both that 71769bd41f2cSmrgdnl copyright notice and this permission notice appear in supporting 71779bd41f2cSmrgdnl documentation. 71789bd41f2cSmrgdnl 71799bd41f2cSmrgdnl The above copyright notice and this permission notice shall be included 71809bd41f2cSmrgdnl in all copies or substantial portions of the Software. 71819bd41f2cSmrgdnl 71829bd41f2cSmrgdnl THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS 71839bd41f2cSmrgdnl OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 71849bd41f2cSmrgdnl MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 71859bd41f2cSmrgdnl IN NO EVENT SHALL THE OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR 71869bd41f2cSmrgdnl OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, 71879bd41f2cSmrgdnl ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 71889bd41f2cSmrgdnl OTHER DEALINGS IN THE SOFTWARE. 71899bd41f2cSmrgdnl 71909bd41f2cSmrgdnl Except as contained in this notice, the name of the copyright holders shall 71919bd41f2cSmrgdnl not be used in advertising or otherwise to promote the sale, use or 71929bd41f2cSmrgdnl other dealings in this Software without prior written authorization 71939bd41f2cSmrgdnl from the copyright holders. 71949bd41f2cSmrgdnl 71959bd41f2cSmrg 71969bd41f2cSmrg# XORG_DRIVER_CHECK_EXT() 71979bd41f2cSmrg# -------------------------- 71989bd41f2cSmrg# Checks for the $1 define in xorg-server.h (from the sdk). If it 71999bd41f2cSmrg# is defined, then add $1 to $REQUIRED_MODULES. 72009bd41f2cSmrg 72019bd41f2cSmrgAC_DEFUN([XORG_DRIVER_CHECK_EXT],[ 72029bd41f2cSmrg SAVE_CFLAGS="$CFLAGS" 72039bd41f2cSmrg CFLAGS="$CFLAGS -I`pkg-config --variable=sdkdir xorg-server`" 72049bd41f2cSmrg AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ 72059bd41f2cSmrg#include "xorg-server.h" 72069bd41f2cSmrg#if !defined $1 72079bd41f2cSmrg#error $1 not defined 72089bd41f2cSmrg#endif 72099bd41f2cSmrg ]])], 72109bd41f2cSmrg [_EXT_CHECK=yes], 72119bd41f2cSmrg [_EXT_CHECK=no]) 72129bd41f2cSmrg CFLAGS="$SAVE_CFLAGS" 72139bd41f2cSmrg AC_MSG_CHECKING([if $1 is defined]) 72149bd41f2cSmrg AC_MSG_RESULT([$_EXT_CHECK]) 72159bd41f2cSmrg if test "$_EXT_CHECK" != no; then 72169bd41f2cSmrg REQUIRED_MODULES="$REQUIRED_MODULES $2" 72179bd41f2cSmrg fi 72189bd41f2cSmrg]) 72199bd41f2cSmrg 72209bd41f2cSmrgdnl Copyright 2005 Red Hat, Inc 72219bd41f2cSmrgdnl 72229bd41f2cSmrgdnl Permission to use, copy, modify, distribute, and sell this software and its 72239bd41f2cSmrgdnl documentation for any purpose is hereby granted without fee, provided that 72249bd41f2cSmrgdnl the above copyright notice appear in all copies and that both that 72259bd41f2cSmrgdnl copyright notice and this permission notice appear in supporting 72269bd41f2cSmrgdnl documentation. 72279bd41f2cSmrgdnl 72289bd41f2cSmrgdnl The above copyright notice and this permission notice shall be included 72299bd41f2cSmrgdnl in all copies or substantial portions of the Software. 72309bd41f2cSmrgdnl 72319bd41f2cSmrgdnl THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS 72329bd41f2cSmrgdnl OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 72339bd41f2cSmrgdnl MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 72349bd41f2cSmrgdnl IN NO EVENT SHALL THE OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR 72359bd41f2cSmrgdnl OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, 72369bd41f2cSmrgdnl ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 72379bd41f2cSmrgdnl OTHER DEALINGS IN THE SOFTWARE. 72389bd41f2cSmrgdnl 72399bd41f2cSmrgdnl Except as contained in this notice, the name of the copyright holders shall 72409bd41f2cSmrgdnl not be used in advertising or otherwise to promote the sale, use or 72419bd41f2cSmrgdnl other dealings in this Software without prior written authorization 72429bd41f2cSmrgdnl from the copyright holders. 72439bd41f2cSmrgdnl 72449bd41f2cSmrg 72459bd41f2cSmrg# XORG_RELEASE_VERSION 72469bd41f2cSmrg# -------------------- 72479bd41f2cSmrg# Adds --with/without-release-string and changes the PACKAGE and 72489bd41f2cSmrg# PACKAGE_TARNAME to use "$PACKAGE{_TARNAME}-$RELEASE_VERSION". If 72499bd41f2cSmrg# no option is given, PACKAGE and PACKAGE_TARNAME are unchanged. Also 72509bd41f2cSmrg# defines PACKAGE_VERSION_{MAJOR,MINOR,PATCHLEVEL} for modules to use. 72519bd41f2cSmrg 72529bd41f2cSmrgAC_DEFUN([XORG_RELEASE_VERSION],[ 72539bd41f2cSmrg AC_ARG_WITH(release-version, 72549bd41f2cSmrg AC_HELP_STRING([--with-release-version=STRING], 72559bd41f2cSmrg [Use release version string in package name]), 72569bd41f2cSmrg [RELEASE_VERSION="$withval"], 72579bd41f2cSmrg [RELEASE_VERSION=""]) 72589bd41f2cSmrg if test "x$RELEASE_VERSION" != "x"; then 72599bd41f2cSmrg PACKAGE="$PACKAGE-$RELEASE_VERSION" 72609bd41f2cSmrg PACKAGE_TARNAME="$PACKAGE_TARNAME-$RELEASE_VERSION" 72619bd41f2cSmrg AC_MSG_NOTICE([Building with package name set to $PACKAGE]) 72629bd41f2cSmrg fi 72639bd41f2cSmrg AC_DEFINE_UNQUOTED([PACKAGE_VERSION_MAJOR], 72649bd41f2cSmrg [`echo $PACKAGE_VERSION | cut -d . -f 1`], 72659bd41f2cSmrg [Major version of this package]) 72669bd41f2cSmrg PVM=`echo $PACKAGE_VERSION | cut -d . -f 2 | cut -d - -f 1` 72679bd41f2cSmrg if test "x$PVM" = "x"; then 72689bd41f2cSmrg PVM="0" 72699bd41f2cSmrg fi 72709bd41f2cSmrg AC_DEFINE_UNQUOTED([PACKAGE_VERSION_MINOR], 72719bd41f2cSmrg [$PVM], 72729bd41f2cSmrg [Minor version of this package]) 72739bd41f2cSmrg PVP=`echo $PACKAGE_VERSION | cut -d . -f 3 | cut -d - -f 1` 72749bd41f2cSmrg if test "x$PVP" = "x"; then 72759bd41f2cSmrg PVP="0" 72769bd41f2cSmrg fi 72779bd41f2cSmrg AC_DEFINE_UNQUOTED([PACKAGE_VERSION_PATCHLEVEL], 72789bd41f2cSmrg [$PVP], 72799bd41f2cSmrg [Patch version of this package]) 72809bd41f2cSmrg]) 72819bd41f2cSmrg 72829bd41f2cSmrg# Copyright (C) 2002, 2003, 2005, 2006 Free Software Foundation, Inc. 72839bd41f2cSmrg# 72849bd41f2cSmrg# This file is free software; the Free Software Foundation 72859bd41f2cSmrg# gives unlimited permission to copy and/or distribute it, 72869bd41f2cSmrg# with or without modifications, as long as this notice is preserved. 72879bd41f2cSmrg 72889bd41f2cSmrg# AM_AUTOMAKE_VERSION(VERSION) 72899bd41f2cSmrg# ---------------------------- 72909bd41f2cSmrg# Automake X.Y traces this macro to ensure aclocal.m4 has been 72919bd41f2cSmrg# generated from the m4 files accompanying Automake X.Y. 72929bd41f2cSmrg# (This private macro should not be called outside this file.) 72939bd41f2cSmrgAC_DEFUN([AM_AUTOMAKE_VERSION], 72949bd41f2cSmrg[am__api_version='1.10' 72959bd41f2cSmrgdnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to 72969bd41f2cSmrgdnl require some minimum version. Point them to the right macro. 72979bd41f2cSmrgm4_if([$1], [1.10], [], 72989bd41f2cSmrg [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl 72999bd41f2cSmrg]) 73009bd41f2cSmrg 73019bd41f2cSmrg# _AM_AUTOCONF_VERSION(VERSION) 73029bd41f2cSmrg# ----------------------------- 73039bd41f2cSmrg# aclocal traces this macro to find the Autoconf version. 73049bd41f2cSmrg# This is a private macro too. Using m4_define simplifies 73059bd41f2cSmrg# the logic in aclocal, which can simply ignore this definition. 73069bd41f2cSmrgm4_define([_AM_AUTOCONF_VERSION], []) 73079bd41f2cSmrg 73089bd41f2cSmrg# AM_SET_CURRENT_AUTOMAKE_VERSION 73099bd41f2cSmrg# ------------------------------- 73109bd41f2cSmrg# Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced. 73119bd41f2cSmrg# This function is AC_REQUIREd by AC_INIT_AUTOMAKE. 73129bd41f2cSmrgAC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION], 73139bd41f2cSmrg[AM_AUTOMAKE_VERSION([1.10])dnl 73149bd41f2cSmrg_AM_AUTOCONF_VERSION(m4_PACKAGE_VERSION)]) 73159bd41f2cSmrg 73169bd41f2cSmrg# AM_AUX_DIR_EXPAND -*- Autoconf -*- 73179bd41f2cSmrg 73189bd41f2cSmrg# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. 73199bd41f2cSmrg# 73209bd41f2cSmrg# This file is free software; the Free Software Foundation 73219bd41f2cSmrg# gives unlimited permission to copy and/or distribute it, 73229bd41f2cSmrg# with or without modifications, as long as this notice is preserved. 73239bd41f2cSmrg 73249bd41f2cSmrg# For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets 73259bd41f2cSmrg# $ac_aux_dir to `$srcdir/foo'. In other projects, it is set to 73269bd41f2cSmrg# `$srcdir', `$srcdir/..', or `$srcdir/../..'. 73279bd41f2cSmrg# 73289bd41f2cSmrg# Of course, Automake must honor this variable whenever it calls a 73299bd41f2cSmrg# tool from the auxiliary directory. The problem is that $srcdir (and 73309bd41f2cSmrg# therefore $ac_aux_dir as well) can be either absolute or relative, 73319bd41f2cSmrg# depending on how configure is run. This is pretty annoying, since 73329bd41f2cSmrg# it makes $ac_aux_dir quite unusable in subdirectories: in the top 73339bd41f2cSmrg# source directory, any form will work fine, but in subdirectories a 73349bd41f2cSmrg# relative path needs to be adjusted first. 73359bd41f2cSmrg# 73369bd41f2cSmrg# $ac_aux_dir/missing 73379bd41f2cSmrg# fails when called from a subdirectory if $ac_aux_dir is relative 73389bd41f2cSmrg# $top_srcdir/$ac_aux_dir/missing 73399bd41f2cSmrg# fails if $ac_aux_dir is absolute, 73409bd41f2cSmrg# fails when called from a subdirectory in a VPATH build with 73419bd41f2cSmrg# a relative $ac_aux_dir 73429bd41f2cSmrg# 73439bd41f2cSmrg# The reason of the latter failure is that $top_srcdir and $ac_aux_dir 73449bd41f2cSmrg# are both prefixed by $srcdir. In an in-source build this is usually 73459bd41f2cSmrg# harmless because $srcdir is `.', but things will broke when you 73469bd41f2cSmrg# start a VPATH build or use an absolute $srcdir. 73479bd41f2cSmrg# 73489bd41f2cSmrg# So we could use something similar to $top_srcdir/$ac_aux_dir/missing, 73499bd41f2cSmrg# iff we strip the leading $srcdir from $ac_aux_dir. That would be: 73509bd41f2cSmrg# am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"` 73519bd41f2cSmrg# and then we would define $MISSING as 73529bd41f2cSmrg# MISSING="\${SHELL} $am_aux_dir/missing" 73539bd41f2cSmrg# This will work as long as MISSING is not called from configure, because 73549bd41f2cSmrg# unfortunately $(top_srcdir) has no meaning in configure. 73559bd41f2cSmrg# However there are other variables, like CC, which are often used in 73569bd41f2cSmrg# configure, and could therefore not use this "fixed" $ac_aux_dir. 73579bd41f2cSmrg# 73589bd41f2cSmrg# Another solution, used here, is to always expand $ac_aux_dir to an 73599bd41f2cSmrg# absolute PATH. The drawback is that using absolute paths prevent a 73609bd41f2cSmrg# configured tree to be moved without reconfiguration. 73619bd41f2cSmrg 73629bd41f2cSmrgAC_DEFUN([AM_AUX_DIR_EXPAND], 73639bd41f2cSmrg[dnl Rely on autoconf to set up CDPATH properly. 73649bd41f2cSmrgAC_PREREQ([2.50])dnl 73659bd41f2cSmrg# expand $ac_aux_dir to an absolute path 73669bd41f2cSmrgam_aux_dir=`cd $ac_aux_dir && pwd` 73679bd41f2cSmrg]) 73689bd41f2cSmrg 73699bd41f2cSmrg# AM_CONDITIONAL -*- Autoconf -*- 73709bd41f2cSmrg 73719bd41f2cSmrg# Copyright (C) 1997, 2000, 2001, 2003, 2004, 2005, 2006 73729bd41f2cSmrg# Free Software Foundation, Inc. 73739bd41f2cSmrg# 73749bd41f2cSmrg# This file is free software; the Free Software Foundation 73759bd41f2cSmrg# gives unlimited permission to copy and/or distribute it, 73769bd41f2cSmrg# with or without modifications, as long as this notice is preserved. 73779bd41f2cSmrg 73789bd41f2cSmrg# serial 8 73799bd41f2cSmrg 73809bd41f2cSmrg# AM_CONDITIONAL(NAME, SHELL-CONDITION) 73819bd41f2cSmrg# ------------------------------------- 73829bd41f2cSmrg# Define a conditional. 73839bd41f2cSmrgAC_DEFUN([AM_CONDITIONAL], 73849bd41f2cSmrg[AC_PREREQ(2.52)dnl 73859bd41f2cSmrg ifelse([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])], 73869bd41f2cSmrg [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl 73879bd41f2cSmrgAC_SUBST([$1_TRUE])dnl 73889bd41f2cSmrgAC_SUBST([$1_FALSE])dnl 73899bd41f2cSmrg_AM_SUBST_NOTMAKE([$1_TRUE])dnl 73909bd41f2cSmrg_AM_SUBST_NOTMAKE([$1_FALSE])dnl 73919bd41f2cSmrgif $2; then 73929bd41f2cSmrg $1_TRUE= 73939bd41f2cSmrg $1_FALSE='#' 73949bd41f2cSmrgelse 73959bd41f2cSmrg $1_TRUE='#' 73969bd41f2cSmrg $1_FALSE= 73979bd41f2cSmrgfi 73989bd41f2cSmrgAC_CONFIG_COMMANDS_PRE( 73999bd41f2cSmrg[if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then 74009bd41f2cSmrg AC_MSG_ERROR([[conditional "$1" was never defined. 74019bd41f2cSmrgUsually this means the macro was only invoked conditionally.]]) 74029bd41f2cSmrgfi])]) 74039bd41f2cSmrg 74049bd41f2cSmrg# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006 74059bd41f2cSmrg# Free Software Foundation, Inc. 74069bd41f2cSmrg# 74079bd41f2cSmrg# This file is free software; the Free Software Foundation 74089bd41f2cSmrg# gives unlimited permission to copy and/or distribute it, 74099bd41f2cSmrg# with or without modifications, as long as this notice is preserved. 74109bd41f2cSmrg 74119bd41f2cSmrg# serial 9 74129bd41f2cSmrg 74139bd41f2cSmrg# There are a few dirty hacks below to avoid letting `AC_PROG_CC' be 74149bd41f2cSmrg# written in clear, in which case automake, when reading aclocal.m4, 74159bd41f2cSmrg# will think it sees a *use*, and therefore will trigger all it's 74169bd41f2cSmrg# C support machinery. Also note that it means that autoscan, seeing 74179bd41f2cSmrg# CC etc. in the Makefile, will ask for an AC_PROG_CC use... 74189bd41f2cSmrg 74199bd41f2cSmrg 74209bd41f2cSmrg# _AM_DEPENDENCIES(NAME) 74219bd41f2cSmrg# ---------------------- 74229bd41f2cSmrg# See how the compiler implements dependency checking. 74239bd41f2cSmrg# NAME is "CC", "CXX", "GCJ", or "OBJC". 74249bd41f2cSmrg# We try a few techniques and use that to set a single cache variable. 74259bd41f2cSmrg# 74269bd41f2cSmrg# We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was 74279bd41f2cSmrg# modified to invoke _AM_DEPENDENCIES(CC); we would have a circular 74289bd41f2cSmrg# dependency, and given that the user is not expected to run this macro, 74299bd41f2cSmrg# just rely on AC_PROG_CC. 74309bd41f2cSmrgAC_DEFUN([_AM_DEPENDENCIES], 74319bd41f2cSmrg[AC_REQUIRE([AM_SET_DEPDIR])dnl 74329bd41f2cSmrgAC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl 74339bd41f2cSmrgAC_REQUIRE([AM_MAKE_INCLUDE])dnl 74349bd41f2cSmrgAC_REQUIRE([AM_DEP_TRACK])dnl 74359bd41f2cSmrg 74369bd41f2cSmrgifelse([$1], CC, [depcc="$CC" am_compiler_list=], 74379bd41f2cSmrg [$1], CXX, [depcc="$CXX" am_compiler_list=], 74389bd41f2cSmrg [$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc'], 74399bd41f2cSmrg [$1], UPC, [depcc="$UPC" am_compiler_list=], 74409bd41f2cSmrg [$1], GCJ, [depcc="$GCJ" am_compiler_list='gcc3 gcc'], 74419bd41f2cSmrg [depcc="$$1" am_compiler_list=]) 74429bd41f2cSmrg 74439bd41f2cSmrgAC_CACHE_CHECK([dependency style of $depcc], 74449bd41f2cSmrg [am_cv_$1_dependencies_compiler_type], 74459bd41f2cSmrg[if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then 74469bd41f2cSmrg # We make a subdir and do the tests there. Otherwise we can end up 74479bd41f2cSmrg # making bogus files that we don't know about and never remove. For 74489bd41f2cSmrg # instance it was reported that on HP-UX the gcc test will end up 74499bd41f2cSmrg # making a dummy file named `D' -- because `-MD' means `put the output 74509bd41f2cSmrg # in D'. 74519bd41f2cSmrg mkdir conftest.dir 74529bd41f2cSmrg # Copy depcomp to subdir because otherwise we won't find it if we're 74539bd41f2cSmrg # using a relative directory. 74549bd41f2cSmrg cp "$am_depcomp" conftest.dir 74559bd41f2cSmrg cd conftest.dir 74569bd41f2cSmrg # We will build objects and dependencies in a subdirectory because 74579bd41f2cSmrg # it helps to detect inapplicable dependency modes. For instance 74589bd41f2cSmrg # both Tru64's cc and ICC support -MD to output dependencies as a 74599bd41f2cSmrg # side effect of compilation, but ICC will put the dependencies in 74609bd41f2cSmrg # the current directory while Tru64 will put them in the object 74619bd41f2cSmrg # directory. 74629bd41f2cSmrg mkdir sub 74639bd41f2cSmrg 74649bd41f2cSmrg am_cv_$1_dependencies_compiler_type=none 74659bd41f2cSmrg if test "$am_compiler_list" = ""; then 74669bd41f2cSmrg am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp` 74679bd41f2cSmrg fi 74689bd41f2cSmrg for depmode in $am_compiler_list; do 74699bd41f2cSmrg # Setup a source with many dependencies, because some compilers 74709bd41f2cSmrg # like to wrap large dependency lists on column 80 (with \), and 74719bd41f2cSmrg # we should not choose a depcomp mode which is confused by this. 74729bd41f2cSmrg # 74739bd41f2cSmrg # We need to recreate these files for each test, as the compiler may 74749bd41f2cSmrg # overwrite some of them when testing with obscure command lines. 74759bd41f2cSmrg # This happens at least with the AIX C compiler. 74769bd41f2cSmrg : > sub/conftest.c 74779bd41f2cSmrg for i in 1 2 3 4 5 6; do 74789bd41f2cSmrg echo '#include "conftst'$i'.h"' >> sub/conftest.c 74799bd41f2cSmrg # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with 74809bd41f2cSmrg # Solaris 8's {/usr,}/bin/sh. 74819bd41f2cSmrg touch sub/conftst$i.h 74829bd41f2cSmrg done 74839bd41f2cSmrg echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf 74849bd41f2cSmrg 74859bd41f2cSmrg case $depmode in 74869bd41f2cSmrg nosideeffect) 74879bd41f2cSmrg # after this tag, mechanisms are not by side-effect, so they'll 74889bd41f2cSmrg # only be used when explicitly requested 74899bd41f2cSmrg if test "x$enable_dependency_tracking" = xyes; then 74909bd41f2cSmrg continue 74919bd41f2cSmrg else 74929bd41f2cSmrg break 74939bd41f2cSmrg fi 74949bd41f2cSmrg ;; 74959bd41f2cSmrg none) break ;; 74969bd41f2cSmrg esac 74979bd41f2cSmrg # We check with `-c' and `-o' for the sake of the "dashmstdout" 74989bd41f2cSmrg # mode. It turns out that the SunPro C++ compiler does not properly 74999bd41f2cSmrg # handle `-M -o', and we need to detect this. 75009bd41f2cSmrg if depmode=$depmode \ 75019bd41f2cSmrg source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \ 75029bd41f2cSmrg depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ 75039bd41f2cSmrg $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \ 75049bd41f2cSmrg >/dev/null 2>conftest.err && 75059bd41f2cSmrg grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && 75069bd41f2cSmrg grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && 75079bd41f2cSmrg grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 && 75089bd41f2cSmrg ${MAKE-make} -s -f confmf > /dev/null 2>&1; then 75099bd41f2cSmrg # icc doesn't choke on unknown options, it will just issue warnings 75109bd41f2cSmrg # or remarks (even with -Werror). So we grep stderr for any message 75119bd41f2cSmrg # that says an option was ignored or not supported. 75129bd41f2cSmrg # When given -MP, icc 7.0 and 7.1 complain thusly: 75139bd41f2cSmrg # icc: Command line warning: ignoring option '-M'; no argument required 75149bd41f2cSmrg # The diagnosis changed in icc 8.0: 75159bd41f2cSmrg # icc: Command line remark: option '-MP' not supported 75169bd41f2cSmrg if (grep 'ignoring option' conftest.err || 75179bd41f2cSmrg grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else 75189bd41f2cSmrg am_cv_$1_dependencies_compiler_type=$depmode 75199bd41f2cSmrg break 75209bd41f2cSmrg fi 75219bd41f2cSmrg fi 75229bd41f2cSmrg done 75239bd41f2cSmrg 75249bd41f2cSmrg cd .. 75259bd41f2cSmrg rm -rf conftest.dir 75269bd41f2cSmrgelse 75279bd41f2cSmrg am_cv_$1_dependencies_compiler_type=none 75289bd41f2cSmrgfi 75299bd41f2cSmrg]) 75309bd41f2cSmrgAC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type]) 75319bd41f2cSmrgAM_CONDITIONAL([am__fastdep$1], [ 75329bd41f2cSmrg test "x$enable_dependency_tracking" != xno \ 75339bd41f2cSmrg && test "$am_cv_$1_dependencies_compiler_type" = gcc3]) 75349bd41f2cSmrg]) 75359bd41f2cSmrg 75369bd41f2cSmrg 75379bd41f2cSmrg# AM_SET_DEPDIR 75389bd41f2cSmrg# ------------- 75399bd41f2cSmrg# Choose a directory name for dependency files. 75409bd41f2cSmrg# This macro is AC_REQUIREd in _AM_DEPENDENCIES 75419bd41f2cSmrgAC_DEFUN([AM_SET_DEPDIR], 75429bd41f2cSmrg[AC_REQUIRE([AM_SET_LEADING_DOT])dnl 75439bd41f2cSmrgAC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl 75449bd41f2cSmrg]) 75459bd41f2cSmrg 75469bd41f2cSmrg 75479bd41f2cSmrg# AM_DEP_TRACK 75489bd41f2cSmrg# ------------ 75499bd41f2cSmrgAC_DEFUN([AM_DEP_TRACK], 75509bd41f2cSmrg[AC_ARG_ENABLE(dependency-tracking, 75519bd41f2cSmrg[ --disable-dependency-tracking speeds up one-time build 75529bd41f2cSmrg --enable-dependency-tracking do not reject slow dependency extractors]) 75539bd41f2cSmrgif test "x$enable_dependency_tracking" != xno; then 75549bd41f2cSmrg am_depcomp="$ac_aux_dir/depcomp" 75559bd41f2cSmrg AMDEPBACKSLASH='\' 75569bd41f2cSmrgfi 75579bd41f2cSmrgAM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno]) 75589bd41f2cSmrgAC_SUBST([AMDEPBACKSLASH])dnl 75599bd41f2cSmrg_AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl 75609bd41f2cSmrg]) 75619bd41f2cSmrg 75629bd41f2cSmrg# Generate code to set up dependency tracking. -*- Autoconf -*- 75639bd41f2cSmrg 75649bd41f2cSmrg# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005 75659bd41f2cSmrg# Free Software Foundation, Inc. 75669bd41f2cSmrg# 75679bd41f2cSmrg# This file is free software; the Free Software Foundation 75689bd41f2cSmrg# gives unlimited permission to copy and/or distribute it, 75699bd41f2cSmrg# with or without modifications, as long as this notice is preserved. 75709bd41f2cSmrg 75719bd41f2cSmrg#serial 3 75729bd41f2cSmrg 75739bd41f2cSmrg# _AM_OUTPUT_DEPENDENCY_COMMANDS 75749bd41f2cSmrg# ------------------------------ 75759bd41f2cSmrgAC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], 75769bd41f2cSmrg[for mf in $CONFIG_FILES; do 75779bd41f2cSmrg # Strip MF so we end up with the name of the file. 75789bd41f2cSmrg mf=`echo "$mf" | sed -e 's/:.*$//'` 75799bd41f2cSmrg # Check whether this is an Automake generated Makefile or not. 75809bd41f2cSmrg # We used to match only the files named `Makefile.in', but 75819bd41f2cSmrg # some people rename them; so instead we look at the file content. 75829bd41f2cSmrg # Grep'ing the first line is not enough: some people post-process 75839bd41f2cSmrg # each Makefile.in and add a new line on top of each file to say so. 75849bd41f2cSmrg # Grep'ing the whole file is not good either: AIX grep has a line 75859bd41f2cSmrg # limit of 2048, but all sed's we know have understand at least 4000. 75869bd41f2cSmrg if sed 10q "$mf" | grep '^#.*generated by automake' > /dev/null 2>&1; then 75879bd41f2cSmrg dirpart=`AS_DIRNAME("$mf")` 75889bd41f2cSmrg else 75899bd41f2cSmrg continue 75909bd41f2cSmrg fi 75919bd41f2cSmrg # Extract the definition of DEPDIR, am__include, and am__quote 75929bd41f2cSmrg # from the Makefile without running `make'. 75939bd41f2cSmrg DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` 75949bd41f2cSmrg test -z "$DEPDIR" && continue 75959bd41f2cSmrg am__include=`sed -n 's/^am__include = //p' < "$mf"` 75969bd41f2cSmrg test -z "am__include" && continue 75979bd41f2cSmrg am__quote=`sed -n 's/^am__quote = //p' < "$mf"` 75989bd41f2cSmrg # When using ansi2knr, U may be empty or an underscore; expand it 75999bd41f2cSmrg U=`sed -n 's/^U = //p' < "$mf"` 76009bd41f2cSmrg # Find all dependency output files, they are included files with 76019bd41f2cSmrg # $(DEPDIR) in their names. We invoke sed twice because it is the 76029bd41f2cSmrg # simplest approach to changing $(DEPDIR) to its actual value in the 76039bd41f2cSmrg # expansion. 76049bd41f2cSmrg for file in `sed -n " 76059bd41f2cSmrg s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ 76069bd41f2cSmrg sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do 76079bd41f2cSmrg # Make sure the directory exists. 76089bd41f2cSmrg test -f "$dirpart/$file" && continue 76099bd41f2cSmrg fdir=`AS_DIRNAME(["$file"])` 76109bd41f2cSmrg AS_MKDIR_P([$dirpart/$fdir]) 76119bd41f2cSmrg # echo "creating $dirpart/$file" 76129bd41f2cSmrg echo '# dummy' > "$dirpart/$file" 76139bd41f2cSmrg done 76149bd41f2cSmrgdone 76159bd41f2cSmrg])# _AM_OUTPUT_DEPENDENCY_COMMANDS 76169bd41f2cSmrg 76179bd41f2cSmrg 76189bd41f2cSmrg# AM_OUTPUT_DEPENDENCY_COMMANDS 76199bd41f2cSmrg# ----------------------------- 76209bd41f2cSmrg# This macro should only be invoked once -- use via AC_REQUIRE. 76219bd41f2cSmrg# 76229bd41f2cSmrg# This code is only required when automatic dependency tracking 76239bd41f2cSmrg# is enabled. FIXME. This creates each `.P' file that we will 76249bd41f2cSmrg# need in order to bootstrap the dependency handling code. 76259bd41f2cSmrgAC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS], 76269bd41f2cSmrg[AC_CONFIG_COMMANDS([depfiles], 76279bd41f2cSmrg [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS], 76289bd41f2cSmrg [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"]) 76299bd41f2cSmrg]) 76309bd41f2cSmrg 76319bd41f2cSmrg# Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005 76329bd41f2cSmrg# Free Software Foundation, Inc. 76339bd41f2cSmrg# 76349bd41f2cSmrg# This file is free software; the Free Software Foundation 76359bd41f2cSmrg# gives unlimited permission to copy and/or distribute it, 76369bd41f2cSmrg# with or without modifications, as long as this notice is preserved. 76379bd41f2cSmrg 76389bd41f2cSmrg# serial 8 76399bd41f2cSmrg 76409bd41f2cSmrg# AM_CONFIG_HEADER is obsolete. It has been replaced by AC_CONFIG_HEADERS. 76419bd41f2cSmrgAU_DEFUN([AM_CONFIG_HEADER], [AC_CONFIG_HEADERS($@)]) 76429bd41f2cSmrg 76439bd41f2cSmrg# Do all the work for Automake. -*- Autoconf -*- 76449bd41f2cSmrg 76459bd41f2cSmrg# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 76469bd41f2cSmrg# 2005, 2006 Free Software Foundation, Inc. 76479bd41f2cSmrg# 76489bd41f2cSmrg# This file is free software; the Free Software Foundation 76499bd41f2cSmrg# gives unlimited permission to copy and/or distribute it, 76509bd41f2cSmrg# with or without modifications, as long as this notice is preserved. 76519bd41f2cSmrg 76529bd41f2cSmrg# serial 12 76539bd41f2cSmrg 76549bd41f2cSmrg# This macro actually does too much. Some checks are only needed if 76559bd41f2cSmrg# your package does certain things. But this isn't really a big deal. 76569bd41f2cSmrg 76579bd41f2cSmrg# AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE]) 76589bd41f2cSmrg# AM_INIT_AUTOMAKE([OPTIONS]) 76599bd41f2cSmrg# ----------------------------------------------- 76609bd41f2cSmrg# The call with PACKAGE and VERSION arguments is the old style 76619bd41f2cSmrg# call (pre autoconf-2.50), which is being phased out. PACKAGE 76629bd41f2cSmrg# and VERSION should now be passed to AC_INIT and removed from 76639bd41f2cSmrg# the call to AM_INIT_AUTOMAKE. 76649bd41f2cSmrg# We support both call styles for the transition. After 76659bd41f2cSmrg# the next Automake release, Autoconf can make the AC_INIT 76669bd41f2cSmrg# arguments mandatory, and then we can depend on a new Autoconf 76679bd41f2cSmrg# release and drop the old call support. 76689bd41f2cSmrgAC_DEFUN([AM_INIT_AUTOMAKE], 76699bd41f2cSmrg[AC_PREREQ([2.60])dnl 76709bd41f2cSmrgdnl Autoconf wants to disallow AM_ names. We explicitly allow 76719bd41f2cSmrgdnl the ones we care about. 76729bd41f2cSmrgm4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl 76739bd41f2cSmrgAC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl 76749bd41f2cSmrgAC_REQUIRE([AC_PROG_INSTALL])dnl 76759bd41f2cSmrgif test "`cd $srcdir && pwd`" != "`pwd`"; then 76769bd41f2cSmrg # Use -I$(srcdir) only when $(srcdir) != ., so that make's output 76779bd41f2cSmrg # is not polluted with repeated "-I." 76789bd41f2cSmrg AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl 76799bd41f2cSmrg # test to see if srcdir already configured 76809bd41f2cSmrg if test -f $srcdir/config.status; then 76819bd41f2cSmrg AC_MSG_ERROR([source directory already configured; run "make distclean" there first]) 76829bd41f2cSmrg fi 76839bd41f2cSmrgfi 76849bd41f2cSmrg 76859bd41f2cSmrg# test whether we have cygpath 76869bd41f2cSmrgif test -z "$CYGPATH_W"; then 76879bd41f2cSmrg if (cygpath --version) >/dev/null 2>/dev/null; then 76889bd41f2cSmrg CYGPATH_W='cygpath -w' 76899bd41f2cSmrg else 76909bd41f2cSmrg CYGPATH_W=echo 76919bd41f2cSmrg fi 76929bd41f2cSmrgfi 76939bd41f2cSmrgAC_SUBST([CYGPATH_W]) 76949bd41f2cSmrg 76959bd41f2cSmrg# Define the identity of the package. 76969bd41f2cSmrgdnl Distinguish between old-style and new-style calls. 76979bd41f2cSmrgm4_ifval([$2], 76989bd41f2cSmrg[m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl 76999bd41f2cSmrg AC_SUBST([PACKAGE], [$1])dnl 77009bd41f2cSmrg AC_SUBST([VERSION], [$2])], 77019bd41f2cSmrg[_AM_SET_OPTIONS([$1])dnl 77029bd41f2cSmrgdnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT. 77039bd41f2cSmrgm4_if(m4_ifdef([AC_PACKAGE_NAME], 1)m4_ifdef([AC_PACKAGE_VERSION], 1), 11,, 77049bd41f2cSmrg [m4_fatal([AC_INIT should be called with package and version arguments])])dnl 77059bd41f2cSmrg AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl 77069bd41f2cSmrg AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl 77079bd41f2cSmrg 77089bd41f2cSmrg_AM_IF_OPTION([no-define],, 77099bd41f2cSmrg[AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package]) 77109bd41f2cSmrg AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl 77119bd41f2cSmrg 77129bd41f2cSmrg# Some tools Automake needs. 77139bd41f2cSmrgAC_REQUIRE([AM_SANITY_CHECK])dnl 77149bd41f2cSmrgAC_REQUIRE([AC_ARG_PROGRAM])dnl 77159bd41f2cSmrgAM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version}) 77169bd41f2cSmrgAM_MISSING_PROG(AUTOCONF, autoconf) 77179bd41f2cSmrgAM_MISSING_PROG(AUTOMAKE, automake-${am__api_version}) 77189bd41f2cSmrgAM_MISSING_PROG(AUTOHEADER, autoheader) 77199bd41f2cSmrgAM_MISSING_PROG(MAKEINFO, makeinfo) 77209bd41f2cSmrgAM_PROG_INSTALL_SH 77219bd41f2cSmrgAM_PROG_INSTALL_STRIP 77229bd41f2cSmrgAC_REQUIRE([AM_PROG_MKDIR_P])dnl 77239bd41f2cSmrg# We need awk for the "check" target. The system "awk" is bad on 77249bd41f2cSmrg# some platforms. 77259bd41f2cSmrgAC_REQUIRE([AC_PROG_AWK])dnl 77269bd41f2cSmrgAC_REQUIRE([AC_PROG_MAKE_SET])dnl 77279bd41f2cSmrgAC_REQUIRE([AM_SET_LEADING_DOT])dnl 77289bd41f2cSmrg_AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])], 77299bd41f2cSmrg [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])], 77309bd41f2cSmrg [_AM_PROG_TAR([v7])])]) 77319bd41f2cSmrg_AM_IF_OPTION([no-dependencies],, 77329bd41f2cSmrg[AC_PROVIDE_IFELSE([AC_PROG_CC], 77339bd41f2cSmrg [_AM_DEPENDENCIES(CC)], 77349bd41f2cSmrg [define([AC_PROG_CC], 77359bd41f2cSmrg defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl 77369bd41f2cSmrgAC_PROVIDE_IFELSE([AC_PROG_CXX], 77379bd41f2cSmrg [_AM_DEPENDENCIES(CXX)], 77389bd41f2cSmrg [define([AC_PROG_CXX], 77399bd41f2cSmrg defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl 77409bd41f2cSmrgAC_PROVIDE_IFELSE([AC_PROG_OBJC], 77419bd41f2cSmrg [_AM_DEPENDENCIES(OBJC)], 77429bd41f2cSmrg [define([AC_PROG_OBJC], 77439bd41f2cSmrg defn([AC_PROG_OBJC])[_AM_DEPENDENCIES(OBJC)])])dnl 77449bd41f2cSmrg]) 77459bd41f2cSmrg]) 77469bd41f2cSmrg 77479bd41f2cSmrg 77489bd41f2cSmrg# When config.status generates a header, we must update the stamp-h file. 77499bd41f2cSmrg# This file resides in the same directory as the config header 77509bd41f2cSmrg# that is generated. The stamp files are numbered to have different names. 77519bd41f2cSmrg 77529bd41f2cSmrg# Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the 77539bd41f2cSmrg# loop where config.status creates the headers, so we can generate 77549bd41f2cSmrg# our stamp files there. 77559bd41f2cSmrgAC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK], 77569bd41f2cSmrg[# Compute $1's index in $config_headers. 77579bd41f2cSmrg_am_stamp_count=1 77589bd41f2cSmrgfor _am_header in $config_headers :; do 77599bd41f2cSmrg case $_am_header in 77609bd41f2cSmrg $1 | $1:* ) 77619bd41f2cSmrg break ;; 77629bd41f2cSmrg * ) 77639bd41f2cSmrg _am_stamp_count=`expr $_am_stamp_count + 1` ;; 77649bd41f2cSmrg esac 77659bd41f2cSmrgdone 77669bd41f2cSmrgecho "timestamp for $1" >`AS_DIRNAME([$1])`/stamp-h[]$_am_stamp_count]) 77679bd41f2cSmrg 77689bd41f2cSmrg# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. 77699bd41f2cSmrg# 77709bd41f2cSmrg# This file is free software; the Free Software Foundation 77719bd41f2cSmrg# gives unlimited permission to copy and/or distribute it, 77729bd41f2cSmrg# with or without modifications, as long as this notice is preserved. 77739bd41f2cSmrg 77749bd41f2cSmrg# AM_PROG_INSTALL_SH 77759bd41f2cSmrg# ------------------ 77769bd41f2cSmrg# Define $install_sh. 77779bd41f2cSmrgAC_DEFUN([AM_PROG_INSTALL_SH], 77789bd41f2cSmrg[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl 77799bd41f2cSmrginstall_sh=${install_sh-"\$(SHELL) $am_aux_dir/install-sh"} 77809bd41f2cSmrgAC_SUBST(install_sh)]) 77819bd41f2cSmrg 77829bd41f2cSmrg# Copyright (C) 2003, 2005 Free Software Foundation, Inc. 77839bd41f2cSmrg# 77849bd41f2cSmrg# This file is free software; the Free Software Foundation 77859bd41f2cSmrg# gives unlimited permission to copy and/or distribute it, 77869bd41f2cSmrg# with or without modifications, as long as this notice is preserved. 77879bd41f2cSmrg 77889bd41f2cSmrg# serial 2 77899bd41f2cSmrg 77909bd41f2cSmrg# Check whether the underlying file-system supports filenames 77919bd41f2cSmrg# with a leading dot. For instance MS-DOS doesn't. 77929bd41f2cSmrgAC_DEFUN([AM_SET_LEADING_DOT], 77939bd41f2cSmrg[rm -rf .tst 2>/dev/null 77949bd41f2cSmrgmkdir .tst 2>/dev/null 77959bd41f2cSmrgif test -d .tst; then 77969bd41f2cSmrg am__leading_dot=. 77979bd41f2cSmrgelse 77989bd41f2cSmrg am__leading_dot=_ 77999bd41f2cSmrgfi 78009bd41f2cSmrgrmdir .tst 2>/dev/null 78019bd41f2cSmrgAC_SUBST([am__leading_dot])]) 78029bd41f2cSmrg 78039bd41f2cSmrg# Add --enable-maintainer-mode option to configure. -*- Autoconf -*- 78049bd41f2cSmrg# From Jim Meyering 78059bd41f2cSmrg 78069bd41f2cSmrg# Copyright (C) 1996, 1998, 2000, 2001, 2002, 2003, 2004, 2005 78079bd41f2cSmrg# Free Software Foundation, Inc. 78089bd41f2cSmrg# 78099bd41f2cSmrg# This file is free software; the Free Software Foundation 78109bd41f2cSmrg# gives unlimited permission to copy and/or distribute it, 78119bd41f2cSmrg# with or without modifications, as long as this notice is preserved. 78129bd41f2cSmrg 78139bd41f2cSmrg# serial 4 78149bd41f2cSmrg 78159bd41f2cSmrgAC_DEFUN([AM_MAINTAINER_MODE], 78169bd41f2cSmrg[AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles]) 78179bd41f2cSmrg dnl maintainer-mode is disabled by default 78189bd41f2cSmrg AC_ARG_ENABLE(maintainer-mode, 78199bd41f2cSmrg[ --enable-maintainer-mode enable make rules and dependencies not useful 78209bd41f2cSmrg (and sometimes confusing) to the casual installer], 78219bd41f2cSmrg USE_MAINTAINER_MODE=$enableval, 78229bd41f2cSmrg USE_MAINTAINER_MODE=no) 78239bd41f2cSmrg AC_MSG_RESULT([$USE_MAINTAINER_MODE]) 78249bd41f2cSmrg AM_CONDITIONAL(MAINTAINER_MODE, [test $USE_MAINTAINER_MODE = yes]) 78259bd41f2cSmrg MAINT=$MAINTAINER_MODE_TRUE 78269bd41f2cSmrg AC_SUBST(MAINT)dnl 78279bd41f2cSmrg] 78289bd41f2cSmrg) 78299bd41f2cSmrg 78309bd41f2cSmrgAU_DEFUN([jm_MAINTAINER_MODE], [AM_MAINTAINER_MODE]) 78319bd41f2cSmrg 78329bd41f2cSmrg# Check to see how 'make' treats includes. -*- Autoconf -*- 78339bd41f2cSmrg 78349bd41f2cSmrg# Copyright (C) 2001, 2002, 2003, 2005 Free Software Foundation, Inc. 78359bd41f2cSmrg# 78369bd41f2cSmrg# This file is free software; the Free Software Foundation 78379bd41f2cSmrg# gives unlimited permission to copy and/or distribute it, 78389bd41f2cSmrg# with or without modifications, as long as this notice is preserved. 78399bd41f2cSmrg 78409bd41f2cSmrg# serial 3 78419bd41f2cSmrg 78429bd41f2cSmrg# AM_MAKE_INCLUDE() 78439bd41f2cSmrg# ----------------- 78449bd41f2cSmrg# Check to see how make treats includes. 78459bd41f2cSmrgAC_DEFUN([AM_MAKE_INCLUDE], 78469bd41f2cSmrg[am_make=${MAKE-make} 78479bd41f2cSmrgcat > confinc << 'END' 78489bd41f2cSmrgam__doit: 78499bd41f2cSmrg @echo done 78509bd41f2cSmrg.PHONY: am__doit 78519bd41f2cSmrgEND 78529bd41f2cSmrg# If we don't find an include directive, just comment out the code. 78539bd41f2cSmrgAC_MSG_CHECKING([for style of include used by $am_make]) 78549bd41f2cSmrgam__include="#" 78559bd41f2cSmrgam__quote= 78569bd41f2cSmrg_am_result=none 78579bd41f2cSmrg# First try GNU make style include. 78589bd41f2cSmrgecho "include confinc" > confmf 78599bd41f2cSmrg# We grep out `Entering directory' and `Leaving directory' 78609bd41f2cSmrg# messages which can occur if `w' ends up in MAKEFLAGS. 78619bd41f2cSmrg# In particular we don't look at `^make:' because GNU make might 78629bd41f2cSmrg# be invoked under some other name (usually "gmake"), in which 78639bd41f2cSmrg# case it prints its new name instead of `make'. 78649bd41f2cSmrgif test "`$am_make -s -f confmf 2> /dev/null | grep -v 'ing directory'`" = "done"; then 78659bd41f2cSmrg am__include=include 78669bd41f2cSmrg am__quote= 78679bd41f2cSmrg _am_result=GNU 78689bd41f2cSmrgfi 78699bd41f2cSmrg# Now try BSD make style include. 78709bd41f2cSmrgif test "$am__include" = "#"; then 78719bd41f2cSmrg echo '.include "confinc"' > confmf 78729bd41f2cSmrg if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then 78739bd41f2cSmrg am__include=.include 78749bd41f2cSmrg am__quote="\"" 78759bd41f2cSmrg _am_result=BSD 78769bd41f2cSmrg fi 78779bd41f2cSmrgfi 78789bd41f2cSmrgAC_SUBST([am__include]) 78799bd41f2cSmrgAC_SUBST([am__quote]) 78809bd41f2cSmrgAC_MSG_RESULT([$_am_result]) 78819bd41f2cSmrgrm -f confinc confmf 78829bd41f2cSmrg]) 78839bd41f2cSmrg 78849bd41f2cSmrg# Fake the existence of programs that GNU maintainers use. -*- Autoconf -*- 78859bd41f2cSmrg 78869bd41f2cSmrg# Copyright (C) 1997, 1999, 2000, 2001, 2003, 2004, 2005 78879bd41f2cSmrg# Free Software Foundation, Inc. 78889bd41f2cSmrg# 78899bd41f2cSmrg# This file is free software; the Free Software Foundation 78909bd41f2cSmrg# gives unlimited permission to copy and/or distribute it, 78919bd41f2cSmrg# with or without modifications, as long as this notice is preserved. 78929bd41f2cSmrg 78939bd41f2cSmrg# serial 5 78949bd41f2cSmrg 78959bd41f2cSmrg# AM_MISSING_PROG(NAME, PROGRAM) 78969bd41f2cSmrg# ------------------------------ 78979bd41f2cSmrgAC_DEFUN([AM_MISSING_PROG], 78989bd41f2cSmrg[AC_REQUIRE([AM_MISSING_HAS_RUN]) 78999bd41f2cSmrg$1=${$1-"${am_missing_run}$2"} 79009bd41f2cSmrgAC_SUBST($1)]) 79019bd41f2cSmrg 79029bd41f2cSmrg 79039bd41f2cSmrg# AM_MISSING_HAS_RUN 79049bd41f2cSmrg# ------------------ 79059bd41f2cSmrg# Define MISSING if not defined so far and test if it supports --run. 79069bd41f2cSmrg# If it does, set am_missing_run to use it, otherwise, to nothing. 79079bd41f2cSmrgAC_DEFUN([AM_MISSING_HAS_RUN], 79089bd41f2cSmrg[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl 79099bd41f2cSmrgAC_REQUIRE_AUX_FILE([missing])dnl 79109bd41f2cSmrgtest x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing" 79119bd41f2cSmrg# Use eval to expand $SHELL 79129bd41f2cSmrgif eval "$MISSING --run true"; then 79139bd41f2cSmrg am_missing_run="$MISSING --run " 79149bd41f2cSmrgelse 79159bd41f2cSmrg am_missing_run= 79169bd41f2cSmrg AC_MSG_WARN([`missing' script is too old or missing]) 79179bd41f2cSmrgfi 79189bd41f2cSmrg]) 79199bd41f2cSmrg 79209bd41f2cSmrg# Copyright (C) 2003, 2004, 2005, 2006 Free Software Foundation, Inc. 79219bd41f2cSmrg# 79229bd41f2cSmrg# This file is free software; the Free Software Foundation 79239bd41f2cSmrg# gives unlimited permission to copy and/or distribute it, 79249bd41f2cSmrg# with or without modifications, as long as this notice is preserved. 79259bd41f2cSmrg 79269bd41f2cSmrg# AM_PROG_MKDIR_P 79279bd41f2cSmrg# --------------- 79289bd41f2cSmrg# Check for `mkdir -p'. 79299bd41f2cSmrgAC_DEFUN([AM_PROG_MKDIR_P], 79309bd41f2cSmrg[AC_PREREQ([2.60])dnl 79319bd41f2cSmrgAC_REQUIRE([AC_PROG_MKDIR_P])dnl 79329bd41f2cSmrgdnl Automake 1.8 to 1.9.6 used to define mkdir_p. We now use MKDIR_P, 79339bd41f2cSmrgdnl while keeping a definition of mkdir_p for backward compatibility. 79349bd41f2cSmrgdnl @MKDIR_P@ is magic: AC_OUTPUT adjusts its value for each Makefile. 79359bd41f2cSmrgdnl However we cannot define mkdir_p as $(MKDIR_P) for the sake of 79369bd41f2cSmrgdnl Makefile.ins that do not define MKDIR_P, so we do our own 79379bd41f2cSmrgdnl adjustment using top_builddir (which is defined more often than 79389bd41f2cSmrgdnl MKDIR_P). 79399bd41f2cSmrgAC_SUBST([mkdir_p], ["$MKDIR_P"])dnl 79409bd41f2cSmrgcase $mkdir_p in 79419bd41f2cSmrg [[\\/$]]* | ?:[[\\/]]*) ;; 79429bd41f2cSmrg */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;; 79439bd41f2cSmrgesac 79449bd41f2cSmrg]) 79459bd41f2cSmrg 79469bd41f2cSmrg# Helper functions for option handling. -*- Autoconf -*- 79479bd41f2cSmrg 79489bd41f2cSmrg# Copyright (C) 2001, 2002, 2003, 2005 Free Software Foundation, Inc. 79499bd41f2cSmrg# 79509bd41f2cSmrg# This file is free software; the Free Software Foundation 79519bd41f2cSmrg# gives unlimited permission to copy and/or distribute it, 79529bd41f2cSmrg# with or without modifications, as long as this notice is preserved. 79539bd41f2cSmrg 79549bd41f2cSmrg# serial 3 79559bd41f2cSmrg 79569bd41f2cSmrg# _AM_MANGLE_OPTION(NAME) 79579bd41f2cSmrg# ----------------------- 79589bd41f2cSmrgAC_DEFUN([_AM_MANGLE_OPTION], 79599bd41f2cSmrg[[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])]) 79609bd41f2cSmrg 79619bd41f2cSmrg# _AM_SET_OPTION(NAME) 79629bd41f2cSmrg# ------------------------------ 79639bd41f2cSmrg# Set option NAME. Presently that only means defining a flag for this option. 79649bd41f2cSmrgAC_DEFUN([_AM_SET_OPTION], 79659bd41f2cSmrg[m4_define(_AM_MANGLE_OPTION([$1]), 1)]) 79669bd41f2cSmrg 79679bd41f2cSmrg# _AM_SET_OPTIONS(OPTIONS) 79689bd41f2cSmrg# ---------------------------------- 79699bd41f2cSmrg# OPTIONS is a space-separated list of Automake options. 79709bd41f2cSmrgAC_DEFUN([_AM_SET_OPTIONS], 79719bd41f2cSmrg[AC_FOREACH([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])]) 79729bd41f2cSmrg 79739bd41f2cSmrg# _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET]) 79749bd41f2cSmrg# ------------------------------------------- 79759bd41f2cSmrg# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. 79769bd41f2cSmrgAC_DEFUN([_AM_IF_OPTION], 79779bd41f2cSmrg[m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])]) 79789bd41f2cSmrg 79799bd41f2cSmrg# Check to make sure that the build environment is sane. -*- Autoconf -*- 79809bd41f2cSmrg 79819bd41f2cSmrg# Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005 79829bd41f2cSmrg# Free Software Foundation, Inc. 79839bd41f2cSmrg# 79849bd41f2cSmrg# This file is free software; the Free Software Foundation 79859bd41f2cSmrg# gives unlimited permission to copy and/or distribute it, 79869bd41f2cSmrg# with or without modifications, as long as this notice is preserved. 79879bd41f2cSmrg 79889bd41f2cSmrg# serial 4 79899bd41f2cSmrg 79909bd41f2cSmrg# AM_SANITY_CHECK 79919bd41f2cSmrg# --------------- 79929bd41f2cSmrgAC_DEFUN([AM_SANITY_CHECK], 79939bd41f2cSmrg[AC_MSG_CHECKING([whether build environment is sane]) 79949bd41f2cSmrg# Just in case 79959bd41f2cSmrgsleep 1 79969bd41f2cSmrgecho timestamp > conftest.file 79979bd41f2cSmrg# Do `set' in a subshell so we don't clobber the current shell's 79989bd41f2cSmrg# arguments. Must try -L first in case configure is actually a 79999bd41f2cSmrg# symlink; some systems play weird games with the mod time of symlinks 80009bd41f2cSmrg# (eg FreeBSD returns the mod time of the symlink's containing 80019bd41f2cSmrg# directory). 80029bd41f2cSmrgif ( 80039bd41f2cSmrg set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null` 80049bd41f2cSmrg if test "$[*]" = "X"; then 80059bd41f2cSmrg # -L didn't work. 80069bd41f2cSmrg set X `ls -t $srcdir/configure conftest.file` 80079bd41f2cSmrg fi 80089bd41f2cSmrg rm -f conftest.file 80099bd41f2cSmrg if test "$[*]" != "X $srcdir/configure conftest.file" \ 80109bd41f2cSmrg && test "$[*]" != "X conftest.file $srcdir/configure"; then 80119bd41f2cSmrg 80129bd41f2cSmrg # If neither matched, then we have a broken ls. This can happen 80139bd41f2cSmrg # if, for instance, CONFIG_SHELL is bash and it inherits a 80149bd41f2cSmrg # broken ls alias from the environment. This has actually 80159bd41f2cSmrg # happened. Such a system could not be considered "sane". 80169bd41f2cSmrg AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken 80179bd41f2cSmrgalias in your environment]) 80189bd41f2cSmrg fi 80199bd41f2cSmrg 80209bd41f2cSmrg test "$[2]" = conftest.file 80219bd41f2cSmrg ) 80229bd41f2cSmrgthen 80239bd41f2cSmrg # Ok. 80249bd41f2cSmrg : 80259bd41f2cSmrgelse 80269bd41f2cSmrg AC_MSG_ERROR([newly created file is older than distributed files! 80279bd41f2cSmrgCheck your system clock]) 80289bd41f2cSmrgfi 80299bd41f2cSmrgAC_MSG_RESULT(yes)]) 80309bd41f2cSmrg 80319bd41f2cSmrg# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. 80329bd41f2cSmrg# 80339bd41f2cSmrg# This file is free software; the Free Software Foundation 80349bd41f2cSmrg# gives unlimited permission to copy and/or distribute it, 80359bd41f2cSmrg# with or without modifications, as long as this notice is preserved. 80369bd41f2cSmrg 80379bd41f2cSmrg# AM_PROG_INSTALL_STRIP 80389bd41f2cSmrg# --------------------- 80399bd41f2cSmrg# One issue with vendor `install' (even GNU) is that you can't 80409bd41f2cSmrg# specify the program used to strip binaries. This is especially 80419bd41f2cSmrg# annoying in cross-compiling environments, where the build's strip 80429bd41f2cSmrg# is unlikely to handle the host's binaries. 80439bd41f2cSmrg# Fortunately install-sh will honor a STRIPPROG variable, so we 80449bd41f2cSmrg# always use install-sh in `make install-strip', and initialize 80459bd41f2cSmrg# STRIPPROG with the value of the STRIP variable (set by the user). 80469bd41f2cSmrgAC_DEFUN([AM_PROG_INSTALL_STRIP], 80479bd41f2cSmrg[AC_REQUIRE([AM_PROG_INSTALL_SH])dnl 80489bd41f2cSmrg# Installed binaries are usually stripped using `strip' when the user 80499bd41f2cSmrg# run `make install-strip'. However `strip' might not be the right 80509bd41f2cSmrg# tool to use in cross-compilation environments, therefore Automake 80519bd41f2cSmrg# will honor the `STRIP' environment variable to overrule this program. 80529bd41f2cSmrgdnl Don't test for $cross_compiling = yes, because it might be `maybe'. 80539bd41f2cSmrgif test "$cross_compiling" != no; then 80549bd41f2cSmrg AC_CHECK_TOOL([STRIP], [strip], :) 80559bd41f2cSmrgfi 80569bd41f2cSmrgINSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" 80579bd41f2cSmrgAC_SUBST([INSTALL_STRIP_PROGRAM])]) 80589bd41f2cSmrg 80599bd41f2cSmrg# Copyright (C) 2006 Free Software Foundation, Inc. 80609bd41f2cSmrg# 80619bd41f2cSmrg# This file is free software; the Free Software Foundation 80629bd41f2cSmrg# gives unlimited permission to copy and/or distribute it, 80639bd41f2cSmrg# with or without modifications, as long as this notice is preserved. 80649bd41f2cSmrg 80659bd41f2cSmrg# _AM_SUBST_NOTMAKE(VARIABLE) 80669bd41f2cSmrg# --------------------------- 80679bd41f2cSmrg# Prevent Automake from outputing VARIABLE = @VARIABLE@ in Makefile.in. 80689bd41f2cSmrg# This macro is traced by Automake. 80699bd41f2cSmrgAC_DEFUN([_AM_SUBST_NOTMAKE]) 80709bd41f2cSmrg 80719bd41f2cSmrg# Check how to create a tarball. -*- Autoconf -*- 80729bd41f2cSmrg 80739bd41f2cSmrg# Copyright (C) 2004, 2005 Free Software Foundation, Inc. 80749bd41f2cSmrg# 80759bd41f2cSmrg# This file is free software; the Free Software Foundation 80769bd41f2cSmrg# gives unlimited permission to copy and/or distribute it, 80779bd41f2cSmrg# with or without modifications, as long as this notice is preserved. 80789bd41f2cSmrg 80799bd41f2cSmrg# serial 2 80809bd41f2cSmrg 80819bd41f2cSmrg# _AM_PROG_TAR(FORMAT) 80829bd41f2cSmrg# -------------------- 80839bd41f2cSmrg# Check how to create a tarball in format FORMAT. 80849bd41f2cSmrg# FORMAT should be one of `v7', `ustar', or `pax'. 80859bd41f2cSmrg# 80869bd41f2cSmrg# Substitute a variable $(am__tar) that is a command 80879bd41f2cSmrg# writing to stdout a FORMAT-tarball containing the directory 80889bd41f2cSmrg# $tardir. 80899bd41f2cSmrg# tardir=directory && $(am__tar) > result.tar 80909bd41f2cSmrg# 80919bd41f2cSmrg# Substitute a variable $(am__untar) that extract such 80929bd41f2cSmrg# a tarball read from stdin. 80939bd41f2cSmrg# $(am__untar) < result.tar 80949bd41f2cSmrgAC_DEFUN([_AM_PROG_TAR], 80959bd41f2cSmrg[# Always define AMTAR for backward compatibility. 80969bd41f2cSmrgAM_MISSING_PROG([AMTAR], [tar]) 80979bd41f2cSmrgm4_if([$1], [v7], 80989bd41f2cSmrg [am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'], 80999bd41f2cSmrg [m4_case([$1], [ustar],, [pax],, 81009bd41f2cSmrg [m4_fatal([Unknown tar format])]) 81019bd41f2cSmrgAC_MSG_CHECKING([how to create a $1 tar archive]) 81029bd41f2cSmrg# Loop over all known methods to create a tar archive until one works. 81039bd41f2cSmrg_am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none' 81049bd41f2cSmrg_am_tools=${am_cv_prog_tar_$1-$_am_tools} 81059bd41f2cSmrg# Do not fold the above two line into one, because Tru64 sh and 81069bd41f2cSmrg# Solaris sh will not grok spaces in the rhs of `-'. 81079bd41f2cSmrgfor _am_tool in $_am_tools 81089bd41f2cSmrgdo 81099bd41f2cSmrg case $_am_tool in 81109bd41f2cSmrg gnutar) 81119bd41f2cSmrg for _am_tar in tar gnutar gtar; 81129bd41f2cSmrg do 81139bd41f2cSmrg AM_RUN_LOG([$_am_tar --version]) && break 81149bd41f2cSmrg done 81159bd41f2cSmrg am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"' 81169bd41f2cSmrg am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"' 81179bd41f2cSmrg am__untar="$_am_tar -xf -" 81189bd41f2cSmrg ;; 81199bd41f2cSmrg plaintar) 81209bd41f2cSmrg # Must skip GNU tar: if it does not support --format= it doesn't create 81219bd41f2cSmrg # ustar tarball either. 81229bd41f2cSmrg (tar --version) >/dev/null 2>&1 && continue 81239bd41f2cSmrg am__tar='tar chf - "$$tardir"' 81249bd41f2cSmrg am__tar_='tar chf - "$tardir"' 81259bd41f2cSmrg am__untar='tar xf -' 81269bd41f2cSmrg ;; 81279bd41f2cSmrg pax) 81289bd41f2cSmrg am__tar='pax -L -x $1 -w "$$tardir"' 81299bd41f2cSmrg am__tar_='pax -L -x $1 -w "$tardir"' 81309bd41f2cSmrg am__untar='pax -r' 81319bd41f2cSmrg ;; 81329bd41f2cSmrg cpio) 81339bd41f2cSmrg am__tar='find "$$tardir" -print | cpio -o -H $1 -L' 81349bd41f2cSmrg am__tar_='find "$tardir" -print | cpio -o -H $1 -L' 81359bd41f2cSmrg am__untar='cpio -i -H $1 -d' 81369bd41f2cSmrg ;; 81379bd41f2cSmrg none) 81389bd41f2cSmrg am__tar=false 81399bd41f2cSmrg am__tar_=false 81409bd41f2cSmrg am__untar=false 81419bd41f2cSmrg ;; 81429bd41f2cSmrg esac 81439bd41f2cSmrg 81449bd41f2cSmrg # If the value was cached, stop now. We just wanted to have am__tar 81459bd41f2cSmrg # and am__untar set. 81469bd41f2cSmrg test -n "${am_cv_prog_tar_$1}" && break 81479bd41f2cSmrg 81489bd41f2cSmrg # tar/untar a dummy directory, and stop if the command works 81499bd41f2cSmrg rm -rf conftest.dir 81509bd41f2cSmrg mkdir conftest.dir 81519bd41f2cSmrg echo GrepMe > conftest.dir/file 81529bd41f2cSmrg AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar]) 81539bd41f2cSmrg rm -rf conftest.dir 81549bd41f2cSmrg if test -s conftest.tar; then 81559bd41f2cSmrg AM_RUN_LOG([$am__untar <conftest.tar]) 81569bd41f2cSmrg grep GrepMe conftest.dir/file >/dev/null 2>&1 && break 81579bd41f2cSmrg fi 81589bd41f2cSmrgdone 81599bd41f2cSmrgrm -rf conftest.dir 81609bd41f2cSmrg 81619bd41f2cSmrgAC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool]) 81629bd41f2cSmrgAC_MSG_RESULT([$am_cv_prog_tar_$1])]) 81639bd41f2cSmrgAC_SUBST([am__tar]) 81649bd41f2cSmrgAC_SUBST([am__untar]) 81659bd41f2cSmrg]) # _AM_PROG_TAR 81669bd41f2cSmrg 8167