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