aclocal.m4 revision b425557e
1# generated automatically by aclocal 1.11.1 -*- Autoconf -*- 2 3# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 4# 2005, 2006, 2007, 2008, 2009 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_ifndef([AC_AUTOCONF_VERSION], 15 [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl 16m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.68],, 17[m4_warning([this file was generated for autoconf 2.68. 18You have another version of autoconf. It may work, but is not guaranteed to. 19If you have problems, you may need to regenerate the build system entirely. 20To do so, use the procedure documented by the package, typically `autoreconf'.])]) 21 22# Copyright (C) 2002, 2003, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. 23# 24# This file is free software; the Free Software Foundation 25# gives unlimited permission to copy and/or distribute it, 26# with or without modifications, as long as this notice is preserved. 27 28# AM_AUTOMAKE_VERSION(VERSION) 29# ---------------------------- 30# Automake X.Y traces this macro to ensure aclocal.m4 has been 31# generated from the m4 files accompanying Automake X.Y. 32# (This private macro should not be called outside this file.) 33AC_DEFUN([AM_AUTOMAKE_VERSION], 34[am__api_version='1.11' 35dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to 36dnl require some minimum version. Point them to the right macro. 37m4_if([$1], [1.11.1], [], 38 [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl 39]) 40 41# _AM_AUTOCONF_VERSION(VERSION) 42# ----------------------------- 43# aclocal traces this macro to find the Autoconf version. 44# This is a private macro too. Using m4_define simplifies 45# the logic in aclocal, which can simply ignore this definition. 46m4_define([_AM_AUTOCONF_VERSION], []) 47 48# AM_SET_CURRENT_AUTOMAKE_VERSION 49# ------------------------------- 50# Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced. 51# This function is AC_REQUIREd by AM_INIT_AUTOMAKE. 52AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION], 53[AM_AUTOMAKE_VERSION([1.11.1])dnl 54m4_ifndef([AC_AUTOCONF_VERSION], 55 [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl 56_AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))]) 57 58# AM_AUX_DIR_EXPAND -*- Autoconf -*- 59 60# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. 61# 62# This file is free software; the Free Software Foundation 63# gives unlimited permission to copy and/or distribute it, 64# with or without modifications, as long as this notice is preserved. 65 66# For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets 67# $ac_aux_dir to `$srcdir/foo'. In other projects, it is set to 68# `$srcdir', `$srcdir/..', or `$srcdir/../..'. 69# 70# Of course, Automake must honor this variable whenever it calls a 71# tool from the auxiliary directory. The problem is that $srcdir (and 72# therefore $ac_aux_dir as well) can be either absolute or relative, 73# depending on how configure is run. This is pretty annoying, since 74# it makes $ac_aux_dir quite unusable in subdirectories: in the top 75# source directory, any form will work fine, but in subdirectories a 76# relative path needs to be adjusted first. 77# 78# $ac_aux_dir/missing 79# fails when called from a subdirectory if $ac_aux_dir is relative 80# $top_srcdir/$ac_aux_dir/missing 81# fails if $ac_aux_dir is absolute, 82# fails when called from a subdirectory in a VPATH build with 83# a relative $ac_aux_dir 84# 85# The reason of the latter failure is that $top_srcdir and $ac_aux_dir 86# are both prefixed by $srcdir. In an in-source build this is usually 87# harmless because $srcdir is `.', but things will broke when you 88# start a VPATH build or use an absolute $srcdir. 89# 90# So we could use something similar to $top_srcdir/$ac_aux_dir/missing, 91# iff we strip the leading $srcdir from $ac_aux_dir. That would be: 92# am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"` 93# and then we would define $MISSING as 94# MISSING="\${SHELL} $am_aux_dir/missing" 95# This will work as long as MISSING is not called from configure, because 96# unfortunately $(top_srcdir) has no meaning in configure. 97# However there are other variables, like CC, which are often used in 98# configure, and could therefore not use this "fixed" $ac_aux_dir. 99# 100# Another solution, used here, is to always expand $ac_aux_dir to an 101# absolute PATH. The drawback is that using absolute paths prevent a 102# configured tree to be moved without reconfiguration. 103 104AC_DEFUN([AM_AUX_DIR_EXPAND], 105[dnl Rely on autoconf to set up CDPATH properly. 106AC_PREREQ([2.50])dnl 107# expand $ac_aux_dir to an absolute path 108am_aux_dir=`cd $ac_aux_dir && pwd` 109]) 110 111# AM_CONDITIONAL -*- Autoconf -*- 112 113# Copyright (C) 1997, 2000, 2001, 2003, 2004, 2005, 2006, 2008 114# Free Software Foundation, Inc. 115# 116# This file is free software; the Free Software Foundation 117# gives unlimited permission to copy and/or distribute it, 118# with or without modifications, as long as this notice is preserved. 119 120# serial 9 121 122# AM_CONDITIONAL(NAME, SHELL-CONDITION) 123# ------------------------------------- 124# Define a conditional. 125AC_DEFUN([AM_CONDITIONAL], 126[AC_PREREQ(2.52)dnl 127 ifelse([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])], 128 [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl 129AC_SUBST([$1_TRUE])dnl 130AC_SUBST([$1_FALSE])dnl 131_AM_SUBST_NOTMAKE([$1_TRUE])dnl 132_AM_SUBST_NOTMAKE([$1_FALSE])dnl 133m4_define([_AM_COND_VALUE_$1], [$2])dnl 134if $2; then 135 $1_TRUE= 136 $1_FALSE='#' 137else 138 $1_TRUE='#' 139 $1_FALSE= 140fi 141AC_CONFIG_COMMANDS_PRE( 142[if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then 143 AC_MSG_ERROR([[conditional "$1" was never defined. 144Usually this means the macro was only invoked conditionally.]]) 145fi])]) 146 147# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2009 148# Free Software Foundation, Inc. 149# 150# This file is free software; the Free Software Foundation 151# gives unlimited permission to copy and/or distribute it, 152# with or without modifications, as long as this notice is preserved. 153 154# serial 10 155 156# There are a few dirty hacks below to avoid letting `AC_PROG_CC' be 157# written in clear, in which case automake, when reading aclocal.m4, 158# will think it sees a *use*, and therefore will trigger all it's 159# C support machinery. Also note that it means that autoscan, seeing 160# CC etc. in the Makefile, will ask for an AC_PROG_CC use... 161 162 163# _AM_DEPENDENCIES(NAME) 164# ---------------------- 165# See how the compiler implements dependency checking. 166# NAME is "CC", "CXX", "GCJ", or "OBJC". 167# We try a few techniques and use that to set a single cache variable. 168# 169# We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was 170# modified to invoke _AM_DEPENDENCIES(CC); we would have a circular 171# dependency, and given that the user is not expected to run this macro, 172# just rely on AC_PROG_CC. 173AC_DEFUN([_AM_DEPENDENCIES], 174[AC_REQUIRE([AM_SET_DEPDIR])dnl 175AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl 176AC_REQUIRE([AM_MAKE_INCLUDE])dnl 177AC_REQUIRE([AM_DEP_TRACK])dnl 178 179ifelse([$1], CC, [depcc="$CC" am_compiler_list=], 180 [$1], CXX, [depcc="$CXX" am_compiler_list=], 181 [$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc'], 182 [$1], UPC, [depcc="$UPC" am_compiler_list=], 183 [$1], GCJ, [depcc="$GCJ" am_compiler_list='gcc3 gcc'], 184 [depcc="$$1" am_compiler_list=]) 185 186AC_CACHE_CHECK([dependency style of $depcc], 187 [am_cv_$1_dependencies_compiler_type], 188[if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then 189 # We make a subdir and do the tests there. Otherwise we can end up 190 # making bogus files that we don't know about and never remove. For 191 # instance it was reported that on HP-UX the gcc test will end up 192 # making a dummy file named `D' -- because `-MD' means `put the output 193 # in D'. 194 mkdir conftest.dir 195 # Copy depcomp to subdir because otherwise we won't find it if we're 196 # using a relative directory. 197 cp "$am_depcomp" conftest.dir 198 cd conftest.dir 199 # We will build objects and dependencies in a subdirectory because 200 # it helps to detect inapplicable dependency modes. For instance 201 # both Tru64's cc and ICC support -MD to output dependencies as a 202 # side effect of compilation, but ICC will put the dependencies in 203 # the current directory while Tru64 will put them in the object 204 # directory. 205 mkdir sub 206 207 am_cv_$1_dependencies_compiler_type=none 208 if test "$am_compiler_list" = ""; then 209 am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp` 210 fi 211 am__universal=false 212 m4_case([$1], [CC], 213 [case " $depcc " in #( 214 *\ -arch\ *\ -arch\ *) am__universal=true ;; 215 esac], 216 [CXX], 217 [case " $depcc " in #( 218 *\ -arch\ *\ -arch\ *) am__universal=true ;; 219 esac]) 220 221 for depmode in $am_compiler_list; do 222 # Setup a source with many dependencies, because some compilers 223 # like to wrap large dependency lists on column 80 (with \), and 224 # we should not choose a depcomp mode which is confused by this. 225 # 226 # We need to recreate these files for each test, as the compiler may 227 # overwrite some of them when testing with obscure command lines. 228 # This happens at least with the AIX C compiler. 229 : > sub/conftest.c 230 for i in 1 2 3 4 5 6; do 231 echo '#include "conftst'$i'.h"' >> sub/conftest.c 232 # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with 233 # Solaris 8's {/usr,}/bin/sh. 234 touch sub/conftst$i.h 235 done 236 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf 237 238 # We check with `-c' and `-o' for the sake of the "dashmstdout" 239 # mode. It turns out that the SunPro C++ compiler does not properly 240 # handle `-M -o', and we need to detect this. Also, some Intel 241 # versions had trouble with output in subdirs 242 am__obj=sub/conftest.${OBJEXT-o} 243 am__minus_obj="-o $am__obj" 244 case $depmode in 245 gcc) 246 # This depmode causes a compiler race in universal mode. 247 test "$am__universal" = false || continue 248 ;; 249 nosideeffect) 250 # after this tag, mechanisms are not by side-effect, so they'll 251 # only be used when explicitly requested 252 if test "x$enable_dependency_tracking" = xyes; then 253 continue 254 else 255 break 256 fi 257 ;; 258 msvisualcpp | msvcmsys) 259 # This compiler won't grok `-c -o', but also, the minuso test has 260 # not run yet. These depmodes are late enough in the game, and 261 # so weak that their functioning should not be impacted. 262 am__obj=conftest.${OBJEXT-o} 263 am__minus_obj= 264 ;; 265 none) break ;; 266 esac 267 if depmode=$depmode \ 268 source=sub/conftest.c object=$am__obj \ 269 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ 270 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ 271 >/dev/null 2>conftest.err && 272 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && 273 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && 274 grep $am__obj sub/conftest.Po > /dev/null 2>&1 && 275 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then 276 # icc doesn't choke on unknown options, it will just issue warnings 277 # or remarks (even with -Werror). So we grep stderr for any message 278 # that says an option was ignored or not supported. 279 # When given -MP, icc 7.0 and 7.1 complain thusly: 280 # icc: Command line warning: ignoring option '-M'; no argument required 281 # The diagnosis changed in icc 8.0: 282 # icc: Command line remark: option '-MP' not supported 283 if (grep 'ignoring option' conftest.err || 284 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else 285 am_cv_$1_dependencies_compiler_type=$depmode 286 break 287 fi 288 fi 289 done 290 291 cd .. 292 rm -rf conftest.dir 293else 294 am_cv_$1_dependencies_compiler_type=none 295fi 296]) 297AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type]) 298AM_CONDITIONAL([am__fastdep$1], [ 299 test "x$enable_dependency_tracking" != xno \ 300 && test "$am_cv_$1_dependencies_compiler_type" = gcc3]) 301]) 302 303 304# AM_SET_DEPDIR 305# ------------- 306# Choose a directory name for dependency files. 307# This macro is AC_REQUIREd in _AM_DEPENDENCIES 308AC_DEFUN([AM_SET_DEPDIR], 309[AC_REQUIRE([AM_SET_LEADING_DOT])dnl 310AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl 311]) 312 313 314# AM_DEP_TRACK 315# ------------ 316AC_DEFUN([AM_DEP_TRACK], 317[AC_ARG_ENABLE(dependency-tracking, 318[ --disable-dependency-tracking speeds up one-time build 319 --enable-dependency-tracking do not reject slow dependency extractors]) 320if test "x$enable_dependency_tracking" != xno; then 321 am_depcomp="$ac_aux_dir/depcomp" 322 AMDEPBACKSLASH='\' 323fi 324AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno]) 325AC_SUBST([AMDEPBACKSLASH])dnl 326_AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl 327]) 328 329# Generate code to set up dependency tracking. -*- Autoconf -*- 330 331# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2008 332# Free Software Foundation, Inc. 333# 334# This file is free software; the Free Software Foundation 335# gives unlimited permission to copy and/or distribute it, 336# with or without modifications, as long as this notice is preserved. 337 338#serial 5 339 340# _AM_OUTPUT_DEPENDENCY_COMMANDS 341# ------------------------------ 342AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], 343[{ 344 # Autoconf 2.62 quotes --file arguments for eval, but not when files 345 # are listed without --file. Let's play safe and only enable the eval 346 # if we detect the quoting. 347 case $CONFIG_FILES in 348 *\'*) eval set x "$CONFIG_FILES" ;; 349 *) set x $CONFIG_FILES ;; 350 esac 351 shift 352 for mf 353 do 354 # Strip MF so we end up with the name of the file. 355 mf=`echo "$mf" | sed -e 's/:.*$//'` 356 # Check whether this is an Automake generated Makefile or not. 357 # We used to match only the files named `Makefile.in', but 358 # some people rename them; so instead we look at the file content. 359 # Grep'ing the first line is not enough: some people post-process 360 # each Makefile.in and add a new line on top of each file to say so. 361 # Grep'ing the whole file is not good either: AIX grep has a line 362 # limit of 2048, but all sed's we know have understand at least 4000. 363 if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then 364 dirpart=`AS_DIRNAME("$mf")` 365 else 366 continue 367 fi 368 # Extract the definition of DEPDIR, am__include, and am__quote 369 # from the Makefile without running `make'. 370 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` 371 test -z "$DEPDIR" && continue 372 am__include=`sed -n 's/^am__include = //p' < "$mf"` 373 test -z "am__include" && continue 374 am__quote=`sed -n 's/^am__quote = //p' < "$mf"` 375 # When using ansi2knr, U may be empty or an underscore; expand it 376 U=`sed -n 's/^U = //p' < "$mf"` 377 # Find all dependency output files, they are included files with 378 # $(DEPDIR) in their names. We invoke sed twice because it is the 379 # simplest approach to changing $(DEPDIR) to its actual value in the 380 # expansion. 381 for file in `sed -n " 382 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ 383 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do 384 # Make sure the directory exists. 385 test -f "$dirpart/$file" && continue 386 fdir=`AS_DIRNAME(["$file"])` 387 AS_MKDIR_P([$dirpart/$fdir]) 388 # echo "creating $dirpart/$file" 389 echo '# dummy' > "$dirpart/$file" 390 done 391 done 392} 393])# _AM_OUTPUT_DEPENDENCY_COMMANDS 394 395 396# AM_OUTPUT_DEPENDENCY_COMMANDS 397# ----------------------------- 398# This macro should only be invoked once -- use via AC_REQUIRE. 399# 400# This code is only required when automatic dependency tracking 401# is enabled. FIXME. This creates each `.P' file that we will 402# need in order to bootstrap the dependency handling code. 403AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS], 404[AC_CONFIG_COMMANDS([depfiles], 405 [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS], 406 [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"]) 407]) 408 409# Do all the work for Automake. -*- Autoconf -*- 410 411# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 412# 2005, 2006, 2008, 2009 Free Software Foundation, Inc. 413# 414# This file is free software; the Free Software Foundation 415# gives unlimited permission to copy and/or distribute it, 416# with or without modifications, as long as this notice is preserved. 417 418# serial 16 419 420# This macro actually does too much. Some checks are only needed if 421# your package does certain things. But this isn't really a big deal. 422 423# AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE]) 424# AM_INIT_AUTOMAKE([OPTIONS]) 425# ----------------------------------------------- 426# The call with PACKAGE and VERSION arguments is the old style 427# call (pre autoconf-2.50), which is being phased out. PACKAGE 428# and VERSION should now be passed to AC_INIT and removed from 429# the call to AM_INIT_AUTOMAKE. 430# We support both call styles for the transition. After 431# the next Automake release, Autoconf can make the AC_INIT 432# arguments mandatory, and then we can depend on a new Autoconf 433# release and drop the old call support. 434AC_DEFUN([AM_INIT_AUTOMAKE], 435[AC_PREREQ([2.62])dnl 436dnl Autoconf wants to disallow AM_ names. We explicitly allow 437dnl the ones we care about. 438m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl 439AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl 440AC_REQUIRE([AC_PROG_INSTALL])dnl 441if test "`cd $srcdir && pwd`" != "`pwd`"; then 442 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output 443 # is not polluted with repeated "-I." 444 AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl 445 # test to see if srcdir already configured 446 if test -f $srcdir/config.status; then 447 AC_MSG_ERROR([source directory already configured; run "make distclean" there first]) 448 fi 449fi 450 451# test whether we have cygpath 452if test -z "$CYGPATH_W"; then 453 if (cygpath --version) >/dev/null 2>/dev/null; then 454 CYGPATH_W='cygpath -w' 455 else 456 CYGPATH_W=echo 457 fi 458fi 459AC_SUBST([CYGPATH_W]) 460 461# Define the identity of the package. 462dnl Distinguish between old-style and new-style calls. 463m4_ifval([$2], 464[m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl 465 AC_SUBST([PACKAGE], [$1])dnl 466 AC_SUBST([VERSION], [$2])], 467[_AM_SET_OPTIONS([$1])dnl 468dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT. 469m4_if(m4_ifdef([AC_PACKAGE_NAME], 1)m4_ifdef([AC_PACKAGE_VERSION], 1), 11,, 470 [m4_fatal([AC_INIT should be called with package and version arguments])])dnl 471 AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl 472 AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl 473 474_AM_IF_OPTION([no-define],, 475[AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package]) 476 AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl 477 478# Some tools Automake needs. 479AC_REQUIRE([AM_SANITY_CHECK])dnl 480AC_REQUIRE([AC_ARG_PROGRAM])dnl 481AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version}) 482AM_MISSING_PROG(AUTOCONF, autoconf) 483AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version}) 484AM_MISSING_PROG(AUTOHEADER, autoheader) 485AM_MISSING_PROG(MAKEINFO, makeinfo) 486AC_REQUIRE([AM_PROG_INSTALL_SH])dnl 487AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl 488AC_REQUIRE([AM_PROG_MKDIR_P])dnl 489# We need awk for the "check" target. The system "awk" is bad on 490# some platforms. 491AC_REQUIRE([AC_PROG_AWK])dnl 492AC_REQUIRE([AC_PROG_MAKE_SET])dnl 493AC_REQUIRE([AM_SET_LEADING_DOT])dnl 494_AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])], 495 [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])], 496 [_AM_PROG_TAR([v7])])]) 497_AM_IF_OPTION([no-dependencies],, 498[AC_PROVIDE_IFELSE([AC_PROG_CC], 499 [_AM_DEPENDENCIES(CC)], 500 [define([AC_PROG_CC], 501 defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl 502AC_PROVIDE_IFELSE([AC_PROG_CXX], 503 [_AM_DEPENDENCIES(CXX)], 504 [define([AC_PROG_CXX], 505 defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl 506AC_PROVIDE_IFELSE([AC_PROG_OBJC], 507 [_AM_DEPENDENCIES(OBJC)], 508 [define([AC_PROG_OBJC], 509 defn([AC_PROG_OBJC])[_AM_DEPENDENCIES(OBJC)])])dnl 510]) 511_AM_IF_OPTION([silent-rules], [AC_REQUIRE([AM_SILENT_RULES])])dnl 512dnl The `parallel-tests' driver may need to know about EXEEXT, so add the 513dnl `am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This macro 514dnl is hooked onto _AC_COMPILER_EXEEXT early, see below. 515AC_CONFIG_COMMANDS_PRE(dnl 516[m4_provide_if([_AM_COMPILER_EXEEXT], 517 [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl 518]) 519 520dnl Hook into `_AC_COMPILER_EXEEXT' early to learn its expansion. Do not 521dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further 522dnl mangled by Autoconf and run in a shell conditional statement. 523m4_define([_AC_COMPILER_EXEEXT], 524m4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])]) 525 526 527# When config.status generates a header, we must update the stamp-h file. 528# This file resides in the same directory as the config header 529# that is generated. The stamp files are numbered to have different names. 530 531# Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the 532# loop where config.status creates the headers, so we can generate 533# our stamp files there. 534AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK], 535[# Compute $1's index in $config_headers. 536_am_arg=$1 537_am_stamp_count=1 538for _am_header in $config_headers :; do 539 case $_am_header in 540 $_am_arg | $_am_arg:* ) 541 break ;; 542 * ) 543 _am_stamp_count=`expr $_am_stamp_count + 1` ;; 544 esac 545done 546echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count]) 547 548# Copyright (C) 2001, 2003, 2005, 2008 Free Software Foundation, Inc. 549# 550# This file is free software; the Free Software Foundation 551# gives unlimited permission to copy and/or distribute it, 552# with or without modifications, as long as this notice is preserved. 553 554# AM_PROG_INSTALL_SH 555# ------------------ 556# Define $install_sh. 557AC_DEFUN([AM_PROG_INSTALL_SH], 558[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl 559if test x"${install_sh}" != xset; then 560 case $am_aux_dir in 561 *\ * | *\ *) 562 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;; 563 *) 564 install_sh="\${SHELL} $am_aux_dir/install-sh" 565 esac 566fi 567AC_SUBST(install_sh)]) 568 569# Copyright (C) 2003, 2005 Free Software Foundation, Inc. 570# 571# This file is free software; the Free Software Foundation 572# gives unlimited permission to copy and/or distribute it, 573# with or without modifications, as long as this notice is preserved. 574 575# serial 2 576 577# Check whether the underlying file-system supports filenames 578# with a leading dot. For instance MS-DOS doesn't. 579AC_DEFUN([AM_SET_LEADING_DOT], 580[rm -rf .tst 2>/dev/null 581mkdir .tst 2>/dev/null 582if test -d .tst; then 583 am__leading_dot=. 584else 585 am__leading_dot=_ 586fi 587rmdir .tst 2>/dev/null 588AC_SUBST([am__leading_dot])]) 589 590# Add --enable-maintainer-mode option to configure. -*- Autoconf -*- 591# From Jim Meyering 592 593# Copyright (C) 1996, 1998, 2000, 2001, 2002, 2003, 2004, 2005, 2008 594# Free Software Foundation, Inc. 595# 596# This file is free software; the Free Software Foundation 597# gives unlimited permission to copy and/or distribute it, 598# with or without modifications, as long as this notice is preserved. 599 600# serial 5 601 602# AM_MAINTAINER_MODE([DEFAULT-MODE]) 603# ---------------------------------- 604# Control maintainer-specific portions of Makefiles. 605# Default is to disable them, unless `enable' is passed literally. 606# For symmetry, `disable' may be passed as well. Anyway, the user 607# can override the default with the --enable/--disable switch. 608AC_DEFUN([AM_MAINTAINER_MODE], 609[m4_case(m4_default([$1], [disable]), 610 [enable], [m4_define([am_maintainer_other], [disable])], 611 [disable], [m4_define([am_maintainer_other], [enable])], 612 [m4_define([am_maintainer_other], [enable]) 613 m4_warn([syntax], [unexpected argument to AM@&t@_MAINTAINER_MODE: $1])]) 614AC_MSG_CHECKING([whether to am_maintainer_other maintainer-specific portions of Makefiles]) 615 dnl maintainer-mode's default is 'disable' unless 'enable' is passed 616 AC_ARG_ENABLE([maintainer-mode], 617[ --][am_maintainer_other][-maintainer-mode am_maintainer_other make rules and dependencies not useful 618 (and sometimes confusing) to the casual installer], 619 [USE_MAINTAINER_MODE=$enableval], 620 [USE_MAINTAINER_MODE=]m4_if(am_maintainer_other, [enable], [no], [yes])) 621 AC_MSG_RESULT([$USE_MAINTAINER_MODE]) 622 AM_CONDITIONAL([MAINTAINER_MODE], [test $USE_MAINTAINER_MODE = yes]) 623 MAINT=$MAINTAINER_MODE_TRUE 624 AC_SUBST([MAINT])dnl 625] 626) 627 628AU_DEFUN([jm_MAINTAINER_MODE], [AM_MAINTAINER_MODE]) 629 630# Check to see how 'make' treats includes. -*- Autoconf -*- 631 632# Copyright (C) 2001, 2002, 2003, 2005, 2009 Free Software Foundation, Inc. 633# 634# This file is free software; the Free Software Foundation 635# gives unlimited permission to copy and/or distribute it, 636# with or without modifications, as long as this notice is preserved. 637 638# serial 4 639 640# AM_MAKE_INCLUDE() 641# ----------------- 642# Check to see how make treats includes. 643AC_DEFUN([AM_MAKE_INCLUDE], 644[am_make=${MAKE-make} 645cat > confinc << 'END' 646am__doit: 647 @echo this is the am__doit target 648.PHONY: am__doit 649END 650# If we don't find an include directive, just comment out the code. 651AC_MSG_CHECKING([for style of include used by $am_make]) 652am__include="#" 653am__quote= 654_am_result=none 655# First try GNU make style include. 656echo "include confinc" > confmf 657# Ignore all kinds of additional output from `make'. 658case `$am_make -s -f confmf 2> /dev/null` in #( 659*the\ am__doit\ target*) 660 am__include=include 661 am__quote= 662 _am_result=GNU 663 ;; 664esac 665# Now try BSD make style include. 666if test "$am__include" = "#"; then 667 echo '.include "confinc"' > confmf 668 case `$am_make -s -f confmf 2> /dev/null` in #( 669 *the\ am__doit\ target*) 670 am__include=.include 671 am__quote="\"" 672 _am_result=BSD 673 ;; 674 esac 675fi 676AC_SUBST([am__include]) 677AC_SUBST([am__quote]) 678AC_MSG_RESULT([$_am_result]) 679rm -f confinc confmf 680]) 681 682# Fake the existence of programs that GNU maintainers use. -*- Autoconf -*- 683 684# Copyright (C) 1997, 1999, 2000, 2001, 2003, 2004, 2005, 2008 685# 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 6 692 693# AM_MISSING_PROG(NAME, PROGRAM) 694# ------------------------------ 695AC_DEFUN([AM_MISSING_PROG], 696[AC_REQUIRE([AM_MISSING_HAS_RUN]) 697$1=${$1-"${am_missing_run}$2"} 698AC_SUBST($1)]) 699 700 701# AM_MISSING_HAS_RUN 702# ------------------ 703# Define MISSING if not defined so far and test if it supports --run. 704# If it does, set am_missing_run to use it, otherwise, to nothing. 705AC_DEFUN([AM_MISSING_HAS_RUN], 706[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl 707AC_REQUIRE_AUX_FILE([missing])dnl 708if test x"${MISSING+set}" != xset; then 709 case $am_aux_dir in 710 *\ * | *\ *) 711 MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;; 712 *) 713 MISSING="\${SHELL} $am_aux_dir/missing" ;; 714 esac 715fi 716# Use eval to expand $SHELL 717if eval "$MISSING --run true"; then 718 am_missing_run="$MISSING --run " 719else 720 am_missing_run= 721 AC_MSG_WARN([`missing' script is too old or missing]) 722fi 723]) 724 725# Copyright (C) 2003, 2004, 2005, 2006 Free Software Foundation, Inc. 726# 727# This file is free software; the Free Software Foundation 728# gives unlimited permission to copy and/or distribute it, 729# with or without modifications, as long as this notice is preserved. 730 731# AM_PROG_MKDIR_P 732# --------------- 733# Check for `mkdir -p'. 734AC_DEFUN([AM_PROG_MKDIR_P], 735[AC_PREREQ([2.60])dnl 736AC_REQUIRE([AC_PROG_MKDIR_P])dnl 737dnl Automake 1.8 to 1.9.6 used to define mkdir_p. We now use MKDIR_P, 738dnl while keeping a definition of mkdir_p for backward compatibility. 739dnl @MKDIR_P@ is magic: AC_OUTPUT adjusts its value for each Makefile. 740dnl However we cannot define mkdir_p as $(MKDIR_P) for the sake of 741dnl Makefile.ins that do not define MKDIR_P, so we do our own 742dnl adjustment using top_builddir (which is defined more often than 743dnl MKDIR_P). 744AC_SUBST([mkdir_p], ["$MKDIR_P"])dnl 745case $mkdir_p in 746 [[\\/$]]* | ?:[[\\/]]*) ;; 747 */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;; 748esac 749]) 750 751# Helper functions for option handling. -*- Autoconf -*- 752 753# Copyright (C) 2001, 2002, 2003, 2005, 2008 Free Software Foundation, Inc. 754# 755# This file is free software; the Free Software Foundation 756# gives unlimited permission to copy and/or distribute it, 757# with or without modifications, as long as this notice is preserved. 758 759# serial 4 760 761# _AM_MANGLE_OPTION(NAME) 762# ----------------------- 763AC_DEFUN([_AM_MANGLE_OPTION], 764[[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])]) 765 766# _AM_SET_OPTION(NAME) 767# ------------------------------ 768# Set option NAME. Presently that only means defining a flag for this option. 769AC_DEFUN([_AM_SET_OPTION], 770[m4_define(_AM_MANGLE_OPTION([$1]), 1)]) 771 772# _AM_SET_OPTIONS(OPTIONS) 773# ---------------------------------- 774# OPTIONS is a space-separated list of Automake options. 775AC_DEFUN([_AM_SET_OPTIONS], 776[m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])]) 777 778# _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET]) 779# ------------------------------------------- 780# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. 781AC_DEFUN([_AM_IF_OPTION], 782[m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])]) 783 784# Check to make sure that the build environment is sane. -*- Autoconf -*- 785 786# Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005, 2008 787# Free Software Foundation, Inc. 788# 789# This file is free software; the Free Software Foundation 790# gives unlimited permission to copy and/or distribute it, 791# with or without modifications, as long as this notice is preserved. 792 793# serial 5 794 795# AM_SANITY_CHECK 796# --------------- 797AC_DEFUN([AM_SANITY_CHECK], 798[AC_MSG_CHECKING([whether build environment is sane]) 799# Just in case 800sleep 1 801echo timestamp > conftest.file 802# Reject unsafe characters in $srcdir or the absolute working directory 803# name. Accept space and tab only in the latter. 804am_lf=' 805' 806case `pwd` in 807 *[[\\\"\#\$\&\'\`$am_lf]]*) 808 AC_MSG_ERROR([unsafe absolute working directory name]);; 809esac 810case $srcdir in 811 *[[\\\"\#\$\&\'\`$am_lf\ \ ]]*) 812 AC_MSG_ERROR([unsafe srcdir value: `$srcdir']);; 813esac 814 815# Do `set' in a subshell so we don't clobber the current shell's 816# arguments. Must try -L first in case configure is actually a 817# symlink; some systems play weird games with the mod time of symlinks 818# (eg FreeBSD returns the mod time of the symlink's containing 819# directory). 820if ( 821 set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` 822 if test "$[*]" = "X"; then 823 # -L didn't work. 824 set X `ls -t "$srcdir/configure" conftest.file` 825 fi 826 rm -f conftest.file 827 if test "$[*]" != "X $srcdir/configure conftest.file" \ 828 && test "$[*]" != "X conftest.file $srcdir/configure"; then 829 830 # If neither matched, then we have a broken ls. This can happen 831 # if, for instance, CONFIG_SHELL is bash and it inherits a 832 # broken ls alias from the environment. This has actually 833 # happened. Such a system could not be considered "sane". 834 AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken 835alias in your environment]) 836 fi 837 838 test "$[2]" = conftest.file 839 ) 840then 841 # Ok. 842 : 843else 844 AC_MSG_ERROR([newly created file is older than distributed files! 845Check your system clock]) 846fi 847AC_MSG_RESULT(yes)]) 848 849# Copyright (C) 2009 Free Software Foundation, Inc. 850# 851# This file is free software; the Free Software Foundation 852# gives unlimited permission to copy and/or distribute it, 853# with or without modifications, as long as this notice is preserved. 854 855# serial 1 856 857# AM_SILENT_RULES([DEFAULT]) 858# -------------------------- 859# Enable less verbose build rules; with the default set to DEFAULT 860# (`yes' being less verbose, `no' or empty being verbose). 861AC_DEFUN([AM_SILENT_RULES], 862[AC_ARG_ENABLE([silent-rules], 863[ --enable-silent-rules less verbose build output (undo: `make V=1') 864 --disable-silent-rules verbose build output (undo: `make V=0')]) 865case $enable_silent_rules in 866yes) AM_DEFAULT_VERBOSITY=0;; 867no) AM_DEFAULT_VERBOSITY=1;; 868*) AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);; 869esac 870AC_SUBST([AM_DEFAULT_VERBOSITY])dnl 871AM_BACKSLASH='\' 872AC_SUBST([AM_BACKSLASH])dnl 873_AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl 874]) 875 876# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. 877# 878# This file is free software; the Free Software Foundation 879# gives unlimited permission to copy and/or distribute it, 880# with or without modifications, as long as this notice is preserved. 881 882# AM_PROG_INSTALL_STRIP 883# --------------------- 884# One issue with vendor `install' (even GNU) is that you can't 885# specify the program used to strip binaries. This is especially 886# annoying in cross-compiling environments, where the build's strip 887# is unlikely to handle the host's binaries. 888# Fortunately install-sh will honor a STRIPPROG variable, so we 889# always use install-sh in `make install-strip', and initialize 890# STRIPPROG with the value of the STRIP variable (set by the user). 891AC_DEFUN([AM_PROG_INSTALL_STRIP], 892[AC_REQUIRE([AM_PROG_INSTALL_SH])dnl 893# Installed binaries are usually stripped using `strip' when the user 894# run `make install-strip'. However `strip' might not be the right 895# tool to use in cross-compilation environments, therefore Automake 896# will honor the `STRIP' environment variable to overrule this program. 897dnl Don't test for $cross_compiling = yes, because it might be `maybe'. 898if test "$cross_compiling" != no; then 899 AC_CHECK_TOOL([STRIP], [strip], :) 900fi 901INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" 902AC_SUBST([INSTALL_STRIP_PROGRAM])]) 903 904# Copyright (C) 2006, 2008 Free Software Foundation, Inc. 905# 906# This file is free software; the Free Software Foundation 907# gives unlimited permission to copy and/or distribute it, 908# with or without modifications, as long as this notice is preserved. 909 910# serial 2 911 912# _AM_SUBST_NOTMAKE(VARIABLE) 913# --------------------------- 914# Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in. 915# This macro is traced by Automake. 916AC_DEFUN([_AM_SUBST_NOTMAKE]) 917 918# AM_SUBST_NOTMAKE(VARIABLE) 919# --------------------------- 920# Public sister of _AM_SUBST_NOTMAKE. 921AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)]) 922 923# Check how to create a tarball. -*- Autoconf -*- 924 925# Copyright (C) 2004, 2005 Free Software Foundation, Inc. 926# 927# This file is free software; the Free Software Foundation 928# gives unlimited permission to copy and/or distribute it, 929# with or without modifications, as long as this notice is preserved. 930 931# serial 2 932 933# _AM_PROG_TAR(FORMAT) 934# -------------------- 935# Check how to create a tarball in format FORMAT. 936# FORMAT should be one of `v7', `ustar', or `pax'. 937# 938# Substitute a variable $(am__tar) that is a command 939# writing to stdout a FORMAT-tarball containing the directory 940# $tardir. 941# tardir=directory && $(am__tar) > result.tar 942# 943# Substitute a variable $(am__untar) that extract such 944# a tarball read from stdin. 945# $(am__untar) < result.tar 946AC_DEFUN([_AM_PROG_TAR], 947[# Always define AMTAR for backward compatibility. 948AM_MISSING_PROG([AMTAR], [tar]) 949m4_if([$1], [v7], 950 [am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'], 951 [m4_case([$1], [ustar],, [pax],, 952 [m4_fatal([Unknown tar format])]) 953AC_MSG_CHECKING([how to create a $1 tar archive]) 954# Loop over all known methods to create a tar archive until one works. 955_am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none' 956_am_tools=${am_cv_prog_tar_$1-$_am_tools} 957# Do not fold the above two line into one, because Tru64 sh and 958# Solaris sh will not grok spaces in the rhs of `-'. 959for _am_tool in $_am_tools 960do 961 case $_am_tool in 962 gnutar) 963 for _am_tar in tar gnutar gtar; 964 do 965 AM_RUN_LOG([$_am_tar --version]) && break 966 done 967 am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"' 968 am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"' 969 am__untar="$_am_tar -xf -" 970 ;; 971 plaintar) 972 # Must skip GNU tar: if it does not support --format= it doesn't create 973 # ustar tarball either. 974 (tar --version) >/dev/null 2>&1 && continue 975 am__tar='tar chf - "$$tardir"' 976 am__tar_='tar chf - "$tardir"' 977 am__untar='tar xf -' 978 ;; 979 pax) 980 am__tar='pax -L -x $1 -w "$$tardir"' 981 am__tar_='pax -L -x $1 -w "$tardir"' 982 am__untar='pax -r' 983 ;; 984 cpio) 985 am__tar='find "$$tardir" -print | cpio -o -H $1 -L' 986 am__tar_='find "$tardir" -print | cpio -o -H $1 -L' 987 am__untar='cpio -i -H $1 -d' 988 ;; 989 none) 990 am__tar=false 991 am__tar_=false 992 am__untar=false 993 ;; 994 esac 995 996 # If the value was cached, stop now. We just wanted to have am__tar 997 # and am__untar set. 998 test -n "${am_cv_prog_tar_$1}" && break 999 1000 # tar/untar a dummy directory, and stop if the command works 1001 rm -rf conftest.dir 1002 mkdir conftest.dir 1003 echo GrepMe > conftest.dir/file 1004 AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar]) 1005 rm -rf conftest.dir 1006 if test -s conftest.tar; then 1007 AM_RUN_LOG([$am__untar <conftest.tar]) 1008 grep GrepMe conftest.dir/file >/dev/null 2>&1 && break 1009 fi 1010done 1011rm -rf conftest.dir 1012 1013AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool]) 1014AC_MSG_RESULT([$am_cv_prog_tar_$1])]) 1015AC_SUBST([am__tar]) 1016AC_SUBST([am__untar]) 1017]) # _AM_PROG_TAR 1018 1019dnl xorg-macros.m4. Generated from xorg-macros.m4.in xorgversion.m4 by configure. 1020dnl 1021dnl Copyright (c) 2005, 2006, Oracle and/or its affiliates. All rights reserved. 1022dnl 1023dnl Permission is hereby granted, free of charge, to any person obtaining a 1024dnl copy of this software and associated documentation files (the "Software"), 1025dnl to deal in the Software without restriction, including without limitation 1026dnl the rights to use, copy, modify, merge, publish, distribute, sublicense, 1027dnl and/or sell copies of the Software, and to permit persons to whom the 1028dnl Software is furnished to do so, subject to the following conditions: 1029dnl 1030dnl The above copyright notice and this permission notice (including the next 1031dnl paragraph) shall be included in all copies or substantial portions of the 1032dnl Software. 1033dnl 1034dnl THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 1035dnl IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 1036dnl FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL 1037dnl THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 1038dnl LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 1039dnl FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER 1040dnl DEALINGS IN THE SOFTWARE. 1041 1042# XORG_MACROS_VERSION(required-version) 1043# ------------------------------------- 1044# Minimum version: 1.1.0 1045# 1046# If you're using a macro added in Version 1.1 or newer, include this in 1047# your configure.ac with the minimum required version, such as: 1048# XORG_MACROS_VERSION(1.1) 1049# 1050# To ensure that this macro is defined, also add: 1051# m4_ifndef([XORG_MACROS_VERSION], 1052# [m4_fatal([must install xorg-macros 1.1 or later before running autoconf/autogen])]) 1053# 1054# 1055# See the "minimum version" comment for each macro you use to see what 1056# version you require. 1057m4_defun([XORG_MACROS_VERSION],[ 1058m4_define([vers_have], [1.11.0]) 1059m4_define([maj_have], m4_substr(vers_have, 0, m4_index(vers_have, [.]))) 1060m4_define([maj_needed], m4_substr([$1], 0, m4_index([$1], [.]))) 1061m4_if(m4_cmp(maj_have, maj_needed), 0,, 1062 [m4_fatal([xorg-macros major version ]maj_needed[ is required but ]vers_have[ found])]) 1063m4_if(m4_version_compare(vers_have, [$1]), -1, 1064 [m4_fatal([xorg-macros version $1 or higher is required but ]vers_have[ found])]) 1065m4_undefine([vers_have]) 1066m4_undefine([maj_have]) 1067m4_undefine([maj_needed]) 1068]) # XORG_MACROS_VERSION 1069 1070# XORG_PROG_RAWCPP() 1071# ------------------ 1072# Minimum version: 1.0.0 1073# 1074# Find cpp program and necessary flags for use in pre-processing text files 1075# such as man pages and config files 1076AC_DEFUN([XORG_PROG_RAWCPP],[ 1077AC_REQUIRE([AC_PROG_CPP]) 1078AC_PATH_PROGS(RAWCPP, [cpp], [${CPP}], 1079 [$PATH:/bin:/usr/bin:/usr/lib:/usr/libexec:/usr/ccs/lib:/usr/ccs/lbin:/lib]) 1080 1081# Check for flag to avoid builtin definitions - assumes unix is predefined, 1082# which is not the best choice for supporting other OS'es, but covers most 1083# of the ones we need for now. 1084AC_MSG_CHECKING([if $RAWCPP requires -undef]) 1085AC_LANG_CONFTEST([Does cpp redefine unix ?]) 1086if test `${RAWCPP} < conftest.$ac_ext | grep -c 'unix'` -eq 1 ; then 1087 AC_MSG_RESULT([no]) 1088else 1089 if test `${RAWCPP} -undef < conftest.$ac_ext | grep -c 'unix'` -eq 1 ; then 1090 RAWCPPFLAGS=-undef 1091 AC_MSG_RESULT([yes]) 1092 # under Cygwin unix is still defined even with -undef 1093 elif test `${RAWCPP} -undef -ansi < conftest.$ac_ext | grep -c 'unix'` -eq 1 ; then 1094 RAWCPPFLAGS="-undef -ansi" 1095 AC_MSG_RESULT([yes, with -ansi]) 1096 else 1097 AC_MSG_ERROR([${RAWCPP} defines unix with or without -undef. I don't know what to do.]) 1098 fi 1099fi 1100rm -f conftest.$ac_ext 1101 1102AC_MSG_CHECKING([if $RAWCPP requires -traditional]) 1103AC_LANG_CONFTEST([Does cpp preserve "whitespace"?]) 1104if test `${RAWCPP} < conftest.$ac_ext | grep -c 'preserve \"'` -eq 1 ; then 1105 AC_MSG_RESULT([no]) 1106else 1107 if test `${RAWCPP} -traditional < conftest.$ac_ext | grep -c 'preserve \"'` -eq 1 ; then 1108 RAWCPPFLAGS="${RAWCPPFLAGS} -traditional" 1109 AC_MSG_RESULT([yes]) 1110 else 1111 AC_MSG_ERROR([${RAWCPP} does not preserve whitespace with or without -traditional. I don't know what to do.]) 1112 fi 1113fi 1114rm -f conftest.$ac_ext 1115AC_SUBST(RAWCPPFLAGS) 1116]) # XORG_PROG_RAWCPP 1117 1118# XORG_MANPAGE_SECTIONS() 1119# ----------------------- 1120# Minimum version: 1.0.0 1121# 1122# Determine which sections man pages go in for the different man page types 1123# on this OS - replaces *ManSuffix settings in old Imake *.cf per-os files. 1124# Not sure if there's any better way than just hardcoding by OS name. 1125# Override default settings by setting environment variables 1126# Added MAN_SUBSTS in version 1.8 1127# Added AC_PROG_SED in version 1.8 1128 1129AC_DEFUN([XORG_MANPAGE_SECTIONS],[ 1130AC_REQUIRE([AC_CANONICAL_HOST]) 1131AC_REQUIRE([AC_PROG_SED]) 1132 1133if test x$APP_MAN_SUFFIX = x ; then 1134 APP_MAN_SUFFIX=1 1135fi 1136if test x$APP_MAN_DIR = x ; then 1137 APP_MAN_DIR='$(mandir)/man$(APP_MAN_SUFFIX)' 1138fi 1139 1140if test x$LIB_MAN_SUFFIX = x ; then 1141 LIB_MAN_SUFFIX=3 1142fi 1143if test x$LIB_MAN_DIR = x ; then 1144 LIB_MAN_DIR='$(mandir)/man$(LIB_MAN_SUFFIX)' 1145fi 1146 1147if test x$FILE_MAN_SUFFIX = x ; then 1148 case $host_os in 1149 solaris*) FILE_MAN_SUFFIX=4 ;; 1150 *) FILE_MAN_SUFFIX=5 ;; 1151 esac 1152fi 1153if test x$FILE_MAN_DIR = x ; then 1154 FILE_MAN_DIR='$(mandir)/man$(FILE_MAN_SUFFIX)' 1155fi 1156 1157if test x$MISC_MAN_SUFFIX = x ; then 1158 case $host_os in 1159 solaris*) MISC_MAN_SUFFIX=5 ;; 1160 *) MISC_MAN_SUFFIX=7 ;; 1161 esac 1162fi 1163if test x$MISC_MAN_DIR = x ; then 1164 MISC_MAN_DIR='$(mandir)/man$(MISC_MAN_SUFFIX)' 1165fi 1166 1167if test x$DRIVER_MAN_SUFFIX = x ; then 1168 case $host_os in 1169 solaris*) DRIVER_MAN_SUFFIX=7 ;; 1170 *) DRIVER_MAN_SUFFIX=4 ;; 1171 esac 1172fi 1173if test x$DRIVER_MAN_DIR = x ; then 1174 DRIVER_MAN_DIR='$(mandir)/man$(DRIVER_MAN_SUFFIX)' 1175fi 1176 1177if test x$ADMIN_MAN_SUFFIX = x ; then 1178 case $host_os in 1179 solaris*) ADMIN_MAN_SUFFIX=1m ;; 1180 *) ADMIN_MAN_SUFFIX=8 ;; 1181 esac 1182fi 1183if test x$ADMIN_MAN_DIR = x ; then 1184 ADMIN_MAN_DIR='$(mandir)/man$(ADMIN_MAN_SUFFIX)' 1185fi 1186 1187 1188AC_SUBST([APP_MAN_SUFFIX]) 1189AC_SUBST([LIB_MAN_SUFFIX]) 1190AC_SUBST([FILE_MAN_SUFFIX]) 1191AC_SUBST([MISC_MAN_SUFFIX]) 1192AC_SUBST([DRIVER_MAN_SUFFIX]) 1193AC_SUBST([ADMIN_MAN_SUFFIX]) 1194AC_SUBST([APP_MAN_DIR]) 1195AC_SUBST([LIB_MAN_DIR]) 1196AC_SUBST([FILE_MAN_DIR]) 1197AC_SUBST([MISC_MAN_DIR]) 1198AC_SUBST([DRIVER_MAN_DIR]) 1199AC_SUBST([ADMIN_MAN_DIR]) 1200 1201XORG_MAN_PAGE="X Version 11" 1202AC_SUBST([XORG_MAN_PAGE]) 1203MAN_SUBSTS="\ 1204 -e 's|__vendorversion__|\"\$(PACKAGE_STRING)\" \"\$(XORG_MAN_PAGE)\"|' \ 1205 -e 's|__xorgversion__|\"\$(PACKAGE_STRING)\" \"\$(XORG_MAN_PAGE)\"|' \ 1206 -e 's|__xservername__|Xorg|g' \ 1207 -e 's|__xconfigfile__|xorg.conf|g' \ 1208 -e 's|__projectroot__|\$(prefix)|g' \ 1209 -e 's|__apploaddir__|\$(appdefaultdir)|g' \ 1210 -e 's|__appmansuffix__|\$(APP_MAN_SUFFIX)|g' \ 1211 -e 's|__drivermansuffix__|\$(DRIVER_MAN_SUFFIX)|g' \ 1212 -e 's|__adminmansuffix__|\$(ADMIN_MAN_SUFFIX)|g' \ 1213 -e 's|__libmansuffix__|\$(LIB_MAN_SUFFIX)|g' \ 1214 -e 's|__miscmansuffix__|\$(MISC_MAN_SUFFIX)|g' \ 1215 -e 's|__filemansuffix__|\$(FILE_MAN_SUFFIX)|g'" 1216AC_SUBST([MAN_SUBSTS]) 1217 1218]) # XORG_MANPAGE_SECTIONS 1219 1220# XORG_CHECK_SGML_DOCTOOLS([MIN-VERSION]) 1221# ------------------------ 1222# Minimum version: 1.7.0 1223# 1224# Defines the variable XORG_SGML_PATH containing the location of X11/defs.ent 1225# provided by xorg-sgml-doctools, if installed. 1226AC_DEFUN([XORG_CHECK_SGML_DOCTOOLS],[ 1227AC_MSG_CHECKING([for X.Org SGML entities m4_ifval([$1],[>= $1])]) 1228XORG_SGML_PATH= 1229PKG_CHECK_EXISTS([xorg-sgml-doctools m4_ifval([$1],[>= $1])], 1230 [XORG_SGML_PATH=`$PKG_CONFIG --variable=sgmlrootdir xorg-sgml-doctools`], 1231 [m4_ifval([$1],[:], 1232 [if test x"$cross_compiling" != x"yes" ; then 1233 AC_CHECK_FILE([$prefix/share/sgml/X11/defs.ent], 1234 [XORG_SGML_PATH=$prefix/share/sgml]) 1235 fi]) 1236 ]) 1237 1238# Define variables STYLESHEET_SRCDIR and XSL_STYLESHEET containing 1239# the path and the name of the doc stylesheet 1240if test "x$XORG_SGML_PATH" != "x" ; then 1241 AC_MSG_RESULT([$XORG_SGML_PATH]) 1242 STYLESHEET_SRCDIR=$XORG_SGML_PATH/X11 1243 XSL_STYLESHEET=$STYLESHEET_SRCDIR/xorg.xsl 1244else 1245 AC_MSG_RESULT([no]) 1246fi 1247 1248AC_SUBST(XORG_SGML_PATH) 1249AC_SUBST(STYLESHEET_SRCDIR) 1250AC_SUBST(XSL_STYLESHEET) 1251AM_CONDITIONAL([HAVE_STYLESHEETS], [test "x$XSL_STYLESHEET" != "x"]) 1252]) # XORG_CHECK_SGML_DOCTOOLS 1253 1254# XORG_CHECK_LINUXDOC 1255# ------------------- 1256# Minimum version: 1.0.0 1257# 1258# Defines the variable MAKE_TEXT if the necessary tools and 1259# files are found. $(MAKE_TEXT) blah.sgml will then produce blah.txt. 1260# Whether or not the necessary tools and files are found can be checked 1261# with the AM_CONDITIONAL "BUILD_LINUXDOC" 1262AC_DEFUN([XORG_CHECK_LINUXDOC],[ 1263AC_REQUIRE([XORG_CHECK_SGML_DOCTOOLS]) 1264AC_REQUIRE([XORG_WITH_PS2PDF]) 1265 1266AC_PATH_PROG(LINUXDOC, linuxdoc) 1267 1268AC_MSG_CHECKING([whether to build documentation]) 1269 1270if test x$XORG_SGML_PATH != x && test x$LINUXDOC != x ; then 1271 BUILDDOC=yes 1272else 1273 BUILDDOC=no 1274fi 1275 1276AM_CONDITIONAL(BUILD_LINUXDOC, [test x$BUILDDOC = xyes]) 1277 1278AC_MSG_RESULT([$BUILDDOC]) 1279 1280AC_MSG_CHECKING([whether to build pdf documentation]) 1281 1282if test x$have_ps2pdf != xno && test x$BUILD_PDFDOC != xno; then 1283 BUILDPDFDOC=yes 1284else 1285 BUILDPDFDOC=no 1286fi 1287 1288AM_CONDITIONAL(BUILD_PDFDOC, [test x$BUILDPDFDOC = xyes]) 1289 1290AC_MSG_RESULT([$BUILDPDFDOC]) 1291 1292MAKE_TEXT="SGML_SEARCH_PATH=$XORG_SGML_PATH GROFF_NO_SGR=y $LINUXDOC -B txt -f" 1293MAKE_PS="SGML_SEARCH_PATH=$XORG_SGML_PATH $LINUXDOC -B latex --papersize=letter --output=ps" 1294MAKE_PDF="$PS2PDF" 1295MAKE_HTML="SGML_SEARCH_PATH=$XORG_SGML_PATH $LINUXDOC -B html --split=0" 1296 1297AC_SUBST(MAKE_TEXT) 1298AC_SUBST(MAKE_PS) 1299AC_SUBST(MAKE_PDF) 1300AC_SUBST(MAKE_HTML) 1301]) # XORG_CHECK_LINUXDOC 1302 1303# XORG_CHECK_DOCBOOK 1304# ------------------- 1305# Minimum version: 1.0.0 1306# 1307# Checks for the ability to build output formats from SGML DocBook source. 1308# For XXX in {TXT, PDF, PS, HTML}, the AM_CONDITIONAL "BUILD_XXXDOC" 1309# indicates whether the necessary tools and files are found and, if set, 1310# $(MAKE_XXX) blah.sgml will produce blah.xxx. 1311AC_DEFUN([XORG_CHECK_DOCBOOK],[ 1312AC_REQUIRE([XORG_CHECK_SGML_DOCTOOLS]) 1313 1314BUILDTXTDOC=no 1315BUILDPDFDOC=no 1316BUILDPSDOC=no 1317BUILDHTMLDOC=no 1318 1319AC_PATH_PROG(DOCBOOKPS, docbook2ps) 1320AC_PATH_PROG(DOCBOOKPDF, docbook2pdf) 1321AC_PATH_PROG(DOCBOOKHTML, docbook2html) 1322AC_PATH_PROG(DOCBOOKTXT, docbook2txt) 1323 1324AC_MSG_CHECKING([whether to build text documentation]) 1325if test x$XORG_SGML_PATH != x && test x$DOCBOOKTXT != x && 1326 test x$BUILD_TXTDOC != xno; then 1327 BUILDTXTDOC=yes 1328fi 1329AM_CONDITIONAL(BUILD_TXTDOC, [test x$BUILDTXTDOC = xyes]) 1330AC_MSG_RESULT([$BUILDTXTDOC]) 1331 1332AC_MSG_CHECKING([whether to build PDF documentation]) 1333if test x$XORG_SGML_PATH != x && test x$DOCBOOKPDF != x && 1334 test x$BUILD_PDFDOC != xno; then 1335 BUILDPDFDOC=yes 1336fi 1337AM_CONDITIONAL(BUILD_PDFDOC, [test x$BUILDPDFDOC = xyes]) 1338AC_MSG_RESULT([$BUILDPDFDOC]) 1339 1340AC_MSG_CHECKING([whether to build PostScript documentation]) 1341if test x$XORG_SGML_PATH != x && test x$DOCBOOKPS != x && 1342 test x$BUILD_PSDOC != xno; then 1343 BUILDPSDOC=yes 1344fi 1345AM_CONDITIONAL(BUILD_PSDOC, [test x$BUILDPSDOC = xyes]) 1346AC_MSG_RESULT([$BUILDPSDOC]) 1347 1348AC_MSG_CHECKING([whether to build HTML documentation]) 1349if test x$XORG_SGML_PATH != x && test x$DOCBOOKHTML != x && 1350 test x$BUILD_HTMLDOC != xno; then 1351 BUILDHTMLDOC=yes 1352fi 1353AM_CONDITIONAL(BUILD_HTMLDOC, [test x$BUILDHTMLDOC = xyes]) 1354AC_MSG_RESULT([$BUILDHTMLDOC]) 1355 1356MAKE_TEXT="SGML_SEARCH_PATH=$XORG_SGML_PATH $DOCBOOKTXT" 1357MAKE_PS="SGML_SEARCH_PATH=$XORG_SGML_PATH $DOCBOOKPS" 1358MAKE_PDF="SGML_SEARCH_PATH=$XORG_SGML_PATH $DOCBOOKPDF" 1359MAKE_HTML="SGML_SEARCH_PATH=$XORG_SGML_PATH $DOCBOOKHTML" 1360 1361AC_SUBST(MAKE_TEXT) 1362AC_SUBST(MAKE_PS) 1363AC_SUBST(MAKE_PDF) 1364AC_SUBST(MAKE_HTML) 1365]) # XORG_CHECK_DOCBOOK 1366 1367# XORG_WITH_XMLTO([MIN-VERSION], [DEFAULT]) 1368# ---------------- 1369# Minimum version: 1.5.0 1370# Minimum version for optional DEFAULT argument: 1.11.0 1371# 1372# Documentation tools are not always available on all platforms and sometimes 1373# not at the appropriate level. This macro enables a module to test for the 1374# presence of the tool and obtain it's path in separate variables. Coupled with 1375# the --with-xmlto option, it allows maximum flexibilty in making decisions 1376# as whether or not to use the xmlto package. When DEFAULT is not specified, 1377# --with-xmlto assumes 'auto'. 1378# 1379# Interface to module: 1380# HAVE_XMLTO: used in makefiles to conditionally generate documentation 1381# XMLTO: returns the path of the xmlto program found 1382# returns the path set by the user in the environment 1383# --with-xmlto: 'yes' user instructs the module to use xmlto 1384# 'no' user instructs the module not to use xmlto 1385# 1386# Added in version 1.10.0 1387# HAVE_XMLTO_TEXT: used in makefiles to conditionally generate text documentation 1388# xmlto for text output requires either lynx, links, or w3m browsers 1389# 1390# If the user sets the value of XMLTO, AC_PATH_PROG skips testing the path. 1391# 1392AC_DEFUN([XORG_WITH_XMLTO],[ 1393AC_ARG_VAR([XMLTO], [Path to xmlto command]) 1394m4_define([_defopt], m4_default([$2], [auto])) 1395AC_ARG_WITH(xmlto, 1396 AS_HELP_STRING([--with-xmlto], 1397 [Use xmlto to regenerate documentation (default: ]_defopt[)]), 1398 [use_xmlto=$withval], [use_xmlto=]_defopt) 1399m4_undefine([_defopt]) 1400 1401if test "x$use_xmlto" = x"auto"; then 1402 AC_PATH_PROG([XMLTO], [xmlto]) 1403 if test "x$XMLTO" = "x"; then 1404 AC_MSG_WARN([xmlto not found - documentation targets will be skipped]) 1405 have_xmlto=no 1406 else 1407 have_xmlto=yes 1408 fi 1409elif test "x$use_xmlto" = x"yes" ; then 1410 AC_PATH_PROG([XMLTO], [xmlto]) 1411 if test "x$XMLTO" = "x"; then 1412 AC_MSG_ERROR([--with-xmlto=yes specified but xmlto not found in PATH]) 1413 fi 1414 have_xmlto=yes 1415elif test "x$use_xmlto" = x"no" ; then 1416 if test "x$XMLTO" != "x"; then 1417 AC_MSG_WARN([ignoring XMLTO environment variable since --with-xmlto=no was specified]) 1418 fi 1419 have_xmlto=no 1420else 1421 AC_MSG_ERROR([--with-xmlto expects 'yes' or 'no']) 1422fi 1423 1424# Test for a minimum version of xmlto, if provided. 1425m4_ifval([$1], 1426[if test "$have_xmlto" = yes; then 1427 # scrape the xmlto version 1428 AC_MSG_CHECKING([the xmlto version]) 1429 xmlto_version=`$XMLTO --version 2>/dev/null | cut -d' ' -f3` 1430 AC_MSG_RESULT([$xmlto_version]) 1431 AS_VERSION_COMPARE([$xmlto_version], [$1], 1432 [if test "x$use_xmlto" = xauto; then 1433 AC_MSG_WARN([xmlto version $xmlto_version found, but $1 needed]) 1434 have_xmlto=no 1435 else 1436 AC_MSG_ERROR([xmlto version $xmlto_version found, but $1 needed]) 1437 fi]) 1438fi]) 1439 1440# Test for the ability of xmlto to generate a text target 1441have_xmlto_text=no 1442cat > conftest.xml << "EOF" 1443EOF 1444AS_IF([test "$have_xmlto" = yes], 1445 [AS_IF([$XMLTO --skip-validation txt conftest.xml >/dev/null 2>&1], 1446 [have_xmlto_text=yes], 1447 [AC_MSG_WARN([xmlto cannot generate text format, this format skipped])])]) 1448rm -f conftest.xml 1449AM_CONDITIONAL([HAVE_XMLTO_TEXT], [test $have_xmlto_text = yes]) 1450AM_CONDITIONAL([HAVE_XMLTO], [test "$have_xmlto" = yes]) 1451]) # XORG_WITH_XMLTO 1452 1453# XORG_WITH_ASCIIDOC([MIN-VERSION], [DEFAULT]) 1454# ---------------- 1455# Minimum version: 1.5.0 1456# Minimum version for optional DEFAULT argument: 1.11.0 1457# 1458# Documentation tools are not always available on all platforms and sometimes 1459# not at the appropriate level. This macro enables a module to test for the 1460# presence of the tool and obtain it's path in separate variables. Coupled with 1461# the --with-asciidoc option, it allows maximum flexibilty in making decisions 1462# as whether or not to use the asciidoc package. When DEFAULT is not specified, 1463# --with-asciidoc assumes 'auto'. 1464# 1465# Interface to module: 1466# HAVE_ASCIIDOC: used in makefiles to conditionally generate documentation 1467# ASCIIDOC: returns the path of the asciidoc program found 1468# returns the path set by the user in the environment 1469# --with-asciidoc: 'yes' user instructs the module to use asciidoc 1470# 'no' user instructs the module not to use asciidoc 1471# 1472# If the user sets the value of ASCIIDOC, AC_PATH_PROG skips testing the path. 1473# 1474AC_DEFUN([XORG_WITH_ASCIIDOC],[ 1475AC_ARG_VAR([ASCIIDOC], [Path to asciidoc command]) 1476m4_define([_defopt], m4_default([$2], [auto])) 1477AC_ARG_WITH(asciidoc, 1478 AS_HELP_STRING([--with-asciidoc], 1479 [Use asciidoc to regenerate documentation (default: ]_defopt[)]), 1480 [use_asciidoc=$withval], [use_asciidoc=]_defopt) 1481m4_undefine([_defopt]) 1482 1483if test "x$use_asciidoc" = x"auto"; then 1484 AC_PATH_PROG([ASCIIDOC], [asciidoc]) 1485 if test "x$ASCIIDOC" = "x"; then 1486 AC_MSG_WARN([asciidoc not found - documentation targets will be skipped]) 1487 have_asciidoc=no 1488 else 1489 have_asciidoc=yes 1490 fi 1491elif test "x$use_asciidoc" = x"yes" ; then 1492 AC_PATH_PROG([ASCIIDOC], [asciidoc]) 1493 if test "x$ASCIIDOC" = "x"; then 1494 AC_MSG_ERROR([--with-asciidoc=yes specified but asciidoc not found in PATH]) 1495 fi 1496 have_asciidoc=yes 1497elif test "x$use_asciidoc" = x"no" ; then 1498 if test "x$ASCIIDOC" != "x"; then 1499 AC_MSG_WARN([ignoring ASCIIDOC environment variable since --with-asciidoc=no was specified]) 1500 fi 1501 have_asciidoc=no 1502else 1503 AC_MSG_ERROR([--with-asciidoc expects 'yes' or 'no']) 1504fi 1505m4_ifval([$1], 1506[if test "$have_asciidoc" = yes; then 1507 # scrape the asciidoc version 1508 AC_MSG_CHECKING([the asciidoc version]) 1509 asciidoc_version=`$ASCIIDOC --version 2>/dev/null | cut -d' ' -f2` 1510 AC_MSG_RESULT([$asciidoc_version]) 1511 AS_VERSION_COMPARE([$asciidoc_version], [$1], 1512 [if test "x$use_asciidoc" = xauto; then 1513 AC_MSG_WARN([asciidoc version $asciidoc_version found, but $1 needed]) 1514 have_asciidoc=no 1515 else 1516 AC_MSG_ERROR([asciidoc version $asciidoc_version found, but $1 needed]) 1517 fi]) 1518fi]) 1519AM_CONDITIONAL([HAVE_ASCIIDOC], [test "$have_asciidoc" = yes]) 1520]) # XORG_WITH_ASCIIDOC 1521 1522# XORG_WITH_DOXYGEN([MIN-VERSION], [DEFAULT]) 1523# -------------------------------- 1524# Minimum version: 1.5.0 1525# Minimum version for optional DEFAULT argument: 1.11.0 1526# 1527# Documentation tools are not always available on all platforms and sometimes 1528# not at the appropriate level. This macro enables a module to test for the 1529# presence of the tool and obtain it's path in separate variables. Coupled with 1530# the --with-doxygen option, it allows maximum flexibilty in making decisions 1531# as whether or not to use the doxygen package. When DEFAULT is not specified, 1532# --with-doxygen assumes 'auto'. 1533# 1534# Interface to module: 1535# HAVE_DOXYGEN: used in makefiles to conditionally generate documentation 1536# DOXYGEN: returns the path of the doxygen program found 1537# returns the path set by the user in the environment 1538# --with-doxygen: 'yes' user instructs the module to use doxygen 1539# 'no' user instructs the module not to use doxygen 1540# 1541# If the user sets the value of DOXYGEN, AC_PATH_PROG skips testing the path. 1542# 1543AC_DEFUN([XORG_WITH_DOXYGEN],[ 1544AC_ARG_VAR([DOXYGEN], [Path to doxygen command]) 1545m4_define([_defopt], m4_default([$2], [auto])) 1546AC_ARG_WITH(doxygen, 1547 AS_HELP_STRING([--with-doxygen], 1548 [Use doxygen to regenerate documentation (default: ]_defopt[)]), 1549 [use_doxygen=$withval], [use_doxygen=]_defopt) 1550m4_undefine([_defopt]) 1551 1552if test "x$use_doxygen" = x"auto"; then 1553 AC_PATH_PROG([DOXYGEN], [doxygen]) 1554 if test "x$DOXYGEN" = "x"; then 1555 AC_MSG_WARN([doxygen not found - documentation targets will be skipped]) 1556 have_doxygen=no 1557 else 1558 have_doxygen=yes 1559 fi 1560elif test "x$use_doxygen" = x"yes" ; then 1561 AC_PATH_PROG([DOXYGEN], [doxygen]) 1562 if test "x$DOXYGEN" = "x"; then 1563 AC_MSG_ERROR([--with-doxygen=yes specified but doxygen not found in PATH]) 1564 fi 1565 have_doxygen=yes 1566elif test "x$use_doxygen" = x"no" ; then 1567 if test "x$DOXYGEN" != "x"; then 1568 AC_MSG_WARN([ignoring DOXYGEN environment variable since --with-doxygen=no was specified]) 1569 fi 1570 have_doxygen=no 1571else 1572 AC_MSG_ERROR([--with-doxygen expects 'yes' or 'no']) 1573fi 1574m4_ifval([$1], 1575[if test "$have_doxygen" = yes; then 1576 # scrape the doxygen version 1577 AC_MSG_CHECKING([the doxygen version]) 1578 doxygen_version=`$DOXYGEN --version 2>/dev/null` 1579 AC_MSG_RESULT([$doxygen_version]) 1580 AS_VERSION_COMPARE([$doxygen_version], [$1], 1581 [if test "x$use_doxygen" = xauto; then 1582 AC_MSG_WARN([doxygen version $doxygen_version found, but $1 needed]) 1583 have_doxygen=no 1584 else 1585 AC_MSG_ERROR([doxygen version $doxygen_version found, but $1 needed]) 1586 fi]) 1587fi]) 1588AM_CONDITIONAL([HAVE_DOXYGEN], [test "$have_doxygen" = yes]) 1589]) # XORG_WITH_DOXYGEN 1590 1591# XORG_WITH_GROFF([DEFAULT]) 1592# ---------------- 1593# Minimum version: 1.6.0 1594# Minimum version for optional DEFAULT argument: 1.11.0 1595# 1596# Documentation tools are not always available on all platforms and sometimes 1597# not at the appropriate level. This macro enables a module to test for the 1598# presence of the tool and obtain it's path in separate variables. Coupled with 1599# the --with-groff option, it allows maximum flexibilty in making decisions 1600# as whether or not to use the groff package. When DEFAULT is not specified, 1601# --with-groff assumes 'auto'. 1602# 1603# Interface to module: 1604# HAVE_GROFF: used in makefiles to conditionally generate documentation 1605# HAVE_GROFF_MM: the memorandum macros (-mm) package 1606# HAVE_GROFF_MS: the -ms macros package 1607# GROFF: returns the path of the groff program found 1608# returns the path set by the user in the environment 1609# --with-groff: 'yes' user instructs the module to use groff 1610# 'no' user instructs the module not to use groff 1611# 1612# Added in version 1.9.0: 1613# HAVE_GROFF_HTML: groff has dependencies to output HTML format: 1614# pnmcut pnmcrop pnmtopng pnmtops from the netpbm package. 1615# psselect from the psutils package. 1616# the ghostcript package. Refer to the grohtml man pages 1617# 1618# If the user sets the value of GROFF, AC_PATH_PROG skips testing the path. 1619# 1620# OS and distros often splits groff in a basic and full package, the former 1621# having the groff program and the later having devices, fonts and macros 1622# Checking for the groff executable is not enough. 1623# 1624# If macros are missing, we cannot assume that groff is useless, so we don't 1625# unset HAVE_GROFF or GROFF env variables. 1626# HAVE_GROFF_?? can never be true while HAVE_GROFF is false. 1627# 1628AC_DEFUN([XORG_WITH_GROFF],[ 1629AC_ARG_VAR([GROFF], [Path to groff command]) 1630m4_define([_defopt], m4_default([$1], [auto])) 1631AC_ARG_WITH(groff, 1632 AS_HELP_STRING([--with-groff], 1633 [Use groff to regenerate documentation (default: ]_defopt[)]), 1634 [use_groff=$withval], [use_groff=]_defopt) 1635m4_undefine([_defopt]) 1636 1637if test "x$use_groff" = x"auto"; then 1638 AC_PATH_PROG([GROFF], [groff]) 1639 if test "x$GROFF" = "x"; then 1640 AC_MSG_WARN([groff not found - documentation targets will be skipped]) 1641 have_groff=no 1642 else 1643 have_groff=yes 1644 fi 1645elif test "x$use_groff" = x"yes" ; then 1646 AC_PATH_PROG([GROFF], [groff]) 1647 if test "x$GROFF" = "x"; then 1648 AC_MSG_ERROR([--with-groff=yes specified but groff not found in PATH]) 1649 fi 1650 have_groff=yes 1651elif test "x$use_groff" = x"no" ; then 1652 if test "x$GROFF" != "x"; then 1653 AC_MSG_WARN([ignoring GROFF environment variable since --with-groff=no was specified]) 1654 fi 1655 have_groff=no 1656else 1657 AC_MSG_ERROR([--with-groff expects 'yes' or 'no']) 1658fi 1659 1660# We have groff, test for the presence of the macro packages 1661if test "x$have_groff" = x"yes"; then 1662 AC_MSG_CHECKING([for ${GROFF} -ms macros]) 1663 if ${GROFF} -ms -I. /dev/null >/dev/null 2>&1 ; then 1664 groff_ms_works=yes 1665 else 1666 groff_ms_works=no 1667 fi 1668 AC_MSG_RESULT([$groff_ms_works]) 1669 AC_MSG_CHECKING([for ${GROFF} -mm macros]) 1670 if ${GROFF} -mm -I. /dev/null >/dev/null 2>&1 ; then 1671 groff_mm_works=yes 1672 else 1673 groff_mm_works=no 1674 fi 1675 AC_MSG_RESULT([$groff_mm_works]) 1676fi 1677 1678# We have groff, test for HTML dependencies, one command per package 1679if test "x$have_groff" = x"yes"; then 1680 AC_PATH_PROGS(GS_PATH, [gs gswin32c]) 1681 AC_PATH_PROG(PNMTOPNG_PATH, [pnmtopng]) 1682 AC_PATH_PROG(PSSELECT_PATH, [psselect]) 1683 if test "x$GS_PATH" != "x" -a "x$PNMTOPNG_PATH" != "x" -a "x$PSSELECT_PATH" != "x"; then 1684 have_groff_html=yes 1685 else 1686 have_groff_html=no 1687 AC_MSG_WARN([grohtml dependencies not found - HTML Documentation skipped. Refer to grohtml man pages]) 1688 fi 1689fi 1690 1691# Set Automake conditionals for Makefiles 1692AM_CONDITIONAL([HAVE_GROFF], [test "$have_groff" = yes]) 1693AM_CONDITIONAL([HAVE_GROFF_MS], [test "$groff_ms_works" = yes]) 1694AM_CONDITIONAL([HAVE_GROFF_MM], [test "$groff_mm_works" = yes]) 1695AM_CONDITIONAL([HAVE_GROFF_HTML], [test "$have_groff_html" = yes]) 1696]) # XORG_WITH_GROFF 1697 1698# XORG_WITH_FOP([DEFAULT]) 1699# ---------------- 1700# Minimum version: 1.6.0 1701# Minimum version for optional DEFAULT argument: 1.11.0 1702# 1703# Documentation tools are not always available on all platforms and sometimes 1704# not at the appropriate level. This macro enables a module to test for the 1705# presence of the tool and obtain it's path in separate variables. Coupled with 1706# the --with-fop option, it allows maximum flexibilty in making decisions 1707# as whether or not to use the fop package. When DEFAULT is not specified, 1708# --with-fop assumes 'auto'. 1709# 1710# Interface to module: 1711# HAVE_FOP: used in makefiles to conditionally generate documentation 1712# FOP: returns the path of the fop program found 1713# returns the path set by the user in the environment 1714# --with-fop: 'yes' user instructs the module to use fop 1715# 'no' user instructs the module not to use fop 1716# 1717# If the user sets the value of FOP, AC_PATH_PROG skips testing the path. 1718# 1719AC_DEFUN([XORG_WITH_FOP],[ 1720AC_ARG_VAR([FOP], [Path to fop command]) 1721m4_define([_defopt], m4_default([$1], [auto])) 1722AC_ARG_WITH(fop, 1723 AS_HELP_STRING([--with-fop], 1724 [Use fop to regenerate documentation (default: ]_defopt[)]), 1725 [use_fop=$withval], [use_fop=]_defopt) 1726m4_undefine([_defopt]) 1727 1728if test "x$use_fop" = x"auto"; then 1729 AC_PATH_PROG([FOP], [fop]) 1730 if test "x$FOP" = "x"; then 1731 AC_MSG_WARN([fop not found - documentation targets will be skipped]) 1732 have_fop=no 1733 else 1734 have_fop=yes 1735 fi 1736elif test "x$use_fop" = x"yes" ; then 1737 AC_PATH_PROG([FOP], [fop]) 1738 if test "x$FOP" = "x"; then 1739 AC_MSG_ERROR([--with-fop=yes specified but fop not found in PATH]) 1740 fi 1741 have_fop=yes 1742elif test "x$use_fop" = x"no" ; then 1743 if test "x$FOP" != "x"; then 1744 AC_MSG_WARN([ignoring FOP environment variable since --with-fop=no was specified]) 1745 fi 1746 have_fop=no 1747else 1748 AC_MSG_ERROR([--with-fop expects 'yes' or 'no']) 1749fi 1750AM_CONDITIONAL([HAVE_FOP], [test "$have_fop" = yes]) 1751]) # XORG_WITH_FOP 1752 1753# XORG_WITH_PS2PDF([DEFAULT]) 1754# ---------------- 1755# Minimum version: 1.6.0 1756# Minimum version for optional DEFAULT argument: 1.11.0 1757# 1758# Documentation tools are not always available on all platforms and sometimes 1759# not at the appropriate level. This macro enables a module to test for the 1760# presence of the tool and obtain it's path in separate variables. Coupled with 1761# the --with-ps2pdf option, it allows maximum flexibilty in making decisions 1762# as whether or not to use the ps2pdf package. When DEFAULT is not specified, 1763# --with-ps2pdf assumes 'auto'. 1764# 1765# Interface to module: 1766# HAVE_PS2PDF: used in makefiles to conditionally generate documentation 1767# PS2PDF: returns the path of the ps2pdf program found 1768# returns the path set by the user in the environment 1769# --with-ps2pdf: 'yes' user instructs the module to use ps2pdf 1770# 'no' user instructs the module not to use ps2pdf 1771# 1772# If the user sets the value of PS2PDF, AC_PATH_PROG skips testing the path. 1773# 1774AC_DEFUN([XORG_WITH_PS2PDF],[ 1775AC_ARG_VAR([PS2PDF], [Path to ps2pdf command]) 1776m4_define([_defopt], m4_default([$1], [auto])) 1777AC_ARG_WITH(ps2pdf, 1778 AS_HELP_STRING([--with-ps2pdf], 1779 [Use ps2pdf to regenerate documentation (default: ]_defopt[)]), 1780 [use_ps2pdf=$withval], [use_ps2pdf=]_defopt) 1781m4_undefine([_defopt]) 1782 1783if test "x$use_ps2pdf" = x"auto"; then 1784 AC_PATH_PROG([PS2PDF], [ps2pdf]) 1785 if test "x$PS2PDF" = "x"; then 1786 AC_MSG_WARN([ps2pdf not found - documentation targets will be skipped]) 1787 have_ps2pdf=no 1788 else 1789 have_ps2pdf=yes 1790 fi 1791elif test "x$use_ps2pdf" = x"yes" ; then 1792 AC_PATH_PROG([PS2PDF], [ps2pdf]) 1793 if test "x$PS2PDF" = "x"; then 1794 AC_MSG_ERROR([--with-ps2pdf=yes specified but ps2pdf not found in PATH]) 1795 fi 1796 have_ps2pdf=yes 1797elif test "x$use_ps2pdf" = x"no" ; then 1798 if test "x$PS2PDF" != "x"; then 1799 AC_MSG_WARN([ignoring PS2PDF environment variable since --with-ps2pdf=no was specified]) 1800 fi 1801 have_ps2pdf=no 1802else 1803 AC_MSG_ERROR([--with-ps2pdf expects 'yes' or 'no']) 1804fi 1805AM_CONDITIONAL([HAVE_PS2PDF], [test "$have_ps2pdf" = yes]) 1806]) # XORG_WITH_PS2PDF 1807 1808# XORG_ENABLE_DOCS (enable_docs=yes) 1809# ---------------- 1810# Minimum version: 1.6.0 1811# 1812# Documentation tools are not always available on all platforms and sometimes 1813# not at the appropriate level. This macro enables a builder to skip all 1814# documentation targets except traditional man pages. 1815# Combined with the specific tool checking macros XORG_WITH_*, it provides 1816# maximum flexibilty in controlling documentation building. 1817# Refer to: 1818# XORG_WITH_XMLTO --with-xmlto 1819# XORG_WITH_ASCIIDOC --with-asciidoc 1820# XORG_WITH_DOXYGEN --with-doxygen 1821# XORG_WITH_FOP --with-fop 1822# XORG_WITH_GROFF --with-groff 1823# XORG_WITH_PS2PDF --with-ps2pdf 1824# 1825# Interface to module: 1826# ENABLE_DOCS: used in makefiles to conditionally generate documentation 1827# --enable-docs: 'yes' user instructs the module to generate docs 1828# 'no' user instructs the module not to generate docs 1829# parm1: specify the default value, yes or no. 1830# 1831AC_DEFUN([XORG_ENABLE_DOCS],[ 1832m4_define([default], m4_default([$1], [yes])) 1833AC_ARG_ENABLE(docs, 1834 AS_HELP_STRING([--enable-docs], 1835 [Enable building the documentation (default: ]default[)]), 1836 [build_docs=$enableval], [build_docs=]default) 1837m4_undefine([default]) 1838AM_CONDITIONAL(ENABLE_DOCS, [test x$build_docs = xyes]) 1839AC_MSG_CHECKING([whether to build documentation]) 1840AC_MSG_RESULT([$build_docs]) 1841]) # XORG_ENABLE_DOCS 1842 1843# XORG_ENABLE_DEVEL_DOCS (enable_devel_docs=yes) 1844# ---------------- 1845# Minimum version: 1.6.0 1846# 1847# This macro enables a builder to skip all developer documentation. 1848# Combined with the specific tool checking macros XORG_WITH_*, it provides 1849# maximum flexibilty in controlling documentation building. 1850# Refer to: 1851# XORG_WITH_XMLTO --with-xmlto 1852# XORG_WITH_ASCIIDOC --with-asciidoc 1853# XORG_WITH_DOXYGEN --with-doxygen 1854# XORG_WITH_FOP --with-fop 1855# XORG_WITH_GROFF --with-groff 1856# XORG_WITH_PS2PDF --with-ps2pdf 1857# 1858# Interface to module: 1859# ENABLE_DEVEL_DOCS: used in makefiles to conditionally generate developer docs 1860# --enable-devel-docs: 'yes' user instructs the module to generate developer docs 1861# 'no' user instructs the module not to generate developer docs 1862# parm1: specify the default value, yes or no. 1863# 1864AC_DEFUN([XORG_ENABLE_DEVEL_DOCS],[ 1865m4_define([devel_default], m4_default([$1], [yes])) 1866AC_ARG_ENABLE(devel-docs, 1867 AS_HELP_STRING([--enable-devel-docs], 1868 [Enable building the developer documentation (default: ]devel_default[)]), 1869 [build_devel_docs=$enableval], [build_devel_docs=]devel_default) 1870m4_undefine([devel_default]) 1871AM_CONDITIONAL(ENABLE_DEVEL_DOCS, [test x$build_devel_docs = xyes]) 1872AC_MSG_CHECKING([whether to build developer documentation]) 1873AC_MSG_RESULT([$build_devel_docs]) 1874]) # XORG_ENABLE_DEVEL_DOCS 1875 1876# XORG_ENABLE_SPECS (enable_specs=yes) 1877# ---------------- 1878# Minimum version: 1.6.0 1879# 1880# This macro enables a builder to skip all functional specification targets. 1881# Combined with the specific tool checking macros XORG_WITH_*, it provides 1882# maximum flexibilty in controlling documentation building. 1883# Refer to: 1884# XORG_WITH_XMLTO --with-xmlto 1885# XORG_WITH_ASCIIDOC --with-asciidoc 1886# XORG_WITH_DOXYGEN --with-doxygen 1887# XORG_WITH_FOP --with-fop 1888# XORG_WITH_GROFF --with-groff 1889# XORG_WITH_PS2PDF --with-ps2pdf 1890# 1891# Interface to module: 1892# ENABLE_SPECS: used in makefiles to conditionally generate specs 1893# --enable-specs: 'yes' user instructs the module to generate specs 1894# 'no' user instructs the module not to generate specs 1895# parm1: specify the default value, yes or no. 1896# 1897AC_DEFUN([XORG_ENABLE_SPECS],[ 1898m4_define([spec_default], m4_default([$1], [yes])) 1899AC_ARG_ENABLE(specs, 1900 AS_HELP_STRING([--enable-specs], 1901 [Enable building the specs (default: ]spec_default[)]), 1902 [build_specs=$enableval], [build_specs=]spec_default) 1903m4_undefine([spec_default]) 1904AM_CONDITIONAL(ENABLE_SPECS, [test x$build_specs = xyes]) 1905AC_MSG_CHECKING([whether to build functional specifications]) 1906AC_MSG_RESULT([$build_specs]) 1907]) # XORG_ENABLE_SPECS 1908 1909# XORG_CHECK_MALLOC_ZERO 1910# ---------------------- 1911# Minimum version: 1.0.0 1912# 1913# Defines {MALLOC,XMALLOC,XTMALLOC}_ZERO_CFLAGS appropriately if 1914# malloc(0) returns NULL. Packages should add one of these cflags to 1915# their AM_CFLAGS (or other appropriate *_CFLAGS) to use them. 1916AC_DEFUN([XORG_CHECK_MALLOC_ZERO],[ 1917AC_ARG_ENABLE(malloc0returnsnull, 1918 AS_HELP_STRING([--enable-malloc0returnsnull], 1919 [malloc(0) returns NULL (default: auto)]), 1920 [MALLOC_ZERO_RETURNS_NULL=$enableval], 1921 [MALLOC_ZERO_RETURNS_NULL=auto]) 1922 1923AC_MSG_CHECKING([whether malloc(0) returns NULL]) 1924if test "x$MALLOC_ZERO_RETURNS_NULL" = xauto; then 1925 AC_RUN_IFELSE([ 1926char *malloc(); 1927char *realloc(); 1928char *calloc(); 1929main() { 1930 char *m0, *r0, *c0, *p; 1931 m0 = malloc(0); 1932 p = malloc(10); 1933 r0 = realloc(p,0); 1934 c0 = calloc(0); 1935 exit(m0 == 0 || r0 == 0 || c0 == 0 ? 0 : 1); 1936}], 1937 [MALLOC_ZERO_RETURNS_NULL=yes], 1938 [MALLOC_ZERO_RETURNS_NULL=no], 1939 [MALLOC_ZERO_RETURNS_NULL=yes]) 1940fi 1941AC_MSG_RESULT([$MALLOC_ZERO_RETURNS_NULL]) 1942 1943if test "x$MALLOC_ZERO_RETURNS_NULL" = xyes; then 1944 MALLOC_ZERO_CFLAGS="-DMALLOC_0_RETURNS_NULL" 1945 XMALLOC_ZERO_CFLAGS=$MALLOC_ZERO_CFLAGS 1946 XTMALLOC_ZERO_CFLAGS="$MALLOC_ZERO_CFLAGS -DXTMALLOC_BC" 1947else 1948 MALLOC_ZERO_CFLAGS="" 1949 XMALLOC_ZERO_CFLAGS="" 1950 XTMALLOC_ZERO_CFLAGS="" 1951fi 1952 1953AC_SUBST([MALLOC_ZERO_CFLAGS]) 1954AC_SUBST([XMALLOC_ZERO_CFLAGS]) 1955AC_SUBST([XTMALLOC_ZERO_CFLAGS]) 1956]) # XORG_CHECK_MALLOC_ZERO 1957 1958# XORG_WITH_LINT() 1959# ---------------- 1960# Minimum version: 1.1.0 1961# 1962# This macro enables the use of a tool that flags some suspicious and 1963# non-portable constructs (likely to be bugs) in C language source code. 1964# It will attempt to locate the tool and use appropriate options. 1965# There are various lint type tools on different platforms. 1966# 1967# Interface to module: 1968# LINT: returns the path to the tool found on the platform 1969# or the value set to LINT on the configure cmd line 1970# also an Automake conditional 1971# LINT_FLAGS: an Automake variable with appropriate flags 1972# 1973# --with-lint: 'yes' user instructs the module to use lint 1974# 'no' user instructs the module not to use lint (default) 1975# 1976# If the user sets the value of LINT, AC_PATH_PROG skips testing the path. 1977# If the user sets the value of LINT_FLAGS, they are used verbatim. 1978# 1979AC_DEFUN([XORG_WITH_LINT],[ 1980 1981AC_ARG_VAR([LINT], [Path to a lint-style command]) 1982AC_ARG_VAR([LINT_FLAGS], [Flags for the lint-style command]) 1983AC_ARG_WITH(lint, [AS_HELP_STRING([--with-lint], 1984 [Use a lint-style source code checker (default: disabled)])], 1985 [use_lint=$withval], [use_lint=no]) 1986 1987# Obtain platform specific info like program name and options 1988# The lint program on FreeBSD and NetBSD is different from the one on Solaris 1989case $host_os in 1990 *linux* | *openbsd* | kfreebsd*-gnu | darwin* | cygwin*) 1991 lint_name=splint 1992 lint_options="-badflag" 1993 ;; 1994 *freebsd* | *netbsd*) 1995 lint_name=lint 1996 lint_options="-u -b" 1997 ;; 1998 *solaris*) 1999 lint_name=lint 2000 lint_options="-u -b -h -erroff=E_INDISTING_FROM_TRUNC2" 2001 ;; 2002esac 2003 2004# Test for the presence of the program (either guessed by the code or spelled out by the user) 2005if test "x$use_lint" = x"yes" ; then 2006 AC_PATH_PROG([LINT], [$lint_name]) 2007 if test "x$LINT" = "x"; then 2008 AC_MSG_ERROR([--with-lint=yes specified but lint-style tool not found in PATH]) 2009 fi 2010elif test "x$use_lint" = x"no" ; then 2011 if test "x$LINT" != "x"; then 2012 AC_MSG_WARN([ignoring LINT environment variable since --with-lint=no was specified]) 2013 fi 2014else 2015 AC_MSG_ERROR([--with-lint expects 'yes' or 'no'. Use LINT variable to specify path.]) 2016fi 2017 2018# User supplied flags override default flags 2019if test "x$LINT_FLAGS" != "x"; then 2020 lint_options=$LINT_FLAGS 2021fi 2022 2023AC_SUBST([LINT_FLAGS],[$lint_options]) 2024AM_CONDITIONAL(LINT, [test "x$LINT" != x]) 2025 2026]) # XORG_WITH_LINT 2027 2028# XORG_LINT_LIBRARY(LIBNAME) 2029# -------------------------- 2030# Minimum version: 1.1.0 2031# 2032# Sets up flags for building lint libraries for checking programs that call 2033# functions in the library. 2034# 2035# Interface to module: 2036# LINTLIB - Automake variable with the name of lint library file to make 2037# MAKE_LINT_LIB - Automake conditional 2038# 2039# --enable-lint-library: - 'yes' user instructs the module to created a lint library 2040# - 'no' user instructs the module not to create a lint library (default) 2041 2042AC_DEFUN([XORG_LINT_LIBRARY],[ 2043AC_REQUIRE([XORG_WITH_LINT]) 2044AC_ARG_ENABLE(lint-library, [AS_HELP_STRING([--enable-lint-library], 2045 [Create lint library (default: disabled)])], 2046 [make_lint_lib=$enableval], [make_lint_lib=no]) 2047 2048if test "x$make_lint_lib" = x"yes" ; then 2049 LINTLIB=llib-l$1.ln 2050 if test "x$LINT" = "x"; then 2051 AC_MSG_ERROR([Cannot make lint library without --with-lint]) 2052 fi 2053elif test "x$make_lint_lib" != x"no" ; then 2054 AC_MSG_ERROR([--enable-lint-library expects 'yes' or 'no'.]) 2055fi 2056 2057AC_SUBST(LINTLIB) 2058AM_CONDITIONAL(MAKE_LINT_LIB, [test x$make_lint_lib != xno]) 2059 2060]) # XORG_LINT_LIBRARY 2061 2062# XORG_CWARNFLAGS 2063# --------------- 2064# Minimum version: 1.2.0 2065# 2066# Defines CWARNFLAGS to enable C compiler warnings. 2067# 2068AC_DEFUN([XORG_CWARNFLAGS], [ 2069AC_REQUIRE([AC_PROG_CC_C99]) 2070if test "x$GCC" = xyes ; then 2071 CWARNFLAGS="-Wall -Wpointer-arith -Wstrict-prototypes -Wmissing-prototypes \ 2072-Wmissing-declarations -Wnested-externs -fno-strict-aliasing \ 2073-Wbad-function-cast -Wformat=2" 2074 case `$CC -dumpversion` in 2075 3.4.* | 4.*) 2076 CWARNFLAGS="$CWARNFLAGS -Wold-style-definition -Wdeclaration-after-statement" 2077 ;; 2078 esac 2079else 2080 AC_CHECK_DECL([__SUNPRO_C], [SUNCC="yes"], [SUNCC="no"]) 2081 if test "x$SUNCC" = "xyes"; then 2082 CWARNFLAGS="-v" 2083 fi 2084fi 2085AC_SUBST(CWARNFLAGS) 2086]) # XORG_CWARNFLAGS 2087 2088# XORG_STRICT_OPTION 2089# ----------------------- 2090# Minimum version: 1.3.0 2091# 2092# Add configure option to enable strict compilation 2093AC_DEFUN([XORG_STRICT_OPTION], [ 2094# If the module's configure.ac calls AC_PROG_CC later on, CC gets set to C89 2095AC_REQUIRE([AC_PROG_CC_C99]) 2096AC_REQUIRE([XORG_CWARNFLAGS]) 2097 2098AC_ARG_ENABLE(strict-compilation, 2099 AS_HELP_STRING([--enable-strict-compilation], 2100 [Enable all warnings from compiler and make them errors (default: disabled)]), 2101 [STRICT_COMPILE=$enableval], [STRICT_COMPILE=no]) 2102if test "x$STRICT_COMPILE" = "xyes"; then 2103 AC_CHECK_DECL([__SUNPRO_C], [SUNCC="yes"], [SUNCC="no"]) 2104 AC_CHECK_DECL([__INTEL_COMPILER], [INTELCC="yes"], [INTELCC="no"]) 2105 if test "x$GCC" = xyes ; then 2106 STRICT_CFLAGS="-pedantic -Werror" 2107 elif test "x$SUNCC" = "xyes"; then 2108 STRICT_CFLAGS="-errwarn" 2109 elif test "x$INTELCC" = "xyes"; then 2110 STRICT_CFLAGS="-Werror" 2111 fi 2112fi 2113CWARNFLAGS="$CWARNFLAGS $STRICT_CFLAGS" 2114AC_SUBST([CWARNFLAGS]) 2115]) # XORG_STRICT_OPTION 2116 2117# XORG_DEFAULT_OPTIONS 2118# -------------------- 2119# Minimum version: 1.3.0 2120# 2121# Defines default options for X.Org modules. 2122# 2123AC_DEFUN([XORG_DEFAULT_OPTIONS], [ 2124AC_REQUIRE([AC_PROG_INSTALL]) 2125XORG_CWARNFLAGS 2126XORG_STRICT_OPTION 2127XORG_RELEASE_VERSION 2128XORG_CHANGELOG 2129XORG_INSTALL 2130XORG_MANPAGE_SECTIONS 2131m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])], 2132 [AC_SUBST([AM_DEFAULT_VERBOSITY], [1])]) 2133]) # XORG_DEFAULT_OPTIONS 2134 2135# XORG_INSTALL() 2136# ---------------- 2137# Minimum version: 1.4.0 2138# 2139# Defines the variable INSTALL_CMD as the command to copy 2140# INSTALL from $prefix/share/util-macros. 2141# 2142AC_DEFUN([XORG_INSTALL], [ 2143AC_REQUIRE([PKG_PROG_PKG_CONFIG]) 2144macros_datadir=`$PKG_CONFIG --print-errors --variable=pkgdatadir xorg-macros` 2145INSTALL_CMD="(cp -f "$macros_datadir/INSTALL" \$(top_srcdir)/.INSTALL.tmp && \ 2146mv \$(top_srcdir)/.INSTALL.tmp \$(top_srcdir)/INSTALL) \ 2147|| (rm -f \$(top_srcdir)/.INSTALL.tmp; touch \$(top_srcdir)/INSTALL; \ 2148echo 'util-macros \"pkgdatadir\" from xorg-macros.pc not found: installing possibly empty INSTALL.' >&2)" 2149AC_SUBST([INSTALL_CMD]) 2150]) # XORG_INSTALL 2151dnl Copyright 2005 Red Hat, Inc 2152dnl 2153dnl Permission to use, copy, modify, distribute, and sell this software and its 2154dnl documentation for any purpose is hereby granted without fee, provided that 2155dnl the above copyright notice appear in all copies and that both that 2156dnl copyright notice and this permission notice appear in supporting 2157dnl documentation. 2158dnl 2159dnl The above copyright notice and this permission notice shall be included 2160dnl in all copies or substantial portions of the Software. 2161dnl 2162dnl THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS 2163dnl OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 2164dnl MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 2165dnl IN NO EVENT SHALL THE OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR 2166dnl OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, 2167dnl ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 2168dnl OTHER DEALINGS IN THE SOFTWARE. 2169dnl 2170dnl Except as contained in this notice, the name of the copyright holders shall 2171dnl not be used in advertising or otherwise to promote the sale, use or 2172dnl other dealings in this Software without prior written authorization 2173dnl from the copyright holders. 2174dnl 2175 2176# XORG_RELEASE_VERSION 2177# -------------------- 2178# Defines PACKAGE_VERSION_{MAJOR,MINOR,PATCHLEVEL} for modules to use. 2179 2180AC_DEFUN([XORG_RELEASE_VERSION],[ 2181 AC_DEFINE_UNQUOTED([PACKAGE_VERSION_MAJOR], 2182 [`echo $PACKAGE_VERSION | cut -d . -f 1`], 2183 [Major version of this package]) 2184 PVM=`echo $PACKAGE_VERSION | cut -d . -f 2 | cut -d - -f 1` 2185 if test "x$PVM" = "x"; then 2186 PVM="0" 2187 fi 2188 AC_DEFINE_UNQUOTED([PACKAGE_VERSION_MINOR], 2189 [$PVM], 2190 [Minor version of this package]) 2191 PVP=`echo $PACKAGE_VERSION | cut -d . -f 3 | cut -d - -f 1` 2192 if test "x$PVP" = "x"; then 2193 PVP="0" 2194 fi 2195 AC_DEFINE_UNQUOTED([PACKAGE_VERSION_PATCHLEVEL], 2196 [$PVP], 2197 [Patch version of this package]) 2198]) 2199 2200# XORG_CHANGELOG() 2201# ---------------- 2202# Minimum version: 1.2.0 2203# 2204# Defines the variable CHANGELOG_CMD as the command to generate 2205# ChangeLog from git. 2206# 2207# 2208AC_DEFUN([XORG_CHANGELOG], [ 2209CHANGELOG_CMD="(GIT_DIR=\$(top_srcdir)/.git git log > \$(top_srcdir)/.changelog.tmp && \ 2210mv \$(top_srcdir)/.changelog.tmp \$(top_srcdir)/ChangeLog) \ 2211|| (rm -f \$(top_srcdir)/.changelog.tmp; touch \$(top_srcdir)/ChangeLog; \ 2212echo 'git directory not found: installing possibly empty changelog.' >&2)" 2213AC_SUBST([CHANGELOG_CMD]) 2214]) # XORG_CHANGELOG 2215 2216# pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*- 2217# 2218# Copyright © 2004 Scott James Remnant <scott@netsplit.com>. 2219# 2220# This program is free software; you can redistribute it and/or modify 2221# it under the terms of the GNU General Public License as published by 2222# the Free Software Foundation; either version 2 of the License, or 2223# (at your option) any later version. 2224# 2225# This program is distributed in the hope that it will be useful, but 2226# WITHOUT ANY WARRANTY; without even the implied warranty of 2227# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 2228# General Public License for more details. 2229# 2230# You should have received a copy of the GNU General Public License 2231# along with this program; if not, write to the Free Software 2232# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 2233# 2234# As a special exception to the GNU General Public License, if you 2235# distribute this file as part of a program that contains a 2236# configuration script generated by Autoconf, you may include it under 2237# the same distribution terms that you use for the rest of that program. 2238 2239# PKG_PROG_PKG_CONFIG([MIN-VERSION]) 2240# ---------------------------------- 2241AC_DEFUN([PKG_PROG_PKG_CONFIG], 2242[m4_pattern_forbid([^_?PKG_[A-Z_]+$]) 2243m4_pattern_allow([^PKG_CONFIG(_PATH)?$]) 2244AC_ARG_VAR([PKG_CONFIG], [path to pkg-config utility])dnl 2245if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then 2246 AC_PATH_TOOL([PKG_CONFIG], [pkg-config]) 2247fi 2248if test -n "$PKG_CONFIG"; then 2249 _pkg_min_version=m4_default([$1], [0.9.0]) 2250 AC_MSG_CHECKING([pkg-config is at least version $_pkg_min_version]) 2251 if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then 2252 AC_MSG_RESULT([yes]) 2253 else 2254 AC_MSG_RESULT([no]) 2255 PKG_CONFIG="" 2256 fi 2257 2258fi[]dnl 2259])# PKG_PROG_PKG_CONFIG 2260 2261# PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) 2262# 2263# Check to see whether a particular set of modules exists. Similar 2264# to PKG_CHECK_MODULES(), but does not set variables or print errors. 2265# 2266# 2267# Similar to PKG_CHECK_MODULES, make sure that the first instance of 2268# this or PKG_CHECK_MODULES is called, or make sure to call 2269# PKG_CHECK_EXISTS manually 2270# -------------------------------------------------------------- 2271AC_DEFUN([PKG_CHECK_EXISTS], 2272[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl 2273if test -n "$PKG_CONFIG" && \ 2274 AC_RUN_LOG([$PKG_CONFIG --exists --print-errors "$1"]); then 2275 m4_ifval([$2], [$2], [:]) 2276m4_ifvaln([$3], [else 2277 $3])dnl 2278fi]) 2279 2280 2281# _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES]) 2282# --------------------------------------------- 2283m4_define([_PKG_CONFIG], 2284[if test -n "$$1"; then 2285 pkg_cv_[]$1="$$1" 2286 elif test -n "$PKG_CONFIG"; then 2287 PKG_CHECK_EXISTS([$3], 2288 [pkg_cv_[]$1=`$PKG_CONFIG --[]$2 "$3" 2>/dev/null`], 2289 [pkg_failed=yes]) 2290 else 2291 pkg_failed=untried 2292fi[]dnl 2293])# _PKG_CONFIG 2294 2295# _PKG_SHORT_ERRORS_SUPPORTED 2296# ----------------------------- 2297AC_DEFUN([_PKG_SHORT_ERRORS_SUPPORTED], 2298[AC_REQUIRE([PKG_PROG_PKG_CONFIG]) 2299if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 2300 _pkg_short_errors_supported=yes 2301else 2302 _pkg_short_errors_supported=no 2303fi[]dnl 2304])# _PKG_SHORT_ERRORS_SUPPORTED 2305 2306 2307# PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND], 2308# [ACTION-IF-NOT-FOUND]) 2309# 2310# 2311# Note that if there is a possibility the first call to 2312# PKG_CHECK_MODULES might not happen, you should be sure to include an 2313# explicit call to PKG_PROG_PKG_CONFIG in your configure.ac 2314# 2315# 2316# -------------------------------------------------------------- 2317AC_DEFUN([PKG_CHECK_MODULES], 2318[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl 2319AC_ARG_VAR([$1][_CFLAGS], [C compiler flags for $1, overriding pkg-config])dnl 2320AC_ARG_VAR([$1][_LIBS], [linker flags for $1, overriding pkg-config])dnl 2321 2322pkg_failed=no 2323AC_MSG_CHECKING([for $1]) 2324 2325_PKG_CONFIG([$1][_CFLAGS], [cflags], [$2]) 2326_PKG_CONFIG([$1][_LIBS], [libs], [$2]) 2327 2328m4_define([_PKG_TEXT], [Alternatively, you may set the environment variables $1[]_CFLAGS 2329and $1[]_LIBS to avoid the need to call pkg-config. 2330See the pkg-config man page for more details.]) 2331 2332if test $pkg_failed = yes; then 2333 _PKG_SHORT_ERRORS_SUPPORTED 2334 if test $_pkg_short_errors_supported = yes; then 2335 $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "$2" 2>&1` 2336 else 2337 $1[]_PKG_ERRORS=`$PKG_CONFIG --print-errors "$2" 2>&1` 2338 fi 2339 # Put the nasty error message in config.log where it belongs 2340 echo "$$1[]_PKG_ERRORS" >&AS_MESSAGE_LOG_FD 2341 2342 ifelse([$4], , [AC_MSG_ERROR(dnl 2343[Package requirements ($2) were not met: 2344 2345$$1_PKG_ERRORS 2346 2347Consider adjusting the PKG_CONFIG_PATH environment variable if you 2348installed software in a non-standard prefix. 2349 2350_PKG_TEXT 2351])], 2352 [AC_MSG_RESULT([no]) 2353 $4]) 2354elif test $pkg_failed = untried; then 2355 ifelse([$4], , [AC_MSG_FAILURE(dnl 2356[The pkg-config script could not be found or is too old. Make sure it 2357is in your PATH or set the PKG_CONFIG environment variable to the full 2358path to pkg-config. 2359 2360_PKG_TEXT 2361 2362To get pkg-config, see <http://pkg-config.freedesktop.org/>.])], 2363 [$4]) 2364else 2365 $1[]_CFLAGS=$pkg_cv_[]$1[]_CFLAGS 2366 $1[]_LIBS=$pkg_cv_[]$1[]_LIBS 2367 AC_MSG_RESULT([yes]) 2368 ifelse([$3], , :, [$3]) 2369fi[]dnl 2370])# PKG_CHECK_MODULES 2371 2372# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*- 2373# 2374# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 2375# 2006, 2007, 2008, 2009, 2010 Free Software Foundation, 2376# Inc. 2377# Written by Gordon Matzigkeit, 1996 2378# 2379# This file is free software; the Free Software Foundation gives 2380# unlimited permission to copy and/or distribute it, with or without 2381# modifications, as long as this notice is preserved. 2382 2383m4_define([_LT_COPYING], [dnl 2384# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 2385# 2006, 2007, 2008, 2009, 2010 Free Software Foundation, 2386# Inc. 2387# Written by Gordon Matzigkeit, 1996 2388# 2389# This file is part of GNU Libtool. 2390# 2391# GNU Libtool is free software; you can redistribute it and/or 2392# modify it under the terms of the GNU General Public License as 2393# published by the Free Software Foundation; either version 2 of 2394# the License, or (at your option) any later version. 2395# 2396# As a special exception to the GNU General Public License, 2397# if you distribute this file as part of a program or library that 2398# is built using GNU Libtool, you may include this file under the 2399# same distribution terms that you use for the rest of that program. 2400# 2401# GNU Libtool is distributed in the hope that it will be useful, 2402# but WITHOUT ANY WARRANTY; without even the implied warranty of 2403# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 2404# GNU General Public License for more details. 2405# 2406# You should have received a copy of the GNU General Public License 2407# along with GNU Libtool; see the file COPYING. If not, a copy 2408# can be downloaded from http://www.gnu.org/licenses/gpl.html, or 2409# obtained by writing to the Free Software Foundation, Inc., 2410# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 2411]) 2412 2413# serial 57 LT_INIT 2414 2415 2416# LT_PREREQ(VERSION) 2417# ------------------ 2418# Complain and exit if this libtool version is less that VERSION. 2419m4_defun([LT_PREREQ], 2420[m4_if(m4_version_compare(m4_defn([LT_PACKAGE_VERSION]), [$1]), -1, 2421 [m4_default([$3], 2422 [m4_fatal([Libtool version $1 or higher is required], 2423 63)])], 2424 [$2])]) 2425 2426 2427# _LT_CHECK_BUILDDIR 2428# ------------------ 2429# Complain if the absolute build directory name contains unusual characters 2430m4_defun([_LT_CHECK_BUILDDIR], 2431[case `pwd` in 2432 *\ * | *\ *) 2433 AC_MSG_WARN([Libtool does not cope well with whitespace in `pwd`]) ;; 2434esac 2435]) 2436 2437 2438# LT_INIT([OPTIONS]) 2439# ------------------ 2440AC_DEFUN([LT_INIT], 2441[AC_PREREQ([2.58])dnl We use AC_INCLUDES_DEFAULT 2442AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl 2443AC_BEFORE([$0], [LT_LANG])dnl 2444AC_BEFORE([$0], [LT_OUTPUT])dnl 2445AC_BEFORE([$0], [LTDL_INIT])dnl 2446m4_require([_LT_CHECK_BUILDDIR])dnl 2447 2448dnl Autoconf doesn't catch unexpanded LT_ macros by default: 2449m4_pattern_forbid([^_?LT_[A-Z_]+$])dnl 2450m4_pattern_allow([^(_LT_EOF|LT_DLGLOBAL|LT_DLLAZY_OR_NOW|LT_MULTI_MODULE)$])dnl 2451dnl aclocal doesn't pull ltoptions.m4, ltsugar.m4, or ltversion.m4 2452dnl unless we require an AC_DEFUNed macro: 2453AC_REQUIRE([LTOPTIONS_VERSION])dnl 2454AC_REQUIRE([LTSUGAR_VERSION])dnl 2455AC_REQUIRE([LTVERSION_VERSION])dnl 2456AC_REQUIRE([LTOBSOLETE_VERSION])dnl 2457m4_require([_LT_PROG_LTMAIN])dnl 2458 2459_LT_SHELL_INIT([SHELL=${CONFIG_SHELL-/bin/sh}]) 2460 2461dnl Parse OPTIONS 2462_LT_SET_OPTIONS([$0], [$1]) 2463 2464# This can be used to rebuild libtool when needed 2465LIBTOOL_DEPS="$ltmain" 2466 2467# Always use our own libtool. 2468LIBTOOL='$(SHELL) $(top_builddir)/libtool' 2469AC_SUBST(LIBTOOL)dnl 2470 2471_LT_SETUP 2472 2473# Only expand once: 2474m4_define([LT_INIT]) 2475])# LT_INIT 2476 2477# Old names: 2478AU_ALIAS([AC_PROG_LIBTOOL], [LT_INIT]) 2479AU_ALIAS([AM_PROG_LIBTOOL], [LT_INIT]) 2480dnl aclocal-1.4 backwards compatibility: 2481dnl AC_DEFUN([AC_PROG_LIBTOOL], []) 2482dnl AC_DEFUN([AM_PROG_LIBTOOL], []) 2483 2484 2485# _LT_CC_BASENAME(CC) 2486# ------------------- 2487# Calculate cc_basename. Skip known compiler wrappers and cross-prefix. 2488m4_defun([_LT_CC_BASENAME], 2489[for cc_temp in $1""; do 2490 case $cc_temp in 2491 compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;; 2492 distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;; 2493 \-*) ;; 2494 *) break;; 2495 esac 2496done 2497cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` 2498]) 2499 2500 2501# _LT_FILEUTILS_DEFAULTS 2502# ---------------------- 2503# It is okay to use these file commands and assume they have been set 2504# sensibly after `m4_require([_LT_FILEUTILS_DEFAULTS])'. 2505m4_defun([_LT_FILEUTILS_DEFAULTS], 2506[: ${CP="cp -f"} 2507: ${MV="mv -f"} 2508: ${RM="rm -f"} 2509])# _LT_FILEUTILS_DEFAULTS 2510 2511 2512# _LT_SETUP 2513# --------- 2514m4_defun([_LT_SETUP], 2515[AC_REQUIRE([AC_CANONICAL_HOST])dnl 2516AC_REQUIRE([AC_CANONICAL_BUILD])dnl 2517AC_REQUIRE([_LT_PREPARE_SED_QUOTE_VARS])dnl 2518AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl 2519 2520_LT_DECL([], [host_alias], [0], [The host system])dnl 2521_LT_DECL([], [host], [0])dnl 2522_LT_DECL([], [host_os], [0])dnl 2523dnl 2524_LT_DECL([], [build_alias], [0], [The build system])dnl 2525_LT_DECL([], [build], [0])dnl 2526_LT_DECL([], [build_os], [0])dnl 2527dnl 2528AC_REQUIRE([AC_PROG_CC])dnl 2529AC_REQUIRE([LT_PATH_LD])dnl 2530AC_REQUIRE([LT_PATH_NM])dnl 2531dnl 2532AC_REQUIRE([AC_PROG_LN_S])dnl 2533test -z "$LN_S" && LN_S="ln -s" 2534_LT_DECL([], [LN_S], [1], [Whether we need soft or hard links])dnl 2535dnl 2536AC_REQUIRE([LT_CMD_MAX_LEN])dnl 2537_LT_DECL([objext], [ac_objext], [0], [Object file suffix (normally "o")])dnl 2538_LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl 2539dnl 2540m4_require([_LT_FILEUTILS_DEFAULTS])dnl 2541m4_require([_LT_CHECK_SHELL_FEATURES])dnl 2542m4_require([_LT_CMD_RELOAD])dnl 2543m4_require([_LT_CHECK_MAGIC_METHOD])dnl 2544m4_require([_LT_CMD_OLD_ARCHIVE])dnl 2545m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl 2546 2547_LT_CONFIG_LIBTOOL_INIT([ 2548# See if we are running on zsh, and set the options which allow our 2549# commands through without removal of \ escapes INIT. 2550if test -n "\${ZSH_VERSION+set}" ; then 2551 setopt NO_GLOB_SUBST 2552fi 2553]) 2554if test -n "${ZSH_VERSION+set}" ; then 2555 setopt NO_GLOB_SUBST 2556fi 2557 2558_LT_CHECK_OBJDIR 2559 2560m4_require([_LT_TAG_COMPILER])dnl 2561 2562case $host_os in 2563aix3*) 2564 # AIX sometimes has problems with the GCC collect2 program. For some 2565 # reason, if we set the COLLECT_NAMES environment variable, the problems 2566 # vanish in a puff of smoke. 2567 if test "X${COLLECT_NAMES+set}" != Xset; then 2568 COLLECT_NAMES= 2569 export COLLECT_NAMES 2570 fi 2571 ;; 2572esac 2573 2574# Global variables: 2575ofile=libtool 2576can_build_shared=yes 2577 2578# All known linkers require a `.a' archive for static linking (except MSVC, 2579# which needs '.lib'). 2580libext=a 2581 2582with_gnu_ld="$lt_cv_prog_gnu_ld" 2583 2584old_CC="$CC" 2585old_CFLAGS="$CFLAGS" 2586 2587# Set sane defaults for various variables 2588test -z "$CC" && CC=cc 2589test -z "$LTCC" && LTCC=$CC 2590test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS 2591test -z "$LD" && LD=ld 2592test -z "$ac_objext" && ac_objext=o 2593 2594_LT_CC_BASENAME([$compiler]) 2595 2596# Only perform the check for file, if the check method requires it 2597test -z "$MAGIC_CMD" && MAGIC_CMD=file 2598case $deplibs_check_method in 2599file_magic*) 2600 if test "$file_magic_cmd" = '$MAGIC_CMD'; then 2601 _LT_PATH_MAGIC 2602 fi 2603 ;; 2604esac 2605 2606# Use C for the default configuration in the libtool script 2607LT_SUPPORTED_TAG([CC]) 2608_LT_LANG_C_CONFIG 2609_LT_LANG_DEFAULT_CONFIG 2610_LT_CONFIG_COMMANDS 2611])# _LT_SETUP 2612 2613 2614# _LT_PREPARE_SED_QUOTE_VARS 2615# -------------------------- 2616# Define a few sed substitution that help us do robust quoting. 2617m4_defun([_LT_PREPARE_SED_QUOTE_VARS], 2618[# Backslashify metacharacters that are still active within 2619# double-quoted strings. 2620sed_quote_subst='s/\([["`$\\]]\)/\\\1/g' 2621 2622# Same as above, but do not quote variable references. 2623double_quote_subst='s/\([["`\\]]\)/\\\1/g' 2624 2625# Sed substitution to delay expansion of an escaped shell variable in a 2626# double_quote_subst'ed string. 2627delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' 2628 2629# Sed substitution to delay expansion of an escaped single quote. 2630delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g' 2631 2632# Sed substitution to avoid accidental globbing in evaled expressions 2633no_glob_subst='s/\*/\\\*/g' 2634]) 2635 2636# _LT_PROG_LTMAIN 2637# --------------- 2638# Note that this code is called both from `configure', and `config.status' 2639# now that we use AC_CONFIG_COMMANDS to generate libtool. Notably, 2640# `config.status' has no value for ac_aux_dir unless we are using Automake, 2641# so we pass a copy along to make sure it has a sensible value anyway. 2642m4_defun([_LT_PROG_LTMAIN], 2643[m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl 2644_LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir']) 2645ltmain="$ac_aux_dir/ltmain.sh" 2646])# _LT_PROG_LTMAIN 2647 2648 2649 2650# So that we can recreate a full libtool script including additional 2651# tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS 2652# in macros and then make a single call at the end using the `libtool' 2653# label. 2654 2655 2656# _LT_CONFIG_LIBTOOL_INIT([INIT-COMMANDS]) 2657# ---------------------------------------- 2658# Register INIT-COMMANDS to be passed to AC_CONFIG_COMMANDS later. 2659m4_define([_LT_CONFIG_LIBTOOL_INIT], 2660[m4_ifval([$1], 2661 [m4_append([_LT_OUTPUT_LIBTOOL_INIT], 2662 [$1 2663])])]) 2664 2665# Initialize. 2666m4_define([_LT_OUTPUT_LIBTOOL_INIT]) 2667 2668 2669# _LT_CONFIG_LIBTOOL([COMMANDS]) 2670# ------------------------------ 2671# Register COMMANDS to be passed to AC_CONFIG_COMMANDS later. 2672m4_define([_LT_CONFIG_LIBTOOL], 2673[m4_ifval([$1], 2674 [m4_append([_LT_OUTPUT_LIBTOOL_COMMANDS], 2675 [$1 2676])])]) 2677 2678# Initialize. 2679m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS]) 2680 2681 2682# _LT_CONFIG_SAVE_COMMANDS([COMMANDS], [INIT_COMMANDS]) 2683# ----------------------------------------------------- 2684m4_defun([_LT_CONFIG_SAVE_COMMANDS], 2685[_LT_CONFIG_LIBTOOL([$1]) 2686_LT_CONFIG_LIBTOOL_INIT([$2]) 2687]) 2688 2689 2690# _LT_FORMAT_COMMENT([COMMENT]) 2691# ----------------------------- 2692# Add leading comment marks to the start of each line, and a trailing 2693# full-stop to the whole comment if one is not present already. 2694m4_define([_LT_FORMAT_COMMENT], 2695[m4_ifval([$1], [ 2696m4_bpatsubst([m4_bpatsubst([$1], [^ *], [# ])], 2697 [['`$\]], [\\\&])]m4_bmatch([$1], [[!?.]$], [], [.]) 2698)]) 2699 2700 2701 2702 2703 2704# _LT_DECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION], [IS-TAGGED?]) 2705# ------------------------------------------------------------------- 2706# CONFIGNAME is the name given to the value in the libtool script. 2707# VARNAME is the (base) name used in the configure script. 2708# VALUE may be 0, 1 or 2 for a computed quote escaped value based on 2709# VARNAME. Any other value will be used directly. 2710m4_define([_LT_DECL], 2711[lt_if_append_uniq([lt_decl_varnames], [$2], [, ], 2712 [lt_dict_add_subkey([lt_decl_dict], [$2], [libtool_name], 2713 [m4_ifval([$1], [$1], [$2])]) 2714 lt_dict_add_subkey([lt_decl_dict], [$2], [value], [$3]) 2715 m4_ifval([$4], 2716 [lt_dict_add_subkey([lt_decl_dict], [$2], [description], [$4])]) 2717 lt_dict_add_subkey([lt_decl_dict], [$2], 2718 [tagged?], [m4_ifval([$5], [yes], [no])])]) 2719]) 2720 2721 2722# _LT_TAGDECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION]) 2723# -------------------------------------------------------- 2724m4_define([_LT_TAGDECL], [_LT_DECL([$1], [$2], [$3], [$4], [yes])]) 2725 2726 2727# lt_decl_tag_varnames([SEPARATOR], [VARNAME1...]) 2728# ------------------------------------------------ 2729m4_define([lt_decl_tag_varnames], 2730[_lt_decl_filter([tagged?], [yes], $@)]) 2731 2732 2733# _lt_decl_filter(SUBKEY, VALUE, [SEPARATOR], [VARNAME1..]) 2734# --------------------------------------------------------- 2735m4_define([_lt_decl_filter], 2736[m4_case([$#], 2737 [0], [m4_fatal([$0: too few arguments: $#])], 2738 [1], [m4_fatal([$0: too few arguments: $#: $1])], 2739 [2], [lt_dict_filter([lt_decl_dict], [$1], [$2], [], lt_decl_varnames)], 2740 [3], [lt_dict_filter([lt_decl_dict], [$1], [$2], [$3], lt_decl_varnames)], 2741 [lt_dict_filter([lt_decl_dict], $@)])[]dnl 2742]) 2743 2744 2745# lt_decl_quote_varnames([SEPARATOR], [VARNAME1...]) 2746# -------------------------------------------------- 2747m4_define([lt_decl_quote_varnames], 2748[_lt_decl_filter([value], [1], $@)]) 2749 2750 2751# lt_decl_dquote_varnames([SEPARATOR], [VARNAME1...]) 2752# --------------------------------------------------- 2753m4_define([lt_decl_dquote_varnames], 2754[_lt_decl_filter([value], [2], $@)]) 2755 2756 2757# lt_decl_varnames_tagged([SEPARATOR], [VARNAME1...]) 2758# --------------------------------------------------- 2759m4_define([lt_decl_varnames_tagged], 2760[m4_assert([$# <= 2])dnl 2761_$0(m4_quote(m4_default([$1], [[, ]])), 2762 m4_ifval([$2], [[$2]], [m4_dquote(lt_decl_tag_varnames)]), 2763 m4_split(m4_normalize(m4_quote(_LT_TAGS)), [ ]))]) 2764m4_define([_lt_decl_varnames_tagged], 2765[m4_ifval([$3], [lt_combine([$1], [$2], [_], $3)])]) 2766 2767 2768# lt_decl_all_varnames([SEPARATOR], [VARNAME1...]) 2769# ------------------------------------------------ 2770m4_define([lt_decl_all_varnames], 2771[_$0(m4_quote(m4_default([$1], [[, ]])), 2772 m4_if([$2], [], 2773 m4_quote(lt_decl_varnames), 2774 m4_quote(m4_shift($@))))[]dnl 2775]) 2776m4_define([_lt_decl_all_varnames], 2777[lt_join($@, lt_decl_varnames_tagged([$1], 2778 lt_decl_tag_varnames([[, ]], m4_shift($@))))dnl 2779]) 2780 2781 2782# _LT_CONFIG_STATUS_DECLARE([VARNAME]) 2783# ------------------------------------ 2784# Quote a variable value, and forward it to `config.status' so that its 2785# declaration there will have the same value as in `configure'. VARNAME 2786# must have a single quote delimited value for this to work. 2787m4_define([_LT_CONFIG_STATUS_DECLARE], 2788[$1='`$ECHO "$][$1" | $SED "$delay_single_quote_subst"`']) 2789 2790 2791# _LT_CONFIG_STATUS_DECLARATIONS 2792# ------------------------------ 2793# We delimit libtool config variables with single quotes, so when 2794# we write them to config.status, we have to be sure to quote all 2795# embedded single quotes properly. In configure, this macro expands 2796# each variable declared with _LT_DECL (and _LT_TAGDECL) into: 2797# 2798# <var>='`$ECHO "$<var>" | $SED "$delay_single_quote_subst"`' 2799m4_defun([_LT_CONFIG_STATUS_DECLARATIONS], 2800[m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames), 2801 [m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])]) 2802 2803 2804# _LT_LIBTOOL_TAGS 2805# ---------------- 2806# Output comment and list of tags supported by the script 2807m4_defun([_LT_LIBTOOL_TAGS], 2808[_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl 2809available_tags="_LT_TAGS"dnl 2810]) 2811 2812 2813# _LT_LIBTOOL_DECLARE(VARNAME, [TAG]) 2814# ----------------------------------- 2815# Extract the dictionary values for VARNAME (optionally with TAG) and 2816# expand to a commented shell variable setting: 2817# 2818# # Some comment about what VAR is for. 2819# visible_name=$lt_internal_name 2820m4_define([_LT_LIBTOOL_DECLARE], 2821[_LT_FORMAT_COMMENT(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], 2822 [description])))[]dnl 2823m4_pushdef([_libtool_name], 2824 m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [libtool_name])))[]dnl 2825m4_case(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [value])), 2826 [0], [_libtool_name=[$]$1], 2827 [1], [_libtool_name=$lt_[]$1], 2828 [2], [_libtool_name=$lt_[]$1], 2829 [_libtool_name=lt_dict_fetch([lt_decl_dict], [$1], [value])])[]dnl 2830m4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl 2831]) 2832 2833 2834# _LT_LIBTOOL_CONFIG_VARS 2835# ----------------------- 2836# Produce commented declarations of non-tagged libtool config variables 2837# suitable for insertion in the LIBTOOL CONFIG section of the `libtool' 2838# script. Tagged libtool config variables (even for the LIBTOOL CONFIG 2839# section) are produced by _LT_LIBTOOL_TAG_VARS. 2840m4_defun([_LT_LIBTOOL_CONFIG_VARS], 2841[m4_foreach([_lt_var], 2842 m4_quote(_lt_decl_filter([tagged?], [no], [], lt_decl_varnames)), 2843 [m4_n([_LT_LIBTOOL_DECLARE(_lt_var)])])]) 2844 2845 2846# _LT_LIBTOOL_TAG_VARS(TAG) 2847# ------------------------- 2848m4_define([_LT_LIBTOOL_TAG_VARS], 2849[m4_foreach([_lt_var], m4_quote(lt_decl_tag_varnames), 2850 [m4_n([_LT_LIBTOOL_DECLARE(_lt_var, [$1])])])]) 2851 2852 2853# _LT_TAGVAR(VARNAME, [TAGNAME]) 2854# ------------------------------ 2855m4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])]) 2856 2857 2858# _LT_CONFIG_COMMANDS 2859# ------------------- 2860# Send accumulated output to $CONFIG_STATUS. Thanks to the lists of 2861# variables for single and double quote escaping we saved from calls 2862# to _LT_DECL, we can put quote escaped variables declarations 2863# into `config.status', and then the shell code to quote escape them in 2864# for loops in `config.status'. Finally, any additional code accumulated 2865# from calls to _LT_CONFIG_LIBTOOL_INIT is expanded. 2866m4_defun([_LT_CONFIG_COMMANDS], 2867[AC_PROVIDE_IFELSE([LT_OUTPUT], 2868 dnl If the libtool generation code has been placed in $CONFIG_LT, 2869 dnl instead of duplicating it all over again into config.status, 2870 dnl then we will have config.status run $CONFIG_LT later, so it 2871 dnl needs to know what name is stored there: 2872 [AC_CONFIG_COMMANDS([libtool], 2873 [$SHELL $CONFIG_LT || AS_EXIT(1)], [CONFIG_LT='$CONFIG_LT'])], 2874 dnl If the libtool generation code is destined for config.status, 2875 dnl expand the accumulated commands and init code now: 2876 [AC_CONFIG_COMMANDS([libtool], 2877 [_LT_OUTPUT_LIBTOOL_COMMANDS], [_LT_OUTPUT_LIBTOOL_COMMANDS_INIT])]) 2878])#_LT_CONFIG_COMMANDS 2879 2880 2881# Initialize. 2882m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS_INIT], 2883[ 2884 2885# The HP-UX ksh and POSIX shell print the target directory to stdout 2886# if CDPATH is set. 2887(unset CDPATH) >/dev/null 2>&1 && unset CDPATH 2888 2889sed_quote_subst='$sed_quote_subst' 2890double_quote_subst='$double_quote_subst' 2891delay_variable_subst='$delay_variable_subst' 2892_LT_CONFIG_STATUS_DECLARATIONS 2893LTCC='$LTCC' 2894LTCFLAGS='$LTCFLAGS' 2895compiler='$compiler_DEFAULT' 2896 2897# A function that is used when there is no print builtin or printf. 2898func_fallback_echo () 2899{ 2900 eval 'cat <<_LTECHO_EOF 2901\$[]1 2902_LTECHO_EOF' 2903} 2904 2905# Quote evaled strings. 2906for var in lt_decl_all_varnames([[ \ 2907]], lt_decl_quote_varnames); do 2908 case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in 2909 *[[\\\\\\\`\\"\\\$]]*) 2910 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" 2911 ;; 2912 *) 2913 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" 2914 ;; 2915 esac 2916done 2917 2918# Double-quote double-evaled strings. 2919for var in lt_decl_all_varnames([[ \ 2920]], lt_decl_dquote_varnames); do 2921 case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in 2922 *[[\\\\\\\`\\"\\\$]]*) 2923 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" 2924 ;; 2925 *) 2926 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" 2927 ;; 2928 esac 2929done 2930 2931_LT_OUTPUT_LIBTOOL_INIT 2932]) 2933 2934# _LT_GENERATED_FILE_INIT(FILE, [COMMENT]) 2935# ------------------------------------ 2936# Generate a child script FILE with all initialization necessary to 2937# reuse the environment learned by the parent script, and make the 2938# file executable. If COMMENT is supplied, it is inserted after the 2939# `#!' sequence but before initialization text begins. After this 2940# macro, additional text can be appended to FILE to form the body of 2941# the child script. The macro ends with non-zero status if the 2942# file could not be fully written (such as if the disk is full). 2943m4_ifdef([AS_INIT_GENERATED], 2944[m4_defun([_LT_GENERATED_FILE_INIT],[AS_INIT_GENERATED($@)])], 2945[m4_defun([_LT_GENERATED_FILE_INIT], 2946[m4_require([AS_PREPARE])]dnl 2947[m4_pushdef([AS_MESSAGE_LOG_FD])]dnl 2948[lt_write_fail=0 2949cat >$1 <<_ASEOF || lt_write_fail=1 2950#! $SHELL 2951# Generated by $as_me. 2952$2 2953SHELL=\${CONFIG_SHELL-$SHELL} 2954export SHELL 2955_ASEOF 2956cat >>$1 <<\_ASEOF || lt_write_fail=1 2957AS_SHELL_SANITIZE 2958_AS_PREPARE 2959exec AS_MESSAGE_FD>&1 2960_ASEOF 2961test $lt_write_fail = 0 && chmod +x $1[]dnl 2962m4_popdef([AS_MESSAGE_LOG_FD])])])# _LT_GENERATED_FILE_INIT 2963 2964# LT_OUTPUT 2965# --------- 2966# This macro allows early generation of the libtool script (before 2967# AC_OUTPUT is called), incase it is used in configure for compilation 2968# tests. 2969AC_DEFUN([LT_OUTPUT], 2970[: ${CONFIG_LT=./config.lt} 2971AC_MSG_NOTICE([creating $CONFIG_LT]) 2972_LT_GENERATED_FILE_INIT(["$CONFIG_LT"], 2973[# Run this file to recreate a libtool stub with the current configuration.]) 2974 2975cat >>"$CONFIG_LT" <<\_LTEOF 2976lt_cl_silent=false 2977exec AS_MESSAGE_LOG_FD>>config.log 2978{ 2979 echo 2980 AS_BOX([Running $as_me.]) 2981} >&AS_MESSAGE_LOG_FD 2982 2983lt_cl_help="\ 2984\`$as_me' creates a local libtool stub from the current configuration, 2985for use in further configure time tests before the real libtool is 2986generated. 2987 2988Usage: $[0] [[OPTIONS]] 2989 2990 -h, --help print this help, then exit 2991 -V, --version print version number, then exit 2992 -q, --quiet do not print progress messages 2993 -d, --debug don't remove temporary files 2994 2995Report bugs to <bug-libtool@gnu.org>." 2996 2997lt_cl_version="\ 2998m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl 2999m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION]) 3000configured by $[0], generated by m4_PACKAGE_STRING. 3001 3002Copyright (C) 2010 Free Software Foundation, Inc. 3003This config.lt script is free software; the Free Software Foundation 3004gives unlimited permision to copy, distribute and modify it." 3005 3006while test $[#] != 0 3007do 3008 case $[1] in 3009 --version | --v* | -V ) 3010 echo "$lt_cl_version"; exit 0 ;; 3011 --help | --h* | -h ) 3012 echo "$lt_cl_help"; exit 0 ;; 3013 --debug | --d* | -d ) 3014 debug=: ;; 3015 --quiet | --q* | --silent | --s* | -q ) 3016 lt_cl_silent=: ;; 3017 3018 -*) AC_MSG_ERROR([unrecognized option: $[1] 3019Try \`$[0] --help' for more information.]) ;; 3020 3021 *) AC_MSG_ERROR([unrecognized argument: $[1] 3022Try \`$[0] --help' for more information.]) ;; 3023 esac 3024 shift 3025done 3026 3027if $lt_cl_silent; then 3028 exec AS_MESSAGE_FD>/dev/null 3029fi 3030_LTEOF 3031 3032cat >>"$CONFIG_LT" <<_LTEOF 3033_LT_OUTPUT_LIBTOOL_COMMANDS_INIT 3034_LTEOF 3035 3036cat >>"$CONFIG_LT" <<\_LTEOF 3037AC_MSG_NOTICE([creating $ofile]) 3038_LT_OUTPUT_LIBTOOL_COMMANDS 3039AS_EXIT(0) 3040_LTEOF 3041chmod +x "$CONFIG_LT" 3042 3043# configure is writing to config.log, but config.lt does its own redirection, 3044# appending to config.log, which fails on DOS, as config.log is still kept 3045# open by configure. Here we exec the FD to /dev/null, effectively closing 3046# config.log, so it can be properly (re)opened and appended to by config.lt. 3047lt_cl_success=: 3048test "$silent" = yes && 3049 lt_config_lt_args="$lt_config_lt_args --quiet" 3050exec AS_MESSAGE_LOG_FD>/dev/null 3051$SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false 3052exec AS_MESSAGE_LOG_FD>>config.log 3053$lt_cl_success || AS_EXIT(1) 3054])# LT_OUTPUT 3055 3056 3057# _LT_CONFIG(TAG) 3058# --------------- 3059# If TAG is the built-in tag, create an initial libtool script with a 3060# default configuration from the untagged config vars. Otherwise add code 3061# to config.status for appending the configuration named by TAG from the 3062# matching tagged config vars. 3063m4_defun([_LT_CONFIG], 3064[m4_require([_LT_FILEUTILS_DEFAULTS])dnl 3065_LT_CONFIG_SAVE_COMMANDS([ 3066 m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl 3067 m4_if(_LT_TAG, [C], [ 3068 # See if we are running on zsh, and set the options which allow our 3069 # commands through without removal of \ escapes. 3070 if test -n "${ZSH_VERSION+set}" ; then 3071 setopt NO_GLOB_SUBST 3072 fi 3073 3074 cfgfile="${ofile}T" 3075 trap "$RM \"$cfgfile\"; exit 1" 1 2 15 3076 $RM "$cfgfile" 3077 3078 cat <<_LT_EOF >> "$cfgfile" 3079#! $SHELL 3080 3081# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services. 3082# Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION 3083# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: 3084# NOTE: Changes made to this file will be lost: look at ltmain.sh. 3085# 3086_LT_COPYING 3087_LT_LIBTOOL_TAGS 3088 3089# ### BEGIN LIBTOOL CONFIG 3090_LT_LIBTOOL_CONFIG_VARS 3091_LT_LIBTOOL_TAG_VARS 3092# ### END LIBTOOL CONFIG 3093 3094_LT_EOF 3095 3096 case $host_os in 3097 aix3*) 3098 cat <<\_LT_EOF >> "$cfgfile" 3099# AIX sometimes has problems with the GCC collect2 program. For some 3100# reason, if we set the COLLECT_NAMES environment variable, the problems 3101# vanish in a puff of smoke. 3102if test "X${COLLECT_NAMES+set}" != Xset; then 3103 COLLECT_NAMES= 3104 export COLLECT_NAMES 3105fi 3106_LT_EOF 3107 ;; 3108 esac 3109 3110 _LT_PROG_LTMAIN 3111 3112 # We use sed instead of cat because bash on DJGPP gets confused if 3113 # if finds mixed CR/LF and LF-only lines. Since sed operates in 3114 # text mode, it properly converts lines to CR/LF. This bash problem 3115 # is reportedly fixed, but why not run on old versions too? 3116 sed '/^# Generated shell functions inserted here/q' "$ltmain" >> "$cfgfile" \ 3117 || (rm -f "$cfgfile"; exit 1) 3118 3119 _LT_PROG_XSI_SHELLFNS 3120 3121 sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \ 3122 || (rm -f "$cfgfile"; exit 1) 3123 3124 mv -f "$cfgfile" "$ofile" || 3125 (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") 3126 chmod +x "$ofile" 3127], 3128[cat <<_LT_EOF >> "$ofile" 3129 3130dnl Unfortunately we have to use $1 here, since _LT_TAG is not expanded 3131dnl in a comment (ie after a #). 3132# ### BEGIN LIBTOOL TAG CONFIG: $1 3133_LT_LIBTOOL_TAG_VARS(_LT_TAG) 3134# ### END LIBTOOL TAG CONFIG: $1 3135_LT_EOF 3136])dnl /m4_if 3137], 3138[m4_if([$1], [], [ 3139 PACKAGE='$PACKAGE' 3140 VERSION='$VERSION' 3141 TIMESTAMP='$TIMESTAMP' 3142 RM='$RM' 3143 ofile='$ofile'], []) 3144])dnl /_LT_CONFIG_SAVE_COMMANDS 3145])# _LT_CONFIG 3146 3147 3148# LT_SUPPORTED_TAG(TAG) 3149# --------------------- 3150# Trace this macro to discover what tags are supported by the libtool 3151# --tag option, using: 3152# autoconf --trace 'LT_SUPPORTED_TAG:$1' 3153AC_DEFUN([LT_SUPPORTED_TAG], []) 3154 3155 3156# C support is built-in for now 3157m4_define([_LT_LANG_C_enabled], []) 3158m4_define([_LT_TAGS], []) 3159 3160 3161# LT_LANG(LANG) 3162# ------------- 3163# Enable libtool support for the given language if not already enabled. 3164AC_DEFUN([LT_LANG], 3165[AC_BEFORE([$0], [LT_OUTPUT])dnl 3166m4_case([$1], 3167 [C], [_LT_LANG(C)], 3168 [C++], [_LT_LANG(CXX)], 3169 [Java], [_LT_LANG(GCJ)], 3170 [Fortran 77], [_LT_LANG(F77)], 3171 [Fortran], [_LT_LANG(FC)], 3172 [Windows Resource], [_LT_LANG(RC)], 3173 [m4_ifdef([_LT_LANG_]$1[_CONFIG], 3174 [_LT_LANG($1)], 3175 [m4_fatal([$0: unsupported language: "$1"])])])dnl 3176])# LT_LANG 3177 3178 3179# _LT_LANG(LANGNAME) 3180# ------------------ 3181m4_defun([_LT_LANG], 3182[m4_ifdef([_LT_LANG_]$1[_enabled], [], 3183 [LT_SUPPORTED_TAG([$1])dnl 3184 m4_append([_LT_TAGS], [$1 ])dnl 3185 m4_define([_LT_LANG_]$1[_enabled], [])dnl 3186 _LT_LANG_$1_CONFIG($1)])dnl 3187])# _LT_LANG 3188 3189 3190# _LT_LANG_DEFAULT_CONFIG 3191# ----------------------- 3192m4_defun([_LT_LANG_DEFAULT_CONFIG], 3193[AC_PROVIDE_IFELSE([AC_PROG_CXX], 3194 [LT_LANG(CXX)], 3195 [m4_define([AC_PROG_CXX], defn([AC_PROG_CXX])[LT_LANG(CXX)])]) 3196 3197AC_PROVIDE_IFELSE([AC_PROG_F77], 3198 [LT_LANG(F77)], 3199 [m4_define([AC_PROG_F77], defn([AC_PROG_F77])[LT_LANG(F77)])]) 3200 3201AC_PROVIDE_IFELSE([AC_PROG_FC], 3202 [LT_LANG(FC)], 3203 [m4_define([AC_PROG_FC], defn([AC_PROG_FC])[LT_LANG(FC)])]) 3204 3205dnl The call to [A][M_PROG_GCJ] is quoted like that to stop aclocal 3206dnl pulling things in needlessly. 3207AC_PROVIDE_IFELSE([AC_PROG_GCJ], 3208 [LT_LANG(GCJ)], 3209 [AC_PROVIDE_IFELSE([A][M_PROG_GCJ], 3210 [LT_LANG(GCJ)], 3211 [AC_PROVIDE_IFELSE([LT_PROG_GCJ], 3212 [LT_LANG(GCJ)], 3213 [m4_ifdef([AC_PROG_GCJ], 3214 [m4_define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[LT_LANG(GCJ)])]) 3215 m4_ifdef([A][M_PROG_GCJ], 3216 [m4_define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[LT_LANG(GCJ)])]) 3217 m4_ifdef([LT_PROG_GCJ], 3218 [m4_define([LT_PROG_GCJ], defn([LT_PROG_GCJ])[LT_LANG(GCJ)])])])])]) 3219 3220AC_PROVIDE_IFELSE([LT_PROG_RC], 3221 [LT_LANG(RC)], 3222 [m4_define([LT_PROG_RC], defn([LT_PROG_RC])[LT_LANG(RC)])]) 3223])# _LT_LANG_DEFAULT_CONFIG 3224 3225# Obsolete macros: 3226AU_DEFUN([AC_LIBTOOL_CXX], [LT_LANG(C++)]) 3227AU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)]) 3228AU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)]) 3229AU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)]) 3230AU_DEFUN([AC_LIBTOOL_RC], [LT_LANG(Windows Resource)]) 3231dnl aclocal-1.4 backwards compatibility: 3232dnl AC_DEFUN([AC_LIBTOOL_CXX], []) 3233dnl AC_DEFUN([AC_LIBTOOL_F77], []) 3234dnl AC_DEFUN([AC_LIBTOOL_FC], []) 3235dnl AC_DEFUN([AC_LIBTOOL_GCJ], []) 3236dnl AC_DEFUN([AC_LIBTOOL_RC], []) 3237 3238 3239# _LT_TAG_COMPILER 3240# ---------------- 3241m4_defun([_LT_TAG_COMPILER], 3242[AC_REQUIRE([AC_PROG_CC])dnl 3243 3244_LT_DECL([LTCC], [CC], [1], [A C compiler])dnl 3245_LT_DECL([LTCFLAGS], [CFLAGS], [1], [LTCC compiler flags])dnl 3246_LT_TAGDECL([CC], [compiler], [1], [A language specific compiler])dnl 3247_LT_TAGDECL([with_gcc], [GCC], [0], [Is the compiler the GNU compiler?])dnl 3248 3249# If no C compiler was specified, use CC. 3250LTCC=${LTCC-"$CC"} 3251 3252# If no C compiler flags were specified, use CFLAGS. 3253LTCFLAGS=${LTCFLAGS-"$CFLAGS"} 3254 3255# Allow CC to be a program name with arguments. 3256compiler=$CC 3257])# _LT_TAG_COMPILER 3258 3259 3260# _LT_COMPILER_BOILERPLATE 3261# ------------------------ 3262# Check for compiler boilerplate output or warnings with 3263# the simple compiler test code. 3264m4_defun([_LT_COMPILER_BOILERPLATE], 3265[m4_require([_LT_DECL_SED])dnl 3266ac_outfile=conftest.$ac_objext 3267echo "$lt_simple_compile_test_code" >conftest.$ac_ext 3268eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err 3269_lt_compiler_boilerplate=`cat conftest.err` 3270$RM conftest* 3271])# _LT_COMPILER_BOILERPLATE 3272 3273 3274# _LT_LINKER_BOILERPLATE 3275# ---------------------- 3276# Check for linker boilerplate output or warnings with 3277# the simple link test code. 3278m4_defun([_LT_LINKER_BOILERPLATE], 3279[m4_require([_LT_DECL_SED])dnl 3280ac_outfile=conftest.$ac_objext 3281echo "$lt_simple_link_test_code" >conftest.$ac_ext 3282eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err 3283_lt_linker_boilerplate=`cat conftest.err` 3284$RM -r conftest* 3285])# _LT_LINKER_BOILERPLATE 3286 3287# _LT_REQUIRED_DARWIN_CHECKS 3288# ------------------------- 3289m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[ 3290 case $host_os in 3291 rhapsody* | darwin*) 3292 AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:]) 3293 AC_CHECK_TOOL([NMEDIT], [nmedit], [:]) 3294 AC_CHECK_TOOL([LIPO], [lipo], [:]) 3295 AC_CHECK_TOOL([OTOOL], [otool], [:]) 3296 AC_CHECK_TOOL([OTOOL64], [otool64], [:]) 3297 _LT_DECL([], [DSYMUTIL], [1], 3298 [Tool to manipulate archived DWARF debug symbol files on Mac OS X]) 3299 _LT_DECL([], [NMEDIT], [1], 3300 [Tool to change global to local symbols on Mac OS X]) 3301 _LT_DECL([], [LIPO], [1], 3302 [Tool to manipulate fat objects and archives on Mac OS X]) 3303 _LT_DECL([], [OTOOL], [1], 3304 [ldd/readelf like tool for Mach-O binaries on Mac OS X]) 3305 _LT_DECL([], [OTOOL64], [1], 3306 [ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4]) 3307 3308 AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod], 3309 [lt_cv_apple_cc_single_mod=no 3310 if test -z "${LT_MULTI_MODULE}"; then 3311 # By default we will add the -single_module flag. You can override 3312 # by either setting the environment variable LT_MULTI_MODULE 3313 # non-empty at configure time, or by adding -multi_module to the 3314 # link flags. 3315 rm -rf libconftest.dylib* 3316 echo "int foo(void){return 1;}" > conftest.c 3317 echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ 3318-dynamiclib -Wl,-single_module conftest.c" >&AS_MESSAGE_LOG_FD 3319 $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ 3320 -dynamiclib -Wl,-single_module conftest.c 2>conftest.err 3321 _lt_result=$? 3322 if test -f libconftest.dylib && test ! -s conftest.err && test $_lt_result = 0; then 3323 lt_cv_apple_cc_single_mod=yes 3324 else 3325 cat conftest.err >&AS_MESSAGE_LOG_FD 3326 fi 3327 rm -rf libconftest.dylib* 3328 rm -f conftest.* 3329 fi]) 3330 AC_CACHE_CHECK([for -exported_symbols_list linker flag], 3331 [lt_cv_ld_exported_symbols_list], 3332 [lt_cv_ld_exported_symbols_list=no 3333 save_LDFLAGS=$LDFLAGS 3334 echo "_main" > conftest.sym 3335 LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" 3336 AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], 3337 [lt_cv_ld_exported_symbols_list=yes], 3338 [lt_cv_ld_exported_symbols_list=no]) 3339 LDFLAGS="$save_LDFLAGS" 3340 ]) 3341 AC_CACHE_CHECK([for -force_load linker flag],[lt_cv_ld_force_load], 3342 [lt_cv_ld_force_load=no 3343 cat > conftest.c << _LT_EOF 3344int forced_loaded() { return 2;} 3345_LT_EOF 3346 echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&AS_MESSAGE_LOG_FD 3347 $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD 3348 echo "$AR cru libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD 3349 $AR cru libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD 3350 echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD 3351 $RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD 3352 cat > conftest.c << _LT_EOF 3353int main() { return 0;} 3354_LT_EOF 3355 echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&AS_MESSAGE_LOG_FD 3356 $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err 3357 _lt_result=$? 3358 if test -f conftest && test ! -s conftest.err && test $_lt_result = 0 && $GREP forced_load conftest 2>&1 >/dev/null; then 3359 lt_cv_ld_force_load=yes 3360 else 3361 cat conftest.err >&AS_MESSAGE_LOG_FD 3362 fi 3363 rm -f conftest.err libconftest.a conftest conftest.c 3364 rm -rf conftest.dSYM 3365 ]) 3366 case $host_os in 3367 rhapsody* | darwin1.[[012]]) 3368 _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;; 3369 darwin1.*) 3370 _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; 3371 darwin*) # darwin 5.x on 3372 # if running on 10.5 or later, the deployment target defaults 3373 # to the OS version, if on x86, and 10.4, the deployment 3374 # target defaults to 10.4. Don't you love it? 3375 case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in 3376 10.0,*86*-darwin8*|10.0,*-darwin[[91]]*) 3377 _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; 3378 10.[[012]]*) 3379 _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; 3380 10.*) 3381 _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; 3382 esac 3383 ;; 3384 esac 3385 if test "$lt_cv_apple_cc_single_mod" = "yes"; then 3386 _lt_dar_single_mod='$single_module' 3387 fi 3388 if test "$lt_cv_ld_exported_symbols_list" = "yes"; then 3389 _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym' 3390 else 3391 _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}' 3392 fi 3393 if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then 3394 _lt_dsymutil='~$DSYMUTIL $lib || :' 3395 else 3396 _lt_dsymutil= 3397 fi 3398 ;; 3399 esac 3400]) 3401 3402 3403# _LT_DARWIN_LINKER_FEATURES 3404# -------------------------- 3405# Checks for linker and compiler features on darwin 3406m4_defun([_LT_DARWIN_LINKER_FEATURES], 3407[ 3408 m4_require([_LT_REQUIRED_DARWIN_CHECKS]) 3409 _LT_TAGVAR(archive_cmds_need_lc, $1)=no 3410 _LT_TAGVAR(hardcode_direct, $1)=no 3411 _LT_TAGVAR(hardcode_automatic, $1)=yes 3412 _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported 3413 if test "$lt_cv_ld_force_load" = "yes"; then 3414 _LT_TAGVAR(whole_archive_flag_spec, $1)='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`' 3415 else 3416 _LT_TAGVAR(whole_archive_flag_spec, $1)='' 3417 fi 3418 _LT_TAGVAR(link_all_deplibs, $1)=yes 3419 _LT_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined" 3420 case $cc_basename in 3421 ifort*) _lt_dar_can_shared=yes ;; 3422 *) _lt_dar_can_shared=$GCC ;; 3423 esac 3424 if test "$_lt_dar_can_shared" = "yes"; then 3425 output_verbose_link_cmd=func_echo_all 3426 _LT_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}" 3427 _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" 3428 _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}" 3429 _LT_TAGVAR(module_expsym_cmds, $1)="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}" 3430 m4_if([$1], [CXX], 3431[ if test "$lt_cv_apple_cc_single_mod" != "yes"; then 3432 _LT_TAGVAR(archive_cmds, $1)="\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dsymutil}" 3433 _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dar_export_syms}${_lt_dsymutil}" 3434 fi 3435],[]) 3436 else 3437 _LT_TAGVAR(ld_shlibs, $1)=no 3438 fi 3439]) 3440 3441# _LT_SYS_MODULE_PATH_AIX 3442# ----------------------- 3443# Links a minimal program and checks the executable 3444# for the system default hardcoded library path. In most cases, 3445# this is /usr/lib:/lib, but when the MPI compilers are used 3446# the location of the communication and MPI libs are included too. 3447# If we don't find anything, use the default library path according 3448# to the aix ld manual. 3449m4_defun([_LT_SYS_MODULE_PATH_AIX], 3450[m4_require([_LT_DECL_SED])dnl 3451AC_LINK_IFELSE(AC_LANG_PROGRAM,[ 3452lt_aix_libpath_sed=' 3453 /Import File Strings/,/^$/ { 3454 /^0/ { 3455 s/^0 *\(.*\)$/\1/ 3456 p 3457 } 3458 }' 3459aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` 3460# Check for a 64-bit object if we didn't find anything. 3461if test -z "$aix_libpath"; then 3462 aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` 3463fi],[]) 3464if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi 3465])# _LT_SYS_MODULE_PATH_AIX 3466 3467 3468# _LT_SHELL_INIT(ARG) 3469# ------------------- 3470m4_define([_LT_SHELL_INIT], 3471[m4_divert_text([M4SH-INIT], [$1 3472])])# _LT_SHELL_INIT 3473 3474 3475 3476# _LT_PROG_ECHO_BACKSLASH 3477# ----------------------- 3478# Find how we can fake an echo command that does not interpret backslash. 3479# In particular, with Autoconf 2.60 or later we add some code to the start 3480# of the generated configure script which will find a shell with a builtin 3481# printf (which we can use as an echo command). 3482m4_defun([_LT_PROG_ECHO_BACKSLASH], 3483[ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' 3484ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO 3485ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO 3486 3487AC_MSG_CHECKING([how to print strings]) 3488# Test print first, because it will be a builtin if present. 3489if test "X`print -r -- -n 2>/dev/null`" = X-n && \ 3490 test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then 3491 ECHO='print -r --' 3492elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then 3493 ECHO='printf %s\n' 3494else 3495 # Use this function as a fallback that always works. 3496 func_fallback_echo () 3497 { 3498 eval 'cat <<_LTECHO_EOF 3499$[]1 3500_LTECHO_EOF' 3501 } 3502 ECHO='func_fallback_echo' 3503fi 3504 3505# func_echo_all arg... 3506# Invoke $ECHO with all args, space-separated. 3507func_echo_all () 3508{ 3509 $ECHO "$*" 3510} 3511 3512case "$ECHO" in 3513 printf*) AC_MSG_RESULT([printf]) ;; 3514 print*) AC_MSG_RESULT([print -r]) ;; 3515 *) AC_MSG_RESULT([cat]) ;; 3516esac 3517 3518m4_ifdef([_AS_DETECT_SUGGESTED], 3519[_AS_DETECT_SUGGESTED([ 3520 test -n "${ZSH_VERSION+set}${BASH_VERSION+set}" || ( 3521 ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' 3522 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO 3523 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO 3524 PATH=/empty FPATH=/empty; export PATH FPATH 3525 test "X`printf %s $ECHO`" = "X$ECHO" \ 3526 || test "X`print -r -- $ECHO`" = "X$ECHO" )])]) 3527 3528_LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts]) 3529_LT_DECL([], [ECHO], [1], [An echo program that protects backslashes]) 3530])# _LT_PROG_ECHO_BACKSLASH 3531 3532 3533# _LT_ENABLE_LOCK 3534# --------------- 3535m4_defun([_LT_ENABLE_LOCK], 3536[AC_ARG_ENABLE([libtool-lock], 3537 [AS_HELP_STRING([--disable-libtool-lock], 3538 [avoid locking (might break parallel builds)])]) 3539test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes 3540 3541# Some flags need to be propagated to the compiler or linker for good 3542# libtool support. 3543case $host in 3544ia64-*-hpux*) 3545 # Find out which ABI we are using. 3546 echo 'int i;' > conftest.$ac_ext 3547 if AC_TRY_EVAL(ac_compile); then 3548 case `/usr/bin/file conftest.$ac_objext` in 3549 *ELF-32*) 3550 HPUX_IA64_MODE="32" 3551 ;; 3552 *ELF-64*) 3553 HPUX_IA64_MODE="64" 3554 ;; 3555 esac 3556 fi 3557 rm -rf conftest* 3558 ;; 3559*-*-irix6*) 3560 # Find out which ABI we are using. 3561 echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext 3562 if AC_TRY_EVAL(ac_compile); then 3563 if test "$lt_cv_prog_gnu_ld" = yes; then 3564 case `/usr/bin/file conftest.$ac_objext` in 3565 *32-bit*) 3566 LD="${LD-ld} -melf32bsmip" 3567 ;; 3568 *N32*) 3569 LD="${LD-ld} -melf32bmipn32" 3570 ;; 3571 *64-bit*) 3572 LD="${LD-ld} -melf64bmip" 3573 ;; 3574 esac 3575 else 3576 case `/usr/bin/file conftest.$ac_objext` in 3577 *32-bit*) 3578 LD="${LD-ld} -32" 3579 ;; 3580 *N32*) 3581 LD="${LD-ld} -n32" 3582 ;; 3583 *64-bit*) 3584 LD="${LD-ld} -64" 3585 ;; 3586 esac 3587 fi 3588 fi 3589 rm -rf conftest* 3590 ;; 3591 3592x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \ 3593s390*-*linux*|s390*-*tpf*|sparc*-*linux*) 3594 # Find out which ABI we are using. 3595 echo 'int i;' > conftest.$ac_ext 3596 if AC_TRY_EVAL(ac_compile); then 3597 case `/usr/bin/file conftest.o` in 3598 *32-bit*) 3599 case $host in 3600 x86_64-*kfreebsd*-gnu) 3601 LD="${LD-ld} -m elf_i386_fbsd" 3602 ;; 3603 x86_64-*linux*) 3604 LD="${LD-ld} -m elf_i386" 3605 ;; 3606 ppc64-*linux*|powerpc64-*linux*) 3607 LD="${LD-ld} -m elf32ppclinux" 3608 ;; 3609 s390x-*linux*) 3610 LD="${LD-ld} -m elf_s390" 3611 ;; 3612 sparc64-*linux*) 3613 LD="${LD-ld} -m elf32_sparc" 3614 ;; 3615 esac 3616 ;; 3617 *64-bit*) 3618 case $host in 3619 x86_64-*kfreebsd*-gnu) 3620 LD="${LD-ld} -m elf_x86_64_fbsd" 3621 ;; 3622 x86_64-*linux*) 3623 LD="${LD-ld} -m elf_x86_64" 3624 ;; 3625 ppc*-*linux*|powerpc*-*linux*) 3626 LD="${LD-ld} -m elf64ppc" 3627 ;; 3628 s390*-*linux*|s390*-*tpf*) 3629 LD="${LD-ld} -m elf64_s390" 3630 ;; 3631 sparc*-*linux*) 3632 LD="${LD-ld} -m elf64_sparc" 3633 ;; 3634 esac 3635 ;; 3636 esac 3637 fi 3638 rm -rf conftest* 3639 ;; 3640 3641*-*-sco3.2v5*) 3642 # On SCO OpenServer 5, we need -belf to get full-featured binaries. 3643 SAVE_CFLAGS="$CFLAGS" 3644 CFLAGS="$CFLAGS -belf" 3645 AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf, 3646 [AC_LANG_PUSH(C) 3647 AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no]) 3648 AC_LANG_POP]) 3649 if test x"$lt_cv_cc_needs_belf" != x"yes"; then 3650 # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf 3651 CFLAGS="$SAVE_CFLAGS" 3652 fi 3653 ;; 3654sparc*-*solaris*) 3655 # Find out which ABI we are using. 3656 echo 'int i;' > conftest.$ac_ext 3657 if AC_TRY_EVAL(ac_compile); then 3658 case `/usr/bin/file conftest.o` in 3659 *64-bit*) 3660 case $lt_cv_prog_gnu_ld in 3661 yes*) LD="${LD-ld} -m elf64_sparc" ;; 3662 *) 3663 if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then 3664 LD="${LD-ld} -64" 3665 fi 3666 ;; 3667 esac 3668 ;; 3669 esac 3670 fi 3671 rm -rf conftest* 3672 ;; 3673esac 3674 3675need_locks="$enable_libtool_lock" 3676])# _LT_ENABLE_LOCK 3677 3678 3679# _LT_CMD_OLD_ARCHIVE 3680# ------------------- 3681m4_defun([_LT_CMD_OLD_ARCHIVE], 3682[AC_CHECK_TOOL(AR, ar, false) 3683test -z "$AR" && AR=ar 3684test -z "$AR_FLAGS" && AR_FLAGS=cru 3685_LT_DECL([], [AR], [1], [The archiver]) 3686_LT_DECL([], [AR_FLAGS], [1]) 3687 3688AC_CHECK_TOOL(STRIP, strip, :) 3689test -z "$STRIP" && STRIP=: 3690_LT_DECL([], [STRIP], [1], [A symbol stripping program]) 3691 3692AC_CHECK_TOOL(RANLIB, ranlib, :) 3693test -z "$RANLIB" && RANLIB=: 3694_LT_DECL([], [RANLIB], [1], 3695 [Commands used to install an old-style archive]) 3696 3697# Determine commands to create old-style static archives. 3698old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' 3699old_postinstall_cmds='chmod 644 $oldlib' 3700old_postuninstall_cmds= 3701 3702if test -n "$RANLIB"; then 3703 case $host_os in 3704 openbsd*) 3705 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib" 3706 ;; 3707 *) 3708 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib" 3709 ;; 3710 esac 3711 old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib" 3712fi 3713 3714case $host_os in 3715 darwin*) 3716 lock_old_archive_extraction=yes ;; 3717 *) 3718 lock_old_archive_extraction=no ;; 3719esac 3720_LT_DECL([], [old_postinstall_cmds], [2]) 3721_LT_DECL([], [old_postuninstall_cmds], [2]) 3722_LT_TAGDECL([], [old_archive_cmds], [2], 3723 [Commands used to build an old-style archive]) 3724_LT_DECL([], [lock_old_archive_extraction], [0], 3725 [Whether to use a lock for old archive extraction]) 3726])# _LT_CMD_OLD_ARCHIVE 3727 3728 3729# _LT_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, 3730# [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE]) 3731# ---------------------------------------------------------------- 3732# Check whether the given compiler option works 3733AC_DEFUN([_LT_COMPILER_OPTION], 3734[m4_require([_LT_FILEUTILS_DEFAULTS])dnl 3735m4_require([_LT_DECL_SED])dnl 3736AC_CACHE_CHECK([$1], [$2], 3737 [$2=no 3738 m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4]) 3739 echo "$lt_simple_compile_test_code" > conftest.$ac_ext 3740 lt_compiler_flag="$3" 3741 # Insert the option either (1) after the last *FLAGS variable, or 3742 # (2) before a word containing "conftest.", or (3) at the end. 3743 # Note that $ac_compile itself does not contain backslashes and begins 3744 # with a dollar sign (not a hyphen), so the echo should work correctly. 3745 # The option is referenced via a variable to avoid confusing sed. 3746 lt_compile=`echo "$ac_compile" | $SED \ 3747 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ 3748 -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ 3749 -e 's:$: $lt_compiler_flag:'` 3750 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD) 3751 (eval "$lt_compile" 2>conftest.err) 3752 ac_status=$? 3753 cat conftest.err >&AS_MESSAGE_LOG_FD 3754 echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD 3755 if (exit $ac_status) && test -s "$ac_outfile"; then 3756 # The compiler can only warn and ignore the option if not recognized 3757 # So say no if there are warnings other than the usual output. 3758 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp 3759 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 3760 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then 3761 $2=yes 3762 fi 3763 fi 3764 $RM conftest* 3765]) 3766 3767if test x"[$]$2" = xyes; then 3768 m4_if([$5], , :, [$5]) 3769else 3770 m4_if([$6], , :, [$6]) 3771fi 3772])# _LT_COMPILER_OPTION 3773 3774# Old name: 3775AU_ALIAS([AC_LIBTOOL_COMPILER_OPTION], [_LT_COMPILER_OPTION]) 3776dnl aclocal-1.4 backwards compatibility: 3777dnl AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], []) 3778 3779 3780# _LT_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, 3781# [ACTION-SUCCESS], [ACTION-FAILURE]) 3782# ---------------------------------------------------- 3783# Check whether the given linker option works 3784AC_DEFUN([_LT_LINKER_OPTION], 3785[m4_require([_LT_FILEUTILS_DEFAULTS])dnl 3786m4_require([_LT_DECL_SED])dnl 3787AC_CACHE_CHECK([$1], [$2], 3788 [$2=no 3789 save_LDFLAGS="$LDFLAGS" 3790 LDFLAGS="$LDFLAGS $3" 3791 echo "$lt_simple_link_test_code" > conftest.$ac_ext 3792 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then 3793 # The linker can only warn and ignore the option if not recognized 3794 # So say no if there are warnings 3795 if test -s conftest.err; then 3796 # Append any errors to the config.log. 3797 cat conftest.err 1>&AS_MESSAGE_LOG_FD 3798 $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp 3799 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 3800 if diff conftest.exp conftest.er2 >/dev/null; then 3801 $2=yes 3802 fi 3803 else 3804 $2=yes 3805 fi 3806 fi 3807 $RM -r conftest* 3808 LDFLAGS="$save_LDFLAGS" 3809]) 3810 3811if test x"[$]$2" = xyes; then 3812 m4_if([$4], , :, [$4]) 3813else 3814 m4_if([$5], , :, [$5]) 3815fi 3816])# _LT_LINKER_OPTION 3817 3818# Old name: 3819AU_ALIAS([AC_LIBTOOL_LINKER_OPTION], [_LT_LINKER_OPTION]) 3820dnl aclocal-1.4 backwards compatibility: 3821dnl AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], []) 3822 3823 3824# LT_CMD_MAX_LEN 3825#--------------- 3826AC_DEFUN([LT_CMD_MAX_LEN], 3827[AC_REQUIRE([AC_CANONICAL_HOST])dnl 3828# find the maximum length of command line arguments 3829AC_MSG_CHECKING([the maximum length of command line arguments]) 3830AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl 3831 i=0 3832 teststring="ABCD" 3833 3834 case $build_os in 3835 msdosdjgpp*) 3836 # On DJGPP, this test can blow up pretty badly due to problems in libc 3837 # (any single argument exceeding 2000 bytes causes a buffer overrun 3838 # during glob expansion). Even if it were fixed, the result of this 3839 # check would be larger than it should be. 3840 lt_cv_sys_max_cmd_len=12288; # 12K is about right 3841 ;; 3842 3843 gnu*) 3844 # Under GNU Hurd, this test is not required because there is 3845 # no limit to the length of command line arguments. 3846 # Libtool will interpret -1 as no limit whatsoever 3847 lt_cv_sys_max_cmd_len=-1; 3848 ;; 3849 3850 cygwin* | mingw* | cegcc*) 3851 # On Win9x/ME, this test blows up -- it succeeds, but takes 3852 # about 5 minutes as the teststring grows exponentially. 3853 # Worse, since 9x/ME are not pre-emptively multitasking, 3854 # you end up with a "frozen" computer, even though with patience 3855 # the test eventually succeeds (with a max line length of 256k). 3856 # Instead, let's just punt: use the minimum linelength reported by 3857 # all of the supported platforms: 8192 (on NT/2K/XP). 3858 lt_cv_sys_max_cmd_len=8192; 3859 ;; 3860 3861 mint*) 3862 # On MiNT this can take a long time and run out of memory. 3863 lt_cv_sys_max_cmd_len=8192; 3864 ;; 3865 3866 amigaos*) 3867 # On AmigaOS with pdksh, this test takes hours, literally. 3868 # So we just punt and use a minimum line length of 8192. 3869 lt_cv_sys_max_cmd_len=8192; 3870 ;; 3871 3872 netbsd* | freebsd* | openbsd* | darwin* | dragonfly*) 3873 # This has been around since 386BSD, at least. Likely further. 3874 if test -x /sbin/sysctl; then 3875 lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` 3876 elif test -x /usr/sbin/sysctl; then 3877 lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` 3878 else 3879 lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs 3880 fi 3881 # And add a safety zone 3882 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` 3883 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` 3884 ;; 3885 3886 interix*) 3887 # We know the value 262144 and hardcode it with a safety zone (like BSD) 3888 lt_cv_sys_max_cmd_len=196608 3889 ;; 3890 3891 osf*) 3892 # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure 3893 # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not 3894 # nice to cause kernel panics so lets avoid the loop below. 3895 # First set a reasonable default. 3896 lt_cv_sys_max_cmd_len=16384 3897 # 3898 if test -x /sbin/sysconfig; then 3899 case `/sbin/sysconfig -q proc exec_disable_arg_limit` in 3900 *1*) lt_cv_sys_max_cmd_len=-1 ;; 3901 esac 3902 fi 3903 ;; 3904 sco3.2v5*) 3905 lt_cv_sys_max_cmd_len=102400 3906 ;; 3907 sysv5* | sco5v6* | sysv4.2uw2*) 3908 kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` 3909 if test -n "$kargmax"; then 3910 lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'` 3911 else 3912 lt_cv_sys_max_cmd_len=32768 3913 fi 3914 ;; 3915 *) 3916 lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` 3917 if test -n "$lt_cv_sys_max_cmd_len"; then 3918 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` 3919 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` 3920 else 3921 # Make teststring a little bigger before we do anything with it. 3922 # a 1K string should be a reasonable start. 3923 for i in 1 2 3 4 5 6 7 8 ; do 3924 teststring=$teststring$teststring 3925 done 3926 SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} 3927 # If test is not a shell built-in, we'll probably end up computing a 3928 # maximum length that is only half of the actual maximum length, but 3929 # we can't tell. 3930 while { test "X"`func_fallback_echo "$teststring$teststring" 2>/dev/null` \ 3931 = "X$teststring$teststring"; } >/dev/null 2>&1 && 3932 test $i != 17 # 1/2 MB should be enough 3933 do 3934 i=`expr $i + 1` 3935 teststring=$teststring$teststring 3936 done 3937 # Only check the string length outside the loop. 3938 lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1` 3939 teststring= 3940 # Add a significant safety factor because C++ compilers can tack on 3941 # massive amounts of additional arguments before passing them to the 3942 # linker. It appears as though 1/2 is a usable value. 3943 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` 3944 fi 3945 ;; 3946 esac 3947]) 3948if test -n $lt_cv_sys_max_cmd_len ; then 3949 AC_MSG_RESULT($lt_cv_sys_max_cmd_len) 3950else 3951 AC_MSG_RESULT(none) 3952fi 3953max_cmd_len=$lt_cv_sys_max_cmd_len 3954_LT_DECL([], [max_cmd_len], [0], 3955 [What is the maximum length of a command?]) 3956])# LT_CMD_MAX_LEN 3957 3958# Old name: 3959AU_ALIAS([AC_LIBTOOL_SYS_MAX_CMD_LEN], [LT_CMD_MAX_LEN]) 3960dnl aclocal-1.4 backwards compatibility: 3961dnl AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], []) 3962 3963 3964# _LT_HEADER_DLFCN 3965# ---------------- 3966m4_defun([_LT_HEADER_DLFCN], 3967[AC_CHECK_HEADERS([dlfcn.h], [], [], [AC_INCLUDES_DEFAULT])dnl 3968])# _LT_HEADER_DLFCN 3969 3970 3971# _LT_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE, 3972# ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING) 3973# ---------------------------------------------------------------- 3974m4_defun([_LT_TRY_DLOPEN_SELF], 3975[m4_require([_LT_HEADER_DLFCN])dnl 3976if test "$cross_compiling" = yes; then : 3977 [$4] 3978else 3979 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 3980 lt_status=$lt_dlunknown 3981 cat > conftest.$ac_ext <<_LT_EOF 3982[#line $LINENO "configure" 3983#include "confdefs.h" 3984 3985#if HAVE_DLFCN_H 3986#include <dlfcn.h> 3987#endif 3988 3989#include <stdio.h> 3990 3991#ifdef RTLD_GLOBAL 3992# define LT_DLGLOBAL RTLD_GLOBAL 3993#else 3994# ifdef DL_GLOBAL 3995# define LT_DLGLOBAL DL_GLOBAL 3996# else 3997# define LT_DLGLOBAL 0 3998# endif 3999#endif 4000 4001/* We may have to define LT_DLLAZY_OR_NOW in the command line if we 4002 find out it does not work in some platform. */ 4003#ifndef LT_DLLAZY_OR_NOW 4004# ifdef RTLD_LAZY 4005# define LT_DLLAZY_OR_NOW RTLD_LAZY 4006# else 4007# ifdef DL_LAZY 4008# define LT_DLLAZY_OR_NOW DL_LAZY 4009# else 4010# ifdef RTLD_NOW 4011# define LT_DLLAZY_OR_NOW RTLD_NOW 4012# else 4013# ifdef DL_NOW 4014# define LT_DLLAZY_OR_NOW DL_NOW 4015# else 4016# define LT_DLLAZY_OR_NOW 0 4017# endif 4018# endif 4019# endif 4020# endif 4021#endif 4022 4023/* When -fvisbility=hidden is used, assume the code has been annotated 4024 correspondingly for the symbols needed. */ 4025#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) 4026void fnord () __attribute__((visibility("default"))); 4027#endif 4028 4029void fnord () { int i=42; } 4030int main () 4031{ 4032 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); 4033 int status = $lt_dlunknown; 4034 4035 if (self) 4036 { 4037 if (dlsym (self,"fnord")) status = $lt_dlno_uscore; 4038 else 4039 { 4040 if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; 4041 else puts (dlerror ()); 4042 } 4043 /* dlclose (self); */ 4044 } 4045 else 4046 puts (dlerror ()); 4047 4048 return status; 4049}] 4050_LT_EOF 4051 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then 4052 (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null 4053 lt_status=$? 4054 case x$lt_status in 4055 x$lt_dlno_uscore) $1 ;; 4056 x$lt_dlneed_uscore) $2 ;; 4057 x$lt_dlunknown|x*) $3 ;; 4058 esac 4059 else : 4060 # compilation failed 4061 $3 4062 fi 4063fi 4064rm -fr conftest* 4065])# _LT_TRY_DLOPEN_SELF 4066 4067 4068# LT_SYS_DLOPEN_SELF 4069# ------------------ 4070AC_DEFUN([LT_SYS_DLOPEN_SELF], 4071[m4_require([_LT_HEADER_DLFCN])dnl 4072if test "x$enable_dlopen" != xyes; then 4073 enable_dlopen=unknown 4074 enable_dlopen_self=unknown 4075 enable_dlopen_self_static=unknown 4076else 4077 lt_cv_dlopen=no 4078 lt_cv_dlopen_libs= 4079 4080 case $host_os in 4081 beos*) 4082 lt_cv_dlopen="load_add_on" 4083 lt_cv_dlopen_libs= 4084 lt_cv_dlopen_self=yes 4085 ;; 4086 4087 mingw* | pw32* | cegcc*) 4088 lt_cv_dlopen="LoadLibrary" 4089 lt_cv_dlopen_libs= 4090 ;; 4091 4092 cygwin*) 4093 lt_cv_dlopen="dlopen" 4094 lt_cv_dlopen_libs= 4095 ;; 4096 4097 darwin*) 4098 # if libdl is installed we need to link against it 4099 AC_CHECK_LIB([dl], [dlopen], 4100 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[ 4101 lt_cv_dlopen="dyld" 4102 lt_cv_dlopen_libs= 4103 lt_cv_dlopen_self=yes 4104 ]) 4105 ;; 4106 4107 *) 4108 AC_CHECK_FUNC([shl_load], 4109 [lt_cv_dlopen="shl_load"], 4110 [AC_CHECK_LIB([dld], [shl_load], 4111 [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"], 4112 [AC_CHECK_FUNC([dlopen], 4113 [lt_cv_dlopen="dlopen"], 4114 [AC_CHECK_LIB([dl], [dlopen], 4115 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"], 4116 [AC_CHECK_LIB([svld], [dlopen], 4117 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"], 4118 [AC_CHECK_LIB([dld], [dld_link], 4119 [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"]) 4120 ]) 4121 ]) 4122 ]) 4123 ]) 4124 ]) 4125 ;; 4126 esac 4127 4128 if test "x$lt_cv_dlopen" != xno; then 4129 enable_dlopen=yes 4130 else 4131 enable_dlopen=no 4132 fi 4133 4134 case $lt_cv_dlopen in 4135 dlopen) 4136 save_CPPFLAGS="$CPPFLAGS" 4137 test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" 4138 4139 save_LDFLAGS="$LDFLAGS" 4140 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" 4141 4142 save_LIBS="$LIBS" 4143 LIBS="$lt_cv_dlopen_libs $LIBS" 4144 4145 AC_CACHE_CHECK([whether a program can dlopen itself], 4146 lt_cv_dlopen_self, [dnl 4147 _LT_TRY_DLOPEN_SELF( 4148 lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes, 4149 lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross) 4150 ]) 4151 4152 if test "x$lt_cv_dlopen_self" = xyes; then 4153 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" 4154 AC_CACHE_CHECK([whether a statically linked program can dlopen itself], 4155 lt_cv_dlopen_self_static, [dnl 4156 _LT_TRY_DLOPEN_SELF( 4157 lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes, 4158 lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross) 4159 ]) 4160 fi 4161 4162 CPPFLAGS="$save_CPPFLAGS" 4163 LDFLAGS="$save_LDFLAGS" 4164 LIBS="$save_LIBS" 4165 ;; 4166 esac 4167 4168 case $lt_cv_dlopen_self in 4169 yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; 4170 *) enable_dlopen_self=unknown ;; 4171 esac 4172 4173 case $lt_cv_dlopen_self_static in 4174 yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; 4175 *) enable_dlopen_self_static=unknown ;; 4176 esac 4177fi 4178_LT_DECL([dlopen_support], [enable_dlopen], [0], 4179 [Whether dlopen is supported]) 4180_LT_DECL([dlopen_self], [enable_dlopen_self], [0], 4181 [Whether dlopen of programs is supported]) 4182_LT_DECL([dlopen_self_static], [enable_dlopen_self_static], [0], 4183 [Whether dlopen of statically linked programs is supported]) 4184])# LT_SYS_DLOPEN_SELF 4185 4186# Old name: 4187AU_ALIAS([AC_LIBTOOL_DLOPEN_SELF], [LT_SYS_DLOPEN_SELF]) 4188dnl aclocal-1.4 backwards compatibility: 4189dnl AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], []) 4190 4191 4192# _LT_COMPILER_C_O([TAGNAME]) 4193# --------------------------- 4194# Check to see if options -c and -o are simultaneously supported by compiler. 4195# This macro does not hard code the compiler like AC_PROG_CC_C_O. 4196m4_defun([_LT_COMPILER_C_O], 4197[m4_require([_LT_DECL_SED])dnl 4198m4_require([_LT_FILEUTILS_DEFAULTS])dnl 4199m4_require([_LT_TAG_COMPILER])dnl 4200AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext], 4201 [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)], 4202 [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no 4203 $RM -r conftest 2>/dev/null 4204 mkdir conftest 4205 cd conftest 4206 mkdir out 4207 echo "$lt_simple_compile_test_code" > conftest.$ac_ext 4208 4209 lt_compiler_flag="-o out/conftest2.$ac_objext" 4210 # Insert the option either (1) after the last *FLAGS variable, or 4211 # (2) before a word containing "conftest.", or (3) at the end. 4212 # Note that $ac_compile itself does not contain backslashes and begins 4213 # with a dollar sign (not a hyphen), so the echo should work correctly. 4214 lt_compile=`echo "$ac_compile" | $SED \ 4215 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ 4216 -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ 4217 -e 's:$: $lt_compiler_flag:'` 4218 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD) 4219 (eval "$lt_compile" 2>out/conftest.err) 4220 ac_status=$? 4221 cat out/conftest.err >&AS_MESSAGE_LOG_FD 4222 echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD 4223 if (exit $ac_status) && test -s out/conftest2.$ac_objext 4224 then 4225 # The compiler can only warn and ignore the option if not recognized 4226 # So say no if there are warnings 4227 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp 4228 $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 4229 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then 4230 _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes 4231 fi 4232 fi 4233 chmod u+w . 2>&AS_MESSAGE_LOG_FD 4234 $RM conftest* 4235 # SGI C++ compiler will create directory out/ii_files/ for 4236 # template instantiation 4237 test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files 4238 $RM out/* && rmdir out 4239 cd .. 4240 $RM -r conftest 4241 $RM conftest* 4242]) 4243_LT_TAGDECL([compiler_c_o], [lt_cv_prog_compiler_c_o], [1], 4244 [Does compiler simultaneously support -c and -o options?]) 4245])# _LT_COMPILER_C_O 4246 4247 4248# _LT_COMPILER_FILE_LOCKS([TAGNAME]) 4249# ---------------------------------- 4250# Check to see if we can do hard links to lock some files if needed 4251m4_defun([_LT_COMPILER_FILE_LOCKS], 4252[m4_require([_LT_ENABLE_LOCK])dnl 4253m4_require([_LT_FILEUTILS_DEFAULTS])dnl 4254_LT_COMPILER_C_O([$1]) 4255 4256hard_links="nottested" 4257if test "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then 4258 # do not overwrite the value of need_locks provided by the user 4259 AC_MSG_CHECKING([if we can lock with hard links]) 4260 hard_links=yes 4261 $RM conftest* 4262 ln conftest.a conftest.b 2>/dev/null && hard_links=no 4263 touch conftest.a 4264 ln conftest.a conftest.b 2>&5 || hard_links=no 4265 ln conftest.a conftest.b 2>/dev/null && hard_links=no 4266 AC_MSG_RESULT([$hard_links]) 4267 if test "$hard_links" = no; then 4268 AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe]) 4269 need_locks=warn 4270 fi 4271else 4272 need_locks=no 4273fi 4274_LT_DECL([], [need_locks], [1], [Must we lock files when doing compilation?]) 4275])# _LT_COMPILER_FILE_LOCKS 4276 4277 4278# _LT_CHECK_OBJDIR 4279# ---------------- 4280m4_defun([_LT_CHECK_OBJDIR], 4281[AC_CACHE_CHECK([for objdir], [lt_cv_objdir], 4282[rm -f .libs 2>/dev/null 4283mkdir .libs 2>/dev/null 4284if test -d .libs; then 4285 lt_cv_objdir=.libs 4286else 4287 # MS-DOS does not allow filenames that begin with a dot. 4288 lt_cv_objdir=_libs 4289fi 4290rmdir .libs 2>/dev/null]) 4291objdir=$lt_cv_objdir 4292_LT_DECL([], [objdir], [0], 4293 [The name of the directory that contains temporary libtool files])dnl 4294m4_pattern_allow([LT_OBJDIR])dnl 4295AC_DEFINE_UNQUOTED(LT_OBJDIR, "$lt_cv_objdir/", 4296 [Define to the sub-directory in which libtool stores uninstalled libraries.]) 4297])# _LT_CHECK_OBJDIR 4298 4299 4300# _LT_LINKER_HARDCODE_LIBPATH([TAGNAME]) 4301# -------------------------------------- 4302# Check hardcoding attributes. 4303m4_defun([_LT_LINKER_HARDCODE_LIBPATH], 4304[AC_MSG_CHECKING([how to hardcode library paths into programs]) 4305_LT_TAGVAR(hardcode_action, $1)= 4306if test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" || 4307 test -n "$_LT_TAGVAR(runpath_var, $1)" || 4308 test "X$_LT_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then 4309 4310 # We can hardcode non-existent directories. 4311 if test "$_LT_TAGVAR(hardcode_direct, $1)" != no && 4312 # If the only mechanism to avoid hardcoding is shlibpath_var, we 4313 # have to relink, otherwise we might link with an installed library 4314 # when we should be linking with a yet-to-be-installed one 4315 ## test "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" != no && 4316 test "$_LT_TAGVAR(hardcode_minus_L, $1)" != no; then 4317 # Linking always hardcodes the temporary library directory. 4318 _LT_TAGVAR(hardcode_action, $1)=relink 4319 else 4320 # We can link without hardcoding, and we can hardcode nonexisting dirs. 4321 _LT_TAGVAR(hardcode_action, $1)=immediate 4322 fi 4323else 4324 # We cannot hardcode anything, or else we can only hardcode existing 4325 # directories. 4326 _LT_TAGVAR(hardcode_action, $1)=unsupported 4327fi 4328AC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)]) 4329 4330if test "$_LT_TAGVAR(hardcode_action, $1)" = relink || 4331 test "$_LT_TAGVAR(inherit_rpath, $1)" = yes; then 4332 # Fast installation is not supported 4333 enable_fast_install=no 4334elif test "$shlibpath_overrides_runpath" = yes || 4335 test "$enable_shared" = no; then 4336 # Fast installation is not necessary 4337 enable_fast_install=needless 4338fi 4339_LT_TAGDECL([], [hardcode_action], [0], 4340 [How to hardcode a shared library path into an executable]) 4341])# _LT_LINKER_HARDCODE_LIBPATH 4342 4343 4344# _LT_CMD_STRIPLIB 4345# ---------------- 4346m4_defun([_LT_CMD_STRIPLIB], 4347[m4_require([_LT_DECL_EGREP]) 4348striplib= 4349old_striplib= 4350AC_MSG_CHECKING([whether stripping libraries is possible]) 4351if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then 4352 test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" 4353 test -z "$striplib" && striplib="$STRIP --strip-unneeded" 4354 AC_MSG_RESULT([yes]) 4355else 4356# FIXME - insert some real tests, host_os isn't really good enough 4357 case $host_os in 4358 darwin*) 4359 if test -n "$STRIP" ; then 4360 striplib="$STRIP -x" 4361 old_striplib="$STRIP -S" 4362 AC_MSG_RESULT([yes]) 4363 else 4364 AC_MSG_RESULT([no]) 4365 fi 4366 ;; 4367 *) 4368 AC_MSG_RESULT([no]) 4369 ;; 4370 esac 4371fi 4372_LT_DECL([], [old_striplib], [1], [Commands to strip libraries]) 4373_LT_DECL([], [striplib], [1]) 4374])# _LT_CMD_STRIPLIB 4375 4376 4377# _LT_SYS_DYNAMIC_LINKER([TAG]) 4378# ----------------------------- 4379# PORTME Fill in your ld.so characteristics 4380m4_defun([_LT_SYS_DYNAMIC_LINKER], 4381[AC_REQUIRE([AC_CANONICAL_HOST])dnl 4382m4_require([_LT_DECL_EGREP])dnl 4383m4_require([_LT_FILEUTILS_DEFAULTS])dnl 4384m4_require([_LT_DECL_OBJDUMP])dnl 4385m4_require([_LT_DECL_SED])dnl 4386m4_require([_LT_CHECK_SHELL_FEATURES])dnl 4387AC_MSG_CHECKING([dynamic linker characteristics]) 4388m4_if([$1], 4389 [], [ 4390if test "$GCC" = yes; then 4391 case $host_os in 4392 darwin*) lt_awk_arg="/^libraries:/,/LR/" ;; 4393 *) lt_awk_arg="/^libraries:/" ;; 4394 esac 4395 case $host_os in 4396 mingw* | cegcc*) lt_sed_strip_eq="s,=\([[A-Za-z]]:\),\1,g" ;; 4397 *) lt_sed_strip_eq="s,=/,/,g" ;; 4398 esac 4399 lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq` 4400 case $lt_search_path_spec in 4401 *\;*) 4402 # if the path contains ";" then we assume it to be the separator 4403 # otherwise default to the standard path separator (i.e. ":") - it is 4404 # assumed that no part of a normal pathname contains ";" but that should 4405 # okay in the real world where ";" in dirpaths is itself problematic. 4406 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'` 4407 ;; 4408 *) 4409 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"` 4410 ;; 4411 esac 4412 # Ok, now we have the path, separated by spaces, we can step through it 4413 # and add multilib dir if necessary. 4414 lt_tmp_lt_search_path_spec= 4415 lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` 4416 for lt_sys_path in $lt_search_path_spec; do 4417 if test -d "$lt_sys_path/$lt_multi_os_dir"; then 4418 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir" 4419 else 4420 test -d "$lt_sys_path" && \ 4421 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" 4422 fi 4423 done 4424 lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk ' 4425BEGIN {RS=" "; FS="/|\n";} { 4426 lt_foo=""; 4427 lt_count=0; 4428 for (lt_i = NF; lt_i > 0; lt_i--) { 4429 if ($lt_i != "" && $lt_i != ".") { 4430 if ($lt_i == "..") { 4431 lt_count++; 4432 } else { 4433 if (lt_count == 0) { 4434 lt_foo="/" $lt_i lt_foo; 4435 } else { 4436 lt_count--; 4437 } 4438 } 4439 } 4440 } 4441 if (lt_foo != "") { lt_freq[[lt_foo]]++; } 4442 if (lt_freq[[lt_foo]] == 1) { print lt_foo; } 4443}'` 4444 # AWK program above erroneously prepends '/' to C:/dos/paths 4445 # for these hosts. 4446 case $host_os in 4447 mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ 4448 $SED 's,/\([[A-Za-z]]:\),\1,g'` ;; 4449 esac 4450 sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP` 4451else 4452 sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" 4453fi]) 4454library_names_spec= 4455libname_spec='lib$name' 4456soname_spec= 4457shrext_cmds=".so" 4458postinstall_cmds= 4459postuninstall_cmds= 4460finish_cmds= 4461finish_eval= 4462shlibpath_var= 4463shlibpath_overrides_runpath=unknown 4464version_type=none 4465dynamic_linker="$host_os ld.so" 4466sys_lib_dlsearch_path_spec="/lib /usr/lib" 4467need_lib_prefix=unknown 4468hardcode_into_libs=no 4469 4470# when you set need_version to no, make sure it does not cause -set_version 4471# flags to be left without arguments 4472need_version=unknown 4473 4474case $host_os in 4475aix3*) 4476 version_type=linux 4477 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' 4478 shlibpath_var=LIBPATH 4479 4480 # AIX 3 has no versioning support, so we append a major version to the name. 4481 soname_spec='${libname}${release}${shared_ext}$major' 4482 ;; 4483 4484aix[[4-9]]*) 4485 version_type=linux 4486 need_lib_prefix=no 4487 need_version=no 4488 hardcode_into_libs=yes 4489 if test "$host_cpu" = ia64; then 4490 # AIX 5 supports IA64 4491 library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' 4492 shlibpath_var=LD_LIBRARY_PATH 4493 else 4494 # With GCC up to 2.95.x, collect2 would create an import file 4495 # for dependence libraries. The import file would start with 4496 # the line `#! .'. This would cause the generated library to 4497 # depend on `.', always an invalid library. This was fixed in 4498 # development snapshots of GCC prior to 3.0. 4499 case $host_os in 4500 aix4 | aix4.[[01]] | aix4.[[01]].*) 4501 if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' 4502 echo ' yes ' 4503 echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then 4504 : 4505 else 4506 can_build_shared=no 4507 fi 4508 ;; 4509 esac 4510 # AIX (on Power*) has no versioning support, so currently we can not hardcode correct 4511 # soname into executable. Probably we can add versioning support to 4512 # collect2, so additional links can be useful in future. 4513 if test "$aix_use_runtimelinking" = yes; then 4514 # If using run time linking (on AIX 4.2 or later) use lib<name>.so 4515 # instead of lib<name>.a to let people know that these are not 4516 # typical AIX shared libraries. 4517 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 4518 else 4519 # We preserve .a as extension for shared libraries through AIX4.2 4520 # and later when we are not doing run time linking. 4521 library_names_spec='${libname}${release}.a $libname.a' 4522 soname_spec='${libname}${release}${shared_ext}$major' 4523 fi 4524 shlibpath_var=LIBPATH 4525 fi 4526 ;; 4527 4528amigaos*) 4529 case $host_cpu in 4530 powerpc) 4531 # Since July 2007 AmigaOS4 officially supports .so libraries. 4532 # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. 4533 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 4534 ;; 4535 m68k) 4536 library_names_spec='$libname.ixlibrary $libname.a' 4537 # Create ${libname}_ixlibrary.a entries in /sys/libs. 4538 finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''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' 4539 ;; 4540 esac 4541 ;; 4542 4543beos*) 4544 library_names_spec='${libname}${shared_ext}' 4545 dynamic_linker="$host_os ld.so" 4546 shlibpath_var=LIBRARY_PATH 4547 ;; 4548 4549bsdi[[45]]*) 4550 version_type=linux 4551 need_version=no 4552 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 4553 soname_spec='${libname}${release}${shared_ext}$major' 4554 finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' 4555 shlibpath_var=LD_LIBRARY_PATH 4556 sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" 4557 sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" 4558 # the default ld.so.conf also contains /usr/contrib/lib and 4559 # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow 4560 # libtool to hard-code these into programs 4561 ;; 4562 4563cygwin* | mingw* | pw32* | cegcc*) 4564 version_type=windows 4565 shrext_cmds=".dll" 4566 need_version=no 4567 need_lib_prefix=no 4568 4569 case $GCC,$host_os in 4570 yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*) 4571 library_names_spec='$libname.dll.a' 4572 # DLL is installed to $(libdir)/../bin by postinstall_cmds 4573 postinstall_cmds='base_file=`basename \${file}`~ 4574 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ 4575 dldir=$destdir/`dirname \$dlpath`~ 4576 test -d \$dldir || mkdir -p \$dldir~ 4577 $install_prog $dir/$dlname \$dldir/$dlname~ 4578 chmod a+x \$dldir/$dlname~ 4579 if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then 4580 eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; 4581 fi' 4582 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ 4583 dlpath=$dir/\$dldll~ 4584 $RM \$dlpath' 4585 shlibpath_overrides_runpath=yes 4586 4587 case $host_os in 4588 cygwin*) 4589 # Cygwin DLLs use 'cyg' prefix rather than 'lib' 4590 soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' 4591m4_if([$1], [],[ 4592 sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"]) 4593 ;; 4594 mingw* | cegcc*) 4595 # MinGW DLLs use traditional 'lib' prefix 4596 soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' 4597 ;; 4598 pw32*) 4599 # pw32 DLLs use 'pw' prefix rather than 'lib' 4600 library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' 4601 ;; 4602 esac 4603 ;; 4604 4605 *) 4606 library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib' 4607 ;; 4608 esac 4609 dynamic_linker='Win32 ld.exe' 4610 # FIXME: first we should search . and the directory the executable is in 4611 shlibpath_var=PATH 4612 ;; 4613 4614darwin* | rhapsody*) 4615 dynamic_linker="$host_os dyld" 4616 version_type=darwin 4617 need_lib_prefix=no 4618 need_version=no 4619 library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext' 4620 soname_spec='${libname}${release}${major}$shared_ext' 4621 shlibpath_overrides_runpath=yes 4622 shlibpath_var=DYLD_LIBRARY_PATH 4623 shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' 4624m4_if([$1], [],[ 4625 sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"]) 4626 sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' 4627 ;; 4628 4629dgux*) 4630 version_type=linux 4631 need_lib_prefix=no 4632 need_version=no 4633 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' 4634 soname_spec='${libname}${release}${shared_ext}$major' 4635 shlibpath_var=LD_LIBRARY_PATH 4636 ;; 4637 4638freebsd1*) 4639 dynamic_linker=no 4640 ;; 4641 4642freebsd* | dragonfly*) 4643 # DragonFly does not have aout. When/if they implement a new 4644 # versioning mechanism, adjust this. 4645 if test -x /usr/bin/objformat; then 4646 objformat=`/usr/bin/objformat` 4647 else 4648 case $host_os in 4649 freebsd[[123]]*) objformat=aout ;; 4650 *) objformat=elf ;; 4651 esac 4652 fi 4653 version_type=freebsd-$objformat 4654 case $version_type in 4655 freebsd-elf*) 4656 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' 4657 need_version=no 4658 need_lib_prefix=no 4659 ;; 4660 freebsd-*) 4661 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' 4662 need_version=yes 4663 ;; 4664 esac 4665 shlibpath_var=LD_LIBRARY_PATH 4666 case $host_os in 4667 freebsd2*) 4668 shlibpath_overrides_runpath=yes 4669 ;; 4670 freebsd3.[[01]]* | freebsdelf3.[[01]]*) 4671 shlibpath_overrides_runpath=yes 4672 hardcode_into_libs=yes 4673 ;; 4674 freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \ 4675 freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1) 4676 shlibpath_overrides_runpath=no 4677 hardcode_into_libs=yes 4678 ;; 4679 *) # from 4.6 on, and DragonFly 4680 shlibpath_overrides_runpath=yes 4681 hardcode_into_libs=yes 4682 ;; 4683 esac 4684 ;; 4685 4686gnu*) 4687 version_type=linux 4688 need_lib_prefix=no 4689 need_version=no 4690 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' 4691 soname_spec='${libname}${release}${shared_ext}$major' 4692 shlibpath_var=LD_LIBRARY_PATH 4693 hardcode_into_libs=yes 4694 ;; 4695 4696haiku*) 4697 version_type=linux 4698 need_lib_prefix=no 4699 need_version=no 4700 dynamic_linker="$host_os runtime_loader" 4701 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' 4702 soname_spec='${libname}${release}${shared_ext}$major' 4703 shlibpath_var=LIBRARY_PATH 4704 shlibpath_overrides_runpath=yes 4705 sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' 4706 hardcode_into_libs=yes 4707 ;; 4708 4709hpux9* | hpux10* | hpux11*) 4710 # Give a soname corresponding to the major version so that dld.sl refuses to 4711 # link against other versions. 4712 version_type=sunos 4713 need_lib_prefix=no 4714 need_version=no 4715 case $host_cpu in 4716 ia64*) 4717 shrext_cmds='.so' 4718 hardcode_into_libs=yes 4719 dynamic_linker="$host_os dld.so" 4720 shlibpath_var=LD_LIBRARY_PATH 4721 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. 4722 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 4723 soname_spec='${libname}${release}${shared_ext}$major' 4724 if test "X$HPUX_IA64_MODE" = X32; then 4725 sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" 4726 else 4727 sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" 4728 fi 4729 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec 4730 ;; 4731 hppa*64*) 4732 shrext_cmds='.sl' 4733 hardcode_into_libs=yes 4734 dynamic_linker="$host_os dld.sl" 4735 shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH 4736 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. 4737 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 4738 soname_spec='${libname}${release}${shared_ext}$major' 4739 sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" 4740 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec 4741 ;; 4742 *) 4743 shrext_cmds='.sl' 4744 dynamic_linker="$host_os dld.sl" 4745 shlibpath_var=SHLIB_PATH 4746 shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH 4747 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 4748 soname_spec='${libname}${release}${shared_ext}$major' 4749 ;; 4750 esac 4751 # HP-UX runs *really* slowly unless shared libraries are mode 555, ... 4752 postinstall_cmds='chmod 555 $lib' 4753 # or fails outright, so override atomically: 4754 install_override_mode=555 4755 ;; 4756 4757interix[[3-9]]*) 4758 version_type=linux 4759 need_lib_prefix=no 4760 need_version=no 4761 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' 4762 soname_spec='${libname}${release}${shared_ext}$major' 4763 dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' 4764 shlibpath_var=LD_LIBRARY_PATH 4765 shlibpath_overrides_runpath=no 4766 hardcode_into_libs=yes 4767 ;; 4768 4769irix5* | irix6* | nonstopux*) 4770 case $host_os in 4771 nonstopux*) version_type=nonstopux ;; 4772 *) 4773 if test "$lt_cv_prog_gnu_ld" = yes; then 4774 version_type=linux 4775 else 4776 version_type=irix 4777 fi ;; 4778 esac 4779 need_lib_prefix=no 4780 need_version=no 4781 soname_spec='${libname}${release}${shared_ext}$major' 4782 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' 4783 case $host_os in 4784 irix5* | nonstopux*) 4785 libsuff= shlibsuff= 4786 ;; 4787 *) 4788 case $LD in # libtool.m4 will add one of these switches to LD 4789 *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") 4790 libsuff= shlibsuff= libmagic=32-bit;; 4791 *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") 4792 libsuff=32 shlibsuff=N32 libmagic=N32;; 4793 *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") 4794 libsuff=64 shlibsuff=64 libmagic=64-bit;; 4795 *) libsuff= shlibsuff= libmagic=never-match;; 4796 esac 4797 ;; 4798 esac 4799 shlibpath_var=LD_LIBRARY${shlibsuff}_PATH 4800 shlibpath_overrides_runpath=no 4801 sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" 4802 sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" 4803 hardcode_into_libs=yes 4804 ;; 4805 4806# No shared lib support for Linux oldld, aout, or coff. 4807linux*oldld* | linux*aout* | linux*coff*) 4808 dynamic_linker=no 4809 ;; 4810 4811# This must be Linux ELF. 4812linux* | k*bsd*-gnu | kopensolaris*-gnu) 4813 version_type=linux 4814 need_lib_prefix=no 4815 need_version=no 4816 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 4817 soname_spec='${libname}${release}${shared_ext}$major' 4818 finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' 4819 shlibpath_var=LD_LIBRARY_PATH 4820 shlibpath_overrides_runpath=no 4821 4822 # Some binutils ld are patched to set DT_RUNPATH 4823 AC_CACHE_VAL([lt_cv_shlibpath_overrides_runpath], 4824 [lt_cv_shlibpath_overrides_runpath=no 4825 save_LDFLAGS=$LDFLAGS 4826 save_libdir=$libdir 4827 eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \ 4828 LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\"" 4829 AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], 4830 [AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null], 4831 [lt_cv_shlibpath_overrides_runpath=yes])]) 4832 LDFLAGS=$save_LDFLAGS 4833 libdir=$save_libdir 4834 ]) 4835 shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath 4836 4837 # This implies no fast_install, which is unacceptable. 4838 # Some rework will be needed to allow for fast_install 4839 # before this can be enabled. 4840 hardcode_into_libs=yes 4841 4842 # Append ld.so.conf contents to the search path 4843 if test -f /etc/ld.so.conf; then 4844 lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '` 4845 sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" 4846 fi 4847 4848 # We used to test for /lib/ld.so.1 and disable shared libraries on 4849 # powerpc, because MkLinux only supported shared libraries with the 4850 # GNU dynamic linker. Since this was broken with cross compilers, 4851 # most powerpc-linux boxes support dynamic linking these days and 4852 # people can always --disable-shared, the test was removed, and we 4853 # assume the GNU/Linux dynamic linker is in use. 4854 dynamic_linker='GNU/Linux ld.so' 4855 ;; 4856 4857netbsd*) 4858 version_type=sunos 4859 need_lib_prefix=no 4860 need_version=no 4861 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then 4862 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' 4863 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' 4864 dynamic_linker='NetBSD (a.out) ld.so' 4865 else 4866 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' 4867 soname_spec='${libname}${release}${shared_ext}$major' 4868 dynamic_linker='NetBSD ld.elf_so' 4869 fi 4870 shlibpath_var=LD_LIBRARY_PATH 4871 shlibpath_overrides_runpath=yes 4872 hardcode_into_libs=yes 4873 ;; 4874 4875newsos6) 4876 version_type=linux 4877 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 4878 shlibpath_var=LD_LIBRARY_PATH 4879 shlibpath_overrides_runpath=yes 4880 ;; 4881 4882*nto* | *qnx*) 4883 version_type=qnx 4884 need_lib_prefix=no 4885 need_version=no 4886 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 4887 soname_spec='${libname}${release}${shared_ext}$major' 4888 shlibpath_var=LD_LIBRARY_PATH 4889 shlibpath_overrides_runpath=no 4890 hardcode_into_libs=yes 4891 dynamic_linker='ldqnx.so' 4892 ;; 4893 4894openbsd*) 4895 version_type=sunos 4896 sys_lib_dlsearch_path_spec="/usr/lib" 4897 need_lib_prefix=no 4898 # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. 4899 case $host_os in 4900 openbsd3.3 | openbsd3.3.*) need_version=yes ;; 4901 *) need_version=no ;; 4902 esac 4903 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' 4904 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' 4905 shlibpath_var=LD_LIBRARY_PATH 4906 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then 4907 case $host_os in 4908 openbsd2.[[89]] | openbsd2.[[89]].*) 4909 shlibpath_overrides_runpath=no 4910 ;; 4911 *) 4912 shlibpath_overrides_runpath=yes 4913 ;; 4914 esac 4915 else 4916 shlibpath_overrides_runpath=yes 4917 fi 4918 ;; 4919 4920os2*) 4921 libname_spec='$name' 4922 shrext_cmds=".dll" 4923 need_lib_prefix=no 4924 library_names_spec='$libname${shared_ext} $libname.a' 4925 dynamic_linker='OS/2 ld.exe' 4926 shlibpath_var=LIBPATH 4927 ;; 4928 4929osf3* | osf4* | osf5*) 4930 version_type=osf 4931 need_lib_prefix=no 4932 need_version=no 4933 soname_spec='${libname}${release}${shared_ext}$major' 4934 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 4935 shlibpath_var=LD_LIBRARY_PATH 4936 sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" 4937 sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" 4938 ;; 4939 4940rdos*) 4941 dynamic_linker=no 4942 ;; 4943 4944solaris*) 4945 version_type=linux 4946 need_lib_prefix=no 4947 need_version=no 4948 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 4949 soname_spec='${libname}${release}${shared_ext}$major' 4950 shlibpath_var=LD_LIBRARY_PATH 4951 shlibpath_overrides_runpath=yes 4952 hardcode_into_libs=yes 4953 # ldd complains unless libraries are executable 4954 postinstall_cmds='chmod +x $lib' 4955 ;; 4956 4957sunos4*) 4958 version_type=sunos 4959 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' 4960 finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' 4961 shlibpath_var=LD_LIBRARY_PATH 4962 shlibpath_overrides_runpath=yes 4963 if test "$with_gnu_ld" = yes; then 4964 need_lib_prefix=no 4965 fi 4966 need_version=yes 4967 ;; 4968 4969sysv4 | sysv4.3*) 4970 version_type=linux 4971 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 4972 soname_spec='${libname}${release}${shared_ext}$major' 4973 shlibpath_var=LD_LIBRARY_PATH 4974 case $host_vendor in 4975 sni) 4976 shlibpath_overrides_runpath=no 4977 need_lib_prefix=no 4978 runpath_var=LD_RUN_PATH 4979 ;; 4980 siemens) 4981 need_lib_prefix=no 4982 ;; 4983 motorola) 4984 need_lib_prefix=no 4985 need_version=no 4986 shlibpath_overrides_runpath=no 4987 sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' 4988 ;; 4989 esac 4990 ;; 4991 4992sysv4*MP*) 4993 if test -d /usr/nec ;then 4994 version_type=linux 4995 library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' 4996 soname_spec='$libname${shared_ext}.$major' 4997 shlibpath_var=LD_LIBRARY_PATH 4998 fi 4999 ;; 5000 5001sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) 5002 version_type=freebsd-elf 5003 need_lib_prefix=no 5004 need_version=no 5005 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' 5006 soname_spec='${libname}${release}${shared_ext}$major' 5007 shlibpath_var=LD_LIBRARY_PATH 5008 shlibpath_overrides_runpath=yes 5009 hardcode_into_libs=yes 5010 if test "$with_gnu_ld" = yes; then 5011 sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' 5012 else 5013 sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' 5014 case $host_os in 5015 sco3.2v5*) 5016 sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" 5017 ;; 5018 esac 5019 fi 5020 sys_lib_dlsearch_path_spec='/usr/lib' 5021 ;; 5022 5023tpf*) 5024 # TPF is a cross-target only. Preferred cross-host = GNU/Linux. 5025 version_type=linux 5026 need_lib_prefix=no 5027 need_version=no 5028 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 5029 shlibpath_var=LD_LIBRARY_PATH 5030 shlibpath_overrides_runpath=no 5031 hardcode_into_libs=yes 5032 ;; 5033 5034uts4*) 5035 version_type=linux 5036 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 5037 soname_spec='${libname}${release}${shared_ext}$major' 5038 shlibpath_var=LD_LIBRARY_PATH 5039 ;; 5040 5041*) 5042 dynamic_linker=no 5043 ;; 5044esac 5045AC_MSG_RESULT([$dynamic_linker]) 5046test "$dynamic_linker" = no && can_build_shared=no 5047 5048variables_saved_for_relink="PATH $shlibpath_var $runpath_var" 5049if test "$GCC" = yes; then 5050 variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" 5051fi 5052 5053if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then 5054 sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" 5055fi 5056if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then 5057 sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" 5058fi 5059 5060_LT_DECL([], [variables_saved_for_relink], [1], 5061 [Variables whose values should be saved in libtool wrapper scripts and 5062 restored at link time]) 5063_LT_DECL([], [need_lib_prefix], [0], 5064 [Do we need the "lib" prefix for modules?]) 5065_LT_DECL([], [need_version], [0], [Do we need a version for libraries?]) 5066_LT_DECL([], [version_type], [0], [Library versioning type]) 5067_LT_DECL([], [runpath_var], [0], [Shared library runtime path variable]) 5068_LT_DECL([], [shlibpath_var], [0],[Shared library path variable]) 5069_LT_DECL([], [shlibpath_overrides_runpath], [0], 5070 [Is shlibpath searched before the hard-coded library search path?]) 5071_LT_DECL([], [libname_spec], [1], [Format of library name prefix]) 5072_LT_DECL([], [library_names_spec], [1], 5073 [[List of archive names. First name is the real one, the rest are links. 5074 The last name is the one that the linker finds with -lNAME]]) 5075_LT_DECL([], [soname_spec], [1], 5076 [[The coded name of the library, if different from the real name]]) 5077_LT_DECL([], [install_override_mode], [1], 5078 [Permission mode override for installation of shared libraries]) 5079_LT_DECL([], [postinstall_cmds], [2], 5080 [Command to use after installation of a shared archive]) 5081_LT_DECL([], [postuninstall_cmds], [2], 5082 [Command to use after uninstallation of a shared archive]) 5083_LT_DECL([], [finish_cmds], [2], 5084 [Commands used to finish a libtool library installation in a directory]) 5085_LT_DECL([], [finish_eval], [1], 5086 [[As "finish_cmds", except a single script fragment to be evaled but 5087 not shown]]) 5088_LT_DECL([], [hardcode_into_libs], [0], 5089 [Whether we should hardcode library paths into libraries]) 5090_LT_DECL([], [sys_lib_search_path_spec], [2], 5091 [Compile-time system search path for libraries]) 5092_LT_DECL([], [sys_lib_dlsearch_path_spec], [2], 5093 [Run-time system search path for libraries]) 5094])# _LT_SYS_DYNAMIC_LINKER 5095 5096 5097# _LT_PATH_TOOL_PREFIX(TOOL) 5098# -------------------------- 5099# find a file program which can recognize shared library 5100AC_DEFUN([_LT_PATH_TOOL_PREFIX], 5101[m4_require([_LT_DECL_EGREP])dnl 5102AC_MSG_CHECKING([for $1]) 5103AC_CACHE_VAL(lt_cv_path_MAGIC_CMD, 5104[case $MAGIC_CMD in 5105[[\\/*] | ?:[\\/]*]) 5106 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. 5107 ;; 5108*) 5109 lt_save_MAGIC_CMD="$MAGIC_CMD" 5110 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR 5111dnl $ac_dummy forces splitting on constant user-supplied paths. 5112dnl POSIX.2 word splitting is done only on the output of word expansions, 5113dnl not every word. This closes a longstanding sh security hole. 5114 ac_dummy="m4_if([$2], , $PATH, [$2])" 5115 for ac_dir in $ac_dummy; do 5116 IFS="$lt_save_ifs" 5117 test -z "$ac_dir" && ac_dir=. 5118 if test -f $ac_dir/$1; then 5119 lt_cv_path_MAGIC_CMD="$ac_dir/$1" 5120 if test -n "$file_magic_test_file"; then 5121 case $deplibs_check_method in 5122 "file_magic "*) 5123 file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` 5124 MAGIC_CMD="$lt_cv_path_MAGIC_CMD" 5125 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | 5126 $EGREP "$file_magic_regex" > /dev/null; then 5127 : 5128 else 5129 cat <<_LT_EOF 1>&2 5130 5131*** Warning: the command libtool uses to detect shared libraries, 5132*** $file_magic_cmd, produces output that libtool cannot recognize. 5133*** The result is that libtool may fail to recognize shared libraries 5134*** as such. This will affect the creation of libtool libraries that 5135*** depend on shared libraries, but programs linked with such libtool 5136*** libraries will work regardless of this problem. Nevertheless, you 5137*** may want to report the problem to your system manager and/or to 5138*** bug-libtool@gnu.org 5139 5140_LT_EOF 5141 fi ;; 5142 esac 5143 fi 5144 break 5145 fi 5146 done 5147 IFS="$lt_save_ifs" 5148 MAGIC_CMD="$lt_save_MAGIC_CMD" 5149 ;; 5150esac]) 5151MAGIC_CMD="$lt_cv_path_MAGIC_CMD" 5152if test -n "$MAGIC_CMD"; then 5153 AC_MSG_RESULT($MAGIC_CMD) 5154else 5155 AC_MSG_RESULT(no) 5156fi 5157_LT_DECL([], [MAGIC_CMD], [0], 5158 [Used to examine libraries when file_magic_cmd begins with "file"])dnl 5159])# _LT_PATH_TOOL_PREFIX 5160 5161# Old name: 5162AU_ALIAS([AC_PATH_TOOL_PREFIX], [_LT_PATH_TOOL_PREFIX]) 5163dnl aclocal-1.4 backwards compatibility: 5164dnl AC_DEFUN([AC_PATH_TOOL_PREFIX], []) 5165 5166 5167# _LT_PATH_MAGIC 5168# -------------- 5169# find a file program which can recognize a shared library 5170m4_defun([_LT_PATH_MAGIC], 5171[_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH) 5172if test -z "$lt_cv_path_MAGIC_CMD"; then 5173 if test -n "$ac_tool_prefix"; then 5174 _LT_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH) 5175 else 5176 MAGIC_CMD=: 5177 fi 5178fi 5179])# _LT_PATH_MAGIC 5180 5181 5182# LT_PATH_LD 5183# ---------- 5184# find the pathname to the GNU or non-GNU linker 5185AC_DEFUN([LT_PATH_LD], 5186[AC_REQUIRE([AC_PROG_CC])dnl 5187AC_REQUIRE([AC_CANONICAL_HOST])dnl 5188AC_REQUIRE([AC_CANONICAL_BUILD])dnl 5189m4_require([_LT_DECL_SED])dnl 5190m4_require([_LT_DECL_EGREP])dnl 5191m4_require([_LT_PROG_ECHO_BACKSLASH])dnl 5192 5193AC_ARG_WITH([gnu-ld], 5194 [AS_HELP_STRING([--with-gnu-ld], 5195 [assume the C compiler uses GNU ld @<:@default=no@:>@])], 5196 [test "$withval" = no || with_gnu_ld=yes], 5197 [with_gnu_ld=no])dnl 5198 5199ac_prog=ld 5200if test "$GCC" = yes; then 5201 # Check if gcc -print-prog-name=ld gives a path. 5202 AC_MSG_CHECKING([for ld used by $CC]) 5203 case $host in 5204 *-*-mingw*) 5205 # gcc leaves a trailing carriage return which upsets mingw 5206 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; 5207 *) 5208 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; 5209 esac 5210 case $ac_prog in 5211 # Accept absolute paths. 5212 [[\\/]]* | ?:[[\\/]]*) 5213 re_direlt='/[[^/]][[^/]]*/\.\./' 5214 # Canonicalize the pathname of ld 5215 ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` 5216 while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do 5217 ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` 5218 done 5219 test -z "$LD" && LD="$ac_prog" 5220 ;; 5221 "") 5222 # If it fails, then pretend we aren't using GCC. 5223 ac_prog=ld 5224 ;; 5225 *) 5226 # If it is relative, then search for the first ld in PATH. 5227 with_gnu_ld=unknown 5228 ;; 5229 esac 5230elif test "$with_gnu_ld" = yes; then 5231 AC_MSG_CHECKING([for GNU ld]) 5232else 5233 AC_MSG_CHECKING([for non-GNU ld]) 5234fi 5235AC_CACHE_VAL(lt_cv_path_LD, 5236[if test -z "$LD"; then 5237 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR 5238 for ac_dir in $PATH; do 5239 IFS="$lt_save_ifs" 5240 test -z "$ac_dir" && ac_dir=. 5241 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then 5242 lt_cv_path_LD="$ac_dir/$ac_prog" 5243 # Check to see if the program is GNU ld. I'd rather use --version, 5244 # but apparently some variants of GNU ld only accept -v. 5245 # Break only if it was the GNU/non-GNU ld that we prefer. 5246 case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in 5247 *GNU* | *'with BFD'*) 5248 test "$with_gnu_ld" != no && break 5249 ;; 5250 *) 5251 test "$with_gnu_ld" != yes && break 5252 ;; 5253 esac 5254 fi 5255 done 5256 IFS="$lt_save_ifs" 5257else 5258 lt_cv_path_LD="$LD" # Let the user override the test with a path. 5259fi]) 5260LD="$lt_cv_path_LD" 5261if test -n "$LD"; then 5262 AC_MSG_RESULT($LD) 5263else 5264 AC_MSG_RESULT(no) 5265fi 5266test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH]) 5267_LT_PATH_LD_GNU 5268AC_SUBST([LD]) 5269 5270_LT_TAGDECL([], [LD], [1], [The linker used to build libraries]) 5271])# LT_PATH_LD 5272 5273# Old names: 5274AU_ALIAS([AM_PROG_LD], [LT_PATH_LD]) 5275AU_ALIAS([AC_PROG_LD], [LT_PATH_LD]) 5276dnl aclocal-1.4 backwards compatibility: 5277dnl AC_DEFUN([AM_PROG_LD], []) 5278dnl AC_DEFUN([AC_PROG_LD], []) 5279 5280 5281# _LT_PATH_LD_GNU 5282#- -------------- 5283m4_defun([_LT_PATH_LD_GNU], 5284[AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld, 5285[# I'd rather use --version here, but apparently some GNU lds only accept -v. 5286case `$LD -v 2>&1 </dev/null` in 5287*GNU* | *'with BFD'*) 5288 lt_cv_prog_gnu_ld=yes 5289 ;; 5290*) 5291 lt_cv_prog_gnu_ld=no 5292 ;; 5293esac]) 5294with_gnu_ld=$lt_cv_prog_gnu_ld 5295])# _LT_PATH_LD_GNU 5296 5297 5298# _LT_CMD_RELOAD 5299# -------------- 5300# find reload flag for linker 5301# -- PORTME Some linkers may need a different reload flag. 5302m4_defun([_LT_CMD_RELOAD], 5303[AC_CACHE_CHECK([for $LD option to reload object files], 5304 lt_cv_ld_reload_flag, 5305 [lt_cv_ld_reload_flag='-r']) 5306reload_flag=$lt_cv_ld_reload_flag 5307case $reload_flag in 5308"" | " "*) ;; 5309*) reload_flag=" $reload_flag" ;; 5310esac 5311reload_cmds='$LD$reload_flag -o $output$reload_objs' 5312case $host_os in 5313 darwin*) 5314 if test "$GCC" = yes; then 5315 reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs' 5316 else 5317 reload_cmds='$LD$reload_flag -o $output$reload_objs' 5318 fi 5319 ;; 5320esac 5321_LT_TAGDECL([], [reload_flag], [1], [How to create reloadable object files])dnl 5322_LT_TAGDECL([], [reload_cmds], [2])dnl 5323])# _LT_CMD_RELOAD 5324 5325 5326# _LT_CHECK_MAGIC_METHOD 5327# ---------------------- 5328# how to check for library dependencies 5329# -- PORTME fill in with the dynamic library characteristics 5330m4_defun([_LT_CHECK_MAGIC_METHOD], 5331[m4_require([_LT_DECL_EGREP]) 5332m4_require([_LT_DECL_OBJDUMP]) 5333AC_CACHE_CHECK([how to recognize dependent libraries], 5334lt_cv_deplibs_check_method, 5335[lt_cv_file_magic_cmd='$MAGIC_CMD' 5336lt_cv_file_magic_test_file= 5337lt_cv_deplibs_check_method='unknown' 5338# Need to set the preceding variable on all platforms that support 5339# interlibrary dependencies. 5340# 'none' -- dependencies not supported. 5341# `unknown' -- same as none, but documents that we really don't know. 5342# 'pass_all' -- all dependencies passed with no checks. 5343# 'test_compile' -- check by making test program. 5344# 'file_magic [[regex]]' -- check by looking for files in library path 5345# which responds to the $file_magic_cmd with a given extended regex. 5346# If you have `file' or equivalent on your system and you're not sure 5347# whether `pass_all' will *always* work, you probably want this one. 5348 5349case $host_os in 5350aix[[4-9]]*) 5351 lt_cv_deplibs_check_method=pass_all 5352 ;; 5353 5354beos*) 5355 lt_cv_deplibs_check_method=pass_all 5356 ;; 5357 5358bsdi[[45]]*) 5359 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)' 5360 lt_cv_file_magic_cmd='/usr/bin/file -L' 5361 lt_cv_file_magic_test_file=/shlib/libc.so 5362 ;; 5363 5364cygwin*) 5365 # func_win32_libid is a shell function defined in ltmain.sh 5366 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' 5367 lt_cv_file_magic_cmd='func_win32_libid' 5368 ;; 5369 5370mingw* | pw32*) 5371 # Base MSYS/MinGW do not provide the 'file' command needed by 5372 # func_win32_libid shell function, so use a weaker test based on 'objdump', 5373 # unless we find 'file', for example because we are cross-compiling. 5374 # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin. 5375 if ( test "$lt_cv_nm_interface" = "BSD nm" && file / ) >/dev/null 2>&1; then 5376 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' 5377 lt_cv_file_magic_cmd='func_win32_libid' 5378 else 5379 # Keep this pattern in sync with the one in func_win32_libid. 5380 lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' 5381 lt_cv_file_magic_cmd='$OBJDUMP -f' 5382 fi 5383 ;; 5384 5385cegcc*) 5386 # use the weaker test based on 'objdump'. See mingw*. 5387 lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?' 5388 lt_cv_file_magic_cmd='$OBJDUMP -f' 5389 ;; 5390 5391darwin* | rhapsody*) 5392 lt_cv_deplibs_check_method=pass_all 5393 ;; 5394 5395freebsd* | dragonfly*) 5396 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then 5397 case $host_cpu in 5398 i*86 ) 5399 # Not sure whether the presence of OpenBSD here was a mistake. 5400 # Let's accept both of them until this is cleared up. 5401 lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library' 5402 lt_cv_file_magic_cmd=/usr/bin/file 5403 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` 5404 ;; 5405 esac 5406 else 5407 lt_cv_deplibs_check_method=pass_all 5408 fi 5409 ;; 5410 5411gnu*) 5412 lt_cv_deplibs_check_method=pass_all 5413 ;; 5414 5415haiku*) 5416 lt_cv_deplibs_check_method=pass_all 5417 ;; 5418 5419hpux10.20* | hpux11*) 5420 lt_cv_file_magic_cmd=/usr/bin/file 5421 case $host_cpu in 5422 ia64*) 5423 lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64' 5424 lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so 5425 ;; 5426 hppa*64*) 5427 [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]'] 5428 lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl 5429 ;; 5430 *) 5431 lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]]\.[[0-9]]) shared library' 5432 lt_cv_file_magic_test_file=/usr/lib/libc.sl 5433 ;; 5434 esac 5435 ;; 5436 5437interix[[3-9]]*) 5438 # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here 5439 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$' 5440 ;; 5441 5442irix5* | irix6* | nonstopux*) 5443 case $LD in 5444 *-32|*"-32 ") libmagic=32-bit;; 5445 *-n32|*"-n32 ") libmagic=N32;; 5446 *-64|*"-64 ") libmagic=64-bit;; 5447 *) libmagic=never-match;; 5448 esac 5449 lt_cv_deplibs_check_method=pass_all 5450 ;; 5451 5452# This must be Linux ELF. 5453linux* | k*bsd*-gnu | kopensolaris*-gnu) 5454 lt_cv_deplibs_check_method=pass_all 5455 ;; 5456 5457netbsd*) 5458 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then 5459 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' 5460 else 5461 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$' 5462 fi 5463 ;; 5464 5465newos6*) 5466 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)' 5467 lt_cv_file_magic_cmd=/usr/bin/file 5468 lt_cv_file_magic_test_file=/usr/lib/libnls.so 5469 ;; 5470 5471*nto* | *qnx*) 5472 lt_cv_deplibs_check_method=pass_all 5473 ;; 5474 5475openbsd*) 5476 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then 5477 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$' 5478 else 5479 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' 5480 fi 5481 ;; 5482 5483osf3* | osf4* | osf5*) 5484 lt_cv_deplibs_check_method=pass_all 5485 ;; 5486 5487rdos*) 5488 lt_cv_deplibs_check_method=pass_all 5489 ;; 5490 5491solaris*) 5492 lt_cv_deplibs_check_method=pass_all 5493 ;; 5494 5495sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) 5496 lt_cv_deplibs_check_method=pass_all 5497 ;; 5498 5499sysv4 | sysv4.3*) 5500 case $host_vendor in 5501 motorola) 5502 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]]' 5503 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` 5504 ;; 5505 ncr) 5506 lt_cv_deplibs_check_method=pass_all 5507 ;; 5508 sequent) 5509 lt_cv_file_magic_cmd='/bin/file' 5510 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )' 5511 ;; 5512 sni) 5513 lt_cv_file_magic_cmd='/bin/file' 5514 lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib" 5515 lt_cv_file_magic_test_file=/lib/libc.so 5516 ;; 5517 siemens) 5518 lt_cv_deplibs_check_method=pass_all 5519 ;; 5520 pc) 5521 lt_cv_deplibs_check_method=pass_all 5522 ;; 5523 esac 5524 ;; 5525 5526tpf*) 5527 lt_cv_deplibs_check_method=pass_all 5528 ;; 5529esac 5530]) 5531file_magic_cmd=$lt_cv_file_magic_cmd 5532deplibs_check_method=$lt_cv_deplibs_check_method 5533test -z "$deplibs_check_method" && deplibs_check_method=unknown 5534 5535_LT_DECL([], [deplibs_check_method], [1], 5536 [Method to check whether dependent libraries are shared objects]) 5537_LT_DECL([], [file_magic_cmd], [1], 5538 [Command to use when deplibs_check_method == "file_magic"]) 5539])# _LT_CHECK_MAGIC_METHOD 5540 5541 5542# LT_PATH_NM 5543# ---------- 5544# find the pathname to a BSD- or MS-compatible name lister 5545AC_DEFUN([LT_PATH_NM], 5546[AC_REQUIRE([AC_PROG_CC])dnl 5547AC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM, 5548[if test -n "$NM"; then 5549 # Let the user override the test. 5550 lt_cv_path_NM="$NM" 5551else 5552 lt_nm_to_check="${ac_tool_prefix}nm" 5553 if test -n "$ac_tool_prefix" && test "$build" = "$host"; then 5554 lt_nm_to_check="$lt_nm_to_check nm" 5555 fi 5556 for lt_tmp_nm in $lt_nm_to_check; do 5557 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR 5558 for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do 5559 IFS="$lt_save_ifs" 5560 test -z "$ac_dir" && ac_dir=. 5561 tmp_nm="$ac_dir/$lt_tmp_nm" 5562 if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then 5563 # Check to see if the nm accepts a BSD-compat flag. 5564 # Adding the `sed 1q' prevents false positives on HP-UX, which says: 5565 # nm: unknown option "B" ignored 5566 # Tru64's nm complains that /dev/null is an invalid object file 5567 case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in 5568 */dev/null* | *'Invalid file or object type'*) 5569 lt_cv_path_NM="$tmp_nm -B" 5570 break 5571 ;; 5572 *) 5573 case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in 5574 */dev/null*) 5575 lt_cv_path_NM="$tmp_nm -p" 5576 break 5577 ;; 5578 *) 5579 lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but 5580 continue # so that we can try to find one that supports BSD flags 5581 ;; 5582 esac 5583 ;; 5584 esac 5585 fi 5586 done 5587 IFS="$lt_save_ifs" 5588 done 5589 : ${lt_cv_path_NM=no} 5590fi]) 5591if test "$lt_cv_path_NM" != "no"; then 5592 NM="$lt_cv_path_NM" 5593else 5594 # Didn't find any BSD compatible name lister, look for dumpbin. 5595 if test -n "$DUMPBIN"; then : 5596 # Let the user override the test. 5597 else 5598 AC_CHECK_TOOLS(DUMPBIN, [dumpbin "link -dump"], :) 5599 case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in 5600 *COFF*) 5601 DUMPBIN="$DUMPBIN -symbols" 5602 ;; 5603 *) 5604 DUMPBIN=: 5605 ;; 5606 esac 5607 fi 5608 AC_SUBST([DUMPBIN]) 5609 if test "$DUMPBIN" != ":"; then 5610 NM="$DUMPBIN" 5611 fi 5612fi 5613test -z "$NM" && NM=nm 5614AC_SUBST([NM]) 5615_LT_DECL([], [NM], [1], [A BSD- or MS-compatible name lister])dnl 5616 5617AC_CACHE_CHECK([the name lister ($NM) interface], [lt_cv_nm_interface], 5618 [lt_cv_nm_interface="BSD nm" 5619 echo "int some_variable = 0;" > conftest.$ac_ext 5620 (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&AS_MESSAGE_LOG_FD) 5621 (eval "$ac_compile" 2>conftest.err) 5622 cat conftest.err >&AS_MESSAGE_LOG_FD 5623 (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD) 5624 (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) 5625 cat conftest.err >&AS_MESSAGE_LOG_FD 5626 (eval echo "\"\$as_me:$LINENO: output\"" >&AS_MESSAGE_LOG_FD) 5627 cat conftest.out >&AS_MESSAGE_LOG_FD 5628 if $GREP 'External.*some_variable' conftest.out > /dev/null; then 5629 lt_cv_nm_interface="MS dumpbin" 5630 fi 5631 rm -f conftest*]) 5632])# LT_PATH_NM 5633 5634# Old names: 5635AU_ALIAS([AM_PROG_NM], [LT_PATH_NM]) 5636AU_ALIAS([AC_PROG_NM], [LT_PATH_NM]) 5637dnl aclocal-1.4 backwards compatibility: 5638dnl AC_DEFUN([AM_PROG_NM], []) 5639dnl AC_DEFUN([AC_PROG_NM], []) 5640 5641 5642# LT_LIB_M 5643# -------- 5644# check for math library 5645AC_DEFUN([LT_LIB_M], 5646[AC_REQUIRE([AC_CANONICAL_HOST])dnl 5647LIBM= 5648case $host in 5649*-*-beos* | *-*-cegcc* | *-*-cygwin* | *-*-haiku* | *-*-pw32* | *-*-darwin*) 5650 # These system don't have libm, or don't need it 5651 ;; 5652*-ncr-sysv4.3*) 5653 AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw") 5654 AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm") 5655 ;; 5656*) 5657 AC_CHECK_LIB(m, cos, LIBM="-lm") 5658 ;; 5659esac 5660AC_SUBST([LIBM]) 5661])# LT_LIB_M 5662 5663# Old name: 5664AU_ALIAS([AC_CHECK_LIBM], [LT_LIB_M]) 5665dnl aclocal-1.4 backwards compatibility: 5666dnl AC_DEFUN([AC_CHECK_LIBM], []) 5667 5668 5669# _LT_COMPILER_NO_RTTI([TAGNAME]) 5670# ------------------------------- 5671m4_defun([_LT_COMPILER_NO_RTTI], 5672[m4_require([_LT_TAG_COMPILER])dnl 5673 5674_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= 5675 5676if test "$GCC" = yes; then 5677 case $cc_basename in 5678 nvcc*) 5679 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -Xcompiler -fno-builtin' ;; 5680 *) 5681 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' ;; 5682 esac 5683 5684 _LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions], 5685 lt_cv_prog_compiler_rtti_exceptions, 5686 [-fno-rtti -fno-exceptions], [], 5687 [_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"]) 5688fi 5689_LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1], 5690 [Compiler flag to turn off builtin functions]) 5691])# _LT_COMPILER_NO_RTTI 5692 5693 5694# _LT_CMD_GLOBAL_SYMBOLS 5695# ---------------------- 5696m4_defun([_LT_CMD_GLOBAL_SYMBOLS], 5697[AC_REQUIRE([AC_CANONICAL_HOST])dnl 5698AC_REQUIRE([AC_PROG_CC])dnl 5699AC_REQUIRE([AC_PROG_AWK])dnl 5700AC_REQUIRE([LT_PATH_NM])dnl 5701AC_REQUIRE([LT_PATH_LD])dnl 5702m4_require([_LT_DECL_SED])dnl 5703m4_require([_LT_DECL_EGREP])dnl 5704m4_require([_LT_TAG_COMPILER])dnl 5705 5706# Check for command to grab the raw symbol name followed by C symbol from nm. 5707AC_MSG_CHECKING([command to parse $NM output from $compiler object]) 5708AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe], 5709[ 5710# These are sane defaults that work on at least a few old systems. 5711# [They come from Ultrix. What could be older than Ultrix?!! ;)] 5712 5713# Character class describing NM global symbol codes. 5714symcode='[[BCDEGRST]]' 5715 5716# Regexp to match symbols that can be accessed directly from C. 5717sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)' 5718 5719# Define system-specific variables. 5720case $host_os in 5721aix*) 5722 symcode='[[BCDT]]' 5723 ;; 5724cygwin* | mingw* | pw32* | cegcc*) 5725 symcode='[[ABCDGISTW]]' 5726 ;; 5727hpux*) 5728 if test "$host_cpu" = ia64; then 5729 symcode='[[ABCDEGRST]]' 5730 fi 5731 ;; 5732irix* | nonstopux*) 5733 symcode='[[BCDEGRST]]' 5734 ;; 5735osf*) 5736 symcode='[[BCDEGQRST]]' 5737 ;; 5738solaris*) 5739 symcode='[[BDRT]]' 5740 ;; 5741sco3.2v5*) 5742 symcode='[[DT]]' 5743 ;; 5744sysv4.2uw2*) 5745 symcode='[[DT]]' 5746 ;; 5747sysv5* | sco5v6* | unixware* | OpenUNIX*) 5748 symcode='[[ABDT]]' 5749 ;; 5750sysv4) 5751 symcode='[[DFNSTU]]' 5752 ;; 5753esac 5754 5755# If we're using GNU nm, then use its standard symbol codes. 5756case `$NM -V 2>&1` in 5757*GNU* | *'with BFD'*) 5758 symcode='[[ABCDGIRSTW]]' ;; 5759esac 5760 5761# Transform an extracted symbol line into a proper C declaration. 5762# Some systems (esp. on ia64) link data and code symbols differently, 5763# so use this general approach. 5764lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" 5765 5766# Transform an extracted symbol line into symbol name and symbol address 5767lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p'" 5768lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \(lib[[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"lib\2\", (void *) \&\2},/p'" 5769 5770# Handle CRLF in mingw tool chain 5771opt_cr= 5772case $build_os in 5773mingw*) 5774 opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp 5775 ;; 5776esac 5777 5778# Try without a prefix underscore, then with it. 5779for ac_symprfx in "" "_"; do 5780 5781 # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. 5782 symxfrm="\\1 $ac_symprfx\\2 \\2" 5783 5784 # Write the raw and C identifiers. 5785 if test "$lt_cv_nm_interface" = "MS dumpbin"; then 5786 # Fake it for dumpbin and say T for any non-static function 5787 # and D for any global variable. 5788 # Also find C++ and __fastcall symbols from MSVC++, 5789 # which start with @ or ?. 5790 lt_cv_sys_global_symbol_pipe="$AWK ['"\ 5791" {last_section=section; section=\$ 3};"\ 5792" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\ 5793" \$ 0!~/External *\|/{next};"\ 5794" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\ 5795" {if(hide[section]) next};"\ 5796" {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\ 5797" {split(\$ 0, a, /\||\r/); split(a[2], s)};"\ 5798" s[1]~/^[@?]/{print s[1], s[1]; next};"\ 5799" s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\ 5800" ' prfx=^$ac_symprfx]" 5801 else 5802 lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" 5803 fi 5804 5805 # Check to see that the pipe works correctly. 5806 pipe_works=no 5807 5808 rm -f conftest* 5809 cat > conftest.$ac_ext <<_LT_EOF 5810#ifdef __cplusplus 5811extern "C" { 5812#endif 5813char nm_test_var; 5814void nm_test_func(void); 5815void nm_test_func(void){} 5816#ifdef __cplusplus 5817} 5818#endif 5819int main(){nm_test_var='a';nm_test_func();return(0);} 5820_LT_EOF 5821 5822 if AC_TRY_EVAL(ac_compile); then 5823 # Now try to grab the symbols. 5824 nlist=conftest.nm 5825 if AC_TRY_EVAL(NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) && test -s "$nlist"; then 5826 # Try sorting and uniquifying the output. 5827 if sort "$nlist" | uniq > "$nlist"T; then 5828 mv -f "$nlist"T "$nlist" 5829 else 5830 rm -f "$nlist"T 5831 fi 5832 5833 # Make sure that we snagged all the symbols we need. 5834 if $GREP ' nm_test_var$' "$nlist" >/dev/null; then 5835 if $GREP ' nm_test_func$' "$nlist" >/dev/null; then 5836 cat <<_LT_EOF > conftest.$ac_ext 5837#ifdef __cplusplus 5838extern "C" { 5839#endif 5840 5841_LT_EOF 5842 # Now generate the symbol file. 5843 eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext' 5844 5845 cat <<_LT_EOF >> conftest.$ac_ext 5846 5847/* The mapping between symbol names and symbols. */ 5848const struct { 5849 const char *name; 5850 void *address; 5851} 5852lt__PROGRAM__LTX_preloaded_symbols[[]] = 5853{ 5854 { "@PROGRAM@", (void *) 0 }, 5855_LT_EOF 5856 $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext 5857 cat <<\_LT_EOF >> conftest.$ac_ext 5858 {0, (void *) 0} 5859}; 5860 5861/* This works around a problem in FreeBSD linker */ 5862#ifdef FREEBSD_WORKAROUND 5863static const void *lt_preloaded_setup() { 5864 return lt__PROGRAM__LTX_preloaded_symbols; 5865} 5866#endif 5867 5868#ifdef __cplusplus 5869} 5870#endif 5871_LT_EOF 5872 # Now try linking the two files. 5873 mv conftest.$ac_objext conftstm.$ac_objext 5874 lt_save_LIBS="$LIBS" 5875 lt_save_CFLAGS="$CFLAGS" 5876 LIBS="conftstm.$ac_objext" 5877 CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)" 5878 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then 5879 pipe_works=yes 5880 fi 5881 LIBS="$lt_save_LIBS" 5882 CFLAGS="$lt_save_CFLAGS" 5883 else 5884 echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD 5885 fi 5886 else 5887 echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD 5888 fi 5889 else 5890 echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD 5891 fi 5892 else 5893 echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD 5894 cat conftest.$ac_ext >&5 5895 fi 5896 rm -rf conftest* conftst* 5897 5898 # Do not use the global_symbol_pipe unless it works. 5899 if test "$pipe_works" = yes; then 5900 break 5901 else 5902 lt_cv_sys_global_symbol_pipe= 5903 fi 5904done 5905]) 5906if test -z "$lt_cv_sys_global_symbol_pipe"; then 5907 lt_cv_sys_global_symbol_to_cdecl= 5908fi 5909if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then 5910 AC_MSG_RESULT(failed) 5911else 5912 AC_MSG_RESULT(ok) 5913fi 5914 5915_LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1], 5916 [Take the output of nm and produce a listing of raw symbols and C names]) 5917_LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1], 5918 [Transform the output of nm in a proper C declaration]) 5919_LT_DECL([global_symbol_to_c_name_address], 5920 [lt_cv_sys_global_symbol_to_c_name_address], [1], 5921 [Transform the output of nm in a C name address pair]) 5922_LT_DECL([global_symbol_to_c_name_address_lib_prefix], 5923 [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1], 5924 [Transform the output of nm in a C name address pair when lib prefix is needed]) 5925]) # _LT_CMD_GLOBAL_SYMBOLS 5926 5927 5928# _LT_COMPILER_PIC([TAGNAME]) 5929# --------------------------- 5930m4_defun([_LT_COMPILER_PIC], 5931[m4_require([_LT_TAG_COMPILER])dnl 5932_LT_TAGVAR(lt_prog_compiler_wl, $1)= 5933_LT_TAGVAR(lt_prog_compiler_pic, $1)= 5934_LT_TAGVAR(lt_prog_compiler_static, $1)= 5935 5936AC_MSG_CHECKING([for $compiler option to produce PIC]) 5937m4_if([$1], [CXX], [ 5938 # C++ specific cases for pic, static, wl, etc. 5939 if test "$GXX" = yes; then 5940 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 5941 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 5942 5943 case $host_os in 5944 aix*) 5945 # All AIX code is PIC. 5946 if test "$host_cpu" = ia64; then 5947 # AIX 5 now supports IA64 processor 5948 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 5949 fi 5950 ;; 5951 5952 amigaos*) 5953 case $host_cpu in 5954 powerpc) 5955 # see comment about AmigaOS4 .so support 5956 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 5957 ;; 5958 m68k) 5959 # FIXME: we need at least 68020 code to build shared libraries, but 5960 # adding the `-m68020' flag to GCC prevents building anything better, 5961 # like `-m68040'. 5962 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' 5963 ;; 5964 esac 5965 ;; 5966 5967 beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) 5968 # PIC is the default for these OSes. 5969 ;; 5970 mingw* | cygwin* | os2* | pw32* | cegcc*) 5971 # This hack is so that the source file can tell whether it is being 5972 # built for inclusion in a dll (and should export symbols for example). 5973 # Although the cygwin gcc ignores -fPIC, still need this for old-style 5974 # (--disable-auto-import) libraries 5975 m4_if([$1], [GCJ], [], 5976 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) 5977 ;; 5978 darwin* | rhapsody*) 5979 # PIC is the default on this platform 5980 # Common symbols not allowed in MH_DYLIB files 5981 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' 5982 ;; 5983 *djgpp*) 5984 # DJGPP does not support shared libraries at all 5985 _LT_TAGVAR(lt_prog_compiler_pic, $1)= 5986 ;; 5987 haiku*) 5988 # PIC is the default for Haiku. 5989 # The "-static" flag exists, but is broken. 5990 _LT_TAGVAR(lt_prog_compiler_static, $1)= 5991 ;; 5992 interix[[3-9]]*) 5993 # Interix 3.x gcc -fpic/-fPIC options generate broken code. 5994 # Instead, we relocate shared libraries at runtime. 5995 ;; 5996 sysv4*MP*) 5997 if test -d /usr/nec; then 5998 _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic 5999 fi 6000 ;; 6001 hpux*) 6002 # PIC is the default for 64-bit PA HP-UX, but not for 32-bit 6003 # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag 6004 # sets the default TLS model and affects inlining. 6005 case $host_cpu in 6006 hppa*64*) 6007 ;; 6008 *) 6009 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 6010 ;; 6011 esac 6012 ;; 6013 *qnx* | *nto*) 6014 # QNX uses GNU C++, but need to define -shared option too, otherwise 6015 # it will coredump. 6016 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' 6017 ;; 6018 *) 6019 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 6020 ;; 6021 esac 6022 else 6023 case $host_os in 6024 aix[[4-9]]*) 6025 # All AIX code is PIC. 6026 if test "$host_cpu" = ia64; then 6027 # AIX 5 now supports IA64 processor 6028 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6029 else 6030 _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' 6031 fi 6032 ;; 6033 chorus*) 6034 case $cc_basename in 6035 cxch68*) 6036 # Green Hills C++ Compiler 6037 # _LT_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" 6038 ;; 6039 esac 6040 ;; 6041 dgux*) 6042 case $cc_basename in 6043 ec++*) 6044 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6045 ;; 6046 ghcx*) 6047 # Green Hills C++ Compiler 6048 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 6049 ;; 6050 *) 6051 ;; 6052 esac 6053 ;; 6054 freebsd* | dragonfly*) 6055 # FreeBSD uses GNU C++ 6056 ;; 6057 hpux9* | hpux10* | hpux11*) 6058 case $cc_basename in 6059 CC*) 6060 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6061 _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' 6062 if test "$host_cpu" != ia64; then 6063 _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' 6064 fi 6065 ;; 6066 aCC*) 6067 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6068 _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' 6069 case $host_cpu in 6070 hppa*64*|ia64*) 6071 # +Z the default 6072 ;; 6073 *) 6074 _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' 6075 ;; 6076 esac 6077 ;; 6078 *) 6079 ;; 6080 esac 6081 ;; 6082 interix*) 6083 # This is c89, which is MS Visual C++ (no shared libs) 6084 # Anyone wants to do a port? 6085 ;; 6086 irix5* | irix6* | nonstopux*) 6087 case $cc_basename in 6088 CC*) 6089 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6090 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 6091 # CC pic flag -KPIC is the default. 6092 ;; 6093 *) 6094 ;; 6095 esac 6096 ;; 6097 linux* | k*bsd*-gnu | kopensolaris*-gnu) 6098 case $cc_basename in 6099 KCC*) 6100 # KAI C++ Compiler 6101 _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' 6102 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 6103 ;; 6104 ecpc* ) 6105 # old Intel C++ for x86_64 which still supported -KPIC. 6106 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6107 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6108 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 6109 ;; 6110 icpc* ) 6111 # Intel C++, used to be incompatible with GCC. 6112 # ICC 10 doesn't accept -KPIC any more. 6113 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6114 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 6115 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 6116 ;; 6117 pgCC* | pgcpp*) 6118 # Portland Group C++ compiler 6119 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6120 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' 6121 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6122 ;; 6123 cxx*) 6124 # Compaq C++ 6125 # Make sure the PIC flag is empty. It appears that all Alpha 6126 # Linux and Compaq Tru64 Unix objects are PIC. 6127 _LT_TAGVAR(lt_prog_compiler_pic, $1)= 6128 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 6129 ;; 6130 xlc* | xlC* | bgxl[[cC]]* | mpixl[[cC]]*) 6131 # IBM XL 8.0, 9.0 on PPC and BlueGene 6132 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6133 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' 6134 _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' 6135 ;; 6136 *) 6137 case `$CC -V 2>&1 | sed 5q` in 6138 *Sun\ C*) 6139 # Sun C++ 5.9 6140 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6141 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6142 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' 6143 ;; 6144 esac 6145 ;; 6146 esac 6147 ;; 6148 lynxos*) 6149 ;; 6150 m88k*) 6151 ;; 6152 mvs*) 6153 case $cc_basename in 6154 cxx*) 6155 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall' 6156 ;; 6157 *) 6158 ;; 6159 esac 6160 ;; 6161 netbsd*) 6162 ;; 6163 *qnx* | *nto*) 6164 # QNX uses GNU C++, but need to define -shared option too, otherwise 6165 # it will coredump. 6166 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' 6167 ;; 6168 osf3* | osf4* | osf5*) 6169 case $cc_basename in 6170 KCC*) 6171 _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' 6172 ;; 6173 RCC*) 6174 # Rational C++ 2.4.1 6175 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 6176 ;; 6177 cxx*) 6178 # Digital/Compaq C++ 6179 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6180 # Make sure the PIC flag is empty. It appears that all Alpha 6181 # Linux and Compaq Tru64 Unix objects are PIC. 6182 _LT_TAGVAR(lt_prog_compiler_pic, $1)= 6183 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 6184 ;; 6185 *) 6186 ;; 6187 esac 6188 ;; 6189 psos*) 6190 ;; 6191 solaris*) 6192 case $cc_basename in 6193 CC* | sunCC*) 6194 # Sun C++ 4.2, 5.x and Centerline C++ 6195 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6196 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6197 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' 6198 ;; 6199 gcx*) 6200 # Green Hills C++ Compiler 6201 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' 6202 ;; 6203 *) 6204 ;; 6205 esac 6206 ;; 6207 sunos4*) 6208 case $cc_basename in 6209 CC*) 6210 # Sun C++ 4.x 6211 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 6212 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6213 ;; 6214 lcc*) 6215 # Lucid 6216 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 6217 ;; 6218 *) 6219 ;; 6220 esac 6221 ;; 6222 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) 6223 case $cc_basename in 6224 CC*) 6225 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6226 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6227 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6228 ;; 6229 esac 6230 ;; 6231 tandem*) 6232 case $cc_basename in 6233 NCC*) 6234 # NonStop-UX NCC 3.20 6235 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6236 ;; 6237 *) 6238 ;; 6239 esac 6240 ;; 6241 vxworks*) 6242 ;; 6243 *) 6244 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 6245 ;; 6246 esac 6247 fi 6248], 6249[ 6250 if test "$GCC" = yes; then 6251 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6252 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 6253 6254 case $host_os in 6255 aix*) 6256 # All AIX code is PIC. 6257 if test "$host_cpu" = ia64; then 6258 # AIX 5 now supports IA64 processor 6259 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6260 fi 6261 ;; 6262 6263 amigaos*) 6264 case $host_cpu in 6265 powerpc) 6266 # see comment about AmigaOS4 .so support 6267 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 6268 ;; 6269 m68k) 6270 # FIXME: we need at least 68020 code to build shared libraries, but 6271 # adding the `-m68020' flag to GCC prevents building anything better, 6272 # like `-m68040'. 6273 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' 6274 ;; 6275 esac 6276 ;; 6277 6278 beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) 6279 # PIC is the default for these OSes. 6280 ;; 6281 6282 mingw* | cygwin* | pw32* | os2* | cegcc*) 6283 # This hack is so that the source file can tell whether it is being 6284 # built for inclusion in a dll (and should export symbols for example). 6285 # Although the cygwin gcc ignores -fPIC, still need this for old-style 6286 # (--disable-auto-import) libraries 6287 m4_if([$1], [GCJ], [], 6288 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) 6289 ;; 6290 6291 darwin* | rhapsody*) 6292 # PIC is the default on this platform 6293 # Common symbols not allowed in MH_DYLIB files 6294 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' 6295 ;; 6296 6297 haiku*) 6298 # PIC is the default for Haiku. 6299 # The "-static" flag exists, but is broken. 6300 _LT_TAGVAR(lt_prog_compiler_static, $1)= 6301 ;; 6302 6303 hpux*) 6304 # PIC is the default for 64-bit PA HP-UX, but not for 32-bit 6305 # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag 6306 # sets the default TLS model and affects inlining. 6307 case $host_cpu in 6308 hppa*64*) 6309 # +Z the default 6310 ;; 6311 *) 6312 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 6313 ;; 6314 esac 6315 ;; 6316 6317 interix[[3-9]]*) 6318 # Interix 3.x gcc -fpic/-fPIC options generate broken code. 6319 # Instead, we relocate shared libraries at runtime. 6320 ;; 6321 6322 msdosdjgpp*) 6323 # Just because we use GCC doesn't mean we suddenly get shared libraries 6324 # on systems that don't support them. 6325 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 6326 enable_shared=no 6327 ;; 6328 6329 *nto* | *qnx*) 6330 # QNX uses GNU C++, but need to define -shared option too, otherwise 6331 # it will coredump. 6332 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' 6333 ;; 6334 6335 sysv4*MP*) 6336 if test -d /usr/nec; then 6337 _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic 6338 fi 6339 ;; 6340 6341 *) 6342 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 6343 ;; 6344 esac 6345 6346 case $cc_basename in 6347 nvcc*) # Cuda Compiler Driver 2.2 6348 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Xlinker ' 6349 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Xcompiler -fPIC' 6350 ;; 6351 esac 6352 else 6353 # PORTME Check for flag to pass linker flags through the system compiler. 6354 case $host_os in 6355 aix*) 6356 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6357 if test "$host_cpu" = ia64; then 6358 # AIX 5 now supports IA64 processor 6359 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6360 else 6361 _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' 6362 fi 6363 ;; 6364 6365 mingw* | cygwin* | pw32* | os2* | cegcc*) 6366 # This hack is so that the source file can tell whether it is being 6367 # built for inclusion in a dll (and should export symbols for example). 6368 m4_if([$1], [GCJ], [], 6369 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) 6370 ;; 6371 6372 hpux9* | hpux10* | hpux11*) 6373 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6374 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but 6375 # not for PA HP-UX. 6376 case $host_cpu in 6377 hppa*64*|ia64*) 6378 # +Z the default 6379 ;; 6380 *) 6381 _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' 6382 ;; 6383 esac 6384 # Is there a better lt_prog_compiler_static that works with the bundled CC? 6385 _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' 6386 ;; 6387 6388 irix5* | irix6* | nonstopux*) 6389 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6390 # PIC (with -KPIC) is the default. 6391 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 6392 ;; 6393 6394 linux* | k*bsd*-gnu | kopensolaris*-gnu) 6395 case $cc_basename in 6396 # old Intel for x86_64 which still supported -KPIC. 6397 ecc*) 6398 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6399 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6400 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 6401 ;; 6402 # icc used to be incompatible with GCC. 6403 # ICC 10 doesn't accept -KPIC any more. 6404 icc* | ifort*) 6405 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6406 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 6407 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 6408 ;; 6409 # Lahey Fortran 8.1. 6410 lf95*) 6411 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6412 _LT_TAGVAR(lt_prog_compiler_pic, $1)='--shared' 6413 _LT_TAGVAR(lt_prog_compiler_static, $1)='--static' 6414 ;; 6415 pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) 6416 # Portland Group compilers (*not* the Pentium gcc compiler, 6417 # which looks to be a dead project) 6418 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6419 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' 6420 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6421 ;; 6422 ccc*) 6423 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6424 # All Alpha code is PIC. 6425 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 6426 ;; 6427 xl* | bgxl* | bgf* | mpixl*) 6428 # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene 6429 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6430 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' 6431 _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' 6432 ;; 6433 *) 6434 case `$CC -V 2>&1 | sed 5q` in 6435 *Sun\ F* | *Sun*Fortran*) 6436 # Sun Fortran 8.3 passes all unrecognized flags to the linker 6437 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6438 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6439 _LT_TAGVAR(lt_prog_compiler_wl, $1)='' 6440 ;; 6441 *Sun\ C*) 6442 # Sun C 5.9 6443 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6444 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6445 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6446 ;; 6447 esac 6448 ;; 6449 esac 6450 ;; 6451 6452 newsos6) 6453 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6454 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6455 ;; 6456 6457 *nto* | *qnx*) 6458 # QNX uses GNU C++, but need to define -shared option too, otherwise 6459 # it will coredump. 6460 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' 6461 ;; 6462 6463 osf3* | osf4* | osf5*) 6464 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6465 # All OSF/1 code is PIC. 6466 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 6467 ;; 6468 6469 rdos*) 6470 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 6471 ;; 6472 6473 solaris*) 6474 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6475 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6476 case $cc_basename in 6477 f77* | f90* | f95* | sunf77* | sunf90* | sunf95*) 6478 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';; 6479 *) 6480 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';; 6481 esac 6482 ;; 6483 6484 sunos4*) 6485 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' 6486 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' 6487 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6488 ;; 6489 6490 sysv4 | sysv4.2uw2* | sysv4.3*) 6491 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6492 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6493 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6494 ;; 6495 6496 sysv4*MP*) 6497 if test -d /usr/nec ;then 6498 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic' 6499 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6500 fi 6501 ;; 6502 6503 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) 6504 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6505 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6506 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6507 ;; 6508 6509 unicos*) 6510 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6511 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 6512 ;; 6513 6514 uts4*) 6515 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 6516 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6517 ;; 6518 6519 *) 6520 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 6521 ;; 6522 esac 6523 fi 6524]) 6525case $host_os in 6526 # For platforms which do not support PIC, -DPIC is meaningless: 6527 *djgpp*) 6528 _LT_TAGVAR(lt_prog_compiler_pic, $1)= 6529 ;; 6530 *) 6531 _LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])" 6532 ;; 6533esac 6534AC_MSG_RESULT([$_LT_TAGVAR(lt_prog_compiler_pic, $1)]) 6535_LT_TAGDECL([wl], [lt_prog_compiler_wl], [1], 6536 [How to pass a linker flag through the compiler]) 6537 6538# 6539# Check to make sure the PIC flag actually works. 6540# 6541if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then 6542 _LT_COMPILER_OPTION([if $compiler PIC flag $_LT_TAGVAR(lt_prog_compiler_pic, $1) works], 6543 [_LT_TAGVAR(lt_cv_prog_compiler_pic_works, $1)], 6544 [$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])], [], 6545 [case $_LT_TAGVAR(lt_prog_compiler_pic, $1) in 6546 "" | " "*) ;; 6547 *) _LT_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_TAGVAR(lt_prog_compiler_pic, $1)" ;; 6548 esac], 6549 [_LT_TAGVAR(lt_prog_compiler_pic, $1)= 6550 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no]) 6551fi 6552_LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1], 6553 [Additional compiler flags for building library objects]) 6554 6555# 6556# Check to make sure the static flag actually works. 6557# 6558wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_TAGVAR(lt_prog_compiler_static, $1)\" 6559_LT_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works], 6560 _LT_TAGVAR(lt_cv_prog_compiler_static_works, $1), 6561 $lt_tmp_static_flag, 6562 [], 6563 [_LT_TAGVAR(lt_prog_compiler_static, $1)=]) 6564_LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1], 6565 [Compiler flag to prevent dynamic linking]) 6566])# _LT_COMPILER_PIC 6567 6568 6569# _LT_LINKER_SHLIBS([TAGNAME]) 6570# ---------------------------- 6571# See if the linker supports building shared libraries. 6572m4_defun([_LT_LINKER_SHLIBS], 6573[AC_REQUIRE([LT_PATH_LD])dnl 6574AC_REQUIRE([LT_PATH_NM])dnl 6575m4_require([_LT_FILEUTILS_DEFAULTS])dnl 6576m4_require([_LT_DECL_EGREP])dnl 6577m4_require([_LT_DECL_SED])dnl 6578m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl 6579m4_require([_LT_TAG_COMPILER])dnl 6580AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) 6581m4_if([$1], [CXX], [ 6582 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' 6583 case $host_os in 6584 aix[[4-9]]*) 6585 # If we're using GNU nm, then we don't want the "-C" option. 6586 # -C means demangle to AIX nm, but means don't demangle with GNU nm 6587 # Also, AIX nm treats weak defined symbols like other global defined 6588 # symbols, whereas GNU nm marks them as "W". 6589 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then 6590 _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' 6591 else 6592 _LT_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' 6593 fi 6594 ;; 6595 pw32*) 6596 _LT_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds" 6597 ;; 6598 cygwin* | mingw* | cegcc*) 6599 _LT_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' 6600 ;; 6601 *) 6602 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' 6603 ;; 6604 esac 6605 _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] 6606], [ 6607 runpath_var= 6608 _LT_TAGVAR(allow_undefined_flag, $1)= 6609 _LT_TAGVAR(always_export_symbols, $1)=no 6610 _LT_TAGVAR(archive_cmds, $1)= 6611 _LT_TAGVAR(archive_expsym_cmds, $1)= 6612 _LT_TAGVAR(compiler_needs_object, $1)=no 6613 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no 6614 _LT_TAGVAR(export_dynamic_flag_spec, $1)= 6615 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' 6616 _LT_TAGVAR(hardcode_automatic, $1)=no 6617 _LT_TAGVAR(hardcode_direct, $1)=no 6618 _LT_TAGVAR(hardcode_direct_absolute, $1)=no 6619 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 6620 _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= 6621 _LT_TAGVAR(hardcode_libdir_separator, $1)= 6622 _LT_TAGVAR(hardcode_minus_L, $1)=no 6623 _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported 6624 _LT_TAGVAR(inherit_rpath, $1)=no 6625 _LT_TAGVAR(link_all_deplibs, $1)=unknown 6626 _LT_TAGVAR(module_cmds, $1)= 6627 _LT_TAGVAR(module_expsym_cmds, $1)= 6628 _LT_TAGVAR(old_archive_from_new_cmds, $1)= 6629 _LT_TAGVAR(old_archive_from_expsyms_cmds, $1)= 6630 _LT_TAGVAR(thread_safe_flag_spec, $1)= 6631 _LT_TAGVAR(whole_archive_flag_spec, $1)= 6632 # include_expsyms should be a list of space-separated symbols to be *always* 6633 # included in the symbol list 6634 _LT_TAGVAR(include_expsyms, $1)= 6635 # exclude_expsyms can be an extended regexp of symbols to exclude 6636 # it will be wrapped by ` (' and `)$', so one must not match beginning or 6637 # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', 6638 # as well as any symbol that contains `d'. 6639 _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] 6640 # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out 6641 # platforms (ab)use it in PIC code, but their linkers get confused if 6642 # the symbol is explicitly referenced. Since portable code cannot 6643 # rely on this symbol name, it's probably fine to never include it in 6644 # preloaded symbol tables. 6645 # Exclude shared library initialization/finalization symbols. 6646dnl Note also adjust exclude_expsyms for C++ above. 6647 extract_expsyms_cmds= 6648 6649 case $host_os in 6650 cygwin* | mingw* | pw32* | cegcc*) 6651 # FIXME: the MSVC++ port hasn't been tested in a loooong time 6652 # When not using gcc, we currently assume that we are using 6653 # Microsoft Visual C++. 6654 if test "$GCC" != yes; then 6655 with_gnu_ld=no 6656 fi 6657 ;; 6658 interix*) 6659 # we just hope/assume this is gcc and not c89 (= MSVC++) 6660 with_gnu_ld=yes 6661 ;; 6662 openbsd*) 6663 with_gnu_ld=no 6664 ;; 6665 esac 6666 6667 _LT_TAGVAR(ld_shlibs, $1)=yes 6668 6669 # On some targets, GNU ld is compatible enough with the native linker 6670 # that we're better off using the native interface for both. 6671 lt_use_gnu_ld_interface=no 6672 if test "$with_gnu_ld" = yes; then 6673 case $host_os in 6674 aix*) 6675 # The AIX port of GNU ld has always aspired to compatibility 6676 # with the native linker. However, as the warning in the GNU ld 6677 # block says, versions before 2.19.5* couldn't really create working 6678 # shared libraries, regardless of the interface used. 6679 case `$LD -v 2>&1` in 6680 *\ \(GNU\ Binutils\)\ 2.19.5*) ;; 6681 *\ \(GNU\ Binutils\)\ 2.[[2-9]]*) ;; 6682 *\ \(GNU\ Binutils\)\ [[3-9]]*) ;; 6683 *) 6684 lt_use_gnu_ld_interface=yes 6685 ;; 6686 esac 6687 ;; 6688 *) 6689 lt_use_gnu_ld_interface=yes 6690 ;; 6691 esac 6692 fi 6693 6694 if test "$lt_use_gnu_ld_interface" = yes; then 6695 # If archive_cmds runs LD, not CC, wlarc should be empty 6696 wlarc='${wl}' 6697 6698 # Set some defaults for GNU ld with shared library support. These 6699 # are reset later if shared libraries are not supported. Putting them 6700 # here allows them to be overridden if necessary. 6701 runpath_var=LD_RUN_PATH 6702 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 6703 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 6704 # ancient GNU ld didn't support --whole-archive et. al. 6705 if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then 6706 _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' 6707 else 6708 _LT_TAGVAR(whole_archive_flag_spec, $1)= 6709 fi 6710 supports_anon_versioning=no 6711 case `$LD -v 2>&1` in 6712 *GNU\ gold*) supports_anon_versioning=yes ;; 6713 *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11 6714 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... 6715 *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... 6716 *\ 2.11.*) ;; # other 2.11 versions 6717 *) supports_anon_versioning=yes ;; 6718 esac 6719 6720 # See if GNU ld supports shared libraries. 6721 case $host_os in 6722 aix[[3-9]]*) 6723 # On AIX/PPC, the GNU linker is very broken 6724 if test "$host_cpu" != ia64; then 6725 _LT_TAGVAR(ld_shlibs, $1)=no 6726 cat <<_LT_EOF 1>&2 6727 6728*** Warning: the GNU linker, at least up to release 2.19, is reported 6729*** to be unable to reliably create shared libraries on AIX. 6730*** Therefore, libtool is disabling shared libraries support. If you 6731*** really care for shared libraries, you may want to install binutils 6732*** 2.20 or above, or modify your PATH so that a non-GNU linker is found. 6733*** You will then need to restart the configuration process. 6734 6735_LT_EOF 6736 fi 6737 ;; 6738 6739 amigaos*) 6740 case $host_cpu in 6741 powerpc) 6742 # see comment about AmigaOS4 .so support 6743 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 6744 _LT_TAGVAR(archive_expsym_cmds, $1)='' 6745 ;; 6746 m68k) 6747 _LT_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)' 6748 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 6749 _LT_TAGVAR(hardcode_minus_L, $1)=yes 6750 ;; 6751 esac 6752 ;; 6753 6754 beos*) 6755 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 6756 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 6757 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc 6758 # support --undefined. This deserves some investigation. FIXME 6759 _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 6760 else 6761 _LT_TAGVAR(ld_shlibs, $1)=no 6762 fi 6763 ;; 6764 6765 cygwin* | mingw* | pw32* | cegcc*) 6766 # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, 6767 # as there is no search path for DLLs. 6768 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 6769 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols' 6770 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 6771 _LT_TAGVAR(always_export_symbols, $1)=no 6772 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 6773 _LT_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' 6774 6775 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then 6776 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' 6777 # If the export-symbols file already is a .def file (1st line 6778 # is EXPORTS), use it as is; otherwise, prepend... 6779 _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then 6780 cp $export_symbols $output_objdir/$soname.def; 6781 else 6782 echo EXPORTS > $output_objdir/$soname.def; 6783 cat $export_symbols >> $output_objdir/$soname.def; 6784 fi~ 6785 $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' 6786 else 6787 _LT_TAGVAR(ld_shlibs, $1)=no 6788 fi 6789 ;; 6790 6791 haiku*) 6792 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 6793 _LT_TAGVAR(link_all_deplibs, $1)=yes 6794 ;; 6795 6796 interix[[3-9]]*) 6797 _LT_TAGVAR(hardcode_direct, $1)=no 6798 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 6799 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 6800 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 6801 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. 6802 # Instead, shared libraries are loaded at an image base (0x10000000 by 6803 # default) and relocated if they conflict, which is a slow very memory 6804 # consuming and fragmenting process. To avoid this, we pick a random, 6805 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link 6806 # time. Moving up from 0x10000000 also allows more sbrk(2) space. 6807 _LT_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' 6808 _LT_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' 6809 ;; 6810 6811 gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) 6812 tmp_diet=no 6813 if test "$host_os" = linux-dietlibc; then 6814 case $cc_basename in 6815 diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn) 6816 esac 6817 fi 6818 if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ 6819 && test "$tmp_diet" = no 6820 then 6821 tmp_addflag= 6822 tmp_sharedflag='-shared' 6823 case $cc_basename,$host_cpu in 6824 pgcc*) # Portland Group C compiler 6825 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' 6826 tmp_addflag=' $pic_flag' 6827 ;; 6828 pgf77* | pgf90* | pgf95* | pgfortran*) 6829 # Portland Group f77 and f90 compilers 6830 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' 6831 tmp_addflag=' $pic_flag -Mnomain' ;; 6832 ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 6833 tmp_addflag=' -i_dynamic' ;; 6834 efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 6835 tmp_addflag=' -i_dynamic -nofor_main' ;; 6836 ifc* | ifort*) # Intel Fortran compiler 6837 tmp_addflag=' -nofor_main' ;; 6838 lf95*) # Lahey Fortran 8.1 6839 _LT_TAGVAR(whole_archive_flag_spec, $1)= 6840 tmp_sharedflag='--shared' ;; 6841 xl[[cC]]* | bgxl[[cC]]* | mpixl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below) 6842 tmp_sharedflag='-qmkshrobj' 6843 tmp_addflag= ;; 6844 nvcc*) # Cuda Compiler Driver 2.2 6845 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' 6846 _LT_TAGVAR(compiler_needs_object, $1)=yes 6847 ;; 6848 esac 6849 case `$CC -V 2>&1 | sed 5q` in 6850 *Sun\ C*) # Sun C 5.9 6851 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' 6852 _LT_TAGVAR(compiler_needs_object, $1)=yes 6853 tmp_sharedflag='-G' ;; 6854 *Sun\ F*) # Sun Fortran 8.3 6855 tmp_sharedflag='-G' ;; 6856 esac 6857 _LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 6858 6859 if test "x$supports_anon_versioning" = xyes; then 6860 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ 6861 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ 6862 echo "local: *; };" >> $output_objdir/$libname.ver~ 6863 $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' 6864 fi 6865 6866 case $cc_basename in 6867 xlf* | bgf* | bgxlf* | mpixlf*) 6868 # IBM XL Fortran 10.1 on PPC cannot create shared libs itself 6869 _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive' 6870 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 6871 _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='-rpath $libdir' 6872 _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib' 6873 if test "x$supports_anon_versioning" = xyes; then 6874 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ 6875 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ 6876 echo "local: *; };" >> $output_objdir/$libname.ver~ 6877 $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' 6878 fi 6879 ;; 6880 esac 6881 else 6882 _LT_TAGVAR(ld_shlibs, $1)=no 6883 fi 6884 ;; 6885 6886 netbsd*) 6887 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then 6888 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' 6889 wlarc= 6890 else 6891 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 6892 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' 6893 fi 6894 ;; 6895 6896 solaris*) 6897 if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then 6898 _LT_TAGVAR(ld_shlibs, $1)=no 6899 cat <<_LT_EOF 1>&2 6900 6901*** Warning: The releases 2.8.* of the GNU linker cannot reliably 6902*** create shared libraries on Solaris systems. Therefore, libtool 6903*** is disabling shared libraries support. We urge you to upgrade GNU 6904*** binutils to release 2.9.1 or newer. Another option is to modify 6905*** your PATH or compiler configuration so that the native linker is 6906*** used, and then restart. 6907 6908_LT_EOF 6909 elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 6910 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 6911 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' 6912 else 6913 _LT_TAGVAR(ld_shlibs, $1)=no 6914 fi 6915 ;; 6916 6917 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) 6918 case `$LD -v 2>&1` in 6919 *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*) 6920 _LT_TAGVAR(ld_shlibs, $1)=no 6921 cat <<_LT_EOF 1>&2 6922 6923*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not 6924*** reliably create shared libraries on SCO systems. Therefore, libtool 6925*** is disabling shared libraries support. We urge you to upgrade GNU 6926*** binutils to release 2.16.91.0.3 or newer. Another option is to modify 6927*** your PATH or compiler configuration so that the native linker is 6928*** used, and then restart. 6929 6930_LT_EOF 6931 ;; 6932 *) 6933 # For security reasons, it is highly recommended that you always 6934 # use absolute paths for naming shared libraries, and exclude the 6935 # DT_RUNPATH tag from executables and libraries. But doing so 6936 # requires that you compile everything twice, which is a pain. 6937 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 6938 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 6939 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 6940 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' 6941 else 6942 _LT_TAGVAR(ld_shlibs, $1)=no 6943 fi 6944 ;; 6945 esac 6946 ;; 6947 6948 sunos4*) 6949 _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' 6950 wlarc= 6951 _LT_TAGVAR(hardcode_direct, $1)=yes 6952 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 6953 ;; 6954 6955 *) 6956 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 6957 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 6958 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' 6959 else 6960 _LT_TAGVAR(ld_shlibs, $1)=no 6961 fi 6962 ;; 6963 esac 6964 6965 if test "$_LT_TAGVAR(ld_shlibs, $1)" = no; then 6966 runpath_var= 6967 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 6968 _LT_TAGVAR(export_dynamic_flag_spec, $1)= 6969 _LT_TAGVAR(whole_archive_flag_spec, $1)= 6970 fi 6971 else 6972 # PORTME fill in a description of your system's linker (not GNU ld) 6973 case $host_os in 6974 aix3*) 6975 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 6976 _LT_TAGVAR(always_export_symbols, $1)=yes 6977 _LT_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' 6978 # Note: this linker hardcodes the directories in LIBPATH if there 6979 # are no directories specified by -L. 6980 _LT_TAGVAR(hardcode_minus_L, $1)=yes 6981 if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then 6982 # Neither direct hardcoding nor static linking is supported with a 6983 # broken collect2. 6984 _LT_TAGVAR(hardcode_direct, $1)=unsupported 6985 fi 6986 ;; 6987 6988 aix[[4-9]]*) 6989 if test "$host_cpu" = ia64; then 6990 # On IA64, the linker does run time linking by default, so we don't 6991 # have to do anything special. 6992 aix_use_runtimelinking=no 6993 exp_sym_flag='-Bexport' 6994 no_entry_flag="" 6995 else 6996 # If we're using GNU nm, then we don't want the "-C" option. 6997 # -C means demangle to AIX nm, but means don't demangle with GNU nm 6998 # Also, AIX nm treats weak defined symbols like other global 6999 # defined symbols, whereas GNU nm marks them as "W". 7000 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then 7001 _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' 7002 else 7003 _LT_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' 7004 fi 7005 aix_use_runtimelinking=no 7006 7007 # Test if we are trying to use run time linking or normal 7008 # AIX style linking. If -brtl is somewhere in LDFLAGS, we 7009 # need to do runtime linking. 7010 case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) 7011 for ld_flag in $LDFLAGS; do 7012 if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then 7013 aix_use_runtimelinking=yes 7014 break 7015 fi 7016 done 7017 ;; 7018 esac 7019 7020 exp_sym_flag='-bexport' 7021 no_entry_flag='-bnoentry' 7022 fi 7023 7024 # When large executables or shared objects are built, AIX ld can 7025 # have problems creating the table of contents. If linking a library 7026 # or program results in "error TOC overflow" add -mminimal-toc to 7027 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not 7028 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. 7029 7030 _LT_TAGVAR(archive_cmds, $1)='' 7031 _LT_TAGVAR(hardcode_direct, $1)=yes 7032 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 7033 _LT_TAGVAR(hardcode_libdir_separator, $1)=':' 7034 _LT_TAGVAR(link_all_deplibs, $1)=yes 7035 _LT_TAGVAR(file_list_spec, $1)='${wl}-f,' 7036 7037 if test "$GCC" = yes; then 7038 case $host_os in aix4.[[012]]|aix4.[[012]].*) 7039 # We only want to do this on AIX 4.2 and lower, the check 7040 # below for broken collect2 doesn't work under 4.3+ 7041 collect2name=`${CC} -print-prog-name=collect2` 7042 if test -f "$collect2name" && 7043 strings "$collect2name" | $GREP resolve_lib_name >/dev/null 7044 then 7045 # We have reworked collect2 7046 : 7047 else 7048 # We have old collect2 7049 _LT_TAGVAR(hardcode_direct, $1)=unsupported 7050 # It fails to find uninstalled libraries when the uninstalled 7051 # path is not listed in the libpath. Setting hardcode_minus_L 7052 # to unsupported forces relinking 7053 _LT_TAGVAR(hardcode_minus_L, $1)=yes 7054 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 7055 _LT_TAGVAR(hardcode_libdir_separator, $1)= 7056 fi 7057 ;; 7058 esac 7059 shared_flag='-shared' 7060 if test "$aix_use_runtimelinking" = yes; then 7061 shared_flag="$shared_flag "'${wl}-G' 7062 fi 7063 else 7064 # not using gcc 7065 if test "$host_cpu" = ia64; then 7066 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release 7067 # chokes on -Wl,-G. The following line is correct: 7068 shared_flag='-G' 7069 else 7070 if test "$aix_use_runtimelinking" = yes; then 7071 shared_flag='${wl}-G' 7072 else 7073 shared_flag='${wl}-bM:SRE' 7074 fi 7075 fi 7076 fi 7077 7078 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall' 7079 # It seems that -bexpall does not export symbols beginning with 7080 # underscore (_), so it is better to generate a list of symbols to export. 7081 _LT_TAGVAR(always_export_symbols, $1)=yes 7082 if test "$aix_use_runtimelinking" = yes; then 7083 # Warning - without using the other runtime loading flags (-brtl), 7084 # -berok will link without error, but may produce a broken library. 7085 _LT_TAGVAR(allow_undefined_flag, $1)='-berok' 7086 # Determine the default libpath from the value encoded in an 7087 # empty executable. 7088 _LT_SYS_MODULE_PATH_AIX 7089 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" 7090 _LT_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 func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" 7091 else 7092 if test "$host_cpu" = ia64; then 7093 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' 7094 _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" 7095 _LT_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" 7096 else 7097 # Determine the default libpath from the value encoded in an 7098 # empty executable. 7099 _LT_SYS_MODULE_PATH_AIX 7100 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" 7101 # Warning - without using the other run time loading flags, 7102 # -berok will link without error, but may produce a broken library. 7103 _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' 7104 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' 7105 if test "$with_gnu_ld" = yes; then 7106 # We only use this code for GNU lds that support --whole-archive. 7107 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' 7108 else 7109 # Exported symbols can be pulled into shared objects from archives 7110 _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' 7111 fi 7112 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes 7113 # This is similar to how AIX traditionally builds its shared libraries. 7114 _LT_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' 7115 fi 7116 fi 7117 ;; 7118 7119 amigaos*) 7120 case $host_cpu in 7121 powerpc) 7122 # see comment about AmigaOS4 .so support 7123 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 7124 _LT_TAGVAR(archive_expsym_cmds, $1)='' 7125 ;; 7126 m68k) 7127 _LT_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)' 7128 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 7129 _LT_TAGVAR(hardcode_minus_L, $1)=yes 7130 ;; 7131 esac 7132 ;; 7133 7134 bsdi[[45]]*) 7135 _LT_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic 7136 ;; 7137 7138 cygwin* | mingw* | pw32* | cegcc*) 7139 # When not using gcc, we currently assume that we are using 7140 # Microsoft Visual C++. 7141 # hardcode_libdir_flag_spec is actually meaningless, as there is 7142 # no search path for DLLs. 7143 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' 7144 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 7145 # Tell ltmain to make .lib files, not .a files. 7146 libext=lib 7147 # Tell ltmain to make .dll files, not .so files. 7148 shrext_cmds=".dll" 7149 # FIXME: Setting linknames here is a bad hack. 7150 _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames=' 7151 # The linker will automatically build a .lib file if we build a DLL. 7152 _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' 7153 # FIXME: Should let the user specify the lib program. 7154 _LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs' 7155 _LT_TAGVAR(fix_srcfile_path, $1)='`cygpath -w "$srcfile"`' 7156 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 7157 ;; 7158 7159 darwin* | rhapsody*) 7160 _LT_DARWIN_LINKER_FEATURES($1) 7161 ;; 7162 7163 dgux*) 7164 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 7165 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 7166 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7167 ;; 7168 7169 freebsd1*) 7170 _LT_TAGVAR(ld_shlibs, $1)=no 7171 ;; 7172 7173 # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor 7174 # support. Future versions do this automatically, but an explicit c++rt0.o 7175 # does not break anything, and helps significantly (at the cost of a little 7176 # extra space). 7177 freebsd2.2*) 7178 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' 7179 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 7180 _LT_TAGVAR(hardcode_direct, $1)=yes 7181 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7182 ;; 7183 7184 # Unfortunately, older versions of FreeBSD 2 do not have this feature. 7185 freebsd2*) 7186 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' 7187 _LT_TAGVAR(hardcode_direct, $1)=yes 7188 _LT_TAGVAR(hardcode_minus_L, $1)=yes 7189 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7190 ;; 7191 7192 # FreeBSD 3 and greater uses gcc -shared to do shared libraries. 7193 freebsd* | dragonfly*) 7194 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' 7195 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 7196 _LT_TAGVAR(hardcode_direct, $1)=yes 7197 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7198 ;; 7199 7200 hpux9*) 7201 if test "$GCC" = yes; then 7202 _LT_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' 7203 else 7204 _LT_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' 7205 fi 7206 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 7207 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 7208 _LT_TAGVAR(hardcode_direct, $1)=yes 7209 7210 # hardcode_minus_L: Not really in the search PATH, 7211 # but as the default location of the library. 7212 _LT_TAGVAR(hardcode_minus_L, $1)=yes 7213 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 7214 ;; 7215 7216 hpux10*) 7217 if test "$GCC" = yes && test "$with_gnu_ld" = no; then 7218 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' 7219 else 7220 _LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' 7221 fi 7222 if test "$with_gnu_ld" = no; then 7223 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 7224 _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir' 7225 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 7226 _LT_TAGVAR(hardcode_direct, $1)=yes 7227 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 7228 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 7229 # hardcode_minus_L: Not really in the search PATH, 7230 # but as the default location of the library. 7231 _LT_TAGVAR(hardcode_minus_L, $1)=yes 7232 fi 7233 ;; 7234 7235 hpux11*) 7236 if test "$GCC" = yes && test "$with_gnu_ld" = no; then 7237 case $host_cpu in 7238 hppa*64*) 7239 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' 7240 ;; 7241 ia64*) 7242 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' 7243 ;; 7244 *) 7245 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' 7246 ;; 7247 esac 7248 else 7249 case $host_cpu in 7250 hppa*64*) 7251 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' 7252 ;; 7253 ia64*) 7254 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' 7255 ;; 7256 *) 7257 m4_if($1, [], [ 7258 # Older versions of the 11.00 compiler do not understand -b yet 7259 # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does) 7260 _LT_LINKER_OPTION([if $CC understands -b], 7261 _LT_TAGVAR(lt_cv_prog_compiler__b, $1), [-b], 7262 [_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'], 7263 [_LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'])], 7264 [_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags']) 7265 ;; 7266 esac 7267 fi 7268 if test "$with_gnu_ld" = no; then 7269 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 7270 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 7271 7272 case $host_cpu in 7273 hppa*64*|ia64*) 7274 _LT_TAGVAR(hardcode_direct, $1)=no 7275 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7276 ;; 7277 *) 7278 _LT_TAGVAR(hardcode_direct, $1)=yes 7279 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 7280 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 7281 7282 # hardcode_minus_L: Not really in the search PATH, 7283 # but as the default location of the library. 7284 _LT_TAGVAR(hardcode_minus_L, $1)=yes 7285 ;; 7286 esac 7287 fi 7288 ;; 7289 7290 irix5* | irix6* | nonstopux*) 7291 if test "$GCC" = yes; then 7292 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' 7293 # Try to use the -exported_symbol ld option, if it does not 7294 # work, assume that -exports_file does not work either and 7295 # implicitly export all symbols. 7296 save_LDFLAGS="$LDFLAGS" 7297 LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null" 7298 AC_LINK_IFELSE(int foo(void) {}, 7299 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib' 7300 ) 7301 LDFLAGS="$save_LDFLAGS" 7302 else 7303 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' 7304 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib' 7305 fi 7306 _LT_TAGVAR(archive_cmds_need_lc, $1)='no' 7307 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 7308 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 7309 _LT_TAGVAR(inherit_rpath, $1)=yes 7310 _LT_TAGVAR(link_all_deplibs, $1)=yes 7311 ;; 7312 7313 netbsd*) 7314 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then 7315 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out 7316 else 7317 _LT_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF 7318 fi 7319 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 7320 _LT_TAGVAR(hardcode_direct, $1)=yes 7321 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7322 ;; 7323 7324 newsos6) 7325 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 7326 _LT_TAGVAR(hardcode_direct, $1)=yes 7327 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 7328 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 7329 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7330 ;; 7331 7332 *nto* | *qnx*) 7333 ;; 7334 7335 openbsd*) 7336 if test -f /usr/libexec/ld.so; then 7337 _LT_TAGVAR(hardcode_direct, $1)=yes 7338 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7339 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 7340 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then 7341 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' 7342 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' 7343 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 7344 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 7345 else 7346 case $host_os in 7347 openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*) 7348 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' 7349 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 7350 ;; 7351 *) 7352 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' 7353 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 7354 ;; 7355 esac 7356 fi 7357 else 7358 _LT_TAGVAR(ld_shlibs, $1)=no 7359 fi 7360 ;; 7361 7362 os2*) 7363 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 7364 _LT_TAGVAR(hardcode_minus_L, $1)=yes 7365 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 7366 _LT_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' 7367 _LT_TAGVAR(old_archive_from_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' 7368 ;; 7369 7370 osf3*) 7371 if test "$GCC" = yes; then 7372 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' 7373 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' 7374 else 7375 _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' 7376 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' 7377 fi 7378 _LT_TAGVAR(archive_cmds_need_lc, $1)='no' 7379 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 7380 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 7381 ;; 7382 7383 osf4* | osf5*) # as osf3* with the addition of -msym flag 7384 if test "$GCC" = yes; then 7385 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' 7386 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' 7387 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 7388 else 7389 _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' 7390 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' 7391 _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~ 7392 $CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp' 7393 7394 # Both c and cxx compiler support -rpath directly 7395 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' 7396 fi 7397 _LT_TAGVAR(archive_cmds_need_lc, $1)='no' 7398 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 7399 ;; 7400 7401 solaris*) 7402 _LT_TAGVAR(no_undefined_flag, $1)=' -z defs' 7403 if test "$GCC" = yes; then 7404 wlarc='${wl}' 7405 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' 7406 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 7407 $CC -shared ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' 7408 else 7409 case `$CC -V 2>&1` in 7410 *"Compilers 5.0"*) 7411 wlarc='' 7412 _LT_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' 7413 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 7414 $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' 7415 ;; 7416 *) 7417 wlarc='${wl}' 7418 _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags' 7419 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 7420 $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' 7421 ;; 7422 esac 7423 fi 7424 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 7425 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7426 case $host_os in 7427 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; 7428 *) 7429 # The compiler driver will combine and reorder linker options, 7430 # but understands `-z linker_flag'. GCC discards it without `$wl', 7431 # but is careful enough not to reorder. 7432 # Supported since Solaris 2.6 (maybe 2.5.1?) 7433 if test "$GCC" = yes; then 7434 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' 7435 else 7436 _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' 7437 fi 7438 ;; 7439 esac 7440 _LT_TAGVAR(link_all_deplibs, $1)=yes 7441 ;; 7442 7443 sunos4*) 7444 if test "x$host_vendor" = xsequent; then 7445 # Use $CC to link under sequent, because it throws in some extra .o 7446 # files that make .init and .fini sections work. 7447 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' 7448 else 7449 _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' 7450 fi 7451 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 7452 _LT_TAGVAR(hardcode_direct, $1)=yes 7453 _LT_TAGVAR(hardcode_minus_L, $1)=yes 7454 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7455 ;; 7456 7457 sysv4) 7458 case $host_vendor in 7459 sni) 7460 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 7461 _LT_TAGVAR(hardcode_direct, $1)=yes # is this really true??? 7462 ;; 7463 siemens) 7464 ## LD is ld it makes a PLAMLIB 7465 ## CC just makes a GrossModule. 7466 _LT_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags' 7467 _LT_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs' 7468 _LT_TAGVAR(hardcode_direct, $1)=no 7469 ;; 7470 motorola) 7471 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 7472 _LT_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie 7473 ;; 7474 esac 7475 runpath_var='LD_RUN_PATH' 7476 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7477 ;; 7478 7479 sysv4.3*) 7480 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 7481 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7482 _LT_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport' 7483 ;; 7484 7485 sysv4*MP*) 7486 if test -d /usr/nec; then 7487 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 7488 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7489 runpath_var=LD_RUN_PATH 7490 hardcode_runpath_var=yes 7491 _LT_TAGVAR(ld_shlibs, $1)=yes 7492 fi 7493 ;; 7494 7495 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) 7496 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' 7497 _LT_TAGVAR(archive_cmds_need_lc, $1)=no 7498 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7499 runpath_var='LD_RUN_PATH' 7500 7501 if test "$GCC" = yes; then 7502 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 7503 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 7504 else 7505 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 7506 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 7507 fi 7508 ;; 7509 7510 sysv5* | sco3.2v5* | sco5v6*) 7511 # Note: We can NOT use -z defs as we might desire, because we do not 7512 # link with -lc, and that would cause any symbols used from libc to 7513 # always be unresolved, which means just about no library would 7514 # ever link correctly. If we're not using GNU ld we use -z text 7515 # though, which does catch some bad symbols but isn't as heavy-handed 7516 # as -z defs. 7517 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' 7518 _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs' 7519 _LT_TAGVAR(archive_cmds_need_lc, $1)=no 7520 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7521 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir' 7522 _LT_TAGVAR(hardcode_libdir_separator, $1)=':' 7523 _LT_TAGVAR(link_all_deplibs, $1)=yes 7524 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' 7525 runpath_var='LD_RUN_PATH' 7526 7527 if test "$GCC" = yes; then 7528 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 7529 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 7530 else 7531 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 7532 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 7533 fi 7534 ;; 7535 7536 uts4*) 7537 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 7538 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 7539 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7540 ;; 7541 7542 *) 7543 _LT_TAGVAR(ld_shlibs, $1)=no 7544 ;; 7545 esac 7546 7547 if test x$host_vendor = xsni; then 7548 case $host in 7549 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) 7550 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Blargedynsym' 7551 ;; 7552 esac 7553 fi 7554 fi 7555]) 7556AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) 7557test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no 7558 7559_LT_TAGVAR(with_gnu_ld, $1)=$with_gnu_ld 7560 7561_LT_DECL([], [libext], [0], [Old archive suffix (normally "a")])dnl 7562_LT_DECL([], [shrext_cmds], [1], [Shared library suffix (normally ".so")])dnl 7563_LT_DECL([], [extract_expsyms_cmds], [2], 7564 [The commands to extract the exported symbol list from a shared archive]) 7565 7566# 7567# Do we need to explicitly link libc? 7568# 7569case "x$_LT_TAGVAR(archive_cmds_need_lc, $1)" in 7570x|xyes) 7571 # Assume -lc should be added 7572 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes 7573 7574 if test "$enable_shared" = yes && test "$GCC" = yes; then 7575 case $_LT_TAGVAR(archive_cmds, $1) in 7576 *'~'*) 7577 # FIXME: we may have to deal with multi-command sequences. 7578 ;; 7579 '$CC '*) 7580 # Test whether the compiler implicitly links with -lc since on some 7581 # systems, -lgcc has to come before -lc. If gcc already passes -lc 7582 # to ld, don't add -lc before -lgcc. 7583 AC_CACHE_CHECK([whether -lc should be explicitly linked in], 7584 [lt_cv_]_LT_TAGVAR(archive_cmds_need_lc, $1), 7585 [$RM conftest* 7586 echo "$lt_simple_compile_test_code" > conftest.$ac_ext 7587 7588 if AC_TRY_EVAL(ac_compile) 2>conftest.err; then 7589 soname=conftest 7590 lib=conftest 7591 libobjs=conftest.$ac_objext 7592 deplibs= 7593 wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) 7594 pic_flag=$_LT_TAGVAR(lt_prog_compiler_pic, $1) 7595 compiler_flags=-v 7596 linker_flags=-v 7597 verstring= 7598 output_objdir=. 7599 libname=conftest 7600 lt_save_allow_undefined_flag=$_LT_TAGVAR(allow_undefined_flag, $1) 7601 _LT_TAGVAR(allow_undefined_flag, $1)= 7602 if AC_TRY_EVAL(_LT_TAGVAR(archive_cmds, $1) 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 7603 then 7604 lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=no 7605 else 7606 lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=yes 7607 fi 7608 _LT_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag 7609 else 7610 cat conftest.err 1>&5 7611 fi 7612 $RM conftest* 7613 ]) 7614 _LT_TAGVAR(archive_cmds_need_lc, $1)=$lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1) 7615 ;; 7616 esac 7617 fi 7618 ;; 7619esac 7620 7621_LT_TAGDECL([build_libtool_need_lc], [archive_cmds_need_lc], [0], 7622 [Whether or not to add -lc for building shared libraries]) 7623_LT_TAGDECL([allow_libtool_libs_with_static_runtimes], 7624 [enable_shared_with_static_runtimes], [0], 7625 [Whether or not to disallow shared libs when runtime libs are static]) 7626_LT_TAGDECL([], [export_dynamic_flag_spec], [1], 7627 [Compiler flag to allow reflexive dlopens]) 7628_LT_TAGDECL([], [whole_archive_flag_spec], [1], 7629 [Compiler flag to generate shared objects directly from archives]) 7630_LT_TAGDECL([], [compiler_needs_object], [1], 7631 [Whether the compiler copes with passing no objects directly]) 7632_LT_TAGDECL([], [old_archive_from_new_cmds], [2], 7633 [Create an old-style archive from a shared archive]) 7634_LT_TAGDECL([], [old_archive_from_expsyms_cmds], [2], 7635 [Create a temporary old-style archive to link instead of a shared archive]) 7636_LT_TAGDECL([], [archive_cmds], [2], [Commands used to build a shared archive]) 7637_LT_TAGDECL([], [archive_expsym_cmds], [2]) 7638_LT_TAGDECL([], [module_cmds], [2], 7639 [Commands used to build a loadable module if different from building 7640 a shared archive.]) 7641_LT_TAGDECL([], [module_expsym_cmds], [2]) 7642_LT_TAGDECL([], [with_gnu_ld], [1], 7643 [Whether we are building with GNU ld or not]) 7644_LT_TAGDECL([], [allow_undefined_flag], [1], 7645 [Flag that allows shared libraries with undefined symbols to be built]) 7646_LT_TAGDECL([], [no_undefined_flag], [1], 7647 [Flag that enforces no undefined symbols]) 7648_LT_TAGDECL([], [hardcode_libdir_flag_spec], [1], 7649 [Flag to hardcode $libdir into a binary during linking. 7650 This must work even if $libdir does not exist]) 7651_LT_TAGDECL([], [hardcode_libdir_flag_spec_ld], [1], 7652 [[If ld is used when linking, flag to hardcode $libdir into a binary 7653 during linking. This must work even if $libdir does not exist]]) 7654_LT_TAGDECL([], [hardcode_libdir_separator], [1], 7655 [Whether we need a single "-rpath" flag with a separated argument]) 7656_LT_TAGDECL([], [hardcode_direct], [0], 7657 [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes 7658 DIR into the resulting binary]) 7659_LT_TAGDECL([], [hardcode_direct_absolute], [0], 7660 [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes 7661 DIR into the resulting binary and the resulting library dependency is 7662 "absolute", i.e impossible to change by setting ${shlibpath_var} if the 7663 library is relocated]) 7664_LT_TAGDECL([], [hardcode_minus_L], [0], 7665 [Set to "yes" if using the -LDIR flag during linking hardcodes DIR 7666 into the resulting binary]) 7667_LT_TAGDECL([], [hardcode_shlibpath_var], [0], 7668 [Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR 7669 into the resulting binary]) 7670_LT_TAGDECL([], [hardcode_automatic], [0], 7671 [Set to "yes" if building a shared library automatically hardcodes DIR 7672 into the library and all subsequent libraries and executables linked 7673 against it]) 7674_LT_TAGDECL([], [inherit_rpath], [0], 7675 [Set to yes if linker adds runtime paths of dependent libraries 7676 to runtime path list]) 7677_LT_TAGDECL([], [link_all_deplibs], [0], 7678 [Whether libtool must link a program against all its dependency libraries]) 7679_LT_TAGDECL([], [fix_srcfile_path], [1], 7680 [Fix the shell variable $srcfile for the compiler]) 7681_LT_TAGDECL([], [always_export_symbols], [0], 7682 [Set to "yes" if exported symbols are required]) 7683_LT_TAGDECL([], [export_symbols_cmds], [2], 7684 [The commands to list exported symbols]) 7685_LT_TAGDECL([], [exclude_expsyms], [1], 7686 [Symbols that should not be listed in the preloaded symbols]) 7687_LT_TAGDECL([], [include_expsyms], [1], 7688 [Symbols that must always be exported]) 7689_LT_TAGDECL([], [prelink_cmds], [2], 7690 [Commands necessary for linking programs (against libraries) with templates]) 7691_LT_TAGDECL([], [file_list_spec], [1], 7692 [Specify filename containing input files]) 7693dnl FIXME: Not yet implemented 7694dnl _LT_TAGDECL([], [thread_safe_flag_spec], [1], 7695dnl [Compiler flag to generate thread safe objects]) 7696])# _LT_LINKER_SHLIBS 7697 7698 7699# _LT_LANG_C_CONFIG([TAG]) 7700# ------------------------ 7701# Ensure that the configuration variables for a C compiler are suitably 7702# defined. These variables are subsequently used by _LT_CONFIG to write 7703# the compiler configuration to `libtool'. 7704m4_defun([_LT_LANG_C_CONFIG], 7705[m4_require([_LT_DECL_EGREP])dnl 7706lt_save_CC="$CC" 7707AC_LANG_PUSH(C) 7708 7709# Source file extension for C test sources. 7710ac_ext=c 7711 7712# Object file extension for compiled C test sources. 7713objext=o 7714_LT_TAGVAR(objext, $1)=$objext 7715 7716# Code to be used in simple compile tests 7717lt_simple_compile_test_code="int some_variable = 0;" 7718 7719# Code to be used in simple link tests 7720lt_simple_link_test_code='int main(){return(0);}' 7721 7722_LT_TAG_COMPILER 7723# Save the default compiler, since it gets overwritten when the other 7724# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP. 7725compiler_DEFAULT=$CC 7726 7727# save warnings/boilerplate of simple test code 7728_LT_COMPILER_BOILERPLATE 7729_LT_LINKER_BOILERPLATE 7730 7731if test -n "$compiler"; then 7732 _LT_COMPILER_NO_RTTI($1) 7733 _LT_COMPILER_PIC($1) 7734 _LT_COMPILER_C_O($1) 7735 _LT_COMPILER_FILE_LOCKS($1) 7736 _LT_LINKER_SHLIBS($1) 7737 _LT_SYS_DYNAMIC_LINKER($1) 7738 _LT_LINKER_HARDCODE_LIBPATH($1) 7739 LT_SYS_DLOPEN_SELF 7740 _LT_CMD_STRIPLIB 7741 7742 # Report which library types will actually be built 7743 AC_MSG_CHECKING([if libtool supports shared libraries]) 7744 AC_MSG_RESULT([$can_build_shared]) 7745 7746 AC_MSG_CHECKING([whether to build shared libraries]) 7747 test "$can_build_shared" = "no" && enable_shared=no 7748 7749 # On AIX, shared libraries and static libraries use the same namespace, and 7750 # are all built from PIC. 7751 case $host_os in 7752 aix3*) 7753 test "$enable_shared" = yes && enable_static=no 7754 if test -n "$RANLIB"; then 7755 archive_cmds="$archive_cmds~\$RANLIB \$lib" 7756 postinstall_cmds='$RANLIB $lib' 7757 fi 7758 ;; 7759 7760 aix[[4-9]]*) 7761 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then 7762 test "$enable_shared" = yes && enable_static=no 7763 fi 7764 ;; 7765 esac 7766 AC_MSG_RESULT([$enable_shared]) 7767 7768 AC_MSG_CHECKING([whether to build static libraries]) 7769 # Make sure either enable_shared or enable_static is yes. 7770 test "$enable_shared" = yes || enable_static=yes 7771 AC_MSG_RESULT([$enable_static]) 7772 7773 _LT_CONFIG($1) 7774fi 7775AC_LANG_POP 7776CC="$lt_save_CC" 7777])# _LT_LANG_C_CONFIG 7778 7779 7780# _LT_LANG_CXX_CONFIG([TAG]) 7781# -------------------------- 7782# Ensure that the configuration variables for a C++ compiler are suitably 7783# defined. These variables are subsequently used by _LT_CONFIG to write 7784# the compiler configuration to `libtool'. 7785m4_defun([_LT_LANG_CXX_CONFIG], 7786[m4_require([_LT_FILEUTILS_DEFAULTS])dnl 7787m4_require([_LT_DECL_EGREP])dnl 7788if test -n "$CXX" && ( test "X$CXX" != "Xno" && 7789 ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || 7790 (test "X$CXX" != "Xg++"))) ; then 7791 AC_PROG_CXXCPP 7792else 7793 _lt_caught_CXX_error=yes 7794fi 7795 7796AC_LANG_PUSH(C++) 7797_LT_TAGVAR(archive_cmds_need_lc, $1)=no 7798_LT_TAGVAR(allow_undefined_flag, $1)= 7799_LT_TAGVAR(always_export_symbols, $1)=no 7800_LT_TAGVAR(archive_expsym_cmds, $1)= 7801_LT_TAGVAR(compiler_needs_object, $1)=no 7802_LT_TAGVAR(export_dynamic_flag_spec, $1)= 7803_LT_TAGVAR(hardcode_direct, $1)=no 7804_LT_TAGVAR(hardcode_direct_absolute, $1)=no 7805_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 7806_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= 7807_LT_TAGVAR(hardcode_libdir_separator, $1)= 7808_LT_TAGVAR(hardcode_minus_L, $1)=no 7809_LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported 7810_LT_TAGVAR(hardcode_automatic, $1)=no 7811_LT_TAGVAR(inherit_rpath, $1)=no 7812_LT_TAGVAR(module_cmds, $1)= 7813_LT_TAGVAR(module_expsym_cmds, $1)= 7814_LT_TAGVAR(link_all_deplibs, $1)=unknown 7815_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 7816_LT_TAGVAR(reload_flag, $1)=$reload_flag 7817_LT_TAGVAR(reload_cmds, $1)=$reload_cmds 7818_LT_TAGVAR(no_undefined_flag, $1)= 7819_LT_TAGVAR(whole_archive_flag_spec, $1)= 7820_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no 7821 7822# Source file extension for C++ test sources. 7823ac_ext=cpp 7824 7825# Object file extension for compiled C++ test sources. 7826objext=o 7827_LT_TAGVAR(objext, $1)=$objext 7828 7829# No sense in running all these tests if we already determined that 7830# the CXX compiler isn't working. Some variables (like enable_shared) 7831# are currently assumed to apply to all compilers on this platform, 7832# and will be corrupted by setting them based on a non-working compiler. 7833if test "$_lt_caught_CXX_error" != yes; then 7834 # Code to be used in simple compile tests 7835 lt_simple_compile_test_code="int some_variable = 0;" 7836 7837 # Code to be used in simple link tests 7838 lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }' 7839 7840 # ltmain only uses $CC for tagged configurations so make sure $CC is set. 7841 _LT_TAG_COMPILER 7842 7843 # save warnings/boilerplate of simple test code 7844 _LT_COMPILER_BOILERPLATE 7845 _LT_LINKER_BOILERPLATE 7846 7847 # Allow CC to be a program name with arguments. 7848 lt_save_CC=$CC 7849 lt_save_LD=$LD 7850 lt_save_GCC=$GCC 7851 GCC=$GXX 7852 lt_save_with_gnu_ld=$with_gnu_ld 7853 lt_save_path_LD=$lt_cv_path_LD 7854 if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then 7855 lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx 7856 else 7857 $as_unset lt_cv_prog_gnu_ld 7858 fi 7859 if test -n "${lt_cv_path_LDCXX+set}"; then 7860 lt_cv_path_LD=$lt_cv_path_LDCXX 7861 else 7862 $as_unset lt_cv_path_LD 7863 fi 7864 test -z "${LDCXX+set}" || LD=$LDCXX 7865 CC=${CXX-"c++"} 7866 compiler=$CC 7867 _LT_TAGVAR(compiler, $1)=$CC 7868 _LT_CC_BASENAME([$compiler]) 7869 7870 if test -n "$compiler"; then 7871 # We don't want -fno-exception when compiling C++ code, so set the 7872 # no_builtin_flag separately 7873 if test "$GXX" = yes; then 7874 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' 7875 else 7876 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= 7877 fi 7878 7879 if test "$GXX" = yes; then 7880 # Set up default GNU C++ configuration 7881 7882 LT_PATH_LD 7883 7884 # Check if GNU C++ uses GNU ld as the underlying linker, since the 7885 # archiving commands below assume that GNU ld is being used. 7886 if test "$with_gnu_ld" = yes; then 7887 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' 7888 _LT_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' 7889 7890 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 7891 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 7892 7893 # If archive_cmds runs LD, not CC, wlarc should be empty 7894 # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to 7895 # investigate it a little bit more. (MM) 7896 wlarc='${wl}' 7897 7898 # ancient GNU ld didn't support --whole-archive et. al. 7899 if eval "`$CC -print-prog-name=ld` --help 2>&1" | 7900 $GREP 'no-whole-archive' > /dev/null; then 7901 _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' 7902 else 7903 _LT_TAGVAR(whole_archive_flag_spec, $1)= 7904 fi 7905 else 7906 with_gnu_ld=no 7907 wlarc= 7908 7909 # A generic and very simple default shared library creation 7910 # command for GNU C++ for the case where it uses the native 7911 # linker, instead of GNU ld. If possible, this setting should 7912 # overridden to take advantage of the native linker features on 7913 # the platform it is being used on. 7914 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' 7915 fi 7916 7917 # Commands to make compiler produce verbose output that lists 7918 # what "hidden" libraries, object files and flags are used when 7919 # linking a shared library. 7920 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' 7921 7922 else 7923 GXX=no 7924 with_gnu_ld=no 7925 wlarc= 7926 fi 7927 7928 # PORTME: fill in a description of your system's C++ link characteristics 7929 AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) 7930 _LT_TAGVAR(ld_shlibs, $1)=yes 7931 case $host_os in 7932 aix3*) 7933 # FIXME: insert proper C++ library support 7934 _LT_TAGVAR(ld_shlibs, $1)=no 7935 ;; 7936 aix[[4-9]]*) 7937 if test "$host_cpu" = ia64; then 7938 # On IA64, the linker does run time linking by default, so we don't 7939 # have to do anything special. 7940 aix_use_runtimelinking=no 7941 exp_sym_flag='-Bexport' 7942 no_entry_flag="" 7943 else 7944 aix_use_runtimelinking=no 7945 7946 # Test if we are trying to use run time linking or normal 7947 # AIX style linking. If -brtl is somewhere in LDFLAGS, we 7948 # need to do runtime linking. 7949 case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) 7950 for ld_flag in $LDFLAGS; do 7951 case $ld_flag in 7952 *-brtl*) 7953 aix_use_runtimelinking=yes 7954 break 7955 ;; 7956 esac 7957 done 7958 ;; 7959 esac 7960 7961 exp_sym_flag='-bexport' 7962 no_entry_flag='-bnoentry' 7963 fi 7964 7965 # When large executables or shared objects are built, AIX ld can 7966 # have problems creating the table of contents. If linking a library 7967 # or program results in "error TOC overflow" add -mminimal-toc to 7968 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not 7969 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. 7970 7971 _LT_TAGVAR(archive_cmds, $1)='' 7972 _LT_TAGVAR(hardcode_direct, $1)=yes 7973 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 7974 _LT_TAGVAR(hardcode_libdir_separator, $1)=':' 7975 _LT_TAGVAR(link_all_deplibs, $1)=yes 7976 _LT_TAGVAR(file_list_spec, $1)='${wl}-f,' 7977 7978 if test "$GXX" = yes; then 7979 case $host_os in aix4.[[012]]|aix4.[[012]].*) 7980 # We only want to do this on AIX 4.2 and lower, the check 7981 # below for broken collect2 doesn't work under 4.3+ 7982 collect2name=`${CC} -print-prog-name=collect2` 7983 if test -f "$collect2name" && 7984 strings "$collect2name" | $GREP resolve_lib_name >/dev/null 7985 then 7986 # We have reworked collect2 7987 : 7988 else 7989 # We have old collect2 7990 _LT_TAGVAR(hardcode_direct, $1)=unsupported 7991 # It fails to find uninstalled libraries when the uninstalled 7992 # path is not listed in the libpath. Setting hardcode_minus_L 7993 # to unsupported forces relinking 7994 _LT_TAGVAR(hardcode_minus_L, $1)=yes 7995 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 7996 _LT_TAGVAR(hardcode_libdir_separator, $1)= 7997 fi 7998 esac 7999 shared_flag='-shared' 8000 if test "$aix_use_runtimelinking" = yes; then 8001 shared_flag="$shared_flag "'${wl}-G' 8002 fi 8003 else 8004 # not using gcc 8005 if test "$host_cpu" = ia64; then 8006 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release 8007 # chokes on -Wl,-G. The following line is correct: 8008 shared_flag='-G' 8009 else 8010 if test "$aix_use_runtimelinking" = yes; then 8011 shared_flag='${wl}-G' 8012 else 8013 shared_flag='${wl}-bM:SRE' 8014 fi 8015 fi 8016 fi 8017 8018 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall' 8019 # It seems that -bexpall does not export symbols beginning with 8020 # underscore (_), so it is better to generate a list of symbols to 8021 # export. 8022 _LT_TAGVAR(always_export_symbols, $1)=yes 8023 if test "$aix_use_runtimelinking" = yes; then 8024 # Warning - without using the other runtime loading flags (-brtl), 8025 # -berok will link without error, but may produce a broken library. 8026 _LT_TAGVAR(allow_undefined_flag, $1)='-berok' 8027 # Determine the default libpath from the value encoded in an empty 8028 # executable. 8029 _LT_SYS_MODULE_PATH_AIX 8030 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" 8031 8032 _LT_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 func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" 8033 else 8034 if test "$host_cpu" = ia64; then 8035 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' 8036 _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" 8037 _LT_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" 8038 else 8039 # Determine the default libpath from the value encoded in an 8040 # empty executable. 8041 _LT_SYS_MODULE_PATH_AIX 8042 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" 8043 # Warning - without using the other run time loading flags, 8044 # -berok will link without error, but may produce a broken library. 8045 _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' 8046 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' 8047 if test "$with_gnu_ld" = yes; then 8048 # We only use this code for GNU lds that support --whole-archive. 8049 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' 8050 else 8051 # Exported symbols can be pulled into shared objects from archives 8052 _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' 8053 fi 8054 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes 8055 # This is similar to how AIX traditionally builds its shared 8056 # libraries. 8057 _LT_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' 8058 fi 8059 fi 8060 ;; 8061 8062 beos*) 8063 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 8064 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 8065 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc 8066 # support --undefined. This deserves some investigation. FIXME 8067 _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 8068 else 8069 _LT_TAGVAR(ld_shlibs, $1)=no 8070 fi 8071 ;; 8072 8073 chorus*) 8074 case $cc_basename in 8075 *) 8076 # FIXME: insert proper C++ library support 8077 _LT_TAGVAR(ld_shlibs, $1)=no 8078 ;; 8079 esac 8080 ;; 8081 8082 cygwin* | mingw* | pw32* | cegcc*) 8083 # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, 8084 # as there is no search path for DLLs. 8085 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 8086 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols' 8087 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 8088 _LT_TAGVAR(always_export_symbols, $1)=no 8089 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 8090 8091 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then 8092 _LT_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' 8093 # If the export-symbols file already is a .def file (1st line 8094 # is EXPORTS), use it as is; otherwise, prepend... 8095 _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then 8096 cp $export_symbols $output_objdir/$soname.def; 8097 else 8098 echo EXPORTS > $output_objdir/$soname.def; 8099 cat $export_symbols >> $output_objdir/$soname.def; 8100 fi~ 8101 $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' 8102 else 8103 _LT_TAGVAR(ld_shlibs, $1)=no 8104 fi 8105 ;; 8106 darwin* | rhapsody*) 8107 _LT_DARWIN_LINKER_FEATURES($1) 8108 ;; 8109 8110 dgux*) 8111 case $cc_basename in 8112 ec++*) 8113 # FIXME: insert proper C++ library support 8114 _LT_TAGVAR(ld_shlibs, $1)=no 8115 ;; 8116 ghcx*) 8117 # Green Hills C++ Compiler 8118 # FIXME: insert proper C++ library support 8119 _LT_TAGVAR(ld_shlibs, $1)=no 8120 ;; 8121 *) 8122 # FIXME: insert proper C++ library support 8123 _LT_TAGVAR(ld_shlibs, $1)=no 8124 ;; 8125 esac 8126 ;; 8127 8128 freebsd[[12]]*) 8129 # C++ shared libraries reported to be fairly broken before 8130 # switch to ELF 8131 _LT_TAGVAR(ld_shlibs, $1)=no 8132 ;; 8133 8134 freebsd-elf*) 8135 _LT_TAGVAR(archive_cmds_need_lc, $1)=no 8136 ;; 8137 8138 freebsd* | dragonfly*) 8139 # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF 8140 # conventions 8141 _LT_TAGVAR(ld_shlibs, $1)=yes 8142 ;; 8143 8144 gnu*) 8145 ;; 8146 8147 haiku*) 8148 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 8149 _LT_TAGVAR(link_all_deplibs, $1)=yes 8150 ;; 8151 8152 hpux9*) 8153 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 8154 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 8155 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 8156 _LT_TAGVAR(hardcode_direct, $1)=yes 8157 _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, 8158 # but as the default 8159 # location of the library. 8160 8161 case $cc_basename in 8162 CC*) 8163 # FIXME: insert proper C++ library support 8164 _LT_TAGVAR(ld_shlibs, $1)=no 8165 ;; 8166 aCC*) 8167 _LT_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' 8168 # Commands to make compiler produce verbose output that lists 8169 # what "hidden" libraries, object files and flags are used when 8170 # linking a shared library. 8171 # 8172 # There doesn't appear to be a way to prevent this compiler from 8173 # explicitly linking system object files so we need to strip them 8174 # from the output so that they don't get included in the library 8175 # dependencies. 8176 output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' 8177 ;; 8178 *) 8179 if test "$GXX" = yes; then 8180 _LT_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' 8181 else 8182 # FIXME: insert proper C++ library support 8183 _LT_TAGVAR(ld_shlibs, $1)=no 8184 fi 8185 ;; 8186 esac 8187 ;; 8188 8189 hpux10*|hpux11*) 8190 if test $with_gnu_ld = no; then 8191 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 8192 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 8193 8194 case $host_cpu in 8195 hppa*64*|ia64*) 8196 ;; 8197 *) 8198 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 8199 ;; 8200 esac 8201 fi 8202 case $host_cpu in 8203 hppa*64*|ia64*) 8204 _LT_TAGVAR(hardcode_direct, $1)=no 8205 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 8206 ;; 8207 *) 8208 _LT_TAGVAR(hardcode_direct, $1)=yes 8209 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 8210 _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, 8211 # but as the default 8212 # location of the library. 8213 ;; 8214 esac 8215 8216 case $cc_basename in 8217 CC*) 8218 # FIXME: insert proper C++ library support 8219 _LT_TAGVAR(ld_shlibs, $1)=no 8220 ;; 8221 aCC*) 8222 case $host_cpu in 8223 hppa*64*) 8224 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 8225 ;; 8226 ia64*) 8227 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 8228 ;; 8229 *) 8230 _LT_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' 8231 ;; 8232 esac 8233 # Commands to make compiler produce verbose output that lists 8234 # what "hidden" libraries, object files and flags are used when 8235 # linking a shared library. 8236 # 8237 # There doesn't appear to be a way to prevent this compiler from 8238 # explicitly linking system object files so we need to strip them 8239 # from the output so that they don't get included in the library 8240 # dependencies. 8241 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; func_echo_all "$list"' 8242 ;; 8243 *) 8244 if test "$GXX" = yes; then 8245 if test $with_gnu_ld = no; then 8246 case $host_cpu in 8247 hppa*64*) 8248 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 8249 ;; 8250 ia64*) 8251 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 8252 ;; 8253 *) 8254 _LT_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' 8255 ;; 8256 esac 8257 fi 8258 else 8259 # FIXME: insert proper C++ library support 8260 _LT_TAGVAR(ld_shlibs, $1)=no 8261 fi 8262 ;; 8263 esac 8264 ;; 8265 8266 interix[[3-9]]*) 8267 _LT_TAGVAR(hardcode_direct, $1)=no 8268 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 8269 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 8270 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 8271 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. 8272 # Instead, shared libraries are loaded at an image base (0x10000000 by 8273 # default) and relocated if they conflict, which is a slow very memory 8274 # consuming and fragmenting process. To avoid this, we pick a random, 8275 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link 8276 # time. Moving up from 0x10000000 also allows more sbrk(2) space. 8277 _LT_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' 8278 _LT_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' 8279 ;; 8280 irix5* | irix6*) 8281 case $cc_basename in 8282 CC*) 8283 # SGI C++ 8284 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' 8285 8286 # Archives containing C++ object files must be created using 8287 # "CC -ar", where "CC" is the IRIX C++ compiler. This is 8288 # necessary to make sure instantiated templates are included 8289 # in the archive. 8290 _LT_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs' 8291 ;; 8292 *) 8293 if test "$GXX" = yes; then 8294 if test "$with_gnu_ld" = no; then 8295 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' 8296 else 8297 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` -o $lib' 8298 fi 8299 fi 8300 _LT_TAGVAR(link_all_deplibs, $1)=yes 8301 ;; 8302 esac 8303 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 8304 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 8305 _LT_TAGVAR(inherit_rpath, $1)=yes 8306 ;; 8307 8308 linux* | k*bsd*-gnu | kopensolaris*-gnu) 8309 case $cc_basename in 8310 KCC*) 8311 # Kuck and Associates, Inc. (KAI) C++ Compiler 8312 8313 # KCC will only create a shared library if the output file 8314 # ends with ".so" (or ".sl" for HP-UX), so rename the library 8315 # to its proper name (with version) after linking. 8316 _LT_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' 8317 _LT_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' 8318 # Commands to make compiler produce verbose output that lists 8319 # what "hidden" libraries, object files and flags are used when 8320 # linking a shared library. 8321 # 8322 # There doesn't appear to be a way to prevent this compiler from 8323 # explicitly linking system object files so we need to strip them 8324 # from the output so that they don't get included in the library 8325 # dependencies. 8326 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; func_echo_all "$list"' 8327 8328 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 8329 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 8330 8331 # Archives containing C++ object files must be created using 8332 # "CC -Bstatic", where "CC" is the KAI C++ compiler. 8333 _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' 8334 ;; 8335 icpc* | ecpc* ) 8336 # Intel C++ 8337 with_gnu_ld=yes 8338 # version 8.0 and above of icpc choke on multiply defined symbols 8339 # if we add $predep_objects and $postdep_objects, however 7.1 and 8340 # earlier do not add the objects themselves. 8341 case `$CC -V 2>&1` in 8342 *"Version 7."*) 8343 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' 8344 _LT_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' 8345 ;; 8346 *) # Version 8.0 or newer 8347 tmp_idyn= 8348 case $host_cpu in 8349 ia64*) tmp_idyn=' -i_dynamic';; 8350 esac 8351 _LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 8352 _LT_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' 8353 ;; 8354 esac 8355 _LT_TAGVAR(archive_cmds_need_lc, $1)=no 8356 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 8357 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 8358 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' 8359 ;; 8360 pgCC* | pgcpp*) 8361 # Portland Group C++ compiler 8362 case `$CC -V` in 8363 *pgCC\ [[1-5]].* | *pgcpp\ [[1-5]].*) 8364 _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~ 8365 rm -rf $tpldir~ 8366 $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~ 8367 compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"' 8368 _LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~ 8369 rm -rf $tpldir~ 8370 $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~ 8371 $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~ 8372 $RANLIB $oldlib' 8373 _LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~ 8374 rm -rf $tpldir~ 8375 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ 8376 $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' 8377 _LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~ 8378 rm -rf $tpldir~ 8379 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ 8380 $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib' 8381 ;; 8382 *) # Version 6 and above use weak symbols 8383 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' 8384 _LT_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' 8385 ;; 8386 esac 8387 8388 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir' 8389 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 8390 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' 8391 ;; 8392 cxx*) 8393 # Compaq C++ 8394 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' 8395 _LT_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' 8396 8397 runpath_var=LD_RUN_PATH 8398 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' 8399 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 8400 8401 # Commands to make compiler produce verbose output that lists 8402 # what "hidden" libraries, object files and flags are used when 8403 # linking a shared library. 8404 # 8405 # There doesn't appear to be a way to prevent this compiler from 8406 # explicitly linking system object files so we need to strip them 8407 # from the output so that they don't get included in the library 8408 # dependencies. 8409 output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$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; func_echo_all "X$list" | $Xsed' 8410 ;; 8411 xl* | mpixl* | bgxl*) 8412 # IBM XL 8.0 on PPC, with GNU ld 8413 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 8414 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 8415 _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 8416 if test "x$supports_anon_versioning" = xyes; then 8417 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ 8418 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ 8419 echo "local: *; };" >> $output_objdir/$libname.ver~ 8420 $CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' 8421 fi 8422 ;; 8423 *) 8424 case `$CC -V 2>&1 | sed 5q` in 8425 *Sun\ C*) 8426 # Sun C++ 5.9 8427 _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' 8428 _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 8429 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols' 8430 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 8431 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' 8432 _LT_TAGVAR(compiler_needs_object, $1)=yes 8433 8434 # Not sure whether something based on 8435 # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 8436 # would be better. 8437 output_verbose_link_cmd='func_echo_all' 8438 8439 # Archives containing C++ object files must be created using 8440 # "CC -xar", where "CC" is the Sun C++ compiler. This is 8441 # necessary to make sure instantiated templates are included 8442 # in the archive. 8443 _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' 8444 ;; 8445 esac 8446 ;; 8447 esac 8448 ;; 8449 8450 lynxos*) 8451 # FIXME: insert proper C++ library support 8452 _LT_TAGVAR(ld_shlibs, $1)=no 8453 ;; 8454 8455 m88k*) 8456 # FIXME: insert proper C++ library support 8457 _LT_TAGVAR(ld_shlibs, $1)=no 8458 ;; 8459 8460 mvs*) 8461 case $cc_basename in 8462 cxx*) 8463 # FIXME: insert proper C++ library support 8464 _LT_TAGVAR(ld_shlibs, $1)=no 8465 ;; 8466 *) 8467 # FIXME: insert proper C++ library support 8468 _LT_TAGVAR(ld_shlibs, $1)=no 8469 ;; 8470 esac 8471 ;; 8472 8473 netbsd*) 8474 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then 8475 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' 8476 wlarc= 8477 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 8478 _LT_TAGVAR(hardcode_direct, $1)=yes 8479 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 8480 fi 8481 # Workaround some broken pre-1.5 toolchains 8482 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' 8483 ;; 8484 8485 *nto* | *qnx*) 8486 _LT_TAGVAR(ld_shlibs, $1)=yes 8487 ;; 8488 8489 openbsd2*) 8490 # C++ shared libraries are fairly broken 8491 _LT_TAGVAR(ld_shlibs, $1)=no 8492 ;; 8493 8494 openbsd*) 8495 if test -f /usr/libexec/ld.so; then 8496 _LT_TAGVAR(hardcode_direct, $1)=yes 8497 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 8498 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 8499 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' 8500 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 8501 if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then 8502 _LT_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' 8503 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 8504 _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' 8505 fi 8506 output_verbose_link_cmd=func_echo_all 8507 else 8508 _LT_TAGVAR(ld_shlibs, $1)=no 8509 fi 8510 ;; 8511 8512 osf3* | osf4* | osf5*) 8513 case $cc_basename in 8514 KCC*) 8515 # Kuck and Associates, Inc. (KAI) C++ Compiler 8516 8517 # KCC will only create a shared library if the output file 8518 # ends with ".so" (or ".sl" for HP-UX), so rename the library 8519 # to its proper name (with version) after linking. 8520 _LT_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' 8521 8522 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 8523 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 8524 8525 # Archives containing C++ object files must be created using 8526 # the KAI C++ compiler. 8527 case $host in 8528 osf3*) _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;; 8529 *) _LT_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' ;; 8530 esac 8531 ;; 8532 RCC*) 8533 # Rational C++ 2.4.1 8534 # FIXME: insert proper C++ library support 8535 _LT_TAGVAR(ld_shlibs, $1)=no 8536 ;; 8537 cxx*) 8538 case $host in 8539 osf3*) 8540 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' 8541 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && func_echo_all "${wl}-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' 8542 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 8543 ;; 8544 *) 8545 _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' 8546 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' 8547 _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ 8548 echo "-hidden">> $lib.exp~ 8549 $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~ 8550 $RM $lib.exp' 8551 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' 8552 ;; 8553 esac 8554 8555 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 8556 8557 # Commands to make compiler produce verbose output that lists 8558 # what "hidden" libraries, object files and flags are used when 8559 # linking a shared library. 8560 # 8561 # There doesn't appear to be a way to prevent this compiler from 8562 # explicitly linking system object files so we need to strip them 8563 # from the output so that they don't get included in the library 8564 # dependencies. 8565 output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$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; func_echo_all "$list"' 8566 ;; 8567 *) 8568 if test "$GXX" = yes && test "$with_gnu_ld" = no; then 8569 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' 8570 case $host in 8571 osf3*) 8572 _LT_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" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' 8573 ;; 8574 *) 8575 _LT_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" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' 8576 ;; 8577 esac 8578 8579 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 8580 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 8581 8582 # Commands to make compiler produce verbose output that lists 8583 # what "hidden" libraries, object files and flags are used when 8584 # linking a shared library. 8585 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' 8586 8587 else 8588 # FIXME: insert proper C++ library support 8589 _LT_TAGVAR(ld_shlibs, $1)=no 8590 fi 8591 ;; 8592 esac 8593 ;; 8594 8595 psos*) 8596 # FIXME: insert proper C++ library support 8597 _LT_TAGVAR(ld_shlibs, $1)=no 8598 ;; 8599 8600 sunos4*) 8601 case $cc_basename in 8602 CC*) 8603 # Sun C++ 4.x 8604 # FIXME: insert proper C++ library support 8605 _LT_TAGVAR(ld_shlibs, $1)=no 8606 ;; 8607 lcc*) 8608 # Lucid 8609 # FIXME: insert proper C++ library support 8610 _LT_TAGVAR(ld_shlibs, $1)=no 8611 ;; 8612 *) 8613 # FIXME: insert proper C++ library support 8614 _LT_TAGVAR(ld_shlibs, $1)=no 8615 ;; 8616 esac 8617 ;; 8618 8619 solaris*) 8620 case $cc_basename in 8621 CC* | sunCC*) 8622 # Sun C++ 4.2, 5.x and Centerline C++ 8623 _LT_TAGVAR(archive_cmds_need_lc,$1)=yes 8624 _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' 8625 _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 8626 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 8627 $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' 8628 8629 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 8630 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 8631 case $host_os in 8632 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; 8633 *) 8634 # The compiler driver will combine and reorder linker options, 8635 # but understands `-z linker_flag'. 8636 # Supported since Solaris 2.6 (maybe 2.5.1?) 8637 _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' 8638 ;; 8639 esac 8640 _LT_TAGVAR(link_all_deplibs, $1)=yes 8641 8642 output_verbose_link_cmd='func_echo_all' 8643 8644 # Archives containing C++ object files must be created using 8645 # "CC -xar", where "CC" is the Sun C++ compiler. This is 8646 # necessary to make sure instantiated templates are included 8647 # in the archive. 8648 _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' 8649 ;; 8650 gcx*) 8651 # Green Hills C++ Compiler 8652 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' 8653 8654 # The C++ compiler must be used to create the archive. 8655 _LT_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs' 8656 ;; 8657 *) 8658 # GNU C++ compiler with Solaris linker 8659 if test "$GXX" = yes && test "$with_gnu_ld" = no; then 8660 _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs' 8661 if $CC --version | $GREP -v '^2\.7' > /dev/null; then 8662 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' 8663 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 8664 $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' 8665 8666 # Commands to make compiler produce verbose output that lists 8667 # what "hidden" libraries, object files and flags are used when 8668 # linking a shared library. 8669 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' 8670 else 8671 # g++ 2.7 appears to require `-G' NOT `-shared' on this 8672 # platform. 8673 _LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' 8674 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 8675 $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' 8676 8677 # Commands to make compiler produce verbose output that lists 8678 # what "hidden" libraries, object files and flags are used when 8679 # linking a shared library. 8680 output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' 8681 fi 8682 8683 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir' 8684 case $host_os in 8685 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; 8686 *) 8687 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' 8688 ;; 8689 esac 8690 fi 8691 ;; 8692 esac 8693 ;; 8694 8695 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) 8696 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' 8697 _LT_TAGVAR(archive_cmds_need_lc, $1)=no 8698 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 8699 runpath_var='LD_RUN_PATH' 8700 8701 case $cc_basename in 8702 CC*) 8703 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 8704 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 8705 ;; 8706 *) 8707 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 8708 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 8709 ;; 8710 esac 8711 ;; 8712 8713 sysv5* | sco3.2v5* | sco5v6*) 8714 # Note: We can NOT use -z defs as we might desire, because we do not 8715 # link with -lc, and that would cause any symbols used from libc to 8716 # always be unresolved, which means just about no library would 8717 # ever link correctly. If we're not using GNU ld we use -z text 8718 # though, which does catch some bad symbols but isn't as heavy-handed 8719 # as -z defs. 8720 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' 8721 _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs' 8722 _LT_TAGVAR(archive_cmds_need_lc, $1)=no 8723 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 8724 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir' 8725 _LT_TAGVAR(hardcode_libdir_separator, $1)=':' 8726 _LT_TAGVAR(link_all_deplibs, $1)=yes 8727 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' 8728 runpath_var='LD_RUN_PATH' 8729 8730 case $cc_basename in 8731 CC*) 8732 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 8733 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 8734 _LT_TAGVAR(old_archive_cmds, $1)='$CC -Tprelink_objects $oldobjs~ 8735 '"$_LT_TAGVAR(old_archive_cmds, $1)" 8736 _LT_TAGVAR(reload_cmds, $1)='$CC -Tprelink_objects $reload_objs~ 8737 '"$_LT_TAGVAR(reload_cmds, $1)" 8738 ;; 8739 *) 8740 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 8741 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 8742 ;; 8743 esac 8744 ;; 8745 8746 tandem*) 8747 case $cc_basename in 8748 NCC*) 8749 # NonStop-UX NCC 3.20 8750 # FIXME: insert proper C++ library support 8751 _LT_TAGVAR(ld_shlibs, $1)=no 8752 ;; 8753 *) 8754 # FIXME: insert proper C++ library support 8755 _LT_TAGVAR(ld_shlibs, $1)=no 8756 ;; 8757 esac 8758 ;; 8759 8760 vxworks*) 8761 # FIXME: insert proper C++ library support 8762 _LT_TAGVAR(ld_shlibs, $1)=no 8763 ;; 8764 8765 *) 8766 # FIXME: insert proper C++ library support 8767 _LT_TAGVAR(ld_shlibs, $1)=no 8768 ;; 8769 esac 8770 8771 AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) 8772 test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no 8773 8774 _LT_TAGVAR(GCC, $1)="$GXX" 8775 _LT_TAGVAR(LD, $1)="$LD" 8776 8777 ## CAVEAT EMPTOR: 8778 ## There is no encapsulation within the following macros, do not change 8779 ## the running order or otherwise move them around unless you know exactly 8780 ## what you are doing... 8781 _LT_SYS_HIDDEN_LIBDEPS($1) 8782 _LT_COMPILER_PIC($1) 8783 _LT_COMPILER_C_O($1) 8784 _LT_COMPILER_FILE_LOCKS($1) 8785 _LT_LINKER_SHLIBS($1) 8786 _LT_SYS_DYNAMIC_LINKER($1) 8787 _LT_LINKER_HARDCODE_LIBPATH($1) 8788 8789 _LT_CONFIG($1) 8790 fi # test -n "$compiler" 8791 8792 CC=$lt_save_CC 8793 LDCXX=$LD 8794 LD=$lt_save_LD 8795 GCC=$lt_save_GCC 8796 with_gnu_ld=$lt_save_with_gnu_ld 8797 lt_cv_path_LDCXX=$lt_cv_path_LD 8798 lt_cv_path_LD=$lt_save_path_LD 8799 lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld 8800 lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld 8801fi # test "$_lt_caught_CXX_error" != yes 8802 8803AC_LANG_POP 8804])# _LT_LANG_CXX_CONFIG 8805 8806 8807# _LT_SYS_HIDDEN_LIBDEPS([TAGNAME]) 8808# --------------------------------- 8809# Figure out "hidden" library dependencies from verbose 8810# compiler output when linking a shared library. 8811# Parse the compiler output and extract the necessary 8812# objects, libraries and library flags. 8813m4_defun([_LT_SYS_HIDDEN_LIBDEPS], 8814[m4_require([_LT_FILEUTILS_DEFAULTS])dnl 8815# Dependencies to place before and after the object being linked: 8816_LT_TAGVAR(predep_objects, $1)= 8817_LT_TAGVAR(postdep_objects, $1)= 8818_LT_TAGVAR(predeps, $1)= 8819_LT_TAGVAR(postdeps, $1)= 8820_LT_TAGVAR(compiler_lib_search_path, $1)= 8821 8822dnl we can't use the lt_simple_compile_test_code here, 8823dnl because it contains code intended for an executable, 8824dnl not a library. It's possible we should let each 8825dnl tag define a new lt_????_link_test_code variable, 8826dnl but it's only used here... 8827m4_if([$1], [], [cat > conftest.$ac_ext <<_LT_EOF 8828int a; 8829void foo (void) { a = 0; } 8830_LT_EOF 8831], [$1], [CXX], [cat > conftest.$ac_ext <<_LT_EOF 8832class Foo 8833{ 8834public: 8835 Foo (void) { a = 0; } 8836private: 8837 int a; 8838}; 8839_LT_EOF 8840], [$1], [F77], [cat > conftest.$ac_ext <<_LT_EOF 8841 subroutine foo 8842 implicit none 8843 integer*4 a 8844 a=0 8845 return 8846 end 8847_LT_EOF 8848], [$1], [FC], [cat > conftest.$ac_ext <<_LT_EOF 8849 subroutine foo 8850 implicit none 8851 integer a 8852 a=0 8853 return 8854 end 8855_LT_EOF 8856], [$1], [GCJ], [cat > conftest.$ac_ext <<_LT_EOF 8857public class foo { 8858 private int a; 8859 public void bar (void) { 8860 a = 0; 8861 } 8862}; 8863_LT_EOF 8864]) 8865dnl Parse the compiler output and extract the necessary 8866dnl objects, libraries and library flags. 8867if AC_TRY_EVAL(ac_compile); then 8868 # Parse the compiler output and extract the necessary 8869 # objects, libraries and library flags. 8870 8871 # Sentinel used to keep track of whether or not we are before 8872 # the conftest object file. 8873 pre_test_object_deps_done=no 8874 8875 for p in `eval "$output_verbose_link_cmd"`; do 8876 case $p in 8877 8878 -L* | -R* | -l*) 8879 # Some compilers place space between "-{L,R}" and the path. 8880 # Remove the space. 8881 if test $p = "-L" || 8882 test $p = "-R"; then 8883 prev=$p 8884 continue 8885 else 8886 prev= 8887 fi 8888 8889 if test "$pre_test_object_deps_done" = no; then 8890 case $p in 8891 -L* | -R*) 8892 # Internal compiler library paths should come after those 8893 # provided the user. The postdeps already come after the 8894 # user supplied libs so there is no need to process them. 8895 if test -z "$_LT_TAGVAR(compiler_lib_search_path, $1)"; then 8896 _LT_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}" 8897 else 8898 _LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}" 8899 fi 8900 ;; 8901 # The "-l" case would never come before the object being 8902 # linked, so don't bother handling this case. 8903 esac 8904 else 8905 if test -z "$_LT_TAGVAR(postdeps, $1)"; then 8906 _LT_TAGVAR(postdeps, $1)="${prev}${p}" 8907 else 8908 _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} ${prev}${p}" 8909 fi 8910 fi 8911 ;; 8912 8913 *.$objext) 8914 # This assumes that the test object file only shows up 8915 # once in the compiler output. 8916 if test "$p" = "conftest.$objext"; then 8917 pre_test_object_deps_done=yes 8918 continue 8919 fi 8920 8921 if test "$pre_test_object_deps_done" = no; then 8922 if test -z "$_LT_TAGVAR(predep_objects, $1)"; then 8923 _LT_TAGVAR(predep_objects, $1)="$p" 8924 else 8925 _LT_TAGVAR(predep_objects, $1)="$_LT_TAGVAR(predep_objects, $1) $p" 8926 fi 8927 else 8928 if test -z "$_LT_TAGVAR(postdep_objects, $1)"; then 8929 _LT_TAGVAR(postdep_objects, $1)="$p" 8930 else 8931 _LT_TAGVAR(postdep_objects, $1)="$_LT_TAGVAR(postdep_objects, $1) $p" 8932 fi 8933 fi 8934 ;; 8935 8936 *) ;; # Ignore the rest. 8937 8938 esac 8939 done 8940 8941 # Clean up. 8942 rm -f a.out a.exe 8943else 8944 echo "libtool.m4: error: problem compiling $1 test program" 8945fi 8946 8947$RM -f confest.$objext 8948 8949# PORTME: override above test on systems where it is broken 8950m4_if([$1], [CXX], 8951[case $host_os in 8952interix[[3-9]]*) 8953 # Interix 3.5 installs completely hosed .la files for C++, so rather than 8954 # hack all around it, let's just trust "g++" to DTRT. 8955 _LT_TAGVAR(predep_objects,$1)= 8956 _LT_TAGVAR(postdep_objects,$1)= 8957 _LT_TAGVAR(postdeps,$1)= 8958 ;; 8959 8960linux*) 8961 case `$CC -V 2>&1 | sed 5q` in 8962 *Sun\ C*) 8963 # Sun C++ 5.9 8964 8965 # The more standards-conforming stlport4 library is 8966 # incompatible with the Cstd library. Avoid specifying 8967 # it if it's in CXXFLAGS. Ignore libCrun as 8968 # -library=stlport4 depends on it. 8969 case " $CXX $CXXFLAGS " in 8970 *" -library=stlport4 "*) 8971 solaris_use_stlport4=yes 8972 ;; 8973 esac 8974 8975 if test "$solaris_use_stlport4" != yes; then 8976 _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun' 8977 fi 8978 ;; 8979 esac 8980 ;; 8981 8982solaris*) 8983 case $cc_basename in 8984 CC* | sunCC*) 8985 # The more standards-conforming stlport4 library is 8986 # incompatible with the Cstd library. Avoid specifying 8987 # it if it's in CXXFLAGS. Ignore libCrun as 8988 # -library=stlport4 depends on it. 8989 case " $CXX $CXXFLAGS " in 8990 *" -library=stlport4 "*) 8991 solaris_use_stlport4=yes 8992 ;; 8993 esac 8994 8995 # Adding this requires a known-good setup of shared libraries for 8996 # Sun compiler versions before 5.6, else PIC objects from an old 8997 # archive will be linked into the output, leading to subtle bugs. 8998 if test "$solaris_use_stlport4" != yes; then 8999 _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun' 9000 fi 9001 ;; 9002 esac 9003 ;; 9004esac 9005]) 9006 9007case " $_LT_TAGVAR(postdeps, $1) " in 9008*" -lc "*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;; 9009esac 9010 _LT_TAGVAR(compiler_lib_search_dirs, $1)= 9011if test -n "${_LT_TAGVAR(compiler_lib_search_path, $1)}"; then 9012 _LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | ${SED} -e 's! -L! !g' -e 's!^ !!'` 9013fi 9014_LT_TAGDECL([], [compiler_lib_search_dirs], [1], 9015 [The directories searched by this compiler when creating a shared library]) 9016_LT_TAGDECL([], [predep_objects], [1], 9017 [Dependencies to place before and after the objects being linked to 9018 create a shared library]) 9019_LT_TAGDECL([], [postdep_objects], [1]) 9020_LT_TAGDECL([], [predeps], [1]) 9021_LT_TAGDECL([], [postdeps], [1]) 9022_LT_TAGDECL([], [compiler_lib_search_path], [1], 9023 [The library search path used internally by the compiler when linking 9024 a shared library]) 9025])# _LT_SYS_HIDDEN_LIBDEPS 9026 9027 9028# _LT_LANG_F77_CONFIG([TAG]) 9029# -------------------------- 9030# Ensure that the configuration variables for a Fortran 77 compiler are 9031# suitably defined. These variables are subsequently used by _LT_CONFIG 9032# to write the compiler configuration to `libtool'. 9033m4_defun([_LT_LANG_F77_CONFIG], 9034[AC_LANG_PUSH(Fortran 77) 9035if test -z "$F77" || test "X$F77" = "Xno"; then 9036 _lt_disable_F77=yes 9037fi 9038 9039_LT_TAGVAR(archive_cmds_need_lc, $1)=no 9040_LT_TAGVAR(allow_undefined_flag, $1)= 9041_LT_TAGVAR(always_export_symbols, $1)=no 9042_LT_TAGVAR(archive_expsym_cmds, $1)= 9043_LT_TAGVAR(export_dynamic_flag_spec, $1)= 9044_LT_TAGVAR(hardcode_direct, $1)=no 9045_LT_TAGVAR(hardcode_direct_absolute, $1)=no 9046_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 9047_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= 9048_LT_TAGVAR(hardcode_libdir_separator, $1)= 9049_LT_TAGVAR(hardcode_minus_L, $1)=no 9050_LT_TAGVAR(hardcode_automatic, $1)=no 9051_LT_TAGVAR(inherit_rpath, $1)=no 9052_LT_TAGVAR(module_cmds, $1)= 9053_LT_TAGVAR(module_expsym_cmds, $1)= 9054_LT_TAGVAR(link_all_deplibs, $1)=unknown 9055_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 9056_LT_TAGVAR(reload_flag, $1)=$reload_flag 9057_LT_TAGVAR(reload_cmds, $1)=$reload_cmds 9058_LT_TAGVAR(no_undefined_flag, $1)= 9059_LT_TAGVAR(whole_archive_flag_spec, $1)= 9060_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no 9061 9062# Source file extension for f77 test sources. 9063ac_ext=f 9064 9065# Object file extension for compiled f77 test sources. 9066objext=o 9067_LT_TAGVAR(objext, $1)=$objext 9068 9069# No sense in running all these tests if we already determined that 9070# the F77 compiler isn't working. Some variables (like enable_shared) 9071# are currently assumed to apply to all compilers on this platform, 9072# and will be corrupted by setting them based on a non-working compiler. 9073if test "$_lt_disable_F77" != yes; then 9074 # Code to be used in simple compile tests 9075 lt_simple_compile_test_code="\ 9076 subroutine t 9077 return 9078 end 9079" 9080 9081 # Code to be used in simple link tests 9082 lt_simple_link_test_code="\ 9083 program t 9084 end 9085" 9086 9087 # ltmain only uses $CC for tagged configurations so make sure $CC is set. 9088 _LT_TAG_COMPILER 9089 9090 # save warnings/boilerplate of simple test code 9091 _LT_COMPILER_BOILERPLATE 9092 _LT_LINKER_BOILERPLATE 9093 9094 # Allow CC to be a program name with arguments. 9095 lt_save_CC="$CC" 9096 lt_save_GCC=$GCC 9097 CC=${F77-"f77"} 9098 compiler=$CC 9099 _LT_TAGVAR(compiler, $1)=$CC 9100 _LT_CC_BASENAME([$compiler]) 9101 GCC=$G77 9102 if test -n "$compiler"; then 9103 AC_MSG_CHECKING([if libtool supports shared libraries]) 9104 AC_MSG_RESULT([$can_build_shared]) 9105 9106 AC_MSG_CHECKING([whether to build shared libraries]) 9107 test "$can_build_shared" = "no" && enable_shared=no 9108 9109 # On AIX, shared libraries and static libraries use the same namespace, and 9110 # are all built from PIC. 9111 case $host_os in 9112 aix3*) 9113 test "$enable_shared" = yes && enable_static=no 9114 if test -n "$RANLIB"; then 9115 archive_cmds="$archive_cmds~\$RANLIB \$lib" 9116 postinstall_cmds='$RANLIB $lib' 9117 fi 9118 ;; 9119 aix[[4-9]]*) 9120 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then 9121 test "$enable_shared" = yes && enable_static=no 9122 fi 9123 ;; 9124 esac 9125 AC_MSG_RESULT([$enable_shared]) 9126 9127 AC_MSG_CHECKING([whether to build static libraries]) 9128 # Make sure either enable_shared or enable_static is yes. 9129 test "$enable_shared" = yes || enable_static=yes 9130 AC_MSG_RESULT([$enable_static]) 9131 9132 _LT_TAGVAR(GCC, $1)="$G77" 9133 _LT_TAGVAR(LD, $1)="$LD" 9134 9135 ## CAVEAT EMPTOR: 9136 ## There is no encapsulation within the following macros, do not change 9137 ## the running order or otherwise move them around unless you know exactly 9138 ## what you are doing... 9139 _LT_COMPILER_PIC($1) 9140 _LT_COMPILER_C_O($1) 9141 _LT_COMPILER_FILE_LOCKS($1) 9142 _LT_LINKER_SHLIBS($1) 9143 _LT_SYS_DYNAMIC_LINKER($1) 9144 _LT_LINKER_HARDCODE_LIBPATH($1) 9145 9146 _LT_CONFIG($1) 9147 fi # test -n "$compiler" 9148 9149 GCC=$lt_save_GCC 9150 CC="$lt_save_CC" 9151fi # test "$_lt_disable_F77" != yes 9152 9153AC_LANG_POP 9154])# _LT_LANG_F77_CONFIG 9155 9156 9157# _LT_LANG_FC_CONFIG([TAG]) 9158# ------------------------- 9159# Ensure that the configuration variables for a Fortran compiler are 9160# suitably defined. These variables are subsequently used by _LT_CONFIG 9161# to write the compiler configuration to `libtool'. 9162m4_defun([_LT_LANG_FC_CONFIG], 9163[AC_LANG_PUSH(Fortran) 9164 9165if test -z "$FC" || test "X$FC" = "Xno"; then 9166 _lt_disable_FC=yes 9167fi 9168 9169_LT_TAGVAR(archive_cmds_need_lc, $1)=no 9170_LT_TAGVAR(allow_undefined_flag, $1)= 9171_LT_TAGVAR(always_export_symbols, $1)=no 9172_LT_TAGVAR(archive_expsym_cmds, $1)= 9173_LT_TAGVAR(export_dynamic_flag_spec, $1)= 9174_LT_TAGVAR(hardcode_direct, $1)=no 9175_LT_TAGVAR(hardcode_direct_absolute, $1)=no 9176_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 9177_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= 9178_LT_TAGVAR(hardcode_libdir_separator, $1)= 9179_LT_TAGVAR(hardcode_minus_L, $1)=no 9180_LT_TAGVAR(hardcode_automatic, $1)=no 9181_LT_TAGVAR(inherit_rpath, $1)=no 9182_LT_TAGVAR(module_cmds, $1)= 9183_LT_TAGVAR(module_expsym_cmds, $1)= 9184_LT_TAGVAR(link_all_deplibs, $1)=unknown 9185_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 9186_LT_TAGVAR(reload_flag, $1)=$reload_flag 9187_LT_TAGVAR(reload_cmds, $1)=$reload_cmds 9188_LT_TAGVAR(no_undefined_flag, $1)= 9189_LT_TAGVAR(whole_archive_flag_spec, $1)= 9190_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no 9191 9192# Source file extension for fc test sources. 9193ac_ext=${ac_fc_srcext-f} 9194 9195# Object file extension for compiled fc test sources. 9196objext=o 9197_LT_TAGVAR(objext, $1)=$objext 9198 9199# No sense in running all these tests if we already determined that 9200# the FC compiler isn't working. Some variables (like enable_shared) 9201# are currently assumed to apply to all compilers on this platform, 9202# and will be corrupted by setting them based on a non-working compiler. 9203if test "$_lt_disable_FC" != yes; then 9204 # Code to be used in simple compile tests 9205 lt_simple_compile_test_code="\ 9206 subroutine t 9207 return 9208 end 9209" 9210 9211 # Code to be used in simple link tests 9212 lt_simple_link_test_code="\ 9213 program t 9214 end 9215" 9216 9217 # ltmain only uses $CC for tagged configurations so make sure $CC is set. 9218 _LT_TAG_COMPILER 9219 9220 # save warnings/boilerplate of simple test code 9221 _LT_COMPILER_BOILERPLATE 9222 _LT_LINKER_BOILERPLATE 9223 9224 # Allow CC to be a program name with arguments. 9225 lt_save_CC="$CC" 9226 lt_save_GCC=$GCC 9227 CC=${FC-"f95"} 9228 compiler=$CC 9229 GCC=$ac_cv_fc_compiler_gnu 9230 9231 _LT_TAGVAR(compiler, $1)=$CC 9232 _LT_CC_BASENAME([$compiler]) 9233 9234 if test -n "$compiler"; then 9235 AC_MSG_CHECKING([if libtool supports shared libraries]) 9236 AC_MSG_RESULT([$can_build_shared]) 9237 9238 AC_MSG_CHECKING([whether to build shared libraries]) 9239 test "$can_build_shared" = "no" && enable_shared=no 9240 9241 # On AIX, shared libraries and static libraries use the same namespace, and 9242 # are all built from PIC. 9243 case $host_os in 9244 aix3*) 9245 test "$enable_shared" = yes && enable_static=no 9246 if test -n "$RANLIB"; then 9247 archive_cmds="$archive_cmds~\$RANLIB \$lib" 9248 postinstall_cmds='$RANLIB $lib' 9249 fi 9250 ;; 9251 aix[[4-9]]*) 9252 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then 9253 test "$enable_shared" = yes && enable_static=no 9254 fi 9255 ;; 9256 esac 9257 AC_MSG_RESULT([$enable_shared]) 9258 9259 AC_MSG_CHECKING([whether to build static libraries]) 9260 # Make sure either enable_shared or enable_static is yes. 9261 test "$enable_shared" = yes || enable_static=yes 9262 AC_MSG_RESULT([$enable_static]) 9263 9264 _LT_TAGVAR(GCC, $1)="$ac_cv_fc_compiler_gnu" 9265 _LT_TAGVAR(LD, $1)="$LD" 9266 9267 ## CAVEAT EMPTOR: 9268 ## There is no encapsulation within the following macros, do not change 9269 ## the running order or otherwise move them around unless you know exactly 9270 ## what you are doing... 9271 _LT_SYS_HIDDEN_LIBDEPS($1) 9272 _LT_COMPILER_PIC($1) 9273 _LT_COMPILER_C_O($1) 9274 _LT_COMPILER_FILE_LOCKS($1) 9275 _LT_LINKER_SHLIBS($1) 9276 _LT_SYS_DYNAMIC_LINKER($1) 9277 _LT_LINKER_HARDCODE_LIBPATH($1) 9278 9279 _LT_CONFIG($1) 9280 fi # test -n "$compiler" 9281 9282 GCC=$lt_save_GCC 9283 CC="$lt_save_CC" 9284fi # test "$_lt_disable_FC" != yes 9285 9286AC_LANG_POP 9287])# _LT_LANG_FC_CONFIG 9288 9289 9290# _LT_LANG_GCJ_CONFIG([TAG]) 9291# -------------------------- 9292# Ensure that the configuration variables for the GNU Java Compiler compiler 9293# are suitably defined. These variables are subsequently used by _LT_CONFIG 9294# to write the compiler configuration to `libtool'. 9295m4_defun([_LT_LANG_GCJ_CONFIG], 9296[AC_REQUIRE([LT_PROG_GCJ])dnl 9297AC_LANG_SAVE 9298 9299# Source file extension for Java test sources. 9300ac_ext=java 9301 9302# Object file extension for compiled Java test sources. 9303objext=o 9304_LT_TAGVAR(objext, $1)=$objext 9305 9306# Code to be used in simple compile tests 9307lt_simple_compile_test_code="class foo {}" 9308 9309# Code to be used in simple link tests 9310lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }' 9311 9312# ltmain only uses $CC for tagged configurations so make sure $CC is set. 9313_LT_TAG_COMPILER 9314 9315# save warnings/boilerplate of simple test code 9316_LT_COMPILER_BOILERPLATE 9317_LT_LINKER_BOILERPLATE 9318 9319# Allow CC to be a program name with arguments. 9320lt_save_CC="$CC" 9321lt_save_GCC=$GCC 9322GCC=yes 9323CC=${GCJ-"gcj"} 9324compiler=$CC 9325_LT_TAGVAR(compiler, $1)=$CC 9326_LT_TAGVAR(LD, $1)="$LD" 9327_LT_CC_BASENAME([$compiler]) 9328 9329# GCJ did not exist at the time GCC didn't implicitly link libc in. 9330_LT_TAGVAR(archive_cmds_need_lc, $1)=no 9331 9332_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 9333_LT_TAGVAR(reload_flag, $1)=$reload_flag 9334_LT_TAGVAR(reload_cmds, $1)=$reload_cmds 9335 9336if test -n "$compiler"; then 9337 _LT_COMPILER_NO_RTTI($1) 9338 _LT_COMPILER_PIC($1) 9339 _LT_COMPILER_C_O($1) 9340 _LT_COMPILER_FILE_LOCKS($1) 9341 _LT_LINKER_SHLIBS($1) 9342 _LT_LINKER_HARDCODE_LIBPATH($1) 9343 9344 _LT_CONFIG($1) 9345fi 9346 9347AC_LANG_RESTORE 9348 9349GCC=$lt_save_GCC 9350CC="$lt_save_CC" 9351])# _LT_LANG_GCJ_CONFIG 9352 9353 9354# _LT_LANG_RC_CONFIG([TAG]) 9355# ------------------------- 9356# Ensure that the configuration variables for the Windows resource compiler 9357# are suitably defined. These variables are subsequently used by _LT_CONFIG 9358# to write the compiler configuration to `libtool'. 9359m4_defun([_LT_LANG_RC_CONFIG], 9360[AC_REQUIRE([LT_PROG_RC])dnl 9361AC_LANG_SAVE 9362 9363# Source file extension for RC test sources. 9364ac_ext=rc 9365 9366# Object file extension for compiled RC test sources. 9367objext=o 9368_LT_TAGVAR(objext, $1)=$objext 9369 9370# Code to be used in simple compile tests 9371lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }' 9372 9373# Code to be used in simple link tests 9374lt_simple_link_test_code="$lt_simple_compile_test_code" 9375 9376# ltmain only uses $CC for tagged configurations so make sure $CC is set. 9377_LT_TAG_COMPILER 9378 9379# save warnings/boilerplate of simple test code 9380_LT_COMPILER_BOILERPLATE 9381_LT_LINKER_BOILERPLATE 9382 9383# Allow CC to be a program name with arguments. 9384lt_save_CC="$CC" 9385lt_save_GCC=$GCC 9386GCC= 9387CC=${RC-"windres"} 9388compiler=$CC 9389_LT_TAGVAR(compiler, $1)=$CC 9390_LT_CC_BASENAME([$compiler]) 9391_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes 9392 9393if test -n "$compiler"; then 9394 : 9395 _LT_CONFIG($1) 9396fi 9397 9398GCC=$lt_save_GCC 9399AC_LANG_RESTORE 9400CC="$lt_save_CC" 9401])# _LT_LANG_RC_CONFIG 9402 9403 9404# LT_PROG_GCJ 9405# ----------- 9406AC_DEFUN([LT_PROG_GCJ], 9407[m4_ifdef([AC_PROG_GCJ], [AC_PROG_GCJ], 9408 [m4_ifdef([A][M_PROG_GCJ], [A][M_PROG_GCJ], 9409 [AC_CHECK_TOOL(GCJ, gcj,) 9410 test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2" 9411 AC_SUBST(GCJFLAGS)])])[]dnl 9412]) 9413 9414# Old name: 9415AU_ALIAS([LT_AC_PROG_GCJ], [LT_PROG_GCJ]) 9416dnl aclocal-1.4 backwards compatibility: 9417dnl AC_DEFUN([LT_AC_PROG_GCJ], []) 9418 9419 9420# LT_PROG_RC 9421# ---------- 9422AC_DEFUN([LT_PROG_RC], 9423[AC_CHECK_TOOL(RC, windres,) 9424]) 9425 9426# Old name: 9427AU_ALIAS([LT_AC_PROG_RC], [LT_PROG_RC]) 9428dnl aclocal-1.4 backwards compatibility: 9429dnl AC_DEFUN([LT_AC_PROG_RC], []) 9430 9431 9432# _LT_DECL_EGREP 9433# -------------- 9434# If we don't have a new enough Autoconf to choose the best grep 9435# available, choose the one first in the user's PATH. 9436m4_defun([_LT_DECL_EGREP], 9437[AC_REQUIRE([AC_PROG_EGREP])dnl 9438AC_REQUIRE([AC_PROG_FGREP])dnl 9439test -z "$GREP" && GREP=grep 9440_LT_DECL([], [GREP], [1], [A grep program that handles long lines]) 9441_LT_DECL([], [EGREP], [1], [An ERE matcher]) 9442_LT_DECL([], [FGREP], [1], [A literal string matcher]) 9443dnl Non-bleeding-edge autoconf doesn't subst GREP, so do it here too 9444AC_SUBST([GREP]) 9445]) 9446 9447 9448# _LT_DECL_OBJDUMP 9449# -------------- 9450# If we don't have a new enough Autoconf to choose the best objdump 9451# available, choose the one first in the user's PATH. 9452m4_defun([_LT_DECL_OBJDUMP], 9453[AC_CHECK_TOOL(OBJDUMP, objdump, false) 9454test -z "$OBJDUMP" && OBJDUMP=objdump 9455_LT_DECL([], [OBJDUMP], [1], [An object symbol dumper]) 9456AC_SUBST([OBJDUMP]) 9457]) 9458 9459 9460# _LT_DECL_SED 9461# ------------ 9462# Check for a fully-functional sed program, that truncates 9463# as few characters as possible. Prefer GNU sed if found. 9464m4_defun([_LT_DECL_SED], 9465[AC_PROG_SED 9466test -z "$SED" && SED=sed 9467Xsed="$SED -e 1s/^X//" 9468_LT_DECL([], [SED], [1], [A sed program that does not truncate output]) 9469_LT_DECL([], [Xsed], ["\$SED -e 1s/^X//"], 9470 [Sed that helps us avoid accidentally triggering echo(1) options like -n]) 9471])# _LT_DECL_SED 9472 9473m4_ifndef([AC_PROG_SED], [ 9474# NOTE: This macro has been submitted for inclusion into # 9475# GNU Autoconf as AC_PROG_SED. When it is available in # 9476# a released version of Autoconf we should remove this # 9477# macro and use it instead. # 9478 9479m4_defun([AC_PROG_SED], 9480[AC_MSG_CHECKING([for a sed that does not truncate output]) 9481AC_CACHE_VAL(lt_cv_path_SED, 9482[# Loop through the user's path and test for sed and gsed. 9483# Then use that list of sed's as ones to test for truncation. 9484as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9485for as_dir in $PATH 9486do 9487 IFS=$as_save_IFS 9488 test -z "$as_dir" && as_dir=. 9489 for lt_ac_prog in sed gsed; do 9490 for ac_exec_ext in '' $ac_executable_extensions; do 9491 if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then 9492 lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext" 9493 fi 9494 done 9495 done 9496done 9497IFS=$as_save_IFS 9498lt_ac_max=0 9499lt_ac_count=0 9500# Add /usr/xpg4/bin/sed as it is typically found on Solaris 9501# along with /bin/sed that truncates output. 9502for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do 9503 test ! -f $lt_ac_sed && continue 9504 cat /dev/null > conftest.in 9505 lt_ac_count=0 9506 echo $ECHO_N "0123456789$ECHO_C" >conftest.in 9507 # Check for GNU sed and select it if it is found. 9508 if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then 9509 lt_cv_path_SED=$lt_ac_sed 9510 break 9511 fi 9512 while true; do 9513 cat conftest.in conftest.in >conftest.tmp 9514 mv conftest.tmp conftest.in 9515 cp conftest.in conftest.nl 9516 echo >>conftest.nl 9517 $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break 9518 cmp -s conftest.out conftest.nl || break 9519 # 10000 chars as input seems more than enough 9520 test $lt_ac_count -gt 10 && break 9521 lt_ac_count=`expr $lt_ac_count + 1` 9522 if test $lt_ac_count -gt $lt_ac_max; then 9523 lt_ac_max=$lt_ac_count 9524 lt_cv_path_SED=$lt_ac_sed 9525 fi 9526 done 9527done 9528]) 9529SED=$lt_cv_path_SED 9530AC_SUBST([SED]) 9531AC_MSG_RESULT([$SED]) 9532])#AC_PROG_SED 9533])#m4_ifndef 9534 9535# Old name: 9536AU_ALIAS([LT_AC_PROG_SED], [AC_PROG_SED]) 9537dnl aclocal-1.4 backwards compatibility: 9538dnl AC_DEFUN([LT_AC_PROG_SED], []) 9539 9540 9541# _LT_CHECK_SHELL_FEATURES 9542# ------------------------ 9543# Find out whether the shell is Bourne or XSI compatible, 9544# or has some other useful features. 9545m4_defun([_LT_CHECK_SHELL_FEATURES], 9546[AC_MSG_CHECKING([whether the shell understands some XSI constructs]) 9547# Try some XSI features 9548xsi_shell=no 9549( _lt_dummy="a/b/c" 9550 test "${_lt_dummy##*/},${_lt_dummy%/*},"${_lt_dummy%"$_lt_dummy"}, \ 9551 = c,a/b,, \ 9552 && eval 'test $(( 1 + 1 )) -eq 2 \ 9553 && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \ 9554 && xsi_shell=yes 9555AC_MSG_RESULT([$xsi_shell]) 9556_LT_CONFIG_LIBTOOL_INIT([xsi_shell='$xsi_shell']) 9557 9558AC_MSG_CHECKING([whether the shell understands "+="]) 9559lt_shell_append=no 9560( foo=bar; set foo baz; eval "$[1]+=\$[2]" && test "$foo" = barbaz ) \ 9561 >/dev/null 2>&1 \ 9562 && lt_shell_append=yes 9563AC_MSG_RESULT([$lt_shell_append]) 9564_LT_CONFIG_LIBTOOL_INIT([lt_shell_append='$lt_shell_append']) 9565 9566if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then 9567 lt_unset=unset 9568else 9569 lt_unset=false 9570fi 9571_LT_DECL([], [lt_unset], [0], [whether the shell understands "unset"])dnl 9572 9573# test EBCDIC or ASCII 9574case `echo X|tr X '\101'` in 9575 A) # ASCII based system 9576 # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr 9577 lt_SP2NL='tr \040 \012' 9578 lt_NL2SP='tr \015\012 \040\040' 9579 ;; 9580 *) # EBCDIC based system 9581 lt_SP2NL='tr \100 \n' 9582 lt_NL2SP='tr \r\n \100\100' 9583 ;; 9584esac 9585_LT_DECL([SP2NL], [lt_SP2NL], [1], [turn spaces into newlines])dnl 9586_LT_DECL([NL2SP], [lt_NL2SP], [1], [turn newlines into spaces])dnl 9587])# _LT_CHECK_SHELL_FEATURES 9588 9589 9590# _LT_PROG_XSI_SHELLFNS 9591# --------------------- 9592# Bourne and XSI compatible variants of some useful shell functions. 9593m4_defun([_LT_PROG_XSI_SHELLFNS], 9594[case $xsi_shell in 9595 yes) 9596 cat << \_LT_EOF >> "$cfgfile" 9597 9598# func_dirname file append nondir_replacement 9599# Compute the dirname of FILE. If nonempty, add APPEND to the result, 9600# otherwise set result to NONDIR_REPLACEMENT. 9601func_dirname () 9602{ 9603 case ${1} in 9604 */*) func_dirname_result="${1%/*}${2}" ;; 9605 * ) func_dirname_result="${3}" ;; 9606 esac 9607} 9608 9609# func_basename file 9610func_basename () 9611{ 9612 func_basename_result="${1##*/}" 9613} 9614 9615# func_dirname_and_basename file append nondir_replacement 9616# perform func_basename and func_dirname in a single function 9617# call: 9618# dirname: Compute the dirname of FILE. If nonempty, 9619# add APPEND to the result, otherwise set result 9620# to NONDIR_REPLACEMENT. 9621# value returned in "$func_dirname_result" 9622# basename: Compute filename of FILE. 9623# value retuned in "$func_basename_result" 9624# Implementation must be kept synchronized with func_dirname 9625# and func_basename. For efficiency, we do not delegate to 9626# those functions but instead duplicate the functionality here. 9627func_dirname_and_basename () 9628{ 9629 case ${1} in 9630 */*) func_dirname_result="${1%/*}${2}" ;; 9631 * ) func_dirname_result="${3}" ;; 9632 esac 9633 func_basename_result="${1##*/}" 9634} 9635 9636# func_stripname prefix suffix name 9637# strip PREFIX and SUFFIX off of NAME. 9638# PREFIX and SUFFIX must not contain globbing or regex special 9639# characters, hashes, percent signs, but SUFFIX may contain a leading 9640# dot (in which case that matches only a dot). 9641func_stripname () 9642{ 9643 # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are 9644 # positional parameters, so assign one to ordinary parameter first. 9645 func_stripname_result=${3} 9646 func_stripname_result=${func_stripname_result#"${1}"} 9647 func_stripname_result=${func_stripname_result%"${2}"} 9648} 9649 9650# func_opt_split 9651func_opt_split () 9652{ 9653 func_opt_split_opt=${1%%=*} 9654 func_opt_split_arg=${1#*=} 9655} 9656 9657# func_lo2o object 9658func_lo2o () 9659{ 9660 case ${1} in 9661 *.lo) func_lo2o_result=${1%.lo}.${objext} ;; 9662 *) func_lo2o_result=${1} ;; 9663 esac 9664} 9665 9666# func_xform libobj-or-source 9667func_xform () 9668{ 9669 func_xform_result=${1%.*}.lo 9670} 9671 9672# func_arith arithmetic-term... 9673func_arith () 9674{ 9675 func_arith_result=$(( $[*] )) 9676} 9677 9678# func_len string 9679# STRING may not start with a hyphen. 9680func_len () 9681{ 9682 func_len_result=${#1} 9683} 9684 9685_LT_EOF 9686 ;; 9687 *) # Bourne compatible functions. 9688 cat << \_LT_EOF >> "$cfgfile" 9689 9690# func_dirname file append nondir_replacement 9691# Compute the dirname of FILE. If nonempty, add APPEND to the result, 9692# otherwise set result to NONDIR_REPLACEMENT. 9693func_dirname () 9694{ 9695 # Extract subdirectory from the argument. 9696 func_dirname_result=`$ECHO "${1}" | $SED "$dirname"` 9697 if test "X$func_dirname_result" = "X${1}"; then 9698 func_dirname_result="${3}" 9699 else 9700 func_dirname_result="$func_dirname_result${2}" 9701 fi 9702} 9703 9704# func_basename file 9705func_basename () 9706{ 9707 func_basename_result=`$ECHO "${1}" | $SED "$basename"` 9708} 9709 9710dnl func_dirname_and_basename 9711dnl A portable version of this function is already defined in general.m4sh 9712dnl so there is no need for it here. 9713 9714# func_stripname prefix suffix name 9715# strip PREFIX and SUFFIX off of NAME. 9716# PREFIX and SUFFIX must not contain globbing or regex special 9717# characters, hashes, percent signs, but SUFFIX may contain a leading 9718# dot (in which case that matches only a dot). 9719# func_strip_suffix prefix name 9720func_stripname () 9721{ 9722 case ${2} in 9723 .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;; 9724 *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;; 9725 esac 9726} 9727 9728# sed scripts: 9729my_sed_long_opt='1s/^\(-[[^=]]*\)=.*/\1/;q' 9730my_sed_long_arg='1s/^-[[^=]]*=//' 9731 9732# func_opt_split 9733func_opt_split () 9734{ 9735 func_opt_split_opt=`$ECHO "${1}" | $SED "$my_sed_long_opt"` 9736 func_opt_split_arg=`$ECHO "${1}" | $SED "$my_sed_long_arg"` 9737} 9738 9739# func_lo2o object 9740func_lo2o () 9741{ 9742 func_lo2o_result=`$ECHO "${1}" | $SED "$lo2o"` 9743} 9744 9745# func_xform libobj-or-source 9746func_xform () 9747{ 9748 func_xform_result=`$ECHO "${1}" | $SED 's/\.[[^.]]*$/.lo/'` 9749} 9750 9751# func_arith arithmetic-term... 9752func_arith () 9753{ 9754 func_arith_result=`expr "$[@]"` 9755} 9756 9757# func_len string 9758# STRING may not start with a hyphen. 9759func_len () 9760{ 9761 func_len_result=`expr "$[1]" : ".*" 2>/dev/null || echo $max_cmd_len` 9762} 9763 9764_LT_EOF 9765esac 9766 9767case $lt_shell_append in 9768 yes) 9769 cat << \_LT_EOF >> "$cfgfile" 9770 9771# func_append var value 9772# Append VALUE to the end of shell variable VAR. 9773func_append () 9774{ 9775 eval "$[1]+=\$[2]" 9776} 9777_LT_EOF 9778 ;; 9779 *) 9780 cat << \_LT_EOF >> "$cfgfile" 9781 9782# func_append var value 9783# Append VALUE to the end of shell variable VAR. 9784func_append () 9785{ 9786 eval "$[1]=\$$[1]\$[2]" 9787} 9788 9789_LT_EOF 9790 ;; 9791 esac 9792]) 9793 9794# Helper functions for option handling. -*- Autoconf -*- 9795# 9796# Copyright (C) 2004, 2005, 2007, 2008, 2009 Free Software Foundation, 9797# Inc. 9798# Written by Gary V. Vaughan, 2004 9799# 9800# This file is free software; the Free Software Foundation gives 9801# unlimited permission to copy and/or distribute it, with or without 9802# modifications, as long as this notice is preserved. 9803 9804# serial 7 ltoptions.m4 9805 9806# This is to help aclocal find these macros, as it can't see m4_define. 9807AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])]) 9808 9809 9810# _LT_MANGLE_OPTION(MACRO-NAME, OPTION-NAME) 9811# ------------------------------------------ 9812m4_define([_LT_MANGLE_OPTION], 9813[[_LT_OPTION_]m4_bpatsubst($1__$2, [[^a-zA-Z0-9_]], [_])]) 9814 9815 9816# _LT_SET_OPTION(MACRO-NAME, OPTION-NAME) 9817# --------------------------------------- 9818# Set option OPTION-NAME for macro MACRO-NAME, and if there is a 9819# matching handler defined, dispatch to it. Other OPTION-NAMEs are 9820# saved as a flag. 9821m4_define([_LT_SET_OPTION], 9822[m4_define(_LT_MANGLE_OPTION([$1], [$2]))dnl 9823m4_ifdef(_LT_MANGLE_DEFUN([$1], [$2]), 9824 _LT_MANGLE_DEFUN([$1], [$2]), 9825 [m4_warning([Unknown $1 option `$2'])])[]dnl 9826]) 9827 9828 9829# _LT_IF_OPTION(MACRO-NAME, OPTION-NAME, IF-SET, [IF-NOT-SET]) 9830# ------------------------------------------------------------ 9831# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. 9832m4_define([_LT_IF_OPTION], 9833[m4_ifdef(_LT_MANGLE_OPTION([$1], [$2]), [$3], [$4])]) 9834 9835 9836# _LT_UNLESS_OPTIONS(MACRO-NAME, OPTION-LIST, IF-NOT-SET) 9837# ------------------------------------------------------- 9838# Execute IF-NOT-SET unless all options in OPTION-LIST for MACRO-NAME 9839# are set. 9840m4_define([_LT_UNLESS_OPTIONS], 9841[m4_foreach([_LT_Option], m4_split(m4_normalize([$2])), 9842 [m4_ifdef(_LT_MANGLE_OPTION([$1], _LT_Option), 9843 [m4_define([$0_found])])])[]dnl 9844m4_ifdef([$0_found], [m4_undefine([$0_found])], [$3 9845])[]dnl 9846]) 9847 9848 9849# _LT_SET_OPTIONS(MACRO-NAME, OPTION-LIST) 9850# ---------------------------------------- 9851# OPTION-LIST is a space-separated list of Libtool options associated 9852# with MACRO-NAME. If any OPTION has a matching handler declared with 9853# LT_OPTION_DEFINE, dispatch to that macro; otherwise complain about 9854# the unknown option and exit. 9855m4_defun([_LT_SET_OPTIONS], 9856[# Set options 9857m4_foreach([_LT_Option], m4_split(m4_normalize([$2])), 9858 [_LT_SET_OPTION([$1], _LT_Option)]) 9859 9860m4_if([$1],[LT_INIT],[ 9861 dnl 9862 dnl Simply set some default values (i.e off) if boolean options were not 9863 dnl specified: 9864 _LT_UNLESS_OPTIONS([LT_INIT], [dlopen], [enable_dlopen=no 9865 ]) 9866 _LT_UNLESS_OPTIONS([LT_INIT], [win32-dll], [enable_win32_dll=no 9867 ]) 9868 dnl 9869 dnl If no reference was made to various pairs of opposing options, then 9870 dnl we run the default mode handler for the pair. For example, if neither 9871 dnl `shared' nor `disable-shared' was passed, we enable building of shared 9872 dnl archives by default: 9873 _LT_UNLESS_OPTIONS([LT_INIT], [shared disable-shared], [_LT_ENABLE_SHARED]) 9874 _LT_UNLESS_OPTIONS([LT_INIT], [static disable-static], [_LT_ENABLE_STATIC]) 9875 _LT_UNLESS_OPTIONS([LT_INIT], [pic-only no-pic], [_LT_WITH_PIC]) 9876 _LT_UNLESS_OPTIONS([LT_INIT], [fast-install disable-fast-install], 9877 [_LT_ENABLE_FAST_INSTALL]) 9878 ]) 9879])# _LT_SET_OPTIONS 9880 9881 9882 9883# _LT_MANGLE_DEFUN(MACRO-NAME, OPTION-NAME) 9884# ----------------------------------------- 9885m4_define([_LT_MANGLE_DEFUN], 9886[[_LT_OPTION_DEFUN_]m4_bpatsubst(m4_toupper([$1__$2]), [[^A-Z0-9_]], [_])]) 9887 9888 9889# LT_OPTION_DEFINE(MACRO-NAME, OPTION-NAME, CODE) 9890# ----------------------------------------------- 9891m4_define([LT_OPTION_DEFINE], 9892[m4_define(_LT_MANGLE_DEFUN([$1], [$2]), [$3])[]dnl 9893])# LT_OPTION_DEFINE 9894 9895 9896# dlopen 9897# ------ 9898LT_OPTION_DEFINE([LT_INIT], [dlopen], [enable_dlopen=yes 9899]) 9900 9901AU_DEFUN([AC_LIBTOOL_DLOPEN], 9902[_LT_SET_OPTION([LT_INIT], [dlopen]) 9903AC_DIAGNOSE([obsolete], 9904[$0: Remove this warning and the call to _LT_SET_OPTION when you 9905put the `dlopen' option into LT_INIT's first parameter.]) 9906]) 9907 9908dnl aclocal-1.4 backwards compatibility: 9909dnl AC_DEFUN([AC_LIBTOOL_DLOPEN], []) 9910 9911 9912# win32-dll 9913# --------- 9914# Declare package support for building win32 dll's. 9915LT_OPTION_DEFINE([LT_INIT], [win32-dll], 9916[enable_win32_dll=yes 9917 9918case $host in 9919*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-cegcc*) 9920 AC_CHECK_TOOL(AS, as, false) 9921 AC_CHECK_TOOL(DLLTOOL, dlltool, false) 9922 AC_CHECK_TOOL(OBJDUMP, objdump, false) 9923 ;; 9924esac 9925 9926test -z "$AS" && AS=as 9927_LT_DECL([], [AS], [1], [Assembler program])dnl 9928 9929test -z "$DLLTOOL" && DLLTOOL=dlltool 9930_LT_DECL([], [DLLTOOL], [1], [DLL creation program])dnl 9931 9932test -z "$OBJDUMP" && OBJDUMP=objdump 9933_LT_DECL([], [OBJDUMP], [1], [Object dumper program])dnl 9934])# win32-dll 9935 9936AU_DEFUN([AC_LIBTOOL_WIN32_DLL], 9937[AC_REQUIRE([AC_CANONICAL_HOST])dnl 9938_LT_SET_OPTION([LT_INIT], [win32-dll]) 9939AC_DIAGNOSE([obsolete], 9940[$0: Remove this warning and the call to _LT_SET_OPTION when you 9941put the `win32-dll' option into LT_INIT's first parameter.]) 9942]) 9943 9944dnl aclocal-1.4 backwards compatibility: 9945dnl AC_DEFUN([AC_LIBTOOL_WIN32_DLL], []) 9946 9947 9948# _LT_ENABLE_SHARED([DEFAULT]) 9949# ---------------------------- 9950# implement the --enable-shared flag, and supports the `shared' and 9951# `disable-shared' LT_INIT options. 9952# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. 9953m4_define([_LT_ENABLE_SHARED], 9954[m4_define([_LT_ENABLE_SHARED_DEFAULT], [m4_if($1, no, no, yes)])dnl 9955AC_ARG_ENABLE([shared], 9956 [AS_HELP_STRING([--enable-shared@<:@=PKGS@:>@], 9957 [build shared libraries @<:@default=]_LT_ENABLE_SHARED_DEFAULT[@:>@])], 9958 [p=${PACKAGE-default} 9959 case $enableval in 9960 yes) enable_shared=yes ;; 9961 no) enable_shared=no ;; 9962 *) 9963 enable_shared=no 9964 # Look at the argument we got. We use all the common list separators. 9965 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," 9966 for pkg in $enableval; do 9967 IFS="$lt_save_ifs" 9968 if test "X$pkg" = "X$p"; then 9969 enable_shared=yes 9970 fi 9971 done 9972 IFS="$lt_save_ifs" 9973 ;; 9974 esac], 9975 [enable_shared=]_LT_ENABLE_SHARED_DEFAULT) 9976 9977 _LT_DECL([build_libtool_libs], [enable_shared], [0], 9978 [Whether or not to build shared libraries]) 9979])# _LT_ENABLE_SHARED 9980 9981LT_OPTION_DEFINE([LT_INIT], [shared], [_LT_ENABLE_SHARED([yes])]) 9982LT_OPTION_DEFINE([LT_INIT], [disable-shared], [_LT_ENABLE_SHARED([no])]) 9983 9984# Old names: 9985AC_DEFUN([AC_ENABLE_SHARED], 9986[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[shared]) 9987]) 9988 9989AC_DEFUN([AC_DISABLE_SHARED], 9990[_LT_SET_OPTION([LT_INIT], [disable-shared]) 9991]) 9992 9993AU_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)]) 9994AU_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)]) 9995 9996dnl aclocal-1.4 backwards compatibility: 9997dnl AC_DEFUN([AM_ENABLE_SHARED], []) 9998dnl AC_DEFUN([AM_DISABLE_SHARED], []) 9999 10000 10001 10002# _LT_ENABLE_STATIC([DEFAULT]) 10003# ---------------------------- 10004# implement the --enable-static flag, and support the `static' and 10005# `disable-static' LT_INIT options. 10006# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. 10007m4_define([_LT_ENABLE_STATIC], 10008[m4_define([_LT_ENABLE_STATIC_DEFAULT], [m4_if($1, no, no, yes)])dnl 10009AC_ARG_ENABLE([static], 10010 [AS_HELP_STRING([--enable-static@<:@=PKGS@:>@], 10011 [build static libraries @<:@default=]_LT_ENABLE_STATIC_DEFAULT[@:>@])], 10012 [p=${PACKAGE-default} 10013 case $enableval in 10014 yes) enable_static=yes ;; 10015 no) enable_static=no ;; 10016 *) 10017 enable_static=no 10018 # Look at the argument we got. We use all the common list separators. 10019 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," 10020 for pkg in $enableval; do 10021 IFS="$lt_save_ifs" 10022 if test "X$pkg" = "X$p"; then 10023 enable_static=yes 10024 fi 10025 done 10026 IFS="$lt_save_ifs" 10027 ;; 10028 esac], 10029 [enable_static=]_LT_ENABLE_STATIC_DEFAULT) 10030 10031 _LT_DECL([build_old_libs], [enable_static], [0], 10032 [Whether or not to build static libraries]) 10033])# _LT_ENABLE_STATIC 10034 10035LT_OPTION_DEFINE([LT_INIT], [static], [_LT_ENABLE_STATIC([yes])]) 10036LT_OPTION_DEFINE([LT_INIT], [disable-static], [_LT_ENABLE_STATIC([no])]) 10037 10038# Old names: 10039AC_DEFUN([AC_ENABLE_STATIC], 10040[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[static]) 10041]) 10042 10043AC_DEFUN([AC_DISABLE_STATIC], 10044[_LT_SET_OPTION([LT_INIT], [disable-static]) 10045]) 10046 10047AU_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)]) 10048AU_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)]) 10049 10050dnl aclocal-1.4 backwards compatibility: 10051dnl AC_DEFUN([AM_ENABLE_STATIC], []) 10052dnl AC_DEFUN([AM_DISABLE_STATIC], []) 10053 10054 10055 10056# _LT_ENABLE_FAST_INSTALL([DEFAULT]) 10057# ---------------------------------- 10058# implement the --enable-fast-install flag, and support the `fast-install' 10059# and `disable-fast-install' LT_INIT options. 10060# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. 10061m4_define([_LT_ENABLE_FAST_INSTALL], 10062[m4_define([_LT_ENABLE_FAST_INSTALL_DEFAULT], [m4_if($1, no, no, yes)])dnl 10063AC_ARG_ENABLE([fast-install], 10064 [AS_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@], 10065 [optimize for fast installation @<:@default=]_LT_ENABLE_FAST_INSTALL_DEFAULT[@:>@])], 10066 [p=${PACKAGE-default} 10067 case $enableval in 10068 yes) enable_fast_install=yes ;; 10069 no) enable_fast_install=no ;; 10070 *) 10071 enable_fast_install=no 10072 # Look at the argument we got. We use all the common list separators. 10073 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," 10074 for pkg in $enableval; do 10075 IFS="$lt_save_ifs" 10076 if test "X$pkg" = "X$p"; then 10077 enable_fast_install=yes 10078 fi 10079 done 10080 IFS="$lt_save_ifs" 10081 ;; 10082 esac], 10083 [enable_fast_install=]_LT_ENABLE_FAST_INSTALL_DEFAULT) 10084 10085_LT_DECL([fast_install], [enable_fast_install], [0], 10086 [Whether or not to optimize for fast installation])dnl 10087])# _LT_ENABLE_FAST_INSTALL 10088 10089LT_OPTION_DEFINE([LT_INIT], [fast-install], [_LT_ENABLE_FAST_INSTALL([yes])]) 10090LT_OPTION_DEFINE([LT_INIT], [disable-fast-install], [_LT_ENABLE_FAST_INSTALL([no])]) 10091 10092# Old names: 10093AU_DEFUN([AC_ENABLE_FAST_INSTALL], 10094[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[fast-install]) 10095AC_DIAGNOSE([obsolete], 10096[$0: Remove this warning and the call to _LT_SET_OPTION when you put 10097the `fast-install' option into LT_INIT's first parameter.]) 10098]) 10099 10100AU_DEFUN([AC_DISABLE_FAST_INSTALL], 10101[_LT_SET_OPTION([LT_INIT], [disable-fast-install]) 10102AC_DIAGNOSE([obsolete], 10103[$0: Remove this warning and the call to _LT_SET_OPTION when you put 10104the `disable-fast-install' option into LT_INIT's first parameter.]) 10105]) 10106 10107dnl aclocal-1.4 backwards compatibility: 10108dnl AC_DEFUN([AC_ENABLE_FAST_INSTALL], []) 10109dnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], []) 10110 10111 10112# _LT_WITH_PIC([MODE]) 10113# -------------------- 10114# implement the --with-pic flag, and support the `pic-only' and `no-pic' 10115# LT_INIT options. 10116# MODE is either `yes' or `no'. If omitted, it defaults to `both'. 10117m4_define([_LT_WITH_PIC], 10118[AC_ARG_WITH([pic], 10119 [AS_HELP_STRING([--with-pic], 10120 [try to use only PIC/non-PIC objects @<:@default=use both@:>@])], 10121 [pic_mode="$withval"], 10122 [pic_mode=default]) 10123 10124test -z "$pic_mode" && pic_mode=m4_default([$1], [default]) 10125 10126_LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl 10127])# _LT_WITH_PIC 10128 10129LT_OPTION_DEFINE([LT_INIT], [pic-only], [_LT_WITH_PIC([yes])]) 10130LT_OPTION_DEFINE([LT_INIT], [no-pic], [_LT_WITH_PIC([no])]) 10131 10132# Old name: 10133AU_DEFUN([AC_LIBTOOL_PICMODE], 10134[_LT_SET_OPTION([LT_INIT], [pic-only]) 10135AC_DIAGNOSE([obsolete], 10136[$0: Remove this warning and the call to _LT_SET_OPTION when you 10137put the `pic-only' option into LT_INIT's first parameter.]) 10138]) 10139 10140dnl aclocal-1.4 backwards compatibility: 10141dnl AC_DEFUN([AC_LIBTOOL_PICMODE], []) 10142 10143 10144m4_define([_LTDL_MODE], []) 10145LT_OPTION_DEFINE([LTDL_INIT], [nonrecursive], 10146 [m4_define([_LTDL_MODE], [nonrecursive])]) 10147LT_OPTION_DEFINE([LTDL_INIT], [recursive], 10148 [m4_define([_LTDL_MODE], [recursive])]) 10149LT_OPTION_DEFINE([LTDL_INIT], [subproject], 10150 [m4_define([_LTDL_MODE], [subproject])]) 10151 10152m4_define([_LTDL_TYPE], []) 10153LT_OPTION_DEFINE([LTDL_INIT], [installable], 10154 [m4_define([_LTDL_TYPE], [installable])]) 10155LT_OPTION_DEFINE([LTDL_INIT], [convenience], 10156 [m4_define([_LTDL_TYPE], [convenience])]) 10157 10158# ltsugar.m4 -- libtool m4 base layer. -*-Autoconf-*- 10159# 10160# Copyright (C) 2004, 2005, 2007, 2008 Free Software Foundation, Inc. 10161# Written by Gary V. Vaughan, 2004 10162# 10163# This file is free software; the Free Software Foundation gives 10164# unlimited permission to copy and/or distribute it, with or without 10165# modifications, as long as this notice is preserved. 10166 10167# serial 6 ltsugar.m4 10168 10169# This is to help aclocal find these macros, as it can't see m4_define. 10170AC_DEFUN([LTSUGAR_VERSION], [m4_if([0.1])]) 10171 10172 10173# lt_join(SEP, ARG1, [ARG2...]) 10174# ----------------------------- 10175# Produce ARG1SEPARG2...SEPARGn, omitting [] arguments and their 10176# associated separator. 10177# Needed until we can rely on m4_join from Autoconf 2.62, since all earlier 10178# versions in m4sugar had bugs. 10179m4_define([lt_join], 10180[m4_if([$#], [1], [], 10181 [$#], [2], [[$2]], 10182 [m4_if([$2], [], [], [[$2]_])$0([$1], m4_shift(m4_shift($@)))])]) 10183m4_define([_lt_join], 10184[m4_if([$#$2], [2], [], 10185 [m4_if([$2], [], [], [[$1$2]])$0([$1], m4_shift(m4_shift($@)))])]) 10186 10187 10188# lt_car(LIST) 10189# lt_cdr(LIST) 10190# ------------ 10191# Manipulate m4 lists. 10192# These macros are necessary as long as will still need to support 10193# Autoconf-2.59 which quotes differently. 10194m4_define([lt_car], [[$1]]) 10195m4_define([lt_cdr], 10196[m4_if([$#], 0, [m4_fatal([$0: cannot be called without arguments])], 10197 [$#], 1, [], 10198 [m4_dquote(m4_shift($@))])]) 10199m4_define([lt_unquote], $1) 10200 10201 10202# lt_append(MACRO-NAME, STRING, [SEPARATOR]) 10203# ------------------------------------------ 10204# Redefine MACRO-NAME to hold its former content plus `SEPARATOR'`STRING'. 10205# Note that neither SEPARATOR nor STRING are expanded; they are appended 10206# to MACRO-NAME as is (leaving the expansion for when MACRO-NAME is invoked). 10207# No SEPARATOR is output if MACRO-NAME was previously undefined (different 10208# than defined and empty). 10209# 10210# This macro is needed until we can rely on Autoconf 2.62, since earlier 10211# versions of m4sugar mistakenly expanded SEPARATOR but not STRING. 10212m4_define([lt_append], 10213[m4_define([$1], 10214 m4_ifdef([$1], [m4_defn([$1])[$3]])[$2])]) 10215 10216 10217 10218# lt_combine(SEP, PREFIX-LIST, INFIX, SUFFIX1, [SUFFIX2...]) 10219# ---------------------------------------------------------- 10220# Produce a SEP delimited list of all paired combinations of elements of 10221# PREFIX-LIST with SUFFIX1 through SUFFIXn. Each element of the list 10222# has the form PREFIXmINFIXSUFFIXn. 10223# Needed until we can rely on m4_combine added in Autoconf 2.62. 10224m4_define([lt_combine], 10225[m4_if(m4_eval([$# > 3]), [1], 10226 [m4_pushdef([_Lt_sep], [m4_define([_Lt_sep], m4_defn([lt_car]))])]]dnl 10227[[m4_foreach([_Lt_prefix], [$2], 10228 [m4_foreach([_Lt_suffix], 10229 ]m4_dquote(m4_dquote(m4_shift(m4_shift(m4_shift($@)))))[, 10230 [_Lt_sep([$1])[]m4_defn([_Lt_prefix])[$3]m4_defn([_Lt_suffix])])])])]) 10231 10232 10233# lt_if_append_uniq(MACRO-NAME, VARNAME, [SEPARATOR], [UNIQ], [NOT-UNIQ]) 10234# ----------------------------------------------------------------------- 10235# Iff MACRO-NAME does not yet contain VARNAME, then append it (delimited 10236# by SEPARATOR if supplied) and expand UNIQ, else NOT-UNIQ. 10237m4_define([lt_if_append_uniq], 10238[m4_ifdef([$1], 10239 [m4_if(m4_index([$3]m4_defn([$1])[$3], [$3$2$3]), [-1], 10240 [lt_append([$1], [$2], [$3])$4], 10241 [$5])], 10242 [lt_append([$1], [$2], [$3])$4])]) 10243 10244 10245# lt_dict_add(DICT, KEY, VALUE) 10246# ----------------------------- 10247m4_define([lt_dict_add], 10248[m4_define([$1($2)], [$3])]) 10249 10250 10251# lt_dict_add_subkey(DICT, KEY, SUBKEY, VALUE) 10252# -------------------------------------------- 10253m4_define([lt_dict_add_subkey], 10254[m4_define([$1($2:$3)], [$4])]) 10255 10256 10257# lt_dict_fetch(DICT, KEY, [SUBKEY]) 10258# ---------------------------------- 10259m4_define([lt_dict_fetch], 10260[m4_ifval([$3], 10261 m4_ifdef([$1($2:$3)], [m4_defn([$1($2:$3)])]), 10262 m4_ifdef([$1($2)], [m4_defn([$1($2)])]))]) 10263 10264 10265# lt_if_dict_fetch(DICT, KEY, [SUBKEY], VALUE, IF-TRUE, [IF-FALSE]) 10266# ----------------------------------------------------------------- 10267m4_define([lt_if_dict_fetch], 10268[m4_if(lt_dict_fetch([$1], [$2], [$3]), [$4], 10269 [$5], 10270 [$6])]) 10271 10272 10273# lt_dict_filter(DICT, [SUBKEY], VALUE, [SEPARATOR], KEY, [...]) 10274# -------------------------------------------------------------- 10275m4_define([lt_dict_filter], 10276[m4_if([$5], [], [], 10277 [lt_join(m4_quote(m4_default([$4], [[, ]])), 10278 lt_unquote(m4_split(m4_normalize(m4_foreach(_Lt_key, lt_car([m4_shiftn(4, $@)]), 10279 [lt_if_dict_fetch([$1], _Lt_key, [$2], [$3], [_Lt_key ])])))))])[]dnl 10280]) 10281 10282# ltversion.m4 -- version numbers -*- Autoconf -*- 10283# 10284# Copyright (C) 2004 Free Software Foundation, Inc. 10285# Written by Scott James Remnant, 2004 10286# 10287# This file is free software; the Free Software Foundation gives 10288# unlimited permission to copy and/or distribute it, with or without 10289# modifications, as long as this notice is preserved. 10290 10291# Generated from ltversion.in. 10292 10293# serial 3175 ltversion.m4 10294# This file is part of GNU Libtool 10295 10296m4_define([LT_PACKAGE_VERSION], [2.2.10]) 10297m4_define([LT_PACKAGE_REVISION], [1.3175]) 10298 10299AC_DEFUN([LTVERSION_VERSION], 10300[macro_version='2.2.10' 10301macro_revision='1.3175' 10302_LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?]) 10303_LT_DECL(, macro_revision, 0) 10304]) 10305 10306# lt~obsolete.m4 -- aclocal satisfying obsolete definitions. -*-Autoconf-*- 10307# 10308# Copyright (C) 2004, 2005, 2007, 2009 Free Software Foundation, Inc. 10309# Written by Scott James Remnant, 2004. 10310# 10311# This file is free software; the Free Software Foundation gives 10312# unlimited permission to copy and/or distribute it, with or without 10313# modifications, as long as this notice is preserved. 10314 10315# serial 5 lt~obsolete.m4 10316 10317# These exist entirely to fool aclocal when bootstrapping libtool. 10318# 10319# In the past libtool.m4 has provided macros via AC_DEFUN (or AU_DEFUN) 10320# which have later been changed to m4_define as they aren't part of the 10321# exported API, or moved to Autoconf or Automake where they belong. 10322# 10323# The trouble is, aclocal is a bit thick. It'll see the old AC_DEFUN 10324# in /usr/share/aclocal/libtool.m4 and remember it, then when it sees us 10325# using a macro with the same name in our local m4/libtool.m4 it'll 10326# pull the old libtool.m4 in (it doesn't see our shiny new m4_define 10327# and doesn't know about Autoconf macros at all.) 10328# 10329# So we provide this file, which has a silly filename so it's always 10330# included after everything else. This provides aclocal with the 10331# AC_DEFUNs it wants, but when m4 processes it, it doesn't do anything 10332# because those macros already exist, or will be overwritten later. 10333# We use AC_DEFUN over AU_DEFUN for compatibility with aclocal-1.6. 10334# 10335# Anytime we withdraw an AC_DEFUN or AU_DEFUN, remember to add it here. 10336# Yes, that means every name once taken will need to remain here until 10337# we give up compatibility with versions before 1.7, at which point 10338# we need to keep only those names which we still refer to. 10339 10340# This is to help aclocal find these macros, as it can't see m4_define. 10341AC_DEFUN([LTOBSOLETE_VERSION], [m4_if([1])]) 10342 10343m4_ifndef([AC_LIBTOOL_LINKER_OPTION], [AC_DEFUN([AC_LIBTOOL_LINKER_OPTION])]) 10344m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP])]) 10345m4_ifndef([_LT_AC_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH])]) 10346m4_ifndef([_LT_AC_SHELL_INIT], [AC_DEFUN([_LT_AC_SHELL_INIT])]) 10347m4_ifndef([_LT_AC_SYS_LIBPATH_AIX], [AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX])]) 10348m4_ifndef([_LT_PROG_LTMAIN], [AC_DEFUN([_LT_PROG_LTMAIN])]) 10349m4_ifndef([_LT_AC_TAGVAR], [AC_DEFUN([_LT_AC_TAGVAR])]) 10350m4_ifndef([AC_LTDL_ENABLE_INSTALL], [AC_DEFUN([AC_LTDL_ENABLE_INSTALL])]) 10351m4_ifndef([AC_LTDL_PREOPEN], [AC_DEFUN([AC_LTDL_PREOPEN])]) 10352m4_ifndef([_LT_AC_SYS_COMPILER], [AC_DEFUN([_LT_AC_SYS_COMPILER])]) 10353m4_ifndef([_LT_AC_LOCK], [AC_DEFUN([_LT_AC_LOCK])]) 10354m4_ifndef([AC_LIBTOOL_SYS_OLD_ARCHIVE], [AC_DEFUN([AC_LIBTOOL_SYS_OLD_ARCHIVE])]) 10355m4_ifndef([_LT_AC_TRY_DLOPEN_SELF], [AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF])]) 10356m4_ifndef([AC_LIBTOOL_PROG_CC_C_O], [AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O])]) 10357m4_ifndef([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], [AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS])]) 10358m4_ifndef([AC_LIBTOOL_OBJDIR], [AC_DEFUN([AC_LIBTOOL_OBJDIR])]) 10359m4_ifndef([AC_LTDL_OBJDIR], [AC_DEFUN([AC_LTDL_OBJDIR])]) 10360m4_ifndef([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], [AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH])]) 10361m4_ifndef([AC_LIBTOOL_SYS_LIB_STRIP], [AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP])]) 10362m4_ifndef([AC_PATH_MAGIC], [AC_DEFUN([AC_PATH_MAGIC])]) 10363m4_ifndef([AC_PROG_LD_GNU], [AC_DEFUN([AC_PROG_LD_GNU])]) 10364m4_ifndef([AC_PROG_LD_RELOAD_FLAG], [AC_DEFUN([AC_PROG_LD_RELOAD_FLAG])]) 10365m4_ifndef([AC_DEPLIBS_CHECK_METHOD], [AC_DEFUN([AC_DEPLIBS_CHECK_METHOD])]) 10366m4_ifndef([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI])]) 10367m4_ifndef([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], [AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE])]) 10368m4_ifndef([AC_LIBTOOL_PROG_COMPILER_PIC], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC])]) 10369m4_ifndef([AC_LIBTOOL_PROG_LD_SHLIBS], [AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS])]) 10370m4_ifndef([AC_LIBTOOL_POSTDEP_PREDEP], [AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP])]) 10371m4_ifndef([LT_AC_PROG_EGREP], [AC_DEFUN([LT_AC_PROG_EGREP])]) 10372m4_ifndef([LT_AC_PROG_SED], [AC_DEFUN([LT_AC_PROG_SED])]) 10373m4_ifndef([_LT_CC_BASENAME], [AC_DEFUN([_LT_CC_BASENAME])]) 10374m4_ifndef([_LT_COMPILER_BOILERPLATE], [AC_DEFUN([_LT_COMPILER_BOILERPLATE])]) 10375m4_ifndef([_LT_LINKER_BOILERPLATE], [AC_DEFUN([_LT_LINKER_BOILERPLATE])]) 10376m4_ifndef([_AC_PROG_LIBTOOL], [AC_DEFUN([_AC_PROG_LIBTOOL])]) 10377m4_ifndef([AC_LIBTOOL_SETUP], [AC_DEFUN([AC_LIBTOOL_SETUP])]) 10378m4_ifndef([_LT_AC_CHECK_DLFCN], [AC_DEFUN([_LT_AC_CHECK_DLFCN])]) 10379m4_ifndef([AC_LIBTOOL_SYS_DYNAMIC_LINKER], [AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER])]) 10380m4_ifndef([_LT_AC_TAGCONFIG], [AC_DEFUN([_LT_AC_TAGCONFIG])]) 10381m4_ifndef([AC_DISABLE_FAST_INSTALL], [AC_DEFUN([AC_DISABLE_FAST_INSTALL])]) 10382m4_ifndef([_LT_AC_LANG_CXX], [AC_DEFUN([_LT_AC_LANG_CXX])]) 10383m4_ifndef([_LT_AC_LANG_F77], [AC_DEFUN([_LT_AC_LANG_F77])]) 10384m4_ifndef([_LT_AC_LANG_GCJ], [AC_DEFUN([_LT_AC_LANG_GCJ])]) 10385m4_ifndef([AC_LIBTOOL_LANG_C_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG])]) 10386m4_ifndef([_LT_AC_LANG_C_CONFIG], [AC_DEFUN([_LT_AC_LANG_C_CONFIG])]) 10387m4_ifndef([AC_LIBTOOL_LANG_CXX_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG])]) 10388m4_ifndef([_LT_AC_LANG_CXX_CONFIG], [AC_DEFUN([_LT_AC_LANG_CXX_CONFIG])]) 10389m4_ifndef([AC_LIBTOOL_LANG_F77_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG])]) 10390m4_ifndef([_LT_AC_LANG_F77_CONFIG], [AC_DEFUN([_LT_AC_LANG_F77_CONFIG])]) 10391m4_ifndef([AC_LIBTOOL_LANG_GCJ_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG])]) 10392m4_ifndef([_LT_AC_LANG_GCJ_CONFIG], [AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG])]) 10393m4_ifndef([AC_LIBTOOL_LANG_RC_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG])]) 10394m4_ifndef([_LT_AC_LANG_RC_CONFIG], [AC_DEFUN([_LT_AC_LANG_RC_CONFIG])]) 10395m4_ifndef([AC_LIBTOOL_CONFIG], [AC_DEFUN([AC_LIBTOOL_CONFIG])]) 10396m4_ifndef([_LT_AC_FILE_LTDLL_C], [AC_DEFUN([_LT_AC_FILE_LTDLL_C])]) 10397m4_ifndef([_LT_REQUIRED_DARWIN_CHECKS], [AC_DEFUN([_LT_REQUIRED_DARWIN_CHECKS])]) 10398m4_ifndef([_LT_AC_PROG_CXXCPP], [AC_DEFUN([_LT_AC_PROG_CXXCPP])]) 10399m4_ifndef([_LT_PREPARE_SED_QUOTE_VARS], [AC_DEFUN([_LT_PREPARE_SED_QUOTE_VARS])]) 10400m4_ifndef([_LT_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_PROG_ECHO_BACKSLASH])]) 10401m4_ifndef([_LT_PROG_F77], [AC_DEFUN([_LT_PROG_F77])]) 10402m4_ifndef([_LT_PROG_FC], [AC_DEFUN([_LT_PROG_FC])]) 10403m4_ifndef([_LT_PROG_CXX], [AC_DEFUN([_LT_PROG_CXX])]) 10404 10405