1# generated automatically by aclocal 1.8.4 -*- Autoconf -*- 2 3# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004 4# Free Software Foundation, Inc. 5# This file is free software; the Free Software Foundation 6# gives unlimited permission to copy and/or distribute it, 7# with or without modifications, as long as this notice is preserved. 8 9# This program is distributed in the hope that it will be useful, 10# but WITHOUT ANY WARRANTY, to the extent permitted by law; without 11# even the implied warranty of MERCHANTABILITY or FITNESS FOR A 12# PARTICULAR PURPOSE. 13 14dnl * 15dnl * Make ready to link EB Library 3.x or 4.x. 16dnl * 17dnl * Copyright (c) 2000-2004 Motoyuki Kasahara 18dnl * 19dnl * Redistribution and use in source and binary forms, with or without 20dnl * modification, are permitted provided that the following conditions 21dnl * are met: 22dnl * 1. Redistributions of source code must retain the above copyright 23dnl * notice, this list of conditions and the following disclaimer. 24dnl * 2. Redistributions in binary form must reproduce the above copyright 25dnl * notice, this list of conditions and the following disclaimer in the 26dnl * documentation and/or other materials provided with the distribution. 27dnl * 3. Neither the name of the project nor the names of its contributors 28dnl * may be used to endorse or promote products derived from this software 29dnl * without specific prior written permission. 30dnl * 31dnl * THIS SOFTWARE IS PROVIDED BY THE PROJECT AND CONTRIBUTORS ``AS IS'' AND 32dnl * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 33dnl * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 34dnl * ARE DISCLAIMED. IN NO EVENT SHALL THE PROJECT OR CONTRIBUTORS BE LIABLE 35dnl * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 36dnl * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 37dnl * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 38dnl * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 39dnl * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 40dnl * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 41dnl * SUCH DAMAGE. 42dnl * 43 44AC_DEFUN([eb_LIB_EB4], 45[dnl 46dnl * 47dnl * Requirements. 48dnl * 49AC_REQUIRE([AC_PROG_CC]) 50AC_REQUIRE([AC_PROG_LIBTOOL]) 51AC_REQUIRE([AC_C_CONST]) 52AC_REQUIRE([AC_C_PROTOTYPES]) 53AC_REQUIRE([AC_TYPE_OFF_T]) 54AC_REQUIRE([AC_TYPE_SIZE_T]) 55AC_REQUIRE([AC_HEADER_TIME]) 56 57AC_CHECK_HEADERS(limits.h) 58AC_CHECK_TYPE(ssize_t, int) 59 60dnl * 61dnl * --with-eb-conf option. 62dnl * 63AC_ARG_WITH(eb-conf, 64AC_HELP_STRING([--with-eb-conf=FILE], 65 [eb.conf file is FILE [[SYSCONFDIR/eb.conf]]]), 66[ebconf="${withval}"], [ebconf=$sysconfdir/eb.conf]) 67if test X$prefix = XNONE; then 68 PREFIX=$ac_default_prefix 69else 70 PREFIX=$prefix 71fi 72ebconf=`echo X$ebconf | sed -e 's/^X//' -e 's;\${prefix};'"$PREFIX;g" \ 73 -e 's;\$(prefix);'"$PREFIX;g"` 74 75dnl * 76dnl * Read eb.conf 77dnl * 78AC_MSG_CHECKING(for eb.conf) 79AC_MSG_RESULT($ebconf) 80if test -f ${ebconf}; then 81 . ${ebconf} 82else 83 AC_MSG_ERROR($ebconf not found) 84fi 85 86if test X$EBCONF_ENABLE_PTHREAD = Xyes; then 87 AC_DEFINE(EBCONF_ENABLE_PTHREAD, 1, 88 [Define if EB Library supports pthread.]) 89fi 90if test X$EBCONF_ENABLE_NLS = Xyes; then 91 AC_DEFINE(EBCONF_ENABLE_NLS, 1, 92 [Define if EB Library supports native language.]) 93fi 94if test X$EBCONF_ENABLE_EBNET = Xyes; then 95 AC_DEFINE(EBCONF_ENABLE_EBNET, 1, 96 [Define if EB Library supports remote access.]) 97fi 98 99AC_SUBST(EBCONF_EBINCS) 100AC_SUBST(EBCONF_EBLIBS) 101AC_SUBST(EBCONF_ZLIBINCS) 102AC_SUBST(EBCONF_ZLIBLIBS) 103AC_SUBST(EBCONF_PTHREAD_CPPFLAGS) 104AC_SUBST(EBCONF_PTHREAD_CFLAGS) 105AC_SUBST(EBCONF_PTHREAD_LDFLAGS) 106AC_SUBST(EBCONF_INTLINCS) 107AC_SUBST(EBCONF_INTLLIBS) 108 109dnl * 110dnl * Check for EB Library. 111dnl * 112AC_MSG_CHECKING(for EB Library) 113save_CPPFLAGS=$CPPFLAGS 114save_CFLAGS=$CFLAGS 115save_LDFLAGS=$LDFLAGS 116save_LIBS=$LIBS 117CPPFLAGS="$CPPFLAGS $EBCONF_PTHREAD_CPPFLAGS $EBCONF_EBINCS $EBCONF_ZLIBINCS $EBCONF_INTLINCS" 118CFLAGS="$CFLAGS $EBCONF_PTHREAD_CFLAGS" 119LDFLAGS="$LDFAGS $EBCONF_PTHREAD_LDFLAGS" 120LIBS="$LIBS $EBCONF_EBLIBS $EBCONF_ZLIBLIBS $EBCONF_INTLLIBS" 121AC_TRY_LINK([#include <eb/eb.h>], 122[eb_initialize_library(); return 0;], 123try_eb=yes, try_eb=no) 124CPPFLAGS=$save_CPPFLAGS 125CFLAGS=$save_CFLAGS 126LDFLAGS=$save_LDFLAGS 127LIBS=$save_LIBS 128AC_MSG_RESULT($try_eb) 129if test ${try_eb} != yes; then 130 AC_MSG_ERROR(EB Library not available) 131fi 132]) 133 134# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*- 135 136# serial 47 AC_PROG_LIBTOOL 137 138 139# AC_PROVIDE_IFELSE(MACRO-NAME, IF-PROVIDED, IF-NOT-PROVIDED) 140# ----------------------------------------------------------- 141# If this macro is not defined by Autoconf, define it here. 142m4_ifdef([AC_PROVIDE_IFELSE], 143 [], 144 [m4_define([AC_PROVIDE_IFELSE], 145 [m4_ifdef([AC_PROVIDE_$1], 146 [$2], [$3])])]) 147 148 149# AC_PROG_LIBTOOL 150# --------------- 151AC_DEFUN([AC_PROG_LIBTOOL], 152[AC_REQUIRE([_AC_PROG_LIBTOOL])dnl 153dnl If AC_PROG_CXX has already been expanded, run AC_LIBTOOL_CXX 154dnl immediately, otherwise, hook it in at the end of AC_PROG_CXX. 155 AC_PROVIDE_IFELSE([AC_PROG_CXX], 156 [AC_LIBTOOL_CXX], 157 [define([AC_PROG_CXX], defn([AC_PROG_CXX])[AC_LIBTOOL_CXX 158 ])]) 159dnl And a similar setup for Fortran 77 support 160 AC_PROVIDE_IFELSE([AC_PROG_F77], 161 [AC_LIBTOOL_F77], 162 [define([AC_PROG_F77], defn([AC_PROG_F77])[AC_LIBTOOL_F77 163])]) 164 165dnl Quote A][M_PROG_GCJ so that aclocal doesn't bring it in needlessly. 166dnl If either AC_PROG_GCJ or A][M_PROG_GCJ have already been expanded, run 167dnl AC_LIBTOOL_GCJ immediately, otherwise, hook it in at the end of both. 168 AC_PROVIDE_IFELSE([AC_PROG_GCJ], 169 [AC_LIBTOOL_GCJ], 170 [AC_PROVIDE_IFELSE([A][M_PROG_GCJ], 171 [AC_LIBTOOL_GCJ], 172 [AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ], 173 [AC_LIBTOOL_GCJ], 174 [ifdef([AC_PROG_GCJ], 175 [define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[AC_LIBTOOL_GCJ])]) 176 ifdef([A][M_PROG_GCJ], 177 [define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[AC_LIBTOOL_GCJ])]) 178 ifdef([LT_AC_PROG_GCJ], 179 [define([LT_AC_PROG_GCJ], 180 defn([LT_AC_PROG_GCJ])[AC_LIBTOOL_GCJ])])])]) 181])])# AC_PROG_LIBTOOL 182 183 184# _AC_PROG_LIBTOOL 185# ---------------- 186AC_DEFUN([_AC_PROG_LIBTOOL], 187[AC_REQUIRE([AC_LIBTOOL_SETUP])dnl 188AC_BEFORE([$0],[AC_LIBTOOL_CXX])dnl 189AC_BEFORE([$0],[AC_LIBTOOL_F77])dnl 190AC_BEFORE([$0],[AC_LIBTOOL_GCJ])dnl 191 192# This can be used to rebuild libtool when needed 193LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh" 194 195# Always use our own libtool. 196LIBTOOL='$(SHELL) $(top_builddir)/libtool' 197AC_SUBST(LIBTOOL)dnl 198 199# Prevent multiple expansion 200define([AC_PROG_LIBTOOL], []) 201])# _AC_PROG_LIBTOOL 202 203 204# AC_LIBTOOL_SETUP 205# ---------------- 206AC_DEFUN([AC_LIBTOOL_SETUP], 207[AC_PREREQ(2.50)dnl 208AC_REQUIRE([AC_ENABLE_SHARED])dnl 209AC_REQUIRE([AC_ENABLE_STATIC])dnl 210AC_REQUIRE([AC_ENABLE_FAST_INSTALL])dnl 211AC_REQUIRE([AC_CANONICAL_HOST])dnl 212AC_REQUIRE([AC_CANONICAL_BUILD])dnl 213AC_REQUIRE([AC_PROG_CC])dnl 214AC_REQUIRE([AC_PROG_LD])dnl 215AC_REQUIRE([AC_PROG_LD_RELOAD_FLAG])dnl 216AC_REQUIRE([AC_PROG_NM])dnl 217 218AC_REQUIRE([AC_PROG_LN_S])dnl 219AC_REQUIRE([AC_DEPLIBS_CHECK_METHOD])dnl 220# Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers! 221AC_REQUIRE([AC_OBJEXT])dnl 222AC_REQUIRE([AC_EXEEXT])dnl 223dnl 224 225AC_LIBTOOL_SYS_MAX_CMD_LEN 226AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE 227AC_LIBTOOL_OBJDIR 228 229AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl 230_LT_AC_PROG_ECHO_BACKSLASH 231 232case $host_os in 233aix3*) 234 # AIX sometimes has problems with the GCC collect2 program. For some 235 # reason, if we set the COLLECT_NAMES environment variable, the problems 236 # vanish in a puff of smoke. 237 if test "X${COLLECT_NAMES+set}" != Xset; then 238 COLLECT_NAMES= 239 export COLLECT_NAMES 240 fi 241 ;; 242esac 243 244# Sed substitution that helps us do robust quoting. It backslashifies 245# metacharacters that are still active within double-quoted strings. 246Xsed='sed -e s/^X//' 247[sed_quote_subst='s/\([\\"\\`$\\\\]\)/\\\1/g'] 248 249# Same as above, but do not quote variable references. 250[double_quote_subst='s/\([\\"\\`\\\\]\)/\\\1/g'] 251 252# Sed substitution to delay expansion of an escaped shell variable in a 253# double_quote_subst'ed string. 254delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' 255 256# Sed substitution to avoid accidental globbing in evaled expressions 257no_glob_subst='s/\*/\\\*/g' 258 259# Constants: 260rm="rm -f" 261 262# Global variables: 263default_ofile=libtool 264can_build_shared=yes 265 266# All known linkers require a `.a' archive for static linking (except M$VC, 267# which needs '.lib'). 268libext=a 269ltmain="$ac_aux_dir/ltmain.sh" 270ofile="$default_ofile" 271with_gnu_ld="$lt_cv_prog_gnu_ld" 272 273AC_CHECK_TOOL(AR, ar, false) 274AC_CHECK_TOOL(RANLIB, ranlib, :) 275AC_CHECK_TOOL(STRIP, strip, :) 276 277old_CC="$CC" 278old_CFLAGS="$CFLAGS" 279 280# Set sane defaults for various variables 281test -z "$AR" && AR=ar 282test -z "$AR_FLAGS" && AR_FLAGS=cru 283test -z "$AS" && AS=as 284test -z "$CC" && CC=cc 285test -z "$LTCC" && LTCC=$CC 286test -z "$DLLTOOL" && DLLTOOL=dlltool 287test -z "$LD" && LD=ld 288test -z "$LN_S" && LN_S="ln -s" 289test -z "$MAGIC_CMD" && MAGIC_CMD=file 290test -z "$NM" && NM=nm 291test -z "$SED" && SED=sed 292test -z "$OBJDUMP" && OBJDUMP=objdump 293test -z "$RANLIB" && RANLIB=: 294test -z "$STRIP" && STRIP=: 295test -z "$ac_objext" && ac_objext=o 296 297# Determine commands to create old-style static archives. 298old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs$old_deplibs' 299old_postinstall_cmds='chmod 644 $oldlib' 300old_postuninstall_cmds= 301 302if test -n "$RANLIB"; then 303 case $host_os in 304 openbsd*) 305 old_postinstall_cmds="\$RANLIB -t \$oldlib~$old_postinstall_cmds" 306 ;; 307 *) 308 old_postinstall_cmds="\$RANLIB \$oldlib~$old_postinstall_cmds" 309 ;; 310 esac 311 old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib" 312fi 313 314# Only perform the check for file, if the check method requires it 315case $deplibs_check_method in 316file_magic*) 317 if test "$file_magic_cmd" = '$MAGIC_CMD'; then 318 AC_PATH_MAGIC 319 fi 320 ;; 321esac 322 323AC_PROVIDE_IFELSE([AC_LIBTOOL_DLOPEN], enable_dlopen=yes, enable_dlopen=no) 324AC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL], 325enable_win32_dll=yes, enable_win32_dll=no) 326 327AC_ARG_ENABLE([libtool-lock], 328 [AC_HELP_STRING([--disable-libtool-lock], 329 [avoid locking (might break parallel builds)])]) 330test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes 331 332AC_ARG_WITH([pic], 333 [AC_HELP_STRING([--with-pic], 334 [try to use only PIC/non-PIC objects @<:@default=use both@:>@])], 335 [pic_mode="$withval"], 336 [pic_mode=default]) 337test -z "$pic_mode" && pic_mode=default 338 339# Use C for the default configuration in the libtool script 340tagname= 341AC_LIBTOOL_LANG_C_CONFIG 342_LT_AC_TAGCONFIG 343])# AC_LIBTOOL_SETUP 344 345 346# _LT_AC_SYS_COMPILER 347# ------------------- 348AC_DEFUN([_LT_AC_SYS_COMPILER], 349[AC_REQUIRE([AC_PROG_CC])dnl 350 351# If no C compiler was specified, use CC. 352LTCC=${LTCC-"$CC"} 353 354# Allow CC to be a program name with arguments. 355compiler=$CC 356])# _LT_AC_SYS_COMPILER 357 358 359# _LT_AC_SYS_LIBPATH_AIX 360# ---------------------- 361# Links a minimal program and checks the executable 362# for the system default hardcoded library path. In most cases, 363# this is /usr/lib:/lib, but when the MPI compilers are used 364# the location of the communication and MPI libs are included too. 365# If we don't find anything, use the default library path according 366# to the aix ld manual. 367AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX], 368[AC_LINK_IFELSE(AC_LANG_PROGRAM,[ 369aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } 370}'` 371# Check for a 64-bit object if we didn't find anything. 372if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } 373}'`; fi],[]) 374if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi 375])# _LT_AC_SYS_LIBPATH_AIX 376 377 378# _LT_AC_SHELL_INIT(ARG) 379# ---------------------- 380AC_DEFUN([_LT_AC_SHELL_INIT], 381[ifdef([AC_DIVERSION_NOTICE], 382 [AC_DIVERT_PUSH(AC_DIVERSION_NOTICE)], 383 [AC_DIVERT_PUSH(NOTICE)]) 384$1 385AC_DIVERT_POP 386])# _LT_AC_SHELL_INIT 387 388 389# _LT_AC_PROG_ECHO_BACKSLASH 390# -------------------------- 391# Add some code to the start of the generated configure script which 392# will find an echo command which doesn't interpret backslashes. 393AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH], 394[_LT_AC_SHELL_INIT([ 395# Check that we are running under the correct shell. 396SHELL=${CONFIG_SHELL-/bin/sh} 397 398case X$ECHO in 399X*--fallback-echo) 400 # Remove one level of quotation (which was required for Make). 401 ECHO=`echo "$ECHO" | sed 's,\\\\\[$]\\[$]0,'[$]0','` 402 ;; 403esac 404 405echo=${ECHO-echo} 406if test "X[$]1" = X--no-reexec; then 407 # Discard the --no-reexec flag, and continue. 408 shift 409elif test "X[$]1" = X--fallback-echo; then 410 # Avoid inline document here, it may be left over 411 : 412elif test "X`($echo '\t') 2>/dev/null`" = 'X\t' ; then 413 # Yippee, $echo works! 414 : 415else 416 # Restart under the correct shell. 417 exec $SHELL "[$]0" --no-reexec ${1+"[$]@"} 418fi 419 420if test "X[$]1" = X--fallback-echo; then 421 # used as fallback echo 422 shift 423 cat <<EOF 424[$]* 425EOF 426 exit 0 427fi 428 429# The HP-UX ksh and POSIX shell print the target directory to stdout 430# if CDPATH is set. 431if test "X${CDPATH+set}" = Xset; then CDPATH=:; export CDPATH; fi 432 433if test -z "$ECHO"; then 434if test "X${echo_test_string+set}" != Xset; then 435# find a string as large as possible, as long as the shell can cope with it 436 for cmd in 'sed 50q "[$]0"' 'sed 20q "[$]0"' 'sed 10q "[$]0"' 'sed 2q "[$]0"' 'echo test'; do 437 # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ... 438 if (echo_test_string="`eval $cmd`") 2>/dev/null && 439 echo_test_string="`eval $cmd`" && 440 (test "X$echo_test_string" = "X$echo_test_string") 2>/dev/null 441 then 442 break 443 fi 444 done 445fi 446 447if test "X`($echo '\t') 2>/dev/null`" = 'X\t' && 448 echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` && 449 test "X$echo_testing_string" = "X$echo_test_string"; then 450 : 451else 452 # The Solaris, AIX, and Digital Unix default echo programs unquote 453 # backslashes. This makes it impossible to quote backslashes using 454 # echo "$something" | sed 's/\\/\\\\/g' 455 # 456 # So, first we look for a working echo in the user's PATH. 457 458 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR 459 for dir in $PATH /usr/ucb; do 460 IFS="$lt_save_ifs" 461 if (test -f $dir/echo || test -f $dir/echo$ac_exeext) && 462 test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' && 463 echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` && 464 test "X$echo_testing_string" = "X$echo_test_string"; then 465 echo="$dir/echo" 466 break 467 fi 468 done 469 IFS="$lt_save_ifs" 470 471 if test "X$echo" = Xecho; then 472 # We didn't find a better echo, so look for alternatives. 473 if test "X`(print -r '\t') 2>/dev/null`" = 'X\t' && 474 echo_testing_string=`(print -r "$echo_test_string") 2>/dev/null` && 475 test "X$echo_testing_string" = "X$echo_test_string"; then 476 # This shell has a builtin print -r that does the trick. 477 echo='print -r' 478 elif (test -f /bin/ksh || test -f /bin/ksh$ac_exeext) && 479 test "X$CONFIG_SHELL" != X/bin/ksh; then 480 # If we have ksh, try running configure again with it. 481 ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh} 482 export ORIGINAL_CONFIG_SHELL 483 CONFIG_SHELL=/bin/ksh 484 export CONFIG_SHELL 485 exec $CONFIG_SHELL "[$]0" --no-reexec ${1+"[$]@"} 486 else 487 # Try using printf. 488 echo='printf %s\n' 489 if test "X`($echo '\t') 2>/dev/null`" = 'X\t' && 490 echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` && 491 test "X$echo_testing_string" = "X$echo_test_string"; then 492 # Cool, printf works 493 : 494 elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` && 495 test "X$echo_testing_string" = 'X\t' && 496 echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` && 497 test "X$echo_testing_string" = "X$echo_test_string"; then 498 CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL 499 export CONFIG_SHELL 500 SHELL="$CONFIG_SHELL" 501 export SHELL 502 echo="$CONFIG_SHELL [$]0 --fallback-echo" 503 elif echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` && 504 test "X$echo_testing_string" = 'X\t' && 505 echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` && 506 test "X$echo_testing_string" = "X$echo_test_string"; then 507 echo="$CONFIG_SHELL [$]0 --fallback-echo" 508 else 509 # maybe with a smaller string... 510 prev=: 511 512 for cmd in 'echo test' 'sed 2q "[$]0"' 'sed 10q "[$]0"' 'sed 20q "[$]0"' 'sed 50q "[$]0"'; do 513 if (test "X$echo_test_string" = "X`eval $cmd`") 2>/dev/null 514 then 515 break 516 fi 517 prev="$cmd" 518 done 519 520 if test "$prev" != 'sed 50q "[$]0"'; then 521 echo_test_string=`eval $prev` 522 export echo_test_string 523 exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "[$]0" ${1+"[$]@"} 524 else 525 # Oops. We lost completely, so just stick with echo. 526 echo=echo 527 fi 528 fi 529 fi 530 fi 531fi 532fi 533 534# Copy echo and quote the copy suitably for passing to libtool from 535# the Makefile, instead of quoting the original, which is used later. 536ECHO=$echo 537if test "X$ECHO" = "X$CONFIG_SHELL [$]0 --fallback-echo"; then 538 ECHO="$CONFIG_SHELL \\\$\[$]0 --fallback-echo" 539fi 540 541AC_SUBST(ECHO) 542])])# _LT_AC_PROG_ECHO_BACKSLASH 543 544 545# _LT_AC_LOCK 546# ----------- 547AC_DEFUN([_LT_AC_LOCK], 548[AC_ARG_ENABLE([libtool-lock], 549 [AC_HELP_STRING([--disable-libtool-lock], 550 [avoid locking (might break parallel builds)])]) 551test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes 552 553# Some flags need to be propagated to the compiler or linker for good 554# libtool support. 555case $host in 556ia64-*-hpux*) 557 # Find out which ABI we are using. 558 echo 'int i;' > conftest.$ac_ext 559 if AC_TRY_EVAL(ac_compile); then 560 case `/usr/bin/file conftest.$ac_objext` in 561 *ELF-32*) 562 HPUX_IA64_MODE="32" 563 ;; 564 *ELF-64*) 565 HPUX_IA64_MODE="64" 566 ;; 567 esac 568 fi 569 rm -rf conftest* 570 ;; 571*-*-irix6*) 572 # Find out which ABI we are using. 573 echo '[#]line __oline__ "configure"' > conftest.$ac_ext 574 if AC_TRY_EVAL(ac_compile); then 575 if test "$lt_cv_prog_gnu_ld" = yes; then 576 case `/usr/bin/file conftest.$ac_objext` in 577 *32-bit*) 578 LD="${LD-ld} -melf32bsmip" 579 ;; 580 *N32*) 581 LD="${LD-ld} -melf32bmipn32" 582 ;; 583 *64-bit*) 584 LD="${LD-ld} -melf64bmip" 585 ;; 586 esac 587 else 588 case `/usr/bin/file conftest.$ac_objext` in 589 *32-bit*) 590 LD="${LD-ld} -32" 591 ;; 592 *N32*) 593 LD="${LD-ld} -n32" 594 ;; 595 *64-bit*) 596 LD="${LD-ld} -64" 597 ;; 598 esac 599 fi 600 fi 601 rm -rf conftest* 602 ;; 603 604x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*|s390*-*linux*|sparc*-*linux*) 605 # Find out which ABI we are using. 606 echo 'int i;' > conftest.$ac_ext 607 if AC_TRY_EVAL(ac_compile); then 608 case "`/usr/bin/file conftest.o`" in 609 *32-bit*) 610 case $host in 611 x86_64-*linux*) 612 LD="${LD-ld} -m elf_i386" 613 ;; 614 ppc64-*linux*) 615 LD="${LD-ld} -m elf32ppclinux" 616 ;; 617 s390x-*linux*) 618 LD="${LD-ld} -m elf_s390" 619 ;; 620 sparc64-*linux*) 621 LD="${LD-ld} -m elf32_sparc" 622 ;; 623 esac 624 ;; 625 *64-bit*) 626 case $host in 627 x86_64-*linux*) 628 LD="${LD-ld} -m elf_x86_64" 629 ;; 630 ppc*-*linux*|powerpc*-*linux*) 631 LD="${LD-ld} -m elf64ppc" 632 ;; 633 s390*-*linux*) 634 LD="${LD-ld} -m elf64_s390" 635 ;; 636 sparc*-*linux*) 637 LD="${LD-ld} -m elf64_sparc" 638 ;; 639 esac 640 ;; 641 esac 642 fi 643 rm -rf conftest* 644 ;; 645 646*-*-sco3.2v5*) 647 # On SCO OpenServer 5, we need -belf to get full-featured binaries. 648 SAVE_CFLAGS="$CFLAGS" 649 CFLAGS="$CFLAGS -belf" 650 AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf, 651 [AC_LANG_PUSH(C) 652 AC_TRY_LINK([],[],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no]) 653 AC_LANG_POP]) 654 if test x"$lt_cv_cc_needs_belf" != x"yes"; then 655 # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf 656 CFLAGS="$SAVE_CFLAGS" 657 fi 658 ;; 659AC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL], 660[*-*-cygwin* | *-*-mingw* | *-*-pw32*) 661 AC_CHECK_TOOL(DLLTOOL, dlltool, false) 662 AC_CHECK_TOOL(AS, as, false) 663 AC_CHECK_TOOL(OBJDUMP, objdump, false) 664 ;; 665 ]) 666esac 667 668need_locks="$enable_libtool_lock" 669 670])# _LT_AC_LOCK 671 672 673# AC_LIBTOOL_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, 674# [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE]) 675# ---------------------------------------------------------------- 676# Check whether the given compiler option works 677AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], 678[AC_CACHE_CHECK([$1], [$2], 679 [$2=no 680 ifelse([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4]) 681 printf "$lt_simple_compile_test_code" > conftest.$ac_ext 682 lt_compiler_flag="$3" 683 # Insert the option either (1) after the last *FLAGS variable, or 684 # (2) before a word containing "conftest.", or (3) at the end. 685 # Note that $ac_compile itself does not contain backslashes and begins 686 # with a dollar sign (not a hyphen), so the echo should work correctly. 687 # The option is referenced via a variable to avoid confusing sed. 688 lt_compile=`echo "$ac_compile" | $SED \ 689 -e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \ 690 -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ 691 -e 's:$: $lt_compiler_flag:'` 692 (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD) 693 (eval "$lt_compile" 2>conftest.err) 694 ac_status=$? 695 cat conftest.err >&AS_MESSAGE_LOG_FD 696 echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD 697 if (exit $ac_status) && test -s "$ac_outfile"; then 698 # The compiler can only warn and ignore the option if not recognized 699 # So say no if there are warnings 700 if test ! -s conftest.err; then 701 $2=yes 702 fi 703 fi 704 $rm conftest* 705]) 706 707if test x"[$]$2" = xyes; then 708 ifelse([$5], , :, [$5]) 709else 710 ifelse([$6], , :, [$6]) 711fi 712])# AC_LIBTOOL_COMPILER_OPTION 713 714 715# AC_LIBTOOL_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, 716# [ACTION-SUCCESS], [ACTION-FAILURE]) 717# ------------------------------------------------------------ 718# Check whether the given compiler option works 719AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], 720[AC_CACHE_CHECK([$1], [$2], 721 [$2=no 722 save_LDFLAGS="$LDFLAGS" 723 LDFLAGS="$LDFLAGS $3" 724 printf "$lt_simple_link_test_code" > conftest.$ac_ext 725 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then 726 # The compiler can only warn and ignore the option if not recognized 727 # So say no if there are warnings 728 if test -s conftest.err; then 729 # Append any errors to the config.log. 730 cat conftest.err 1>&AS_MESSAGE_LOG_FD 731 else 732 $2=yes 733 fi 734 fi 735 $rm conftest* 736 LDFLAGS="$save_LDFLAGS" 737]) 738 739if test x"[$]$2" = xyes; then 740 ifelse([$4], , :, [$4]) 741else 742 ifelse([$5], , :, [$5]) 743fi 744])# AC_LIBTOOL_LINKER_OPTION 745 746 747# AC_LIBTOOL_SYS_MAX_CMD_LEN 748# -------------------------- 749AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], 750[# find the maximum length of command line arguments 751AC_MSG_CHECKING([the maximum length of command line arguments]) 752AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl 753 i=0 754 testring="ABCD" 755 756 case $build_os in 757 msdosdjgpp*) 758 # On DJGPP, this test can blow up pretty badly due to problems in libc 759 # (any single argument exceeding 2000 bytes causes a buffer overrun 760 # during glob expansion). Even if it were fixed, the result of this 761 # check would be larger than it should be. 762 lt_cv_sys_max_cmd_len=12288; # 12K is about right 763 ;; 764 765 gnu*) 766 # Under GNU Hurd, this test is not required because there is 767 # no limit to the length of command line arguments. 768 # Libtool will interpret -1 as no limit whatsoever 769 lt_cv_sys_max_cmd_len=-1; 770 ;; 771 772 cygwin* | mingw*) 773 # On Win9x/ME, this test blows up -- it succeeds, but takes 774 # about 5 minutes as the teststring grows exponentially. 775 # Worse, since 9x/ME are not pre-emptively multitasking, 776 # you end up with a "frozen" computer, even though with patience 777 # the test eventually succeeds (with a max line length of 256k). 778 # Instead, let's just punt: use the minimum linelength reported by 779 # all of the supported platforms: 8192 (on NT/2K/XP). 780 lt_cv_sys_max_cmd_len=8192; 781 ;; 782 783 *) 784 # If test is not a shell built-in, we'll probably end up computing a 785 # maximum length that is only half of the actual maximum length, but 786 # we can't tell. 787 while (test "X"`$CONFIG_SHELL [$]0 --fallback-echo "X$testring" 2>/dev/null` \ 788 = "XX$testring") >/dev/null 2>&1 && 789 new_result=`expr "X$testring" : ".*" 2>&1` && 790 lt_cv_sys_max_cmd_len=$new_result && 791 test $i != 17 # 1/2 MB should be enough 792 do 793 i=`expr $i + 1` 794 testring=$testring$testring 795 done 796 testring= 797 # Add a significant safety factor because C++ compilers can tack on massive 798 # amounts of additional arguments before passing them to the linker. 799 # It appears as though 1/2 is a usable value. 800 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` 801 ;; 802 esac 803]) 804if test -n $lt_cv_sys_max_cmd_len ; then 805 AC_MSG_RESULT($lt_cv_sys_max_cmd_len) 806else 807 AC_MSG_RESULT(none) 808fi 809])# AC_LIBTOOL_SYS_MAX_CMD_LEN 810 811 812# _LT_AC_CHECK_DLFCN 813# -------------------- 814AC_DEFUN([_LT_AC_CHECK_DLFCN], 815[AC_CHECK_HEADERS(dlfcn.h)dnl 816])# _LT_AC_CHECK_DLFCN 817 818 819# _LT_AC_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE, 820# ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING) 821# ------------------------------------------------------------------ 822AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF], 823[AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl 824if test "$cross_compiling" = yes; then : 825 [$4] 826else 827 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 828 lt_status=$lt_dlunknown 829 cat > conftest.$ac_ext <<EOF 830[#line __oline__ "configure" 831#include "confdefs.h" 832 833#if HAVE_DLFCN_H 834#include <dlfcn.h> 835#endif 836 837#include <stdio.h> 838 839#ifdef RTLD_GLOBAL 840# define LT_DLGLOBAL RTLD_GLOBAL 841#else 842# ifdef DL_GLOBAL 843# define LT_DLGLOBAL DL_GLOBAL 844# else 845# define LT_DLGLOBAL 0 846# endif 847#endif 848 849/* We may have to define LT_DLLAZY_OR_NOW in the command line if we 850 find out it does not work in some platform. */ 851#ifndef LT_DLLAZY_OR_NOW 852# ifdef RTLD_LAZY 853# define LT_DLLAZY_OR_NOW RTLD_LAZY 854# else 855# ifdef DL_LAZY 856# define LT_DLLAZY_OR_NOW DL_LAZY 857# else 858# ifdef RTLD_NOW 859# define LT_DLLAZY_OR_NOW RTLD_NOW 860# else 861# ifdef DL_NOW 862# define LT_DLLAZY_OR_NOW DL_NOW 863# else 864# define LT_DLLAZY_OR_NOW 0 865# endif 866# endif 867# endif 868# endif 869#endif 870 871#ifdef __cplusplus 872extern "C" void exit (int); 873#endif 874 875void fnord() { int i=42;} 876int main () 877{ 878 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); 879 int status = $lt_dlunknown; 880 881 if (self) 882 { 883 if (dlsym (self,"fnord")) status = $lt_dlno_uscore; 884 else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; 885 /* dlclose (self); */ 886 } 887 888 exit (status); 889}] 890EOF 891 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then 892 (./conftest; exit; ) 2>/dev/null 893 lt_status=$? 894 case x$lt_status in 895 x$lt_dlno_uscore) $1 ;; 896 x$lt_dlneed_uscore) $2 ;; 897 x$lt_unknown|x*) $3 ;; 898 esac 899 else : 900 # compilation failed 901 $3 902 fi 903fi 904rm -fr conftest* 905])# _LT_AC_TRY_DLOPEN_SELF 906 907 908# AC_LIBTOOL_DLOPEN_SELF 909# ------------------- 910AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], 911[AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl 912if test "x$enable_dlopen" != xyes; then 913 enable_dlopen=unknown 914 enable_dlopen_self=unknown 915 enable_dlopen_self_static=unknown 916else 917 lt_cv_dlopen=no 918 lt_cv_dlopen_libs= 919 920 case $host_os in 921 beos*) 922 lt_cv_dlopen="load_add_on" 923 lt_cv_dlopen_libs= 924 lt_cv_dlopen_self=yes 925 ;; 926 927 mingw* | pw32*) 928 lt_cv_dlopen="LoadLibrary" 929 lt_cv_dlopen_libs= 930 ;; 931 932 cygwin*) 933 lt_cv_dlopen="dlopen" 934 lt_cv_dlopen_libs= 935 ;; 936 937 darwin*) 938 # if libdl is installed we need to link against it 939 AC_CHECK_LIB([dl], [dlopen], 940 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[ 941 lt_cv_dlopen="dyld" 942 lt_cv_dlopen_libs= 943 lt_cv_dlopen_self=yes 944 ]) 945 ;; 946 947 *) 948 AC_CHECK_FUNC([shl_load], 949 [lt_cv_dlopen="shl_load"], 950 [AC_CHECK_LIB([dld], [shl_load], 951 [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-dld"], 952 [AC_CHECK_FUNC([dlopen], 953 [lt_cv_dlopen="dlopen"], 954 [AC_CHECK_LIB([dl], [dlopen], 955 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"], 956 [AC_CHECK_LIB([svld], [dlopen], 957 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"], 958 [AC_CHECK_LIB([dld], [dld_link], 959 [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld"]) 960 ]) 961 ]) 962 ]) 963 ]) 964 ]) 965 ;; 966 esac 967 968 if test "x$lt_cv_dlopen" != xno; then 969 enable_dlopen=yes 970 else 971 enable_dlopen=no 972 fi 973 974 case $lt_cv_dlopen in 975 dlopen) 976 save_CPPFLAGS="$CPPFLAGS" 977 test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" 978 979 save_LDFLAGS="$LDFLAGS" 980 eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" 981 982 save_LIBS="$LIBS" 983 LIBS="$lt_cv_dlopen_libs $LIBS" 984 985 AC_CACHE_CHECK([whether a program can dlopen itself], 986 lt_cv_dlopen_self, [dnl 987 _LT_AC_TRY_DLOPEN_SELF( 988 lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes, 989 lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross) 990 ]) 991 992 if test "x$lt_cv_dlopen_self" = xyes; then 993 LDFLAGS="$LDFLAGS $link_static_flag" 994 AC_CACHE_CHECK([whether a statically linked program can dlopen itself], 995 lt_cv_dlopen_self_static, [dnl 996 _LT_AC_TRY_DLOPEN_SELF( 997 lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes, 998 lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross) 999 ]) 1000 fi 1001 1002 CPPFLAGS="$save_CPPFLAGS" 1003 LDFLAGS="$save_LDFLAGS" 1004 LIBS="$save_LIBS" 1005 ;; 1006 esac 1007 1008 case $lt_cv_dlopen_self in 1009 yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; 1010 *) enable_dlopen_self=unknown ;; 1011 esac 1012 1013 case $lt_cv_dlopen_self_static in 1014 yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; 1015 *) enable_dlopen_self_static=unknown ;; 1016 esac 1017fi 1018])# AC_LIBTOOL_DLOPEN_SELF 1019 1020 1021# AC_LIBTOOL_PROG_CC_C_O([TAGNAME]) 1022# --------------------------------- 1023# Check to see if options -c and -o are simultaneously supported by compiler 1024AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O], 1025[AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl 1026AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext], 1027 [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)], 1028 [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no 1029 $rm -r conftest 2>/dev/null 1030 mkdir conftest 1031 cd conftest 1032 mkdir out 1033 printf "$lt_simple_compile_test_code" > conftest.$ac_ext 1034 1035 # According to Tom Tromey, Ian Lance Taylor reported there are C compilers 1036 # that will create temporary files in the current directory regardless of 1037 # the output directory. Thus, making CWD read-only will cause this test 1038 # to fail, enabling locking or at least warning the user not to do parallel 1039 # builds. 1040 chmod -w . 1041 1042 lt_compiler_flag="-o out/conftest2.$ac_objext" 1043 # Insert the option either (1) after the last *FLAGS variable, or 1044 # (2) before a word containing "conftest.", or (3) at the end. 1045 # Note that $ac_compile itself does not contain backslashes and begins 1046 # with a dollar sign (not a hyphen), so the echo should work correctly. 1047 lt_compile=`echo "$ac_compile" | $SED \ 1048 -e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \ 1049 -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ 1050 -e 's:$: $lt_compiler_flag:'` 1051 (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD) 1052 (eval "$lt_compile" 2>out/conftest.err) 1053 ac_status=$? 1054 cat out/conftest.err >&AS_MESSAGE_LOG_FD 1055 echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD 1056 if (exit $ac_status) && test -s out/conftest2.$ac_objext 1057 then 1058 # The compiler can only warn and ignore the option if not recognized 1059 # So say no if there are warnings 1060 if test ! -s out/conftest.err; then 1061 _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes 1062 fi 1063 fi 1064 chmod u+w . 1065 $rm conftest* out/* 1066 rmdir out 1067 cd .. 1068 rmdir conftest 1069 $rm conftest* 1070]) 1071])# AC_LIBTOOL_PROG_CC_C_O 1072 1073 1074# AC_LIBTOOL_SYS_HARD_LINK_LOCKS([TAGNAME]) 1075# ----------------------------------------- 1076# Check to see if we can do hard links to lock some files if needed 1077AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], 1078[AC_REQUIRE([_LT_AC_LOCK])dnl 1079 1080hard_links="nottested" 1081if test "$_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then 1082 # do not overwrite the value of need_locks provided by the user 1083 AC_MSG_CHECKING([if we can lock with hard links]) 1084 hard_links=yes 1085 $rm conftest* 1086 ln conftest.a conftest.b 2>/dev/null && hard_links=no 1087 touch conftest.a 1088 ln conftest.a conftest.b 2>&5 || hard_links=no 1089 ln conftest.a conftest.b 2>/dev/null && hard_links=no 1090 AC_MSG_RESULT([$hard_links]) 1091 if test "$hard_links" = no; then 1092 AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe]) 1093 need_locks=warn 1094 fi 1095else 1096 need_locks=no 1097fi 1098])# AC_LIBTOOL_SYS_HARD_LINK_LOCKS 1099 1100 1101# AC_LIBTOOL_OBJDIR 1102# ----------------- 1103AC_DEFUN([AC_LIBTOOL_OBJDIR], 1104[AC_CACHE_CHECK([for objdir], [lt_cv_objdir], 1105[rm -f .libs 2>/dev/null 1106mkdir .libs 2>/dev/null 1107if test -d .libs; then 1108 lt_cv_objdir=.libs 1109else 1110 # MS-DOS does not allow filenames that begin with a dot. 1111 lt_cv_objdir=_libs 1112fi 1113rmdir .libs 2>/dev/null]) 1114objdir=$lt_cv_objdir 1115])# AC_LIBTOOL_OBJDIR 1116 1117 1118# AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH([TAGNAME]) 1119# ---------------------------------------------- 1120# Check hardcoding attributes. 1121AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], 1122[AC_MSG_CHECKING([how to hardcode library paths into programs]) 1123_LT_AC_TAGVAR(hardcode_action, $1)= 1124if test -n "$_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)" || \ 1125 test -n "$_LT_AC_TAGVAR(runpath_var $1)" || \ 1126 test "X$_LT_AC_TAGVAR(hardcode_automatic, $1)"="Xyes" ; then 1127 1128 # We can hardcode non-existant directories. 1129 if test "$_LT_AC_TAGVAR(hardcode_direct, $1)" != no && 1130 # If the only mechanism to avoid hardcoding is shlibpath_var, we 1131 # have to relink, otherwise we might link with an installed library 1132 # when we should be linking with a yet-to-be-installed one 1133 ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)" != no && 1134 test "$_LT_AC_TAGVAR(hardcode_minus_L, $1)" != no; then 1135 # Linking always hardcodes the temporary library directory. 1136 _LT_AC_TAGVAR(hardcode_action, $1)=relink 1137 else 1138 # We can link without hardcoding, and we can hardcode nonexisting dirs. 1139 _LT_AC_TAGVAR(hardcode_action, $1)=immediate 1140 fi 1141else 1142 # We cannot hardcode anything, or else we can only hardcode existing 1143 # directories. 1144 _LT_AC_TAGVAR(hardcode_action, $1)=unsupported 1145fi 1146AC_MSG_RESULT([$_LT_AC_TAGVAR(hardcode_action, $1)]) 1147 1148if test "$_LT_AC_TAGVAR(hardcode_action, $1)" = relink; then 1149 # Fast installation is not supported 1150 enable_fast_install=no 1151elif test "$shlibpath_overrides_runpath" = yes || 1152 test "$enable_shared" = no; then 1153 # Fast installation is not necessary 1154 enable_fast_install=needless 1155fi 1156])# AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH 1157 1158 1159# AC_LIBTOOL_SYS_LIB_STRIP 1160# ------------------------ 1161AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP], 1162[striplib= 1163old_striplib= 1164AC_MSG_CHECKING([whether stripping libraries is possible]) 1165if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then 1166 test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" 1167 test -z "$striplib" && striplib="$STRIP --strip-unneeded" 1168 AC_MSG_RESULT([yes]) 1169else 1170# FIXME - insert some real tests, host_os isn't really good enough 1171 case $host_os in 1172 darwin*) 1173 if test -n "$STRIP" ; then 1174 striplib="$STRIP -x" 1175 AC_MSG_RESULT([yes]) 1176 else 1177 AC_MSG_RESULT([no]) 1178fi 1179 ;; 1180 *) 1181 AC_MSG_RESULT([no]) 1182 ;; 1183 esac 1184fi 1185])# AC_LIBTOOL_SYS_LIB_STRIP 1186 1187 1188# AC_LIBTOOL_SYS_DYNAMIC_LINKER 1189# ----------------------------- 1190# PORTME Fill in your ld.so characteristics 1191AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER], 1192[AC_MSG_CHECKING([dynamic linker characteristics]) 1193library_names_spec= 1194libname_spec='lib$name' 1195soname_spec= 1196shrext=".so" 1197postinstall_cmds= 1198postuninstall_cmds= 1199finish_cmds= 1200finish_eval= 1201shlibpath_var= 1202shlibpath_overrides_runpath=unknown 1203version_type=none 1204dynamic_linker="$host_os ld.so" 1205sys_lib_dlsearch_path_spec="/lib /usr/lib" 1206if test "$GCC" = yes; then 1207 sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` 1208 if echo "$sys_lib_search_path_spec" | grep ';' >/dev/null ; then 1209 # if the path contains ";" then we assume it to be the separator 1210 # otherwise default to the standard path separator (i.e. ":") - it is 1211 # assumed that no part of a normal pathname contains ";" but that should 1212 # okay in the real world where ";" in dirpaths is itself problematic. 1213 sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` 1214 else 1215 sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` 1216 fi 1217else 1218 sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" 1219fi 1220need_lib_prefix=unknown 1221hardcode_into_libs=no 1222 1223# when you set need_version to no, make sure it does not cause -set_version 1224# flags to be left without arguments 1225need_version=unknown 1226 1227case $host_os in 1228aix3*) 1229 version_type=linux 1230 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' 1231 shlibpath_var=LIBPATH 1232 1233 # AIX 3 has no versioning support, so we append a major version to the name. 1234 soname_spec='${libname}${release}${shared_ext}$major' 1235 ;; 1236 1237aix4* | aix5*) 1238 version_type=linux 1239 need_lib_prefix=no 1240 need_version=no 1241 hardcode_into_libs=yes 1242 if test "$host_cpu" = ia64; then 1243 # AIX 5 supports IA64 1244 library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' 1245 shlibpath_var=LD_LIBRARY_PATH 1246 else 1247 # With GCC up to 2.95.x, collect2 would create an import file 1248 # for dependence libraries. The import file would start with 1249 # the line `#! .'. This would cause the generated library to 1250 # depend on `.', always an invalid library. This was fixed in 1251 # development snapshots of GCC prior to 3.0. 1252 case $host_os in 1253 aix4 | aix4.[[01]] | aix4.[[01]].*) 1254 if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' 1255 echo ' yes ' 1256 echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then 1257 : 1258 else 1259 can_build_shared=no 1260 fi 1261 ;; 1262 esac 1263 # AIX (on Power*) has no versioning support, so currently we can not hardcode correct 1264 # soname into executable. Probably we can add versioning support to 1265 # collect2, so additional links can be useful in future. 1266 if test "$aix_use_runtimelinking" = yes; then 1267 # If using run time linking (on AIX 4.2 or later) use lib<name>.so 1268 # instead of lib<name>.a to let people know that these are not 1269 # typical AIX shared libraries. 1270 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 1271 else 1272 # We preserve .a as extension for shared libraries through AIX4.2 1273 # and later when we are not doing run time linking. 1274 library_names_spec='${libname}${release}.a $libname.a' 1275 soname_spec='${libname}${release}${shared_ext}$major' 1276 fi 1277 shlibpath_var=LIBPATH 1278 fi 1279 ;; 1280 1281amigaos*) 1282 library_names_spec='$libname.ixlibrary $libname.a' 1283 # Create ${libname}_ixlibrary.a entries in /sys/libs. 1284 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' 1285 ;; 1286 1287beos*) 1288 library_names_spec='${libname}${shared_ext}' 1289 dynamic_linker="$host_os ld.so" 1290 shlibpath_var=LIBRARY_PATH 1291 ;; 1292 1293bsdi4*) 1294 version_type=linux 1295 need_version=no 1296 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 1297 soname_spec='${libname}${release}${shared_ext}$major' 1298 finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' 1299 shlibpath_var=LD_LIBRARY_PATH 1300 sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" 1301 sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" 1302 # the default ld.so.conf also contains /usr/contrib/lib and 1303 # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow 1304 # libtool to hard-code these into programs 1305 ;; 1306 1307cygwin* | mingw* | pw32*) 1308 version_type=windows 1309 shrext=".dll" 1310 need_version=no 1311 need_lib_prefix=no 1312 1313 case $GCC,$host_os in 1314 yes,cygwin* | yes,mingw* | yes,pw32*) 1315 library_names_spec='$libname.dll.a' 1316 # DLL is installed to $(libdir)/../bin by postinstall_cmds 1317 postinstall_cmds='base_file=`basename \${file}`~ 1318 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~ 1319 dldir=$destdir/`dirname \$dlpath`~ 1320 test -d \$dldir || mkdir -p \$dldir~ 1321 $install_prog $dir/$dlname \$dldir/$dlname' 1322 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ 1323 dlpath=$dir/\$dldll~ 1324 $rm \$dlpath' 1325 shlibpath_overrides_runpath=yes 1326 1327 case $host_os in 1328 cygwin*) 1329 # Cygwin DLLs use 'cyg' prefix rather than 'lib' 1330 soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' 1331 sys_lib_search_path_spec="/lib /lib/w32api /usr/lib /usr/local/lib" 1332 ;; 1333 mingw*) 1334 # MinGW DLLs use traditional 'lib' prefix 1335 soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' 1336 sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` 1337 if echo "$sys_lib_search_path_spec" | [grep ';[c-zC-Z]:/' >/dev/null]; then 1338 # It is most probably a Windows format PATH printed by 1339 # mingw gcc, but we are running on Cygwin. Gcc prints its search 1340 # path with ; separators, and with drive letters. We can handle the 1341 # drive letters (cygwin fileutils understands them), so leave them, 1342 # especially as we might pass files found there to a mingw objdump, 1343 # which wouldn't understand a cygwinified path. Ahh. 1344 sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` 1345 else 1346 sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` 1347 fi 1348 ;; 1349 pw32*) 1350 # pw32 DLLs use 'pw' prefix rather than 'lib' 1351 library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' 1352 ;; 1353 esac 1354 ;; 1355 1356 *) 1357 library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib' 1358 ;; 1359 esac 1360 dynamic_linker='Win32 ld.exe' 1361 # FIXME: first we should search . and the directory the executable is in 1362 shlibpath_var=PATH 1363 ;; 1364 1365darwin* | rhapsody*) 1366 dynamic_linker="$host_os dyld" 1367 version_type=darwin 1368 need_lib_prefix=no 1369 need_version=no 1370 # FIXME: Relying on posixy $() will cause problems for 1371 # cross-compilation, but unfortunately the echo tests do not 1372 # yet detect zsh echo's removal of \ escapes. 1373 library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext' 1374 soname_spec='${libname}${release}${major}$shared_ext' 1375 shlibpath_overrides_runpath=yes 1376 shlibpath_var=DYLD_LIBRARY_PATH 1377 shrext='$(test .$module = .yes && echo .so || echo .dylib)' 1378 # Apple's gcc prints 'gcc -print-search-dirs' doesn't operate the same. 1379 if $CC -v 2>&1 | grep 'Apple' >/dev/null ; then 1380 sys_lib_search_path_spec=`$CC -print-search-dirs | tr "\n" "$PATH_SEPARATOR" | sed -e 's/libraries:/@libraries:/' | tr "@" "\n" | grep "^libraries:" | sed -e "s/^libraries://" -e "s,=/,/,g" -e "s,$PATH_SEPARATOR, ,g" -e "s,.*,& /lib /usr/lib /usr/local/lib,g"` 1381 fi 1382 sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' 1383 ;; 1384 1385dgux*) 1386 version_type=linux 1387 need_lib_prefix=no 1388 need_version=no 1389 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' 1390 soname_spec='${libname}${release}${shared_ext}$major' 1391 shlibpath_var=LD_LIBRARY_PATH 1392 ;; 1393 1394freebsd1*) 1395 dynamic_linker=no 1396 ;; 1397 1398freebsd*) 1399 objformat=`test -x /usr/bin/objformat && /usr/bin/objformat || echo aout` 1400 version_type=freebsd-$objformat 1401 case $version_type in 1402 freebsd-elf*) 1403 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' 1404 need_version=no 1405 need_lib_prefix=no 1406 ;; 1407 freebsd-*) 1408 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' 1409 need_version=yes 1410 ;; 1411 esac 1412 shlibpath_var=LD_LIBRARY_PATH 1413 case $host_os in 1414 freebsd2*) 1415 shlibpath_overrides_runpath=yes 1416 ;; 1417 freebsd3.[01]* | freebsdelf3.[01]*) 1418 shlibpath_overrides_runpath=yes 1419 hardcode_into_libs=yes 1420 ;; 1421 *) # from 3.2 on 1422 shlibpath_overrides_runpath=no 1423 hardcode_into_libs=yes 1424 ;; 1425 esac 1426 ;; 1427 1428gnu*) 1429 version_type=linux 1430 need_lib_prefix=no 1431 need_version=no 1432 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' 1433 soname_spec='${libname}${release}${shared_ext}$major' 1434 shlibpath_var=LD_LIBRARY_PATH 1435 hardcode_into_libs=yes 1436 ;; 1437 1438hpux9* | hpux10* | hpux11*) 1439 # Give a soname corresponding to the major version so that dld.sl refuses to 1440 # link against other versions. 1441 version_type=sunos 1442 need_lib_prefix=no 1443 need_version=no 1444 case "$host_cpu" in 1445 ia64*) 1446 shrext='.so' 1447 hardcode_into_libs=yes 1448 dynamic_linker="$host_os dld.so" 1449 shlibpath_var=LD_LIBRARY_PATH 1450 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. 1451 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 1452 soname_spec='${libname}${release}${shared_ext}$major' 1453 if test "X$HPUX_IA64_MODE" = X32; then 1454 sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" 1455 else 1456 sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" 1457 fi 1458 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec 1459 ;; 1460 hppa*64*) 1461 shrext='.sl' 1462 hardcode_into_libs=yes 1463 dynamic_linker="$host_os dld.sl" 1464 shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH 1465 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. 1466 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 1467 soname_spec='${libname}${release}${shared_ext}$major' 1468 sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" 1469 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec 1470 ;; 1471 *) 1472 shrext='.sl' 1473 dynamic_linker="$host_os dld.sl" 1474 shlibpath_var=SHLIB_PATH 1475 shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH 1476 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 1477 soname_spec='${libname}${release}${shared_ext}$major' 1478 ;; 1479 esac 1480 # HP-UX runs *really* slowly unless shared libraries are mode 555. 1481 postinstall_cmds='chmod 555 $lib' 1482 ;; 1483 1484irix5* | irix6* | nonstopux*) 1485 case $host_os in 1486 nonstopux*) version_type=nonstopux ;; 1487 *) 1488 if test "$lt_cv_prog_gnu_ld" = yes; then 1489 version_type=linux 1490 else 1491 version_type=irix 1492 fi ;; 1493 esac 1494 need_lib_prefix=no 1495 need_version=no 1496 soname_spec='${libname}${release}${shared_ext}$major' 1497 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' 1498 case $host_os in 1499 irix5* | nonstopux*) 1500 libsuff= shlibsuff= 1501 ;; 1502 *) 1503 case $LD in # libtool.m4 will add one of these switches to LD 1504 *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") 1505 libsuff= shlibsuff= libmagic=32-bit;; 1506 *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") 1507 libsuff=32 shlibsuff=N32 libmagic=N32;; 1508 *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") 1509 libsuff=64 shlibsuff=64 libmagic=64-bit;; 1510 *) libsuff= shlibsuff= libmagic=never-match;; 1511 esac 1512 ;; 1513 esac 1514 shlibpath_var=LD_LIBRARY${shlibsuff}_PATH 1515 shlibpath_overrides_runpath=no 1516 sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" 1517 sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" 1518 hardcode_into_libs=yes 1519 ;; 1520 1521# No shared lib support for Linux oldld, aout, or coff. 1522linux*oldld* | linux*aout* | linux*coff*) 1523 dynamic_linker=no 1524 ;; 1525 1526# This must be Linux ELF. 1527linux*) 1528 version_type=linux 1529 need_lib_prefix=no 1530 need_version=no 1531 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 1532 soname_spec='${libname}${release}${shared_ext}$major' 1533 finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' 1534 shlibpath_var=LD_LIBRARY_PATH 1535 shlibpath_overrides_runpath=no 1536 # This implies no fast_install, which is unacceptable. 1537 # Some rework will be needed to allow for fast_install 1538 # before this can be enabled. 1539 hardcode_into_libs=yes 1540 1541 # We used to test for /lib/ld.so.1 and disable shared libraries on 1542 # powerpc, because MkLinux only supported shared libraries with the 1543 # GNU dynamic linker. Since this was broken with cross compilers, 1544 # most powerpc-linux boxes support dynamic linking these days and 1545 # people can always --disable-shared, the test was removed, and we 1546 # assume the GNU/Linux dynamic linker is in use. 1547 dynamic_linker='GNU/Linux ld.so' 1548 ;; 1549 1550netbsd*) 1551 version_type=sunos 1552 need_lib_prefix=no 1553 need_version=no 1554 if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then 1555 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' 1556 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' 1557 dynamic_linker='NetBSD (a.out) ld.so' 1558 else 1559 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} ${libname}${shared_ext}' 1560 soname_spec='${libname}${release}${shared_ext}$major' 1561 dynamic_linker='NetBSD ld.elf_so' 1562 fi 1563 shlibpath_var=LD_LIBRARY_PATH 1564 shlibpath_overrides_runpath=yes 1565 hardcode_into_libs=yes 1566 ;; 1567 1568newsos6) 1569 version_type=linux 1570 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 1571 shlibpath_var=LD_LIBRARY_PATH 1572 shlibpath_overrides_runpath=yes 1573 ;; 1574 1575nto-qnx) 1576 version_type=linux 1577 need_lib_prefix=no 1578 need_version=no 1579 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 1580 soname_spec='${libname}${release}${shared_ext}$major' 1581 shlibpath_var=LD_LIBRARY_PATH 1582 shlibpath_overrides_runpath=yes 1583 ;; 1584 1585openbsd*) 1586 version_type=sunos 1587 need_lib_prefix=no 1588 need_version=no 1589 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' 1590 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' 1591 shlibpath_var=LD_LIBRARY_PATH 1592 if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then 1593 case $host_os in 1594 openbsd2.[[89]] | openbsd2.[[89]].*) 1595 shlibpath_overrides_runpath=no 1596 ;; 1597 *) 1598 shlibpath_overrides_runpath=yes 1599 ;; 1600 esac 1601 else 1602 shlibpath_overrides_runpath=yes 1603 fi 1604 ;; 1605 1606os2*) 1607 libname_spec='$name' 1608 shrext=".dll" 1609 need_lib_prefix=no 1610 library_names_spec='$libname${shared_ext} $libname.a' 1611 dynamic_linker='OS/2 ld.exe' 1612 shlibpath_var=LIBPATH 1613 ;; 1614 1615osf3* | osf4* | osf5*) 1616 version_type=osf 1617 need_lib_prefix=no 1618 need_version=no 1619 soname_spec='${libname}${release}${shared_ext}$major' 1620 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 1621 shlibpath_var=LD_LIBRARY_PATH 1622 sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" 1623 sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" 1624 ;; 1625 1626sco3.2v5*) 1627 version_type=osf 1628 soname_spec='${libname}${release}${shared_ext}$major' 1629 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 1630 shlibpath_var=LD_LIBRARY_PATH 1631 ;; 1632 1633solaris*) 1634 version_type=linux 1635 need_lib_prefix=no 1636 need_version=no 1637 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 1638 soname_spec='${libname}${release}${shared_ext}$major' 1639 shlibpath_var=LD_LIBRARY_PATH 1640 shlibpath_overrides_runpath=yes 1641 hardcode_into_libs=yes 1642 # ldd complains unless libraries are executable 1643 postinstall_cmds='chmod +x $lib' 1644 ;; 1645 1646sunos4*) 1647 version_type=sunos 1648 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' 1649 finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' 1650 shlibpath_var=LD_LIBRARY_PATH 1651 shlibpath_overrides_runpath=yes 1652 if test "$with_gnu_ld" = yes; then 1653 need_lib_prefix=no 1654 fi 1655 need_version=yes 1656 ;; 1657 1658sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) 1659 version_type=linux 1660 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 1661 soname_spec='${libname}${release}${shared_ext}$major' 1662 shlibpath_var=LD_LIBRARY_PATH 1663 case $host_vendor in 1664 sni) 1665 shlibpath_overrides_runpath=no 1666 need_lib_prefix=no 1667 export_dynamic_flag_spec='${wl}-Blargedynsym' 1668 runpath_var=LD_RUN_PATH 1669 ;; 1670 siemens) 1671 need_lib_prefix=no 1672 ;; 1673 motorola) 1674 need_lib_prefix=no 1675 need_version=no 1676 shlibpath_overrides_runpath=no 1677 sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' 1678 ;; 1679 esac 1680 ;; 1681 1682sysv4*MP*) 1683 if test -d /usr/nec ;then 1684 version_type=linux 1685 library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' 1686 soname_spec='$libname${shared_ext}.$major' 1687 shlibpath_var=LD_LIBRARY_PATH 1688 fi 1689 ;; 1690 1691uts4*) 1692 version_type=linux 1693 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 1694 soname_spec='${libname}${release}${shared_ext}$major' 1695 shlibpath_var=LD_LIBRARY_PATH 1696 ;; 1697 1698*) 1699 dynamic_linker=no 1700 ;; 1701esac 1702AC_MSG_RESULT([$dynamic_linker]) 1703test "$dynamic_linker" = no && can_build_shared=no 1704])# AC_LIBTOOL_SYS_DYNAMIC_LINKER 1705 1706 1707# _LT_AC_TAGCONFIG 1708# ---------------- 1709AC_DEFUN([_LT_AC_TAGCONFIG], 1710[AC_ARG_WITH([tags], 1711 [AC_HELP_STRING([--with-tags@<:@=TAGS@:>@], 1712 [include additional configurations @<:@automatic@:>@])], 1713 [tagnames="$withval"]) 1714 1715if test -f "$ltmain" && test -n "$tagnames"; then 1716 if test ! -f "${ofile}"; then 1717 AC_MSG_WARN([output file `$ofile' does not exist]) 1718 fi 1719 1720 if test -z "$LTCC"; then 1721 eval "`$SHELL ${ofile} --config | grep '^LTCC='`" 1722 if test -z "$LTCC"; then 1723 AC_MSG_WARN([output file `$ofile' does not look like a libtool script]) 1724 else 1725 AC_MSG_WARN([using `LTCC=$LTCC', extracted from `$ofile']) 1726 fi 1727 fi 1728 1729 # Extract list of available tagged configurations in $ofile. 1730 # Note that this assumes the entire list is on one line. 1731 available_tags=`grep "^available_tags=" "${ofile}" | $SED -e 's/available_tags=\(.*$\)/\1/' -e 's/\"//g'` 1732 1733 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," 1734 for tagname in $tagnames; do 1735 IFS="$lt_save_ifs" 1736 # Check whether tagname contains only valid characters 1737 case `$echo "X$tagname" | $Xsed -e 's:[[-_ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890,/]]::g'` in 1738 "") ;; 1739 *) AC_MSG_ERROR([invalid tag name: $tagname]) 1740 ;; 1741 esac 1742 1743 if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$" < "${ofile}" > /dev/null 1744 then 1745 AC_MSG_ERROR([tag name \"$tagname\" already exists]) 1746 fi 1747 1748 # Update the list of available tags. 1749 if test -n "$tagname"; then 1750 echo appending configuration tag \"$tagname\" to $ofile 1751 1752 case $tagname in 1753 CXX) 1754 if test -n "$CXX" && test "X$CXX" != "Xno"; then 1755 AC_LIBTOOL_LANG_CXX_CONFIG 1756 else 1757 tagname="" 1758 fi 1759 ;; 1760 1761 F77) 1762 if test -n "$F77" && test "X$F77" != "Xno"; then 1763 AC_LIBTOOL_LANG_F77_CONFIG 1764 else 1765 tagname="" 1766 fi 1767 ;; 1768 1769 GCJ) 1770 if test -n "$GCJ" && test "X$GCJ" != "Xno"; then 1771 AC_LIBTOOL_LANG_GCJ_CONFIG 1772 else 1773 tagname="" 1774 fi 1775 ;; 1776 1777 RC) 1778 AC_LIBTOOL_LANG_RC_CONFIG 1779 ;; 1780 1781 *) 1782 AC_MSG_ERROR([Unsupported tag name: $tagname]) 1783 ;; 1784 esac 1785 1786 # Append the new tag name to the list of available tags. 1787 if test -n "$tagname" ; then 1788 available_tags="$available_tags $tagname" 1789 fi 1790 fi 1791 done 1792 IFS="$lt_save_ifs" 1793 1794 # Now substitute the updated list of available tags. 1795 if eval "sed -e 's/^available_tags=.*\$/available_tags=\"$available_tags\"/' \"$ofile\" > \"${ofile}T\""; then 1796 mv "${ofile}T" "$ofile" 1797 chmod +x "$ofile" 1798 else 1799 rm -f "${ofile}T" 1800 AC_MSG_ERROR([unable to update list of available tagged configurations.]) 1801 fi 1802fi 1803])# _LT_AC_TAGCONFIG 1804 1805 1806# AC_LIBTOOL_DLOPEN 1807# ----------------- 1808# enable checks for dlopen support 1809AC_DEFUN([AC_LIBTOOL_DLOPEN], 1810 [AC_BEFORE([$0],[AC_LIBTOOL_SETUP]) 1811])# AC_LIBTOOL_DLOPEN 1812 1813 1814# AC_LIBTOOL_WIN32_DLL 1815# -------------------- 1816# declare package support for building win32 dll's 1817AC_DEFUN([AC_LIBTOOL_WIN32_DLL], 1818[AC_BEFORE([$0], [AC_LIBTOOL_SETUP]) 1819])# AC_LIBTOOL_WIN32_DLL 1820 1821 1822# AC_ENABLE_SHARED([DEFAULT]) 1823# --------------------------- 1824# implement the --enable-shared flag 1825# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. 1826AC_DEFUN([AC_ENABLE_SHARED], 1827[define([AC_ENABLE_SHARED_DEFAULT], ifelse($1, no, no, yes))dnl 1828AC_ARG_ENABLE([shared], 1829 [AC_HELP_STRING([--enable-shared@<:@=PKGS@:>@], 1830 [build shared libraries @<:@default=]AC_ENABLE_SHARED_DEFAULT[@:>@])], 1831 [p=${PACKAGE-default} 1832 case $enableval in 1833 yes) enable_shared=yes ;; 1834 no) enable_shared=no ;; 1835 *) 1836 enable_shared=no 1837 # Look at the argument we got. We use all the common list separators. 1838 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," 1839 for pkg in $enableval; do 1840 IFS="$lt_save_ifs" 1841 if test "X$pkg" = "X$p"; then 1842 enable_shared=yes 1843 fi 1844 done 1845 IFS="$lt_save_ifs" 1846 ;; 1847 esac], 1848 [enable_shared=]AC_ENABLE_SHARED_DEFAULT) 1849])# AC_ENABLE_SHARED 1850 1851 1852# AC_DISABLE_SHARED 1853# ----------------- 1854#- set the default shared flag to --disable-shared 1855AC_DEFUN([AC_DISABLE_SHARED], 1856[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl 1857AC_ENABLE_SHARED(no) 1858])# AC_DISABLE_SHARED 1859 1860 1861# AC_ENABLE_STATIC([DEFAULT]) 1862# --------------------------- 1863# implement the --enable-static flag 1864# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. 1865AC_DEFUN([AC_ENABLE_STATIC], 1866[define([AC_ENABLE_STATIC_DEFAULT], ifelse($1, no, no, yes))dnl 1867AC_ARG_ENABLE([static], 1868 [AC_HELP_STRING([--enable-static@<:@=PKGS@:>@], 1869 [build static libraries @<:@default=]AC_ENABLE_STATIC_DEFAULT[@:>@])], 1870 [p=${PACKAGE-default} 1871 case $enableval in 1872 yes) enable_static=yes ;; 1873 no) enable_static=no ;; 1874 *) 1875 enable_static=no 1876 # Look at the argument we got. We use all the common list separators. 1877 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," 1878 for pkg in $enableval; do 1879 IFS="$lt_save_ifs" 1880 if test "X$pkg" = "X$p"; then 1881 enable_static=yes 1882 fi 1883 done 1884 IFS="$lt_save_ifs" 1885 ;; 1886 esac], 1887 [enable_static=]AC_ENABLE_STATIC_DEFAULT) 1888])# AC_ENABLE_STATIC 1889 1890 1891# AC_DISABLE_STATIC 1892# ----------------- 1893# set the default static flag to --disable-static 1894AC_DEFUN([AC_DISABLE_STATIC], 1895[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl 1896AC_ENABLE_STATIC(no) 1897])# AC_DISABLE_STATIC 1898 1899 1900# AC_ENABLE_FAST_INSTALL([DEFAULT]) 1901# --------------------------------- 1902# implement the --enable-fast-install flag 1903# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. 1904AC_DEFUN([AC_ENABLE_FAST_INSTALL], 1905[define([AC_ENABLE_FAST_INSTALL_DEFAULT], ifelse($1, no, no, yes))dnl 1906AC_ARG_ENABLE([fast-install], 1907 [AC_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@], 1908 [optimize for fast installation @<:@default=]AC_ENABLE_FAST_INSTALL_DEFAULT[@:>@])], 1909 [p=${PACKAGE-default} 1910 case $enableval in 1911 yes) enable_fast_install=yes ;; 1912 no) enable_fast_install=no ;; 1913 *) 1914 enable_fast_install=no 1915 # Look at the argument we got. We use all the common list separators. 1916 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," 1917 for pkg in $enableval; do 1918 IFS="$lt_save_ifs" 1919 if test "X$pkg" = "X$p"; then 1920 enable_fast_install=yes 1921 fi 1922 done 1923 IFS="$lt_save_ifs" 1924 ;; 1925 esac], 1926 [enable_fast_install=]AC_ENABLE_FAST_INSTALL_DEFAULT) 1927])# AC_ENABLE_FAST_INSTALL 1928 1929 1930# AC_DISABLE_FAST_INSTALL 1931# ----------------------- 1932# set the default to --disable-fast-install 1933AC_DEFUN([AC_DISABLE_FAST_INSTALL], 1934[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl 1935AC_ENABLE_FAST_INSTALL(no) 1936])# AC_DISABLE_FAST_INSTALL 1937 1938 1939# AC_LIBTOOL_PICMODE([MODE]) 1940# -------------------------- 1941# implement the --with-pic flag 1942# MODE is either `yes' or `no'. If omitted, it defaults to `both'. 1943AC_DEFUN([AC_LIBTOOL_PICMODE], 1944[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl 1945pic_mode=ifelse($#,1,$1,default) 1946])# AC_LIBTOOL_PICMODE 1947 1948 1949# AC_PROG_EGREP 1950# ------------- 1951# This is predefined starting with Autoconf 2.54, so this conditional 1952# definition can be removed once we require Autoconf 2.54 or later. 1953m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP], 1954[AC_CACHE_CHECK([for egrep], [ac_cv_prog_egrep], 1955 [if echo a | (grep -E '(a|b)') >/dev/null 2>&1 1956 then ac_cv_prog_egrep='grep -E' 1957 else ac_cv_prog_egrep='egrep' 1958 fi]) 1959 EGREP=$ac_cv_prog_egrep 1960 AC_SUBST([EGREP]) 1961])]) 1962 1963 1964# AC_PATH_TOOL_PREFIX 1965# ------------------- 1966# find a file program which can recognise shared library 1967AC_DEFUN([AC_PATH_TOOL_PREFIX], 1968[AC_REQUIRE([AC_PROG_EGREP])dnl 1969AC_MSG_CHECKING([for $1]) 1970AC_CACHE_VAL(lt_cv_path_MAGIC_CMD, 1971[case $MAGIC_CMD in 1972[[\\/*] | ?:[\\/]*]) 1973 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. 1974 ;; 1975*) 1976 lt_save_MAGIC_CMD="$MAGIC_CMD" 1977 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR 1978dnl $ac_dummy forces splitting on constant user-supplied paths. 1979dnl POSIX.2 word splitting is done only on the output of word expansions, 1980dnl not every word. This closes a longstanding sh security hole. 1981 ac_dummy="ifelse([$2], , $PATH, [$2])" 1982 for ac_dir in $ac_dummy; do 1983 IFS="$lt_save_ifs" 1984 test -z "$ac_dir" && ac_dir=. 1985 if test -f $ac_dir/$1; then 1986 lt_cv_path_MAGIC_CMD="$ac_dir/$1" 1987 if test -n "$file_magic_test_file"; then 1988 case $deplibs_check_method in 1989 "file_magic "*) 1990 file_magic_regex="`expr \"$deplibs_check_method\" : \"file_magic \(.*\)\"`" 1991 MAGIC_CMD="$lt_cv_path_MAGIC_CMD" 1992 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | 1993 $EGREP "$file_magic_regex" > /dev/null; then 1994 : 1995 else 1996 cat <<EOF 1>&2 1997 1998*** Warning: the command libtool uses to detect shared libraries, 1999*** $file_magic_cmd, produces output that libtool cannot recognize. 2000*** The result is that libtool may fail to recognize shared libraries 2001*** as such. This will affect the creation of libtool libraries that 2002*** depend on shared libraries, but programs linked with such libtool 2003*** libraries will work regardless of this problem. Nevertheless, you 2004*** may want to report the problem to your system manager and/or to 2005*** bug-libtool@gnu.org 2006 2007EOF 2008 fi ;; 2009 esac 2010 fi 2011 break 2012 fi 2013 done 2014 IFS="$lt_save_ifs" 2015 MAGIC_CMD="$lt_save_MAGIC_CMD" 2016 ;; 2017esac]) 2018MAGIC_CMD="$lt_cv_path_MAGIC_CMD" 2019if test -n "$MAGIC_CMD"; then 2020 AC_MSG_RESULT($MAGIC_CMD) 2021else 2022 AC_MSG_RESULT(no) 2023fi 2024])# AC_PATH_TOOL_PREFIX 2025 2026 2027# AC_PATH_MAGIC 2028# ------------- 2029# find a file program which can recognise a shared library 2030AC_DEFUN([AC_PATH_MAGIC], 2031[AC_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH) 2032if test -z "$lt_cv_path_MAGIC_CMD"; then 2033 if test -n "$ac_tool_prefix"; then 2034 AC_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH) 2035 else 2036 MAGIC_CMD=: 2037 fi 2038fi 2039])# AC_PATH_MAGIC 2040 2041 2042# AC_PROG_LD 2043# ---------- 2044# find the path to the GNU or non-GNU linker 2045AC_DEFUN([AC_PROG_LD], 2046[AC_ARG_WITH([gnu-ld], 2047 [AC_HELP_STRING([--with-gnu-ld], 2048 [assume the C compiler uses GNU ld @<:@default=no@:>@])], 2049 [test "$withval" = no || with_gnu_ld=yes], 2050 [with_gnu_ld=no]) 2051AC_REQUIRE([LT_AC_PROG_SED])dnl 2052AC_REQUIRE([AC_PROG_CC])dnl 2053AC_REQUIRE([AC_CANONICAL_HOST])dnl 2054AC_REQUIRE([AC_CANONICAL_BUILD])dnl 2055ac_prog=ld 2056if test "$GCC" = yes; then 2057 # Check if gcc -print-prog-name=ld gives a path. 2058 AC_MSG_CHECKING([for ld used by $CC]) 2059 case $host in 2060 *-*-mingw*) 2061 # gcc leaves a trailing carriage return which upsets mingw 2062 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; 2063 *) 2064 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; 2065 esac 2066 case $ac_prog in 2067 # Accept absolute paths. 2068 [[\\/]]* | ?:[[\\/]]*) 2069 re_direlt='/[[^/]][[^/]]*/\.\./' 2070 # Canonicalize the path of ld 2071 ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'` 2072 while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do 2073 ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"` 2074 done 2075 test -z "$LD" && LD="$ac_prog" 2076 ;; 2077 "") 2078 # If it fails, then pretend we aren't using GCC. 2079 ac_prog=ld 2080 ;; 2081 *) 2082 # If it is relative, then search for the first ld in PATH. 2083 with_gnu_ld=unknown 2084 ;; 2085 esac 2086elif test "$with_gnu_ld" = yes; then 2087 AC_MSG_CHECKING([for GNU ld]) 2088else 2089 AC_MSG_CHECKING([for non-GNU ld]) 2090fi 2091AC_CACHE_VAL(lt_cv_path_LD, 2092[if test -z "$LD"; then 2093 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR 2094 for ac_dir in $PATH; do 2095 IFS="$lt_save_ifs" 2096 test -z "$ac_dir" && ac_dir=. 2097 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then 2098 lt_cv_path_LD="$ac_dir/$ac_prog" 2099 # Check to see if the program is GNU ld. I'd rather use --version, 2100 # but apparently some GNU ld's only accept -v. 2101 # Break only if it was the GNU/non-GNU ld that we prefer. 2102 case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in 2103 *GNU* | *'with BFD'*) 2104 test "$with_gnu_ld" != no && break 2105 ;; 2106 *) 2107 test "$with_gnu_ld" != yes && break 2108 ;; 2109 esac 2110 fi 2111 done 2112 IFS="$lt_save_ifs" 2113else 2114 lt_cv_path_LD="$LD" # Let the user override the test with a path. 2115fi]) 2116LD="$lt_cv_path_LD" 2117if test -n "$LD"; then 2118 AC_MSG_RESULT($LD) 2119else 2120 AC_MSG_RESULT(no) 2121fi 2122test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH]) 2123AC_PROG_LD_GNU 2124])# AC_PROG_LD 2125 2126 2127# AC_PROG_LD_GNU 2128# -------------- 2129AC_DEFUN([AC_PROG_LD_GNU], 2130[AC_REQUIRE([AC_PROG_EGREP])dnl 2131AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld, 2132[# I'd rather use --version here, but apparently some GNU ld's only accept -v. 2133case `"$LD" -v 2>&1 </dev/null` in 2134*GNU* | *'with BFD'*) 2135 lt_cv_prog_gnu_ld=yes 2136 ;; 2137*) 2138 lt_cv_prog_gnu_ld=no 2139 ;; 2140esac]) 2141with_gnu_ld=$lt_cv_prog_gnu_ld 2142])# AC_PROG_LD_GNU 2143 2144 2145# AC_PROG_LD_RELOAD_FLAG 2146# ---------------------- 2147# find reload flag for linker 2148# -- PORTME Some linkers may need a different reload flag. 2149AC_DEFUN([AC_PROG_LD_RELOAD_FLAG], 2150[AC_CACHE_CHECK([for $LD option to reload object files], 2151 lt_cv_ld_reload_flag, 2152 [lt_cv_ld_reload_flag='-r']) 2153reload_flag=$lt_cv_ld_reload_flag 2154case $reload_flag in 2155"" | " "*) ;; 2156*) reload_flag=" $reload_flag" ;; 2157esac 2158reload_cmds='$LD$reload_flag -o $output$reload_objs' 2159])# AC_PROG_LD_RELOAD_FLAG 2160 2161 2162# AC_DEPLIBS_CHECK_METHOD 2163# ----------------------- 2164# how to check for library dependencies 2165# -- PORTME fill in with the dynamic library characteristics 2166AC_DEFUN([AC_DEPLIBS_CHECK_METHOD], 2167[AC_CACHE_CHECK([how to recognise dependent libraries], 2168lt_cv_deplibs_check_method, 2169[lt_cv_file_magic_cmd='$MAGIC_CMD' 2170lt_cv_file_magic_test_file= 2171lt_cv_deplibs_check_method='unknown' 2172# Need to set the preceding variable on all platforms that support 2173# interlibrary dependencies. 2174# 'none' -- dependencies not supported. 2175# `unknown' -- same as none, but documents that we really don't know. 2176# 'pass_all' -- all dependencies passed with no checks. 2177# 'test_compile' -- check by making test program. 2178# 'file_magic [[regex]]' -- check by looking for files in library path 2179# which responds to the $file_magic_cmd with a given extended regex. 2180# If you have `file' or equivalent on your system and you're not sure 2181# whether `pass_all' will *always* work, you probably want this one. 2182 2183case $host_os in 2184aix4* | aix5*) 2185 lt_cv_deplibs_check_method=pass_all 2186 ;; 2187 2188beos*) 2189 lt_cv_deplibs_check_method=pass_all 2190 ;; 2191 2192bsdi4*) 2193 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)' 2194 lt_cv_file_magic_cmd='/usr/bin/file -L' 2195 lt_cv_file_magic_test_file=/shlib/libc.so 2196 ;; 2197 2198cygwin* | mingw* | pw32*) 2199 # win32_libid is a shell function defined in ltmain.sh 2200 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' 2201 lt_cv_file_magic_cmd='win32_libid' 2202 ;; 2203 2204darwin* | rhapsody*) 2205 # this will be overwritten by pass_all, but leave it in just in case 2206 lt_cv_deplibs_check_method='file_magic Mach-O dynamically linked shared library' 2207 lt_cv_file_magic_cmd='/usr/bin/file -L' 2208 case "$host_os" in 2209 rhapsody* | darwin1.[[012]]) 2210 lt_cv_file_magic_test_file=`/System/Library/Frameworks/System.framework/System` 2211 ;; 2212 *) # Darwin 1.3 on 2213 lt_cv_file_magic_test_file='/usr/lib/libSystem.dylib' 2214 ;; 2215 esac 2216 lt_cv_deplibs_check_method=pass_all 2217 ;; 2218 2219freebsd*) 2220 if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then 2221 case $host_cpu in 2222 i*86 ) 2223 # Not sure whether the presence of OpenBSD here was a mistake. 2224 # Let's accept both of them until this is cleared up. 2225 lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD)/i[[3-9]]86 (compact )?demand paged shared library' 2226 lt_cv_file_magic_cmd=/usr/bin/file 2227 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` 2228 ;; 2229 esac 2230 else 2231 lt_cv_deplibs_check_method=pass_all 2232 fi 2233 ;; 2234 2235gnu*) 2236 lt_cv_deplibs_check_method=pass_all 2237 ;; 2238 2239hpux10.20* | hpux11*) 2240 lt_cv_file_magic_cmd=/usr/bin/file 2241 case "$host_cpu" in 2242 ia64*) 2243 lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64' 2244 lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so 2245 ;; 2246 hppa*64*) 2247 [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]'] 2248 lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl 2249 ;; 2250 *) 2251 lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]].[[0-9]]) shared library' 2252 lt_cv_file_magic_test_file=/usr/lib/libc.sl 2253 ;; 2254 esac 2255 ;; 2256 2257irix5* | irix6* | nonstopux*) 2258 case $host_os in 2259 irix5* | nonstopux*) 2260 # this will be overridden with pass_all, but let us keep it just in case 2261 lt_cv_deplibs_check_method="file_magic ELF 32-bit MSB dynamic lib MIPS - version 1" 2262 ;; 2263 *) 2264 case $LD in 2265 *-32|*"-32 ") libmagic=32-bit;; 2266 *-n32|*"-n32 ") libmagic=N32;; 2267 *-64|*"-64 ") libmagic=64-bit;; 2268 *) libmagic=never-match;; 2269 esac 2270 # this will be overridden with pass_all, but let us keep it just in case 2271 lt_cv_deplibs_check_method="file_magic ELF ${libmagic} MSB mips-[[1234]] dynamic lib MIPS - version 1" 2272 ;; 2273 esac 2274 lt_cv_file_magic_test_file=`echo /lib${libsuff}/libc.so*` 2275 lt_cv_deplibs_check_method=pass_all 2276 ;; 2277 2278# This must be Linux ELF. 2279linux*) 2280 case $host_cpu in 2281 alpha* | hppa* | i*86 | ia64* | m68* | mips | mipsel | powerpc* | sparc* | s390* | sh*) 2282 lt_cv_deplibs_check_method=pass_all ;; 2283 *) 2284 # glibc up to 2.1.1 does not perform some relocations on ARM 2285 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )' ;; 2286 esac 2287 lt_cv_file_magic_test_file=`echo /lib/libc.so* /lib/libc-*.so` 2288 ;; 2289 2290netbsd*) 2291 if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then 2292 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' 2293 else 2294 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$' 2295 fi 2296 ;; 2297 2298newos6*) 2299 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)' 2300 lt_cv_file_magic_cmd=/usr/bin/file 2301 lt_cv_file_magic_test_file=/usr/lib/libnls.so 2302 ;; 2303 2304nto-qnx) 2305 lt_cv_deplibs_check_method=unknown 2306 ;; 2307 2308openbsd*) 2309 lt_cv_file_magic_cmd=/usr/bin/file 2310 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` 2311 if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then 2312 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB shared object' 2313 else 2314 lt_cv_deplibs_check_method='file_magic OpenBSD.* shared library' 2315 fi 2316 ;; 2317 2318osf3* | osf4* | osf5*) 2319 # this will be overridden with pass_all, but let us keep it just in case 2320 lt_cv_deplibs_check_method='file_magic COFF format alpha shared library' 2321 lt_cv_file_magic_test_file=/shlib/libc.so 2322 lt_cv_deplibs_check_method=pass_all 2323 ;; 2324 2325sco3.2v5*) 2326 lt_cv_deplibs_check_method=pass_all 2327 ;; 2328 2329solaris*) 2330 lt_cv_deplibs_check_method=pass_all 2331 lt_cv_file_magic_test_file=/lib/libc.so 2332 ;; 2333 2334sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) 2335 case $host_vendor in 2336 motorola) 2337 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]]' 2338 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` 2339 ;; 2340 ncr) 2341 lt_cv_deplibs_check_method=pass_all 2342 ;; 2343 sequent) 2344 lt_cv_file_magic_cmd='/bin/file' 2345 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )' 2346 ;; 2347 sni) 2348 lt_cv_file_magic_cmd='/bin/file' 2349 lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib" 2350 lt_cv_file_magic_test_file=/lib/libc.so 2351 ;; 2352 siemens) 2353 lt_cv_deplibs_check_method=pass_all 2354 ;; 2355 esac 2356 ;; 2357 2358sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[[78]]* | unixware7* | sysv4*uw2*) 2359 lt_cv_deplibs_check_method=pass_all 2360 ;; 2361esac 2362]) 2363file_magic_cmd=$lt_cv_file_magic_cmd 2364deplibs_check_method=$lt_cv_deplibs_check_method 2365test -z "$deplibs_check_method" && deplibs_check_method=unknown 2366])# AC_DEPLIBS_CHECK_METHOD 2367 2368 2369# AC_PROG_NM 2370# ---------- 2371# find the path to a BSD-compatible name lister 2372AC_DEFUN([AC_PROG_NM], 2373[AC_CACHE_CHECK([for BSD-compatible nm], lt_cv_path_NM, 2374[if test -n "$NM"; then 2375 # Let the user override the test. 2376 lt_cv_path_NM="$NM" 2377else 2378 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR 2379 for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do 2380 IFS="$lt_save_ifs" 2381 test -z "$ac_dir" && ac_dir=. 2382 tmp_nm="$ac_dir/${ac_tool_prefix}nm" 2383 if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then 2384 # Check to see if the nm accepts a BSD-compat flag. 2385 # Adding the `sed 1q' prevents false positives on HP-UX, which says: 2386 # nm: unknown option "B" ignored 2387 # Tru64's nm complains that /dev/null is an invalid object file 2388 case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in 2389 */dev/null* | *'Invalid file or object type'*) 2390 lt_cv_path_NM="$tmp_nm -B" 2391 break 2392 ;; 2393 *) 2394 case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in 2395 */dev/null*) 2396 lt_cv_path_NM="$tmp_nm -p" 2397 break 2398 ;; 2399 *) 2400 lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but 2401 continue # so that we can try to find one that supports BSD flags 2402 ;; 2403 esac 2404 esac 2405 fi 2406 done 2407 IFS="$lt_save_ifs" 2408 test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm 2409fi]) 2410NM="$lt_cv_path_NM" 2411])# AC_PROG_NM 2412 2413 2414# AC_CHECK_LIBM 2415# ------------- 2416# check for math library 2417AC_DEFUN([AC_CHECK_LIBM], 2418[AC_REQUIRE([AC_CANONICAL_HOST])dnl 2419LIBM= 2420case $host in 2421*-*-beos* | *-*-cygwin* | *-*-pw32* | *-*-darwin*) 2422 # These system don't have libm, or don't need it 2423 ;; 2424*-ncr-sysv4.3*) 2425 AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw") 2426 AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm") 2427 ;; 2428*) 2429 AC_CHECK_LIB(m, cos, LIBM="-lm") 2430 ;; 2431esac 2432])# AC_CHECK_LIBM 2433 2434 2435# AC_LIBLTDL_CONVENIENCE([DIRECTORY]) 2436# ----------------------------------- 2437# sets LIBLTDL to the link flags for the libltdl convenience library and 2438# LTDLINCL to the include flags for the libltdl header and adds 2439# --enable-ltdl-convenience to the configure arguments. Note that LIBLTDL 2440# and LTDLINCL are not AC_SUBSTed, nor is AC_CONFIG_SUBDIRS called. If 2441# DIRECTORY is not provided, it is assumed to be `libltdl'. LIBLTDL will 2442# be prefixed with '${top_builddir}/' and LTDLINCL will be prefixed with 2443# '${top_srcdir}/' (note the single quotes!). If your package is not 2444# flat and you're not using automake, define top_builddir and 2445# top_srcdir appropriately in the Makefiles. 2446AC_DEFUN([AC_LIBLTDL_CONVENIENCE], 2447[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl 2448 case $enable_ltdl_convenience in 2449 no) AC_MSG_ERROR([this package needs a convenience libltdl]) ;; 2450 "") enable_ltdl_convenience=yes 2451 ac_configure_args="$ac_configure_args --enable-ltdl-convenience" ;; 2452 esac 2453 LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdlc.la 2454 LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl']) 2455 # For backwards non-gettext consistent compatibility... 2456 INCLTDL="$LTDLINCL" 2457])# AC_LIBLTDL_CONVENIENCE 2458 2459 2460# AC_LIBLTDL_INSTALLABLE([DIRECTORY]) 2461# ----------------------------------- 2462# sets LIBLTDL to the link flags for the libltdl installable library and 2463# LTDLINCL to the include flags for the libltdl header and adds 2464# --enable-ltdl-install to the configure arguments. Note that LIBLTDL 2465# and LTDLINCL are not AC_SUBSTed, nor is AC_CONFIG_SUBDIRS called. If 2466# DIRECTORY is not provided and an installed libltdl is not found, it is 2467# assumed to be `libltdl'. LIBLTDL will be prefixed with '${top_builddir}/' 2468# and LTDLINCL will be prefixed with '${top_srcdir}/' (note the single 2469# quotes!). If your package is not flat and you're not using automake, 2470# define top_builddir and top_srcdir appropriately in the Makefiles. 2471# In the future, this macro may have to be called after AC_PROG_LIBTOOL. 2472AC_DEFUN([AC_LIBLTDL_INSTALLABLE], 2473[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl 2474 AC_CHECK_LIB(ltdl, lt_dlinit, 2475 [test x"$enable_ltdl_install" != xyes && enable_ltdl_install=no], 2476 [if test x"$enable_ltdl_install" = xno; then 2477 AC_MSG_WARN([libltdl not installed, but installation disabled]) 2478 else 2479 enable_ltdl_install=yes 2480 fi 2481 ]) 2482 if test x"$enable_ltdl_install" = x"yes"; then 2483 ac_configure_args="$ac_configure_args --enable-ltdl-install" 2484 LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdl.la 2485 LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl']) 2486 else 2487 ac_configure_args="$ac_configure_args --enable-ltdl-install=no" 2488 LIBLTDL="-lltdl" 2489 LTDLINCL= 2490 fi 2491 # For backwards non-gettext consistent compatibility... 2492 INCLTDL="$LTDLINCL" 2493])# AC_LIBLTDL_INSTALLABLE 2494 2495 2496# AC_LIBTOOL_CXX 2497# -------------- 2498# enable support for C++ libraries 2499AC_DEFUN([AC_LIBTOOL_CXX], 2500[AC_REQUIRE([_LT_AC_LANG_CXX]) 2501])# AC_LIBTOOL_CXX 2502 2503 2504# _LT_AC_LANG_CXX 2505# --------------- 2506AC_DEFUN([_LT_AC_LANG_CXX], 2507[AC_REQUIRE([AC_PROG_CXX]) 2508AC_REQUIRE([AC_PROG_CXXCPP]) 2509_LT_AC_SHELL_INIT([tagnames=`echo "$tagnames,CXX" | sed 's/^,//'`]) 2510])# _LT_AC_LANG_CXX 2511 2512 2513# AC_LIBTOOL_F77 2514# -------------- 2515# enable support for Fortran 77 libraries 2516AC_DEFUN([AC_LIBTOOL_F77], 2517[AC_REQUIRE([_LT_AC_LANG_F77]) 2518])# AC_LIBTOOL_F77 2519 2520 2521# _LT_AC_LANG_F77 2522# --------------- 2523AC_DEFUN([_LT_AC_LANG_F77], 2524[AC_REQUIRE([AC_PROG_F77]) 2525_LT_AC_SHELL_INIT([tagnames=`echo "$tagnames,F77" | sed 's/^,//'`]) 2526])# _LT_AC_LANG_F77 2527 2528 2529# AC_LIBTOOL_GCJ 2530# -------------- 2531# enable support for GCJ libraries 2532AC_DEFUN([AC_LIBTOOL_GCJ], 2533[AC_REQUIRE([_LT_AC_LANG_GCJ]) 2534])# AC_LIBTOOL_GCJ 2535 2536 2537# _LT_AC_LANG_GCJ 2538# --------------- 2539AC_DEFUN([_LT_AC_LANG_GCJ], 2540[AC_PROVIDE_IFELSE([AC_PROG_GCJ],[], 2541 [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],[], 2542 [AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ],[], 2543 [ifdef([AC_PROG_GCJ],[AC_REQUIRE([AC_PROG_GCJ])], 2544 [ifdef([A][M_PROG_GCJ],[AC_REQUIRE([A][M_PROG_GCJ])], 2545 [AC_REQUIRE([A][C_PROG_GCJ_OR_A][M_PROG_GCJ])])])])])]) 2546_LT_AC_SHELL_INIT([tagnames=`echo "$tagnames,GCJ" | sed 's/^,//'`]) 2547])# _LT_AC_LANG_GCJ 2548 2549 2550# AC_LIBTOOL_RC 2551# -------------- 2552# enable support for Windows resource files 2553AC_DEFUN([AC_LIBTOOL_RC], 2554[AC_REQUIRE([LT_AC_PROG_RC]) 2555_LT_AC_SHELL_INIT([tagnames=`echo "$tagnames,RC" | sed 's/^,//'`]) 2556])# AC_LIBTOOL_RC 2557 2558 2559# AC_LIBTOOL_LANG_C_CONFIG 2560# ------------------------ 2561# Ensure that the configuration vars for the C compiler are 2562# suitably defined. Those variables are subsequently used by 2563# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'. 2564AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG], [_LT_AC_LANG_C_CONFIG]) 2565AC_DEFUN([_LT_AC_LANG_C_CONFIG], 2566[lt_save_CC="$CC" 2567AC_LANG_PUSH(C) 2568 2569# Source file extension for C test sources. 2570ac_ext=c 2571 2572# Object file extension for compiled C test sources. 2573objext=o 2574_LT_AC_TAGVAR(objext, $1)=$objext 2575 2576# Code to be used in simple compile tests 2577lt_simple_compile_test_code="int some_variable = 0;\n" 2578 2579# Code to be used in simple link tests 2580lt_simple_link_test_code='int main(){return(0);}\n' 2581 2582_LT_AC_SYS_COMPILER 2583 2584# 2585# Check for any special shared library compilation flags. 2586# 2587_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)= 2588if test "$GCC" = no; then 2589 case $host_os in 2590 sco3.2v5*) 2591 _LT_AC_TAGVAR(lt_prog_cc_shlib, $1)='-belf' 2592 ;; 2593 esac 2594fi 2595if test -n "$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)"; then 2596 AC_MSG_WARN([`$CC' requires `$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)' to build shared libraries]) 2597 if echo "$old_CC $old_CFLAGS " | grep "[[ ]]$]_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)[[[ ]]" >/dev/null; then : 2598 else 2599 AC_MSG_WARN([add `$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)' to the CC or CFLAGS env variable and reconfigure]) 2600 _LT_AC_TAGVAR(lt_cv_prog_cc_can_build_shared, $1)=no 2601 fi 2602fi 2603 2604 2605# 2606# Check to make sure the static flag actually works. 2607# 2608AC_LIBTOOL_LINKER_OPTION([if $compiler static flag $_LT_AC_TAGVAR(lt_prog_compiler_static, $1) works], 2609 _LT_AC_TAGVAR(lt_prog_compiler_static_works, $1), 2610 $_LT_AC_TAGVAR(lt_prog_compiler_static, $1), 2611 [], 2612 [_LT_AC_TAGVAR(lt_prog_compiler_static, $1)=]) 2613 2614 2615AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1) 2616AC_LIBTOOL_PROG_COMPILER_PIC($1) 2617AC_LIBTOOL_PROG_CC_C_O($1) 2618AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1) 2619AC_LIBTOOL_PROG_LD_SHLIBS($1) 2620AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1) 2621AC_LIBTOOL_SYS_LIB_STRIP 2622AC_LIBTOOL_SYS_DYNAMIC_LINKER($1) 2623AC_LIBTOOL_DLOPEN_SELF($1) 2624 2625# Report which librarie types wil actually be built 2626AC_MSG_CHECKING([if libtool supports shared libraries]) 2627AC_MSG_RESULT([$can_build_shared]) 2628 2629AC_MSG_CHECKING([whether to build shared libraries]) 2630test "$can_build_shared" = "no" && enable_shared=no 2631 2632# On AIX, shared libraries and static libraries use the same namespace, and 2633# are all built from PIC. 2634case "$host_os" in 2635aix3*) 2636 test "$enable_shared" = yes && enable_static=no 2637 if test -n "$RANLIB"; then 2638 archive_cmds="$archive_cmds~\$RANLIB \$lib" 2639 postinstall_cmds='$RANLIB $lib' 2640 fi 2641 ;; 2642 2643aix4*) 2644 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then 2645 test "$enable_shared" = yes && enable_static=no 2646 fi 2647 ;; 2648 darwin* | rhapsody*) 2649 if $CC -v 2>&1 | grep 'Apple' >/dev/null ; then 2650 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no 2651 case "$host_os" in 2652 rhapsody* | darwin1.[[012]]) 2653 _LT_AC_TAGVAR(allow_undefined_flag, $1)='-undefined suppress' 2654 ;; 2655 *) # Darwin 1.3 on 2656 test -z ${LD_TWOLEVEL_NAMESPACE} && _LT_AC_TAGVAR(allow_undefined_flag, $1)='-flat_namespace -undefined suppress' 2657 ;; 2658 esac 2659 # FIXME: Relying on posixy $() will cause problems for 2660 # cross-compilation, but unfortunately the echo tests do not 2661 # yet detect zsh echo's removal of \ escapes. Also zsh mangles 2662 # `"' quotes if we put them in here... so don't! 2663 output_verbose_link_cmd='echo' 2664 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs$compiler_flags -install_name $rpath/$soname $verstring' 2665 _LT_AC_TAGVAR(module_cmds, $1)='$CC -bundle $allow_undefined_flag -o $lib $libobjs $deplibs$compiler_flags' 2666 # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin ld's 2667 _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}' 2668 _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -bundle $allow_undefined_flag -o $lib $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' 2669 _LT_AC_TAGVAR(hardcode_direct, $1)=no 2670 _LT_AC_TAGVAR(hardcode_automatic, $1)=yes 2671 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported 2672 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-all_load $convenience' 2673 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes 2674 fi 2675 ;; 2676esac 2677AC_MSG_RESULT([$enable_shared]) 2678 2679AC_MSG_CHECKING([whether to build static libraries]) 2680# Make sure either enable_shared or enable_static is yes. 2681test "$enable_shared" = yes || enable_static=yes 2682AC_MSG_RESULT([$enable_static]) 2683 2684AC_LIBTOOL_CONFIG($1) 2685 2686AC_LANG_POP 2687CC="$lt_save_CC" 2688])# AC_LIBTOOL_LANG_C_CONFIG 2689 2690 2691# AC_LIBTOOL_LANG_CXX_CONFIG 2692# -------------------------- 2693# Ensure that the configuration vars for the C compiler are 2694# suitably defined. Those variables are subsequently used by 2695# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'. 2696AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG], [_LT_AC_LANG_CXX_CONFIG(CXX)]) 2697AC_DEFUN([_LT_AC_LANG_CXX_CONFIG], 2698[AC_LANG_PUSH(C++) 2699AC_REQUIRE([AC_PROG_CXX]) 2700AC_REQUIRE([AC_PROG_CXXCPP]) 2701 2702_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no 2703_LT_AC_TAGVAR(allow_undefined_flag, $1)= 2704_LT_AC_TAGVAR(always_export_symbols, $1)=no 2705_LT_AC_TAGVAR(archive_expsym_cmds, $1)= 2706_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)= 2707_LT_AC_TAGVAR(hardcode_direct, $1)=no 2708_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)= 2709_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= 2710_LT_AC_TAGVAR(hardcode_libdir_separator, $1)= 2711_LT_AC_TAGVAR(hardcode_minus_L, $1)=no 2712_LT_AC_TAGVAR(hardcode_automatic, $1)=no 2713_LT_AC_TAGVAR(module_cmds, $1)= 2714_LT_AC_TAGVAR(module_expsym_cmds, $1)= 2715_LT_AC_TAGVAR(link_all_deplibs, $1)=unknown 2716_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 2717_LT_AC_TAGVAR(no_undefined_flag, $1)= 2718_LT_AC_TAGVAR(whole_archive_flag_spec, $1)= 2719_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no 2720 2721# Dependencies to place before and after the object being linked: 2722_LT_AC_TAGVAR(predep_objects, $1)= 2723_LT_AC_TAGVAR(postdep_objects, $1)= 2724_LT_AC_TAGVAR(predeps, $1)= 2725_LT_AC_TAGVAR(postdeps, $1)= 2726_LT_AC_TAGVAR(compiler_lib_search_path, $1)= 2727 2728# Source file extension for C++ test sources. 2729ac_ext=cc 2730 2731# Object file extension for compiled C++ test sources. 2732objext=o 2733_LT_AC_TAGVAR(objext, $1)=$objext 2734 2735# Code to be used in simple compile tests 2736lt_simple_compile_test_code="int some_variable = 0;\n" 2737 2738# Code to be used in simple link tests 2739lt_simple_link_test_code='int main(int, char *[]) { return(0); }\n' 2740 2741# ltmain only uses $CC for tagged configurations so make sure $CC is set. 2742_LT_AC_SYS_COMPILER 2743 2744# Allow CC to be a program name with arguments. 2745lt_save_CC=$CC 2746lt_save_LD=$LD 2747lt_save_GCC=$GCC 2748GCC=$GXX 2749lt_save_with_gnu_ld=$with_gnu_ld 2750lt_save_path_LD=$lt_cv_path_LD 2751if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then 2752 lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx 2753else 2754 unset lt_cv_prog_gnu_ld 2755fi 2756if test -n "${lt_cv_path_LDCXX+set}"; then 2757 lt_cv_path_LD=$lt_cv_path_LDCXX 2758else 2759 unset lt_cv_path_LD 2760fi 2761test -z "${LDCXX+set}" || LD=$LDCXX 2762CC=${CXX-"c++"} 2763compiler=$CC 2764_LT_AC_TAGVAR(compiler, $1)=$CC 2765cc_basename=`$echo X"$compiler" | $Xsed -e 's%^.*/%%'` 2766 2767# We don't want -fno-exception wen compiling C++ code, so set the 2768# no_builtin_flag separately 2769if test "$GXX" = yes; then 2770 _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' 2771else 2772 _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= 2773fi 2774 2775if test "$GXX" = yes; then 2776 # Set up default GNU C++ configuration 2777 2778 AC_PROG_LD 2779 2780 # Check if GNU C++ uses GNU ld as the underlying linker, since the 2781 # archiving commands below assume that GNU ld is being used. 2782 if test "$with_gnu_ld" = yes; then 2783 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' 2784 _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' 2785 2786 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir' 2787 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 2788 2789 # If archive_cmds runs LD, not CC, wlarc should be empty 2790 # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to 2791 # investigate it a little bit more. (MM) 2792 wlarc='${wl}' 2793 2794 # ancient GNU ld didn't support --whole-archive et. al. 2795 if eval "`$CC -print-prog-name=ld` --help 2>&1" | \ 2796 grep 'no-whole-archive' > /dev/null; then 2797 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' 2798 else 2799 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)= 2800 fi 2801 else 2802 with_gnu_ld=no 2803 wlarc= 2804 2805 # A generic and very simple default shared library creation 2806 # command for GNU C++ for the case where it uses the native 2807 # linker, instead of GNU ld. If possible, this setting should 2808 # overridden to take advantage of the native linker features on 2809 # the platform it is being used on. 2810 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' 2811 fi 2812 2813 # Commands to make compiler produce verbose output that lists 2814 # what "hidden" libraries, object files and flags are used when 2815 # linking a shared library. 2816 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"' 2817 2818else 2819 GXX=no 2820 with_gnu_ld=no 2821 wlarc= 2822fi 2823 2824# PORTME: fill in a description of your system's C++ link characteristics 2825AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) 2826_LT_AC_TAGVAR(ld_shlibs, $1)=yes 2827case $host_os in 2828 aix3*) 2829 # FIXME: insert proper C++ library support 2830 _LT_AC_TAGVAR(ld_shlibs, $1)=no 2831 ;; 2832 aix4* | aix5*) 2833 if test "$host_cpu" = ia64; then 2834 # On IA64, the linker does run time linking by default, so we don't 2835 # have to do anything special. 2836 aix_use_runtimelinking=no 2837 exp_sym_flag='-Bexport' 2838 no_entry_flag="" 2839 else 2840 aix_use_runtimelinking=no 2841 2842 # Test if we are trying to use run time linking or normal 2843 # AIX style linking. If -brtl is somewhere in LDFLAGS, we 2844 # need to do runtime linking. 2845 case $host_os in aix4.[[23]]|aix4.[[23]].*|aix5*) 2846 for ld_flag in $LDFLAGS; do 2847 case $ld_flag in 2848 *-brtl*) 2849 aix_use_runtimelinking=yes 2850 break 2851 ;; 2852 esac 2853 done 2854 esac 2855 2856 exp_sym_flag='-bexport' 2857 no_entry_flag='-bnoentry' 2858 fi 2859 2860 # When large executables or shared objects are built, AIX ld can 2861 # have problems creating the table of contents. If linking a library 2862 # or program results in "error TOC overflow" add -mminimal-toc to 2863 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not 2864 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. 2865 2866 _LT_AC_TAGVAR(archive_cmds, $1)='' 2867 _LT_AC_TAGVAR(hardcode_direct, $1)=yes 2868 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':' 2869 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes 2870 2871 if test "$GXX" = yes; then 2872 case $host_os in aix4.[012]|aix4.[012].*) 2873 # We only want to do this on AIX 4.2 and lower, the check 2874 # below for broken collect2 doesn't work under 4.3+ 2875 collect2name=`${CC} -print-prog-name=collect2` 2876 if test -f "$collect2name" && \ 2877 strings "$collect2name" | grep resolve_lib_name >/dev/null 2878 then 2879 # We have reworked collect2 2880 _LT_AC_TAGVAR(hardcode_direct, $1)=yes 2881 else 2882 # We have old collect2 2883 _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported 2884 # It fails to find uninstalled libraries when the uninstalled 2885 # path is not listed in the libpath. Setting hardcode_minus_L 2886 # to unsupported forces relinking 2887 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes 2888 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 2889 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)= 2890 fi 2891 esac 2892 shared_flag='-shared' 2893 else 2894 # not using gcc 2895 if test "$host_cpu" = ia64; then 2896 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release 2897 # chokes on -Wl,-G. The following line is correct: 2898 shared_flag='-G' 2899 else 2900 if test "$aix_use_runtimelinking" = yes; then 2901 shared_flag='${wl}-G' 2902 else 2903 shared_flag='${wl}-bM:SRE' 2904 fi 2905 fi 2906 fi 2907 2908 # It seems that -bexpall does not export symbols beginning with 2909 # underscore (_), so it is better to generate a list of symbols to export. 2910 _LT_AC_TAGVAR(always_export_symbols, $1)=yes 2911 if test "$aix_use_runtimelinking" = yes; then 2912 # Warning - without using the other runtime loading flags (-brtl), 2913 # -berok will link without error, but may produce a broken library. 2914 _LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok' 2915 # Determine the default libpath from the value encoded in an empty executable. 2916 _LT_AC_SYS_LIBPATH_AIX 2917 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" 2918 2919 _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols $shared_flag" 2920 else 2921 if test "$host_cpu" = ia64; then 2922 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' 2923 _LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs" 2924 _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols" 2925 else 2926 # Determine the default libpath from the value encoded in an empty executable. 2927 _LT_AC_SYS_LIBPATH_AIX 2928 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" 2929 # Warning - without using the other run time loading flags, 2930 # -berok will link without error, but may produce a broken library. 2931 _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' 2932 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' 2933 # -bexpall does not export symbols beginning with underscore (_) 2934 _LT_AC_TAGVAR(always_export_symbols, $1)=yes 2935 # Exported symbols can be pulled into shared objects from archives 2936 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=' ' 2937 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes 2938 # This is similar to how AIX traditionally builds it's shared libraries. 2939 _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' 2940 fi 2941 fi 2942 ;; 2943 chorus*) 2944 case $cc_basename in 2945 *) 2946 # FIXME: insert proper C++ library support 2947 _LT_AC_TAGVAR(ld_shlibs, $1)=no 2948 ;; 2949 esac 2950 ;; 2951 2952 cygwin* | mingw* | pw32*) 2953 # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, 2954 # as there is no search path for DLLs. 2955 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 2956 _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported 2957 _LT_AC_TAGVAR(always_export_symbols, $1)=no 2958 _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 2959 2960 if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then 2961 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib' 2962 # If the export-symbols file already is a .def file (1st line 2963 # is EXPORTS), use it as is; otherwise, prepend... 2964 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then 2965 cp $export_symbols $output_objdir/$soname.def; 2966 else 2967 echo EXPORTS > $output_objdir/$soname.def; 2968 cat $export_symbols >> $output_objdir/$soname.def; 2969 fi~ 2970 $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib' 2971 else 2972 _LT_AC_TAGVAR(ld_shlibs, $1)=no 2973 fi 2974 ;; 2975 2976 darwin* | rhapsody*) 2977 if $CC -v 2>&1 | grep 'Apple' >/dev/null ; then 2978 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no 2979 case "$host_os" in 2980 rhapsody* | darwin1.[[012]]) 2981 _LT_AC_TAGVAR(allow_undefined_flag, $1)='-undefined suppress' 2982 ;; 2983 *) # Darwin 1.3 on 2984 test -z ${LD_TWOLEVEL_NAMESPACE} && _LT_AC_TAGVAR(allow_undefined_flag, $1)='-flat_namespace -undefined suppress' 2985 ;; 2986 esac 2987 lt_int_apple_cc_single_mod=no 2988 output_verbose_link_cmd='echo' 2989 if $CC -dumpspecs 2>&1 | grep 'single_module' >/dev/null ; then 2990 lt_int_apple_cc_single_mod=yes 2991 fi 2992 if test "X$lt_int_apple_cc_single_mod" = Xyes ; then 2993 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring' 2994 else 2995 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -r ${wl}-bind_at_load -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' 2996 fi 2997 _LT_AC_TAGVAR(module_cmds, $1)='$CC -bundle ${wl}-bind_at_load $allow_undefined_flag -o $lib $libobjs $deplibs$compiler_flags' 2998 2999 # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin ld's 3000 if test "X$lt_int_apple_cc_single_mod" = Xyes ; then 3001 _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}' 3002 else 3003 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -r ${wl}-bind_at_load -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}' 3004 fi 3005 _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -bundle $allow_undefined_flag -o $lib $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' 3006 _LT_AC_TAGVAR(hardcode_direct, $1)=no 3007 _LT_AC_TAGVAR(hardcode_automatic, $1)=yes 3008 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported 3009 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-all_load $convenience' 3010 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes 3011 fi 3012 ;; 3013 3014 dgux*) 3015 case $cc_basename in 3016 ec++) 3017 # FIXME: insert proper C++ library support 3018 _LT_AC_TAGVAR(ld_shlibs, $1)=no 3019 ;; 3020 ghcx) 3021 # Green Hills C++ Compiler 3022 # FIXME: insert proper C++ library support 3023 _LT_AC_TAGVAR(ld_shlibs, $1)=no 3024 ;; 3025 *) 3026 # FIXME: insert proper C++ library support 3027 _LT_AC_TAGVAR(ld_shlibs, $1)=no 3028 ;; 3029 esac 3030 ;; 3031 freebsd[12]*) 3032 # C++ shared libraries reported to be fairly broken before switch to ELF 3033 _LT_AC_TAGVAR(ld_shlibs, $1)=no 3034 ;; 3035 freebsd-elf*) 3036 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no 3037 ;; 3038 freebsd*) 3039 # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF 3040 # conventions 3041 _LT_AC_TAGVAR(ld_shlibs, $1)=yes 3042 ;; 3043 gnu*) 3044 ;; 3045 hpux9*) 3046 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 3047 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 3048 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 3049 _LT_AC_TAGVAR(hardcode_direct, $1)=yes 3050 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, 3051 # but as the default 3052 # location of the library. 3053 3054 case $cc_basename in 3055 CC) 3056 # FIXME: insert proper C++ library support 3057 _LT_AC_TAGVAR(ld_shlibs, $1)=no 3058 ;; 3059 aCC) 3060 _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' 3061 # Commands to make compiler produce verbose output that lists 3062 # what "hidden" libraries, object files and flags are used when 3063 # linking a shared library. 3064 # 3065 # There doesn't appear to be a way to prevent this compiler from 3066 # explicitly linking system object files so we need to strip them 3067 # from the output so that they don't get included in the library 3068 # dependencies. 3069 output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | egrep "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' 3070 ;; 3071 *) 3072 if test "$GXX" = yes; then 3073 _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' 3074 else 3075 # FIXME: insert proper C++ library support 3076 _LT_AC_TAGVAR(ld_shlibs, $1)=no 3077 fi 3078 ;; 3079 esac 3080 ;; 3081 hpux10*|hpux11*) 3082 if test $with_gnu_ld = no; then 3083 case "$host_cpu" in 3084 hppa*64*) 3085 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 3086 _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir' 3087 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 3088 ;; 3089 ia64*) 3090 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 3091 ;; 3092 *) 3093 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 3094 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 3095 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 3096 ;; 3097 esac 3098 fi 3099 case "$host_cpu" in 3100 hppa*64*) 3101 _LT_AC_TAGVAR(hardcode_direct, $1)=no 3102 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 3103 ;; 3104 ia64*) 3105 _LT_AC_TAGVAR(hardcode_direct, $1)=no 3106 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 3107 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, 3108 # but as the default 3109 # location of the library. 3110 ;; 3111 *) 3112 _LT_AC_TAGVAR(hardcode_direct, $1)=yes 3113 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, 3114 # but as the default 3115 # location of the library. 3116 ;; 3117 esac 3118 3119 case $cc_basename in 3120 CC) 3121 # FIXME: insert proper C++ library support 3122 _LT_AC_TAGVAR(ld_shlibs, $1)=no 3123 ;; 3124 aCC) 3125 case "$host_cpu" in 3126 hppa*64*|ia64*) 3127 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname -o $lib $linker_flags $libobjs $deplibs' 3128 ;; 3129 *) 3130 _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' 3131 ;; 3132 esac 3133 # Commands to make compiler produce verbose output that lists 3134 # what "hidden" libraries, object files and flags are used when 3135 # linking a shared library. 3136 # 3137 # There doesn't appear to be a way to prevent this compiler from 3138 # explicitly linking system object files so we need to strip them 3139 # from the output so that they don't get included in the library 3140 # dependencies. 3141 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' 3142 ;; 3143 *) 3144 if test "$GXX" = yes; then 3145 if test $with_gnu_ld = no; then 3146 case "$host_cpu" in 3147 ia64*|hppa*64*) 3148 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname -o $lib $linker_flags $libobjs $deplibs' 3149 ;; 3150 *) 3151 _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' 3152 ;; 3153 esac 3154 fi 3155 else 3156 # FIXME: insert proper C++ library support 3157 _LT_AC_TAGVAR(ld_shlibs, $1)=no 3158 fi 3159 ;; 3160 esac 3161 ;; 3162 irix5* | irix6*) 3163 case $cc_basename in 3164 CC) 3165 # SGI C++ 3166 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${objdir}/so_locations -o $lib' 3167 3168 # Archives containing C++ object files must be created using 3169 # "CC -ar", where "CC" is the IRIX C++ compiler. This is 3170 # necessary to make sure instantiated templates are included 3171 # in the archive. 3172 _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs' 3173 ;; 3174 *) 3175 if test "$GXX" = yes; then 3176 if test "$with_gnu_ld" = no; then 3177 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${objdir}/so_locations -o $lib' 3178 else 3179 _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' 3180 fi 3181 fi 3182 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes 3183 ;; 3184 esac 3185 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 3186 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 3187 ;; 3188 linux*) 3189 case $cc_basename in 3190 KCC) 3191 # Kuck and Associates, Inc. (KAI) C++ Compiler 3192 3193 # KCC will only create a shared library if the output file 3194 # ends with ".so" (or ".sl" for HP-UX), so rename the library 3195 # to its proper name (with version) after linking. 3196 _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' 3197 _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' 3198 # Commands to make compiler produce verbose output that lists 3199 # what "hidden" libraries, object files and flags are used when 3200 # linking a shared library. 3201 # 3202 # There doesn't appear to be a way to prevent this compiler from 3203 # explicitly linking system object files so we need to strip them 3204 # from the output so that they don't get included in the library 3205 # dependencies. 3206 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' 3207 3208 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath,$libdir' 3209 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 3210 3211 # Archives containing C++ object files must be created using 3212 # "CC -Bstatic", where "CC" is the KAI C++ compiler. 3213 _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' 3214 ;; 3215 icpc) 3216 # Intel C++ 3217 with_gnu_ld=yes 3218 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no 3219 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' 3220 _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' 3221 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 3222 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 3223 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' 3224 ;; 3225 cxx) 3226 # Compaq C++ 3227 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' 3228 _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' 3229 3230 runpath_var=LD_RUN_PATH 3231 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' 3232 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 3233 3234 # Commands to make compiler produce verbose output that lists 3235 # what "hidden" libraries, object files and flags are used when 3236 # linking a shared library. 3237 # 3238 # There doesn't appear to be a way to prevent this compiler from 3239 # explicitly linking system object files so we need to strip them 3240 # from the output so that they don't get included in the library 3241 # dependencies. 3242 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' 3243 ;; 3244 esac 3245 ;; 3246 lynxos*) 3247 # FIXME: insert proper C++ library support 3248 _LT_AC_TAGVAR(ld_shlibs, $1)=no 3249 ;; 3250 m88k*) 3251 # FIXME: insert proper C++ library support 3252 _LT_AC_TAGVAR(ld_shlibs, $1)=no 3253 ;; 3254 mvs*) 3255 case $cc_basename in 3256 cxx) 3257 # FIXME: insert proper C++ library support 3258 _LT_AC_TAGVAR(ld_shlibs, $1)=no 3259 ;; 3260 *) 3261 # FIXME: insert proper C++ library support 3262 _LT_AC_TAGVAR(ld_shlibs, $1)=no 3263 ;; 3264 esac 3265 ;; 3266 netbsd*) 3267 if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then 3268 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' 3269 wlarc= 3270 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 3271 _LT_AC_TAGVAR(hardcode_direct, $1)=yes 3272 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 3273 fi 3274 # Workaround some broken pre-1.5 toolchains 3275 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' 3276 ;; 3277 osf3*) 3278 case $cc_basename in 3279 KCC) 3280 # Kuck and Associates, Inc. (KAI) C++ Compiler 3281 3282 # KCC will only create a shared library if the output file 3283 # ends with ".so" (or ".sl" for HP-UX), so rename the library 3284 # to its proper name (with version) after linking. 3285 _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' 3286 3287 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 3288 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 3289 3290 # Archives containing C++ object files must be created using 3291 # "CC -Bstatic", where "CC" is the KAI C++ compiler. 3292 _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' 3293 3294 ;; 3295 RCC) 3296 # Rational C++ 2.4.1 3297 # FIXME: insert proper C++ library support 3298 _LT_AC_TAGVAR(ld_shlibs, $1)=no 3299 ;; 3300 cxx) 3301 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' 3302 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && echo ${wl}-set_version $verstring` -update_registry ${objdir}/so_locations -o $lib' 3303 3304 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 3305 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 3306 3307 # Commands to make compiler produce verbose output that lists 3308 # what "hidden" libraries, object files and flags are used when 3309 # linking a shared library. 3310 # 3311 # There doesn't appear to be a way to prevent this compiler from 3312 # explicitly linking system object files so we need to strip them 3313 # from the output so that they don't get included in the library 3314 # dependencies. 3315 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' 3316 ;; 3317 *) 3318 if test "$GXX" = yes && test "$with_gnu_ld" = no; then 3319 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' 3320 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${objdir}/so_locations -o $lib' 3321 3322 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 3323 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 3324 3325 # Commands to make compiler produce verbose output that lists 3326 # what "hidden" libraries, object files and flags are used when 3327 # linking a shared library. 3328 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"' 3329 3330 else 3331 # FIXME: insert proper C++ library support 3332 _LT_AC_TAGVAR(ld_shlibs, $1)=no 3333 fi 3334 ;; 3335 esac 3336 ;; 3337 osf4* | osf5*) 3338 case $cc_basename in 3339 KCC) 3340 # Kuck and Associates, Inc. (KAI) C++ Compiler 3341 3342 # KCC will only create a shared library if the output file 3343 # ends with ".so" (or ".sl" for HP-UX), so rename the library 3344 # to its proper name (with version) after linking. 3345 _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' 3346 3347 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 3348 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 3349 3350 # Archives containing C++ object files must be created using 3351 # the KAI C++ compiler. 3352 _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' 3353 ;; 3354 RCC) 3355 # Rational C++ 2.4.1 3356 # FIXME: insert proper C++ library support 3357 _LT_AC_TAGVAR(ld_shlibs, $1)=no 3358 ;; 3359 cxx) 3360 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' 3361 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${objdir}/so_locations -o $lib' 3362 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ 3363 echo "-hidden">> $lib.exp~ 3364 $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname -Wl,-input -Wl,$lib.exp `test -n "$verstring" && echo -set_version $verstring` -update_registry $objdir/so_locations -o $lib~ 3365 $rm $lib.exp' 3366 3367 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' 3368 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 3369 3370 # Commands to make compiler produce verbose output that lists 3371 # what "hidden" libraries, object files and flags are used when 3372 # linking a shared library. 3373 # 3374 # There doesn't appear to be a way to prevent this compiler from 3375 # explicitly linking system object files so we need to strip them 3376 # from the output so that they don't get included in the library 3377 # dependencies. 3378 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' 3379 ;; 3380 *) 3381 if test "$GXX" = yes && test "$with_gnu_ld" = no; then 3382 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' 3383 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${objdir}/so_locations -o $lib' 3384 3385 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 3386 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 3387 3388 # Commands to make compiler produce verbose output that lists 3389 # what "hidden" libraries, object files and flags are used when 3390 # linking a shared library. 3391 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"' 3392 3393 else 3394 # FIXME: insert proper C++ library support 3395 _LT_AC_TAGVAR(ld_shlibs, $1)=no 3396 fi 3397 ;; 3398 esac 3399 ;; 3400 psos*) 3401 # FIXME: insert proper C++ library support 3402 _LT_AC_TAGVAR(ld_shlibs, $1)=no 3403 ;; 3404 sco*) 3405 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no 3406 case $cc_basename in 3407 CC) 3408 # FIXME: insert proper C++ library support 3409 _LT_AC_TAGVAR(ld_shlibs, $1)=no 3410 ;; 3411 *) 3412 # FIXME: insert proper C++ library support 3413 _LT_AC_TAGVAR(ld_shlibs, $1)=no 3414 ;; 3415 esac 3416 ;; 3417 sunos4*) 3418 case $cc_basename in 3419 CC) 3420 # Sun C++ 4.x 3421 # FIXME: insert proper C++ library support 3422 _LT_AC_TAGVAR(ld_shlibs, $1)=no 3423 ;; 3424 lcc) 3425 # Lucid 3426 # FIXME: insert proper C++ library support 3427 _LT_AC_TAGVAR(ld_shlibs, $1)=no 3428 ;; 3429 *) 3430 # FIXME: insert proper C++ library support 3431 _LT_AC_TAGVAR(ld_shlibs, $1)=no 3432 ;; 3433 esac 3434 ;; 3435 solaris*) 3436 case $cc_basename in 3437 CC) 3438 # Sun C++ 4.2, 5.x and Centerline C++ 3439 _LT_AC_TAGVAR(no_undefined_flag, $1)=' -zdefs' 3440 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -nolib -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 3441 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ 3442 $CC -G${allow_undefined_flag} -nolib ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp' 3443 3444 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 3445 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 3446 case $host_os in 3447 solaris2.[0-5] | solaris2.[0-5].*) ;; 3448 *) 3449 # The C++ compiler is used as linker so we must use $wl 3450 # flag to pass the commands to the underlying system 3451 # linker. 3452 # Supported since Solaris 2.6 (maybe 2.5.1?) 3453 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' 3454 ;; 3455 esac 3456 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes 3457 3458 # Commands to make compiler produce verbose output that lists 3459 # what "hidden" libraries, object files and flags are used when 3460 # linking a shared library. 3461 # 3462 # There doesn't appear to be a way to prevent this compiler from 3463 # explicitly linking system object files so we need to strip them 3464 # from the output so that they don't get included in the library 3465 # dependencies. 3466 output_verbose_link_cmd='templist=`$CC -G $CFLAGS -v conftest.$objext 2>&1 | grep "\-[[LR]]"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' 3467 3468 # Archives containing C++ object files must be created using 3469 # "CC -xar", where "CC" is the Sun C++ compiler. This is 3470 # necessary to make sure instantiated templates are included 3471 # in the archive. 3472 _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' 3473 ;; 3474 gcx) 3475 # Green Hills C++ Compiler 3476 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' 3477 3478 # The C++ compiler must be used to create the archive. 3479 _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs' 3480 ;; 3481 *) 3482 # GNU C++ compiler with Solaris linker 3483 if test "$GXX" = yes && test "$with_gnu_ld" = no; then 3484 _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs' 3485 if $CC --version | grep -v '^2\.7' > /dev/null; then 3486 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' 3487 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ 3488 $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp' 3489 3490 # Commands to make compiler produce verbose output that lists 3491 # what "hidden" libraries, object files and flags are used when 3492 # linking a shared library. 3493 output_verbose_link_cmd="$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\"" 3494 else 3495 # g++ 2.7 appears to require `-G' NOT `-shared' on this 3496 # platform. 3497 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' 3498 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ 3499 $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp' 3500 3501 # Commands to make compiler produce verbose output that lists 3502 # what "hidden" libraries, object files and flags are used when 3503 # linking a shared library. 3504 output_verbose_link_cmd="$CC -G $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\"" 3505 fi 3506 3507 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir' 3508 fi 3509 ;; 3510 esac 3511 ;; 3512 sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[[78]]* | unixware7*) 3513 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no 3514 ;; 3515 tandem*) 3516 case $cc_basename in 3517 NCC) 3518 # NonStop-UX NCC 3.20 3519 # FIXME: insert proper C++ library support 3520 _LT_AC_TAGVAR(ld_shlibs, $1)=no 3521 ;; 3522 *) 3523 # FIXME: insert proper C++ library support 3524 _LT_AC_TAGVAR(ld_shlibs, $1)=no 3525 ;; 3526 esac 3527 ;; 3528 vxworks*) 3529 # FIXME: insert proper C++ library support 3530 _LT_AC_TAGVAR(ld_shlibs, $1)=no 3531 ;; 3532 *) 3533 # FIXME: insert proper C++ library support 3534 _LT_AC_TAGVAR(ld_shlibs, $1)=no 3535 ;; 3536esac 3537AC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)]) 3538test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no 3539 3540_LT_AC_TAGVAR(GCC, $1)="$GXX" 3541_LT_AC_TAGVAR(LD, $1)="$LD" 3542 3543AC_LIBTOOL_POSTDEP_PREDEP($1) 3544AC_LIBTOOL_PROG_COMPILER_PIC($1) 3545AC_LIBTOOL_PROG_CC_C_O($1) 3546AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1) 3547AC_LIBTOOL_PROG_LD_SHLIBS($1) 3548AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1) 3549AC_LIBTOOL_SYS_LIB_STRIP 3550AC_LIBTOOL_SYS_DYNAMIC_LINKER($1) 3551AC_LIBTOOL_DLOPEN_SELF($1) 3552 3553AC_LIBTOOL_CONFIG($1) 3554 3555AC_LANG_POP 3556CC=$lt_save_CC 3557LDCXX=$LD 3558LD=$lt_save_LD 3559GCC=$lt_save_GCC 3560with_gnu_ldcxx=$with_gnu_ld 3561with_gnu_ld=$lt_save_with_gnu_ld 3562lt_cv_path_LDCXX=$lt_cv_path_LD 3563lt_cv_path_LD=$lt_save_path_LD 3564lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld 3565lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld 3566])# AC_LIBTOOL_LANG_CXX_CONFIG 3567 3568# AC_LIBTOOL_POSTDEP_PREDEP([TAGNAME]) 3569# ------------------------ 3570# Figure out "hidden" library dependencies from verbose 3571# compiler output when linking a shared library. 3572# Parse the compiler output and extract the necessary 3573# objects, libraries and library flags. 3574AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP],[ 3575dnl we can't use the lt_simple_compile_test_code here, 3576dnl because it contains code intended for an executable, 3577dnl not a library. It's possible we should let each 3578dnl tag define a new lt_????_link_test_code variable, 3579dnl but it's only used here... 3580ifelse([$1],[],[cat > conftest.$ac_ext <<EOF 3581int a; 3582void foo (void) { a = 0; } 3583EOF 3584],[$1],[CXX],[cat > conftest.$ac_ext <<EOF 3585class Foo 3586{ 3587public: 3588 Foo (void) { a = 0; } 3589private: 3590 int a; 3591}; 3592EOF 3593],[$1],[F77],[cat > conftest.$ac_ext <<EOF 3594 subroutine foo 3595 implicit none 3596 integer*4 a 3597 a=0 3598 return 3599 end 3600EOF 3601],[$1],[GCJ],[cat > conftest.$ac_ext <<EOF 3602public class foo { 3603 private int a; 3604 public void bar (void) { 3605 a = 0; 3606 } 3607}; 3608EOF 3609]) 3610dnl Parse the compiler output and extract the necessary 3611dnl objects, libraries and library flags. 3612if AC_TRY_EVAL(ac_compile); then 3613 # Parse the compiler output and extract the necessary 3614 # objects, libraries and library flags. 3615 3616 # Sentinel used to keep track of whether or not we are before 3617 # the conftest object file. 3618 pre_test_object_deps_done=no 3619 3620 # The `*' in the case matches for architectures that use `case' in 3621 # $output_verbose_cmd can trigger glob expansion during the loop 3622 # eval without this substitution. 3623 output_verbose_link_cmd="`$echo \"X$output_verbose_link_cmd\" | $Xsed -e \"$no_glob_subst\"`" 3624 3625 for p in `eval $output_verbose_link_cmd`; do 3626 case $p in 3627 3628 -L* | -R* | -l*) 3629 # Some compilers place space between "-{L,R}" and the path. 3630 # Remove the space. 3631 if test $p = "-L" \ 3632 || test $p = "-R"; then 3633 prev=$p 3634 continue 3635 else 3636 prev= 3637 fi 3638 3639 if test "$pre_test_object_deps_done" = no; then 3640 case $p in 3641 -L* | -R*) 3642 # Internal compiler library paths should come after those 3643 # provided the user. The postdeps already come after the 3644 # user supplied libs so there is no need to process them. 3645 if test -z "$_LT_AC_TAGVAR(compiler_lib_search_path, $1)"; then 3646 _LT_AC_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}" 3647 else 3648 _LT_AC_TAGVAR(compiler_lib_search_path, $1)="${_LT_AC_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}" 3649 fi 3650 ;; 3651 # The "-l" case would never come before the object being 3652 # linked, so don't bother handling this case. 3653 esac 3654 else 3655 if test -z "$_LT_AC_TAGVAR(postdeps, $1)"; then 3656 _LT_AC_TAGVAR(postdeps, $1)="${prev}${p}" 3657 else 3658 _LT_AC_TAGVAR(postdeps, $1)="${_LT_AC_TAGVAR(postdeps, $1)} ${prev}${p}" 3659 fi 3660 fi 3661 ;; 3662 3663 *.$objext) 3664 # This assumes that the test object file only shows up 3665 # once in the compiler output. 3666 if test "$p" = "conftest.$objext"; then 3667 pre_test_object_deps_done=yes 3668 continue 3669 fi 3670 3671 if test "$pre_test_object_deps_done" = no; then 3672 if test -z "$_LT_AC_TAGVAR(predep_objects, $1)"; then 3673 _LT_AC_TAGVAR(predep_objects, $1)="$p" 3674 else 3675 _LT_AC_TAGVAR(predep_objects, $1)="$_LT_AC_TAGVAR(predep_objects, $1) $p" 3676 fi 3677 else 3678 if test -z "$_LT_AC_TAGVAR(postdep_objects, $1)"; then 3679 _LT_AC_TAGVAR(postdep_objects, $1)="$p" 3680 else 3681 _LT_AC_TAGVAR(postdep_objects, $1)="$_LT_AC_TAGVAR(postdep_objects, $1) $p" 3682 fi 3683 fi 3684 ;; 3685 3686 *) ;; # Ignore the rest. 3687 3688 esac 3689 done 3690 3691 # Clean up. 3692 rm -f a.out a.exe 3693else 3694 echo "libtool.m4: error: problem compiling $1 test program" 3695fi 3696 3697$rm -f confest.$objext 3698 3699case " $_LT_AC_TAGVAR(postdeps, $1) " in 3700*" -lc "*) _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no ;; 3701esac 3702])# AC_LIBTOOL_POSTDEP_PREDEP 3703 3704# AC_LIBTOOL_LANG_F77_CONFIG 3705# ------------------------ 3706# Ensure that the configuration vars for the C compiler are 3707# suitably defined. Those variables are subsequently used by 3708# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'. 3709AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG], [_LT_AC_LANG_F77_CONFIG(F77)]) 3710AC_DEFUN([_LT_AC_LANG_F77_CONFIG], 3711[AC_REQUIRE([AC_PROG_F77]) 3712AC_LANG_PUSH(Fortran 77) 3713 3714_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no 3715_LT_AC_TAGVAR(allow_undefined_flag, $1)= 3716_LT_AC_TAGVAR(always_export_symbols, $1)=no 3717_LT_AC_TAGVAR(archive_expsym_cmds, $1)= 3718_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)= 3719_LT_AC_TAGVAR(hardcode_direct, $1)=no 3720_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)= 3721_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= 3722_LT_AC_TAGVAR(hardcode_libdir_separator, $1)= 3723_LT_AC_TAGVAR(hardcode_minus_L, $1)=no 3724_LT_AC_TAGVAR(hardcode_automatic, $1)=no 3725_LT_AC_TAGVAR(module_cmds, $1)= 3726_LT_AC_TAGVAR(module_expsym_cmds, $1)= 3727_LT_AC_TAGVAR(link_all_deplibs, $1)=unknown 3728_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 3729_LT_AC_TAGVAR(no_undefined_flag, $1)= 3730_LT_AC_TAGVAR(whole_archive_flag_spec, $1)= 3731_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no 3732 3733# Source file extension for f77 test sources. 3734ac_ext=f 3735 3736# Object file extension for compiled f77 test sources. 3737objext=o 3738_LT_AC_TAGVAR(objext, $1)=$objext 3739 3740# Code to be used in simple compile tests 3741lt_simple_compile_test_code=" subroutine t\n return\n end\n" 3742 3743# Code to be used in simple link tests 3744lt_simple_link_test_code=" program t\n end\n" 3745 3746# ltmain only uses $CC for tagged configurations so make sure $CC is set. 3747_LT_AC_SYS_COMPILER 3748 3749# Allow CC to be a program name with arguments. 3750lt_save_CC="$CC" 3751CC=${F77-"f77"} 3752compiler=$CC 3753_LT_AC_TAGVAR(compiler, $1)=$CC 3754cc_basename=`$echo X"$compiler" | $Xsed -e 's%^.*/%%'` 3755 3756AC_MSG_CHECKING([if libtool supports shared libraries]) 3757AC_MSG_RESULT([$can_build_shared]) 3758 3759AC_MSG_CHECKING([whether to build shared libraries]) 3760test "$can_build_shared" = "no" && enable_shared=no 3761 3762# On AIX, shared libraries and static libraries use the same namespace, and 3763# are all built from PIC. 3764case "$host_os" in 3765aix3*) 3766 test "$enable_shared" = yes && enable_static=no 3767 if test -n "$RANLIB"; then 3768 archive_cmds="$archive_cmds~\$RANLIB \$lib" 3769 postinstall_cmds='$RANLIB $lib' 3770 fi 3771 ;; 3772aix4*) 3773 test "$enable_shared" = yes && enable_static=no 3774 ;; 3775esac 3776AC_MSG_RESULT([$enable_shared]) 3777 3778AC_MSG_CHECKING([whether to build static libraries]) 3779# Make sure either enable_shared or enable_static is yes. 3780test "$enable_shared" = yes || enable_static=yes 3781AC_MSG_RESULT([$enable_static]) 3782 3783test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no 3784 3785_LT_AC_TAGVAR(GCC, $1)="$G77" 3786_LT_AC_TAGVAR(LD, $1)="$LD" 3787 3788AC_LIBTOOL_PROG_COMPILER_PIC($1) 3789AC_LIBTOOL_PROG_CC_C_O($1) 3790AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1) 3791AC_LIBTOOL_PROG_LD_SHLIBS($1) 3792AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1) 3793AC_LIBTOOL_SYS_LIB_STRIP 3794AC_LIBTOOL_SYS_DYNAMIC_LINKER($1) 3795 3796AC_LIBTOOL_CONFIG($1) 3797 3798AC_LANG_POP 3799CC="$lt_save_CC" 3800])# AC_LIBTOOL_LANG_F77_CONFIG 3801 3802 3803# AC_LIBTOOL_LANG_GCJ_CONFIG 3804# -------------------------- 3805# Ensure that the configuration vars for the C compiler are 3806# suitably defined. Those variables are subsequently used by 3807# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'. 3808AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG], [_LT_AC_LANG_GCJ_CONFIG(GCJ)]) 3809AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG], 3810[AC_LANG_SAVE 3811 3812# Source file extension for Java test sources. 3813ac_ext=java 3814 3815# Object file extension for compiled Java test sources. 3816objext=o 3817_LT_AC_TAGVAR(objext, $1)=$objext 3818 3819# Code to be used in simple compile tests 3820lt_simple_compile_test_code="class foo {}\n" 3821 3822# Code to be used in simple link tests 3823lt_simple_link_test_code='public class conftest { public static void main(String[] argv) {}; }\n' 3824 3825# ltmain only uses $CC for tagged configurations so make sure $CC is set. 3826_LT_AC_SYS_COMPILER 3827 3828# Allow CC to be a program name with arguments. 3829lt_save_CC="$CC" 3830CC=${GCJ-"gcj"} 3831compiler=$CC 3832_LT_AC_TAGVAR(compiler, $1)=$CC 3833 3834# GCJ did not exist at the time GCC didn't implicitly link libc in. 3835_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no 3836 3837AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1) 3838AC_LIBTOOL_PROG_COMPILER_PIC($1) 3839AC_LIBTOOL_PROG_CC_C_O($1) 3840AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1) 3841AC_LIBTOOL_PROG_LD_SHLIBS($1) 3842AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1) 3843AC_LIBTOOL_SYS_LIB_STRIP 3844AC_LIBTOOL_SYS_DYNAMIC_LINKER($1) 3845AC_LIBTOOL_DLOPEN_SELF($1) 3846 3847AC_LIBTOOL_CONFIG($1) 3848 3849AC_LANG_RESTORE 3850CC="$lt_save_CC" 3851])# AC_LIBTOOL_LANG_GCJ_CONFIG 3852 3853 3854# AC_LIBTOOL_LANG_RC_CONFIG 3855# -------------------------- 3856# Ensure that the configuration vars for the Windows resource compiler are 3857# suitably defined. Those variables are subsequently used by 3858# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'. 3859AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG], [_LT_AC_LANG_RC_CONFIG(RC)]) 3860AC_DEFUN([_LT_AC_LANG_RC_CONFIG], 3861[AC_LANG_SAVE 3862 3863# Source file extension for RC test sources. 3864ac_ext=rc 3865 3866# Object file extension for compiled RC test sources. 3867objext=o 3868_LT_AC_TAGVAR(objext, $1)=$objext 3869 3870# Code to be used in simple compile tests 3871lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }\n' 3872 3873# Code to be used in simple link tests 3874lt_simple_link_test_code="$lt_simple_compile_test_code" 3875 3876# ltmain only uses $CC for tagged configurations so make sure $CC is set. 3877_LT_AC_SYS_COMPILER 3878 3879# Allow CC to be a program name with arguments. 3880lt_save_CC="$CC" 3881CC=${RC-"windres"} 3882compiler=$CC 3883_LT_AC_TAGVAR(compiler, $1)=$CC 3884_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes 3885 3886AC_LIBTOOL_CONFIG($1) 3887 3888AC_LANG_RESTORE 3889CC="$lt_save_CC" 3890])# AC_LIBTOOL_LANG_RC_CONFIG 3891 3892 3893# AC_LIBTOOL_CONFIG([TAGNAME]) 3894# ---------------------------- 3895# If TAGNAME is not passed, then create an initial libtool script 3896# with a default configuration from the untagged config vars. Otherwise 3897# add code to config.status for appending the configuration named by 3898# TAGNAME from the matching tagged config vars. 3899AC_DEFUN([AC_LIBTOOL_CONFIG], 3900[# The else clause should only fire when bootstrapping the 3901# libtool distribution, otherwise you forgot to ship ltmain.sh 3902# with your package, and you will get complaints that there are 3903# no rules to generate ltmain.sh. 3904if test -f "$ltmain"; then 3905 # See if we are running on zsh, and set the options which allow our commands through 3906 # without removal of \ escapes. 3907 if test -n "${ZSH_VERSION+set}" ; then 3908 setopt NO_GLOB_SUBST 3909 fi 3910 # Now quote all the things that may contain metacharacters while being 3911 # careful not to overquote the AC_SUBSTed values. We take copies of the 3912 # variables and quote the copies for generation of the libtool script. 3913 for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC NM SED SHELL \ 3914 libname_spec library_names_spec soname_spec extract_expsyms_cmds \ 3915 old_striplib striplib file_magic_cmd finish_cmds finish_eval \ 3916 deplibs_check_method reload_flag reload_cmds need_locks \ 3917 lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \ 3918 lt_cv_sys_global_symbol_to_c_name_address \ 3919 sys_lib_search_path_spec sys_lib_dlsearch_path_spec \ 3920 old_postinstall_cmds old_postuninstall_cmds \ 3921 _LT_AC_TAGVAR(compiler, $1) \ 3922 _LT_AC_TAGVAR(CC, $1) \ 3923 _LT_AC_TAGVAR(LD, $1) \ 3924 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1) \ 3925 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1) \ 3926 _LT_AC_TAGVAR(lt_prog_compiler_static, $1) \ 3927 _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) \ 3928 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1) \ 3929 _LT_AC_TAGVAR(thread_safe_flag_spec, $1) \ 3930 _LT_AC_TAGVAR(whole_archive_flag_spec, $1) \ 3931 _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1) \ 3932 _LT_AC_TAGVAR(old_archive_cmds, $1) \ 3933 _LT_AC_TAGVAR(old_archive_from_new_cmds, $1) \ 3934 _LT_AC_TAGVAR(predep_objects, $1) \ 3935 _LT_AC_TAGVAR(postdep_objects, $1) \ 3936 _LT_AC_TAGVAR(predeps, $1) \ 3937 _LT_AC_TAGVAR(postdeps, $1) \ 3938 _LT_AC_TAGVAR(compiler_lib_search_path, $1) \ 3939 _LT_AC_TAGVAR(archive_cmds, $1) \ 3940 _LT_AC_TAGVAR(archive_expsym_cmds, $1) \ 3941 _LT_AC_TAGVAR(postinstall_cmds, $1) \ 3942 _LT_AC_TAGVAR(postuninstall_cmds, $1) \ 3943 _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) \ 3944 _LT_AC_TAGVAR(allow_undefined_flag, $1) \ 3945 _LT_AC_TAGVAR(no_undefined_flag, $1) \ 3946 _LT_AC_TAGVAR(export_symbols_cmds, $1) \ 3947 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) \ 3948 _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1) \ 3949 _LT_AC_TAGVAR(hardcode_libdir_separator, $1) \ 3950 _LT_AC_TAGVAR(hardcode_automatic, $1) \ 3951 _LT_AC_TAGVAR(module_cmds, $1) \ 3952 _LT_AC_TAGVAR(module_expsym_cmds, $1) \ 3953 _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1) \ 3954 _LT_AC_TAGVAR(exclude_expsyms, $1) \ 3955 _LT_AC_TAGVAR(include_expsyms, $1); do 3956 3957 case $var in 3958 _LT_AC_TAGVAR(old_archive_cmds, $1) | \ 3959 _LT_AC_TAGVAR(old_archive_from_new_cmds, $1) | \ 3960 _LT_AC_TAGVAR(archive_cmds, $1) | \ 3961 _LT_AC_TAGVAR(archive_expsym_cmds, $1) | \ 3962 _LT_AC_TAGVAR(module_cmds, $1) | \ 3963 _LT_AC_TAGVAR(module_expsym_cmds, $1) | \ 3964 _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) | \ 3965 _LT_AC_TAGVAR(export_symbols_cmds, $1) | \ 3966 extract_expsyms_cmds | reload_cmds | finish_cmds | \ 3967 postinstall_cmds | postuninstall_cmds | \ 3968 old_postinstall_cmds | old_postuninstall_cmds | \ 3969 sys_lib_search_path_spec | sys_lib_dlsearch_path_spec) 3970 # Double-quote double-evaled strings. 3971 eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\"" 3972 ;; 3973 *) 3974 eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\"" 3975 ;; 3976 esac 3977 done 3978 3979 case $lt_echo in 3980 *'\[$]0 --fallback-echo"') 3981 lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\[$]0 --fallback-echo"[$]/[$]0 --fallback-echo"/'` 3982 ;; 3983 esac 3984 3985ifelse([$1], [], 3986 [cfgfile="${ofile}T" 3987 trap "$rm \"$cfgfile\"; exit 1" 1 2 15 3988 $rm -f "$cfgfile" 3989 AC_MSG_NOTICE([creating $ofile])], 3990 [cfgfile="$ofile"]) 3991 3992 cat <<__EOF__ >> "$cfgfile" 3993ifelse([$1], [], 3994[#! $SHELL 3995 3996# `$echo "$cfgfile" | sed 's%^.*/%%'` - Provide generalized library-building support services. 3997# Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP) 3998# NOTE: Changes made to this file will be lost: look at ltmain.sh. 3999# 4000# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001 4001# Free Software Foundation, Inc. 4002# 4003# This file is part of GNU Libtool: 4004# Originally by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996 4005# 4006# This program is free software; you can redistribute it and/or modify 4007# it under the terms of the GNU General Public License as published by 4008# the Free Software Foundation; either version 2 of the License, or 4009# (at your option) any later version. 4010# 4011# This program is distributed in the hope that it will be useful, but 4012# WITHOUT ANY WARRANTY; without even the implied warranty of 4013# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 4014# General Public License for more details. 4015# 4016# You should have received a copy of the GNU General Public License 4017# along with this program; if not, write to the Free Software 4018# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 4019# 4020# As a special exception to the GNU General Public License, if you 4021# distribute this file as part of a program that contains a 4022# configuration script generated by Autoconf, you may include it under 4023# the same distribution terms that you use for the rest of that program. 4024 4025# A sed program that does not truncate output. 4026SED=$lt_SED 4027 4028# Sed that helps us avoid accidentally triggering echo(1) options like -n. 4029Xsed="$SED -e s/^X//" 4030 4031# The HP-UX ksh and POSIX shell print the target directory to stdout 4032# if CDPATH is set. 4033if test "X\${CDPATH+set}" = Xset; then CDPATH=:; export CDPATH; fi 4034 4035# The names of the tagged configurations supported by this script. 4036available_tags= 4037 4038# ### BEGIN LIBTOOL CONFIG], 4039[# ### BEGIN LIBTOOL TAG CONFIG: $tagname]) 4040 4041# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: 4042 4043# Shell to use when invoking shell scripts. 4044SHELL=$lt_SHELL 4045 4046# Whether or not to build shared libraries. 4047build_libtool_libs=$enable_shared 4048 4049# Whether or not to build static libraries. 4050build_old_libs=$enable_static 4051 4052# Whether or not to add -lc for building shared libraries. 4053build_libtool_need_lc=$_LT_AC_TAGVAR(archive_cmds_need_lc, $1) 4054 4055# Whether or not to disallow shared libs when runtime libs are static 4056allow_libtool_libs_with_static_runtimes=$_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1) 4057 4058# Whether or not to optimize for fast installation. 4059fast_install=$enable_fast_install 4060 4061# The host system. 4062host_alias=$host_alias 4063host=$host 4064 4065# An echo program that does not interpret backslashes. 4066echo=$lt_echo 4067 4068# The archiver. 4069AR=$lt_AR 4070AR_FLAGS=$lt_AR_FLAGS 4071 4072# A C compiler. 4073LTCC=$lt_LTCC 4074 4075# A language-specific compiler. 4076CC=$lt_[]_LT_AC_TAGVAR(compiler, $1) 4077 4078# Is the compiler the GNU C compiler? 4079with_gcc=$_LT_AC_TAGVAR(GCC, $1) 4080 4081# An ERE matcher. 4082EGREP=$lt_EGREP 4083 4084# The linker used to build libraries. 4085LD=$lt_[]_LT_AC_TAGVAR(LD, $1) 4086 4087# Whether we need hard or soft links. 4088LN_S=$lt_LN_S 4089 4090# A BSD-compatible nm program. 4091NM=$lt_NM 4092 4093# A symbol stripping program 4094STRIP=$STRIP 4095 4096# Used to examine libraries when file_magic_cmd begins "file" 4097MAGIC_CMD=$MAGIC_CMD 4098 4099# Used on cygwin: DLL creation program. 4100DLLTOOL="$DLLTOOL" 4101 4102# Used on cygwin: object dumper. 4103OBJDUMP="$OBJDUMP" 4104 4105# Used on cygwin: assembler. 4106AS="$AS" 4107 4108# The name of the directory that contains temporary libtool files. 4109objdir=$objdir 4110 4111# How to create reloadable object files. 4112reload_flag=$lt_reload_flag 4113reload_cmds=$lt_reload_cmds 4114 4115# How to pass a linker flag through the compiler. 4116wl=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_wl, $1) 4117 4118# Object file suffix (normally "o"). 4119objext="$ac_objext" 4120 4121# Old archive suffix (normally "a"). 4122libext="$libext" 4123 4124# Shared library suffix (normally ".so"). 4125shrext='$shrext' 4126 4127# Executable file suffix (normally ""). 4128exeext="$exeext" 4129 4130# Additional compiler flags for building library objects. 4131pic_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) 4132pic_mode=$pic_mode 4133 4134# What is the maximum length of a command? 4135max_cmd_len=$lt_cv_sys_max_cmd_len 4136 4137# Does compiler simultaneously support -c and -o options? 4138compiler_c_o=$lt_[]_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1) 4139 4140# Must we lock files when doing compilation ? 4141need_locks=$lt_need_locks 4142 4143# Do we need the lib prefix for modules? 4144need_lib_prefix=$need_lib_prefix 4145 4146# Do we need a version for libraries? 4147need_version=$need_version 4148 4149# Whether dlopen is supported. 4150dlopen_support=$enable_dlopen 4151 4152# Whether dlopen of programs is supported. 4153dlopen_self=$enable_dlopen_self 4154 4155# Whether dlopen of statically linked programs is supported. 4156dlopen_self_static=$enable_dlopen_self_static 4157 4158# Compiler flag to prevent dynamic linking. 4159link_static_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_static, $1) 4160 4161# Compiler flag to turn off builtin functions. 4162no_builtin_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) 4163 4164# Compiler flag to allow reflexive dlopens. 4165export_dynamic_flag_spec=$lt_[]_LT_AC_TAGVAR(export_dynamic_flag_spec, $1) 4166 4167# Compiler flag to generate shared objects directly from archives. 4168whole_archive_flag_spec=$lt_[]_LT_AC_TAGVAR(whole_archive_flag_spec, $1) 4169 4170# Compiler flag to generate thread-safe objects. 4171thread_safe_flag_spec=$lt_[]_LT_AC_TAGVAR(thread_safe_flag_spec, $1) 4172 4173# Library versioning type. 4174version_type=$version_type 4175 4176# Format of library name prefix. 4177libname_spec=$lt_libname_spec 4178 4179# List of archive names. First name is the real one, the rest are links. 4180# The last name is the one that the linker finds with -lNAME. 4181library_names_spec=$lt_library_names_spec 4182 4183# The coded name of the library, if different from the real name. 4184soname_spec=$lt_soname_spec 4185 4186# Commands used to build and install an old-style archive. 4187RANLIB=$lt_RANLIB 4188old_archive_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_cmds, $1) 4189old_postinstall_cmds=$lt_old_postinstall_cmds 4190old_postuninstall_cmds=$lt_old_postuninstall_cmds 4191 4192# Create an old-style archive from a shared archive. 4193old_archive_from_new_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_from_new_cmds, $1) 4194 4195# Create a temporary old-style archive to link instead of a shared archive. 4196old_archive_from_expsyms_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) 4197 4198# Commands used to build and install a shared archive. 4199archive_cmds=$lt_[]_LT_AC_TAGVAR(archive_cmds, $1) 4200archive_expsym_cmds=$lt_[]_LT_AC_TAGVAR(archive_expsym_cmds, $1) 4201postinstall_cmds=$lt_postinstall_cmds 4202postuninstall_cmds=$lt_postuninstall_cmds 4203 4204# Commands used to build a loadable module (assumed same as above if empty) 4205module_cmds=$lt_[]_LT_AC_TAGVAR(module_cmds, $1) 4206module_expsym_cmds=$lt_[]_LT_AC_TAGVAR(module_expsym_cmds, $1) 4207 4208# Commands to strip libraries. 4209old_striplib=$lt_old_striplib 4210striplib=$lt_striplib 4211 4212# Dependencies to place before the objects being linked to create a 4213# shared library. 4214predep_objects=$lt_[]_LT_AC_TAGVAR(predep_objects, $1) 4215 4216# Dependencies to place after the objects being linked to create a 4217# shared library. 4218postdep_objects=$lt_[]_LT_AC_TAGVAR(postdep_objects, $1) 4219 4220# Dependencies to place before the objects being linked to create a 4221# shared library. 4222predeps=$lt_[]_LT_AC_TAGVAR(predeps, $1) 4223 4224# Dependencies to place after the objects being linked to create a 4225# shared library. 4226postdeps=$lt_[]_LT_AC_TAGVAR(postdeps, $1) 4227 4228# The library search path used internally by the compiler when linking 4229# a shared library. 4230compiler_lib_search_path=$lt_[]_LT_AC_TAGVAR(compiler_lib_search_path, $1) 4231 4232# Method to check whether dependent libraries are shared objects. 4233deplibs_check_method=$lt_deplibs_check_method 4234 4235# Command to use when deplibs_check_method == file_magic. 4236file_magic_cmd=$lt_file_magic_cmd 4237 4238# Flag that allows shared libraries with undefined symbols to be built. 4239allow_undefined_flag=$lt_[]_LT_AC_TAGVAR(allow_undefined_flag, $1) 4240 4241# Flag that forces no undefined symbols. 4242no_undefined_flag=$lt_[]_LT_AC_TAGVAR(no_undefined_flag, $1) 4243 4244# Commands used to finish a libtool library installation in a directory. 4245finish_cmds=$lt_finish_cmds 4246 4247# Same as above, but a single script fragment to be evaled but not shown. 4248finish_eval=$lt_finish_eval 4249 4250# Take the output of nm and produce a listing of raw symbols and C names. 4251global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe 4252 4253# Transform the output of nm in a proper C declaration 4254global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl 4255 4256# Transform the output of nm in a C name address pair 4257global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address 4258 4259# This is the shared library runtime path variable. 4260runpath_var=$runpath_var 4261 4262# This is the shared library path variable. 4263shlibpath_var=$shlibpath_var 4264 4265# Is shlibpath searched before the hard-coded library search path? 4266shlibpath_overrides_runpath=$shlibpath_overrides_runpath 4267 4268# How to hardcode a shared library path into an executable. 4269hardcode_action=$_LT_AC_TAGVAR(hardcode_action, $1) 4270 4271# Whether we should hardcode library paths into libraries. 4272hardcode_into_libs=$hardcode_into_libs 4273 4274# Flag to hardcode \$libdir into a binary during linking. 4275# This must work even if \$libdir does not exist. 4276hardcode_libdir_flag_spec=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) 4277 4278# If ld is used when linking, flag to hardcode \$libdir into 4279# a binary during linking. This must work even if \$libdir does 4280# not exist. 4281hardcode_libdir_flag_spec_ld=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1) 4282 4283# Whether we need a single -rpath flag with a separated argument. 4284hardcode_libdir_separator=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_separator, $1) 4285 4286# Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the 4287# resulting binary. 4288hardcode_direct=$_LT_AC_TAGVAR(hardcode_direct, $1) 4289 4290# Set to yes if using the -LDIR flag during linking hardcodes DIR into the 4291# resulting binary. 4292hardcode_minus_L=$_LT_AC_TAGVAR(hardcode_minus_L, $1) 4293 4294# Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into 4295# the resulting binary. 4296hardcode_shlibpath_var=$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1) 4297 4298# Set to yes if building a shared library automatically hardcodes DIR into the library 4299# and all subsequent libraries and executables linked against it. 4300hardcode_automatic=$_LT_AC_TAGVAR(hardcode_automatic, $1) 4301 4302# Variables whose values should be saved in libtool wrapper scripts and 4303# restored at relink time. 4304variables_saved_for_relink="$variables_saved_for_relink" 4305 4306# Whether libtool must link a program against all its dependency libraries. 4307link_all_deplibs=$_LT_AC_TAGVAR(link_all_deplibs, $1) 4308 4309# Compile-time system search path for libraries 4310sys_lib_search_path_spec=$lt_sys_lib_search_path_spec 4311 4312# Run-time system search path for libraries 4313sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec 4314 4315# Fix the shell variable \$srcfile for the compiler. 4316fix_srcfile_path="$_LT_AC_TAGVAR(fix_srcfile_path, $1)" 4317 4318# Set to yes if exported symbols are required. 4319always_export_symbols=$_LT_AC_TAGVAR(always_export_symbols, $1) 4320 4321# The commands to list exported symbols. 4322export_symbols_cmds=$lt_[]_LT_AC_TAGVAR(export_symbols_cmds, $1) 4323 4324# The commands to extract the exported symbol list from a shared archive. 4325extract_expsyms_cmds=$lt_extract_expsyms_cmds 4326 4327# Symbols that should not be listed in the preloaded symbols. 4328exclude_expsyms=$lt_[]_LT_AC_TAGVAR(exclude_expsyms, $1) 4329 4330# Symbols that must always be exported. 4331include_expsyms=$lt_[]_LT_AC_TAGVAR(include_expsyms, $1) 4332 4333ifelse([$1],[], 4334[# ### END LIBTOOL CONFIG], 4335[# ### END LIBTOOL TAG CONFIG: $tagname]) 4336 4337__EOF__ 4338 4339ifelse([$1],[], [ 4340 case $host_os in 4341 aix3*) 4342 cat <<\EOF >> "$cfgfile" 4343 4344# AIX sometimes has problems with the GCC collect2 program. For some 4345# reason, if we set the COLLECT_NAMES environment variable, the problems 4346# vanish in a puff of smoke. 4347if test "X${COLLECT_NAMES+set}" != Xset; then 4348 COLLECT_NAMES= 4349 export COLLECT_NAMES 4350fi 4351EOF 4352 ;; 4353 esac 4354 4355 # We use sed instead of cat because bash on DJGPP gets confused if 4356 # if finds mixed CR/LF and LF-only lines. Since sed operates in 4357 # text mode, it properly converts lines to CR/LF. This bash problem 4358 # is reportedly fixed, but why not run on old versions too? 4359 sed '$q' "$ltmain" >> "$cfgfile" || (rm -f "$cfgfile"; exit 1) 4360 4361 mv -f "$cfgfile" "$ofile" || \ 4362 (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") 4363 chmod +x "$ofile" 4364]) 4365else 4366 # If there is no Makefile yet, we rely on a make rule to execute 4367 # `config.status --recheck' to rerun these tests and create the 4368 # libtool script then. 4369 test -f Makefile && make "$ltmain" 4370fi 4371])# AC_LIBTOOL_CONFIG 4372 4373 4374# AC_LIBTOOL_PROG_COMPILER_NO_RTTI([TAGNAME]) 4375# ------------------------------------------- 4376AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], 4377[AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl 4378 4379_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= 4380 4381if test "$GCC" = yes; then 4382 _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' 4383 4384 AC_LIBTOOL_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions], 4385 lt_cv_prog_compiler_rtti_exceptions, 4386 [-fno-rtti -fno-exceptions], [], 4387 [_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"]) 4388fi 4389])# AC_LIBTOOL_PROG_COMPILER_NO_RTTI 4390 4391 4392# AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE 4393# --------------------------------- 4394AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], 4395[AC_REQUIRE([AC_CANONICAL_HOST]) 4396AC_REQUIRE([AC_PROG_NM]) 4397AC_REQUIRE([AC_OBJEXT]) 4398# Check for command to grab the raw symbol name followed by C symbol from nm. 4399AC_MSG_CHECKING([command to parse $NM output from $compiler object]) 4400AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe], 4401[ 4402# These are sane defaults that work on at least a few old systems. 4403# [They come from Ultrix. What could be older than Ultrix?!! ;)] 4404 4405# Character class describing NM global symbol codes. 4406symcode='[[BCDEGRST]]' 4407 4408# Regexp to match symbols that can be accessed directly from C. 4409sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)' 4410 4411# Transform the above into a raw symbol and a C symbol. 4412symxfrm='\1 \2\3 \3' 4413 4414# Transform an extracted symbol line into a proper C declaration 4415lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern int \1;/p'" 4416 4417# Transform an extracted symbol line into symbol name and symbol address 4418lt_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'" 4419 4420# Define system-specific variables. 4421case $host_os in 4422aix*) 4423 symcode='[[BCDT]]' 4424 ;; 4425cygwin* | mingw* | pw32*) 4426 symcode='[[ABCDGISTW]]' 4427 ;; 4428hpux*) # Its linker distinguishes data from code symbols 4429 if test "$host_cpu" = ia64; then 4430 symcode='[[ABCDEGRST]]' 4431 fi 4432 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" 4433 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'" 4434 ;; 4435irix* | nonstopux*) 4436 symcode='[[BCDEGRST]]' 4437 ;; 4438osf*) 4439 symcode='[[BCDEGQRST]]' 4440 ;; 4441solaris* | sysv5*) 4442 symcode='[[BDT]]' 4443 ;; 4444sysv4) 4445 symcode='[[DFNSTU]]' 4446 ;; 4447esac 4448 4449# Handle CRLF in mingw tool chain 4450opt_cr= 4451case $build_os in 4452mingw*) 4453 opt_cr=`echo 'x\{0,1\}' | tr x '\015'` # option cr in regexp 4454 ;; 4455esac 4456 4457# If we're using GNU nm, then use its standard symbol codes. 4458case `$NM -V 2>&1` in 4459*GNU* | *'with BFD'*) 4460 symcode='[[ABCDGISTW]]' ;; 4461esac 4462 4463# Try without a prefix undercore, then with it. 4464for ac_symprfx in "" "_"; do 4465 4466 # Write the raw and C identifiers. 4467 lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*\($ac_symprfx\)$sympat$opt_cr$/$symxfrm/p'" 4468 4469 # Check to see that the pipe works correctly. 4470 pipe_works=no 4471 4472 rm -f conftest* 4473 cat > conftest.$ac_ext <<EOF 4474#ifdef __cplusplus 4475extern "C" { 4476#endif 4477char nm_test_var; 4478void nm_test_func(){} 4479#ifdef __cplusplus 4480} 4481#endif 4482int main(){nm_test_var='a';nm_test_func();return(0);} 4483EOF 4484 4485 if AC_TRY_EVAL(ac_compile); then 4486 # Now try to grab the symbols. 4487 nlist=conftest.nm 4488 if AC_TRY_EVAL(NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) && test -s "$nlist"; then 4489 # Try sorting and uniquifying the output. 4490 if sort "$nlist" | uniq > "$nlist"T; then 4491 mv -f "$nlist"T "$nlist" 4492 else 4493 rm -f "$nlist"T 4494 fi 4495 4496 # Make sure that we snagged all the symbols we need. 4497 if grep ' nm_test_var$' "$nlist" >/dev/null; then 4498 if grep ' nm_test_func$' "$nlist" >/dev/null; then 4499 cat <<EOF > conftest.$ac_ext 4500#ifdef __cplusplus 4501extern "C" { 4502#endif 4503 4504EOF 4505 # Now generate the symbol file. 4506 eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | grep -v main >> conftest.$ac_ext' 4507 4508 cat <<EOF >> conftest.$ac_ext 4509#if defined (__STDC__) && __STDC__ 4510# define lt_ptr_t void * 4511#else 4512# define lt_ptr_t char * 4513# define const 4514#endif 4515 4516/* The mapping between symbol names and symbols. */ 4517const struct { 4518 const char *name; 4519 lt_ptr_t address; 4520} 4521lt_preloaded_symbols[[]] = 4522{ 4523EOF 4524 $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (lt_ptr_t) \&\2},/" < "$nlist" | grep -v main >> conftest.$ac_ext 4525 cat <<\EOF >> conftest.$ac_ext 4526 {0, (lt_ptr_t) 0} 4527}; 4528 4529#ifdef __cplusplus 4530} 4531#endif 4532EOF 4533 # Now try linking the two files. 4534 mv conftest.$ac_objext conftstm.$ac_objext 4535 lt_save_LIBS="$LIBS" 4536 lt_save_CFLAGS="$CFLAGS" 4537 LIBS="conftstm.$ac_objext" 4538 CFLAGS="$CFLAGS$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)" 4539 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then 4540 pipe_works=yes 4541 fi 4542 LIBS="$lt_save_LIBS" 4543 CFLAGS="$lt_save_CFLAGS" 4544 else 4545 echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD 4546 fi 4547 else 4548 echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD 4549 fi 4550 else 4551 echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD 4552 fi 4553 else 4554 echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD 4555 cat conftest.$ac_ext >&5 4556 fi 4557 rm -f conftest* conftst* 4558 4559 # Do not use the global_symbol_pipe unless it works. 4560 if test "$pipe_works" = yes; then 4561 break 4562 else 4563 lt_cv_sys_global_symbol_pipe= 4564 fi 4565done 4566]) 4567if test -z "$lt_cv_sys_global_symbol_pipe"; then 4568 lt_cv_sys_global_symbol_to_cdecl= 4569fi 4570if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then 4571 AC_MSG_RESULT(failed) 4572else 4573 AC_MSG_RESULT(ok) 4574fi 4575]) # AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE 4576 4577 4578# AC_LIBTOOL_PROG_COMPILER_PIC([TAGNAME]) 4579# --------------------------------------- 4580AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC], 4581[_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)= 4582_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= 4583_LT_AC_TAGVAR(lt_prog_compiler_static, $1)= 4584 4585AC_MSG_CHECKING([for $compiler option to produce PIC]) 4586 ifelse([$1],[CXX],[ 4587 # C++ specific cases for pic, static, wl, etc. 4588 if test "$GXX" = yes; then 4589 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4590 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static' 4591 4592 case $host_os in 4593 aix*) 4594 # All AIX code is PIC. 4595 if test "$host_cpu" = ia64; then 4596 # AIX 5 now supports IA64 processor 4597 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4598 fi 4599 ;; 4600 amigaos*) 4601 # FIXME: we need at least 68020 code to build shared libraries, but 4602 # adding the `-m68020' flag to GCC prevents building anything better, 4603 # like `-m68040'. 4604 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' 4605 ;; 4606 beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) 4607 # PIC is the default for these OSes. 4608 ;; 4609 mingw* | os2* | pw32*) 4610 # This hack is so that the source file can tell whether it is being 4611 # built for inclusion in a dll (and should export symbols for example). 4612 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT' 4613 ;; 4614 darwin* | rhapsody*) 4615 # PIC is the default on this platform 4616 # Common symbols not allowed in MH_DYLIB files 4617 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' 4618 ;; 4619 *djgpp*) 4620 # DJGPP does not support shared libraries at all 4621 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= 4622 ;; 4623 sysv4*MP*) 4624 if test -d /usr/nec; then 4625 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic 4626 fi 4627 ;; 4628 hpux*) 4629 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but 4630 # not for PA HP-UX. 4631 case "$host_cpu" in 4632 hppa*64*|ia64*) 4633 ;; 4634 *) 4635 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 4636 ;; 4637 esac 4638 ;; 4639 *) 4640 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 4641 ;; 4642 esac 4643 else 4644 case $host_os in 4645 aix4* | aix5*) 4646 # All AIX code is PIC. 4647 if test "$host_cpu" = ia64; then 4648 # AIX 5 now supports IA64 processor 4649 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4650 else 4651 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' 4652 fi 4653 ;; 4654 chorus*) 4655 case $cc_basename in 4656 cxch68) 4657 # Green Hills C++ Compiler 4658 # _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" 4659 ;; 4660 esac 4661 ;; 4662 dgux*) 4663 case $cc_basename in 4664 ec++) 4665 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4666 ;; 4667 ghcx) 4668 # Green Hills C++ Compiler 4669 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 4670 ;; 4671 *) 4672 ;; 4673 esac 4674 ;; 4675 freebsd*) 4676 # FreeBSD uses GNU C++ 4677 ;; 4678 hpux9* | hpux10* | hpux11*) 4679 case $cc_basename in 4680 CC) 4681 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4682 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)="${ac_cv_prog_cc_wl}-a ${ac_cv_prog_cc_wl}archive" 4683 if test "$host_cpu" != ia64; then 4684 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z' 4685 fi 4686 ;; 4687 aCC) 4688 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4689 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)="${ac_cv_prog_cc_wl}-a ${ac_cv_prog_cc_wl}archive" 4690 case "$host_cpu" in 4691 hppa*64*|ia64*) 4692 # +Z the default 4693 ;; 4694 *) 4695 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z' 4696 ;; 4697 esac 4698 ;; 4699 *) 4700 ;; 4701 esac 4702 ;; 4703 irix5* | irix6* | nonstopux*) 4704 case $cc_basename in 4705 CC) 4706 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4707 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 4708 # CC pic flag -KPIC is the default. 4709 ;; 4710 *) 4711 ;; 4712 esac 4713 ;; 4714 linux*) 4715 case $cc_basename in 4716 KCC) 4717 # KAI C++ Compiler 4718 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' 4719 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 4720 ;; 4721 icpc) 4722 # Intel C++ 4723 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4724 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4725 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static' 4726 ;; 4727 cxx) 4728 # Compaq C++ 4729 # Make sure the PIC flag is empty. It appears that all Alpha 4730 # Linux and Compaq Tru64 Unix objects are PIC. 4731 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= 4732 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 4733 ;; 4734 *) 4735 ;; 4736 esac 4737 ;; 4738 lynxos*) 4739 ;; 4740 m88k*) 4741 ;; 4742 mvs*) 4743 case $cc_basename in 4744 cxx) 4745 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall' 4746 ;; 4747 *) 4748 ;; 4749 esac 4750 ;; 4751 netbsd*) 4752 ;; 4753 osf3* | osf4* | osf5*) 4754 case $cc_basename in 4755 KCC) 4756 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' 4757 ;; 4758 RCC) 4759 # Rational C++ 2.4.1 4760 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 4761 ;; 4762 cxx) 4763 # Digital/Compaq C++ 4764 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4765 # Make sure the PIC flag is empty. It appears that all Alpha 4766 # Linux and Compaq Tru64 Unix objects are PIC. 4767 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= 4768 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 4769 ;; 4770 *) 4771 ;; 4772 esac 4773 ;; 4774 psos*) 4775 ;; 4776 sco*) 4777 case $cc_basename in 4778 CC) 4779 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 4780 ;; 4781 *) 4782 ;; 4783 esac 4784 ;; 4785 solaris*) 4786 case $cc_basename in 4787 CC) 4788 # Sun C++ 4.2, 5.x and Centerline C++ 4789 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4790 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4791 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' 4792 ;; 4793 gcx) 4794 # Green Hills C++ Compiler 4795 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' 4796 ;; 4797 *) 4798 ;; 4799 esac 4800 ;; 4801 sunos4*) 4802 case $cc_basename in 4803 CC) 4804 # Sun C++ 4.x 4805 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 4806 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4807 ;; 4808 lcc) 4809 # Lucid 4810 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 4811 ;; 4812 *) 4813 ;; 4814 esac 4815 ;; 4816 tandem*) 4817 case $cc_basename in 4818 NCC) 4819 # NonStop-UX NCC 3.20 4820 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4821 ;; 4822 *) 4823 ;; 4824 esac 4825 ;; 4826 unixware*) 4827 ;; 4828 vxworks*) 4829 ;; 4830 *) 4831 _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 4832 ;; 4833 esac 4834 fi 4835], 4836[ 4837 if test "$GCC" = yes; then 4838 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4839 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static' 4840 4841 case $host_os in 4842 aix*) 4843 # All AIX code is PIC. 4844 if test "$host_cpu" = ia64; then 4845 # AIX 5 now supports IA64 processor 4846 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4847 fi 4848 ;; 4849 4850 amigaos*) 4851 # FIXME: we need at least 68020 code to build shared libraries, but 4852 # adding the `-m68020' flag to GCC prevents building anything better, 4853 # like `-m68040'. 4854 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' 4855 ;; 4856 4857 beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) 4858 # PIC is the default for these OSes. 4859 ;; 4860 4861 mingw* | pw32* | os2*) 4862 # This hack is so that the source file can tell whether it is being 4863 # built for inclusion in a dll (and should export symbols for example). 4864 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT' 4865 ;; 4866 4867 darwin* | rhapsody*) 4868 # PIC is the default on this platform 4869 # Common symbols not allowed in MH_DYLIB files 4870 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' 4871 ;; 4872 4873 msdosdjgpp*) 4874 # Just because we use GCC doesn't mean we suddenly get shared libraries 4875 # on systems that don't support them. 4876 _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 4877 enable_shared=no 4878 ;; 4879 4880 sysv4*MP*) 4881 if test -d /usr/nec; then 4882 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic 4883 fi 4884 ;; 4885 4886 hpux*) 4887 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but 4888 # not for PA HP-UX. 4889 case "$host_cpu" in 4890 hppa*64*|ia64*) 4891 # +Z the default 4892 ;; 4893 *) 4894 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 4895 ;; 4896 esac 4897 ;; 4898 4899 *) 4900 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 4901 ;; 4902 esac 4903 else 4904 # PORTME Check for flag to pass linker flags through the system compiler. 4905 case $host_os in 4906 aix*) 4907 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4908 if test "$host_cpu" = ia64; then 4909 # AIX 5 now supports IA64 processor 4910 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4911 else 4912 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' 4913 fi 4914 ;; 4915 4916 mingw* | pw32* | os2*) 4917 # This hack is so that the source file can tell whether it is being 4918 # built for inclusion in a dll (and should export symbols for example). 4919 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT' 4920 ;; 4921 4922 hpux9* | hpux10* | hpux11*) 4923 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4924 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but 4925 # not for PA HP-UX. 4926 case "$host_cpu" in 4927 hppa*64*|ia64*) 4928 # +Z the default 4929 ;; 4930 *) 4931 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z' 4932 ;; 4933 esac 4934 # Is there a better lt_prog_compiler_static that works with the bundled CC? 4935 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' 4936 ;; 4937 4938 irix5* | irix6* | nonstopux*) 4939 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4940 # PIC (with -KPIC) is the default. 4941 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 4942 ;; 4943 4944 newsos6) 4945 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4946 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4947 ;; 4948 4949 linux*) 4950 case $CC in 4951 icc|ecc) 4952 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4953 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4954 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static' 4955 ;; 4956 ccc) 4957 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4958 # All Alpha code is PIC. 4959 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 4960 ;; 4961 esac 4962 ;; 4963 4964 osf3* | osf4* | osf5*) 4965 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4966 # All OSF/1 code is PIC. 4967 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 4968 ;; 4969 4970 sco3.2v5*) 4971 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-Kpic' 4972 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-dn' 4973 ;; 4974 4975 solaris*) 4976 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4977 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4978 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4979 ;; 4980 4981 sunos4*) 4982 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' 4983 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' 4984 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4985 ;; 4986 4987 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) 4988 _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4989 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4990 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4991 ;; 4992 4993 sysv4*MP*) 4994 if test -d /usr/nec ;then 4995 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic' 4996 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4997 fi 4998 ;; 4999 5000 uts4*) 5001 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 5002 _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 5003 ;; 5004 5005 *) 5006 _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 5007 ;; 5008 esac 5009 fi 5010]) 5011AC_MSG_RESULT([$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)]) 5012 5013# 5014# Check to make sure the PIC flag actually works. 5015# 5016if test -n "$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)"; then 5017 AC_LIBTOOL_COMPILER_OPTION([if $compiler PIC flag $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) works], 5018 _LT_AC_TAGVAR(lt_prog_compiler_pic_works, $1), 5019 [$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])], [], 5020 [case $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) in 5021 "" | " "*) ;; 5022 *) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)" ;; 5023 esac], 5024 [_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= 5025 _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no]) 5026fi 5027case "$host_os" in 5028 # For platforms which do not support PIC, -DPIC is meaningless: 5029 *djgpp*) 5030 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= 5031 ;; 5032 *) 5033 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])" 5034 ;; 5035esac 5036]) 5037 5038 5039# AC_LIBTOOL_PROG_LD_SHLIBS([TAGNAME]) 5040# ------------------------------------ 5041# See if the linker supports building shared libraries. 5042AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS], 5043[AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) 5044ifelse([$1],[CXX],[ 5045 _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' 5046 case $host_os in 5047 aix4* | aix5*) 5048 # If we're using GNU nm, then we don't want the "-C" option. 5049 # -C means demangle to AIX nm, but means don't demangle with GNU nm 5050 if $NM -V 2>&1 | grep 'GNU' > /dev/null; then 5051 _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' 5052 else 5053 _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' 5054 fi 5055 ;; 5056 pw32*) 5057 _LT_AC_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds" 5058 ;; 5059 cygwin* | mingw*) 5060 _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGS]] /s/.* \([[^ ]]*\)/\1 DATA/'\'' | $SED -e '\''/^[[AITW]] /s/.* //'\'' | sort | uniq > $export_symbols' 5061 ;; 5062 *) 5063 _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' 5064 ;; 5065 esac 5066],[ 5067 runpath_var= 5068 _LT_AC_TAGVAR(allow_undefined_flag, $1)= 5069 _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no 5070 _LT_AC_TAGVAR(archive_cmds, $1)= 5071 _LT_AC_TAGVAR(archive_expsym_cmds, $1)= 5072 _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)= 5073 _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1)= 5074 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)= 5075 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)= 5076 _LT_AC_TAGVAR(thread_safe_flag_spec, $1)= 5077 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)= 5078 _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= 5079 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)= 5080 _LT_AC_TAGVAR(hardcode_direct, $1)=no 5081 _LT_AC_TAGVAR(hardcode_minus_L, $1)=no 5082 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported 5083 _LT_AC_TAGVAR(link_all_deplibs, $1)=unknown 5084 _LT_AC_TAGVAR(hardcode_automatic, $1)=no 5085 _LT_AC_TAGVAR(module_cmds, $1)= 5086 _LT_AC_TAGVAR(module_expsym_cmds, $1)= 5087 _LT_AC_TAGVAR(always_export_symbols, $1)=no 5088 _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' 5089 # include_expsyms should be a list of space-separated symbols to be *always* 5090 # included in the symbol list 5091 _LT_AC_TAGVAR(include_expsyms, $1)= 5092 # exclude_expsyms can be an extended regexp of symbols to exclude 5093 # it will be wrapped by ` (' and `)$', so one must not match beginning or 5094 # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', 5095 # as well as any symbol that contains `d'. 5096 _LT_AC_TAGVAR(exclude_expsyms, $1)="_GLOBAL_OFFSET_TABLE_" 5097 # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out 5098 # platforms (ab)use it in PIC code, but their linkers get confused if 5099 # the symbol is explicitly referenced. Since portable code cannot 5100 # rely on this symbol name, it's probably fine to never include it in 5101 # preloaded symbol tables. 5102 extract_expsyms_cmds= 5103 5104 case $host_os in 5105 cygwin* | mingw* | pw32*) 5106 # FIXME: the MSVC++ port hasn't been tested in a loooong time 5107 # When not using gcc, we currently assume that we are using 5108 # Microsoft Visual C++. 5109 if test "$GCC" != yes; then 5110 with_gnu_ld=no 5111 fi 5112 ;; 5113 openbsd*) 5114 with_gnu_ld=no 5115 ;; 5116 esac 5117 5118 _LT_AC_TAGVAR(ld_shlibs, $1)=yes 5119 if test "$with_gnu_ld" = yes; then 5120 # If archive_cmds runs LD, not CC, wlarc should be empty 5121 wlarc='${wl}' 5122 5123 # See if GNU ld supports shared libraries. 5124 case $host_os in 5125 aix3* | aix4* | aix5*) 5126 # On AIX/PPC, the GNU linker is very broken 5127 if test "$host_cpu" != ia64; then 5128 _LT_AC_TAGVAR(ld_shlibs, $1)=no 5129 cat <<EOF 1>&2 5130 5131*** Warning: the GNU linker, at least up to release 2.9.1, is reported 5132*** to be unable to reliably create shared libraries on AIX. 5133*** Therefore, libtool is disabling shared libraries support. If you 5134*** really care for shared libraries, you may want to modify your PATH 5135*** so that a non-GNU linker is found, and then restart. 5136 5137EOF 5138 fi 5139 ;; 5140 5141 amigaos*) 5142 _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)' 5143 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 5144 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes 5145 5146 # Samuel A. Falvo II <kc5tja@dolphin.openprojects.net> reports 5147 # that the semantics of dynamic libraries on AmigaOS, at least up 5148 # to version 4, is to share data among multiple programs linked 5149 # with the same dynamic library. Since this doesn't match the 5150 # behavior of shared libraries on other platforms, we can't use 5151 # them. 5152 _LT_AC_TAGVAR(ld_shlibs, $1)=no 5153 ;; 5154 5155 beos*) 5156 if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then 5157 _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported 5158 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc 5159 # support --undefined. This deserves some investigation. FIXME 5160 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 5161 else 5162 _LT_AC_TAGVAR(ld_shlibs, $1)=no 5163 fi 5164 ;; 5165 5166 cygwin* | mingw* | pw32*) 5167 # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, 5168 # as there is no search path for DLLs. 5169 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 5170 _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported 5171 _LT_AC_TAGVAR(always_export_symbols, $1)=no 5172 _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 5173 _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGS]] /s/.* \([[^ ]]*\)/\1 DATA/'\'' | $SED -e '\''/^[[AITW]] /s/.* //'\'' | sort | uniq > $export_symbols' 5174 5175 if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then 5176 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib' 5177 # If the export-symbols file already is a .def file (1st line 5178 # is EXPORTS), use it as is; otherwise, prepend... 5179 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then 5180 cp $export_symbols $output_objdir/$soname.def; 5181 else 5182 echo EXPORTS > $output_objdir/$soname.def; 5183 cat $export_symbols >> $output_objdir/$soname.def; 5184 fi~ 5185 $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib' 5186 else 5187 ld_shlibs=no 5188 fi 5189 ;; 5190 5191 netbsd*) 5192 if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then 5193 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' 5194 wlarc= 5195 else 5196 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 5197 _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' 5198 fi 5199 ;; 5200 5201 solaris* | sysv5*) 5202 if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then 5203 _LT_AC_TAGVAR(ld_shlibs, $1)=no 5204 cat <<EOF 1>&2 5205 5206*** Warning: The releases 2.8.* of the GNU linker cannot reliably 5207*** create shared libraries on Solaris systems. Therefore, libtool 5208*** is disabling shared libraries support. We urge you to upgrade GNU 5209*** binutils to release 2.9.1 or newer. Another option is to modify 5210*** your PATH or compiler configuration so that the native linker is 5211*** used, and then restart. 5212 5213EOF 5214 elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then 5215 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 5216 _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' 5217 else 5218 _LT_AC_TAGVAR(ld_shlibs, $1)=no 5219 fi 5220 ;; 5221 5222 sunos4*) 5223 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' 5224 wlarc= 5225 _LT_AC_TAGVAR(hardcode_direct, $1)=yes 5226 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 5227 ;; 5228 5229 *) 5230 if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then 5231 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 5232 _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' 5233 else 5234 _LT_AC_TAGVAR(ld_shlibs, $1)=no 5235 fi 5236 ;; 5237 esac 5238 5239 if test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = yes; then 5240 runpath_var=LD_RUN_PATH 5241 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir' 5242 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 5243 # ancient GNU ld didn't support --whole-archive et. al. 5244 if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then 5245 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' 5246 else 5247 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)= 5248 fi 5249 fi 5250 else 5251 # PORTME fill in a description of your system's linker (not GNU ld) 5252 case $host_os in 5253 aix3*) 5254 _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported 5255 _LT_AC_TAGVAR(always_export_symbols, $1)=yes 5256 _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' 5257 # Note: this linker hardcodes the directories in LIBPATH if there 5258 # are no directories specified by -L. 5259 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes 5260 if test "$GCC" = yes && test -z "$link_static_flag"; then 5261 # Neither direct hardcoding nor static linking is supported with a 5262 # broken collect2. 5263 _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported 5264 fi 5265 ;; 5266 5267 aix4* | aix5*) 5268 if test "$host_cpu" = ia64; then 5269 # On IA64, the linker does run time linking by default, so we don't 5270 # have to do anything special. 5271 aix_use_runtimelinking=no 5272 exp_sym_flag='-Bexport' 5273 no_entry_flag="" 5274 else 5275 # If we're using GNU nm, then we don't want the "-C" option. 5276 # -C means demangle to AIX nm, but means don't demangle with GNU nm 5277 if $NM -V 2>&1 | grep 'GNU' > /dev/null; then 5278 _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' 5279 else 5280 _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' 5281 fi 5282 aix_use_runtimelinking=no 5283 5284 # Test if we are trying to use run time linking or normal 5285 # AIX style linking. If -brtl is somewhere in LDFLAGS, we 5286 # need to do runtime linking. 5287 case $host_os in aix4.[[23]]|aix4.[[23]].*|aix5*) 5288 for ld_flag in $LDFLAGS; do 5289 if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then 5290 aix_use_runtimelinking=yes 5291 break 5292 fi 5293 done 5294 esac 5295 5296 exp_sym_flag='-bexport' 5297 no_entry_flag='-bnoentry' 5298 fi 5299 5300 # When large executables or shared objects are built, AIX ld can 5301 # have problems creating the table of contents. If linking a library 5302 # or program results in "error TOC overflow" add -mminimal-toc to 5303 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not 5304 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. 5305 5306 _LT_AC_TAGVAR(archive_cmds, $1)='' 5307 _LT_AC_TAGVAR(hardcode_direct, $1)=yes 5308 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':' 5309 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes 5310 5311 if test "$GCC" = yes; then 5312 case $host_os in aix4.[012]|aix4.[012].*) 5313 # We only want to do this on AIX 4.2 and lower, the check 5314 # below for broken collect2 doesn't work under 4.3+ 5315 collect2name=`${CC} -print-prog-name=collect2` 5316 if test -f "$collect2name" && \ 5317 strings "$collect2name" | grep resolve_lib_name >/dev/null 5318 then 5319 # We have reworked collect2 5320 _LT_AC_TAGVAR(hardcode_direct, $1)=yes 5321 else 5322 # We have old collect2 5323 _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported 5324 # It fails to find uninstalled libraries when the uninstalled 5325 # path is not listed in the libpath. Setting hardcode_minus_L 5326 # to unsupported forces relinking 5327 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes 5328 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 5329 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)= 5330 fi 5331 esac 5332 shared_flag='-shared' 5333 else 5334 # not using gcc 5335 if test "$host_cpu" = ia64; then 5336 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release 5337 # chokes on -Wl,-G. The following line is correct: 5338 shared_flag='-G' 5339 else 5340 if test "$aix_use_runtimelinking" = yes; then 5341 shared_flag='${wl}-G' 5342 else 5343 shared_flag='${wl}-bM:SRE' 5344 fi 5345 fi 5346 fi 5347 5348 # It seems that -bexpall does not export symbols beginning with 5349 # underscore (_), so it is better to generate a list of symbols to export. 5350 _LT_AC_TAGVAR(always_export_symbols, $1)=yes 5351 if test "$aix_use_runtimelinking" = yes; then 5352 # Warning - without using the other runtime loading flags (-brtl), 5353 # -berok will link without error, but may produce a broken library. 5354 _LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok' 5355 # Determine the default libpath from the value encoded in an empty executable. 5356 _LT_AC_SYS_LIBPATH_AIX 5357 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" 5358 _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols $shared_flag" 5359 else 5360 if test "$host_cpu" = ia64; then 5361 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' 5362 _LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs" 5363 _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols" 5364 else 5365 # Determine the default libpath from the value encoded in an empty executable. 5366 _LT_AC_SYS_LIBPATH_AIX 5367 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" 5368 # Warning - without using the other run time loading flags, 5369 # -berok will link without error, but may produce a broken library. 5370 _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' 5371 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' 5372 # -bexpall does not export symbols beginning with underscore (_) 5373 _LT_AC_TAGVAR(always_export_symbols, $1)=yes 5374 # Exported symbols can be pulled into shared objects from archives 5375 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=' ' 5376 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes 5377 # This is similar to how AIX traditionally builds it's shared libraries. 5378 _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' 5379 fi 5380 fi 5381 ;; 5382 5383 amigaos*) 5384 _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)' 5385 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 5386 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes 5387 # see comment about different semantics on the GNU ld section 5388 _LT_AC_TAGVAR(ld_shlibs, $1)=no 5389 ;; 5390 5391 bsdi4*) 5392 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic 5393 ;; 5394 5395 cygwin* | mingw* | pw32*) 5396 # When not using gcc, we currently assume that we are using 5397 # Microsoft Visual C++. 5398 # hardcode_libdir_flag_spec is actually meaningless, as there is 5399 # no search path for DLLs. 5400 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' 5401 _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported 5402 # Tell ltmain to make .lib files, not .a files. 5403 libext=lib 5404 # Tell ltmain to make .dll files, not .so files. 5405 shrext=".dll" 5406 # FIXME: Setting linknames here is a bad hack. 5407 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames=' 5408 # The linker will automatically build a .lib file if we build a DLL. 5409 _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='true' 5410 # FIXME: Should let the user specify the lib program. 5411 _LT_AC_TAGVAR(old_archive_cmds, $1)='lib /OUT:$oldlib$oldobjs$old_deplibs' 5412 fix_srcfile_path='`cygpath -w "$srcfile"`' 5413 _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 5414 ;; 5415 5416 darwin* | rhapsody*) 5417 if $CC -v 2>&1 | grep 'Apple' >/dev/null ; then 5418 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no 5419 case "$host_os" in 5420 rhapsody* | darwin1.[[012]]) 5421 _LT_AC_TAGVAR(allow_undefined_flag, $1)='-undefined suppress' 5422 ;; 5423 *) # Darwin 1.3 on 5424 test -z ${LD_TWOLEVEL_NAMESPACE} && _LT_AC_TAGVAR(allow_undefined_flag, $1)='-flat_namespace -undefined suppress' 5425 ;; 5426 esac 5427 # FIXME: Relying on posixy $() will cause problems for 5428 # cross-compilation, but unfortunately the echo tests do not 5429 # yet detect zsh echo's removal of \ escapes. Also zsh mangles 5430 # `"' quotes if we put them in here... so don't! 5431 lt_int_apple_cc_single_mod=no 5432 output_verbose_link_cmd='echo' 5433 if $CC -dumpspecs 2>&1 | grep 'single_module' >/dev/null ; then 5434 lt_int_apple_cc_single_mod=yes 5435 fi 5436 if test "X$lt_int_apple_cc_single_mod" = Xyes ; then 5437 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring' 5438 else 5439 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -r ${wl}-bind_at_load -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' 5440 fi 5441 _LT_AC_TAGVAR(module_cmds, $1)='$CC -bundle ${wl}-bind_at_load $allow_undefined_flag -o $lib $libobjs $deplibs$compiler_flags' 5442 # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin ld's 5443 if test "X$lt_int_apple_cc_single_mod" = Xyes ; then 5444 _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}' 5445 else 5446 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -r ${wl}-bind_at_load -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}' 5447 fi 5448 _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -bundle $allow_undefined_flag -o $lib $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' 5449 _LT_AC_TAGVAR(hardcode_direct, $1)=no 5450 _LT_AC_TAGVAR(hardcode_automatic, $1)=yes 5451 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported 5452 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-all_load $convenience' 5453 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes 5454 fi 5455 ;; 5456 5457 dgux*) 5458 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 5459 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 5460 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 5461 ;; 5462 5463 freebsd1*) 5464 _LT_AC_TAGVAR(ld_shlibs, $1)=no 5465 ;; 5466 5467 # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor 5468 # support. Future versions do this automatically, but an explicit c++rt0.o 5469 # does not break anything, and helps significantly (at the cost of a little 5470 # extra space). 5471 freebsd2.2*) 5472 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' 5473 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 5474 _LT_AC_TAGVAR(hardcode_direct, $1)=yes 5475 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 5476 ;; 5477 5478 # Unfortunately, older versions of FreeBSD 2 do not have this feature. 5479 freebsd2*) 5480 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' 5481 _LT_AC_TAGVAR(hardcode_direct, $1)=yes 5482 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes 5483 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 5484 ;; 5485 5486 # FreeBSD 3 and greater uses gcc -shared to do shared libraries. 5487 freebsd*) 5488 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' 5489 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 5490 _LT_AC_TAGVAR(hardcode_direct, $1)=yes 5491 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 5492 ;; 5493 5494 hpux9*) 5495 if test "$GCC" = yes; then 5496 _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' 5497 else 5498 _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' 5499 fi 5500 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 5501 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 5502 _LT_AC_TAGVAR(hardcode_direct, $1)=yes 5503 5504 # hardcode_minus_L: Not really in the search PATH, 5505 # but as the default location of the library. 5506 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes 5507 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 5508 ;; 5509 5510 hpux10* | hpux11*) 5511 if test "$GCC" = yes -a "$with_gnu_ld" = no; then 5512 case "$host_cpu" in 5513 hppa*64*|ia64*) 5514 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' 5515 ;; 5516 *) 5517 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' 5518 ;; 5519 esac 5520 else 5521 case "$host_cpu" in 5522 hppa*64*|ia64*) 5523 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname -o $lib $libobjs $deplibs $linker_flags' 5524 ;; 5525 *) 5526 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' 5527 ;; 5528 esac 5529 fi 5530 if test "$with_gnu_ld" = no; then 5531 case "$host_cpu" in 5532 hppa*64*) 5533 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 5534 _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir' 5535 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 5536 _LT_AC_TAGVAR(hardcode_direct, $1)=no 5537 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 5538 ;; 5539 ia64*) 5540 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 5541 _LT_AC_TAGVAR(hardcode_direct, $1)=no 5542 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 5543 5544 # hardcode_minus_L: Not really in the search PATH, 5545 # but as the default location of the library. 5546 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes 5547 ;; 5548 *) 5549 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 5550 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 5551 _LT_AC_TAGVAR(hardcode_direct, $1)=yes 5552 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 5553 5554 # hardcode_minus_L: Not really in the search PATH, 5555 # but as the default location of the library. 5556 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes 5557 ;; 5558 esac 5559 fi 5560 ;; 5561 5562 irix5* | irix6* | nonstopux*) 5563 if test "$GCC" = yes; then 5564 _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' 5565 else 5566 _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' 5567 _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='-rpath $libdir' 5568 fi 5569 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 5570 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 5571 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes 5572 ;; 5573 5574 netbsd*) 5575 if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then 5576 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out 5577 else 5578 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF 5579 fi 5580 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 5581 _LT_AC_TAGVAR(hardcode_direct, $1)=yes 5582 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 5583 ;; 5584 5585 newsos6) 5586 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 5587 _LT_AC_TAGVAR(hardcode_direct, $1)=yes 5588 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 5589 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 5590 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 5591 ;; 5592 5593 openbsd*) 5594 _LT_AC_TAGVAR(hardcode_direct, $1)=yes 5595 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 5596 if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then 5597 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' 5598 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 5599 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 5600 else 5601 case $host_os in 5602 openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*) 5603 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' 5604 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 5605 ;; 5606 *) 5607 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' 5608 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 5609 ;; 5610 esac 5611 fi 5612 ;; 5613 5614 os2*) 5615 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 5616 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes 5617 _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported 5618 _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' 5619 _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' 5620 ;; 5621 5622 osf3*) 5623 if test "$GCC" = yes; then 5624 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' 5625 _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' 5626 else 5627 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' 5628 _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' 5629 fi 5630 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 5631 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 5632 ;; 5633 5634 osf4* | osf5*) # as osf3* with the addition of -msym flag 5635 if test "$GCC" = yes; then 5636 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' 5637 _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' 5638 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 5639 else 5640 _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' 5641 _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' 5642 _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~ 5643 $LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${objdir}/so_locations -o $lib~$rm $lib.exp' 5644 5645 # Both c and cxx compiler support -rpath directly 5646 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' 5647 fi 5648 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 5649 ;; 5650 5651 sco3.2v5*) 5652 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 5653 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 5654 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' 5655 runpath_var=LD_RUN_PATH 5656 hardcode_runpath_var=yes 5657 ;; 5658 5659 solaris*) 5660 _LT_AC_TAGVAR(no_undefined_flag, $1)=' -z text' 5661 if test "$GCC" = yes; then 5662 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' 5663 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ 5664 $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp' 5665 else 5666 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' 5667 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ 5668 $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp' 5669 fi 5670 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 5671 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 5672 case $host_os in 5673 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; 5674 *) # Supported since Solaris 2.6 (maybe 2.5.1?) 5675 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' ;; 5676 esac 5677 _LT_AC_TAGVAR(link_all_deplibs, $1)=yes 5678 ;; 5679 5680 sunos4*) 5681 if test "x$host_vendor" = xsequent; then 5682 # Use $CC to link under sequent, because it throws in some extra .o 5683 # files that make .init and .fini sections work. 5684 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' 5685 else 5686 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' 5687 fi 5688 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 5689 _LT_AC_TAGVAR(hardcode_direct, $1)=yes 5690 _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes 5691 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 5692 ;; 5693 5694 sysv4) 5695 case $host_vendor in 5696 sni) 5697 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 5698 _LT_AC_TAGVAR(hardcode_direct, $1)=yes # is this really true??? 5699 ;; 5700 siemens) 5701 ## LD is ld it makes a PLAMLIB 5702 ## CC just makes a GrossModule. 5703 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags' 5704 _LT_AC_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs' 5705 _LT_AC_TAGVAR(hardcode_direct, $1)=no 5706 ;; 5707 motorola) 5708 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 5709 _LT_AC_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie 5710 ;; 5711 esac 5712 runpath_var='LD_RUN_PATH' 5713 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 5714 ;; 5715 5716 sysv4.3*) 5717 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 5718 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 5719 _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport' 5720 ;; 5721 5722 sysv4*MP*) 5723 if test -d /usr/nec; then 5724 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 5725 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 5726 runpath_var=LD_RUN_PATH 5727 hardcode_runpath_var=yes 5728 _LT_AC_TAGVAR(ld_shlibs, $1)=yes 5729 fi 5730 ;; 5731 5732 sysv4.2uw2*) 5733 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags' 5734 _LT_AC_TAGVAR(hardcode_direct, $1)=yes 5735 _LT_AC_TAGVAR(hardcode_minus_L, $1)=no 5736 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 5737 hardcode_runpath_var=yes 5738 runpath_var=LD_RUN_PATH 5739 ;; 5740 5741 sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[[78]]* | unixware7*) 5742 _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z ${wl}text' 5743 if test "$GCC" = yes; then 5744 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' 5745 else 5746 _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' 5747 fi 5748 runpath_var='LD_RUN_PATH' 5749 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 5750 ;; 5751 5752 sysv5*) 5753 _LT_AC_TAGVAR(no_undefined_flag, $1)=' -z text' 5754 # $CC -shared without GNU ld will not create a library from C++ 5755 # object files and a static libstdc++, better avoid it by now 5756 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' 5757 _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ 5758 $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp' 5759 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)= 5760 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 5761 runpath_var='LD_RUN_PATH' 5762 ;; 5763 5764 uts4*) 5765 _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 5766 _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 5767 _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 5768 ;; 5769 5770 *) 5771 _LT_AC_TAGVAR(ld_shlibs, $1)=no 5772 ;; 5773 esac 5774 fi 5775]) 5776AC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)]) 5777test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no 5778 5779variables_saved_for_relink="PATH $shlibpath_var $runpath_var" 5780if test "$GCC" = yes; then 5781 variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" 5782fi 5783 5784# 5785# Do we need to explicitly link libc? 5786# 5787case "x$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)" in 5788x|xyes) 5789 # Assume -lc should be added 5790 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes 5791 5792 if test "$enable_shared" = yes && test "$GCC" = yes; then 5793 case $_LT_AC_TAGVAR(archive_cmds, $1) in 5794 *'~'*) 5795 # FIXME: we may have to deal with multi-command sequences. 5796 ;; 5797 '$CC '*) 5798 # Test whether the compiler implicitly links with -lc since on some 5799 # systems, -lgcc has to come before -lc. If gcc already passes -lc 5800 # to ld, don't add -lc before -lgcc. 5801 AC_MSG_CHECKING([whether -lc should be explicitly linked in]) 5802 $rm conftest* 5803 printf "$lt_simple_compile_test_code" > conftest.$ac_ext 5804 5805 if AC_TRY_EVAL(ac_compile) 2>conftest.err; then 5806 soname=conftest 5807 lib=conftest 5808 libobjs=conftest.$ac_objext 5809 deplibs= 5810 wl=$_LT_AC_TAGVAR(lt_prog_compiler_wl, $1) 5811 compiler_flags=-v 5812 linker_flags=-v 5813 verstring= 5814 output_objdir=. 5815 libname=conftest 5816 lt_save_allow_undefined_flag=$_LT_AC_TAGVAR(allow_undefined_flag, $1) 5817 _LT_AC_TAGVAR(allow_undefined_flag, $1)= 5818 if AC_TRY_EVAL(_LT_AC_TAGVAR(archive_cmds, $1) 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 5819 then 5820 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no 5821 else 5822 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes 5823 fi 5824 _LT_AC_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag 5825 else 5826 cat conftest.err 1>&5 5827 fi 5828 $rm conftest* 5829 AC_MSG_RESULT([$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)]) 5830 ;; 5831 esac 5832 fi 5833 ;; 5834esac 5835])# AC_LIBTOOL_PROG_LD_SHLIBS 5836 5837 5838# _LT_AC_FILE_LTDLL_C 5839# ------------------- 5840# Be careful that the start marker always follows a newline. 5841AC_DEFUN([_LT_AC_FILE_LTDLL_C], [ 5842# /* ltdll.c starts here */ 5843# #define WIN32_LEAN_AND_MEAN 5844# #include <windows.h> 5845# #undef WIN32_LEAN_AND_MEAN 5846# #include <stdio.h> 5847# 5848# #ifndef __CYGWIN__ 5849# # ifdef __CYGWIN32__ 5850# # define __CYGWIN__ __CYGWIN32__ 5851# # endif 5852# #endif 5853# 5854# #ifdef __cplusplus 5855# extern "C" { 5856# #endif 5857# BOOL APIENTRY DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved); 5858# #ifdef __cplusplus 5859# } 5860# #endif 5861# 5862# #ifdef __CYGWIN__ 5863# #include <cygwin/cygwin_dll.h> 5864# DECLARE_CYGWIN_DLL( DllMain ); 5865# #endif 5866# HINSTANCE __hDllInstance_base; 5867# 5868# BOOL APIENTRY 5869# DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved) 5870# { 5871# __hDllInstance_base = hInst; 5872# return TRUE; 5873# } 5874# /* ltdll.c ends here */ 5875])# _LT_AC_FILE_LTDLL_C 5876 5877 5878# _LT_AC_TAGVAR(VARNAME, [TAGNAME]) 5879# --------------------------------- 5880AC_DEFUN([_LT_AC_TAGVAR], [ifelse([$2], [], [$1], [$1_$2])]) 5881 5882 5883# old names 5884AC_DEFUN([AM_PROG_LIBTOOL], [AC_PROG_LIBTOOL]) 5885AC_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)]) 5886AC_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)]) 5887AC_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)]) 5888AC_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)]) 5889AC_DEFUN([AM_PROG_LD], [AC_PROG_LD]) 5890AC_DEFUN([AM_PROG_NM], [AC_PROG_NM]) 5891 5892# This is just to silence aclocal about the macro not being used 5893ifelse([AC_DISABLE_FAST_INSTALL]) 5894 5895AC_DEFUN([LT_AC_PROG_GCJ], 5896[AC_CHECK_TOOL(GCJ, gcj, no) 5897 test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2" 5898 AC_SUBST(GCJFLAGS) 5899]) 5900 5901AC_DEFUN([LT_AC_PROG_RC], 5902[AC_CHECK_TOOL(RC, windres, no) 5903]) 5904 5905# NOTE: This macro has been submitted for inclusion into # 5906# GNU Autoconf as AC_PROG_SED. When it is available in # 5907# a released version of Autoconf we should remove this # 5908# macro and use it instead. # 5909# LT_AC_PROG_SED 5910# -------------- 5911# Check for a fully-functional sed program, that truncates 5912# as few characters as possible. Prefer GNU sed if found. 5913AC_DEFUN([LT_AC_PROG_SED], 5914[AC_MSG_CHECKING([for a sed that does not truncate output]) 5915AC_CACHE_VAL(lt_cv_path_SED, 5916[# Loop through the user's path and test for sed and gsed. 5917# Then use that list of sed's as ones to test for truncation. 5918as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5919for as_dir in $PATH 5920do 5921 IFS=$as_save_IFS 5922 test -z "$as_dir" && as_dir=. 5923 for lt_ac_prog in sed gsed; do 5924 for ac_exec_ext in '' $ac_executable_extensions; do 5925 if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then 5926 lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext" 5927 fi 5928 done 5929 done 5930done 5931lt_ac_max=0 5932lt_ac_count=0 5933# Add /usr/xpg4/bin/sed as it is typically found on Solaris 5934# along with /bin/sed that truncates output. 5935for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do 5936 test ! -f $lt_ac_sed && break 5937 cat /dev/null > conftest.in 5938 lt_ac_count=0 5939 echo $ECHO_N "0123456789$ECHO_C" >conftest.in 5940 # Check for GNU sed and select it if it is found. 5941 if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then 5942 lt_cv_path_SED=$lt_ac_sed 5943 break 5944 fi 5945 while true; do 5946 cat conftest.in conftest.in >conftest.tmp 5947 mv conftest.tmp conftest.in 5948 cp conftest.in conftest.nl 5949 echo >>conftest.nl 5950 $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break 5951 cmp -s conftest.out conftest.nl || break 5952 # 10000 chars as input seems more than enough 5953 test $lt_ac_count -gt 10 && break 5954 lt_ac_count=`expr $lt_ac_count + 1` 5955 if test $lt_ac_count -gt $lt_ac_max; then 5956 lt_ac_max=$lt_ac_count 5957 lt_cv_path_SED=$lt_ac_sed 5958 fi 5959 done 5960done 5961SED=$lt_cv_path_SED 5962]) 5963AC_MSG_RESULT([$SED]) 5964]) 5965 5966# -*- Autoconf -*- 5967# Copyright (C) 2002, 2003 Free Software Foundation, Inc. 5968# Generated from amversion.in; do not edit by hand. 5969 5970# This program is free software; you can redistribute it and/or modify 5971# it under the terms of the GNU General Public License as published by 5972# the Free Software Foundation; either version 2, or (at your option) 5973# any later version. 5974 5975# This program is distributed in the hope that it will be useful, 5976# but WITHOUT ANY WARRANTY; without even the implied warranty of 5977# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 5978# GNU General Public License for more details. 5979 5980# You should have received a copy of the GNU General Public License 5981# along with this program; if not, write to the Free Software 5982# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 5983 5984# AM_AUTOMAKE_VERSION(VERSION) 5985# ---------------------------- 5986# Automake X.Y traces this macro to ensure aclocal.m4 has been 5987# generated from the m4 files accompanying Automake X.Y. 5988AC_DEFUN([AM_AUTOMAKE_VERSION], [am__api_version="1.8"]) 5989 5990# AM_SET_CURRENT_AUTOMAKE_VERSION 5991# ------------------------------- 5992# Call AM_AUTOMAKE_VERSION so it can be traced. 5993# This function is AC_REQUIREd by AC_INIT_AUTOMAKE. 5994AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION], 5995 [AM_AUTOMAKE_VERSION([1.8.4])]) 5996 5997# AM_AUX_DIR_EXPAND 5998 5999# Copyright (C) 2001, 2003 Free Software Foundation, Inc. 6000 6001# This program is free software; you can redistribute it and/or modify 6002# it under the terms of the GNU General Public License as published by 6003# the Free Software Foundation; either version 2, or (at your option) 6004# any later version. 6005 6006# This program is distributed in the hope that it will be useful, 6007# but WITHOUT ANY WARRANTY; without even the implied warranty of 6008# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 6009# GNU General Public License for more details. 6010 6011# You should have received a copy of the GNU General Public License 6012# along with this program; if not, write to the Free Software 6013# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 6014# 02111-1307, USA. 6015 6016# For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets 6017# $ac_aux_dir to `$srcdir/foo'. In other projects, it is set to 6018# `$srcdir', `$srcdir/..', or `$srcdir/../..'. 6019# 6020# Of course, Automake must honor this variable whenever it calls a 6021# tool from the auxiliary directory. The problem is that $srcdir (and 6022# therefore $ac_aux_dir as well) can be either absolute or relative, 6023# depending on how configure is run. This is pretty annoying, since 6024# it makes $ac_aux_dir quite unusable in subdirectories: in the top 6025# source directory, any form will work fine, but in subdirectories a 6026# relative path needs to be adjusted first. 6027# 6028# $ac_aux_dir/missing 6029# fails when called from a subdirectory if $ac_aux_dir is relative 6030# $top_srcdir/$ac_aux_dir/missing 6031# fails if $ac_aux_dir is absolute, 6032# fails when called from a subdirectory in a VPATH build with 6033# a relative $ac_aux_dir 6034# 6035# The reason of the latter failure is that $top_srcdir and $ac_aux_dir 6036# are both prefixed by $srcdir. In an in-source build this is usually 6037# harmless because $srcdir is `.', but things will broke when you 6038# start a VPATH build or use an absolute $srcdir. 6039# 6040# So we could use something similar to $top_srcdir/$ac_aux_dir/missing, 6041# iff we strip the leading $srcdir from $ac_aux_dir. That would be: 6042# am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"` 6043# and then we would define $MISSING as 6044# MISSING="\${SHELL} $am_aux_dir/missing" 6045# This will work as long as MISSING is not called from configure, because 6046# unfortunately $(top_srcdir) has no meaning in configure. 6047# However there are other variables, like CC, which are often used in 6048# configure, and could therefore not use this "fixed" $ac_aux_dir. 6049# 6050# Another solution, used here, is to always expand $ac_aux_dir to an 6051# absolute PATH. The drawback is that using absolute paths prevent a 6052# configured tree to be moved without reconfiguration. 6053 6054AC_DEFUN([AM_AUX_DIR_EXPAND], 6055[dnl Rely on autoconf to set up CDPATH properly. 6056AC_PREREQ([2.50])dnl 6057# expand $ac_aux_dir to an absolute path 6058am_aux_dir=`cd $ac_aux_dir && pwd` 6059]) 6060 6061# AM_CONDITIONAL -*- Autoconf -*- 6062 6063# Copyright (C) 1997, 2000, 2001, 2003 Free Software Foundation, Inc. 6064 6065# This program is free software; you can redistribute it and/or modify 6066# it under the terms of the GNU General Public License as published by 6067# the Free Software Foundation; either version 2, or (at your option) 6068# any later version. 6069 6070# This program is distributed in the hope that it will be useful, 6071# but WITHOUT ANY WARRANTY; without even the implied warranty of 6072# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 6073# GNU General Public License for more details. 6074 6075# You should have received a copy of the GNU General Public License 6076# along with this program; if not, write to the Free Software 6077# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 6078# 02111-1307, USA. 6079 6080# serial 6 6081 6082# AM_CONDITIONAL(NAME, SHELL-CONDITION) 6083# ------------------------------------- 6084# Define a conditional. 6085AC_DEFUN([AM_CONDITIONAL], 6086[AC_PREREQ(2.52)dnl 6087 ifelse([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])], 6088 [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl 6089AC_SUBST([$1_TRUE]) 6090AC_SUBST([$1_FALSE]) 6091if $2; then 6092 $1_TRUE= 6093 $1_FALSE='#' 6094else 6095 $1_TRUE='#' 6096 $1_FALSE= 6097fi 6098AC_CONFIG_COMMANDS_PRE( 6099[if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then 6100 AC_MSG_ERROR([conditional "$1" was never defined. 6101Usually this means the macro was only invoked conditionally.]) 6102fi])]) 6103 6104# serial 7 -*- Autoconf -*- 6105 6106# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004 6107# Free Software Foundation, Inc. 6108 6109# This program is free software; you can redistribute it and/or modify 6110# it under the terms of the GNU General Public License as published by 6111# the Free Software Foundation; either version 2, or (at your option) 6112# any later version. 6113 6114# This program is distributed in the hope that it will be useful, 6115# but WITHOUT ANY WARRANTY; without even the implied warranty of 6116# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 6117# GNU General Public License for more details. 6118 6119# You should have received a copy of the GNU General Public License 6120# along with this program; if not, write to the Free Software 6121# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 6122# 02111-1307, USA. 6123 6124 6125# There are a few dirty hacks below to avoid letting `AC_PROG_CC' be 6126# written in clear, in which case automake, when reading aclocal.m4, 6127# will think it sees a *use*, and therefore will trigger all it's 6128# C support machinery. Also note that it means that autoscan, seeing 6129# CC etc. in the Makefile, will ask for an AC_PROG_CC use... 6130 6131 6132 6133# _AM_DEPENDENCIES(NAME) 6134# ---------------------- 6135# See how the compiler implements dependency checking. 6136# NAME is "CC", "CXX", "GCJ", or "OBJC". 6137# We try a few techniques and use that to set a single cache variable. 6138# 6139# We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was 6140# modified to invoke _AM_DEPENDENCIES(CC); we would have a circular 6141# dependency, and given that the user is not expected to run this macro, 6142# just rely on AC_PROG_CC. 6143AC_DEFUN([_AM_DEPENDENCIES], 6144[AC_REQUIRE([AM_SET_DEPDIR])dnl 6145AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl 6146AC_REQUIRE([AM_MAKE_INCLUDE])dnl 6147AC_REQUIRE([AM_DEP_TRACK])dnl 6148 6149ifelse([$1], CC, [depcc="$CC" am_compiler_list=], 6150 [$1], CXX, [depcc="$CXX" am_compiler_list=], 6151 [$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc'], 6152 [$1], GCJ, [depcc="$GCJ" am_compiler_list='gcc3 gcc'], 6153 [depcc="$$1" am_compiler_list=]) 6154 6155AC_CACHE_CHECK([dependency style of $depcc], 6156 [am_cv_$1_dependencies_compiler_type], 6157[if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then 6158 # We make a subdir and do the tests there. Otherwise we can end up 6159 # making bogus files that we don't know about and never remove. For 6160 # instance it was reported that on HP-UX the gcc test will end up 6161 # making a dummy file named `D' -- because `-MD' means `put the output 6162 # in D'. 6163 mkdir conftest.dir 6164 # Copy depcomp to subdir because otherwise we won't find it if we're 6165 # using a relative directory. 6166 cp "$am_depcomp" conftest.dir 6167 cd conftest.dir 6168 # We will build objects and dependencies in a subdirectory because 6169 # it helps to detect inapplicable dependency modes. For instance 6170 # both Tru64's cc and ICC support -MD to output dependencies as a 6171 # side effect of compilation, but ICC will put the dependencies in 6172 # the current directory while Tru64 will put them in the object 6173 # directory. 6174 mkdir sub 6175 6176 am_cv_$1_dependencies_compiler_type=none 6177 if test "$am_compiler_list" = ""; then 6178 am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp` 6179 fi 6180 for depmode in $am_compiler_list; do 6181 # Setup a source with many dependencies, because some compilers 6182 # like to wrap large dependency lists on column 80 (with \), and 6183 # we should not choose a depcomp mode which is confused by this. 6184 # 6185 # We need to recreate these files for each test, as the compiler may 6186 # overwrite some of them when testing with obscure command lines. 6187 # This happens at least with the AIX C compiler. 6188 : > sub/conftest.c 6189 for i in 1 2 3 4 5 6; do 6190 echo '#include "conftst'$i'.h"' >> sub/conftest.c 6191 # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with 6192 # Solaris 8's {/usr,}/bin/sh. 6193 touch sub/conftst$i.h 6194 done 6195 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf 6196 6197 case $depmode in 6198 nosideeffect) 6199 # after this tag, mechanisms are not by side-effect, so they'll 6200 # only be used when explicitly requested 6201 if test "x$enable_dependency_tracking" = xyes; then 6202 continue 6203 else 6204 break 6205 fi 6206 ;; 6207 none) break ;; 6208 esac 6209 # We check with `-c' and `-o' for the sake of the "dashmstdout" 6210 # mode. It turns out that the SunPro C++ compiler does not properly 6211 # handle `-M -o', and we need to detect this. 6212 if depmode=$depmode \ 6213 source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \ 6214 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ 6215 $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \ 6216 >/dev/null 2>conftest.err && 6217 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && 6218 grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 && 6219 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then 6220 # icc doesn't choke on unknown options, it will just issue warnings 6221 # or remarks (even with -Werror). So we grep stderr for any message 6222 # that says an option was ignored or not supported. 6223 # When given -MP, icc 7.0 and 7.1 complain thusly: 6224 # icc: Command line warning: ignoring option '-M'; no argument required 6225 # The diagnosis changed in icc 8.0: 6226 # icc: Command line remark: option '-MP' not supported 6227 if (grep 'ignoring option' conftest.err || 6228 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else 6229 am_cv_$1_dependencies_compiler_type=$depmode 6230 break 6231 fi 6232 fi 6233 done 6234 6235 cd .. 6236 rm -rf conftest.dir 6237else 6238 am_cv_$1_dependencies_compiler_type=none 6239fi 6240]) 6241AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type]) 6242AM_CONDITIONAL([am__fastdep$1], [ 6243 test "x$enable_dependency_tracking" != xno \ 6244 && test "$am_cv_$1_dependencies_compiler_type" = gcc3]) 6245]) 6246 6247 6248# AM_SET_DEPDIR 6249# ------------- 6250# Choose a directory name for dependency files. 6251# This macro is AC_REQUIREd in _AM_DEPENDENCIES 6252AC_DEFUN([AM_SET_DEPDIR], 6253[AC_REQUIRE([AM_SET_LEADING_DOT])dnl 6254AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl 6255]) 6256 6257 6258# AM_DEP_TRACK 6259# ------------ 6260AC_DEFUN([AM_DEP_TRACK], 6261[AC_ARG_ENABLE(dependency-tracking, 6262[ --disable-dependency-tracking speeds up one-time build 6263 --enable-dependency-tracking do not reject slow dependency extractors]) 6264if test "x$enable_dependency_tracking" != xno; then 6265 am_depcomp="$ac_aux_dir/depcomp" 6266 AMDEPBACKSLASH='\' 6267fi 6268AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno]) 6269AC_SUBST([AMDEPBACKSLASH]) 6270]) 6271 6272# Generate code to set up dependency tracking. -*- Autoconf -*- 6273 6274# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc. 6275 6276# This program is free software; you can redistribute it and/or modify 6277# it under the terms of the GNU General Public License as published by 6278# the Free Software Foundation; either version 2, or (at your option) 6279# any later version. 6280 6281# This program is distributed in the hope that it will be useful, 6282# but WITHOUT ANY WARRANTY; without even the implied warranty of 6283# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 6284# GNU General Public License for more details. 6285 6286# You should have received a copy of the GNU General Public License 6287# along with this program; if not, write to the Free Software 6288# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 6289# 02111-1307, USA. 6290 6291#serial 2 6292 6293# _AM_OUTPUT_DEPENDENCY_COMMANDS 6294# ------------------------------ 6295AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], 6296[for mf in $CONFIG_FILES; do 6297 # Strip MF so we end up with the name of the file. 6298 mf=`echo "$mf" | sed -e 's/:.*$//'` 6299 # Check whether this is an Automake generated Makefile or not. 6300 # We used to match only the files named `Makefile.in', but 6301 # some people rename them; so instead we look at the file content. 6302 # Grep'ing the first line is not enough: some people post-process 6303 # each Makefile.in and add a new line on top of each file to say so. 6304 # So let's grep whole file. 6305 if grep '^#.*generated by automake' $mf > /dev/null 2>&1; then 6306 dirpart=`AS_DIRNAME("$mf")` 6307 else 6308 continue 6309 fi 6310 grep '^DEP_FILES *= *[[^ @%:@]]' < "$mf" > /dev/null || continue 6311 # Extract the definition of DEP_FILES from the Makefile without 6312 # running `make'. 6313 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` 6314 test -z "$DEPDIR" && continue 6315 # When using ansi2knr, U may be empty or an underscore; expand it 6316 U=`sed -n 's/^U = //p' < "$mf"` 6317 test -d "$dirpart/$DEPDIR" || mkdir "$dirpart/$DEPDIR" 6318 # We invoke sed twice because it is the simplest approach to 6319 # changing $(DEPDIR) to its actual value in the expansion. 6320 for file in `sed -n ' 6321 /^DEP_FILES = .*\\\\$/ { 6322 s/^DEP_FILES = // 6323 :loop 6324 s/\\\\$// 6325 p 6326 n 6327 /\\\\$/ b loop 6328 p 6329 } 6330 /^DEP_FILES = / s/^DEP_FILES = //p' < "$mf" | \ 6331 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do 6332 # Make sure the directory exists. 6333 test -f "$dirpart/$file" && continue 6334 fdir=`AS_DIRNAME(["$file"])` 6335 AS_MKDIR_P([$dirpart/$fdir]) 6336 # echo "creating $dirpart/$file" 6337 echo '# dummy' > "$dirpart/$file" 6338 done 6339done 6340])# _AM_OUTPUT_DEPENDENCY_COMMANDS 6341 6342 6343# AM_OUTPUT_DEPENDENCY_COMMANDS 6344# ----------------------------- 6345# This macro should only be invoked once -- use via AC_REQUIRE. 6346# 6347# This code is only required when automatic dependency tracking 6348# is enabled. FIXME. This creates each `.P' file that we will 6349# need in order to bootstrap the dependency handling code. 6350AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS], 6351[AC_CONFIG_COMMANDS([depfiles], 6352 [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS], 6353 [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"]) 6354]) 6355 6356# Do all the work for Automake. -*- Autoconf -*- 6357 6358# This macro actually does too much some checks are only needed if 6359# your package does certain things. But this isn't really a big deal. 6360 6361# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003 6362# Free Software Foundation, Inc. 6363 6364# This program is free software; you can redistribute it and/or modify 6365# it under the terms of the GNU General Public License as published by 6366# the Free Software Foundation; either version 2, or (at your option) 6367# any later version. 6368 6369# This program is distributed in the hope that it will be useful, 6370# but WITHOUT ANY WARRANTY; without even the implied warranty of 6371# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 6372# GNU General Public License for more details. 6373 6374# You should have received a copy of the GNU General Public License 6375# along with this program; if not, write to the Free Software 6376# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 6377# 02111-1307, USA. 6378 6379# serial 11 6380 6381# AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE]) 6382# AM_INIT_AUTOMAKE([OPTIONS]) 6383# ----------------------------------------------- 6384# The call with PACKAGE and VERSION arguments is the old style 6385# call (pre autoconf-2.50), which is being phased out. PACKAGE 6386# and VERSION should now be passed to AC_INIT and removed from 6387# the call to AM_INIT_AUTOMAKE. 6388# We support both call styles for the transition. After 6389# the next Automake release, Autoconf can make the AC_INIT 6390# arguments mandatory, and then we can depend on a new Autoconf 6391# release and drop the old call support. 6392AC_DEFUN([AM_INIT_AUTOMAKE], 6393[AC_PREREQ([2.58])dnl 6394dnl Autoconf wants to disallow AM_ names. We explicitly allow 6395dnl the ones we care about. 6396m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl 6397AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl 6398AC_REQUIRE([AC_PROG_INSTALL])dnl 6399# test to see if srcdir already configured 6400if test "`cd $srcdir && pwd`" != "`pwd`" && 6401 test -f $srcdir/config.status; then 6402 AC_MSG_ERROR([source directory already configured; run "make distclean" there first]) 6403fi 6404 6405# test whether we have cygpath 6406if test -z "$CYGPATH_W"; then 6407 if (cygpath --version) >/dev/null 2>/dev/null; then 6408 CYGPATH_W='cygpath -w' 6409 else 6410 CYGPATH_W=echo 6411 fi 6412fi 6413AC_SUBST([CYGPATH_W]) 6414 6415# Define the identity of the package. 6416dnl Distinguish between old-style and new-style calls. 6417m4_ifval([$2], 6418[m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl 6419 AC_SUBST([PACKAGE], [$1])dnl 6420 AC_SUBST([VERSION], [$2])], 6421[_AM_SET_OPTIONS([$1])dnl 6422 AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl 6423 AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl 6424 6425_AM_IF_OPTION([no-define],, 6426[AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package]) 6427 AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl 6428 6429# Some tools Automake needs. 6430AC_REQUIRE([AM_SANITY_CHECK])dnl 6431AC_REQUIRE([AC_ARG_PROGRAM])dnl 6432AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version}) 6433AM_MISSING_PROG(AUTOCONF, autoconf) 6434AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version}) 6435AM_MISSING_PROG(AUTOHEADER, autoheader) 6436AM_MISSING_PROG(MAKEINFO, makeinfo) 6437AM_MISSING_PROG(AMTAR, tar) 6438AM_PROG_INSTALL_SH 6439AM_PROG_INSTALL_STRIP 6440AC_REQUIRE([AM_PROG_MKDIR_P])dnl 6441# We need awk for the "check" target. The system "awk" is bad on 6442# some platforms. 6443AC_REQUIRE([AC_PROG_AWK])dnl 6444AC_REQUIRE([AC_PROG_MAKE_SET])dnl 6445AC_REQUIRE([AM_SET_LEADING_DOT])dnl 6446 6447_AM_IF_OPTION([no-dependencies],, 6448[AC_PROVIDE_IFELSE([AC_PROG_CC], 6449 [_AM_DEPENDENCIES(CC)], 6450 [define([AC_PROG_CC], 6451 defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl 6452AC_PROVIDE_IFELSE([AC_PROG_CXX], 6453 [_AM_DEPENDENCIES(CXX)], 6454 [define([AC_PROG_CXX], 6455 defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl 6456]) 6457]) 6458 6459 6460# When config.status generates a header, we must update the stamp-h file. 6461# This file resides in the same directory as the config header 6462# that is generated. The stamp files are numbered to have different names. 6463 6464# Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the 6465# loop where config.status creates the headers, so we can generate 6466# our stamp files there. 6467AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK], 6468[# Compute $1's index in $config_headers. 6469_am_stamp_count=1 6470for _am_header in $config_headers :; do 6471 case $_am_header in 6472 $1 | $1:* ) 6473 break ;; 6474 * ) 6475 _am_stamp_count=`expr $_am_stamp_count + 1` ;; 6476 esac 6477done 6478echo "timestamp for $1" >`AS_DIRNAME([$1])`/stamp-h[]$_am_stamp_count]) 6479 6480# AM_PROG_INSTALL_SH 6481# ------------------ 6482# Define $install_sh. 6483 6484# Copyright (C) 2001, 2003 Free Software Foundation, Inc. 6485 6486# This program is free software; you can redistribute it and/or modify 6487# it under the terms of the GNU General Public License as published by 6488# the Free Software Foundation; either version 2, or (at your option) 6489# any later version. 6490 6491# This program is distributed in the hope that it will be useful, 6492# but WITHOUT ANY WARRANTY; without even the implied warranty of 6493# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 6494# GNU General Public License for more details. 6495 6496# You should have received a copy of the GNU General Public License 6497# along with this program; if not, write to the Free Software 6498# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 6499# 02111-1307, USA. 6500 6501AC_DEFUN([AM_PROG_INSTALL_SH], 6502[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl 6503install_sh=${install_sh-"$am_aux_dir/install-sh"} 6504AC_SUBST(install_sh)]) 6505 6506# -*- Autoconf -*- 6507# Copyright (C) 2003 Free Software Foundation, Inc. 6508 6509# This program is free software; you can redistribute it and/or modify 6510# it under the terms of the GNU General Public License as published by 6511# the Free Software Foundation; either version 2, or (at your option) 6512# any later version. 6513 6514# This program is distributed in the hope that it will be useful, 6515# but WITHOUT ANY WARRANTY; without even the implied warranty of 6516# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 6517# GNU General Public License for more details. 6518 6519# You should have received a copy of the GNU General Public License 6520# along with this program; if not, write to the Free Software 6521# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 6522# 02111-1307, USA. 6523 6524# serial 1 6525 6526# Check whether the underlying file-system supports filenames 6527# with a leading dot. For instance MS-DOS doesn't. 6528AC_DEFUN([AM_SET_LEADING_DOT], 6529[rm -rf .tst 2>/dev/null 6530mkdir .tst 2>/dev/null 6531if test -d .tst; then 6532 am__leading_dot=. 6533else 6534 am__leading_dot=_ 6535fi 6536rmdir .tst 2>/dev/null 6537AC_SUBST([am__leading_dot])]) 6538 6539# Check to see how 'make' treats includes. -*- Autoconf -*- 6540 6541# Copyright (C) 2001, 2002, 2003 Free Software Foundation, Inc. 6542 6543# This program is free software; you can redistribute it and/or modify 6544# it under the terms of the GNU General Public License as published by 6545# the Free Software Foundation; either version 2, or (at your option) 6546# any later version. 6547 6548# This program is distributed in the hope that it will be useful, 6549# but WITHOUT ANY WARRANTY; without even the implied warranty of 6550# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 6551# GNU General Public License for more details. 6552 6553# You should have received a copy of the GNU General Public License 6554# along with this program; if not, write to the Free Software 6555# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 6556# 02111-1307, USA. 6557 6558# serial 2 6559 6560# AM_MAKE_INCLUDE() 6561# ----------------- 6562# Check to see how make treats includes. 6563AC_DEFUN([AM_MAKE_INCLUDE], 6564[am_make=${MAKE-make} 6565cat > confinc << 'END' 6566am__doit: 6567 @echo done 6568.PHONY: am__doit 6569END 6570# If we don't find an include directive, just comment out the code. 6571AC_MSG_CHECKING([for style of include used by $am_make]) 6572am__include="#" 6573am__quote= 6574_am_result=none 6575# First try GNU make style include. 6576echo "include confinc" > confmf 6577# We grep out `Entering directory' and `Leaving directory' 6578# messages which can occur if `w' ends up in MAKEFLAGS. 6579# In particular we don't look at `^make:' because GNU make might 6580# be invoked under some other name (usually "gmake"), in which 6581# case it prints its new name instead of `make'. 6582if test "`$am_make -s -f confmf 2> /dev/null | grep -v 'ing directory'`" = "done"; then 6583 am__include=include 6584 am__quote= 6585 _am_result=GNU 6586fi 6587# Now try BSD make style include. 6588if test "$am__include" = "#"; then 6589 echo '.include "confinc"' > confmf 6590 if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then 6591 am__include=.include 6592 am__quote="\"" 6593 _am_result=BSD 6594 fi 6595fi 6596AC_SUBST([am__include]) 6597AC_SUBST([am__quote]) 6598AC_MSG_RESULT([$_am_result]) 6599rm -f confinc confmf 6600]) 6601 6602# -*- Autoconf -*- 6603 6604 6605# Copyright (C) 1997, 1999, 2000, 2001, 2003 Free Software Foundation, Inc. 6606 6607# This program is free software; you can redistribute it and/or modify 6608# it under the terms of the GNU General Public License as published by 6609# the Free Software Foundation; either version 2, or (at your option) 6610# any later version. 6611 6612# This program is distributed in the hope that it will be useful, 6613# but WITHOUT ANY WARRANTY; without even the implied warranty of 6614# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 6615# GNU General Public License for more details. 6616 6617# You should have received a copy of the GNU General Public License 6618# along with this program; if not, write to the Free Software 6619# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 6620# 02111-1307, USA. 6621 6622# serial 3 6623 6624# AM_MISSING_PROG(NAME, PROGRAM) 6625# ------------------------------ 6626AC_DEFUN([AM_MISSING_PROG], 6627[AC_REQUIRE([AM_MISSING_HAS_RUN]) 6628$1=${$1-"${am_missing_run}$2"} 6629AC_SUBST($1)]) 6630 6631 6632# AM_MISSING_HAS_RUN 6633# ------------------ 6634# Define MISSING if not defined so far and test if it supports --run. 6635# If it does, set am_missing_run to use it, otherwise, to nothing. 6636AC_DEFUN([AM_MISSING_HAS_RUN], 6637[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl 6638test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing" 6639# Use eval to expand $SHELL 6640if eval "$MISSING --run true"; then 6641 am_missing_run="$MISSING --run " 6642else 6643 am_missing_run= 6644 AC_MSG_WARN([`missing' script is too old or missing]) 6645fi 6646]) 6647 6648# AM_PROG_MKDIR_P 6649# --------------- 6650# Check whether `mkdir -p' is supported, fallback to mkinstalldirs otherwise. 6651 6652# Copyright (C) 2003, 2004 Free Software Foundation, Inc. 6653 6654# This program is free software; you can redistribute it and/or modify 6655# it under the terms of the GNU General Public License as published by 6656# the Free Software Foundation; either version 2, or (at your option) 6657# any later version. 6658 6659# This program is distributed in the hope that it will be useful, 6660# but WITHOUT ANY WARRANTY; without even the implied warranty of 6661# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 6662# GNU General Public License for more details. 6663 6664# You should have received a copy of the GNU General Public License 6665# along with this program; if not, write to the Free Software 6666# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 6667# 02111-1307, USA. 6668 6669# Automake 1.8 used `mkdir -m 0755 -p --' to ensure that directories 6670# created by `make install' are always world readable, even if the 6671# installer happens to have an overly restrictive umask (e.g. 077). 6672# This was a mistake. There are at least two reasons why we must not 6673# use `-m 0755': 6674# - it causes special bits like SGID to be ignored, 6675# - it may be too restrictive (some setups expect 775 directories). 6676# 6677# Do not use -m 0755 and let people choose whatever they expect by 6678# setting umask. 6679# 6680# We cannot accept any implementation of `mkdir' that recognizes `-p'. 6681# Some implementations (such as Solaris 8's) are not thread-safe: if a 6682# parallel make tries to run `mkdir -p a/b' and `mkdir -p a/c' 6683# concurrently, both version can detect that a/ is missing, but only 6684# one can create it and the other will error out. Consequently we 6685# restrict ourselves to GNU make (using the --version option ensures 6686# this.) 6687AC_DEFUN([AM_PROG_MKDIR_P], 6688[if mkdir -p --version . >/dev/null 2>&1 && test ! -d ./--version; then 6689 # Keeping the `.' argument allows $(mkdir_p) to be used without 6690 # argument. Indeed, we sometimes output rules like 6691 # $(mkdir_p) $(somedir) 6692 # where $(somedir) is conditionally defined. 6693 # (`test -n '$(somedir)' && $(mkdir_p) $(somedir)' is a more 6694 # expensive solution, as it forces Make to start a sub-shell.) 6695 mkdir_p='mkdir -p -- .' 6696else 6697 # On NextStep and OpenStep, the `mkdir' command does not 6698 # recognize any option. It will interpret all options as 6699 # directories to create, and then abort because `.' already 6700 # exists. 6701 for d in ./-p ./--version; 6702 do 6703 test -d $d && rmdir $d 6704 done 6705 # $(mkinstalldirs) is defined by Automake if mkinstalldirs exists. 6706 if test -f "$ac_aux_dir/mkinstalldirs"; then 6707 mkdir_p='$(mkinstalldirs)' 6708 else 6709 mkdir_p='$(install_sh) -d' 6710 fi 6711fi 6712AC_SUBST([mkdir_p])]) 6713 6714# Helper functions for option handling. -*- Autoconf -*- 6715 6716# Copyright (C) 2001, 2002, 2003 Free Software Foundation, Inc. 6717 6718# This program is free software; you can redistribute it and/or modify 6719# it under the terms of the GNU General Public License as published by 6720# the Free Software Foundation; either version 2, or (at your option) 6721# any later version. 6722 6723# This program is distributed in the hope that it will be useful, 6724# but WITHOUT ANY WARRANTY; without even the implied warranty of 6725# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 6726# GNU General Public License for more details. 6727 6728# You should have received a copy of the GNU General Public License 6729# along with this program; if not, write to the Free Software 6730# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 6731# 02111-1307, USA. 6732 6733# serial 2 6734 6735# _AM_MANGLE_OPTION(NAME) 6736# ----------------------- 6737AC_DEFUN([_AM_MANGLE_OPTION], 6738[[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])]) 6739 6740# _AM_SET_OPTION(NAME) 6741# ------------------------------ 6742# Set option NAME. Presently that only means defining a flag for this option. 6743AC_DEFUN([_AM_SET_OPTION], 6744[m4_define(_AM_MANGLE_OPTION([$1]), 1)]) 6745 6746# _AM_SET_OPTIONS(OPTIONS) 6747# ---------------------------------- 6748# OPTIONS is a space-separated list of Automake options. 6749AC_DEFUN([_AM_SET_OPTIONS], 6750[AC_FOREACH([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])]) 6751 6752# _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET]) 6753# ------------------------------------------- 6754# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. 6755AC_DEFUN([_AM_IF_OPTION], 6756[m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])]) 6757 6758# 6759# Check to make sure that the build environment is sane. 6760# 6761 6762# Copyright (C) 1996, 1997, 2000, 2001, 2003 Free Software Foundation, Inc. 6763 6764# This program is free software; you can redistribute it and/or modify 6765# it under the terms of the GNU General Public License as published by 6766# the Free Software Foundation; either version 2, or (at your option) 6767# any later version. 6768 6769# This program is distributed in the hope that it will be useful, 6770# but WITHOUT ANY WARRANTY; without even the implied warranty of 6771# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 6772# GNU General Public License for more details. 6773 6774# You should have received a copy of the GNU General Public License 6775# along with this program; if not, write to the Free Software 6776# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 6777# 02111-1307, USA. 6778 6779# serial 3 6780 6781# AM_SANITY_CHECK 6782# --------------- 6783AC_DEFUN([AM_SANITY_CHECK], 6784[AC_MSG_CHECKING([whether build environment is sane]) 6785# Just in case 6786sleep 1 6787echo timestamp > conftest.file 6788# Do `set' in a subshell so we don't clobber the current shell's 6789# arguments. Must try -L first in case configure is actually a 6790# symlink; some systems play weird games with the mod time of symlinks 6791# (eg FreeBSD returns the mod time of the symlink's containing 6792# directory). 6793if ( 6794 set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null` 6795 if test "$[*]" = "X"; then 6796 # -L didn't work. 6797 set X `ls -t $srcdir/configure conftest.file` 6798 fi 6799 rm -f conftest.file 6800 if test "$[*]" != "X $srcdir/configure conftest.file" \ 6801 && test "$[*]" != "X conftest.file $srcdir/configure"; then 6802 6803 # If neither matched, then we have a broken ls. This can happen 6804 # if, for instance, CONFIG_SHELL is bash and it inherits a 6805 # broken ls alias from the environment. This has actually 6806 # happened. Such a system could not be considered "sane". 6807 AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken 6808alias in your environment]) 6809 fi 6810 6811 test "$[2]" = conftest.file 6812 ) 6813then 6814 # Ok. 6815 : 6816else 6817 AC_MSG_ERROR([newly created file is older than distributed files! 6818Check your system clock]) 6819fi 6820AC_MSG_RESULT(yes)]) 6821 6822# AM_PROG_INSTALL_STRIP 6823 6824# Copyright (C) 2001, 2003 Free Software Foundation, Inc. 6825 6826# This program is free software; you can redistribute it and/or modify 6827# it under the terms of the GNU General Public License as published by 6828# the Free Software Foundation; either version 2, or (at your option) 6829# any later version. 6830 6831# This program is distributed in the hope that it will be useful, 6832# but WITHOUT ANY WARRANTY; without even the implied warranty of 6833# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 6834# GNU General Public License for more details. 6835 6836# You should have received a copy of the GNU General Public License 6837# along with this program; if not, write to the Free Software 6838# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 6839# 02111-1307, USA. 6840 6841# One issue with vendor `install' (even GNU) is that you can't 6842# specify the program used to strip binaries. This is especially 6843# annoying in cross-compiling environments, where the build's strip 6844# is unlikely to handle the host's binaries. 6845# Fortunately install-sh will honor a STRIPPROG variable, so we 6846# always use install-sh in `make install-strip', and initialize 6847# STRIPPROG with the value of the STRIP variable (set by the user). 6848AC_DEFUN([AM_PROG_INSTALL_STRIP], 6849[AC_REQUIRE([AM_PROG_INSTALL_SH])dnl 6850# Installed binaries are usually stripped using `strip' when the user 6851# run `make install-strip'. However `strip' might not be the right 6852# tool to use in cross-compilation environments, therefore Automake 6853# will honor the `STRIP' environment variable to overrule this program. 6854dnl Don't test for $cross_compiling = yes, because it might be `maybe'. 6855if test "$cross_compiling" != no; then 6856 AC_CHECK_TOOL([STRIP], [strip], :) 6857fi 6858INSTALL_STRIP_PROGRAM="\${SHELL} \$(install_sh) -c -s" 6859AC_SUBST([INSTALL_STRIP_PROGRAM])]) 6860 6861