aclocal.m4 revision d5c3dbf1
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# Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005 410# Free Software Foundation, Inc. 411# 412# This file is free software; the Free Software Foundation 413# gives unlimited permission to copy and/or distribute it, 414# with or without modifications, as long as this notice is preserved. 415 416# serial 8 417 418# AM_CONFIG_HEADER is obsolete. It has been replaced by AC_CONFIG_HEADERS. 419AU_DEFUN([AM_CONFIG_HEADER], [AC_CONFIG_HEADERS($@)]) 420 421# Do all the work for Automake. -*- Autoconf -*- 422 423# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 424# 2005, 2006, 2008, 2009 Free Software Foundation, Inc. 425# 426# This file is free software; the Free Software Foundation 427# gives unlimited permission to copy and/or distribute it, 428# with or without modifications, as long as this notice is preserved. 429 430# serial 16 431 432# This macro actually does too much. Some checks are only needed if 433# your package does certain things. But this isn't really a big deal. 434 435# AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE]) 436# AM_INIT_AUTOMAKE([OPTIONS]) 437# ----------------------------------------------- 438# The call with PACKAGE and VERSION arguments is the old style 439# call (pre autoconf-2.50), which is being phased out. PACKAGE 440# and VERSION should now be passed to AC_INIT and removed from 441# the call to AM_INIT_AUTOMAKE. 442# We support both call styles for the transition. After 443# the next Automake release, Autoconf can make the AC_INIT 444# arguments mandatory, and then we can depend on a new Autoconf 445# release and drop the old call support. 446AC_DEFUN([AM_INIT_AUTOMAKE], 447[AC_PREREQ([2.62])dnl 448dnl Autoconf wants to disallow AM_ names. We explicitly allow 449dnl the ones we care about. 450m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl 451AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl 452AC_REQUIRE([AC_PROG_INSTALL])dnl 453if test "`cd $srcdir && pwd`" != "`pwd`"; then 454 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output 455 # is not polluted with repeated "-I." 456 AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl 457 # test to see if srcdir already configured 458 if test -f $srcdir/config.status; then 459 AC_MSG_ERROR([source directory already configured; run "make distclean" there first]) 460 fi 461fi 462 463# test whether we have cygpath 464if test -z "$CYGPATH_W"; then 465 if (cygpath --version) >/dev/null 2>/dev/null; then 466 CYGPATH_W='cygpath -w' 467 else 468 CYGPATH_W=echo 469 fi 470fi 471AC_SUBST([CYGPATH_W]) 472 473# Define the identity of the package. 474dnl Distinguish between old-style and new-style calls. 475m4_ifval([$2], 476[m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl 477 AC_SUBST([PACKAGE], [$1])dnl 478 AC_SUBST([VERSION], [$2])], 479[_AM_SET_OPTIONS([$1])dnl 480dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT. 481m4_if(m4_ifdef([AC_PACKAGE_NAME], 1)m4_ifdef([AC_PACKAGE_VERSION], 1), 11,, 482 [m4_fatal([AC_INIT should be called with package and version arguments])])dnl 483 AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl 484 AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl 485 486_AM_IF_OPTION([no-define],, 487[AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package]) 488 AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl 489 490# Some tools Automake needs. 491AC_REQUIRE([AM_SANITY_CHECK])dnl 492AC_REQUIRE([AC_ARG_PROGRAM])dnl 493AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version}) 494AM_MISSING_PROG(AUTOCONF, autoconf) 495AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version}) 496AM_MISSING_PROG(AUTOHEADER, autoheader) 497AM_MISSING_PROG(MAKEINFO, makeinfo) 498AC_REQUIRE([AM_PROG_INSTALL_SH])dnl 499AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl 500AC_REQUIRE([AM_PROG_MKDIR_P])dnl 501# We need awk for the "check" target. The system "awk" is bad on 502# some platforms. 503AC_REQUIRE([AC_PROG_AWK])dnl 504AC_REQUIRE([AC_PROG_MAKE_SET])dnl 505AC_REQUIRE([AM_SET_LEADING_DOT])dnl 506_AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])], 507 [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])], 508 [_AM_PROG_TAR([v7])])]) 509_AM_IF_OPTION([no-dependencies],, 510[AC_PROVIDE_IFELSE([AC_PROG_CC], 511 [_AM_DEPENDENCIES(CC)], 512 [define([AC_PROG_CC], 513 defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl 514AC_PROVIDE_IFELSE([AC_PROG_CXX], 515 [_AM_DEPENDENCIES(CXX)], 516 [define([AC_PROG_CXX], 517 defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl 518AC_PROVIDE_IFELSE([AC_PROG_OBJC], 519 [_AM_DEPENDENCIES(OBJC)], 520 [define([AC_PROG_OBJC], 521 defn([AC_PROG_OBJC])[_AM_DEPENDENCIES(OBJC)])])dnl 522]) 523_AM_IF_OPTION([silent-rules], [AC_REQUIRE([AM_SILENT_RULES])])dnl 524dnl The `parallel-tests' driver may need to know about EXEEXT, so add the 525dnl `am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This macro 526dnl is hooked onto _AC_COMPILER_EXEEXT early, see below. 527AC_CONFIG_COMMANDS_PRE(dnl 528[m4_provide_if([_AM_COMPILER_EXEEXT], 529 [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl 530]) 531 532dnl Hook into `_AC_COMPILER_EXEEXT' early to learn its expansion. Do not 533dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further 534dnl mangled by Autoconf and run in a shell conditional statement. 535m4_define([_AC_COMPILER_EXEEXT], 536m4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])]) 537 538 539# When config.status generates a header, we must update the stamp-h file. 540# This file resides in the same directory as the config header 541# that is generated. The stamp files are numbered to have different names. 542 543# Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the 544# loop where config.status creates the headers, so we can generate 545# our stamp files there. 546AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK], 547[# Compute $1's index in $config_headers. 548_am_arg=$1 549_am_stamp_count=1 550for _am_header in $config_headers :; do 551 case $_am_header in 552 $_am_arg | $_am_arg:* ) 553 break ;; 554 * ) 555 _am_stamp_count=`expr $_am_stamp_count + 1` ;; 556 esac 557done 558echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count]) 559 560# Copyright (C) 2001, 2003, 2005, 2008 Free Software Foundation, Inc. 561# 562# This file is free software; the Free Software Foundation 563# gives unlimited permission to copy and/or distribute it, 564# with or without modifications, as long as this notice is preserved. 565 566# AM_PROG_INSTALL_SH 567# ------------------ 568# Define $install_sh. 569AC_DEFUN([AM_PROG_INSTALL_SH], 570[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl 571if test x"${install_sh}" != xset; then 572 case $am_aux_dir in 573 *\ * | *\ *) 574 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;; 575 *) 576 install_sh="\${SHELL} $am_aux_dir/install-sh" 577 esac 578fi 579AC_SUBST(install_sh)]) 580 581# Copyright (C) 2003, 2005 Free Software Foundation, Inc. 582# 583# This file is free software; the Free Software Foundation 584# gives unlimited permission to copy and/or distribute it, 585# with or without modifications, as long as this notice is preserved. 586 587# serial 2 588 589# Check whether the underlying file-system supports filenames 590# with a leading dot. For instance MS-DOS doesn't. 591AC_DEFUN([AM_SET_LEADING_DOT], 592[rm -rf .tst 2>/dev/null 593mkdir .tst 2>/dev/null 594if test -d .tst; then 595 am__leading_dot=. 596else 597 am__leading_dot=_ 598fi 599rmdir .tst 2>/dev/null 600AC_SUBST([am__leading_dot])]) 601 602# Add --enable-maintainer-mode option to configure. -*- Autoconf -*- 603# From Jim Meyering 604 605# Copyright (C) 1996, 1998, 2000, 2001, 2002, 2003, 2004, 2005, 2008 606# Free Software Foundation, Inc. 607# 608# This file is free software; the Free Software Foundation 609# gives unlimited permission to copy and/or distribute it, 610# with or without modifications, as long as this notice is preserved. 611 612# serial 5 613 614# AM_MAINTAINER_MODE([DEFAULT-MODE]) 615# ---------------------------------- 616# Control maintainer-specific portions of Makefiles. 617# Default is to disable them, unless `enable' is passed literally. 618# For symmetry, `disable' may be passed as well. Anyway, the user 619# can override the default with the --enable/--disable switch. 620AC_DEFUN([AM_MAINTAINER_MODE], 621[m4_case(m4_default([$1], [disable]), 622 [enable], [m4_define([am_maintainer_other], [disable])], 623 [disable], [m4_define([am_maintainer_other], [enable])], 624 [m4_define([am_maintainer_other], [enable]) 625 m4_warn([syntax], [unexpected argument to AM@&t@_MAINTAINER_MODE: $1])]) 626AC_MSG_CHECKING([whether to am_maintainer_other maintainer-specific portions of Makefiles]) 627 dnl maintainer-mode's default is 'disable' unless 'enable' is passed 628 AC_ARG_ENABLE([maintainer-mode], 629[ --][am_maintainer_other][-maintainer-mode am_maintainer_other make rules and dependencies not useful 630 (and sometimes confusing) to the casual installer], 631 [USE_MAINTAINER_MODE=$enableval], 632 [USE_MAINTAINER_MODE=]m4_if(am_maintainer_other, [enable], [no], [yes])) 633 AC_MSG_RESULT([$USE_MAINTAINER_MODE]) 634 AM_CONDITIONAL([MAINTAINER_MODE], [test $USE_MAINTAINER_MODE = yes]) 635 MAINT=$MAINTAINER_MODE_TRUE 636 AC_SUBST([MAINT])dnl 637] 638) 639 640AU_DEFUN([jm_MAINTAINER_MODE], [AM_MAINTAINER_MODE]) 641 642# Check to see how 'make' treats includes. -*- Autoconf -*- 643 644# Copyright (C) 2001, 2002, 2003, 2005, 2009 Free Software Foundation, Inc. 645# 646# This file is free software; the Free Software Foundation 647# gives unlimited permission to copy and/or distribute it, 648# with or without modifications, as long as this notice is preserved. 649 650# serial 4 651 652# AM_MAKE_INCLUDE() 653# ----------------- 654# Check to see how make treats includes. 655AC_DEFUN([AM_MAKE_INCLUDE], 656[am_make=${MAKE-make} 657cat > confinc << 'END' 658am__doit: 659 @echo this is the am__doit target 660.PHONY: am__doit 661END 662# If we don't find an include directive, just comment out the code. 663AC_MSG_CHECKING([for style of include used by $am_make]) 664am__include="#" 665am__quote= 666_am_result=none 667# First try GNU make style include. 668echo "include confinc" > confmf 669# Ignore all kinds of additional output from `make'. 670case `$am_make -s -f confmf 2> /dev/null` in #( 671*the\ am__doit\ target*) 672 am__include=include 673 am__quote= 674 _am_result=GNU 675 ;; 676esac 677# Now try BSD make style include. 678if test "$am__include" = "#"; then 679 echo '.include "confinc"' > confmf 680 case `$am_make -s -f confmf 2> /dev/null` in #( 681 *the\ am__doit\ target*) 682 am__include=.include 683 am__quote="\"" 684 _am_result=BSD 685 ;; 686 esac 687fi 688AC_SUBST([am__include]) 689AC_SUBST([am__quote]) 690AC_MSG_RESULT([$_am_result]) 691rm -f confinc confmf 692]) 693 694# Fake the existence of programs that GNU maintainers use. -*- Autoconf -*- 695 696# Copyright (C) 1997, 1999, 2000, 2001, 2003, 2004, 2005, 2008 697# Free Software Foundation, Inc. 698# 699# This file is free software; the Free Software Foundation 700# gives unlimited permission to copy and/or distribute it, 701# with or without modifications, as long as this notice is preserved. 702 703# serial 6 704 705# AM_MISSING_PROG(NAME, PROGRAM) 706# ------------------------------ 707AC_DEFUN([AM_MISSING_PROG], 708[AC_REQUIRE([AM_MISSING_HAS_RUN]) 709$1=${$1-"${am_missing_run}$2"} 710AC_SUBST($1)]) 711 712 713# AM_MISSING_HAS_RUN 714# ------------------ 715# Define MISSING if not defined so far and test if it supports --run. 716# If it does, set am_missing_run to use it, otherwise, to nothing. 717AC_DEFUN([AM_MISSING_HAS_RUN], 718[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl 719AC_REQUIRE_AUX_FILE([missing])dnl 720if test x"${MISSING+set}" != xset; then 721 case $am_aux_dir in 722 *\ * | *\ *) 723 MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;; 724 *) 725 MISSING="\${SHELL} $am_aux_dir/missing" ;; 726 esac 727fi 728# Use eval to expand $SHELL 729if eval "$MISSING --run true"; then 730 am_missing_run="$MISSING --run " 731else 732 am_missing_run= 733 AC_MSG_WARN([`missing' script is too old or missing]) 734fi 735]) 736 737# Copyright (C) 2003, 2004, 2005, 2006 Free Software Foundation, Inc. 738# 739# This file is free software; the Free Software Foundation 740# gives unlimited permission to copy and/or distribute it, 741# with or without modifications, as long as this notice is preserved. 742 743# AM_PROG_MKDIR_P 744# --------------- 745# Check for `mkdir -p'. 746AC_DEFUN([AM_PROG_MKDIR_P], 747[AC_PREREQ([2.60])dnl 748AC_REQUIRE([AC_PROG_MKDIR_P])dnl 749dnl Automake 1.8 to 1.9.6 used to define mkdir_p. We now use MKDIR_P, 750dnl while keeping a definition of mkdir_p for backward compatibility. 751dnl @MKDIR_P@ is magic: AC_OUTPUT adjusts its value for each Makefile. 752dnl However we cannot define mkdir_p as $(MKDIR_P) for the sake of 753dnl Makefile.ins that do not define MKDIR_P, so we do our own 754dnl adjustment using top_builddir (which is defined more often than 755dnl MKDIR_P). 756AC_SUBST([mkdir_p], ["$MKDIR_P"])dnl 757case $mkdir_p in 758 [[\\/$]]* | ?:[[\\/]]*) ;; 759 */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;; 760esac 761]) 762 763# Helper functions for option handling. -*- Autoconf -*- 764 765# Copyright (C) 2001, 2002, 2003, 2005, 2008 Free Software Foundation, Inc. 766# 767# This file is free software; the Free Software Foundation 768# gives unlimited permission to copy and/or distribute it, 769# with or without modifications, as long as this notice is preserved. 770 771# serial 4 772 773# _AM_MANGLE_OPTION(NAME) 774# ----------------------- 775AC_DEFUN([_AM_MANGLE_OPTION], 776[[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])]) 777 778# _AM_SET_OPTION(NAME) 779# ------------------------------ 780# Set option NAME. Presently that only means defining a flag for this option. 781AC_DEFUN([_AM_SET_OPTION], 782[m4_define(_AM_MANGLE_OPTION([$1]), 1)]) 783 784# _AM_SET_OPTIONS(OPTIONS) 785# ---------------------------------- 786# OPTIONS is a space-separated list of Automake options. 787AC_DEFUN([_AM_SET_OPTIONS], 788[m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])]) 789 790# _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET]) 791# ------------------------------------------- 792# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. 793AC_DEFUN([_AM_IF_OPTION], 794[m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])]) 795 796# Check to make sure that the build environment is sane. -*- Autoconf -*- 797 798# Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005, 2008 799# Free Software Foundation, Inc. 800# 801# This file is free software; the Free Software Foundation 802# gives unlimited permission to copy and/or distribute it, 803# with or without modifications, as long as this notice is preserved. 804 805# serial 5 806 807# AM_SANITY_CHECK 808# --------------- 809AC_DEFUN([AM_SANITY_CHECK], 810[AC_MSG_CHECKING([whether build environment is sane]) 811# Just in case 812sleep 1 813echo timestamp > conftest.file 814# Reject unsafe characters in $srcdir or the absolute working directory 815# name. Accept space and tab only in the latter. 816am_lf=' 817' 818case `pwd` in 819 *[[\\\"\#\$\&\'\`$am_lf]]*) 820 AC_MSG_ERROR([unsafe absolute working directory name]);; 821esac 822case $srcdir in 823 *[[\\\"\#\$\&\'\`$am_lf\ \ ]]*) 824 AC_MSG_ERROR([unsafe srcdir value: `$srcdir']);; 825esac 826 827# Do `set' in a subshell so we don't clobber the current shell's 828# arguments. Must try -L first in case configure is actually a 829# symlink; some systems play weird games with the mod time of symlinks 830# (eg FreeBSD returns the mod time of the symlink's containing 831# directory). 832if ( 833 set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` 834 if test "$[*]" = "X"; then 835 # -L didn't work. 836 set X `ls -t "$srcdir/configure" conftest.file` 837 fi 838 rm -f conftest.file 839 if test "$[*]" != "X $srcdir/configure conftest.file" \ 840 && test "$[*]" != "X conftest.file $srcdir/configure"; then 841 842 # If neither matched, then we have a broken ls. This can happen 843 # if, for instance, CONFIG_SHELL is bash and it inherits a 844 # broken ls alias from the environment. This has actually 845 # happened. Such a system could not be considered "sane". 846 AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken 847alias in your environment]) 848 fi 849 850 test "$[2]" = conftest.file 851 ) 852then 853 # Ok. 854 : 855else 856 AC_MSG_ERROR([newly created file is older than distributed files! 857Check your system clock]) 858fi 859AC_MSG_RESULT(yes)]) 860 861# Copyright (C) 2009 Free Software Foundation, Inc. 862# 863# This file is free software; the Free Software Foundation 864# gives unlimited permission to copy and/or distribute it, 865# with or without modifications, as long as this notice is preserved. 866 867# serial 1 868 869# AM_SILENT_RULES([DEFAULT]) 870# -------------------------- 871# Enable less verbose build rules; with the default set to DEFAULT 872# (`yes' being less verbose, `no' or empty being verbose). 873AC_DEFUN([AM_SILENT_RULES], 874[AC_ARG_ENABLE([silent-rules], 875[ --enable-silent-rules less verbose build output (undo: `make V=1') 876 --disable-silent-rules verbose build output (undo: `make V=0')]) 877case $enable_silent_rules in 878yes) AM_DEFAULT_VERBOSITY=0;; 879no) AM_DEFAULT_VERBOSITY=1;; 880*) AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);; 881esac 882AC_SUBST([AM_DEFAULT_VERBOSITY])dnl 883AM_BACKSLASH='\' 884AC_SUBST([AM_BACKSLASH])dnl 885_AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl 886]) 887 888# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. 889# 890# This file is free software; the Free Software Foundation 891# gives unlimited permission to copy and/or distribute it, 892# with or without modifications, as long as this notice is preserved. 893 894# AM_PROG_INSTALL_STRIP 895# --------------------- 896# One issue with vendor `install' (even GNU) is that you can't 897# specify the program used to strip binaries. This is especially 898# annoying in cross-compiling environments, where the build's strip 899# is unlikely to handle the host's binaries. 900# Fortunately install-sh will honor a STRIPPROG variable, so we 901# always use install-sh in `make install-strip', and initialize 902# STRIPPROG with the value of the STRIP variable (set by the user). 903AC_DEFUN([AM_PROG_INSTALL_STRIP], 904[AC_REQUIRE([AM_PROG_INSTALL_SH])dnl 905# Installed binaries are usually stripped using `strip' when the user 906# run `make install-strip'. However `strip' might not be the right 907# tool to use in cross-compilation environments, therefore Automake 908# will honor the `STRIP' environment variable to overrule this program. 909dnl Don't test for $cross_compiling = yes, because it might be `maybe'. 910if test "$cross_compiling" != no; then 911 AC_CHECK_TOOL([STRIP], [strip], :) 912fi 913INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" 914AC_SUBST([INSTALL_STRIP_PROGRAM])]) 915 916# Copyright (C) 2006, 2008 Free Software Foundation, Inc. 917# 918# This file is free software; the Free Software Foundation 919# gives unlimited permission to copy and/or distribute it, 920# with or without modifications, as long as this notice is preserved. 921 922# serial 2 923 924# _AM_SUBST_NOTMAKE(VARIABLE) 925# --------------------------- 926# Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in. 927# This macro is traced by Automake. 928AC_DEFUN([_AM_SUBST_NOTMAKE]) 929 930# AM_SUBST_NOTMAKE(VARIABLE) 931# --------------------------- 932# Public sister of _AM_SUBST_NOTMAKE. 933AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)]) 934 935# Check how to create a tarball. -*- Autoconf -*- 936 937# Copyright (C) 2004, 2005 Free Software Foundation, Inc. 938# 939# This file is free software; the Free Software Foundation 940# gives unlimited permission to copy and/or distribute it, 941# with or without modifications, as long as this notice is preserved. 942 943# serial 2 944 945# _AM_PROG_TAR(FORMAT) 946# -------------------- 947# Check how to create a tarball in format FORMAT. 948# FORMAT should be one of `v7', `ustar', or `pax'. 949# 950# Substitute a variable $(am__tar) that is a command 951# writing to stdout a FORMAT-tarball containing the directory 952# $tardir. 953# tardir=directory && $(am__tar) > result.tar 954# 955# Substitute a variable $(am__untar) that extract such 956# a tarball read from stdin. 957# $(am__untar) < result.tar 958AC_DEFUN([_AM_PROG_TAR], 959[# Always define AMTAR for backward compatibility. 960AM_MISSING_PROG([AMTAR], [tar]) 961m4_if([$1], [v7], 962 [am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'], 963 [m4_case([$1], [ustar],, [pax],, 964 [m4_fatal([Unknown tar format])]) 965AC_MSG_CHECKING([how to create a $1 tar archive]) 966# Loop over all known methods to create a tar archive until one works. 967_am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none' 968_am_tools=${am_cv_prog_tar_$1-$_am_tools} 969# Do not fold the above two line into one, because Tru64 sh and 970# Solaris sh will not grok spaces in the rhs of `-'. 971for _am_tool in $_am_tools 972do 973 case $_am_tool in 974 gnutar) 975 for _am_tar in tar gnutar gtar; 976 do 977 AM_RUN_LOG([$_am_tar --version]) && break 978 done 979 am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"' 980 am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"' 981 am__untar="$_am_tar -xf -" 982 ;; 983 plaintar) 984 # Must skip GNU tar: if it does not support --format= it doesn't create 985 # ustar tarball either. 986 (tar --version) >/dev/null 2>&1 && continue 987 am__tar='tar chf - "$$tardir"' 988 am__tar_='tar chf - "$tardir"' 989 am__untar='tar xf -' 990 ;; 991 pax) 992 am__tar='pax -L -x $1 -w "$$tardir"' 993 am__tar_='pax -L -x $1 -w "$tardir"' 994 am__untar='pax -r' 995 ;; 996 cpio) 997 am__tar='find "$$tardir" -print | cpio -o -H $1 -L' 998 am__tar_='find "$tardir" -print | cpio -o -H $1 -L' 999 am__untar='cpio -i -H $1 -d' 1000 ;; 1001 none) 1002 am__tar=false 1003 am__tar_=false 1004 am__untar=false 1005 ;; 1006 esac 1007 1008 # If the value was cached, stop now. We just wanted to have am__tar 1009 # and am__untar set. 1010 test -n "${am_cv_prog_tar_$1}" && break 1011 1012 # tar/untar a dummy directory, and stop if the command works 1013 rm -rf conftest.dir 1014 mkdir conftest.dir 1015 echo GrepMe > conftest.dir/file 1016 AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar]) 1017 rm -rf conftest.dir 1018 if test -s conftest.tar; then 1019 AM_RUN_LOG([$am__untar <conftest.tar]) 1020 grep GrepMe conftest.dir/file >/dev/null 2>&1 && break 1021 fi 1022done 1023rm -rf conftest.dir 1024 1025AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool]) 1026AC_MSG_RESULT([$am_cv_prog_tar_$1])]) 1027AC_SUBST([am__tar]) 1028AC_SUBST([am__untar]) 1029]) # _AM_PROG_TAR 1030 1031dnl xorg-macros.m4. Generated from xorg-macros.m4.in xorgversion.m4 by configure. 1032dnl 1033dnl Copyright (c) 2005, 2006, Oracle and/or its affiliates. All rights reserved. 1034dnl 1035dnl Permission is hereby granted, free of charge, to any person obtaining a 1036dnl copy of this software and associated documentation files (the "Software"), 1037dnl to deal in the Software without restriction, including without limitation 1038dnl the rights to use, copy, modify, merge, publish, distribute, sublicense, 1039dnl and/or sell copies of the Software, and to permit persons to whom the 1040dnl Software is furnished to do so, subject to the following conditions: 1041dnl 1042dnl The above copyright notice and this permission notice (including the next 1043dnl paragraph) shall be included in all copies or substantial portions of the 1044dnl Software. 1045dnl 1046dnl THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 1047dnl IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 1048dnl FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL 1049dnl THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 1050dnl LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 1051dnl FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER 1052dnl DEALINGS IN THE SOFTWARE. 1053 1054# XORG_MACROS_VERSION(required-version) 1055# ------------------------------------- 1056# Minimum version: 1.1.0 1057# 1058# If you're using a macro added in Version 1.1 or newer, include this in 1059# your configure.ac with the minimum required version, such as: 1060# XORG_MACROS_VERSION(1.1) 1061# 1062# To ensure that this macro is defined, also add: 1063# m4_ifndef([XORG_MACROS_VERSION], 1064# [m4_fatal([must install xorg-macros 1.1 or later before running autoconf/autogen])]) 1065# 1066# 1067# See the "minimum version" comment for each macro you use to see what 1068# version you require. 1069m4_defun([XORG_MACROS_VERSION],[ 1070m4_define([vers_have], [1.10.1]) 1071m4_define([maj_have], m4_substr(vers_have, 0, m4_index(vers_have, [.]))) 1072m4_define([maj_needed], m4_substr([$1], 0, m4_index([$1], [.]))) 1073m4_if(m4_cmp(maj_have, maj_needed), 0,, 1074 [m4_fatal([xorg-macros major version ]maj_needed[ is required but ]vers_have[ found])]) 1075m4_if(m4_version_compare(vers_have, [$1]), -1, 1076 [m4_fatal([xorg-macros version $1 or higher is required but ]vers_have[ found])]) 1077m4_undefine([vers_have]) 1078m4_undefine([maj_have]) 1079m4_undefine([maj_needed]) 1080]) # XORG_MACROS_VERSION 1081 1082# XORG_PROG_RAWCPP() 1083# ------------------ 1084# Minimum version: 1.0.0 1085# 1086# Find cpp program and necessary flags for use in pre-processing text files 1087# such as man pages and config files 1088AC_DEFUN([XORG_PROG_RAWCPP],[ 1089AC_REQUIRE([AC_PROG_CPP]) 1090AC_PATH_PROGS(RAWCPP, [cpp], [${CPP}], 1091 [$PATH:/bin:/usr/bin:/usr/lib:/usr/libexec:/usr/ccs/lib:/usr/ccs/lbin:/lib]) 1092 1093# Check for flag to avoid builtin definitions - assumes unix is predefined, 1094# which is not the best choice for supporting other OS'es, but covers most 1095# of the ones we need for now. 1096AC_MSG_CHECKING([if $RAWCPP requires -undef]) 1097AC_LANG_CONFTEST([Does cpp redefine unix ?]) 1098if test `${RAWCPP} < conftest.$ac_ext | grep -c 'unix'` -eq 1 ; then 1099 AC_MSG_RESULT([no]) 1100else 1101 if test `${RAWCPP} -undef < conftest.$ac_ext | grep -c 'unix'` -eq 1 ; then 1102 RAWCPPFLAGS=-undef 1103 AC_MSG_RESULT([yes]) 1104 # under Cygwin unix is still defined even with -undef 1105 elif test `${RAWCPP} -undef -ansi < conftest.$ac_ext | grep -c 'unix'` -eq 1 ; then 1106 RAWCPPFLAGS="-undef -ansi" 1107 AC_MSG_RESULT([yes, with -ansi]) 1108 else 1109 AC_MSG_ERROR([${RAWCPP} defines unix with or without -undef. I don't know what to do.]) 1110 fi 1111fi 1112rm -f conftest.$ac_ext 1113 1114AC_MSG_CHECKING([if $RAWCPP requires -traditional]) 1115AC_LANG_CONFTEST([Does cpp preserve "whitespace"?]) 1116if test `${RAWCPP} < conftest.$ac_ext | grep -c 'preserve \"'` -eq 1 ; then 1117 AC_MSG_RESULT([no]) 1118else 1119 if test `${RAWCPP} -traditional < conftest.$ac_ext | grep -c 'preserve \"'` -eq 1 ; then 1120 RAWCPPFLAGS="${RAWCPPFLAGS} -traditional" 1121 AC_MSG_RESULT([yes]) 1122 else 1123 AC_MSG_ERROR([${RAWCPP} does not preserve whitespace with or without -traditional. I don't know what to do.]) 1124 fi 1125fi 1126rm -f conftest.$ac_ext 1127AC_SUBST(RAWCPPFLAGS) 1128]) # XORG_PROG_RAWCPP 1129 1130# XORG_MANPAGE_SECTIONS() 1131# ----------------------- 1132# Minimum version: 1.0.0 1133# 1134# Determine which sections man pages go in for the different man page types 1135# on this OS - replaces *ManSuffix settings in old Imake *.cf per-os files. 1136# Not sure if there's any better way than just hardcoding by OS name. 1137# Override default settings by setting environment variables 1138# Added MAN_SUBSTS in version 1.8 1139# Added AC_PROG_SED in version 1.8 1140 1141AC_DEFUN([XORG_MANPAGE_SECTIONS],[ 1142AC_REQUIRE([AC_CANONICAL_HOST]) 1143AC_REQUIRE([AC_PROG_SED]) 1144 1145if test x$APP_MAN_SUFFIX = x ; then 1146 APP_MAN_SUFFIX=1 1147fi 1148if test x$APP_MAN_DIR = x ; then 1149 APP_MAN_DIR='$(mandir)/man$(APP_MAN_SUFFIX)' 1150fi 1151 1152if test x$LIB_MAN_SUFFIX = x ; then 1153 LIB_MAN_SUFFIX=3 1154fi 1155if test x$LIB_MAN_DIR = x ; then 1156 LIB_MAN_DIR='$(mandir)/man$(LIB_MAN_SUFFIX)' 1157fi 1158 1159if test x$FILE_MAN_SUFFIX = x ; then 1160 case $host_os in 1161 solaris*) FILE_MAN_SUFFIX=4 ;; 1162 *) FILE_MAN_SUFFIX=5 ;; 1163 esac 1164fi 1165if test x$FILE_MAN_DIR = x ; then 1166 FILE_MAN_DIR='$(mandir)/man$(FILE_MAN_SUFFIX)' 1167fi 1168 1169if test x$MISC_MAN_SUFFIX = x ; then 1170 case $host_os in 1171 solaris*) MISC_MAN_SUFFIX=5 ;; 1172 *) MISC_MAN_SUFFIX=7 ;; 1173 esac 1174fi 1175if test x$MISC_MAN_DIR = x ; then 1176 MISC_MAN_DIR='$(mandir)/man$(MISC_MAN_SUFFIX)' 1177fi 1178 1179if test x$DRIVER_MAN_SUFFIX = x ; then 1180 case $host_os in 1181 solaris*) DRIVER_MAN_SUFFIX=7 ;; 1182 *) DRIVER_MAN_SUFFIX=4 ;; 1183 esac 1184fi 1185if test x$DRIVER_MAN_DIR = x ; then 1186 DRIVER_MAN_DIR='$(mandir)/man$(DRIVER_MAN_SUFFIX)' 1187fi 1188 1189if test x$ADMIN_MAN_SUFFIX = x ; then 1190 case $host_os in 1191 solaris*) ADMIN_MAN_SUFFIX=1m ;; 1192 *) ADMIN_MAN_SUFFIX=8 ;; 1193 esac 1194fi 1195if test x$ADMIN_MAN_DIR = x ; then 1196 ADMIN_MAN_DIR='$(mandir)/man$(ADMIN_MAN_SUFFIX)' 1197fi 1198 1199 1200AC_SUBST([APP_MAN_SUFFIX]) 1201AC_SUBST([LIB_MAN_SUFFIX]) 1202AC_SUBST([FILE_MAN_SUFFIX]) 1203AC_SUBST([MISC_MAN_SUFFIX]) 1204AC_SUBST([DRIVER_MAN_SUFFIX]) 1205AC_SUBST([ADMIN_MAN_SUFFIX]) 1206AC_SUBST([APP_MAN_DIR]) 1207AC_SUBST([LIB_MAN_DIR]) 1208AC_SUBST([FILE_MAN_DIR]) 1209AC_SUBST([MISC_MAN_DIR]) 1210AC_SUBST([DRIVER_MAN_DIR]) 1211AC_SUBST([ADMIN_MAN_DIR]) 1212 1213XORG_MAN_PAGE="X Version 11" 1214AC_SUBST([XORG_MAN_PAGE]) 1215MAN_SUBSTS="\ 1216 -e 's|__vendorversion__|\"\$(PACKAGE_STRING)\" \"\$(XORG_MAN_PAGE)\"|' \ 1217 -e 's|__xorgversion__|\"\$(PACKAGE_STRING)\" \"\$(XORG_MAN_PAGE)\"|' \ 1218 -e 's|__xservername__|Xorg|g' \ 1219 -e 's|__xconfigfile__|xorg.conf|g' \ 1220 -e 's|__projectroot__|\$(prefix)|g' \ 1221 -e 's|__apploaddir__|\$(appdefaultdir)|g' \ 1222 -e 's|__appmansuffix__|\$(APP_MAN_SUFFIX)|g' \ 1223 -e 's|__drivermansuffix__|\$(DRIVER_MAN_SUFFIX)|g' \ 1224 -e 's|__adminmansuffix__|\$(ADMIN_MAN_SUFFIX)|g' \ 1225 -e 's|__libmansuffix__|\$(LIB_MAN_SUFFIX)|g' \ 1226 -e 's|__miscmansuffix__|\$(MISC_MAN_SUFFIX)|g' \ 1227 -e 's|__filemansuffix__|\$(FILE_MAN_SUFFIX)|g'" 1228AC_SUBST([MAN_SUBSTS]) 1229 1230]) # XORG_MANPAGE_SECTIONS 1231 1232# XORG_CHECK_SGML_DOCTOOLS([MIN-VERSION]) 1233# ------------------------ 1234# Minimum version: 1.7.0 1235# 1236# Defines the variable XORG_SGML_PATH containing the location of X11/defs.ent 1237# provided by xorg-sgml-doctools, if installed. 1238AC_DEFUN([XORG_CHECK_SGML_DOCTOOLS],[ 1239AC_MSG_CHECKING([for X.Org SGML entities m4_ifval([$1],[>= $1])]) 1240XORG_SGML_PATH= 1241PKG_CHECK_EXISTS([xorg-sgml-doctools m4_ifval([$1],[>= $1])], 1242 [XORG_SGML_PATH=`$PKG_CONFIG --variable=sgmlrootdir xorg-sgml-doctools`], 1243 [m4_ifval([$1],[:], 1244 [if test x"$cross_compiling" != x"yes" ; then 1245 AC_CHECK_FILE([$prefix/share/sgml/X11/defs.ent], 1246 [XORG_SGML_PATH=$prefix/share/sgml]) 1247 fi]) 1248 ]) 1249 1250# Define variables STYLESHEET_SRCDIR and XSL_STYLESHEET containing 1251# the path and the name of the doc stylesheet 1252if test "x$XORG_SGML_PATH" != "x" ; then 1253 AC_MSG_RESULT([$XORG_SGML_PATH]) 1254 STYLESHEET_SRCDIR=$XORG_SGML_PATH/X11 1255 XSL_STYLESHEET=$STYLESHEET_SRCDIR/xorg.xsl 1256else 1257 AC_MSG_RESULT([no]) 1258fi 1259 1260AC_SUBST(XORG_SGML_PATH) 1261AC_SUBST(STYLESHEET_SRCDIR) 1262AC_SUBST(XSL_STYLESHEET) 1263AM_CONDITIONAL([HAVE_STYLESHEETS], [test "x$XSL_STYLESHEET" != "x"]) 1264]) # XORG_CHECK_SGML_DOCTOOLS 1265 1266# XORG_CHECK_LINUXDOC 1267# ------------------- 1268# Minimum version: 1.0.0 1269# 1270# Defines the variable MAKE_TEXT if the necessary tools and 1271# files are found. $(MAKE_TEXT) blah.sgml will then produce blah.txt. 1272# Whether or not the necessary tools and files are found can be checked 1273# with the AM_CONDITIONAL "BUILD_LINUXDOC" 1274AC_DEFUN([XORG_CHECK_LINUXDOC],[ 1275AC_REQUIRE([XORG_CHECK_SGML_DOCTOOLS]) 1276AC_REQUIRE([XORG_WITH_PS2PDF]) 1277 1278AC_PATH_PROG(LINUXDOC, linuxdoc) 1279 1280AC_MSG_CHECKING([whether to build documentation]) 1281 1282if test x$XORG_SGML_PATH != x && test x$LINUXDOC != x ; then 1283 BUILDDOC=yes 1284else 1285 BUILDDOC=no 1286fi 1287 1288AM_CONDITIONAL(BUILD_LINUXDOC, [test x$BUILDDOC = xyes]) 1289 1290AC_MSG_RESULT([$BUILDDOC]) 1291 1292AC_MSG_CHECKING([whether to build pdf documentation]) 1293 1294if test x$have_ps2pdf != xno && test x$BUILD_PDFDOC != xno; then 1295 BUILDPDFDOC=yes 1296else 1297 BUILDPDFDOC=no 1298fi 1299 1300AM_CONDITIONAL(BUILD_PDFDOC, [test x$BUILDPDFDOC = xyes]) 1301 1302AC_MSG_RESULT([$BUILDPDFDOC]) 1303 1304MAKE_TEXT="SGML_SEARCH_PATH=$XORG_SGML_PATH GROFF_NO_SGR=y $LINUXDOC -B txt -f" 1305MAKE_PS="SGML_SEARCH_PATH=$XORG_SGML_PATH $LINUXDOC -B latex --papersize=letter --output=ps" 1306MAKE_PDF="$PS2PDF" 1307MAKE_HTML="SGML_SEARCH_PATH=$XORG_SGML_PATH $LINUXDOC -B html --split=0" 1308 1309AC_SUBST(MAKE_TEXT) 1310AC_SUBST(MAKE_PS) 1311AC_SUBST(MAKE_PDF) 1312AC_SUBST(MAKE_HTML) 1313]) # XORG_CHECK_LINUXDOC 1314 1315# XORG_CHECK_DOCBOOK 1316# ------------------- 1317# Minimum version: 1.0.0 1318# 1319# Checks for the ability to build output formats from SGML DocBook source. 1320# For XXX in {TXT, PDF, PS, HTML}, the AM_CONDITIONAL "BUILD_XXXDOC" 1321# indicates whether the necessary tools and files are found and, if set, 1322# $(MAKE_XXX) blah.sgml will produce blah.xxx. 1323AC_DEFUN([XORG_CHECK_DOCBOOK],[ 1324AC_REQUIRE([XORG_CHECK_SGML_DOCTOOLS]) 1325 1326BUILDTXTDOC=no 1327BUILDPDFDOC=no 1328BUILDPSDOC=no 1329BUILDHTMLDOC=no 1330 1331AC_PATH_PROG(DOCBOOKPS, docbook2ps) 1332AC_PATH_PROG(DOCBOOKPDF, docbook2pdf) 1333AC_PATH_PROG(DOCBOOKHTML, docbook2html) 1334AC_PATH_PROG(DOCBOOKTXT, docbook2txt) 1335 1336AC_MSG_CHECKING([whether to build text documentation]) 1337if test x$XORG_SGML_PATH != x && test x$DOCBOOKTXT != x && 1338 test x$BUILD_TXTDOC != xno; then 1339 BUILDTXTDOC=yes 1340fi 1341AM_CONDITIONAL(BUILD_TXTDOC, [test x$BUILDTXTDOC = xyes]) 1342AC_MSG_RESULT([$BUILDTXTDOC]) 1343 1344AC_MSG_CHECKING([whether to build PDF documentation]) 1345if test x$XORG_SGML_PATH != x && test x$DOCBOOKPDF != x && 1346 test x$BUILD_PDFDOC != xno; then 1347 BUILDPDFDOC=yes 1348fi 1349AM_CONDITIONAL(BUILD_PDFDOC, [test x$BUILDPDFDOC = xyes]) 1350AC_MSG_RESULT([$BUILDPDFDOC]) 1351 1352AC_MSG_CHECKING([whether to build PostScript documentation]) 1353if test x$XORG_SGML_PATH != x && test x$DOCBOOKPS != x && 1354 test x$BUILD_PSDOC != xno; then 1355 BUILDPSDOC=yes 1356fi 1357AM_CONDITIONAL(BUILD_PSDOC, [test x$BUILDPSDOC = xyes]) 1358AC_MSG_RESULT([$BUILDPSDOC]) 1359 1360AC_MSG_CHECKING([whether to build HTML documentation]) 1361if test x$XORG_SGML_PATH != x && test x$DOCBOOKHTML != x && 1362 test x$BUILD_HTMLDOC != xno; then 1363 BUILDHTMLDOC=yes 1364fi 1365AM_CONDITIONAL(BUILD_HTMLDOC, [test x$BUILDHTMLDOC = xyes]) 1366AC_MSG_RESULT([$BUILDHTMLDOC]) 1367 1368MAKE_TEXT="SGML_SEARCH_PATH=$XORG_SGML_PATH $DOCBOOKTXT" 1369MAKE_PS="SGML_SEARCH_PATH=$XORG_SGML_PATH $DOCBOOKPS" 1370MAKE_PDF="SGML_SEARCH_PATH=$XORG_SGML_PATH $DOCBOOKPDF" 1371MAKE_HTML="SGML_SEARCH_PATH=$XORG_SGML_PATH $DOCBOOKHTML" 1372 1373AC_SUBST(MAKE_TEXT) 1374AC_SUBST(MAKE_PS) 1375AC_SUBST(MAKE_PDF) 1376AC_SUBST(MAKE_HTML) 1377]) # XORG_CHECK_DOCBOOK 1378 1379# XORG_WITH_XMLTO([MIN-VERSION], [DEFAULT]) 1380# ---------------- 1381# Minimum version: 1.5.0 1382# 1383# Documentation tools are not always available on all platforms and sometimes 1384# not at the appropriate level. This macro enables a module to test for the 1385# presence of the tool and obtain it's path in separate variables. Coupled with 1386# the --with-xmlto option, it allows maximum flexibilty in making decisions 1387# as whether or not to use the xmlto package. When DEFAULT is not specified, 1388# --with-xmlto assumes 'auto'. 1389# 1390# Interface to module: 1391# HAVE_XMLTO: used in makefiles to conditionally generate documentation 1392# XMLTO: returns the path of the xmlto program found 1393# returns the path set by the user in the environment 1394# --with-xmlto: 'yes' user instructs the module to use xmlto 1395# 'no' user instructs the module not to use xmlto 1396# 1397# Added in version 1.10.0 1398# HAVE_XMLTO_TEXT: used in makefiles to conditionally generate text documentation 1399# xmlto for text output requires either lynx, links, or w3m browsers 1400# 1401# If the user sets the value of XMLTO, AC_PATH_PROG skips testing the path. 1402# 1403AC_DEFUN([XORG_WITH_XMLTO],[ 1404AC_ARG_VAR([XMLTO], [Path to xmlto command]) 1405m4_define([_defopt], m4_default([$2], [auto])) 1406AC_ARG_WITH(xmlto, 1407 AS_HELP_STRING([--with-xmlto], 1408 [Use xmlto to regenerate documentation (default: ]_defopt[)]), 1409 [use_xmlto=$withval], [use_xmlto=]_defopt) 1410m4_undefine([_defopt]) 1411 1412if test "x$use_xmlto" = x"auto"; then 1413 AC_PATH_PROG([XMLTO], [xmlto]) 1414 if test "x$XMLTO" = "x"; then 1415 AC_MSG_WARN([xmlto not found - documentation targets will be skipped]) 1416 have_xmlto=no 1417 else 1418 have_xmlto=yes 1419 fi 1420elif test "x$use_xmlto" = x"yes" ; then 1421 AC_PATH_PROG([XMLTO], [xmlto]) 1422 if test "x$XMLTO" = "x"; then 1423 AC_MSG_ERROR([--with-xmlto=yes specified but xmlto not found in PATH]) 1424 fi 1425 have_xmlto=yes 1426elif test "x$use_xmlto" = x"no" ; then 1427 if test "x$XMLTO" != "x"; then 1428 AC_MSG_WARN([ignoring XMLTO environment variable since --with-xmlto=no was specified]) 1429 fi 1430 have_xmlto=no 1431else 1432 AC_MSG_ERROR([--with-xmlto expects 'yes' or 'no']) 1433fi 1434 1435# Test for a minimum version of xmlto, if provided. 1436m4_ifval([$1], 1437[if test "$have_xmlto" = yes; then 1438 # scrape the xmlto version 1439 AC_MSG_CHECKING([the xmlto version]) 1440 xmlto_version=`$XMLTO --version 2>/dev/null | cut -d' ' -f3` 1441 AC_MSG_RESULT([$xmlto_version]) 1442 AS_VERSION_COMPARE([$xmlto_version], [$1], 1443 [if test "x$use_xmlto" = xauto; then 1444 AC_MSG_WARN([xmlto version $xmlto_version found, but $1 needed]) 1445 have_xmlto=no 1446 else 1447 AC_MSG_ERROR([xmlto version $xmlto_version found, but $1 needed]) 1448 fi]) 1449fi]) 1450 1451# Test for the ability of xmlto to generate a text target 1452have_xmlto_text=no 1453cat > conftest.xml << "EOF" 1454EOF 1455AS_IF([test "$have_xmlto" = yes], 1456 [AS_IF([$XMLTO --skip-validation txt conftest.xml >/dev/null 2>&1], 1457 [have_xmlto_text=yes], 1458 [AC_MSG_WARN([xmlto cannot generate text format, this format skipped])])]) 1459rm -f conftest.xml 1460AM_CONDITIONAL([HAVE_XMLTO_TEXT], [test $have_xmlto_text = yes]) 1461AM_CONDITIONAL([HAVE_XMLTO], [test "$have_xmlto" = yes]) 1462]) # XORG_WITH_XMLTO 1463 1464# XORG_WITH_ASCIIDOC([MIN-VERSION], [DEFAULT]) 1465# ---------------- 1466# Minimum version: 1.5.0 1467# 1468# Documentation tools are not always available on all platforms and sometimes 1469# not at the appropriate level. This macro enables a module to test for the 1470# presence of the tool and obtain it's path in separate variables. Coupled with 1471# the --with-asciidoc option, it allows maximum flexibilty in making decisions 1472# as whether or not to use the asciidoc package. When DEFAULT is not specified, 1473# --with-asciidoc assumes 'auto'. 1474# 1475# Interface to module: 1476# HAVE_ASCIIDOC: used in makefiles to conditionally generate documentation 1477# ASCIIDOC: returns the path of the asciidoc program found 1478# returns the path set by the user in the environment 1479# --with-asciidoc: 'yes' user instructs the module to use asciidoc 1480# 'no' user instructs the module not to use asciidoc 1481# 1482# If the user sets the value of ASCIIDOC, AC_PATH_PROG skips testing the path. 1483# 1484AC_DEFUN([XORG_WITH_ASCIIDOC],[ 1485AC_ARG_VAR([ASCIIDOC], [Path to asciidoc command]) 1486m4_define([_defopt], m4_default([$2], [auto])) 1487AC_ARG_WITH(asciidoc, 1488 AS_HELP_STRING([--with-asciidoc], 1489 [Use asciidoc to regenerate documentation (default: ]_defopt[)]), 1490 [use_asciidoc=$withval], [use_asciidoc=]_defopt) 1491m4_undefine([_defopt]) 1492 1493if test "x$use_asciidoc" = x"auto"; then 1494 AC_PATH_PROG([ASCIIDOC], [asciidoc]) 1495 if test "x$ASCIIDOC" = "x"; then 1496 AC_MSG_WARN([asciidoc not found - documentation targets will be skipped]) 1497 have_asciidoc=no 1498 else 1499 have_asciidoc=yes 1500 fi 1501elif test "x$use_asciidoc" = x"yes" ; then 1502 AC_PATH_PROG([ASCIIDOC], [asciidoc]) 1503 if test "x$ASCIIDOC" = "x"; then 1504 AC_MSG_ERROR([--with-asciidoc=yes specified but asciidoc not found in PATH]) 1505 fi 1506 have_asciidoc=yes 1507elif test "x$use_asciidoc" = x"no" ; then 1508 if test "x$ASCIIDOC" != "x"; then 1509 AC_MSG_WARN([ignoring ASCIIDOC environment variable since --with-asciidoc=no was specified]) 1510 fi 1511 have_asciidoc=no 1512else 1513 AC_MSG_ERROR([--with-asciidoc expects 'yes' or 'no']) 1514fi 1515m4_ifval([$1], 1516[if test "$have_asciidoc" = yes; then 1517 # scrape the asciidoc version 1518 AC_MSG_CHECKING([the asciidoc version]) 1519 asciidoc_version=`$ASCIIDOC --version 2>/dev/null | cut -d' ' -f2` 1520 AC_MSG_RESULT([$asciidoc_version]) 1521 AS_VERSION_COMPARE([$asciidoc_version], [$1], 1522 [if test "x$use_asciidoc" = xauto; then 1523 AC_MSG_WARN([asciidoc version $asciidoc_version found, but $1 needed]) 1524 have_asciidoc=no 1525 else 1526 AC_MSG_ERROR([asciidoc version $asciidoc_version found, but $1 needed]) 1527 fi]) 1528fi]) 1529AM_CONDITIONAL([HAVE_ASCIIDOC], [test "$have_asciidoc" = yes]) 1530]) # XORG_WITH_ASCIIDOC 1531 1532# XORG_WITH_DOXYGEN([MIN-VERSION], [DEFAULT]) 1533# -------------------------------- 1534# Minimum version: 1.5.0 1535# 1536# Documentation tools are not always available on all platforms and sometimes 1537# not at the appropriate level. This macro enables a module to test for the 1538# presence of the tool and obtain it's path in separate variables. Coupled with 1539# the --with-doxygen option, it allows maximum flexibilty in making decisions 1540# as whether or not to use the doxygen package. When DEFAULT is not specified, 1541# --with-doxygen assumes 'auto'. 1542# 1543# Interface to module: 1544# HAVE_DOXYGEN: used in makefiles to conditionally generate documentation 1545# DOXYGEN: returns the path of the doxygen program found 1546# returns the path set by the user in the environment 1547# --with-doxygen: 'yes' user instructs the module to use doxygen 1548# 'no' user instructs the module not to use doxygen 1549# 1550# If the user sets the value of DOXYGEN, AC_PATH_PROG skips testing the path. 1551# 1552AC_DEFUN([XORG_WITH_DOXYGEN],[ 1553AC_ARG_VAR([DOXYGEN], [Path to doxygen command]) 1554m4_define([_defopt], m4_default([$2], [auto])) 1555AC_ARG_WITH(doxygen, 1556 AS_HELP_STRING([--with-doxygen], 1557 [Use doxygen to regenerate documentation (default: ]_defopt[)]), 1558 [use_doxygen=$withval], [use_doxygen=]_defopt) 1559m4_undefine([_defopt]) 1560 1561if test "x$use_doxygen" = x"auto"; then 1562 AC_PATH_PROG([DOXYGEN], [doxygen]) 1563 if test "x$DOXYGEN" = "x"; then 1564 AC_MSG_WARN([doxygen not found - documentation targets will be skipped]) 1565 have_doxygen=no 1566 else 1567 have_doxygen=yes 1568 fi 1569elif test "x$use_doxygen" = x"yes" ; then 1570 AC_PATH_PROG([DOXYGEN], [doxygen]) 1571 if test "x$DOXYGEN" = "x"; then 1572 AC_MSG_ERROR([--with-doxygen=yes specified but doxygen not found in PATH]) 1573 fi 1574 have_doxygen=yes 1575elif test "x$use_doxygen" = x"no" ; then 1576 if test "x$DOXYGEN" != "x"; then 1577 AC_MSG_WARN([ignoring DOXYGEN environment variable since --with-doxygen=no was specified]) 1578 fi 1579 have_doxygen=no 1580else 1581 AC_MSG_ERROR([--with-doxygen expects 'yes' or 'no']) 1582fi 1583m4_ifval([$1], 1584[if test "$have_doxygen" = yes; then 1585 # scrape the doxygen version 1586 AC_MSG_CHECKING([the doxygen version]) 1587 doxygen_version=`$DOXYGEN --version 2>/dev/null` 1588 AC_MSG_RESULT([$doxygen_version]) 1589 AS_VERSION_COMPARE([$doxygen_version], [$1], 1590 [if test "x$use_doxygen" = xauto; then 1591 AC_MSG_WARN([doxygen version $doxygen_version found, but $1 needed]) 1592 have_doxygen=no 1593 else 1594 AC_MSG_ERROR([doxygen version $doxygen_version found, but $1 needed]) 1595 fi]) 1596fi]) 1597AM_CONDITIONAL([HAVE_DOXYGEN], [test "$have_doxygen" = yes]) 1598]) # XORG_WITH_DOXYGEN 1599 1600# XORG_WITH_GROFF([DEFAULT]) 1601# ---------------- 1602# Minimum version: 1.6.0 1603# 1604# Documentation tools are not always available on all platforms and sometimes 1605# not at the appropriate level. This macro enables a module to test for the 1606# presence of the tool and obtain it's path in separate variables. Coupled with 1607# the --with-groff option, it allows maximum flexibilty in making decisions 1608# as whether or not to use the groff package. When DEFAULT is not specified, 1609# --with-groff assumes 'auto'. 1610# 1611# Interface to module: 1612# HAVE_GROFF: used in makefiles to conditionally generate documentation 1613# HAVE_GROFF_MM: the memorandum macros (-mm) package 1614# HAVE_GROFF_MS: the -ms macros package 1615# GROFF: returns the path of the groff program found 1616# returns the path set by the user in the environment 1617# --with-groff: 'yes' user instructs the module to use groff 1618# 'no' user instructs the module not to use groff 1619# 1620# Added in version 1.9.0: 1621# HAVE_GROFF_HTML: groff has dependencies to output HTML format: 1622# pnmcut pnmcrop pnmtopng pnmtops from the netpbm package. 1623# psselect from the psutils package. 1624# the ghostcript package. Refer to the grohtml man pages 1625# 1626# If the user sets the value of GROFF, AC_PATH_PROG skips testing the path. 1627# 1628# OS and distros often splits groff in a basic and full package, the former 1629# having the groff program and the later having devices, fonts and macros 1630# Checking for the groff executable is not enough. 1631# 1632# If macros are missing, we cannot assume that groff is useless, so we don't 1633# unset HAVE_GROFF or GROFF env variables. 1634# HAVE_GROFF_?? can never be true while HAVE_GROFF is false. 1635# 1636AC_DEFUN([XORG_WITH_GROFF],[ 1637AC_ARG_VAR([GROFF], [Path to groff command]) 1638m4_define([_defopt], m4_default([$1], [auto])) 1639AC_ARG_WITH(groff, 1640 AS_HELP_STRING([--with-groff], 1641 [Use groff to regenerate documentation (default: ]_defopt[)]), 1642 [use_groff=$withval], [use_groff=]_defopt) 1643m4_undefine([_defopt]) 1644 1645if test "x$use_groff" = x"auto"; then 1646 AC_PATH_PROG([GROFF], [groff]) 1647 if test "x$GROFF" = "x"; then 1648 AC_MSG_WARN([groff not found - documentation targets will be skipped]) 1649 have_groff=no 1650 else 1651 have_groff=yes 1652 fi 1653elif test "x$use_groff" = x"yes" ; then 1654 AC_PATH_PROG([GROFF], [groff]) 1655 if test "x$GROFF" = "x"; then 1656 AC_MSG_ERROR([--with-groff=yes specified but groff not found in PATH]) 1657 fi 1658 have_groff=yes 1659elif test "x$use_groff" = x"no" ; then 1660 if test "x$GROFF" != "x"; then 1661 AC_MSG_WARN([ignoring GROFF environment variable since --with-groff=no was specified]) 1662 fi 1663 have_groff=no 1664else 1665 AC_MSG_ERROR([--with-groff expects 'yes' or 'no']) 1666fi 1667 1668# We have groff, test for the presence of the macro packages 1669if test "x$have_groff" = x"yes"; then 1670 AC_MSG_CHECKING([for ${GROFF} -ms macros]) 1671 if ${GROFF} -ms -I. /dev/null >/dev/null 2>&1 ; then 1672 groff_ms_works=yes 1673 else 1674 groff_ms_works=no 1675 fi 1676 AC_MSG_RESULT([$groff_ms_works]) 1677 AC_MSG_CHECKING([for ${GROFF} -mm macros]) 1678 if ${GROFF} -mm -I. /dev/null >/dev/null 2>&1 ; then 1679 groff_mm_works=yes 1680 else 1681 groff_mm_works=no 1682 fi 1683 AC_MSG_RESULT([$groff_mm_works]) 1684fi 1685 1686# We have groff, test for HTML dependencies, one command per package 1687if test "x$have_groff" = x"yes"; then 1688 AC_PATH_PROGS(GS_PATH, [gs gswin32c]) 1689 AC_PATH_PROG(PNMTOPNG_PATH, [pnmtopng]) 1690 AC_PATH_PROG(PSSELECT_PATH, [psselect]) 1691 if test "x$GS_PATH" != "x" -a "x$PNMTOPNG_PATH" != "x" -a "x$PSSELECT_PATH" != "x"; then 1692 have_groff_html=yes 1693 else 1694 have_groff_html=no 1695 AC_MSG_WARN([grohtml dependencies not found - HTML Documentation skipped. Refer to grohtml man pages]) 1696 fi 1697fi 1698 1699# Set Automake conditionals for Makefiles 1700AM_CONDITIONAL([HAVE_GROFF], [test "$have_groff" = yes]) 1701AM_CONDITIONAL([HAVE_GROFF_MS], [test "$groff_ms_works" = yes]) 1702AM_CONDITIONAL([HAVE_GROFF_MM], [test "$groff_mm_works" = yes]) 1703AM_CONDITIONAL([HAVE_GROFF_HTML], [test "$have_groff_html" = yes]) 1704]) # XORG_WITH_GROFF 1705 1706# XORG_WITH_FOP([DEFAULT]) 1707# ---------------- 1708# Minimum version: 1.6.0 1709# 1710# Documentation tools are not always available on all platforms and sometimes 1711# not at the appropriate level. This macro enables a module to test for the 1712# presence of the tool and obtain it's path in separate variables. Coupled with 1713# the --with-fop option, it allows maximum flexibilty in making decisions 1714# as whether or not to use the fop package. When DEFAULT is not specified, 1715# --with-fop assumes 'auto'. 1716# 1717# Interface to module: 1718# HAVE_FOP: used in makefiles to conditionally generate documentation 1719# FOP: returns the path of the fop program found 1720# returns the path set by the user in the environment 1721# --with-fop: 'yes' user instructs the module to use fop 1722# 'no' user instructs the module not to use fop 1723# 1724# If the user sets the value of FOP, AC_PATH_PROG skips testing the path. 1725# 1726AC_DEFUN([XORG_WITH_FOP],[ 1727AC_ARG_VAR([FOP], [Path to fop command]) 1728m4_define([_defopt], m4_default([$1], [auto])) 1729AC_ARG_WITH(fop, 1730 AS_HELP_STRING([--with-fop], 1731 [Use fop to regenerate documentation (default: ]_defopt[)]), 1732 [use_fop=$withval], [use_fop=]_defopt) 1733m4_undefine([_defopt]) 1734 1735if test "x$use_fop" = x"auto"; then 1736 AC_PATH_PROG([FOP], [fop]) 1737 if test "x$FOP" = "x"; then 1738 AC_MSG_WARN([fop not found - documentation targets will be skipped]) 1739 have_fop=no 1740 else 1741 have_fop=yes 1742 fi 1743elif test "x$use_fop" = x"yes" ; then 1744 AC_PATH_PROG([FOP], [fop]) 1745 if test "x$FOP" = "x"; then 1746 AC_MSG_ERROR([--with-fop=yes specified but fop not found in PATH]) 1747 fi 1748 have_fop=yes 1749elif test "x$use_fop" = x"no" ; then 1750 if test "x$FOP" != "x"; then 1751 AC_MSG_WARN([ignoring FOP environment variable since --with-fop=no was specified]) 1752 fi 1753 have_fop=no 1754else 1755 AC_MSG_ERROR([--with-fop expects 'yes' or 'no']) 1756fi 1757AM_CONDITIONAL([HAVE_FOP], [test "$have_fop" = yes]) 1758]) # XORG_WITH_FOP 1759 1760# XORG_WITH_PS2PDF([DEFAULT]) 1761# ---------------- 1762# Minimum version: 1.6.0 1763# 1764# Documentation tools are not always available on all platforms and sometimes 1765# not at the appropriate level. This macro enables a module to test for the 1766# presence of the tool and obtain it's path in separate variables. Coupled with 1767# the --with-ps2pdf option, it allows maximum flexibilty in making decisions 1768# as whether or not to use the ps2pdf package. When DEFAULT is not specified, 1769# --with-ps2pdf assumes 'auto'. 1770# 1771# Interface to module: 1772# HAVE_PS2PDF: used in makefiles to conditionally generate documentation 1773# PS2PDF: returns the path of the ps2pdf program found 1774# returns the path set by the user in the environment 1775# --with-ps2pdf: 'yes' user instructs the module to use ps2pdf 1776# 'no' user instructs the module not to use ps2pdf 1777# 1778# If the user sets the value of PS2PDF, AC_PATH_PROG skips testing the path. 1779# 1780AC_DEFUN([XORG_WITH_PS2PDF],[ 1781AC_ARG_VAR([PS2PDF], [Path to ps2pdf command]) 1782m4_define([_defopt], m4_default([$1], [auto])) 1783AC_ARG_WITH(ps2pdf, 1784 AS_HELP_STRING([--with-ps2pdf], 1785 [Use ps2pdf to regenerate documentation (default: ]_defopt[)]), 1786 [use_ps2pdf=$withval], [use_ps2pdf=]_defopt) 1787m4_undefine([_defopt]) 1788 1789if test "x$use_ps2pdf" = x"auto"; then 1790 AC_PATH_PROG([PS2PDF], [ps2pdf]) 1791 if test "x$PS2PDF" = "x"; then 1792 AC_MSG_WARN([ps2pdf not found - documentation targets will be skipped]) 1793 have_ps2pdf=no 1794 else 1795 have_ps2pdf=yes 1796 fi 1797elif test "x$use_ps2pdf" = x"yes" ; then 1798 AC_PATH_PROG([PS2PDF], [ps2pdf]) 1799 if test "x$PS2PDF" = "x"; then 1800 AC_MSG_ERROR([--with-ps2pdf=yes specified but ps2pdf not found in PATH]) 1801 fi 1802 have_ps2pdf=yes 1803elif test "x$use_ps2pdf" = x"no" ; then 1804 if test "x$PS2PDF" != "x"; then 1805 AC_MSG_WARN([ignoring PS2PDF environment variable since --with-ps2pdf=no was specified]) 1806 fi 1807 have_ps2pdf=no 1808else 1809 AC_MSG_ERROR([--with-ps2pdf expects 'yes' or 'no']) 1810fi 1811AM_CONDITIONAL([HAVE_PS2PDF], [test "$have_ps2pdf" = yes]) 1812]) # XORG_WITH_PS2PDF 1813 1814# XORG_ENABLE_DOCS (enable_docs=yes) 1815# ---------------- 1816# Minimum version: 1.6.0 1817# 1818# Documentation tools are not always available on all platforms and sometimes 1819# not at the appropriate level. This macro enables a builder to skip all 1820# documentation targets except traditional man pages. 1821# Combined with the specific tool checking macros XORG_WITH_*, it provides 1822# maximum flexibilty in controlling documentation building. 1823# Refer to: 1824# XORG_WITH_XMLTO --with-xmlto 1825# XORG_WITH_ASCIIDOC --with-asciidoc 1826# XORG_WITH_DOXYGEN --with-doxygen 1827# XORG_WITH_FOP --with-fop 1828# XORG_WITH_GROFF --with-groff 1829# XORG_WITH_PS2PDF --with-ps2pdf 1830# 1831# Interface to module: 1832# ENABLE_DOCS: used in makefiles to conditionally generate documentation 1833# --enable-docs: 'yes' user instructs the module to generate docs 1834# 'no' user instructs the module not to generate docs 1835# parm1: specify the default value, yes or no. 1836# 1837AC_DEFUN([XORG_ENABLE_DOCS],[ 1838m4_define([default], m4_default([$1], [yes])) 1839AC_ARG_ENABLE(docs, 1840 AS_HELP_STRING([--enable-docs], 1841 [Enable building the documentation (default: ]default[)]), 1842 [build_docs=$enableval], [build_docs=]default) 1843m4_undefine([default]) 1844AM_CONDITIONAL(ENABLE_DOCS, [test x$build_docs = xyes]) 1845AC_MSG_CHECKING([whether to build documentation]) 1846AC_MSG_RESULT([$build_docs]) 1847]) # XORG_ENABLE_DOCS 1848 1849# XORG_ENABLE_DEVEL_DOCS (enable_devel_docs=yes) 1850# ---------------- 1851# Minimum version: 1.6.0 1852# 1853# This macro enables a builder to skip all developer documentation. 1854# Combined with the specific tool checking macros XORG_WITH_*, it provides 1855# maximum flexibilty in controlling documentation building. 1856# Refer to: 1857# XORG_WITH_XMLTO --with-xmlto 1858# XORG_WITH_ASCIIDOC --with-asciidoc 1859# XORG_WITH_DOXYGEN --with-doxygen 1860# XORG_WITH_FOP --with-fop 1861# XORG_WITH_GROFF --with-groff 1862# XORG_WITH_PS2PDF --with-ps2pdf 1863# 1864# Interface to module: 1865# ENABLE_DEVEL_DOCS: used in makefiles to conditionally generate developer docs 1866# --enable-devel-docs: 'yes' user instructs the module to generate developer docs 1867# 'no' user instructs the module not to generate developer docs 1868# parm1: specify the default value, yes or no. 1869# 1870AC_DEFUN([XORG_ENABLE_DEVEL_DOCS],[ 1871m4_define([devel_default], m4_default([$1], [yes])) 1872AC_ARG_ENABLE(devel-docs, 1873 AS_HELP_STRING([--enable-devel-docs], 1874 [Enable building the developer documentation (default: ]devel_default[)]), 1875 [build_devel_docs=$enableval], [build_devel_docs=]devel_default) 1876m4_undefine([devel_default]) 1877AM_CONDITIONAL(ENABLE_DEVEL_DOCS, [test x$build_devel_docs = xyes]) 1878AC_MSG_CHECKING([whether to build developer documentation]) 1879AC_MSG_RESULT([$build_devel_docs]) 1880]) # XORG_ENABLE_DEVEL_DOCS 1881 1882# XORG_ENABLE_SPECS (enable_specs=yes) 1883# ---------------- 1884# Minimum version: 1.6.0 1885# 1886# This macro enables a builder to skip all functional specification targets. 1887# Combined with the specific tool checking macros XORG_WITH_*, it provides 1888# maximum flexibilty in controlling documentation building. 1889# Refer to: 1890# XORG_WITH_XMLTO --with-xmlto 1891# XORG_WITH_ASCIIDOC --with-asciidoc 1892# XORG_WITH_DOXYGEN --with-doxygen 1893# XORG_WITH_FOP --with-fop 1894# XORG_WITH_GROFF --with-groff 1895# XORG_WITH_PS2PDF --with-ps2pdf 1896# 1897# Interface to module: 1898# ENABLE_SPECS: used in makefiles to conditionally generate specs 1899# --enable-specs: 'yes' user instructs the module to generate specs 1900# 'no' user instructs the module not to generate specs 1901# parm1: specify the default value, yes or no. 1902# 1903AC_DEFUN([XORG_ENABLE_SPECS],[ 1904m4_define([spec_default], m4_default([$1], [yes])) 1905AC_ARG_ENABLE(specs, 1906 AS_HELP_STRING([--enable-specs], 1907 [Enable building the specs (default: ]spec_default[)]), 1908 [build_specs=$enableval], [build_specs=]spec_default) 1909m4_undefine([spec_default]) 1910AM_CONDITIONAL(ENABLE_SPECS, [test x$build_specs = xyes]) 1911AC_MSG_CHECKING([whether to build functional specifications]) 1912AC_MSG_RESULT([$build_specs]) 1913]) # XORG_ENABLE_SPECS 1914 1915# XORG_CHECK_MALLOC_ZERO 1916# ---------------------- 1917# Minimum version: 1.0.0 1918# 1919# Defines {MALLOC,XMALLOC,XTMALLOC}_ZERO_CFLAGS appropriately if 1920# malloc(0) returns NULL. Packages should add one of these cflags to 1921# their AM_CFLAGS (or other appropriate *_CFLAGS) to use them. 1922AC_DEFUN([XORG_CHECK_MALLOC_ZERO],[ 1923AC_ARG_ENABLE(malloc0returnsnull, 1924 AS_HELP_STRING([--enable-malloc0returnsnull], 1925 [malloc(0) returns NULL (default: auto)]), 1926 [MALLOC_ZERO_RETURNS_NULL=$enableval], 1927 [MALLOC_ZERO_RETURNS_NULL=auto]) 1928 1929AC_MSG_CHECKING([whether malloc(0) returns NULL]) 1930if test "x$MALLOC_ZERO_RETURNS_NULL" = xauto; then 1931 AC_RUN_IFELSE([ 1932char *malloc(); 1933char *realloc(); 1934char *calloc(); 1935main() { 1936 char *m0, *r0, *c0, *p; 1937 m0 = malloc(0); 1938 p = malloc(10); 1939 r0 = realloc(p,0); 1940 c0 = calloc(0); 1941 exit(m0 == 0 || r0 == 0 || c0 == 0 ? 0 : 1); 1942}], 1943 [MALLOC_ZERO_RETURNS_NULL=yes], 1944 [MALLOC_ZERO_RETURNS_NULL=no], 1945 [MALLOC_ZERO_RETURNS_NULL=yes]) 1946fi 1947AC_MSG_RESULT([$MALLOC_ZERO_RETURNS_NULL]) 1948 1949if test "x$MALLOC_ZERO_RETURNS_NULL" = xyes; then 1950 MALLOC_ZERO_CFLAGS="-DMALLOC_0_RETURNS_NULL" 1951 XMALLOC_ZERO_CFLAGS=$MALLOC_ZERO_CFLAGS 1952 XTMALLOC_ZERO_CFLAGS="$MALLOC_ZERO_CFLAGS -DXTMALLOC_BC" 1953else 1954 MALLOC_ZERO_CFLAGS="" 1955 XMALLOC_ZERO_CFLAGS="" 1956 XTMALLOC_ZERO_CFLAGS="" 1957fi 1958 1959AC_SUBST([MALLOC_ZERO_CFLAGS]) 1960AC_SUBST([XMALLOC_ZERO_CFLAGS]) 1961AC_SUBST([XTMALLOC_ZERO_CFLAGS]) 1962]) # XORG_CHECK_MALLOC_ZERO 1963 1964# XORG_WITH_LINT() 1965# ---------------- 1966# Minimum version: 1.1.0 1967# 1968# This macro enables the use of a tool that flags some suspicious and 1969# non-portable constructs (likely to be bugs) in C language source code. 1970# It will attempt to locate the tool and use appropriate options. 1971# There are various lint type tools on different platforms. 1972# 1973# Interface to module: 1974# LINT: returns the path to the tool found on the platform 1975# or the value set to LINT on the configure cmd line 1976# also an Automake conditional 1977# LINT_FLAGS: an Automake variable with appropriate flags 1978# 1979# --with-lint: 'yes' user instructs the module to use lint 1980# 'no' user instructs the module not to use lint (default) 1981# 1982# If the user sets the value of LINT, AC_PATH_PROG skips testing the path. 1983# If the user sets the value of LINT_FLAGS, they are used verbatim. 1984# 1985AC_DEFUN([XORG_WITH_LINT],[ 1986 1987AC_ARG_VAR([LINT], [Path to a lint-style command]) 1988AC_ARG_VAR([LINT_FLAGS], [Flags for the lint-style command]) 1989AC_ARG_WITH(lint, [AS_HELP_STRING([--with-lint], 1990 [Use a lint-style source code checker (default: disabled)])], 1991 [use_lint=$withval], [use_lint=no]) 1992 1993# Obtain platform specific info like program name and options 1994# The lint program on FreeBSD and NetBSD is different from the one on Solaris 1995case $host_os in 1996 *linux* | *openbsd* | kfreebsd*-gnu | darwin* | cygwin*) 1997 lint_name=splint 1998 lint_options="-badflag" 1999 ;; 2000 *freebsd* | *netbsd*) 2001 lint_name=lint 2002 lint_options="-u -b" 2003 ;; 2004 *solaris*) 2005 lint_name=lint 2006 lint_options="-u -b -h -erroff=E_INDISTING_FROM_TRUNC2" 2007 ;; 2008esac 2009 2010# Test for the presence of the program (either guessed by the code or spelled out by the user) 2011if test "x$use_lint" = x"yes" ; then 2012 AC_PATH_PROG([LINT], [$lint_name]) 2013 if test "x$LINT" = "x"; then 2014 AC_MSG_ERROR([--with-lint=yes specified but lint-style tool not found in PATH]) 2015 fi 2016elif test "x$use_lint" = x"no" ; then 2017 if test "x$LINT" != "x"; then 2018 AC_MSG_WARN([ignoring LINT environment variable since --with-lint=no was specified]) 2019 fi 2020else 2021 AC_MSG_ERROR([--with-lint expects 'yes' or 'no'. Use LINT variable to specify path.]) 2022fi 2023 2024# User supplied flags override default flags 2025if test "x$LINT_FLAGS" != "x"; then 2026 lint_options=$LINT_FLAGS 2027fi 2028 2029AC_SUBST([LINT_FLAGS],[$lint_options]) 2030AM_CONDITIONAL(LINT, [test "x$LINT" != x]) 2031 2032]) # XORG_WITH_LINT 2033 2034# XORG_LINT_LIBRARY(LIBNAME) 2035# -------------------------- 2036# Minimum version: 1.1.0 2037# 2038# Sets up flags for building lint libraries for checking programs that call 2039# functions in the library. 2040# 2041# Interface to module: 2042# LINTLIB - Automake variable with the name of lint library file to make 2043# MAKE_LINT_LIB - Automake conditional 2044# 2045# --enable-lint-library: - 'yes' user instructs the module to created a lint library 2046# - 'no' user instructs the module not to create a lint library (default) 2047 2048AC_DEFUN([XORG_LINT_LIBRARY],[ 2049AC_REQUIRE([XORG_WITH_LINT]) 2050AC_ARG_ENABLE(lint-library, [AS_HELP_STRING([--enable-lint-library], 2051 [Create lint library (default: disabled)])], 2052 [make_lint_lib=$enableval], [make_lint_lib=no]) 2053 2054if test "x$make_lint_lib" = x"yes" ; then 2055 LINTLIB=llib-l$1.ln 2056 if test "x$LINT" = "x"; then 2057 AC_MSG_ERROR([Cannot make lint library without --with-lint]) 2058 fi 2059elif test "x$make_lint_lib" != x"no" ; then 2060 AC_MSG_ERROR([--enable-lint-library expects 'yes' or 'no'.]) 2061fi 2062 2063AC_SUBST(LINTLIB) 2064AM_CONDITIONAL(MAKE_LINT_LIB, [test x$make_lint_lib != xno]) 2065 2066]) # XORG_LINT_LIBRARY 2067 2068# XORG_CWARNFLAGS 2069# --------------- 2070# Minimum version: 1.2.0 2071# 2072# Defines CWARNFLAGS to enable C compiler warnings. 2073# 2074AC_DEFUN([XORG_CWARNFLAGS], [ 2075AC_REQUIRE([AC_PROG_CC_C99]) 2076if test "x$GCC" = xyes ; then 2077 CWARNFLAGS="-Wall -Wpointer-arith -Wstrict-prototypes -Wmissing-prototypes \ 2078-Wmissing-declarations -Wnested-externs -fno-strict-aliasing \ 2079-Wbad-function-cast -Wformat=2" 2080 case `$CC -dumpversion` in 2081 3.4.* | 4.*) 2082 CWARNFLAGS="$CWARNFLAGS -Wold-style-definition -Wdeclaration-after-statement" 2083 ;; 2084 esac 2085else 2086 AC_CHECK_DECL([__SUNPRO_C], [SUNCC="yes"], [SUNCC="no"]) 2087 if test "x$SUNCC" = "xyes"; then 2088 CWARNFLAGS="-v" 2089 fi 2090fi 2091AC_SUBST(CWARNFLAGS) 2092]) # XORG_CWARNFLAGS 2093 2094# XORG_STRICT_OPTION 2095# ----------------------- 2096# Minimum version: 1.3.0 2097# 2098# Add configure option to enable strict compilation 2099AC_DEFUN([XORG_STRICT_OPTION], [ 2100# If the module's configure.ac calls AC_PROG_CC later on, CC gets set to C89 2101AC_REQUIRE([AC_PROG_CC_C99]) 2102AC_REQUIRE([XORG_CWARNFLAGS]) 2103 2104AC_ARG_ENABLE(strict-compilation, 2105 AS_HELP_STRING([--enable-strict-compilation], 2106 [Enable all warnings from compiler and make them errors (default: disabled)]), 2107 [STRICT_COMPILE=$enableval], [STRICT_COMPILE=no]) 2108if test "x$STRICT_COMPILE" = "xyes"; then 2109 AC_CHECK_DECL([__SUNPRO_C], [SUNCC="yes"], [SUNCC="no"]) 2110 AC_CHECK_DECL([__INTEL_COMPILER], [INTELCC="yes"], [INTELCC="no"]) 2111 if test "x$GCC" = xyes ; then 2112 STRICT_CFLAGS="-pedantic -Werror" 2113 elif test "x$SUNCC" = "xyes"; then 2114 STRICT_CFLAGS="-errwarn" 2115 elif test "x$INTELCC" = "xyes"; then 2116 STRICT_CFLAGS="-Werror" 2117 fi 2118fi 2119CWARNFLAGS="$CWARNFLAGS $STRICT_CFLAGS" 2120AC_SUBST([CWARNFLAGS]) 2121]) # XORG_STRICT_OPTION 2122 2123# XORG_DEFAULT_OPTIONS 2124# -------------------- 2125# Minimum version: 1.3.0 2126# 2127# Defines default options for X.Org modules. 2128# 2129AC_DEFUN([XORG_DEFAULT_OPTIONS], [ 2130AC_REQUIRE([AC_PROG_INSTALL]) 2131XORG_CWARNFLAGS 2132XORG_STRICT_OPTION 2133XORG_RELEASE_VERSION 2134XORG_CHANGELOG 2135XORG_INSTALL 2136XORG_MANPAGE_SECTIONS 2137m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])], 2138 [AC_SUBST([AM_DEFAULT_VERBOSITY], [1])]) 2139]) # XORG_DEFAULT_OPTIONS 2140 2141# XORG_INSTALL() 2142# ---------------- 2143# Minimum version: 1.4.0 2144# 2145# Defines the variable INSTALL_CMD as the command to copy 2146# INSTALL from $prefix/share/util-macros. 2147# 2148AC_DEFUN([XORG_INSTALL], [ 2149AC_REQUIRE([PKG_PROG_PKG_CONFIG]) 2150macros_datadir=`$PKG_CONFIG --print-errors --variable=pkgdatadir xorg-macros` 2151INSTALL_CMD="(cp -f "$macros_datadir/INSTALL" \$(top_srcdir)/.INSTALL.tmp && \ 2152mv \$(top_srcdir)/.INSTALL.tmp \$(top_srcdir)/INSTALL) \ 2153|| (rm -f \$(top_srcdir)/.INSTALL.tmp; touch \$(top_srcdir)/INSTALL; \ 2154echo 'util-macros \"pkgdatadir\" from xorg-macros.pc not found: installing possibly empty INSTALL.' >&2)" 2155AC_SUBST([INSTALL_CMD]) 2156]) # XORG_INSTALL 2157dnl Copyright 2005 Red Hat, Inc 2158dnl 2159dnl Permission to use, copy, modify, distribute, and sell this software and its 2160dnl documentation for any purpose is hereby granted without fee, provided that 2161dnl the above copyright notice appear in all copies and that both that 2162dnl copyright notice and this permission notice appear in supporting 2163dnl documentation. 2164dnl 2165dnl The above copyright notice and this permission notice shall be included 2166dnl in all copies or substantial portions of the Software. 2167dnl 2168dnl THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS 2169dnl OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 2170dnl MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 2171dnl IN NO EVENT SHALL THE OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR 2172dnl OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, 2173dnl ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 2174dnl OTHER DEALINGS IN THE SOFTWARE. 2175dnl 2176dnl Except as contained in this notice, the name of the copyright holders shall 2177dnl not be used in advertising or otherwise to promote the sale, use or 2178dnl other dealings in this Software without prior written authorization 2179dnl from the copyright holders. 2180dnl 2181 2182# XORG_RELEASE_VERSION 2183# -------------------- 2184# Defines PACKAGE_VERSION_{MAJOR,MINOR,PATCHLEVEL} for modules to use. 2185 2186AC_DEFUN([XORG_RELEASE_VERSION],[ 2187 AC_DEFINE_UNQUOTED([PACKAGE_VERSION_MAJOR], 2188 [`echo $PACKAGE_VERSION | cut -d . -f 1`], 2189 [Major version of this package]) 2190 PVM=`echo $PACKAGE_VERSION | cut -d . -f 2 | cut -d - -f 1` 2191 if test "x$PVM" = "x"; then 2192 PVM="0" 2193 fi 2194 AC_DEFINE_UNQUOTED([PACKAGE_VERSION_MINOR], 2195 [$PVM], 2196 [Minor version of this package]) 2197 PVP=`echo $PACKAGE_VERSION | cut -d . -f 3 | cut -d - -f 1` 2198 if test "x$PVP" = "x"; then 2199 PVP="0" 2200 fi 2201 AC_DEFINE_UNQUOTED([PACKAGE_VERSION_PATCHLEVEL], 2202 [$PVP], 2203 [Patch version of this package]) 2204]) 2205 2206# XORG_CHANGELOG() 2207# ---------------- 2208# Minimum version: 1.2.0 2209# 2210# Defines the variable CHANGELOG_CMD as the command to generate 2211# ChangeLog from git. 2212# 2213# 2214AC_DEFUN([XORG_CHANGELOG], [ 2215CHANGELOG_CMD="(GIT_DIR=\$(top_srcdir)/.git git log > \$(top_srcdir)/.changelog.tmp && \ 2216mv \$(top_srcdir)/.changelog.tmp \$(top_srcdir)/ChangeLog) \ 2217|| (rm -f \$(top_srcdir)/.changelog.tmp; touch \$(top_srcdir)/ChangeLog; \ 2218echo 'git directory not found: installing possibly empty changelog.' >&2)" 2219AC_SUBST([CHANGELOG_CMD]) 2220]) # XORG_CHANGELOG 2221 2222# pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*- 2223# 2224# Copyright © 2004 Scott James Remnant <scott@netsplit.com>. 2225# 2226# This program is free software; you can redistribute it and/or modify 2227# it under the terms of the GNU General Public License as published by 2228# the Free Software Foundation; either version 2 of the License, or 2229# (at your option) any later version. 2230# 2231# This program is distributed in the hope that it will be useful, but 2232# WITHOUT ANY WARRANTY; without even the implied warranty of 2233# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 2234# General Public License for more details. 2235# 2236# You should have received a copy of the GNU General Public License 2237# along with this program; if not, write to the Free Software 2238# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 2239# 2240# As a special exception to the GNU General Public License, if you 2241# distribute this file as part of a program that contains a 2242# configuration script generated by Autoconf, you may include it under 2243# the same distribution terms that you use for the rest of that program. 2244 2245# PKG_PROG_PKG_CONFIG([MIN-VERSION]) 2246# ---------------------------------- 2247AC_DEFUN([PKG_PROG_PKG_CONFIG], 2248[m4_pattern_forbid([^_?PKG_[A-Z_]+$]) 2249m4_pattern_allow([^PKG_CONFIG(_PATH)?$]) 2250AC_ARG_VAR([PKG_CONFIG], [path to pkg-config utility])dnl 2251if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then 2252 AC_PATH_TOOL([PKG_CONFIG], [pkg-config]) 2253fi 2254if test -n "$PKG_CONFIG"; then 2255 _pkg_min_version=m4_default([$1], [0.9.0]) 2256 AC_MSG_CHECKING([pkg-config is at least version $_pkg_min_version]) 2257 if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then 2258 AC_MSG_RESULT([yes]) 2259 else 2260 AC_MSG_RESULT([no]) 2261 PKG_CONFIG="" 2262 fi 2263 2264fi[]dnl 2265])# PKG_PROG_PKG_CONFIG 2266 2267# PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) 2268# 2269# Check to see whether a particular set of modules exists. Similar 2270# to PKG_CHECK_MODULES(), but does not set variables or print errors. 2271# 2272# 2273# Similar to PKG_CHECK_MODULES, make sure that the first instance of 2274# this or PKG_CHECK_MODULES is called, or make sure to call 2275# PKG_CHECK_EXISTS manually 2276# -------------------------------------------------------------- 2277AC_DEFUN([PKG_CHECK_EXISTS], 2278[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl 2279if test -n "$PKG_CONFIG" && \ 2280 AC_RUN_LOG([$PKG_CONFIG --exists --print-errors "$1"]); then 2281 m4_ifval([$2], [$2], [:]) 2282m4_ifvaln([$3], [else 2283 $3])dnl 2284fi]) 2285 2286 2287# _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES]) 2288# --------------------------------------------- 2289m4_define([_PKG_CONFIG], 2290[if test -n "$$1"; then 2291 pkg_cv_[]$1="$$1" 2292 elif test -n "$PKG_CONFIG"; then 2293 PKG_CHECK_EXISTS([$3], 2294 [pkg_cv_[]$1=`$PKG_CONFIG --[]$2 "$3" 2>/dev/null`], 2295 [pkg_failed=yes]) 2296 else 2297 pkg_failed=untried 2298fi[]dnl 2299])# _PKG_CONFIG 2300 2301# _PKG_SHORT_ERRORS_SUPPORTED 2302# ----------------------------- 2303AC_DEFUN([_PKG_SHORT_ERRORS_SUPPORTED], 2304[AC_REQUIRE([PKG_PROG_PKG_CONFIG]) 2305if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 2306 _pkg_short_errors_supported=yes 2307else 2308 _pkg_short_errors_supported=no 2309fi[]dnl 2310])# _PKG_SHORT_ERRORS_SUPPORTED 2311 2312 2313# PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND], 2314# [ACTION-IF-NOT-FOUND]) 2315# 2316# 2317# Note that if there is a possibility the first call to 2318# PKG_CHECK_MODULES might not happen, you should be sure to include an 2319# explicit call to PKG_PROG_PKG_CONFIG in your configure.ac 2320# 2321# 2322# -------------------------------------------------------------- 2323AC_DEFUN([PKG_CHECK_MODULES], 2324[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl 2325AC_ARG_VAR([$1][_CFLAGS], [C compiler flags for $1, overriding pkg-config])dnl 2326AC_ARG_VAR([$1][_LIBS], [linker flags for $1, overriding pkg-config])dnl 2327 2328pkg_failed=no 2329AC_MSG_CHECKING([for $1]) 2330 2331_PKG_CONFIG([$1][_CFLAGS], [cflags], [$2]) 2332_PKG_CONFIG([$1][_LIBS], [libs], [$2]) 2333 2334m4_define([_PKG_TEXT], [Alternatively, you may set the environment variables $1[]_CFLAGS 2335and $1[]_LIBS to avoid the need to call pkg-config. 2336See the pkg-config man page for more details.]) 2337 2338if test $pkg_failed = yes; then 2339 _PKG_SHORT_ERRORS_SUPPORTED 2340 if test $_pkg_short_errors_supported = yes; then 2341 $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "$2" 2>&1` 2342 else 2343 $1[]_PKG_ERRORS=`$PKG_CONFIG --print-errors "$2" 2>&1` 2344 fi 2345 # Put the nasty error message in config.log where it belongs 2346 echo "$$1[]_PKG_ERRORS" >&AS_MESSAGE_LOG_FD 2347 2348 ifelse([$4], , [AC_MSG_ERROR(dnl 2349[Package requirements ($2) were not met: 2350 2351$$1_PKG_ERRORS 2352 2353Consider adjusting the PKG_CONFIG_PATH environment variable if you 2354installed software in a non-standard prefix. 2355 2356_PKG_TEXT 2357])], 2358 [AC_MSG_RESULT([no]) 2359 $4]) 2360elif test $pkg_failed = untried; then 2361 ifelse([$4], , [AC_MSG_FAILURE(dnl 2362[The pkg-config script could not be found or is too old. Make sure it 2363is in your PATH or set the PKG_CONFIG environment variable to the full 2364path to pkg-config. 2365 2366_PKG_TEXT 2367 2368To get pkg-config, see <http://pkg-config.freedesktop.org/>.])], 2369 [$4]) 2370else 2371 $1[]_CFLAGS=$pkg_cv_[]$1[]_CFLAGS 2372 $1[]_LIBS=$pkg_cv_[]$1[]_LIBS 2373 AC_MSG_RESULT([yes]) 2374 ifelse([$3], , :, [$3]) 2375fi[]dnl 2376])# PKG_CHECK_MODULES 2377 2378# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*- 2379# 2380# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 2381# 2006, 2007, 2008, 2009, 2010 Free Software Foundation, 2382# Inc. 2383# Written by Gordon Matzigkeit, 1996 2384# 2385# This file is free software; the Free Software Foundation gives 2386# unlimited permission to copy and/or distribute it, with or without 2387# modifications, as long as this notice is preserved. 2388 2389m4_define([_LT_COPYING], [dnl 2390# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 2391# 2006, 2007, 2008, 2009, 2010 Free Software Foundation, 2392# Inc. 2393# Written by Gordon Matzigkeit, 1996 2394# 2395# This file is part of GNU Libtool. 2396# 2397# GNU Libtool is free software; you can redistribute it and/or 2398# modify it under the terms of the GNU General Public License as 2399# published by the Free Software Foundation; either version 2 of 2400# the License, or (at your option) any later version. 2401# 2402# As a special exception to the GNU General Public License, 2403# if you distribute this file as part of a program or library that 2404# is built using GNU Libtool, you may include this file under the 2405# same distribution terms that you use for the rest of that program. 2406# 2407# GNU Libtool is distributed in the hope that it will be useful, 2408# but WITHOUT ANY WARRANTY; without even the implied warranty of 2409# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 2410# GNU General Public License for more details. 2411# 2412# You should have received a copy of the GNU General Public License 2413# along with GNU Libtool; see the file COPYING. If not, a copy 2414# can be downloaded from http://www.gnu.org/licenses/gpl.html, or 2415# obtained by writing to the Free Software Foundation, Inc., 2416# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 2417]) 2418 2419# serial 57 LT_INIT 2420 2421 2422# LT_PREREQ(VERSION) 2423# ------------------ 2424# Complain and exit if this libtool version is less that VERSION. 2425m4_defun([LT_PREREQ], 2426[m4_if(m4_version_compare(m4_defn([LT_PACKAGE_VERSION]), [$1]), -1, 2427 [m4_default([$3], 2428 [m4_fatal([Libtool version $1 or higher is required], 2429 63)])], 2430 [$2])]) 2431 2432 2433# _LT_CHECK_BUILDDIR 2434# ------------------ 2435# Complain if the absolute build directory name contains unusual characters 2436m4_defun([_LT_CHECK_BUILDDIR], 2437[case `pwd` in 2438 *\ * | *\ *) 2439 AC_MSG_WARN([Libtool does not cope well with whitespace in `pwd`]) ;; 2440esac 2441]) 2442 2443 2444# LT_INIT([OPTIONS]) 2445# ------------------ 2446AC_DEFUN([LT_INIT], 2447[AC_PREREQ([2.58])dnl We use AC_INCLUDES_DEFAULT 2448AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl 2449AC_BEFORE([$0], [LT_LANG])dnl 2450AC_BEFORE([$0], [LT_OUTPUT])dnl 2451AC_BEFORE([$0], [LTDL_INIT])dnl 2452m4_require([_LT_CHECK_BUILDDIR])dnl 2453 2454dnl Autoconf doesn't catch unexpanded LT_ macros by default: 2455m4_pattern_forbid([^_?LT_[A-Z_]+$])dnl 2456m4_pattern_allow([^(_LT_EOF|LT_DLGLOBAL|LT_DLLAZY_OR_NOW|LT_MULTI_MODULE)$])dnl 2457dnl aclocal doesn't pull ltoptions.m4, ltsugar.m4, or ltversion.m4 2458dnl unless we require an AC_DEFUNed macro: 2459AC_REQUIRE([LTOPTIONS_VERSION])dnl 2460AC_REQUIRE([LTSUGAR_VERSION])dnl 2461AC_REQUIRE([LTVERSION_VERSION])dnl 2462AC_REQUIRE([LTOBSOLETE_VERSION])dnl 2463m4_require([_LT_PROG_LTMAIN])dnl 2464 2465_LT_SHELL_INIT([SHELL=${CONFIG_SHELL-/bin/sh}]) 2466 2467dnl Parse OPTIONS 2468_LT_SET_OPTIONS([$0], [$1]) 2469 2470# This can be used to rebuild libtool when needed 2471LIBTOOL_DEPS="$ltmain" 2472 2473# Always use our own libtool. 2474LIBTOOL='$(SHELL) $(top_builddir)/libtool' 2475AC_SUBST(LIBTOOL)dnl 2476 2477_LT_SETUP 2478 2479# Only expand once: 2480m4_define([LT_INIT]) 2481])# LT_INIT 2482 2483# Old names: 2484AU_ALIAS([AC_PROG_LIBTOOL], [LT_INIT]) 2485AU_ALIAS([AM_PROG_LIBTOOL], [LT_INIT]) 2486dnl aclocal-1.4 backwards compatibility: 2487dnl AC_DEFUN([AC_PROG_LIBTOOL], []) 2488dnl AC_DEFUN([AM_PROG_LIBTOOL], []) 2489 2490 2491# _LT_CC_BASENAME(CC) 2492# ------------------- 2493# Calculate cc_basename. Skip known compiler wrappers and cross-prefix. 2494m4_defun([_LT_CC_BASENAME], 2495[for cc_temp in $1""; do 2496 case $cc_temp in 2497 compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;; 2498 distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;; 2499 \-*) ;; 2500 *) break;; 2501 esac 2502done 2503cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` 2504]) 2505 2506 2507# _LT_FILEUTILS_DEFAULTS 2508# ---------------------- 2509# It is okay to use these file commands and assume they have been set 2510# sensibly after `m4_require([_LT_FILEUTILS_DEFAULTS])'. 2511m4_defun([_LT_FILEUTILS_DEFAULTS], 2512[: ${CP="cp -f"} 2513: ${MV="mv -f"} 2514: ${RM="rm -f"} 2515])# _LT_FILEUTILS_DEFAULTS 2516 2517 2518# _LT_SETUP 2519# --------- 2520m4_defun([_LT_SETUP], 2521[AC_REQUIRE([AC_CANONICAL_HOST])dnl 2522AC_REQUIRE([AC_CANONICAL_BUILD])dnl 2523AC_REQUIRE([_LT_PREPARE_SED_QUOTE_VARS])dnl 2524AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl 2525 2526_LT_DECL([], [host_alias], [0], [The host system])dnl 2527_LT_DECL([], [host], [0])dnl 2528_LT_DECL([], [host_os], [0])dnl 2529dnl 2530_LT_DECL([], [build_alias], [0], [The build system])dnl 2531_LT_DECL([], [build], [0])dnl 2532_LT_DECL([], [build_os], [0])dnl 2533dnl 2534AC_REQUIRE([AC_PROG_CC])dnl 2535AC_REQUIRE([LT_PATH_LD])dnl 2536AC_REQUIRE([LT_PATH_NM])dnl 2537dnl 2538AC_REQUIRE([AC_PROG_LN_S])dnl 2539test -z "$LN_S" && LN_S="ln -s" 2540_LT_DECL([], [LN_S], [1], [Whether we need soft or hard links])dnl 2541dnl 2542AC_REQUIRE([LT_CMD_MAX_LEN])dnl 2543_LT_DECL([objext], [ac_objext], [0], [Object file suffix (normally "o")])dnl 2544_LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl 2545dnl 2546m4_require([_LT_FILEUTILS_DEFAULTS])dnl 2547m4_require([_LT_CHECK_SHELL_FEATURES])dnl 2548m4_require([_LT_CMD_RELOAD])dnl 2549m4_require([_LT_CHECK_MAGIC_METHOD])dnl 2550m4_require([_LT_CMD_OLD_ARCHIVE])dnl 2551m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl 2552 2553_LT_CONFIG_LIBTOOL_INIT([ 2554# See if we are running on zsh, and set the options which allow our 2555# commands through without removal of \ escapes INIT. 2556if test -n "\${ZSH_VERSION+set}" ; then 2557 setopt NO_GLOB_SUBST 2558fi 2559]) 2560if test -n "${ZSH_VERSION+set}" ; then 2561 setopt NO_GLOB_SUBST 2562fi 2563 2564_LT_CHECK_OBJDIR 2565 2566m4_require([_LT_TAG_COMPILER])dnl 2567 2568case $host_os in 2569aix3*) 2570 # AIX sometimes has problems with the GCC collect2 program. For some 2571 # reason, if we set the COLLECT_NAMES environment variable, the problems 2572 # vanish in a puff of smoke. 2573 if test "X${COLLECT_NAMES+set}" != Xset; then 2574 COLLECT_NAMES= 2575 export COLLECT_NAMES 2576 fi 2577 ;; 2578esac 2579 2580# Global variables: 2581ofile=libtool 2582can_build_shared=yes 2583 2584# All known linkers require a `.a' archive for static linking (except MSVC, 2585# which needs '.lib'). 2586libext=a 2587 2588with_gnu_ld="$lt_cv_prog_gnu_ld" 2589 2590old_CC="$CC" 2591old_CFLAGS="$CFLAGS" 2592 2593# Set sane defaults for various variables 2594test -z "$CC" && CC=cc 2595test -z "$LTCC" && LTCC=$CC 2596test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS 2597test -z "$LD" && LD=ld 2598test -z "$ac_objext" && ac_objext=o 2599 2600_LT_CC_BASENAME([$compiler]) 2601 2602# Only perform the check for file, if the check method requires it 2603test -z "$MAGIC_CMD" && MAGIC_CMD=file 2604case $deplibs_check_method in 2605file_magic*) 2606 if test "$file_magic_cmd" = '$MAGIC_CMD'; then 2607 _LT_PATH_MAGIC 2608 fi 2609 ;; 2610esac 2611 2612# Use C for the default configuration in the libtool script 2613LT_SUPPORTED_TAG([CC]) 2614_LT_LANG_C_CONFIG 2615_LT_LANG_DEFAULT_CONFIG 2616_LT_CONFIG_COMMANDS 2617])# _LT_SETUP 2618 2619 2620# _LT_PREPARE_SED_QUOTE_VARS 2621# -------------------------- 2622# Define a few sed substitution that help us do robust quoting. 2623m4_defun([_LT_PREPARE_SED_QUOTE_VARS], 2624[# Backslashify metacharacters that are still active within 2625# double-quoted strings. 2626sed_quote_subst='s/\([["`$\\]]\)/\\\1/g' 2627 2628# Same as above, but do not quote variable references. 2629double_quote_subst='s/\([["`\\]]\)/\\\1/g' 2630 2631# Sed substitution to delay expansion of an escaped shell variable in a 2632# double_quote_subst'ed string. 2633delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' 2634 2635# Sed substitution to delay expansion of an escaped single quote. 2636delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g' 2637 2638# Sed substitution to avoid accidental globbing in evaled expressions 2639no_glob_subst='s/\*/\\\*/g' 2640]) 2641 2642# _LT_PROG_LTMAIN 2643# --------------- 2644# Note that this code is called both from `configure', and `config.status' 2645# now that we use AC_CONFIG_COMMANDS to generate libtool. Notably, 2646# `config.status' has no value for ac_aux_dir unless we are using Automake, 2647# so we pass a copy along to make sure it has a sensible value anyway. 2648m4_defun([_LT_PROG_LTMAIN], 2649[m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl 2650_LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir']) 2651ltmain="$ac_aux_dir/ltmain.sh" 2652])# _LT_PROG_LTMAIN 2653 2654 2655 2656# So that we can recreate a full libtool script including additional 2657# tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS 2658# in macros and then make a single call at the end using the `libtool' 2659# label. 2660 2661 2662# _LT_CONFIG_LIBTOOL_INIT([INIT-COMMANDS]) 2663# ---------------------------------------- 2664# Register INIT-COMMANDS to be passed to AC_CONFIG_COMMANDS later. 2665m4_define([_LT_CONFIG_LIBTOOL_INIT], 2666[m4_ifval([$1], 2667 [m4_append([_LT_OUTPUT_LIBTOOL_INIT], 2668 [$1 2669])])]) 2670 2671# Initialize. 2672m4_define([_LT_OUTPUT_LIBTOOL_INIT]) 2673 2674 2675# _LT_CONFIG_LIBTOOL([COMMANDS]) 2676# ------------------------------ 2677# Register COMMANDS to be passed to AC_CONFIG_COMMANDS later. 2678m4_define([_LT_CONFIG_LIBTOOL], 2679[m4_ifval([$1], 2680 [m4_append([_LT_OUTPUT_LIBTOOL_COMMANDS], 2681 [$1 2682])])]) 2683 2684# Initialize. 2685m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS]) 2686 2687 2688# _LT_CONFIG_SAVE_COMMANDS([COMMANDS], [INIT_COMMANDS]) 2689# ----------------------------------------------------- 2690m4_defun([_LT_CONFIG_SAVE_COMMANDS], 2691[_LT_CONFIG_LIBTOOL([$1]) 2692_LT_CONFIG_LIBTOOL_INIT([$2]) 2693]) 2694 2695 2696# _LT_FORMAT_COMMENT([COMMENT]) 2697# ----------------------------- 2698# Add leading comment marks to the start of each line, and a trailing 2699# full-stop to the whole comment if one is not present already. 2700m4_define([_LT_FORMAT_COMMENT], 2701[m4_ifval([$1], [ 2702m4_bpatsubst([m4_bpatsubst([$1], [^ *], [# ])], 2703 [['`$\]], [\\\&])]m4_bmatch([$1], [[!?.]$], [], [.]) 2704)]) 2705 2706 2707 2708 2709 2710# _LT_DECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION], [IS-TAGGED?]) 2711# ------------------------------------------------------------------- 2712# CONFIGNAME is the name given to the value in the libtool script. 2713# VARNAME is the (base) name used in the configure script. 2714# VALUE may be 0, 1 or 2 for a computed quote escaped value based on 2715# VARNAME. Any other value will be used directly. 2716m4_define([_LT_DECL], 2717[lt_if_append_uniq([lt_decl_varnames], [$2], [, ], 2718 [lt_dict_add_subkey([lt_decl_dict], [$2], [libtool_name], 2719 [m4_ifval([$1], [$1], [$2])]) 2720 lt_dict_add_subkey([lt_decl_dict], [$2], [value], [$3]) 2721 m4_ifval([$4], 2722 [lt_dict_add_subkey([lt_decl_dict], [$2], [description], [$4])]) 2723 lt_dict_add_subkey([lt_decl_dict], [$2], 2724 [tagged?], [m4_ifval([$5], [yes], [no])])]) 2725]) 2726 2727 2728# _LT_TAGDECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION]) 2729# -------------------------------------------------------- 2730m4_define([_LT_TAGDECL], [_LT_DECL([$1], [$2], [$3], [$4], [yes])]) 2731 2732 2733# lt_decl_tag_varnames([SEPARATOR], [VARNAME1...]) 2734# ------------------------------------------------ 2735m4_define([lt_decl_tag_varnames], 2736[_lt_decl_filter([tagged?], [yes], $@)]) 2737 2738 2739# _lt_decl_filter(SUBKEY, VALUE, [SEPARATOR], [VARNAME1..]) 2740# --------------------------------------------------------- 2741m4_define([_lt_decl_filter], 2742[m4_case([$#], 2743 [0], [m4_fatal([$0: too few arguments: $#])], 2744 [1], [m4_fatal([$0: too few arguments: $#: $1])], 2745 [2], [lt_dict_filter([lt_decl_dict], [$1], [$2], [], lt_decl_varnames)], 2746 [3], [lt_dict_filter([lt_decl_dict], [$1], [$2], [$3], lt_decl_varnames)], 2747 [lt_dict_filter([lt_decl_dict], $@)])[]dnl 2748]) 2749 2750 2751# lt_decl_quote_varnames([SEPARATOR], [VARNAME1...]) 2752# -------------------------------------------------- 2753m4_define([lt_decl_quote_varnames], 2754[_lt_decl_filter([value], [1], $@)]) 2755 2756 2757# lt_decl_dquote_varnames([SEPARATOR], [VARNAME1...]) 2758# --------------------------------------------------- 2759m4_define([lt_decl_dquote_varnames], 2760[_lt_decl_filter([value], [2], $@)]) 2761 2762 2763# lt_decl_varnames_tagged([SEPARATOR], [VARNAME1...]) 2764# --------------------------------------------------- 2765m4_define([lt_decl_varnames_tagged], 2766[m4_assert([$# <= 2])dnl 2767_$0(m4_quote(m4_default([$1], [[, ]])), 2768 m4_ifval([$2], [[$2]], [m4_dquote(lt_decl_tag_varnames)]), 2769 m4_split(m4_normalize(m4_quote(_LT_TAGS)), [ ]))]) 2770m4_define([_lt_decl_varnames_tagged], 2771[m4_ifval([$3], [lt_combine([$1], [$2], [_], $3)])]) 2772 2773 2774# lt_decl_all_varnames([SEPARATOR], [VARNAME1...]) 2775# ------------------------------------------------ 2776m4_define([lt_decl_all_varnames], 2777[_$0(m4_quote(m4_default([$1], [[, ]])), 2778 m4_if([$2], [], 2779 m4_quote(lt_decl_varnames), 2780 m4_quote(m4_shift($@))))[]dnl 2781]) 2782m4_define([_lt_decl_all_varnames], 2783[lt_join($@, lt_decl_varnames_tagged([$1], 2784 lt_decl_tag_varnames([[, ]], m4_shift($@))))dnl 2785]) 2786 2787 2788# _LT_CONFIG_STATUS_DECLARE([VARNAME]) 2789# ------------------------------------ 2790# Quote a variable value, and forward it to `config.status' so that its 2791# declaration there will have the same value as in `configure'. VARNAME 2792# must have a single quote delimited value for this to work. 2793m4_define([_LT_CONFIG_STATUS_DECLARE], 2794[$1='`$ECHO "$][$1" | $SED "$delay_single_quote_subst"`']) 2795 2796 2797# _LT_CONFIG_STATUS_DECLARATIONS 2798# ------------------------------ 2799# We delimit libtool config variables with single quotes, so when 2800# we write them to config.status, we have to be sure to quote all 2801# embedded single quotes properly. In configure, this macro expands 2802# each variable declared with _LT_DECL (and _LT_TAGDECL) into: 2803# 2804# <var>='`$ECHO "$<var>" | $SED "$delay_single_quote_subst"`' 2805m4_defun([_LT_CONFIG_STATUS_DECLARATIONS], 2806[m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames), 2807 [m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])]) 2808 2809 2810# _LT_LIBTOOL_TAGS 2811# ---------------- 2812# Output comment and list of tags supported by the script 2813m4_defun([_LT_LIBTOOL_TAGS], 2814[_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl 2815available_tags="_LT_TAGS"dnl 2816]) 2817 2818 2819# _LT_LIBTOOL_DECLARE(VARNAME, [TAG]) 2820# ----------------------------------- 2821# Extract the dictionary values for VARNAME (optionally with TAG) and 2822# expand to a commented shell variable setting: 2823# 2824# # Some comment about what VAR is for. 2825# visible_name=$lt_internal_name 2826m4_define([_LT_LIBTOOL_DECLARE], 2827[_LT_FORMAT_COMMENT(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], 2828 [description])))[]dnl 2829m4_pushdef([_libtool_name], 2830 m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [libtool_name])))[]dnl 2831m4_case(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [value])), 2832 [0], [_libtool_name=[$]$1], 2833 [1], [_libtool_name=$lt_[]$1], 2834 [2], [_libtool_name=$lt_[]$1], 2835 [_libtool_name=lt_dict_fetch([lt_decl_dict], [$1], [value])])[]dnl 2836m4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl 2837]) 2838 2839 2840# _LT_LIBTOOL_CONFIG_VARS 2841# ----------------------- 2842# Produce commented declarations of non-tagged libtool config variables 2843# suitable for insertion in the LIBTOOL CONFIG section of the `libtool' 2844# script. Tagged libtool config variables (even for the LIBTOOL CONFIG 2845# section) are produced by _LT_LIBTOOL_TAG_VARS. 2846m4_defun([_LT_LIBTOOL_CONFIG_VARS], 2847[m4_foreach([_lt_var], 2848 m4_quote(_lt_decl_filter([tagged?], [no], [], lt_decl_varnames)), 2849 [m4_n([_LT_LIBTOOL_DECLARE(_lt_var)])])]) 2850 2851 2852# _LT_LIBTOOL_TAG_VARS(TAG) 2853# ------------------------- 2854m4_define([_LT_LIBTOOL_TAG_VARS], 2855[m4_foreach([_lt_var], m4_quote(lt_decl_tag_varnames), 2856 [m4_n([_LT_LIBTOOL_DECLARE(_lt_var, [$1])])])]) 2857 2858 2859# _LT_TAGVAR(VARNAME, [TAGNAME]) 2860# ------------------------------ 2861m4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])]) 2862 2863 2864# _LT_CONFIG_COMMANDS 2865# ------------------- 2866# Send accumulated output to $CONFIG_STATUS. Thanks to the lists of 2867# variables for single and double quote escaping we saved from calls 2868# to _LT_DECL, we can put quote escaped variables declarations 2869# into `config.status', and then the shell code to quote escape them in 2870# for loops in `config.status'. Finally, any additional code accumulated 2871# from calls to _LT_CONFIG_LIBTOOL_INIT is expanded. 2872m4_defun([_LT_CONFIG_COMMANDS], 2873[AC_PROVIDE_IFELSE([LT_OUTPUT], 2874 dnl If the libtool generation code has been placed in $CONFIG_LT, 2875 dnl instead of duplicating it all over again into config.status, 2876 dnl then we will have config.status run $CONFIG_LT later, so it 2877 dnl needs to know what name is stored there: 2878 [AC_CONFIG_COMMANDS([libtool], 2879 [$SHELL $CONFIG_LT || AS_EXIT(1)], [CONFIG_LT='$CONFIG_LT'])], 2880 dnl If the libtool generation code is destined for config.status, 2881 dnl expand the accumulated commands and init code now: 2882 [AC_CONFIG_COMMANDS([libtool], 2883 [_LT_OUTPUT_LIBTOOL_COMMANDS], [_LT_OUTPUT_LIBTOOL_COMMANDS_INIT])]) 2884])#_LT_CONFIG_COMMANDS 2885 2886 2887# Initialize. 2888m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS_INIT], 2889[ 2890 2891# The HP-UX ksh and POSIX shell print the target directory to stdout 2892# if CDPATH is set. 2893(unset CDPATH) >/dev/null 2>&1 && unset CDPATH 2894 2895sed_quote_subst='$sed_quote_subst' 2896double_quote_subst='$double_quote_subst' 2897delay_variable_subst='$delay_variable_subst' 2898_LT_CONFIG_STATUS_DECLARATIONS 2899LTCC='$LTCC' 2900LTCFLAGS='$LTCFLAGS' 2901compiler='$compiler_DEFAULT' 2902 2903# A function that is used when there is no print builtin or printf. 2904func_fallback_echo () 2905{ 2906 eval 'cat <<_LTECHO_EOF 2907\$[]1 2908_LTECHO_EOF' 2909} 2910 2911# Quote evaled strings. 2912for var in lt_decl_all_varnames([[ \ 2913]], lt_decl_quote_varnames); do 2914 case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in 2915 *[[\\\\\\\`\\"\\\$]]*) 2916 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" 2917 ;; 2918 *) 2919 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" 2920 ;; 2921 esac 2922done 2923 2924# Double-quote double-evaled strings. 2925for var in lt_decl_all_varnames([[ \ 2926]], lt_decl_dquote_varnames); do 2927 case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in 2928 *[[\\\\\\\`\\"\\\$]]*) 2929 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" 2930 ;; 2931 *) 2932 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" 2933 ;; 2934 esac 2935done 2936 2937_LT_OUTPUT_LIBTOOL_INIT 2938]) 2939 2940# _LT_GENERATED_FILE_INIT(FILE, [COMMENT]) 2941# ------------------------------------ 2942# Generate a child script FILE with all initialization necessary to 2943# reuse the environment learned by the parent script, and make the 2944# file executable. If COMMENT is supplied, it is inserted after the 2945# `#!' sequence but before initialization text begins. After this 2946# macro, additional text can be appended to FILE to form the body of 2947# the child script. The macro ends with non-zero status if the 2948# file could not be fully written (such as if the disk is full). 2949m4_ifdef([AS_INIT_GENERATED], 2950[m4_defun([_LT_GENERATED_FILE_INIT],[AS_INIT_GENERATED($@)])], 2951[m4_defun([_LT_GENERATED_FILE_INIT], 2952[m4_require([AS_PREPARE])]dnl 2953[m4_pushdef([AS_MESSAGE_LOG_FD])]dnl 2954[lt_write_fail=0 2955cat >$1 <<_ASEOF || lt_write_fail=1 2956#! $SHELL 2957# Generated by $as_me. 2958$2 2959SHELL=\${CONFIG_SHELL-$SHELL} 2960export SHELL 2961_ASEOF 2962cat >>$1 <<\_ASEOF || lt_write_fail=1 2963AS_SHELL_SANITIZE 2964_AS_PREPARE 2965exec AS_MESSAGE_FD>&1 2966_ASEOF 2967test $lt_write_fail = 0 && chmod +x $1[]dnl 2968m4_popdef([AS_MESSAGE_LOG_FD])])])# _LT_GENERATED_FILE_INIT 2969 2970# LT_OUTPUT 2971# --------- 2972# This macro allows early generation of the libtool script (before 2973# AC_OUTPUT is called), incase it is used in configure for compilation 2974# tests. 2975AC_DEFUN([LT_OUTPUT], 2976[: ${CONFIG_LT=./config.lt} 2977AC_MSG_NOTICE([creating $CONFIG_LT]) 2978_LT_GENERATED_FILE_INIT(["$CONFIG_LT"], 2979[# Run this file to recreate a libtool stub with the current configuration.]) 2980 2981cat >>"$CONFIG_LT" <<\_LTEOF 2982lt_cl_silent=false 2983exec AS_MESSAGE_LOG_FD>>config.log 2984{ 2985 echo 2986 AS_BOX([Running $as_me.]) 2987} >&AS_MESSAGE_LOG_FD 2988 2989lt_cl_help="\ 2990\`$as_me' creates a local libtool stub from the current configuration, 2991for use in further configure time tests before the real libtool is 2992generated. 2993 2994Usage: $[0] [[OPTIONS]] 2995 2996 -h, --help print this help, then exit 2997 -V, --version print version number, then exit 2998 -q, --quiet do not print progress messages 2999 -d, --debug don't remove temporary files 3000 3001Report bugs to <bug-libtool@gnu.org>." 3002 3003lt_cl_version="\ 3004m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl 3005m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION]) 3006configured by $[0], generated by m4_PACKAGE_STRING. 3007 3008Copyright (C) 2010 Free Software Foundation, Inc. 3009This config.lt script is free software; the Free Software Foundation 3010gives unlimited permision to copy, distribute and modify it." 3011 3012while test $[#] != 0 3013do 3014 case $[1] in 3015 --version | --v* | -V ) 3016 echo "$lt_cl_version"; exit 0 ;; 3017 --help | --h* | -h ) 3018 echo "$lt_cl_help"; exit 0 ;; 3019 --debug | --d* | -d ) 3020 debug=: ;; 3021 --quiet | --q* | --silent | --s* | -q ) 3022 lt_cl_silent=: ;; 3023 3024 -*) AC_MSG_ERROR([unrecognized option: $[1] 3025Try \`$[0] --help' for more information.]) ;; 3026 3027 *) AC_MSG_ERROR([unrecognized argument: $[1] 3028Try \`$[0] --help' for more information.]) ;; 3029 esac 3030 shift 3031done 3032 3033if $lt_cl_silent; then 3034 exec AS_MESSAGE_FD>/dev/null 3035fi 3036_LTEOF 3037 3038cat >>"$CONFIG_LT" <<_LTEOF 3039_LT_OUTPUT_LIBTOOL_COMMANDS_INIT 3040_LTEOF 3041 3042cat >>"$CONFIG_LT" <<\_LTEOF 3043AC_MSG_NOTICE([creating $ofile]) 3044_LT_OUTPUT_LIBTOOL_COMMANDS 3045AS_EXIT(0) 3046_LTEOF 3047chmod +x "$CONFIG_LT" 3048 3049# configure is writing to config.log, but config.lt does its own redirection, 3050# appending to config.log, which fails on DOS, as config.log is still kept 3051# open by configure. Here we exec the FD to /dev/null, effectively closing 3052# config.log, so it can be properly (re)opened and appended to by config.lt. 3053lt_cl_success=: 3054test "$silent" = yes && 3055 lt_config_lt_args="$lt_config_lt_args --quiet" 3056exec AS_MESSAGE_LOG_FD>/dev/null 3057$SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false 3058exec AS_MESSAGE_LOG_FD>>config.log 3059$lt_cl_success || AS_EXIT(1) 3060])# LT_OUTPUT 3061 3062 3063# _LT_CONFIG(TAG) 3064# --------------- 3065# If TAG is the built-in tag, create an initial libtool script with a 3066# default configuration from the untagged config vars. Otherwise add code 3067# to config.status for appending the configuration named by TAG from the 3068# matching tagged config vars. 3069m4_defun([_LT_CONFIG], 3070[m4_require([_LT_FILEUTILS_DEFAULTS])dnl 3071_LT_CONFIG_SAVE_COMMANDS([ 3072 m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl 3073 m4_if(_LT_TAG, [C], [ 3074 # See if we are running on zsh, and set the options which allow our 3075 # commands through without removal of \ escapes. 3076 if test -n "${ZSH_VERSION+set}" ; then 3077 setopt NO_GLOB_SUBST 3078 fi 3079 3080 cfgfile="${ofile}T" 3081 trap "$RM \"$cfgfile\"; exit 1" 1 2 15 3082 $RM "$cfgfile" 3083 3084 cat <<_LT_EOF >> "$cfgfile" 3085#! $SHELL 3086 3087# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services. 3088# Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION 3089# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: 3090# NOTE: Changes made to this file will be lost: look at ltmain.sh. 3091# 3092_LT_COPYING 3093_LT_LIBTOOL_TAGS 3094 3095# ### BEGIN LIBTOOL CONFIG 3096_LT_LIBTOOL_CONFIG_VARS 3097_LT_LIBTOOL_TAG_VARS 3098# ### END LIBTOOL CONFIG 3099 3100_LT_EOF 3101 3102 case $host_os in 3103 aix3*) 3104 cat <<\_LT_EOF >> "$cfgfile" 3105# AIX sometimes has problems with the GCC collect2 program. For some 3106# reason, if we set the COLLECT_NAMES environment variable, the problems 3107# vanish in a puff of smoke. 3108if test "X${COLLECT_NAMES+set}" != Xset; then 3109 COLLECT_NAMES= 3110 export COLLECT_NAMES 3111fi 3112_LT_EOF 3113 ;; 3114 esac 3115 3116 _LT_PROG_LTMAIN 3117 3118 # We use sed instead of cat because bash on DJGPP gets confused if 3119 # if finds mixed CR/LF and LF-only lines. Since sed operates in 3120 # text mode, it properly converts lines to CR/LF. This bash problem 3121 # is reportedly fixed, but why not run on old versions too? 3122 sed '/^# Generated shell functions inserted here/q' "$ltmain" >> "$cfgfile" \ 3123 || (rm -f "$cfgfile"; exit 1) 3124 3125 _LT_PROG_XSI_SHELLFNS 3126 3127 sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \ 3128 || (rm -f "$cfgfile"; exit 1) 3129 3130 mv -f "$cfgfile" "$ofile" || 3131 (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") 3132 chmod +x "$ofile" 3133], 3134[cat <<_LT_EOF >> "$ofile" 3135 3136dnl Unfortunately we have to use $1 here, since _LT_TAG is not expanded 3137dnl in a comment (ie after a #). 3138# ### BEGIN LIBTOOL TAG CONFIG: $1 3139_LT_LIBTOOL_TAG_VARS(_LT_TAG) 3140# ### END LIBTOOL TAG CONFIG: $1 3141_LT_EOF 3142])dnl /m4_if 3143], 3144[m4_if([$1], [], [ 3145 PACKAGE='$PACKAGE' 3146 VERSION='$VERSION' 3147 TIMESTAMP='$TIMESTAMP' 3148 RM='$RM' 3149 ofile='$ofile'], []) 3150])dnl /_LT_CONFIG_SAVE_COMMANDS 3151])# _LT_CONFIG 3152 3153 3154# LT_SUPPORTED_TAG(TAG) 3155# --------------------- 3156# Trace this macro to discover what tags are supported by the libtool 3157# --tag option, using: 3158# autoconf --trace 'LT_SUPPORTED_TAG:$1' 3159AC_DEFUN([LT_SUPPORTED_TAG], []) 3160 3161 3162# C support is built-in for now 3163m4_define([_LT_LANG_C_enabled], []) 3164m4_define([_LT_TAGS], []) 3165 3166 3167# LT_LANG(LANG) 3168# ------------- 3169# Enable libtool support for the given language if not already enabled. 3170AC_DEFUN([LT_LANG], 3171[AC_BEFORE([$0], [LT_OUTPUT])dnl 3172m4_case([$1], 3173 [C], [_LT_LANG(C)], 3174 [C++], [_LT_LANG(CXX)], 3175 [Java], [_LT_LANG(GCJ)], 3176 [Fortran 77], [_LT_LANG(F77)], 3177 [Fortran], [_LT_LANG(FC)], 3178 [Windows Resource], [_LT_LANG(RC)], 3179 [m4_ifdef([_LT_LANG_]$1[_CONFIG], 3180 [_LT_LANG($1)], 3181 [m4_fatal([$0: unsupported language: "$1"])])])dnl 3182])# LT_LANG 3183 3184 3185# _LT_LANG(LANGNAME) 3186# ------------------ 3187m4_defun([_LT_LANG], 3188[m4_ifdef([_LT_LANG_]$1[_enabled], [], 3189 [LT_SUPPORTED_TAG([$1])dnl 3190 m4_append([_LT_TAGS], [$1 ])dnl 3191 m4_define([_LT_LANG_]$1[_enabled], [])dnl 3192 _LT_LANG_$1_CONFIG($1)])dnl 3193])# _LT_LANG 3194 3195 3196# _LT_LANG_DEFAULT_CONFIG 3197# ----------------------- 3198m4_defun([_LT_LANG_DEFAULT_CONFIG], 3199[AC_PROVIDE_IFELSE([AC_PROG_CXX], 3200 [LT_LANG(CXX)], 3201 [m4_define([AC_PROG_CXX], defn([AC_PROG_CXX])[LT_LANG(CXX)])]) 3202 3203AC_PROVIDE_IFELSE([AC_PROG_F77], 3204 [LT_LANG(F77)], 3205 [m4_define([AC_PROG_F77], defn([AC_PROG_F77])[LT_LANG(F77)])]) 3206 3207AC_PROVIDE_IFELSE([AC_PROG_FC], 3208 [LT_LANG(FC)], 3209 [m4_define([AC_PROG_FC], defn([AC_PROG_FC])[LT_LANG(FC)])]) 3210 3211dnl The call to [A][M_PROG_GCJ] is quoted like that to stop aclocal 3212dnl pulling things in needlessly. 3213AC_PROVIDE_IFELSE([AC_PROG_GCJ], 3214 [LT_LANG(GCJ)], 3215 [AC_PROVIDE_IFELSE([A][M_PROG_GCJ], 3216 [LT_LANG(GCJ)], 3217 [AC_PROVIDE_IFELSE([LT_PROG_GCJ], 3218 [LT_LANG(GCJ)], 3219 [m4_ifdef([AC_PROG_GCJ], 3220 [m4_define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[LT_LANG(GCJ)])]) 3221 m4_ifdef([A][M_PROG_GCJ], 3222 [m4_define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[LT_LANG(GCJ)])]) 3223 m4_ifdef([LT_PROG_GCJ], 3224 [m4_define([LT_PROG_GCJ], defn([LT_PROG_GCJ])[LT_LANG(GCJ)])])])])]) 3225 3226AC_PROVIDE_IFELSE([LT_PROG_RC], 3227 [LT_LANG(RC)], 3228 [m4_define([LT_PROG_RC], defn([LT_PROG_RC])[LT_LANG(RC)])]) 3229])# _LT_LANG_DEFAULT_CONFIG 3230 3231# Obsolete macros: 3232AU_DEFUN([AC_LIBTOOL_CXX], [LT_LANG(C++)]) 3233AU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)]) 3234AU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)]) 3235AU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)]) 3236AU_DEFUN([AC_LIBTOOL_RC], [LT_LANG(Windows Resource)]) 3237dnl aclocal-1.4 backwards compatibility: 3238dnl AC_DEFUN([AC_LIBTOOL_CXX], []) 3239dnl AC_DEFUN([AC_LIBTOOL_F77], []) 3240dnl AC_DEFUN([AC_LIBTOOL_FC], []) 3241dnl AC_DEFUN([AC_LIBTOOL_GCJ], []) 3242dnl AC_DEFUN([AC_LIBTOOL_RC], []) 3243 3244 3245# _LT_TAG_COMPILER 3246# ---------------- 3247m4_defun([_LT_TAG_COMPILER], 3248[AC_REQUIRE([AC_PROG_CC])dnl 3249 3250_LT_DECL([LTCC], [CC], [1], [A C compiler])dnl 3251_LT_DECL([LTCFLAGS], [CFLAGS], [1], [LTCC compiler flags])dnl 3252_LT_TAGDECL([CC], [compiler], [1], [A language specific compiler])dnl 3253_LT_TAGDECL([with_gcc], [GCC], [0], [Is the compiler the GNU compiler?])dnl 3254 3255# If no C compiler was specified, use CC. 3256LTCC=${LTCC-"$CC"} 3257 3258# If no C compiler flags were specified, use CFLAGS. 3259LTCFLAGS=${LTCFLAGS-"$CFLAGS"} 3260 3261# Allow CC to be a program name with arguments. 3262compiler=$CC 3263])# _LT_TAG_COMPILER 3264 3265 3266# _LT_COMPILER_BOILERPLATE 3267# ------------------------ 3268# Check for compiler boilerplate output or warnings with 3269# the simple compiler test code. 3270m4_defun([_LT_COMPILER_BOILERPLATE], 3271[m4_require([_LT_DECL_SED])dnl 3272ac_outfile=conftest.$ac_objext 3273echo "$lt_simple_compile_test_code" >conftest.$ac_ext 3274eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err 3275_lt_compiler_boilerplate=`cat conftest.err` 3276$RM conftest* 3277])# _LT_COMPILER_BOILERPLATE 3278 3279 3280# _LT_LINKER_BOILERPLATE 3281# ---------------------- 3282# Check for linker boilerplate output or warnings with 3283# the simple link test code. 3284m4_defun([_LT_LINKER_BOILERPLATE], 3285[m4_require([_LT_DECL_SED])dnl 3286ac_outfile=conftest.$ac_objext 3287echo "$lt_simple_link_test_code" >conftest.$ac_ext 3288eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err 3289_lt_linker_boilerplate=`cat conftest.err` 3290$RM -r conftest* 3291])# _LT_LINKER_BOILERPLATE 3292 3293# _LT_REQUIRED_DARWIN_CHECKS 3294# ------------------------- 3295m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[ 3296 case $host_os in 3297 rhapsody* | darwin*) 3298 AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:]) 3299 AC_CHECK_TOOL([NMEDIT], [nmedit], [:]) 3300 AC_CHECK_TOOL([LIPO], [lipo], [:]) 3301 AC_CHECK_TOOL([OTOOL], [otool], [:]) 3302 AC_CHECK_TOOL([OTOOL64], [otool64], [:]) 3303 _LT_DECL([], [DSYMUTIL], [1], 3304 [Tool to manipulate archived DWARF debug symbol files on Mac OS X]) 3305 _LT_DECL([], [NMEDIT], [1], 3306 [Tool to change global to local symbols on Mac OS X]) 3307 _LT_DECL([], [LIPO], [1], 3308 [Tool to manipulate fat objects and archives on Mac OS X]) 3309 _LT_DECL([], [OTOOL], [1], 3310 [ldd/readelf like tool for Mach-O binaries on Mac OS X]) 3311 _LT_DECL([], [OTOOL64], [1], 3312 [ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4]) 3313 3314 AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod], 3315 [lt_cv_apple_cc_single_mod=no 3316 if test -z "${LT_MULTI_MODULE}"; then 3317 # By default we will add the -single_module flag. You can override 3318 # by either setting the environment variable LT_MULTI_MODULE 3319 # non-empty at configure time, or by adding -multi_module to the 3320 # link flags. 3321 rm -rf libconftest.dylib* 3322 echo "int foo(void){return 1;}" > conftest.c 3323 echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ 3324-dynamiclib -Wl,-single_module conftest.c" >&AS_MESSAGE_LOG_FD 3325 $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ 3326 -dynamiclib -Wl,-single_module conftest.c 2>conftest.err 3327 _lt_result=$? 3328 if test -f libconftest.dylib && test ! -s conftest.err && test $_lt_result = 0; then 3329 lt_cv_apple_cc_single_mod=yes 3330 else 3331 cat conftest.err >&AS_MESSAGE_LOG_FD 3332 fi 3333 rm -rf libconftest.dylib* 3334 rm -f conftest.* 3335 fi]) 3336 AC_CACHE_CHECK([for -exported_symbols_list linker flag], 3337 [lt_cv_ld_exported_symbols_list], 3338 [lt_cv_ld_exported_symbols_list=no 3339 save_LDFLAGS=$LDFLAGS 3340 echo "_main" > conftest.sym 3341 LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" 3342 AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], 3343 [lt_cv_ld_exported_symbols_list=yes], 3344 [lt_cv_ld_exported_symbols_list=no]) 3345 LDFLAGS="$save_LDFLAGS" 3346 ]) 3347 AC_CACHE_CHECK([for -force_load linker flag],[lt_cv_ld_force_load], 3348 [lt_cv_ld_force_load=no 3349 cat > conftest.c << _LT_EOF 3350int forced_loaded() { return 2;} 3351_LT_EOF 3352 echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&AS_MESSAGE_LOG_FD 3353 $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD 3354 echo "$AR cru libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD 3355 $AR cru libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD 3356 echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD 3357 $RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD 3358 cat > conftest.c << _LT_EOF 3359int main() { return 0;} 3360_LT_EOF 3361 echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&AS_MESSAGE_LOG_FD 3362 $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err 3363 _lt_result=$? 3364 if test -f conftest && test ! -s conftest.err && test $_lt_result = 0 && $GREP forced_load conftest 2>&1 >/dev/null; then 3365 lt_cv_ld_force_load=yes 3366 else 3367 cat conftest.err >&AS_MESSAGE_LOG_FD 3368 fi 3369 rm -f conftest.err libconftest.a conftest conftest.c 3370 rm -rf conftest.dSYM 3371 ]) 3372 case $host_os in 3373 rhapsody* | darwin1.[[012]]) 3374 _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;; 3375 darwin1.*) 3376 _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; 3377 darwin*) # darwin 5.x on 3378 # if running on 10.5 or later, the deployment target defaults 3379 # to the OS version, if on x86, and 10.4, the deployment 3380 # target defaults to 10.4. Don't you love it? 3381 case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in 3382 10.0,*86*-darwin8*|10.0,*-darwin[[91]]*) 3383 _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; 3384 10.[[012]]*) 3385 _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; 3386 10.*) 3387 _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; 3388 esac 3389 ;; 3390 esac 3391 if test "$lt_cv_apple_cc_single_mod" = "yes"; then 3392 _lt_dar_single_mod='$single_module' 3393 fi 3394 if test "$lt_cv_ld_exported_symbols_list" = "yes"; then 3395 _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym' 3396 else 3397 _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}' 3398 fi 3399 if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then 3400 _lt_dsymutil='~$DSYMUTIL $lib || :' 3401 else 3402 _lt_dsymutil= 3403 fi 3404 ;; 3405 esac 3406]) 3407 3408 3409# _LT_DARWIN_LINKER_FEATURES 3410# -------------------------- 3411# Checks for linker and compiler features on darwin 3412m4_defun([_LT_DARWIN_LINKER_FEATURES], 3413[ 3414 m4_require([_LT_REQUIRED_DARWIN_CHECKS]) 3415 _LT_TAGVAR(archive_cmds_need_lc, $1)=no 3416 _LT_TAGVAR(hardcode_direct, $1)=no 3417 _LT_TAGVAR(hardcode_automatic, $1)=yes 3418 _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported 3419 if test "$lt_cv_ld_force_load" = "yes"; then 3420 _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\"`' 3421 else 3422 _LT_TAGVAR(whole_archive_flag_spec, $1)='' 3423 fi 3424 _LT_TAGVAR(link_all_deplibs, $1)=yes 3425 _LT_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined" 3426 case $cc_basename in 3427 ifort*) _lt_dar_can_shared=yes ;; 3428 *) _lt_dar_can_shared=$GCC ;; 3429 esac 3430 if test "$_lt_dar_can_shared" = "yes"; then 3431 output_verbose_link_cmd=func_echo_all 3432 _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}" 3433 _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" 3434 _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}" 3435 _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}" 3436 m4_if([$1], [CXX], 3437[ if test "$lt_cv_apple_cc_single_mod" != "yes"; then 3438 _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}" 3439 _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}" 3440 fi 3441],[]) 3442 else 3443 _LT_TAGVAR(ld_shlibs, $1)=no 3444 fi 3445]) 3446 3447# _LT_SYS_MODULE_PATH_AIX 3448# ----------------------- 3449# Links a minimal program and checks the executable 3450# for the system default hardcoded library path. In most cases, 3451# this is /usr/lib:/lib, but when the MPI compilers are used 3452# the location of the communication and MPI libs are included too. 3453# If we don't find anything, use the default library path according 3454# to the aix ld manual. 3455m4_defun([_LT_SYS_MODULE_PATH_AIX], 3456[m4_require([_LT_DECL_SED])dnl 3457AC_LINK_IFELSE(AC_LANG_PROGRAM,[ 3458lt_aix_libpath_sed=' 3459 /Import File Strings/,/^$/ { 3460 /^0/ { 3461 s/^0 *\(.*\)$/\1/ 3462 p 3463 } 3464 }' 3465aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` 3466# Check for a 64-bit object if we didn't find anything. 3467if test -z "$aix_libpath"; then 3468 aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` 3469fi],[]) 3470if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi 3471])# _LT_SYS_MODULE_PATH_AIX 3472 3473 3474# _LT_SHELL_INIT(ARG) 3475# ------------------- 3476m4_define([_LT_SHELL_INIT], 3477[m4_divert_text([M4SH-INIT], [$1 3478])])# _LT_SHELL_INIT 3479 3480 3481 3482# _LT_PROG_ECHO_BACKSLASH 3483# ----------------------- 3484# Find how we can fake an echo command that does not interpret backslash. 3485# In particular, with Autoconf 2.60 or later we add some code to the start 3486# of the generated configure script which will find a shell with a builtin 3487# printf (which we can use as an echo command). 3488m4_defun([_LT_PROG_ECHO_BACKSLASH], 3489[ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' 3490ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO 3491ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO 3492 3493AC_MSG_CHECKING([how to print strings]) 3494# Test print first, because it will be a builtin if present. 3495if test "X`print -r -- -n 2>/dev/null`" = X-n && \ 3496 test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then 3497 ECHO='print -r --' 3498elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then 3499 ECHO='printf %s\n' 3500else 3501 # Use this function as a fallback that always works. 3502 func_fallback_echo () 3503 { 3504 eval 'cat <<_LTECHO_EOF 3505$[]1 3506_LTECHO_EOF' 3507 } 3508 ECHO='func_fallback_echo' 3509fi 3510 3511# func_echo_all arg... 3512# Invoke $ECHO with all args, space-separated. 3513func_echo_all () 3514{ 3515 $ECHO "$*" 3516} 3517 3518case "$ECHO" in 3519 printf*) AC_MSG_RESULT([printf]) ;; 3520 print*) AC_MSG_RESULT([print -r]) ;; 3521 *) AC_MSG_RESULT([cat]) ;; 3522esac 3523 3524m4_ifdef([_AS_DETECT_SUGGESTED], 3525[_AS_DETECT_SUGGESTED([ 3526 test -n "${ZSH_VERSION+set}${BASH_VERSION+set}" || ( 3527 ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' 3528 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO 3529 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO 3530 PATH=/empty FPATH=/empty; export PATH FPATH 3531 test "X`printf %s $ECHO`" = "X$ECHO" \ 3532 || test "X`print -r -- $ECHO`" = "X$ECHO" )])]) 3533 3534_LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts]) 3535_LT_DECL([], [ECHO], [1], [An echo program that protects backslashes]) 3536])# _LT_PROG_ECHO_BACKSLASH 3537 3538 3539# _LT_ENABLE_LOCK 3540# --------------- 3541m4_defun([_LT_ENABLE_LOCK], 3542[AC_ARG_ENABLE([libtool-lock], 3543 [AS_HELP_STRING([--disable-libtool-lock], 3544 [avoid locking (might break parallel builds)])]) 3545test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes 3546 3547# Some flags need to be propagated to the compiler or linker for good 3548# libtool support. 3549case $host in 3550ia64-*-hpux*) 3551 # Find out which ABI we are using. 3552 echo 'int i;' > conftest.$ac_ext 3553 if AC_TRY_EVAL(ac_compile); then 3554 case `/usr/bin/file conftest.$ac_objext` in 3555 *ELF-32*) 3556 HPUX_IA64_MODE="32" 3557 ;; 3558 *ELF-64*) 3559 HPUX_IA64_MODE="64" 3560 ;; 3561 esac 3562 fi 3563 rm -rf conftest* 3564 ;; 3565*-*-irix6*) 3566 # Find out which ABI we are using. 3567 echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext 3568 if AC_TRY_EVAL(ac_compile); then 3569 if test "$lt_cv_prog_gnu_ld" = yes; then 3570 case `/usr/bin/file conftest.$ac_objext` in 3571 *32-bit*) 3572 LD="${LD-ld} -melf32bsmip" 3573 ;; 3574 *N32*) 3575 LD="${LD-ld} -melf32bmipn32" 3576 ;; 3577 *64-bit*) 3578 LD="${LD-ld} -melf64bmip" 3579 ;; 3580 esac 3581 else 3582 case `/usr/bin/file conftest.$ac_objext` in 3583 *32-bit*) 3584 LD="${LD-ld} -32" 3585 ;; 3586 *N32*) 3587 LD="${LD-ld} -n32" 3588 ;; 3589 *64-bit*) 3590 LD="${LD-ld} -64" 3591 ;; 3592 esac 3593 fi 3594 fi 3595 rm -rf conftest* 3596 ;; 3597 3598x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \ 3599s390*-*linux*|s390*-*tpf*|sparc*-*linux*) 3600 # Find out which ABI we are using. 3601 echo 'int i;' > conftest.$ac_ext 3602 if AC_TRY_EVAL(ac_compile); then 3603 case `/usr/bin/file conftest.o` in 3604 *32-bit*) 3605 case $host in 3606 x86_64-*kfreebsd*-gnu) 3607 LD="${LD-ld} -m elf_i386_fbsd" 3608 ;; 3609 x86_64-*linux*) 3610 LD="${LD-ld} -m elf_i386" 3611 ;; 3612 ppc64-*linux*|powerpc64-*linux*) 3613 LD="${LD-ld} -m elf32ppclinux" 3614 ;; 3615 s390x-*linux*) 3616 LD="${LD-ld} -m elf_s390" 3617 ;; 3618 sparc64-*linux*) 3619 LD="${LD-ld} -m elf32_sparc" 3620 ;; 3621 esac 3622 ;; 3623 *64-bit*) 3624 case $host in 3625 x86_64-*kfreebsd*-gnu) 3626 LD="${LD-ld} -m elf_x86_64_fbsd" 3627 ;; 3628 x86_64-*linux*) 3629 LD="${LD-ld} -m elf_x86_64" 3630 ;; 3631 ppc*-*linux*|powerpc*-*linux*) 3632 LD="${LD-ld} -m elf64ppc" 3633 ;; 3634 s390*-*linux*|s390*-*tpf*) 3635 LD="${LD-ld} -m elf64_s390" 3636 ;; 3637 sparc*-*linux*) 3638 LD="${LD-ld} -m elf64_sparc" 3639 ;; 3640 esac 3641 ;; 3642 esac 3643 fi 3644 rm -rf conftest* 3645 ;; 3646 3647*-*-sco3.2v5*) 3648 # On SCO OpenServer 5, we need -belf to get full-featured binaries. 3649 SAVE_CFLAGS="$CFLAGS" 3650 CFLAGS="$CFLAGS -belf" 3651 AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf, 3652 [AC_LANG_PUSH(C) 3653 AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no]) 3654 AC_LANG_POP]) 3655 if test x"$lt_cv_cc_needs_belf" != x"yes"; then 3656 # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf 3657 CFLAGS="$SAVE_CFLAGS" 3658 fi 3659 ;; 3660sparc*-*solaris*) 3661 # Find out which ABI we are using. 3662 echo 'int i;' > conftest.$ac_ext 3663 if AC_TRY_EVAL(ac_compile); then 3664 case `/usr/bin/file conftest.o` in 3665 *64-bit*) 3666 case $lt_cv_prog_gnu_ld in 3667 yes*) LD="${LD-ld} -m elf64_sparc" ;; 3668 *) 3669 if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then 3670 LD="${LD-ld} -64" 3671 fi 3672 ;; 3673 esac 3674 ;; 3675 esac 3676 fi 3677 rm -rf conftest* 3678 ;; 3679esac 3680 3681need_locks="$enable_libtool_lock" 3682])# _LT_ENABLE_LOCK 3683 3684 3685# _LT_CMD_OLD_ARCHIVE 3686# ------------------- 3687m4_defun([_LT_CMD_OLD_ARCHIVE], 3688[AC_CHECK_TOOL(AR, ar, false) 3689test -z "$AR" && AR=ar 3690test -z "$AR_FLAGS" && AR_FLAGS=cru 3691_LT_DECL([], [AR], [1], [The archiver]) 3692_LT_DECL([], [AR_FLAGS], [1]) 3693 3694AC_CHECK_TOOL(STRIP, strip, :) 3695test -z "$STRIP" && STRIP=: 3696_LT_DECL([], [STRIP], [1], [A symbol stripping program]) 3697 3698AC_CHECK_TOOL(RANLIB, ranlib, :) 3699test -z "$RANLIB" && RANLIB=: 3700_LT_DECL([], [RANLIB], [1], 3701 [Commands used to install an old-style archive]) 3702 3703# Determine commands to create old-style static archives. 3704old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' 3705old_postinstall_cmds='chmod 644 $oldlib' 3706old_postuninstall_cmds= 3707 3708if test -n "$RANLIB"; then 3709 case $host_os in 3710 openbsd*) 3711 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib" 3712 ;; 3713 *) 3714 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib" 3715 ;; 3716 esac 3717 old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib" 3718fi 3719 3720case $host_os in 3721 darwin*) 3722 lock_old_archive_extraction=yes ;; 3723 *) 3724 lock_old_archive_extraction=no ;; 3725esac 3726_LT_DECL([], [old_postinstall_cmds], [2]) 3727_LT_DECL([], [old_postuninstall_cmds], [2]) 3728_LT_TAGDECL([], [old_archive_cmds], [2], 3729 [Commands used to build an old-style archive]) 3730_LT_DECL([], [lock_old_archive_extraction], [0], 3731 [Whether to use a lock for old archive extraction]) 3732])# _LT_CMD_OLD_ARCHIVE 3733 3734 3735# _LT_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, 3736# [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE]) 3737# ---------------------------------------------------------------- 3738# Check whether the given compiler option works 3739AC_DEFUN([_LT_COMPILER_OPTION], 3740[m4_require([_LT_FILEUTILS_DEFAULTS])dnl 3741m4_require([_LT_DECL_SED])dnl 3742AC_CACHE_CHECK([$1], [$2], 3743 [$2=no 3744 m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4]) 3745 echo "$lt_simple_compile_test_code" > conftest.$ac_ext 3746 lt_compiler_flag="$3" 3747 # Insert the option either (1) after the last *FLAGS variable, or 3748 # (2) before a word containing "conftest.", or (3) at the end. 3749 # Note that $ac_compile itself does not contain backslashes and begins 3750 # with a dollar sign (not a hyphen), so the echo should work correctly. 3751 # The option is referenced via a variable to avoid confusing sed. 3752 lt_compile=`echo "$ac_compile" | $SED \ 3753 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ 3754 -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ 3755 -e 's:$: $lt_compiler_flag:'` 3756 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD) 3757 (eval "$lt_compile" 2>conftest.err) 3758 ac_status=$? 3759 cat conftest.err >&AS_MESSAGE_LOG_FD 3760 echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD 3761 if (exit $ac_status) && test -s "$ac_outfile"; then 3762 # The compiler can only warn and ignore the option if not recognized 3763 # So say no if there are warnings other than the usual output. 3764 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp 3765 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 3766 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then 3767 $2=yes 3768 fi 3769 fi 3770 $RM conftest* 3771]) 3772 3773if test x"[$]$2" = xyes; then 3774 m4_if([$5], , :, [$5]) 3775else 3776 m4_if([$6], , :, [$6]) 3777fi 3778])# _LT_COMPILER_OPTION 3779 3780# Old name: 3781AU_ALIAS([AC_LIBTOOL_COMPILER_OPTION], [_LT_COMPILER_OPTION]) 3782dnl aclocal-1.4 backwards compatibility: 3783dnl AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], []) 3784 3785 3786# _LT_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, 3787# [ACTION-SUCCESS], [ACTION-FAILURE]) 3788# ---------------------------------------------------- 3789# Check whether the given linker option works 3790AC_DEFUN([_LT_LINKER_OPTION], 3791[m4_require([_LT_FILEUTILS_DEFAULTS])dnl 3792m4_require([_LT_DECL_SED])dnl 3793AC_CACHE_CHECK([$1], [$2], 3794 [$2=no 3795 save_LDFLAGS="$LDFLAGS" 3796 LDFLAGS="$LDFLAGS $3" 3797 echo "$lt_simple_link_test_code" > conftest.$ac_ext 3798 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then 3799 # The linker can only warn and ignore the option if not recognized 3800 # So say no if there are warnings 3801 if test -s conftest.err; then 3802 # Append any errors to the config.log. 3803 cat conftest.err 1>&AS_MESSAGE_LOG_FD 3804 $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp 3805 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 3806 if diff conftest.exp conftest.er2 >/dev/null; then 3807 $2=yes 3808 fi 3809 else 3810 $2=yes 3811 fi 3812 fi 3813 $RM -r conftest* 3814 LDFLAGS="$save_LDFLAGS" 3815]) 3816 3817if test x"[$]$2" = xyes; then 3818 m4_if([$4], , :, [$4]) 3819else 3820 m4_if([$5], , :, [$5]) 3821fi 3822])# _LT_LINKER_OPTION 3823 3824# Old name: 3825AU_ALIAS([AC_LIBTOOL_LINKER_OPTION], [_LT_LINKER_OPTION]) 3826dnl aclocal-1.4 backwards compatibility: 3827dnl AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], []) 3828 3829 3830# LT_CMD_MAX_LEN 3831#--------------- 3832AC_DEFUN([LT_CMD_MAX_LEN], 3833[AC_REQUIRE([AC_CANONICAL_HOST])dnl 3834# find the maximum length of command line arguments 3835AC_MSG_CHECKING([the maximum length of command line arguments]) 3836AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl 3837 i=0 3838 teststring="ABCD" 3839 3840 case $build_os in 3841 msdosdjgpp*) 3842 # On DJGPP, this test can blow up pretty badly due to problems in libc 3843 # (any single argument exceeding 2000 bytes causes a buffer overrun 3844 # during glob expansion). Even if it were fixed, the result of this 3845 # check would be larger than it should be. 3846 lt_cv_sys_max_cmd_len=12288; # 12K is about right 3847 ;; 3848 3849 gnu*) 3850 # Under GNU Hurd, this test is not required because there is 3851 # no limit to the length of command line arguments. 3852 # Libtool will interpret -1 as no limit whatsoever 3853 lt_cv_sys_max_cmd_len=-1; 3854 ;; 3855 3856 cygwin* | mingw* | cegcc*) 3857 # On Win9x/ME, this test blows up -- it succeeds, but takes 3858 # about 5 minutes as the teststring grows exponentially. 3859 # Worse, since 9x/ME are not pre-emptively multitasking, 3860 # you end up with a "frozen" computer, even though with patience 3861 # the test eventually succeeds (with a max line length of 256k). 3862 # Instead, let's just punt: use the minimum linelength reported by 3863 # all of the supported platforms: 8192 (on NT/2K/XP). 3864 lt_cv_sys_max_cmd_len=8192; 3865 ;; 3866 3867 mint*) 3868 # On MiNT this can take a long time and run out of memory. 3869 lt_cv_sys_max_cmd_len=8192; 3870 ;; 3871 3872 amigaos*) 3873 # On AmigaOS with pdksh, this test takes hours, literally. 3874 # So we just punt and use a minimum line length of 8192. 3875 lt_cv_sys_max_cmd_len=8192; 3876 ;; 3877 3878 netbsd* | freebsd* | openbsd* | darwin* | dragonfly*) 3879 # This has been around since 386BSD, at least. Likely further. 3880 if test -x /sbin/sysctl; then 3881 lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` 3882 elif test -x /usr/sbin/sysctl; then 3883 lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` 3884 else 3885 lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs 3886 fi 3887 # And add a safety zone 3888 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` 3889 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` 3890 ;; 3891 3892 interix*) 3893 # We know the value 262144 and hardcode it with a safety zone (like BSD) 3894 lt_cv_sys_max_cmd_len=196608 3895 ;; 3896 3897 osf*) 3898 # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure 3899 # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not 3900 # nice to cause kernel panics so lets avoid the loop below. 3901 # First set a reasonable default. 3902 lt_cv_sys_max_cmd_len=16384 3903 # 3904 if test -x /sbin/sysconfig; then 3905 case `/sbin/sysconfig -q proc exec_disable_arg_limit` in 3906 *1*) lt_cv_sys_max_cmd_len=-1 ;; 3907 esac 3908 fi 3909 ;; 3910 sco3.2v5*) 3911 lt_cv_sys_max_cmd_len=102400 3912 ;; 3913 sysv5* | sco5v6* | sysv4.2uw2*) 3914 kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` 3915 if test -n "$kargmax"; then 3916 lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'` 3917 else 3918 lt_cv_sys_max_cmd_len=32768 3919 fi 3920 ;; 3921 *) 3922 lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` 3923 if test -n "$lt_cv_sys_max_cmd_len"; then 3924 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` 3925 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` 3926 else 3927 # Make teststring a little bigger before we do anything with it. 3928 # a 1K string should be a reasonable start. 3929 for i in 1 2 3 4 5 6 7 8 ; do 3930 teststring=$teststring$teststring 3931 done 3932 SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} 3933 # If test is not a shell built-in, we'll probably end up computing a 3934 # maximum length that is only half of the actual maximum length, but 3935 # we can't tell. 3936 while { test "X"`func_fallback_echo "$teststring$teststring" 2>/dev/null` \ 3937 = "X$teststring$teststring"; } >/dev/null 2>&1 && 3938 test $i != 17 # 1/2 MB should be enough 3939 do 3940 i=`expr $i + 1` 3941 teststring=$teststring$teststring 3942 done 3943 # Only check the string length outside the loop. 3944 lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1` 3945 teststring= 3946 # Add a significant safety factor because C++ compilers can tack on 3947 # massive amounts of additional arguments before passing them to the 3948 # linker. It appears as though 1/2 is a usable value. 3949 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` 3950 fi 3951 ;; 3952 esac 3953]) 3954if test -n $lt_cv_sys_max_cmd_len ; then 3955 AC_MSG_RESULT($lt_cv_sys_max_cmd_len) 3956else 3957 AC_MSG_RESULT(none) 3958fi 3959max_cmd_len=$lt_cv_sys_max_cmd_len 3960_LT_DECL([], [max_cmd_len], [0], 3961 [What is the maximum length of a command?]) 3962])# LT_CMD_MAX_LEN 3963 3964# Old name: 3965AU_ALIAS([AC_LIBTOOL_SYS_MAX_CMD_LEN], [LT_CMD_MAX_LEN]) 3966dnl aclocal-1.4 backwards compatibility: 3967dnl AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], []) 3968 3969 3970# _LT_HEADER_DLFCN 3971# ---------------- 3972m4_defun([_LT_HEADER_DLFCN], 3973[AC_CHECK_HEADERS([dlfcn.h], [], [], [AC_INCLUDES_DEFAULT])dnl 3974])# _LT_HEADER_DLFCN 3975 3976 3977# _LT_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE, 3978# ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING) 3979# ---------------------------------------------------------------- 3980m4_defun([_LT_TRY_DLOPEN_SELF], 3981[m4_require([_LT_HEADER_DLFCN])dnl 3982if test "$cross_compiling" = yes; then : 3983 [$4] 3984else 3985 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 3986 lt_status=$lt_dlunknown 3987 cat > conftest.$ac_ext <<_LT_EOF 3988[#line $LINENO "configure" 3989#include "confdefs.h" 3990 3991#if HAVE_DLFCN_H 3992#include <dlfcn.h> 3993#endif 3994 3995#include <stdio.h> 3996 3997#ifdef RTLD_GLOBAL 3998# define LT_DLGLOBAL RTLD_GLOBAL 3999#else 4000# ifdef DL_GLOBAL 4001# define LT_DLGLOBAL DL_GLOBAL 4002# else 4003# define LT_DLGLOBAL 0 4004# endif 4005#endif 4006 4007/* We may have to define LT_DLLAZY_OR_NOW in the command line if we 4008 find out it does not work in some platform. */ 4009#ifndef LT_DLLAZY_OR_NOW 4010# ifdef RTLD_LAZY 4011# define LT_DLLAZY_OR_NOW RTLD_LAZY 4012# else 4013# ifdef DL_LAZY 4014# define LT_DLLAZY_OR_NOW DL_LAZY 4015# else 4016# ifdef RTLD_NOW 4017# define LT_DLLAZY_OR_NOW RTLD_NOW 4018# else 4019# ifdef DL_NOW 4020# define LT_DLLAZY_OR_NOW DL_NOW 4021# else 4022# define LT_DLLAZY_OR_NOW 0 4023# endif 4024# endif 4025# endif 4026# endif 4027#endif 4028 4029/* When -fvisbility=hidden is used, assume the code has been annotated 4030 correspondingly for the symbols needed. */ 4031#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) 4032void fnord () __attribute__((visibility("default"))); 4033#endif 4034 4035void fnord () { int i=42; } 4036int main () 4037{ 4038 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); 4039 int status = $lt_dlunknown; 4040 4041 if (self) 4042 { 4043 if (dlsym (self,"fnord")) status = $lt_dlno_uscore; 4044 else 4045 { 4046 if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; 4047 else puts (dlerror ()); 4048 } 4049 /* dlclose (self); */ 4050 } 4051 else 4052 puts (dlerror ()); 4053 4054 return status; 4055}] 4056_LT_EOF 4057 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then 4058 (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null 4059 lt_status=$? 4060 case x$lt_status in 4061 x$lt_dlno_uscore) $1 ;; 4062 x$lt_dlneed_uscore) $2 ;; 4063 x$lt_dlunknown|x*) $3 ;; 4064 esac 4065 else : 4066 # compilation failed 4067 $3 4068 fi 4069fi 4070rm -fr conftest* 4071])# _LT_TRY_DLOPEN_SELF 4072 4073 4074# LT_SYS_DLOPEN_SELF 4075# ------------------ 4076AC_DEFUN([LT_SYS_DLOPEN_SELF], 4077[m4_require([_LT_HEADER_DLFCN])dnl 4078if test "x$enable_dlopen" != xyes; then 4079 enable_dlopen=unknown 4080 enable_dlopen_self=unknown 4081 enable_dlopen_self_static=unknown 4082else 4083 lt_cv_dlopen=no 4084 lt_cv_dlopen_libs= 4085 4086 case $host_os in 4087 beos*) 4088 lt_cv_dlopen="load_add_on" 4089 lt_cv_dlopen_libs= 4090 lt_cv_dlopen_self=yes 4091 ;; 4092 4093 mingw* | pw32* | cegcc*) 4094 lt_cv_dlopen="LoadLibrary" 4095 lt_cv_dlopen_libs= 4096 ;; 4097 4098 cygwin*) 4099 lt_cv_dlopen="dlopen" 4100 lt_cv_dlopen_libs= 4101 ;; 4102 4103 darwin*) 4104 # if libdl is installed we need to link against it 4105 AC_CHECK_LIB([dl], [dlopen], 4106 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[ 4107 lt_cv_dlopen="dyld" 4108 lt_cv_dlopen_libs= 4109 lt_cv_dlopen_self=yes 4110 ]) 4111 ;; 4112 4113 *) 4114 AC_CHECK_FUNC([shl_load], 4115 [lt_cv_dlopen="shl_load"], 4116 [AC_CHECK_LIB([dld], [shl_load], 4117 [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"], 4118 [AC_CHECK_FUNC([dlopen], 4119 [lt_cv_dlopen="dlopen"], 4120 [AC_CHECK_LIB([dl], [dlopen], 4121 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"], 4122 [AC_CHECK_LIB([svld], [dlopen], 4123 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"], 4124 [AC_CHECK_LIB([dld], [dld_link], 4125 [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"]) 4126 ]) 4127 ]) 4128 ]) 4129 ]) 4130 ]) 4131 ;; 4132 esac 4133 4134 if test "x$lt_cv_dlopen" != xno; then 4135 enable_dlopen=yes 4136 else 4137 enable_dlopen=no 4138 fi 4139 4140 case $lt_cv_dlopen in 4141 dlopen) 4142 save_CPPFLAGS="$CPPFLAGS" 4143 test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" 4144 4145 save_LDFLAGS="$LDFLAGS" 4146 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" 4147 4148 save_LIBS="$LIBS" 4149 LIBS="$lt_cv_dlopen_libs $LIBS" 4150 4151 AC_CACHE_CHECK([whether a program can dlopen itself], 4152 lt_cv_dlopen_self, [dnl 4153 _LT_TRY_DLOPEN_SELF( 4154 lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes, 4155 lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross) 4156 ]) 4157 4158 if test "x$lt_cv_dlopen_self" = xyes; then 4159 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" 4160 AC_CACHE_CHECK([whether a statically linked program can dlopen itself], 4161 lt_cv_dlopen_self_static, [dnl 4162 _LT_TRY_DLOPEN_SELF( 4163 lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes, 4164 lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross) 4165 ]) 4166 fi 4167 4168 CPPFLAGS="$save_CPPFLAGS" 4169 LDFLAGS="$save_LDFLAGS" 4170 LIBS="$save_LIBS" 4171 ;; 4172 esac 4173 4174 case $lt_cv_dlopen_self in 4175 yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; 4176 *) enable_dlopen_self=unknown ;; 4177 esac 4178 4179 case $lt_cv_dlopen_self_static in 4180 yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; 4181 *) enable_dlopen_self_static=unknown ;; 4182 esac 4183fi 4184_LT_DECL([dlopen_support], [enable_dlopen], [0], 4185 [Whether dlopen is supported]) 4186_LT_DECL([dlopen_self], [enable_dlopen_self], [0], 4187 [Whether dlopen of programs is supported]) 4188_LT_DECL([dlopen_self_static], [enable_dlopen_self_static], [0], 4189 [Whether dlopen of statically linked programs is supported]) 4190])# LT_SYS_DLOPEN_SELF 4191 4192# Old name: 4193AU_ALIAS([AC_LIBTOOL_DLOPEN_SELF], [LT_SYS_DLOPEN_SELF]) 4194dnl aclocal-1.4 backwards compatibility: 4195dnl AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], []) 4196 4197 4198# _LT_COMPILER_C_O([TAGNAME]) 4199# --------------------------- 4200# Check to see if options -c and -o are simultaneously supported by compiler. 4201# This macro does not hard code the compiler like AC_PROG_CC_C_O. 4202m4_defun([_LT_COMPILER_C_O], 4203[m4_require([_LT_DECL_SED])dnl 4204m4_require([_LT_FILEUTILS_DEFAULTS])dnl 4205m4_require([_LT_TAG_COMPILER])dnl 4206AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext], 4207 [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)], 4208 [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no 4209 $RM -r conftest 2>/dev/null 4210 mkdir conftest 4211 cd conftest 4212 mkdir out 4213 echo "$lt_simple_compile_test_code" > conftest.$ac_ext 4214 4215 lt_compiler_flag="-o out/conftest2.$ac_objext" 4216 # Insert the option either (1) after the last *FLAGS variable, or 4217 # (2) before a word containing "conftest.", or (3) at the end. 4218 # Note that $ac_compile itself does not contain backslashes and begins 4219 # with a dollar sign (not a hyphen), so the echo should work correctly. 4220 lt_compile=`echo "$ac_compile" | $SED \ 4221 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ 4222 -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ 4223 -e 's:$: $lt_compiler_flag:'` 4224 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD) 4225 (eval "$lt_compile" 2>out/conftest.err) 4226 ac_status=$? 4227 cat out/conftest.err >&AS_MESSAGE_LOG_FD 4228 echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD 4229 if (exit $ac_status) && test -s out/conftest2.$ac_objext 4230 then 4231 # The compiler can only warn and ignore the option if not recognized 4232 # So say no if there are warnings 4233 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp 4234 $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 4235 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then 4236 _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes 4237 fi 4238 fi 4239 chmod u+w . 2>&AS_MESSAGE_LOG_FD 4240 $RM conftest* 4241 # SGI C++ compiler will create directory out/ii_files/ for 4242 # template instantiation 4243 test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files 4244 $RM out/* && rmdir out 4245 cd .. 4246 $RM -r conftest 4247 $RM conftest* 4248]) 4249_LT_TAGDECL([compiler_c_o], [lt_cv_prog_compiler_c_o], [1], 4250 [Does compiler simultaneously support -c and -o options?]) 4251])# _LT_COMPILER_C_O 4252 4253 4254# _LT_COMPILER_FILE_LOCKS([TAGNAME]) 4255# ---------------------------------- 4256# Check to see if we can do hard links to lock some files if needed 4257m4_defun([_LT_COMPILER_FILE_LOCKS], 4258[m4_require([_LT_ENABLE_LOCK])dnl 4259m4_require([_LT_FILEUTILS_DEFAULTS])dnl 4260_LT_COMPILER_C_O([$1]) 4261 4262hard_links="nottested" 4263if test "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then 4264 # do not overwrite the value of need_locks provided by the user 4265 AC_MSG_CHECKING([if we can lock with hard links]) 4266 hard_links=yes 4267 $RM conftest* 4268 ln conftest.a conftest.b 2>/dev/null && hard_links=no 4269 touch conftest.a 4270 ln conftest.a conftest.b 2>&5 || hard_links=no 4271 ln conftest.a conftest.b 2>/dev/null && hard_links=no 4272 AC_MSG_RESULT([$hard_links]) 4273 if test "$hard_links" = no; then 4274 AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe]) 4275 need_locks=warn 4276 fi 4277else 4278 need_locks=no 4279fi 4280_LT_DECL([], [need_locks], [1], [Must we lock files when doing compilation?]) 4281])# _LT_COMPILER_FILE_LOCKS 4282 4283 4284# _LT_CHECK_OBJDIR 4285# ---------------- 4286m4_defun([_LT_CHECK_OBJDIR], 4287[AC_CACHE_CHECK([for objdir], [lt_cv_objdir], 4288[rm -f .libs 2>/dev/null 4289mkdir .libs 2>/dev/null 4290if test -d .libs; then 4291 lt_cv_objdir=.libs 4292else 4293 # MS-DOS does not allow filenames that begin with a dot. 4294 lt_cv_objdir=_libs 4295fi 4296rmdir .libs 2>/dev/null]) 4297objdir=$lt_cv_objdir 4298_LT_DECL([], [objdir], [0], 4299 [The name of the directory that contains temporary libtool files])dnl 4300m4_pattern_allow([LT_OBJDIR])dnl 4301AC_DEFINE_UNQUOTED(LT_OBJDIR, "$lt_cv_objdir/", 4302 [Define to the sub-directory in which libtool stores uninstalled libraries.]) 4303])# _LT_CHECK_OBJDIR 4304 4305 4306# _LT_LINKER_HARDCODE_LIBPATH([TAGNAME]) 4307# -------------------------------------- 4308# Check hardcoding attributes. 4309m4_defun([_LT_LINKER_HARDCODE_LIBPATH], 4310[AC_MSG_CHECKING([how to hardcode library paths into programs]) 4311_LT_TAGVAR(hardcode_action, $1)= 4312if test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" || 4313 test -n "$_LT_TAGVAR(runpath_var, $1)" || 4314 test "X$_LT_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then 4315 4316 # We can hardcode non-existent directories. 4317 if test "$_LT_TAGVAR(hardcode_direct, $1)" != no && 4318 # If the only mechanism to avoid hardcoding is shlibpath_var, we 4319 # have to relink, otherwise we might link with an installed library 4320 # when we should be linking with a yet-to-be-installed one 4321 ## test "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" != no && 4322 test "$_LT_TAGVAR(hardcode_minus_L, $1)" != no; then 4323 # Linking always hardcodes the temporary library directory. 4324 _LT_TAGVAR(hardcode_action, $1)=relink 4325 else 4326 # We can link without hardcoding, and we can hardcode nonexisting dirs. 4327 _LT_TAGVAR(hardcode_action, $1)=immediate 4328 fi 4329else 4330 # We cannot hardcode anything, or else we can only hardcode existing 4331 # directories. 4332 _LT_TAGVAR(hardcode_action, $1)=unsupported 4333fi 4334AC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)]) 4335 4336if test "$_LT_TAGVAR(hardcode_action, $1)" = relink || 4337 test "$_LT_TAGVAR(inherit_rpath, $1)" = yes; then 4338 # Fast installation is not supported 4339 enable_fast_install=no 4340elif test "$shlibpath_overrides_runpath" = yes || 4341 test "$enable_shared" = no; then 4342 # Fast installation is not necessary 4343 enable_fast_install=needless 4344fi 4345_LT_TAGDECL([], [hardcode_action], [0], 4346 [How to hardcode a shared library path into an executable]) 4347])# _LT_LINKER_HARDCODE_LIBPATH 4348 4349 4350# _LT_CMD_STRIPLIB 4351# ---------------- 4352m4_defun([_LT_CMD_STRIPLIB], 4353[m4_require([_LT_DECL_EGREP]) 4354striplib= 4355old_striplib= 4356AC_MSG_CHECKING([whether stripping libraries is possible]) 4357if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then 4358 test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" 4359 test -z "$striplib" && striplib="$STRIP --strip-unneeded" 4360 AC_MSG_RESULT([yes]) 4361else 4362# FIXME - insert some real tests, host_os isn't really good enough 4363 case $host_os in 4364 darwin*) 4365 if test -n "$STRIP" ; then 4366 striplib="$STRIP -x" 4367 old_striplib="$STRIP -S" 4368 AC_MSG_RESULT([yes]) 4369 else 4370 AC_MSG_RESULT([no]) 4371 fi 4372 ;; 4373 *) 4374 AC_MSG_RESULT([no]) 4375 ;; 4376 esac 4377fi 4378_LT_DECL([], [old_striplib], [1], [Commands to strip libraries]) 4379_LT_DECL([], [striplib], [1]) 4380])# _LT_CMD_STRIPLIB 4381 4382 4383# _LT_SYS_DYNAMIC_LINKER([TAG]) 4384# ----------------------------- 4385# PORTME Fill in your ld.so characteristics 4386m4_defun([_LT_SYS_DYNAMIC_LINKER], 4387[AC_REQUIRE([AC_CANONICAL_HOST])dnl 4388m4_require([_LT_DECL_EGREP])dnl 4389m4_require([_LT_FILEUTILS_DEFAULTS])dnl 4390m4_require([_LT_DECL_OBJDUMP])dnl 4391m4_require([_LT_DECL_SED])dnl 4392m4_require([_LT_CHECK_SHELL_FEATURES])dnl 4393AC_MSG_CHECKING([dynamic linker characteristics]) 4394m4_if([$1], 4395 [], [ 4396if test "$GCC" = yes; then 4397 case $host_os in 4398 darwin*) lt_awk_arg="/^libraries:/,/LR/" ;; 4399 *) lt_awk_arg="/^libraries:/" ;; 4400 esac 4401 case $host_os in 4402 mingw* | cegcc*) lt_sed_strip_eq="s,=\([[A-Za-z]]:\),\1,g" ;; 4403 *) lt_sed_strip_eq="s,=/,/,g" ;; 4404 esac 4405 lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq` 4406 case $lt_search_path_spec in 4407 *\;*) 4408 # if the path contains ";" then we assume it to be the separator 4409 # otherwise default to the standard path separator (i.e. ":") - it is 4410 # assumed that no part of a normal pathname contains ";" but that should 4411 # okay in the real world where ";" in dirpaths is itself problematic. 4412 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'` 4413 ;; 4414 *) 4415 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"` 4416 ;; 4417 esac 4418 # Ok, now we have the path, separated by spaces, we can step through it 4419 # and add multilib dir if necessary. 4420 lt_tmp_lt_search_path_spec= 4421 lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` 4422 for lt_sys_path in $lt_search_path_spec; do 4423 if test -d "$lt_sys_path/$lt_multi_os_dir"; then 4424 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir" 4425 else 4426 test -d "$lt_sys_path" && \ 4427 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" 4428 fi 4429 done 4430 lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk ' 4431BEGIN {RS=" "; FS="/|\n";} { 4432 lt_foo=""; 4433 lt_count=0; 4434 for (lt_i = NF; lt_i > 0; lt_i--) { 4435 if ($lt_i != "" && $lt_i != ".") { 4436 if ($lt_i == "..") { 4437 lt_count++; 4438 } else { 4439 if (lt_count == 0) { 4440 lt_foo="/" $lt_i lt_foo; 4441 } else { 4442 lt_count--; 4443 } 4444 } 4445 } 4446 } 4447 if (lt_foo != "") { lt_freq[[lt_foo]]++; } 4448 if (lt_freq[[lt_foo]] == 1) { print lt_foo; } 4449}'` 4450 # AWK program above erroneously prepends '/' to C:/dos/paths 4451 # for these hosts. 4452 case $host_os in 4453 mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ 4454 $SED 's,/\([[A-Za-z]]:\),\1,g'` ;; 4455 esac 4456 sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP` 4457else 4458 sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" 4459fi]) 4460library_names_spec= 4461libname_spec='lib$name' 4462soname_spec= 4463shrext_cmds=".so" 4464postinstall_cmds= 4465postuninstall_cmds= 4466finish_cmds= 4467finish_eval= 4468shlibpath_var= 4469shlibpath_overrides_runpath=unknown 4470version_type=none 4471dynamic_linker="$host_os ld.so" 4472sys_lib_dlsearch_path_spec="/lib /usr/lib" 4473need_lib_prefix=unknown 4474hardcode_into_libs=no 4475 4476# when you set need_version to no, make sure it does not cause -set_version 4477# flags to be left without arguments 4478need_version=unknown 4479 4480case $host_os in 4481aix3*) 4482 version_type=linux 4483 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' 4484 shlibpath_var=LIBPATH 4485 4486 # AIX 3 has no versioning support, so we append a major version to the name. 4487 soname_spec='${libname}${release}${shared_ext}$major' 4488 ;; 4489 4490aix[[4-9]]*) 4491 version_type=linux 4492 need_lib_prefix=no 4493 need_version=no 4494 hardcode_into_libs=yes 4495 if test "$host_cpu" = ia64; then 4496 # AIX 5 supports IA64 4497 library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' 4498 shlibpath_var=LD_LIBRARY_PATH 4499 else 4500 # With GCC up to 2.95.x, collect2 would create an import file 4501 # for dependence libraries. The import file would start with 4502 # the line `#! .'. This would cause the generated library to 4503 # depend on `.', always an invalid library. This was fixed in 4504 # development snapshots of GCC prior to 3.0. 4505 case $host_os in 4506 aix4 | aix4.[[01]] | aix4.[[01]].*) 4507 if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' 4508 echo ' yes ' 4509 echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then 4510 : 4511 else 4512 can_build_shared=no 4513 fi 4514 ;; 4515 esac 4516 # AIX (on Power*) has no versioning support, so currently we can not hardcode correct 4517 # soname into executable. Probably we can add versioning support to 4518 # collect2, so additional links can be useful in future. 4519 if test "$aix_use_runtimelinking" = yes; then 4520 # If using run time linking (on AIX 4.2 or later) use lib<name>.so 4521 # instead of lib<name>.a to let people know that these are not 4522 # typical AIX shared libraries. 4523 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 4524 else 4525 # We preserve .a as extension for shared libraries through AIX4.2 4526 # and later when we are not doing run time linking. 4527 library_names_spec='${libname}${release}.a $libname.a' 4528 soname_spec='${libname}${release}${shared_ext}$major' 4529 fi 4530 shlibpath_var=LIBPATH 4531 fi 4532 ;; 4533 4534amigaos*) 4535 case $host_cpu in 4536 powerpc) 4537 # Since July 2007 AmigaOS4 officially supports .so libraries. 4538 # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. 4539 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 4540 ;; 4541 m68k) 4542 library_names_spec='$libname.ixlibrary $libname.a' 4543 # Create ${libname}_ixlibrary.a entries in /sys/libs. 4544 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' 4545 ;; 4546 esac 4547 ;; 4548 4549beos*) 4550 library_names_spec='${libname}${shared_ext}' 4551 dynamic_linker="$host_os ld.so" 4552 shlibpath_var=LIBRARY_PATH 4553 ;; 4554 4555bsdi[[45]]*) 4556 version_type=linux 4557 need_version=no 4558 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 4559 soname_spec='${libname}${release}${shared_ext}$major' 4560 finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' 4561 shlibpath_var=LD_LIBRARY_PATH 4562 sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" 4563 sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" 4564 # the default ld.so.conf also contains /usr/contrib/lib and 4565 # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow 4566 # libtool to hard-code these into programs 4567 ;; 4568 4569cygwin* | mingw* | pw32* | cegcc*) 4570 version_type=windows 4571 shrext_cmds=".dll" 4572 need_version=no 4573 need_lib_prefix=no 4574 4575 case $GCC,$host_os in 4576 yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*) 4577 library_names_spec='$libname.dll.a' 4578 # DLL is installed to $(libdir)/../bin by postinstall_cmds 4579 postinstall_cmds='base_file=`basename \${file}`~ 4580 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ 4581 dldir=$destdir/`dirname \$dlpath`~ 4582 test -d \$dldir || mkdir -p \$dldir~ 4583 $install_prog $dir/$dlname \$dldir/$dlname~ 4584 chmod a+x \$dldir/$dlname~ 4585 if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then 4586 eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; 4587 fi' 4588 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ 4589 dlpath=$dir/\$dldll~ 4590 $RM \$dlpath' 4591 shlibpath_overrides_runpath=yes 4592 4593 case $host_os in 4594 cygwin*) 4595 # Cygwin DLLs use 'cyg' prefix rather than 'lib' 4596 soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' 4597m4_if([$1], [],[ 4598 sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"]) 4599 ;; 4600 mingw* | cegcc*) 4601 # MinGW DLLs use traditional 'lib' prefix 4602 soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' 4603 ;; 4604 pw32*) 4605 # pw32 DLLs use 'pw' prefix rather than 'lib' 4606 library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' 4607 ;; 4608 esac 4609 ;; 4610 4611 *) 4612 library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib' 4613 ;; 4614 esac 4615 dynamic_linker='Win32 ld.exe' 4616 # FIXME: first we should search . and the directory the executable is in 4617 shlibpath_var=PATH 4618 ;; 4619 4620darwin* | rhapsody*) 4621 dynamic_linker="$host_os dyld" 4622 version_type=darwin 4623 need_lib_prefix=no 4624 need_version=no 4625 library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext' 4626 soname_spec='${libname}${release}${major}$shared_ext' 4627 shlibpath_overrides_runpath=yes 4628 shlibpath_var=DYLD_LIBRARY_PATH 4629 shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' 4630m4_if([$1], [],[ 4631 sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"]) 4632 sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' 4633 ;; 4634 4635dgux*) 4636 version_type=linux 4637 need_lib_prefix=no 4638 need_version=no 4639 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' 4640 soname_spec='${libname}${release}${shared_ext}$major' 4641 shlibpath_var=LD_LIBRARY_PATH 4642 ;; 4643 4644freebsd1*) 4645 dynamic_linker=no 4646 ;; 4647 4648freebsd* | dragonfly*) 4649 # DragonFly does not have aout. When/if they implement a new 4650 # versioning mechanism, adjust this. 4651 if test -x /usr/bin/objformat; then 4652 objformat=`/usr/bin/objformat` 4653 else 4654 case $host_os in 4655 freebsd[[123]]*) objformat=aout ;; 4656 *) objformat=elf ;; 4657 esac 4658 fi 4659 version_type=freebsd-$objformat 4660 case $version_type in 4661 freebsd-elf*) 4662 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' 4663 need_version=no 4664 need_lib_prefix=no 4665 ;; 4666 freebsd-*) 4667 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' 4668 need_version=yes 4669 ;; 4670 esac 4671 shlibpath_var=LD_LIBRARY_PATH 4672 case $host_os in 4673 freebsd2*) 4674 shlibpath_overrides_runpath=yes 4675 ;; 4676 freebsd3.[[01]]* | freebsdelf3.[[01]]*) 4677 shlibpath_overrides_runpath=yes 4678 hardcode_into_libs=yes 4679 ;; 4680 freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \ 4681 freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1) 4682 shlibpath_overrides_runpath=no 4683 hardcode_into_libs=yes 4684 ;; 4685 *) # from 4.6 on, and DragonFly 4686 shlibpath_overrides_runpath=yes 4687 hardcode_into_libs=yes 4688 ;; 4689 esac 4690 ;; 4691 4692gnu*) 4693 version_type=linux 4694 need_lib_prefix=no 4695 need_version=no 4696 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' 4697 soname_spec='${libname}${release}${shared_ext}$major' 4698 shlibpath_var=LD_LIBRARY_PATH 4699 hardcode_into_libs=yes 4700 ;; 4701 4702haiku*) 4703 version_type=linux 4704 need_lib_prefix=no 4705 need_version=no 4706 dynamic_linker="$host_os runtime_loader" 4707 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' 4708 soname_spec='${libname}${release}${shared_ext}$major' 4709 shlibpath_var=LIBRARY_PATH 4710 shlibpath_overrides_runpath=yes 4711 sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' 4712 hardcode_into_libs=yes 4713 ;; 4714 4715hpux9* | hpux10* | hpux11*) 4716 # Give a soname corresponding to the major version so that dld.sl refuses to 4717 # link against other versions. 4718 version_type=sunos 4719 need_lib_prefix=no 4720 need_version=no 4721 case $host_cpu in 4722 ia64*) 4723 shrext_cmds='.so' 4724 hardcode_into_libs=yes 4725 dynamic_linker="$host_os dld.so" 4726 shlibpath_var=LD_LIBRARY_PATH 4727 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. 4728 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 4729 soname_spec='${libname}${release}${shared_ext}$major' 4730 if test "X$HPUX_IA64_MODE" = X32; then 4731 sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" 4732 else 4733 sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" 4734 fi 4735 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec 4736 ;; 4737 hppa*64*) 4738 shrext_cmds='.sl' 4739 hardcode_into_libs=yes 4740 dynamic_linker="$host_os dld.sl" 4741 shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH 4742 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. 4743 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 4744 soname_spec='${libname}${release}${shared_ext}$major' 4745 sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" 4746 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec 4747 ;; 4748 *) 4749 shrext_cmds='.sl' 4750 dynamic_linker="$host_os dld.sl" 4751 shlibpath_var=SHLIB_PATH 4752 shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH 4753 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 4754 soname_spec='${libname}${release}${shared_ext}$major' 4755 ;; 4756 esac 4757 # HP-UX runs *really* slowly unless shared libraries are mode 555, ... 4758 postinstall_cmds='chmod 555 $lib' 4759 # or fails outright, so override atomically: 4760 install_override_mode=555 4761 ;; 4762 4763interix[[3-9]]*) 4764 version_type=linux 4765 need_lib_prefix=no 4766 need_version=no 4767 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' 4768 soname_spec='${libname}${release}${shared_ext}$major' 4769 dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' 4770 shlibpath_var=LD_LIBRARY_PATH 4771 shlibpath_overrides_runpath=no 4772 hardcode_into_libs=yes 4773 ;; 4774 4775irix5* | irix6* | nonstopux*) 4776 case $host_os in 4777 nonstopux*) version_type=nonstopux ;; 4778 *) 4779 if test "$lt_cv_prog_gnu_ld" = yes; then 4780 version_type=linux 4781 else 4782 version_type=irix 4783 fi ;; 4784 esac 4785 need_lib_prefix=no 4786 need_version=no 4787 soname_spec='${libname}${release}${shared_ext}$major' 4788 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' 4789 case $host_os in 4790 irix5* | nonstopux*) 4791 libsuff= shlibsuff= 4792 ;; 4793 *) 4794 case $LD in # libtool.m4 will add one of these switches to LD 4795 *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") 4796 libsuff= shlibsuff= libmagic=32-bit;; 4797 *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") 4798 libsuff=32 shlibsuff=N32 libmagic=N32;; 4799 *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") 4800 libsuff=64 shlibsuff=64 libmagic=64-bit;; 4801 *) libsuff= shlibsuff= libmagic=never-match;; 4802 esac 4803 ;; 4804 esac 4805 shlibpath_var=LD_LIBRARY${shlibsuff}_PATH 4806 shlibpath_overrides_runpath=no 4807 sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" 4808 sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" 4809 hardcode_into_libs=yes 4810 ;; 4811 4812# No shared lib support for Linux oldld, aout, or coff. 4813linux*oldld* | linux*aout* | linux*coff*) 4814 dynamic_linker=no 4815 ;; 4816 4817# This must be Linux ELF. 4818linux* | k*bsd*-gnu | kopensolaris*-gnu) 4819 version_type=linux 4820 need_lib_prefix=no 4821 need_version=no 4822 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 4823 soname_spec='${libname}${release}${shared_ext}$major' 4824 finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' 4825 shlibpath_var=LD_LIBRARY_PATH 4826 shlibpath_overrides_runpath=no 4827 4828 # Some binutils ld are patched to set DT_RUNPATH 4829 AC_CACHE_VAL([lt_cv_shlibpath_overrides_runpath], 4830 [lt_cv_shlibpath_overrides_runpath=no 4831 save_LDFLAGS=$LDFLAGS 4832 save_libdir=$libdir 4833 eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \ 4834 LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\"" 4835 AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], 4836 [AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null], 4837 [lt_cv_shlibpath_overrides_runpath=yes])]) 4838 LDFLAGS=$save_LDFLAGS 4839 libdir=$save_libdir 4840 ]) 4841 shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath 4842 4843 # This implies no fast_install, which is unacceptable. 4844 # Some rework will be needed to allow for fast_install 4845 # before this can be enabled. 4846 hardcode_into_libs=yes 4847 4848 # Append ld.so.conf contents to the search path 4849 if test -f /etc/ld.so.conf; then 4850 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' ' '` 4851 sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" 4852 fi 4853 4854 # We used to test for /lib/ld.so.1 and disable shared libraries on 4855 # powerpc, because MkLinux only supported shared libraries with the 4856 # GNU dynamic linker. Since this was broken with cross compilers, 4857 # most powerpc-linux boxes support dynamic linking these days and 4858 # people can always --disable-shared, the test was removed, and we 4859 # assume the GNU/Linux dynamic linker is in use. 4860 dynamic_linker='GNU/Linux ld.so' 4861 ;; 4862 4863netbsd*) 4864 version_type=sunos 4865 need_lib_prefix=no 4866 need_version=no 4867 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then 4868 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' 4869 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' 4870 dynamic_linker='NetBSD (a.out) ld.so' 4871 else 4872 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' 4873 soname_spec='${libname}${release}${shared_ext}$major' 4874 dynamic_linker='NetBSD ld.elf_so' 4875 fi 4876 shlibpath_var=LD_LIBRARY_PATH 4877 shlibpath_overrides_runpath=yes 4878 hardcode_into_libs=yes 4879 ;; 4880 4881newsos6) 4882 version_type=linux 4883 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 4884 shlibpath_var=LD_LIBRARY_PATH 4885 shlibpath_overrides_runpath=yes 4886 ;; 4887 4888*nto* | *qnx*) 4889 version_type=qnx 4890 need_lib_prefix=no 4891 need_version=no 4892 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 4893 soname_spec='${libname}${release}${shared_ext}$major' 4894 shlibpath_var=LD_LIBRARY_PATH 4895 shlibpath_overrides_runpath=no 4896 hardcode_into_libs=yes 4897 dynamic_linker='ldqnx.so' 4898 ;; 4899 4900openbsd*) 4901 version_type=sunos 4902 sys_lib_dlsearch_path_spec="/usr/lib" 4903 need_lib_prefix=no 4904 # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. 4905 case $host_os in 4906 openbsd3.3 | openbsd3.3.*) need_version=yes ;; 4907 *) need_version=no ;; 4908 esac 4909 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' 4910 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' 4911 shlibpath_var=LD_LIBRARY_PATH 4912 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then 4913 case $host_os in 4914 openbsd2.[[89]] | openbsd2.[[89]].*) 4915 shlibpath_overrides_runpath=no 4916 ;; 4917 *) 4918 shlibpath_overrides_runpath=yes 4919 ;; 4920 esac 4921 else 4922 shlibpath_overrides_runpath=yes 4923 fi 4924 ;; 4925 4926os2*) 4927 libname_spec='$name' 4928 shrext_cmds=".dll" 4929 need_lib_prefix=no 4930 library_names_spec='$libname${shared_ext} $libname.a' 4931 dynamic_linker='OS/2 ld.exe' 4932 shlibpath_var=LIBPATH 4933 ;; 4934 4935osf3* | osf4* | osf5*) 4936 version_type=osf 4937 need_lib_prefix=no 4938 need_version=no 4939 soname_spec='${libname}${release}${shared_ext}$major' 4940 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 4941 shlibpath_var=LD_LIBRARY_PATH 4942 sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" 4943 sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" 4944 ;; 4945 4946rdos*) 4947 dynamic_linker=no 4948 ;; 4949 4950solaris*) 4951 version_type=linux 4952 need_lib_prefix=no 4953 need_version=no 4954 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 4955 soname_spec='${libname}${release}${shared_ext}$major' 4956 shlibpath_var=LD_LIBRARY_PATH 4957 shlibpath_overrides_runpath=yes 4958 hardcode_into_libs=yes 4959 # ldd complains unless libraries are executable 4960 postinstall_cmds='chmod +x $lib' 4961 ;; 4962 4963sunos4*) 4964 version_type=sunos 4965 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' 4966 finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' 4967 shlibpath_var=LD_LIBRARY_PATH 4968 shlibpath_overrides_runpath=yes 4969 if test "$with_gnu_ld" = yes; then 4970 need_lib_prefix=no 4971 fi 4972 need_version=yes 4973 ;; 4974 4975sysv4 | sysv4.3*) 4976 version_type=linux 4977 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 4978 soname_spec='${libname}${release}${shared_ext}$major' 4979 shlibpath_var=LD_LIBRARY_PATH 4980 case $host_vendor in 4981 sni) 4982 shlibpath_overrides_runpath=no 4983 need_lib_prefix=no 4984 runpath_var=LD_RUN_PATH 4985 ;; 4986 siemens) 4987 need_lib_prefix=no 4988 ;; 4989 motorola) 4990 need_lib_prefix=no 4991 need_version=no 4992 shlibpath_overrides_runpath=no 4993 sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' 4994 ;; 4995 esac 4996 ;; 4997 4998sysv4*MP*) 4999 if test -d /usr/nec ;then 5000 version_type=linux 5001 library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' 5002 soname_spec='$libname${shared_ext}.$major' 5003 shlibpath_var=LD_LIBRARY_PATH 5004 fi 5005 ;; 5006 5007sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) 5008 version_type=freebsd-elf 5009 need_lib_prefix=no 5010 need_version=no 5011 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' 5012 soname_spec='${libname}${release}${shared_ext}$major' 5013 shlibpath_var=LD_LIBRARY_PATH 5014 shlibpath_overrides_runpath=yes 5015 hardcode_into_libs=yes 5016 if test "$with_gnu_ld" = yes; then 5017 sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' 5018 else 5019 sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' 5020 case $host_os in 5021 sco3.2v5*) 5022 sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" 5023 ;; 5024 esac 5025 fi 5026 sys_lib_dlsearch_path_spec='/usr/lib' 5027 ;; 5028 5029tpf*) 5030 # TPF is a cross-target only. Preferred cross-host = GNU/Linux. 5031 version_type=linux 5032 need_lib_prefix=no 5033 need_version=no 5034 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 5035 shlibpath_var=LD_LIBRARY_PATH 5036 shlibpath_overrides_runpath=no 5037 hardcode_into_libs=yes 5038 ;; 5039 5040uts4*) 5041 version_type=linux 5042 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 5043 soname_spec='${libname}${release}${shared_ext}$major' 5044 shlibpath_var=LD_LIBRARY_PATH 5045 ;; 5046 5047*) 5048 dynamic_linker=no 5049 ;; 5050esac 5051AC_MSG_RESULT([$dynamic_linker]) 5052test "$dynamic_linker" = no && can_build_shared=no 5053 5054variables_saved_for_relink="PATH $shlibpath_var $runpath_var" 5055if test "$GCC" = yes; then 5056 variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" 5057fi 5058 5059if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then 5060 sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" 5061fi 5062if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then 5063 sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" 5064fi 5065 5066_LT_DECL([], [variables_saved_for_relink], [1], 5067 [Variables whose values should be saved in libtool wrapper scripts and 5068 restored at link time]) 5069_LT_DECL([], [need_lib_prefix], [0], 5070 [Do we need the "lib" prefix for modules?]) 5071_LT_DECL([], [need_version], [0], [Do we need a version for libraries?]) 5072_LT_DECL([], [version_type], [0], [Library versioning type]) 5073_LT_DECL([], [runpath_var], [0], [Shared library runtime path variable]) 5074_LT_DECL([], [shlibpath_var], [0],[Shared library path variable]) 5075_LT_DECL([], [shlibpath_overrides_runpath], [0], 5076 [Is shlibpath searched before the hard-coded library search path?]) 5077_LT_DECL([], [libname_spec], [1], [Format of library name prefix]) 5078_LT_DECL([], [library_names_spec], [1], 5079 [[List of archive names. First name is the real one, the rest are links. 5080 The last name is the one that the linker finds with -lNAME]]) 5081_LT_DECL([], [soname_spec], [1], 5082 [[The coded name of the library, if different from the real name]]) 5083_LT_DECL([], [install_override_mode], [1], 5084 [Permission mode override for installation of shared libraries]) 5085_LT_DECL([], [postinstall_cmds], [2], 5086 [Command to use after installation of a shared archive]) 5087_LT_DECL([], [postuninstall_cmds], [2], 5088 [Command to use after uninstallation of a shared archive]) 5089_LT_DECL([], [finish_cmds], [2], 5090 [Commands used to finish a libtool library installation in a directory]) 5091_LT_DECL([], [finish_eval], [1], 5092 [[As "finish_cmds", except a single script fragment to be evaled but 5093 not shown]]) 5094_LT_DECL([], [hardcode_into_libs], [0], 5095 [Whether we should hardcode library paths into libraries]) 5096_LT_DECL([], [sys_lib_search_path_spec], [2], 5097 [Compile-time system search path for libraries]) 5098_LT_DECL([], [sys_lib_dlsearch_path_spec], [2], 5099 [Run-time system search path for libraries]) 5100])# _LT_SYS_DYNAMIC_LINKER 5101 5102 5103# _LT_PATH_TOOL_PREFIX(TOOL) 5104# -------------------------- 5105# find a file program which can recognize shared library 5106AC_DEFUN([_LT_PATH_TOOL_PREFIX], 5107[m4_require([_LT_DECL_EGREP])dnl 5108AC_MSG_CHECKING([for $1]) 5109AC_CACHE_VAL(lt_cv_path_MAGIC_CMD, 5110[case $MAGIC_CMD in 5111[[\\/*] | ?:[\\/]*]) 5112 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. 5113 ;; 5114*) 5115 lt_save_MAGIC_CMD="$MAGIC_CMD" 5116 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR 5117dnl $ac_dummy forces splitting on constant user-supplied paths. 5118dnl POSIX.2 word splitting is done only on the output of word expansions, 5119dnl not every word. This closes a longstanding sh security hole. 5120 ac_dummy="m4_if([$2], , $PATH, [$2])" 5121 for ac_dir in $ac_dummy; do 5122 IFS="$lt_save_ifs" 5123 test -z "$ac_dir" && ac_dir=. 5124 if test -f $ac_dir/$1; then 5125 lt_cv_path_MAGIC_CMD="$ac_dir/$1" 5126 if test -n "$file_magic_test_file"; then 5127 case $deplibs_check_method in 5128 "file_magic "*) 5129 file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` 5130 MAGIC_CMD="$lt_cv_path_MAGIC_CMD" 5131 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | 5132 $EGREP "$file_magic_regex" > /dev/null; then 5133 : 5134 else 5135 cat <<_LT_EOF 1>&2 5136 5137*** Warning: the command libtool uses to detect shared libraries, 5138*** $file_magic_cmd, produces output that libtool cannot recognize. 5139*** The result is that libtool may fail to recognize shared libraries 5140*** as such. This will affect the creation of libtool libraries that 5141*** depend on shared libraries, but programs linked with such libtool 5142*** libraries will work regardless of this problem. Nevertheless, you 5143*** may want to report the problem to your system manager and/or to 5144*** bug-libtool@gnu.org 5145 5146_LT_EOF 5147 fi ;; 5148 esac 5149 fi 5150 break 5151 fi 5152 done 5153 IFS="$lt_save_ifs" 5154 MAGIC_CMD="$lt_save_MAGIC_CMD" 5155 ;; 5156esac]) 5157MAGIC_CMD="$lt_cv_path_MAGIC_CMD" 5158if test -n "$MAGIC_CMD"; then 5159 AC_MSG_RESULT($MAGIC_CMD) 5160else 5161 AC_MSG_RESULT(no) 5162fi 5163_LT_DECL([], [MAGIC_CMD], [0], 5164 [Used to examine libraries when file_magic_cmd begins with "file"])dnl 5165])# _LT_PATH_TOOL_PREFIX 5166 5167# Old name: 5168AU_ALIAS([AC_PATH_TOOL_PREFIX], [_LT_PATH_TOOL_PREFIX]) 5169dnl aclocal-1.4 backwards compatibility: 5170dnl AC_DEFUN([AC_PATH_TOOL_PREFIX], []) 5171 5172 5173# _LT_PATH_MAGIC 5174# -------------- 5175# find a file program which can recognize a shared library 5176m4_defun([_LT_PATH_MAGIC], 5177[_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH) 5178if test -z "$lt_cv_path_MAGIC_CMD"; then 5179 if test -n "$ac_tool_prefix"; then 5180 _LT_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH) 5181 else 5182 MAGIC_CMD=: 5183 fi 5184fi 5185])# _LT_PATH_MAGIC 5186 5187 5188# LT_PATH_LD 5189# ---------- 5190# find the pathname to the GNU or non-GNU linker 5191AC_DEFUN([LT_PATH_LD], 5192[AC_REQUIRE([AC_PROG_CC])dnl 5193AC_REQUIRE([AC_CANONICAL_HOST])dnl 5194AC_REQUIRE([AC_CANONICAL_BUILD])dnl 5195m4_require([_LT_DECL_SED])dnl 5196m4_require([_LT_DECL_EGREP])dnl 5197m4_require([_LT_PROG_ECHO_BACKSLASH])dnl 5198 5199AC_ARG_WITH([gnu-ld], 5200 [AS_HELP_STRING([--with-gnu-ld], 5201 [assume the C compiler uses GNU ld @<:@default=no@:>@])], 5202 [test "$withval" = no || with_gnu_ld=yes], 5203 [with_gnu_ld=no])dnl 5204 5205ac_prog=ld 5206if test "$GCC" = yes; then 5207 # Check if gcc -print-prog-name=ld gives a path. 5208 AC_MSG_CHECKING([for ld used by $CC]) 5209 case $host in 5210 *-*-mingw*) 5211 # gcc leaves a trailing carriage return which upsets mingw 5212 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; 5213 *) 5214 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; 5215 esac 5216 case $ac_prog in 5217 # Accept absolute paths. 5218 [[\\/]]* | ?:[[\\/]]*) 5219 re_direlt='/[[^/]][[^/]]*/\.\./' 5220 # Canonicalize the pathname of ld 5221 ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` 5222 while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do 5223 ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` 5224 done 5225 test -z "$LD" && LD="$ac_prog" 5226 ;; 5227 "") 5228 # If it fails, then pretend we aren't using GCC. 5229 ac_prog=ld 5230 ;; 5231 *) 5232 # If it is relative, then search for the first ld in PATH. 5233 with_gnu_ld=unknown 5234 ;; 5235 esac 5236elif test "$with_gnu_ld" = yes; then 5237 AC_MSG_CHECKING([for GNU ld]) 5238else 5239 AC_MSG_CHECKING([for non-GNU ld]) 5240fi 5241AC_CACHE_VAL(lt_cv_path_LD, 5242[if test -z "$LD"; then 5243 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR 5244 for ac_dir in $PATH; do 5245 IFS="$lt_save_ifs" 5246 test -z "$ac_dir" && ac_dir=. 5247 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then 5248 lt_cv_path_LD="$ac_dir/$ac_prog" 5249 # Check to see if the program is GNU ld. I'd rather use --version, 5250 # but apparently some variants of GNU ld only accept -v. 5251 # Break only if it was the GNU/non-GNU ld that we prefer. 5252 case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in 5253 *GNU* | *'with BFD'*) 5254 test "$with_gnu_ld" != no && break 5255 ;; 5256 *) 5257 test "$with_gnu_ld" != yes && break 5258 ;; 5259 esac 5260 fi 5261 done 5262 IFS="$lt_save_ifs" 5263else 5264 lt_cv_path_LD="$LD" # Let the user override the test with a path. 5265fi]) 5266LD="$lt_cv_path_LD" 5267if test -n "$LD"; then 5268 AC_MSG_RESULT($LD) 5269else 5270 AC_MSG_RESULT(no) 5271fi 5272test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH]) 5273_LT_PATH_LD_GNU 5274AC_SUBST([LD]) 5275 5276_LT_TAGDECL([], [LD], [1], [The linker used to build libraries]) 5277])# LT_PATH_LD 5278 5279# Old names: 5280AU_ALIAS([AM_PROG_LD], [LT_PATH_LD]) 5281AU_ALIAS([AC_PROG_LD], [LT_PATH_LD]) 5282dnl aclocal-1.4 backwards compatibility: 5283dnl AC_DEFUN([AM_PROG_LD], []) 5284dnl AC_DEFUN([AC_PROG_LD], []) 5285 5286 5287# _LT_PATH_LD_GNU 5288#- -------------- 5289m4_defun([_LT_PATH_LD_GNU], 5290[AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld, 5291[# I'd rather use --version here, but apparently some GNU lds only accept -v. 5292case `$LD -v 2>&1 </dev/null` in 5293*GNU* | *'with BFD'*) 5294 lt_cv_prog_gnu_ld=yes 5295 ;; 5296*) 5297 lt_cv_prog_gnu_ld=no 5298 ;; 5299esac]) 5300with_gnu_ld=$lt_cv_prog_gnu_ld 5301])# _LT_PATH_LD_GNU 5302 5303 5304# _LT_CMD_RELOAD 5305# -------------- 5306# find reload flag for linker 5307# -- PORTME Some linkers may need a different reload flag. 5308m4_defun([_LT_CMD_RELOAD], 5309[AC_CACHE_CHECK([for $LD option to reload object files], 5310 lt_cv_ld_reload_flag, 5311 [lt_cv_ld_reload_flag='-r']) 5312reload_flag=$lt_cv_ld_reload_flag 5313case $reload_flag in 5314"" | " "*) ;; 5315*) reload_flag=" $reload_flag" ;; 5316esac 5317reload_cmds='$LD$reload_flag -o $output$reload_objs' 5318case $host_os in 5319 darwin*) 5320 if test "$GCC" = yes; then 5321 reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs' 5322 else 5323 reload_cmds='$LD$reload_flag -o $output$reload_objs' 5324 fi 5325 ;; 5326esac 5327_LT_TAGDECL([], [reload_flag], [1], [How to create reloadable object files])dnl 5328_LT_TAGDECL([], [reload_cmds], [2])dnl 5329])# _LT_CMD_RELOAD 5330 5331 5332# _LT_CHECK_MAGIC_METHOD 5333# ---------------------- 5334# how to check for library dependencies 5335# -- PORTME fill in with the dynamic library characteristics 5336m4_defun([_LT_CHECK_MAGIC_METHOD], 5337[m4_require([_LT_DECL_EGREP]) 5338m4_require([_LT_DECL_OBJDUMP]) 5339AC_CACHE_CHECK([how to recognize dependent libraries], 5340lt_cv_deplibs_check_method, 5341[lt_cv_file_magic_cmd='$MAGIC_CMD' 5342lt_cv_file_magic_test_file= 5343lt_cv_deplibs_check_method='unknown' 5344# Need to set the preceding variable on all platforms that support 5345# interlibrary dependencies. 5346# 'none' -- dependencies not supported. 5347# `unknown' -- same as none, but documents that we really don't know. 5348# 'pass_all' -- all dependencies passed with no checks. 5349# 'test_compile' -- check by making test program. 5350# 'file_magic [[regex]]' -- check by looking for files in library path 5351# which responds to the $file_magic_cmd with a given extended regex. 5352# If you have `file' or equivalent on your system and you're not sure 5353# whether `pass_all' will *always* work, you probably want this one. 5354 5355case $host_os in 5356aix[[4-9]]*) 5357 lt_cv_deplibs_check_method=pass_all 5358 ;; 5359 5360beos*) 5361 lt_cv_deplibs_check_method=pass_all 5362 ;; 5363 5364bsdi[[45]]*) 5365 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)' 5366 lt_cv_file_magic_cmd='/usr/bin/file -L' 5367 lt_cv_file_magic_test_file=/shlib/libc.so 5368 ;; 5369 5370cygwin*) 5371 # func_win32_libid is a shell function defined in ltmain.sh 5372 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' 5373 lt_cv_file_magic_cmd='func_win32_libid' 5374 ;; 5375 5376mingw* | pw32*) 5377 # Base MSYS/MinGW do not provide the 'file' command needed by 5378 # func_win32_libid shell function, so use a weaker test based on 'objdump', 5379 # unless we find 'file', for example because we are cross-compiling. 5380 # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin. 5381 if ( test "$lt_cv_nm_interface" = "BSD nm" && file / ) >/dev/null 2>&1; then 5382 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' 5383 lt_cv_file_magic_cmd='func_win32_libid' 5384 else 5385 # Keep this pattern in sync with the one in func_win32_libid. 5386 lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' 5387 lt_cv_file_magic_cmd='$OBJDUMP -f' 5388 fi 5389 ;; 5390 5391cegcc*) 5392 # use the weaker test based on 'objdump'. See mingw*. 5393 lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?' 5394 lt_cv_file_magic_cmd='$OBJDUMP -f' 5395 ;; 5396 5397darwin* | rhapsody*) 5398 lt_cv_deplibs_check_method=pass_all 5399 ;; 5400 5401freebsd* | dragonfly*) 5402 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then 5403 case $host_cpu in 5404 i*86 ) 5405 # Not sure whether the presence of OpenBSD here was a mistake. 5406 # Let's accept both of them until this is cleared up. 5407 lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library' 5408 lt_cv_file_magic_cmd=/usr/bin/file 5409 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` 5410 ;; 5411 esac 5412 else 5413 lt_cv_deplibs_check_method=pass_all 5414 fi 5415 ;; 5416 5417gnu*) 5418 lt_cv_deplibs_check_method=pass_all 5419 ;; 5420 5421haiku*) 5422 lt_cv_deplibs_check_method=pass_all 5423 ;; 5424 5425hpux10.20* | hpux11*) 5426 lt_cv_file_magic_cmd=/usr/bin/file 5427 case $host_cpu in 5428 ia64*) 5429 lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64' 5430 lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so 5431 ;; 5432 hppa*64*) 5433 [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]'] 5434 lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl 5435 ;; 5436 *) 5437 lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]]\.[[0-9]]) shared library' 5438 lt_cv_file_magic_test_file=/usr/lib/libc.sl 5439 ;; 5440 esac 5441 ;; 5442 5443interix[[3-9]]*) 5444 # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here 5445 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$' 5446 ;; 5447 5448irix5* | irix6* | nonstopux*) 5449 case $LD in 5450 *-32|*"-32 ") libmagic=32-bit;; 5451 *-n32|*"-n32 ") libmagic=N32;; 5452 *-64|*"-64 ") libmagic=64-bit;; 5453 *) libmagic=never-match;; 5454 esac 5455 lt_cv_deplibs_check_method=pass_all 5456 ;; 5457 5458# This must be Linux ELF. 5459linux* | k*bsd*-gnu | kopensolaris*-gnu) 5460 lt_cv_deplibs_check_method=pass_all 5461 ;; 5462 5463netbsd*) 5464 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then 5465 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' 5466 else 5467 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$' 5468 fi 5469 ;; 5470 5471newos6*) 5472 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)' 5473 lt_cv_file_magic_cmd=/usr/bin/file 5474 lt_cv_file_magic_test_file=/usr/lib/libnls.so 5475 ;; 5476 5477*nto* | *qnx*) 5478 lt_cv_deplibs_check_method=pass_all 5479 ;; 5480 5481openbsd*) 5482 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then 5483 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$' 5484 else 5485 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' 5486 fi 5487 ;; 5488 5489osf3* | osf4* | osf5*) 5490 lt_cv_deplibs_check_method=pass_all 5491 ;; 5492 5493rdos*) 5494 lt_cv_deplibs_check_method=pass_all 5495 ;; 5496 5497solaris*) 5498 lt_cv_deplibs_check_method=pass_all 5499 ;; 5500 5501sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) 5502 lt_cv_deplibs_check_method=pass_all 5503 ;; 5504 5505sysv4 | sysv4.3*) 5506 case $host_vendor in 5507 motorola) 5508 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]]' 5509 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` 5510 ;; 5511 ncr) 5512 lt_cv_deplibs_check_method=pass_all 5513 ;; 5514 sequent) 5515 lt_cv_file_magic_cmd='/bin/file' 5516 lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )' 5517 ;; 5518 sni) 5519 lt_cv_file_magic_cmd='/bin/file' 5520 lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib" 5521 lt_cv_file_magic_test_file=/lib/libc.so 5522 ;; 5523 siemens) 5524 lt_cv_deplibs_check_method=pass_all 5525 ;; 5526 pc) 5527 lt_cv_deplibs_check_method=pass_all 5528 ;; 5529 esac 5530 ;; 5531 5532tpf*) 5533 lt_cv_deplibs_check_method=pass_all 5534 ;; 5535esac 5536]) 5537file_magic_cmd=$lt_cv_file_magic_cmd 5538deplibs_check_method=$lt_cv_deplibs_check_method 5539test -z "$deplibs_check_method" && deplibs_check_method=unknown 5540 5541_LT_DECL([], [deplibs_check_method], [1], 5542 [Method to check whether dependent libraries are shared objects]) 5543_LT_DECL([], [file_magic_cmd], [1], 5544 [Command to use when deplibs_check_method == "file_magic"]) 5545])# _LT_CHECK_MAGIC_METHOD 5546 5547 5548# LT_PATH_NM 5549# ---------- 5550# find the pathname to a BSD- or MS-compatible name lister 5551AC_DEFUN([LT_PATH_NM], 5552[AC_REQUIRE([AC_PROG_CC])dnl 5553AC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM, 5554[if test -n "$NM"; then 5555 # Let the user override the test. 5556 lt_cv_path_NM="$NM" 5557else 5558 lt_nm_to_check="${ac_tool_prefix}nm" 5559 if test -n "$ac_tool_prefix" && test "$build" = "$host"; then 5560 lt_nm_to_check="$lt_nm_to_check nm" 5561 fi 5562 for lt_tmp_nm in $lt_nm_to_check; do 5563 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR 5564 for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do 5565 IFS="$lt_save_ifs" 5566 test -z "$ac_dir" && ac_dir=. 5567 tmp_nm="$ac_dir/$lt_tmp_nm" 5568 if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then 5569 # Check to see if the nm accepts a BSD-compat flag. 5570 # Adding the `sed 1q' prevents false positives on HP-UX, which says: 5571 # nm: unknown option "B" ignored 5572 # Tru64's nm complains that /dev/null is an invalid object file 5573 case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in 5574 */dev/null* | *'Invalid file or object type'*) 5575 lt_cv_path_NM="$tmp_nm -B" 5576 break 5577 ;; 5578 *) 5579 case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in 5580 */dev/null*) 5581 lt_cv_path_NM="$tmp_nm -p" 5582 break 5583 ;; 5584 *) 5585 lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but 5586 continue # so that we can try to find one that supports BSD flags 5587 ;; 5588 esac 5589 ;; 5590 esac 5591 fi 5592 done 5593 IFS="$lt_save_ifs" 5594 done 5595 : ${lt_cv_path_NM=no} 5596fi]) 5597if test "$lt_cv_path_NM" != "no"; then 5598 NM="$lt_cv_path_NM" 5599else 5600 # Didn't find any BSD compatible name lister, look for dumpbin. 5601 if test -n "$DUMPBIN"; then : 5602 # Let the user override the test. 5603 else 5604 AC_CHECK_TOOLS(DUMPBIN, [dumpbin "link -dump"], :) 5605 case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in 5606 *COFF*) 5607 DUMPBIN="$DUMPBIN -symbols" 5608 ;; 5609 *) 5610 DUMPBIN=: 5611 ;; 5612 esac 5613 fi 5614 AC_SUBST([DUMPBIN]) 5615 if test "$DUMPBIN" != ":"; then 5616 NM="$DUMPBIN" 5617 fi 5618fi 5619test -z "$NM" && NM=nm 5620AC_SUBST([NM]) 5621_LT_DECL([], [NM], [1], [A BSD- or MS-compatible name lister])dnl 5622 5623AC_CACHE_CHECK([the name lister ($NM) interface], [lt_cv_nm_interface], 5624 [lt_cv_nm_interface="BSD nm" 5625 echo "int some_variable = 0;" > conftest.$ac_ext 5626 (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&AS_MESSAGE_LOG_FD) 5627 (eval "$ac_compile" 2>conftest.err) 5628 cat conftest.err >&AS_MESSAGE_LOG_FD 5629 (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD) 5630 (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) 5631 cat conftest.err >&AS_MESSAGE_LOG_FD 5632 (eval echo "\"\$as_me:$LINENO: output\"" >&AS_MESSAGE_LOG_FD) 5633 cat conftest.out >&AS_MESSAGE_LOG_FD 5634 if $GREP 'External.*some_variable' conftest.out > /dev/null; then 5635 lt_cv_nm_interface="MS dumpbin" 5636 fi 5637 rm -f conftest*]) 5638])# LT_PATH_NM 5639 5640# Old names: 5641AU_ALIAS([AM_PROG_NM], [LT_PATH_NM]) 5642AU_ALIAS([AC_PROG_NM], [LT_PATH_NM]) 5643dnl aclocal-1.4 backwards compatibility: 5644dnl AC_DEFUN([AM_PROG_NM], []) 5645dnl AC_DEFUN([AC_PROG_NM], []) 5646 5647 5648# LT_LIB_M 5649# -------- 5650# check for math library 5651AC_DEFUN([LT_LIB_M], 5652[AC_REQUIRE([AC_CANONICAL_HOST])dnl 5653LIBM= 5654case $host in 5655*-*-beos* | *-*-cegcc* | *-*-cygwin* | *-*-haiku* | *-*-pw32* | *-*-darwin*) 5656 # These system don't have libm, or don't need it 5657 ;; 5658*-ncr-sysv4.3*) 5659 AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw") 5660 AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm") 5661 ;; 5662*) 5663 AC_CHECK_LIB(m, cos, LIBM="-lm") 5664 ;; 5665esac 5666AC_SUBST([LIBM]) 5667])# LT_LIB_M 5668 5669# Old name: 5670AU_ALIAS([AC_CHECK_LIBM], [LT_LIB_M]) 5671dnl aclocal-1.4 backwards compatibility: 5672dnl AC_DEFUN([AC_CHECK_LIBM], []) 5673 5674 5675# _LT_COMPILER_NO_RTTI([TAGNAME]) 5676# ------------------------------- 5677m4_defun([_LT_COMPILER_NO_RTTI], 5678[m4_require([_LT_TAG_COMPILER])dnl 5679 5680_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= 5681 5682if test "$GCC" = yes; then 5683 case $cc_basename in 5684 nvcc*) 5685 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -Xcompiler -fno-builtin' ;; 5686 *) 5687 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' ;; 5688 esac 5689 5690 _LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions], 5691 lt_cv_prog_compiler_rtti_exceptions, 5692 [-fno-rtti -fno-exceptions], [], 5693 [_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"]) 5694fi 5695_LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1], 5696 [Compiler flag to turn off builtin functions]) 5697])# _LT_COMPILER_NO_RTTI 5698 5699 5700# _LT_CMD_GLOBAL_SYMBOLS 5701# ---------------------- 5702m4_defun([_LT_CMD_GLOBAL_SYMBOLS], 5703[AC_REQUIRE([AC_CANONICAL_HOST])dnl 5704AC_REQUIRE([AC_PROG_CC])dnl 5705AC_REQUIRE([AC_PROG_AWK])dnl 5706AC_REQUIRE([LT_PATH_NM])dnl 5707AC_REQUIRE([LT_PATH_LD])dnl 5708m4_require([_LT_DECL_SED])dnl 5709m4_require([_LT_DECL_EGREP])dnl 5710m4_require([_LT_TAG_COMPILER])dnl 5711 5712# Check for command to grab the raw symbol name followed by C symbol from nm. 5713AC_MSG_CHECKING([command to parse $NM output from $compiler object]) 5714AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe], 5715[ 5716# These are sane defaults that work on at least a few old systems. 5717# [They come from Ultrix. What could be older than Ultrix?!! ;)] 5718 5719# Character class describing NM global symbol codes. 5720symcode='[[BCDEGRST]]' 5721 5722# Regexp to match symbols that can be accessed directly from C. 5723sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)' 5724 5725# Define system-specific variables. 5726case $host_os in 5727aix*) 5728 symcode='[[BCDT]]' 5729 ;; 5730cygwin* | mingw* | pw32* | cegcc*) 5731 symcode='[[ABCDGISTW]]' 5732 ;; 5733hpux*) 5734 if test "$host_cpu" = ia64; then 5735 symcode='[[ABCDEGRST]]' 5736 fi 5737 ;; 5738irix* | nonstopux*) 5739 symcode='[[BCDEGRST]]' 5740 ;; 5741osf*) 5742 symcode='[[BCDEGQRST]]' 5743 ;; 5744solaris*) 5745 symcode='[[BDRT]]' 5746 ;; 5747sco3.2v5*) 5748 symcode='[[DT]]' 5749 ;; 5750sysv4.2uw2*) 5751 symcode='[[DT]]' 5752 ;; 5753sysv5* | sco5v6* | unixware* | OpenUNIX*) 5754 symcode='[[ABDT]]' 5755 ;; 5756sysv4) 5757 symcode='[[DFNSTU]]' 5758 ;; 5759esac 5760 5761# If we're using GNU nm, then use its standard symbol codes. 5762case `$NM -V 2>&1` in 5763*GNU* | *'with BFD'*) 5764 symcode='[[ABCDGIRSTW]]' ;; 5765esac 5766 5767# Transform an extracted symbol line into a proper C declaration. 5768# Some systems (esp. on ia64) link data and code symbols differently, 5769# so use this general approach. 5770lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" 5771 5772# Transform an extracted symbol line into symbol name and symbol address 5773lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p'" 5774lt_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'" 5775 5776# Handle CRLF in mingw tool chain 5777opt_cr= 5778case $build_os in 5779mingw*) 5780 opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp 5781 ;; 5782esac 5783 5784# Try without a prefix underscore, then with it. 5785for ac_symprfx in "" "_"; do 5786 5787 # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. 5788 symxfrm="\\1 $ac_symprfx\\2 \\2" 5789 5790 # Write the raw and C identifiers. 5791 if test "$lt_cv_nm_interface" = "MS dumpbin"; then 5792 # Fake it for dumpbin and say T for any non-static function 5793 # and D for any global variable. 5794 # Also find C++ and __fastcall symbols from MSVC++, 5795 # which start with @ or ?. 5796 lt_cv_sys_global_symbol_pipe="$AWK ['"\ 5797" {last_section=section; section=\$ 3};"\ 5798" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\ 5799" \$ 0!~/External *\|/{next};"\ 5800" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\ 5801" {if(hide[section]) next};"\ 5802" {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\ 5803" {split(\$ 0, a, /\||\r/); split(a[2], s)};"\ 5804" s[1]~/^[@?]/{print s[1], s[1]; next};"\ 5805" s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\ 5806" ' prfx=^$ac_symprfx]" 5807 else 5808 lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" 5809 fi 5810 5811 # Check to see that the pipe works correctly. 5812 pipe_works=no 5813 5814 rm -f conftest* 5815 cat > conftest.$ac_ext <<_LT_EOF 5816#ifdef __cplusplus 5817extern "C" { 5818#endif 5819char nm_test_var; 5820void nm_test_func(void); 5821void nm_test_func(void){} 5822#ifdef __cplusplus 5823} 5824#endif 5825int main(){nm_test_var='a';nm_test_func();return(0);} 5826_LT_EOF 5827 5828 if AC_TRY_EVAL(ac_compile); then 5829 # Now try to grab the symbols. 5830 nlist=conftest.nm 5831 if AC_TRY_EVAL(NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) && test -s "$nlist"; then 5832 # Try sorting and uniquifying the output. 5833 if sort "$nlist" | uniq > "$nlist"T; then 5834 mv -f "$nlist"T "$nlist" 5835 else 5836 rm -f "$nlist"T 5837 fi 5838 5839 # Make sure that we snagged all the symbols we need. 5840 if $GREP ' nm_test_var$' "$nlist" >/dev/null; then 5841 if $GREP ' nm_test_func$' "$nlist" >/dev/null; then 5842 cat <<_LT_EOF > conftest.$ac_ext 5843#ifdef __cplusplus 5844extern "C" { 5845#endif 5846 5847_LT_EOF 5848 # Now generate the symbol file. 5849 eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext' 5850 5851 cat <<_LT_EOF >> conftest.$ac_ext 5852 5853/* The mapping between symbol names and symbols. */ 5854const struct { 5855 const char *name; 5856 void *address; 5857} 5858lt__PROGRAM__LTX_preloaded_symbols[[]] = 5859{ 5860 { "@PROGRAM@", (void *) 0 }, 5861_LT_EOF 5862 $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext 5863 cat <<\_LT_EOF >> conftest.$ac_ext 5864 {0, (void *) 0} 5865}; 5866 5867/* This works around a problem in FreeBSD linker */ 5868#ifdef FREEBSD_WORKAROUND 5869static const void *lt_preloaded_setup() { 5870 return lt__PROGRAM__LTX_preloaded_symbols; 5871} 5872#endif 5873 5874#ifdef __cplusplus 5875} 5876#endif 5877_LT_EOF 5878 # Now try linking the two files. 5879 mv conftest.$ac_objext conftstm.$ac_objext 5880 lt_save_LIBS="$LIBS" 5881 lt_save_CFLAGS="$CFLAGS" 5882 LIBS="conftstm.$ac_objext" 5883 CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)" 5884 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then 5885 pipe_works=yes 5886 fi 5887 LIBS="$lt_save_LIBS" 5888 CFLAGS="$lt_save_CFLAGS" 5889 else 5890 echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD 5891 fi 5892 else 5893 echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD 5894 fi 5895 else 5896 echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD 5897 fi 5898 else 5899 echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD 5900 cat conftest.$ac_ext >&5 5901 fi 5902 rm -rf conftest* conftst* 5903 5904 # Do not use the global_symbol_pipe unless it works. 5905 if test "$pipe_works" = yes; then 5906 break 5907 else 5908 lt_cv_sys_global_symbol_pipe= 5909 fi 5910done 5911]) 5912if test -z "$lt_cv_sys_global_symbol_pipe"; then 5913 lt_cv_sys_global_symbol_to_cdecl= 5914fi 5915if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then 5916 AC_MSG_RESULT(failed) 5917else 5918 AC_MSG_RESULT(ok) 5919fi 5920 5921_LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1], 5922 [Take the output of nm and produce a listing of raw symbols and C names]) 5923_LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1], 5924 [Transform the output of nm in a proper C declaration]) 5925_LT_DECL([global_symbol_to_c_name_address], 5926 [lt_cv_sys_global_symbol_to_c_name_address], [1], 5927 [Transform the output of nm in a C name address pair]) 5928_LT_DECL([global_symbol_to_c_name_address_lib_prefix], 5929 [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1], 5930 [Transform the output of nm in a C name address pair when lib prefix is needed]) 5931]) # _LT_CMD_GLOBAL_SYMBOLS 5932 5933 5934# _LT_COMPILER_PIC([TAGNAME]) 5935# --------------------------- 5936m4_defun([_LT_COMPILER_PIC], 5937[m4_require([_LT_TAG_COMPILER])dnl 5938_LT_TAGVAR(lt_prog_compiler_wl, $1)= 5939_LT_TAGVAR(lt_prog_compiler_pic, $1)= 5940_LT_TAGVAR(lt_prog_compiler_static, $1)= 5941 5942AC_MSG_CHECKING([for $compiler option to produce PIC]) 5943m4_if([$1], [CXX], [ 5944 # C++ specific cases for pic, static, wl, etc. 5945 if test "$GXX" = yes; then 5946 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 5947 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 5948 5949 case $host_os in 5950 aix*) 5951 # All AIX code is PIC. 5952 if test "$host_cpu" = ia64; then 5953 # AIX 5 now supports IA64 processor 5954 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 5955 fi 5956 ;; 5957 5958 amigaos*) 5959 case $host_cpu in 5960 powerpc) 5961 # see comment about AmigaOS4 .so support 5962 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 5963 ;; 5964 m68k) 5965 # FIXME: we need at least 68020 code to build shared libraries, but 5966 # adding the `-m68020' flag to GCC prevents building anything better, 5967 # like `-m68040'. 5968 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' 5969 ;; 5970 esac 5971 ;; 5972 5973 beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) 5974 # PIC is the default for these OSes. 5975 ;; 5976 mingw* | cygwin* | os2* | pw32* | cegcc*) 5977 # This hack is so that the source file can tell whether it is being 5978 # built for inclusion in a dll (and should export symbols for example). 5979 # Although the cygwin gcc ignores -fPIC, still need this for old-style 5980 # (--disable-auto-import) libraries 5981 m4_if([$1], [GCJ], [], 5982 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) 5983 ;; 5984 darwin* | rhapsody*) 5985 # PIC is the default on this platform 5986 # Common symbols not allowed in MH_DYLIB files 5987 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' 5988 ;; 5989 *djgpp*) 5990 # DJGPP does not support shared libraries at all 5991 _LT_TAGVAR(lt_prog_compiler_pic, $1)= 5992 ;; 5993 haiku*) 5994 # PIC is the default for Haiku. 5995 # The "-static" flag exists, but is broken. 5996 _LT_TAGVAR(lt_prog_compiler_static, $1)= 5997 ;; 5998 interix[[3-9]]*) 5999 # Interix 3.x gcc -fpic/-fPIC options generate broken code. 6000 # Instead, we relocate shared libraries at runtime. 6001 ;; 6002 sysv4*MP*) 6003 if test -d /usr/nec; then 6004 _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic 6005 fi 6006 ;; 6007 hpux*) 6008 # PIC is the default for 64-bit PA HP-UX, but not for 32-bit 6009 # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag 6010 # sets the default TLS model and affects inlining. 6011 case $host_cpu in 6012 hppa*64*) 6013 ;; 6014 *) 6015 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 6016 ;; 6017 esac 6018 ;; 6019 *qnx* | *nto*) 6020 # QNX uses GNU C++, but need to define -shared option too, otherwise 6021 # it will coredump. 6022 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' 6023 ;; 6024 *) 6025 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 6026 ;; 6027 esac 6028 else 6029 case $host_os in 6030 aix[[4-9]]*) 6031 # All AIX code is PIC. 6032 if test "$host_cpu" = ia64; then 6033 # AIX 5 now supports IA64 processor 6034 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6035 else 6036 _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' 6037 fi 6038 ;; 6039 chorus*) 6040 case $cc_basename in 6041 cxch68*) 6042 # Green Hills C++ Compiler 6043 # _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" 6044 ;; 6045 esac 6046 ;; 6047 dgux*) 6048 case $cc_basename in 6049 ec++*) 6050 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6051 ;; 6052 ghcx*) 6053 # Green Hills C++ Compiler 6054 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 6055 ;; 6056 *) 6057 ;; 6058 esac 6059 ;; 6060 freebsd* | dragonfly*) 6061 # FreeBSD uses GNU C++ 6062 ;; 6063 hpux9* | hpux10* | hpux11*) 6064 case $cc_basename in 6065 CC*) 6066 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6067 _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' 6068 if test "$host_cpu" != ia64; then 6069 _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' 6070 fi 6071 ;; 6072 aCC*) 6073 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6074 _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' 6075 case $host_cpu in 6076 hppa*64*|ia64*) 6077 # +Z the default 6078 ;; 6079 *) 6080 _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' 6081 ;; 6082 esac 6083 ;; 6084 *) 6085 ;; 6086 esac 6087 ;; 6088 interix*) 6089 # This is c89, which is MS Visual C++ (no shared libs) 6090 # Anyone wants to do a port? 6091 ;; 6092 irix5* | irix6* | nonstopux*) 6093 case $cc_basename in 6094 CC*) 6095 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6096 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 6097 # CC pic flag -KPIC is the default. 6098 ;; 6099 *) 6100 ;; 6101 esac 6102 ;; 6103 linux* | k*bsd*-gnu | kopensolaris*-gnu) 6104 case $cc_basename in 6105 KCC*) 6106 # KAI C++ Compiler 6107 _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' 6108 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 6109 ;; 6110 ecpc* ) 6111 # old Intel C++ for x86_64 which still supported -KPIC. 6112 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6113 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6114 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 6115 ;; 6116 icpc* ) 6117 # Intel C++, used to be incompatible with GCC. 6118 # ICC 10 doesn't accept -KPIC any more. 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)='-static' 6122 ;; 6123 pgCC* | pgcpp*) 6124 # Portland Group C++ compiler 6125 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6126 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' 6127 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6128 ;; 6129 cxx*) 6130 # Compaq C++ 6131 # Make sure the PIC flag is empty. It appears that all Alpha 6132 # Linux and Compaq Tru64 Unix objects are PIC. 6133 _LT_TAGVAR(lt_prog_compiler_pic, $1)= 6134 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 6135 ;; 6136 xlc* | xlC* | bgxl[[cC]]* | mpixl[[cC]]*) 6137 # IBM XL 8.0, 9.0 on PPC and BlueGene 6138 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6139 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' 6140 _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' 6141 ;; 6142 *) 6143 case `$CC -V 2>&1 | sed 5q` in 6144 *Sun\ C*) 6145 # Sun C++ 5.9 6146 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6147 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6148 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' 6149 ;; 6150 esac 6151 ;; 6152 esac 6153 ;; 6154 lynxos*) 6155 ;; 6156 m88k*) 6157 ;; 6158 mvs*) 6159 case $cc_basename in 6160 cxx*) 6161 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall' 6162 ;; 6163 *) 6164 ;; 6165 esac 6166 ;; 6167 netbsd*) 6168 ;; 6169 *qnx* | *nto*) 6170 # QNX uses GNU C++, but need to define -shared option too, otherwise 6171 # it will coredump. 6172 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' 6173 ;; 6174 osf3* | osf4* | osf5*) 6175 case $cc_basename in 6176 KCC*) 6177 _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' 6178 ;; 6179 RCC*) 6180 # Rational C++ 2.4.1 6181 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 6182 ;; 6183 cxx*) 6184 # Digital/Compaq C++ 6185 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6186 # Make sure the PIC flag is empty. It appears that all Alpha 6187 # Linux and Compaq Tru64 Unix objects are PIC. 6188 _LT_TAGVAR(lt_prog_compiler_pic, $1)= 6189 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 6190 ;; 6191 *) 6192 ;; 6193 esac 6194 ;; 6195 psos*) 6196 ;; 6197 solaris*) 6198 case $cc_basename in 6199 CC* | sunCC*) 6200 # Sun C++ 4.2, 5.x and Centerline C++ 6201 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6202 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6203 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' 6204 ;; 6205 gcx*) 6206 # Green Hills C++ Compiler 6207 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' 6208 ;; 6209 *) 6210 ;; 6211 esac 6212 ;; 6213 sunos4*) 6214 case $cc_basename in 6215 CC*) 6216 # Sun C++ 4.x 6217 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 6218 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6219 ;; 6220 lcc*) 6221 # Lucid 6222 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 6223 ;; 6224 *) 6225 ;; 6226 esac 6227 ;; 6228 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) 6229 case $cc_basename in 6230 CC*) 6231 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6232 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6233 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6234 ;; 6235 esac 6236 ;; 6237 tandem*) 6238 case $cc_basename in 6239 NCC*) 6240 # NonStop-UX NCC 3.20 6241 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6242 ;; 6243 *) 6244 ;; 6245 esac 6246 ;; 6247 vxworks*) 6248 ;; 6249 *) 6250 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 6251 ;; 6252 esac 6253 fi 6254], 6255[ 6256 if test "$GCC" = yes; then 6257 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6258 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 6259 6260 case $host_os in 6261 aix*) 6262 # All AIX code is PIC. 6263 if test "$host_cpu" = ia64; then 6264 # AIX 5 now supports IA64 processor 6265 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6266 fi 6267 ;; 6268 6269 amigaos*) 6270 case $host_cpu in 6271 powerpc) 6272 # see comment about AmigaOS4 .so support 6273 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 6274 ;; 6275 m68k) 6276 # FIXME: we need at least 68020 code to build shared libraries, but 6277 # adding the `-m68020' flag to GCC prevents building anything better, 6278 # like `-m68040'. 6279 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' 6280 ;; 6281 esac 6282 ;; 6283 6284 beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) 6285 # PIC is the default for these OSes. 6286 ;; 6287 6288 mingw* | cygwin* | pw32* | os2* | cegcc*) 6289 # This hack is so that the source file can tell whether it is being 6290 # built for inclusion in a dll (and should export symbols for example). 6291 # Although the cygwin gcc ignores -fPIC, still need this for old-style 6292 # (--disable-auto-import) libraries 6293 m4_if([$1], [GCJ], [], 6294 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) 6295 ;; 6296 6297 darwin* | rhapsody*) 6298 # PIC is the default on this platform 6299 # Common symbols not allowed in MH_DYLIB files 6300 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' 6301 ;; 6302 6303 haiku*) 6304 # PIC is the default for Haiku. 6305 # The "-static" flag exists, but is broken. 6306 _LT_TAGVAR(lt_prog_compiler_static, $1)= 6307 ;; 6308 6309 hpux*) 6310 # PIC is the default for 64-bit PA HP-UX, but not for 32-bit 6311 # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag 6312 # sets the default TLS model and affects inlining. 6313 case $host_cpu in 6314 hppa*64*) 6315 # +Z the default 6316 ;; 6317 *) 6318 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 6319 ;; 6320 esac 6321 ;; 6322 6323 interix[[3-9]]*) 6324 # Interix 3.x gcc -fpic/-fPIC options generate broken code. 6325 # Instead, we relocate shared libraries at runtime. 6326 ;; 6327 6328 msdosdjgpp*) 6329 # Just because we use GCC doesn't mean we suddenly get shared libraries 6330 # on systems that don't support them. 6331 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 6332 enable_shared=no 6333 ;; 6334 6335 *nto* | *qnx*) 6336 # QNX uses GNU C++, but need to define -shared option too, otherwise 6337 # it will coredump. 6338 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' 6339 ;; 6340 6341 sysv4*MP*) 6342 if test -d /usr/nec; then 6343 _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic 6344 fi 6345 ;; 6346 6347 *) 6348 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 6349 ;; 6350 esac 6351 6352 case $cc_basename in 6353 nvcc*) # Cuda Compiler Driver 2.2 6354 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Xlinker ' 6355 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Xcompiler -fPIC' 6356 ;; 6357 esac 6358 else 6359 # PORTME Check for flag to pass linker flags through the system compiler. 6360 case $host_os in 6361 aix*) 6362 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6363 if test "$host_cpu" = ia64; then 6364 # AIX 5 now supports IA64 processor 6365 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6366 else 6367 _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' 6368 fi 6369 ;; 6370 6371 mingw* | cygwin* | pw32* | os2* | cegcc*) 6372 # This hack is so that the source file can tell whether it is being 6373 # built for inclusion in a dll (and should export symbols for example). 6374 m4_if([$1], [GCJ], [], 6375 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) 6376 ;; 6377 6378 hpux9* | hpux10* | hpux11*) 6379 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6380 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but 6381 # not for PA HP-UX. 6382 case $host_cpu in 6383 hppa*64*|ia64*) 6384 # +Z the default 6385 ;; 6386 *) 6387 _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' 6388 ;; 6389 esac 6390 # Is there a better lt_prog_compiler_static that works with the bundled CC? 6391 _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' 6392 ;; 6393 6394 irix5* | irix6* | nonstopux*) 6395 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6396 # PIC (with -KPIC) is the default. 6397 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 6398 ;; 6399 6400 linux* | k*bsd*-gnu | kopensolaris*-gnu) 6401 case $cc_basename in 6402 # old Intel for x86_64 which still supported -KPIC. 6403 ecc*) 6404 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6405 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6406 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 6407 ;; 6408 # icc used to be incompatible with GCC. 6409 # ICC 10 doesn't accept -KPIC any more. 6410 icc* | ifort*) 6411 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6412 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 6413 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 6414 ;; 6415 # Lahey Fortran 8.1. 6416 lf95*) 6417 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6418 _LT_TAGVAR(lt_prog_compiler_pic, $1)='--shared' 6419 _LT_TAGVAR(lt_prog_compiler_static, $1)='--static' 6420 ;; 6421 pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) 6422 # Portland Group compilers (*not* the Pentium gcc compiler, 6423 # which looks to be a dead project) 6424 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6425 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' 6426 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6427 ;; 6428 ccc*) 6429 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6430 # All Alpha code is PIC. 6431 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 6432 ;; 6433 xl* | bgxl* | bgf* | mpixl*) 6434 # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene 6435 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6436 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' 6437 _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' 6438 ;; 6439 *) 6440 case `$CC -V 2>&1 | sed 5q` in 6441 *Sun\ F* | *Sun*Fortran*) 6442 # Sun Fortran 8.3 passes all unrecognized flags to the linker 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)='' 6446 ;; 6447 *Sun\ C*) 6448 # Sun C 5.9 6449 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6450 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6451 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6452 ;; 6453 esac 6454 ;; 6455 esac 6456 ;; 6457 6458 newsos6) 6459 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6460 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6461 ;; 6462 6463 *nto* | *qnx*) 6464 # QNX uses GNU C++, but need to define -shared option too, otherwise 6465 # it will coredump. 6466 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' 6467 ;; 6468 6469 osf3* | osf4* | osf5*) 6470 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6471 # All OSF/1 code is PIC. 6472 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 6473 ;; 6474 6475 rdos*) 6476 _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 6477 ;; 6478 6479 solaris*) 6480 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6481 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6482 case $cc_basename in 6483 f77* | f90* | f95* | sunf77* | sunf90* | sunf95*) 6484 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';; 6485 *) 6486 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';; 6487 esac 6488 ;; 6489 6490 sunos4*) 6491 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' 6492 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' 6493 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6494 ;; 6495 6496 sysv4 | sysv4.2uw2* | sysv4.3*) 6497 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6498 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6499 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6500 ;; 6501 6502 sysv4*MP*) 6503 if test -d /usr/nec ;then 6504 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic' 6505 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6506 fi 6507 ;; 6508 6509 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) 6510 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6511 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6512 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6513 ;; 6514 6515 unicos*) 6516 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6517 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 6518 ;; 6519 6520 uts4*) 6521 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 6522 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6523 ;; 6524 6525 *) 6526 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 6527 ;; 6528 esac 6529 fi 6530]) 6531case $host_os in 6532 # For platforms which do not support PIC, -DPIC is meaningless: 6533 *djgpp*) 6534 _LT_TAGVAR(lt_prog_compiler_pic, $1)= 6535 ;; 6536 *) 6537 _LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])" 6538 ;; 6539esac 6540AC_MSG_RESULT([$_LT_TAGVAR(lt_prog_compiler_pic, $1)]) 6541_LT_TAGDECL([wl], [lt_prog_compiler_wl], [1], 6542 [How to pass a linker flag through the compiler]) 6543 6544# 6545# Check to make sure the PIC flag actually works. 6546# 6547if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then 6548 _LT_COMPILER_OPTION([if $compiler PIC flag $_LT_TAGVAR(lt_prog_compiler_pic, $1) works], 6549 [_LT_TAGVAR(lt_cv_prog_compiler_pic_works, $1)], 6550 [$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])], [], 6551 [case $_LT_TAGVAR(lt_prog_compiler_pic, $1) in 6552 "" | " "*) ;; 6553 *) _LT_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_TAGVAR(lt_prog_compiler_pic, $1)" ;; 6554 esac], 6555 [_LT_TAGVAR(lt_prog_compiler_pic, $1)= 6556 _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no]) 6557fi 6558_LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1], 6559 [Additional compiler flags for building library objects]) 6560 6561# 6562# Check to make sure the static flag actually works. 6563# 6564wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_TAGVAR(lt_prog_compiler_static, $1)\" 6565_LT_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works], 6566 _LT_TAGVAR(lt_cv_prog_compiler_static_works, $1), 6567 $lt_tmp_static_flag, 6568 [], 6569 [_LT_TAGVAR(lt_prog_compiler_static, $1)=]) 6570_LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1], 6571 [Compiler flag to prevent dynamic linking]) 6572])# _LT_COMPILER_PIC 6573 6574 6575# _LT_LINKER_SHLIBS([TAGNAME]) 6576# ---------------------------- 6577# See if the linker supports building shared libraries. 6578m4_defun([_LT_LINKER_SHLIBS], 6579[AC_REQUIRE([LT_PATH_LD])dnl 6580AC_REQUIRE([LT_PATH_NM])dnl 6581m4_require([_LT_FILEUTILS_DEFAULTS])dnl 6582m4_require([_LT_DECL_EGREP])dnl 6583m4_require([_LT_DECL_SED])dnl 6584m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl 6585m4_require([_LT_TAG_COMPILER])dnl 6586AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) 6587m4_if([$1], [CXX], [ 6588 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' 6589 case $host_os in 6590 aix[[4-9]]*) 6591 # If we're using GNU nm, then we don't want the "-C" option. 6592 # -C means demangle to AIX nm, but means don't demangle with GNU nm 6593 # Also, AIX nm treats weak defined symbols like other global defined 6594 # symbols, whereas GNU nm marks them as "W". 6595 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then 6596 _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' 6597 else 6598 _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' 6599 fi 6600 ;; 6601 pw32*) 6602 _LT_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds" 6603 ;; 6604 cygwin* | mingw* | cegcc*) 6605 _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' 6606 ;; 6607 *) 6608 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' 6609 ;; 6610 esac 6611 _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] 6612], [ 6613 runpath_var= 6614 _LT_TAGVAR(allow_undefined_flag, $1)= 6615 _LT_TAGVAR(always_export_symbols, $1)=no 6616 _LT_TAGVAR(archive_cmds, $1)= 6617 _LT_TAGVAR(archive_expsym_cmds, $1)= 6618 _LT_TAGVAR(compiler_needs_object, $1)=no 6619 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no 6620 _LT_TAGVAR(export_dynamic_flag_spec, $1)= 6621 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' 6622 _LT_TAGVAR(hardcode_automatic, $1)=no 6623 _LT_TAGVAR(hardcode_direct, $1)=no 6624 _LT_TAGVAR(hardcode_direct_absolute, $1)=no 6625 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 6626 _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= 6627 _LT_TAGVAR(hardcode_libdir_separator, $1)= 6628 _LT_TAGVAR(hardcode_minus_L, $1)=no 6629 _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported 6630 _LT_TAGVAR(inherit_rpath, $1)=no 6631 _LT_TAGVAR(link_all_deplibs, $1)=unknown 6632 _LT_TAGVAR(module_cmds, $1)= 6633 _LT_TAGVAR(module_expsym_cmds, $1)= 6634 _LT_TAGVAR(old_archive_from_new_cmds, $1)= 6635 _LT_TAGVAR(old_archive_from_expsyms_cmds, $1)= 6636 _LT_TAGVAR(thread_safe_flag_spec, $1)= 6637 _LT_TAGVAR(whole_archive_flag_spec, $1)= 6638 # include_expsyms should be a list of space-separated symbols to be *always* 6639 # included in the symbol list 6640 _LT_TAGVAR(include_expsyms, $1)= 6641 # exclude_expsyms can be an extended regexp of symbols to exclude 6642 # it will be wrapped by ` (' and `)$', so one must not match beginning or 6643 # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', 6644 # as well as any symbol that contains `d'. 6645 _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] 6646 # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out 6647 # platforms (ab)use it in PIC code, but their linkers get confused if 6648 # the symbol is explicitly referenced. Since portable code cannot 6649 # rely on this symbol name, it's probably fine to never include it in 6650 # preloaded symbol tables. 6651 # Exclude shared library initialization/finalization symbols. 6652dnl Note also adjust exclude_expsyms for C++ above. 6653 extract_expsyms_cmds= 6654 6655 case $host_os in 6656 cygwin* | mingw* | pw32* | cegcc*) 6657 # FIXME: the MSVC++ port hasn't been tested in a loooong time 6658 # When not using gcc, we currently assume that we are using 6659 # Microsoft Visual C++. 6660 if test "$GCC" != yes; then 6661 with_gnu_ld=no 6662 fi 6663 ;; 6664 interix*) 6665 # we just hope/assume this is gcc and not c89 (= MSVC++) 6666 with_gnu_ld=yes 6667 ;; 6668 openbsd*) 6669 with_gnu_ld=no 6670 ;; 6671 esac 6672 6673 _LT_TAGVAR(ld_shlibs, $1)=yes 6674 6675 # On some targets, GNU ld is compatible enough with the native linker 6676 # that we're better off using the native interface for both. 6677 lt_use_gnu_ld_interface=no 6678 if test "$with_gnu_ld" = yes; then 6679 case $host_os in 6680 aix*) 6681 # The AIX port of GNU ld has always aspired to compatibility 6682 # with the native linker. However, as the warning in the GNU ld 6683 # block says, versions before 2.19.5* couldn't really create working 6684 # shared libraries, regardless of the interface used. 6685 case `$LD -v 2>&1` in 6686 *\ \(GNU\ Binutils\)\ 2.19.5*) ;; 6687 *\ \(GNU\ Binutils\)\ 2.[[2-9]]*) ;; 6688 *\ \(GNU\ Binutils\)\ [[3-9]]*) ;; 6689 *) 6690 lt_use_gnu_ld_interface=yes 6691 ;; 6692 esac 6693 ;; 6694 *) 6695 lt_use_gnu_ld_interface=yes 6696 ;; 6697 esac 6698 fi 6699 6700 if test "$lt_use_gnu_ld_interface" = yes; then 6701 # If archive_cmds runs LD, not CC, wlarc should be empty 6702 wlarc='${wl}' 6703 6704 # Set some defaults for GNU ld with shared library support. These 6705 # are reset later if shared libraries are not supported. Putting them 6706 # here allows them to be overridden if necessary. 6707 runpath_var=LD_RUN_PATH 6708 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 6709 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 6710 # ancient GNU ld didn't support --whole-archive et. al. 6711 if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then 6712 _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' 6713 else 6714 _LT_TAGVAR(whole_archive_flag_spec, $1)= 6715 fi 6716 supports_anon_versioning=no 6717 case `$LD -v 2>&1` in 6718 *GNU\ gold*) supports_anon_versioning=yes ;; 6719 *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11 6720 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... 6721 *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... 6722 *\ 2.11.*) ;; # other 2.11 versions 6723 *) supports_anon_versioning=yes ;; 6724 esac 6725 6726 # See if GNU ld supports shared libraries. 6727 case $host_os in 6728 aix[[3-9]]*) 6729 # On AIX/PPC, the GNU linker is very broken 6730 if test "$host_cpu" != ia64; then 6731 _LT_TAGVAR(ld_shlibs, $1)=no 6732 cat <<_LT_EOF 1>&2 6733 6734*** Warning: the GNU linker, at least up to release 2.19, is reported 6735*** to be unable to reliably create shared libraries on AIX. 6736*** Therefore, libtool is disabling shared libraries support. If you 6737*** really care for shared libraries, you may want to install binutils 6738*** 2.20 or above, or modify your PATH so that a non-GNU linker is found. 6739*** You will then need to restart the configuration process. 6740 6741_LT_EOF 6742 fi 6743 ;; 6744 6745 amigaos*) 6746 case $host_cpu in 6747 powerpc) 6748 # see comment about AmigaOS4 .so support 6749 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 6750 _LT_TAGVAR(archive_expsym_cmds, $1)='' 6751 ;; 6752 m68k) 6753 _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)' 6754 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 6755 _LT_TAGVAR(hardcode_minus_L, $1)=yes 6756 ;; 6757 esac 6758 ;; 6759 6760 beos*) 6761 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 6762 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 6763 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc 6764 # support --undefined. This deserves some investigation. FIXME 6765 _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 6766 else 6767 _LT_TAGVAR(ld_shlibs, $1)=no 6768 fi 6769 ;; 6770 6771 cygwin* | mingw* | pw32* | cegcc*) 6772 # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, 6773 # as there is no search path for DLLs. 6774 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 6775 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols' 6776 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 6777 _LT_TAGVAR(always_export_symbols, $1)=no 6778 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 6779 _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' 6780 6781 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then 6782 _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' 6783 # If the export-symbols file already is a .def file (1st line 6784 # is EXPORTS), use it as is; otherwise, prepend... 6785 _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then 6786 cp $export_symbols $output_objdir/$soname.def; 6787 else 6788 echo EXPORTS > $output_objdir/$soname.def; 6789 cat $export_symbols >> $output_objdir/$soname.def; 6790 fi~ 6791 $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' 6792 else 6793 _LT_TAGVAR(ld_shlibs, $1)=no 6794 fi 6795 ;; 6796 6797 haiku*) 6798 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 6799 _LT_TAGVAR(link_all_deplibs, $1)=yes 6800 ;; 6801 6802 interix[[3-9]]*) 6803 _LT_TAGVAR(hardcode_direct, $1)=no 6804 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 6805 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 6806 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 6807 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. 6808 # Instead, shared libraries are loaded at an image base (0x10000000 by 6809 # default) and relocated if they conflict, which is a slow very memory 6810 # consuming and fragmenting process. To avoid this, we pick a random, 6811 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link 6812 # time. Moving up from 0x10000000 also allows more sbrk(2) space. 6813 _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' 6814 _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' 6815 ;; 6816 6817 gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) 6818 tmp_diet=no 6819 if test "$host_os" = linux-dietlibc; then 6820 case $cc_basename in 6821 diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn) 6822 esac 6823 fi 6824 if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ 6825 && test "$tmp_diet" = no 6826 then 6827 tmp_addflag= 6828 tmp_sharedflag='-shared' 6829 case $cc_basename,$host_cpu in 6830 pgcc*) # Portland Group C compiler 6831 _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' 6832 tmp_addflag=' $pic_flag' 6833 ;; 6834 pgf77* | pgf90* | pgf95* | pgfortran*) 6835 # Portland Group f77 and f90 compilers 6836 _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' 6837 tmp_addflag=' $pic_flag -Mnomain' ;; 6838 ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 6839 tmp_addflag=' -i_dynamic' ;; 6840 efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 6841 tmp_addflag=' -i_dynamic -nofor_main' ;; 6842 ifc* | ifort*) # Intel Fortran compiler 6843 tmp_addflag=' -nofor_main' ;; 6844 lf95*) # Lahey Fortran 8.1 6845 _LT_TAGVAR(whole_archive_flag_spec, $1)= 6846 tmp_sharedflag='--shared' ;; 6847 xl[[cC]]* | bgxl[[cC]]* | mpixl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below) 6848 tmp_sharedflag='-qmkshrobj' 6849 tmp_addflag= ;; 6850 nvcc*) # Cuda Compiler Driver 2.2 6851 _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' 6852 _LT_TAGVAR(compiler_needs_object, $1)=yes 6853 ;; 6854 esac 6855 case `$CC -V 2>&1 | sed 5q` in 6856 *Sun\ C*) # Sun C 5.9 6857 _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' 6858 _LT_TAGVAR(compiler_needs_object, $1)=yes 6859 tmp_sharedflag='-G' ;; 6860 *Sun\ F*) # Sun Fortran 8.3 6861 tmp_sharedflag='-G' ;; 6862 esac 6863 _LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 6864 6865 if test "x$supports_anon_versioning" = xyes; then 6866 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ 6867 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ 6868 echo "local: *; };" >> $output_objdir/$libname.ver~ 6869 $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' 6870 fi 6871 6872 case $cc_basename in 6873 xlf* | bgf* | bgxlf* | mpixlf*) 6874 # IBM XL Fortran 10.1 on PPC cannot create shared libs itself 6875 _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive' 6876 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 6877 _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='-rpath $libdir' 6878 _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib' 6879 if test "x$supports_anon_versioning" = xyes; then 6880 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ 6881 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ 6882 echo "local: *; };" >> $output_objdir/$libname.ver~ 6883 $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' 6884 fi 6885 ;; 6886 esac 6887 else 6888 _LT_TAGVAR(ld_shlibs, $1)=no 6889 fi 6890 ;; 6891 6892 netbsd*) 6893 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then 6894 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' 6895 wlarc= 6896 else 6897 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 6898 _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' 6899 fi 6900 ;; 6901 6902 solaris*) 6903 if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then 6904 _LT_TAGVAR(ld_shlibs, $1)=no 6905 cat <<_LT_EOF 1>&2 6906 6907*** Warning: The releases 2.8.* of the GNU linker cannot reliably 6908*** create shared libraries on Solaris systems. Therefore, libtool 6909*** is disabling shared libraries support. We urge you to upgrade GNU 6910*** binutils to release 2.9.1 or newer. Another option is to modify 6911*** your PATH or compiler configuration so that the native linker is 6912*** used, and then restart. 6913 6914_LT_EOF 6915 elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 6916 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 6917 _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' 6918 else 6919 _LT_TAGVAR(ld_shlibs, $1)=no 6920 fi 6921 ;; 6922 6923 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) 6924 case `$LD -v 2>&1` in 6925 *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*) 6926 _LT_TAGVAR(ld_shlibs, $1)=no 6927 cat <<_LT_EOF 1>&2 6928 6929*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not 6930*** reliably create shared libraries on SCO systems. Therefore, libtool 6931*** is disabling shared libraries support. We urge you to upgrade GNU 6932*** binutils to release 2.16.91.0.3 or newer. Another option is to modify 6933*** your PATH or compiler configuration so that the native linker is 6934*** used, and then restart. 6935 6936_LT_EOF 6937 ;; 6938 *) 6939 # For security reasons, it is highly recommended that you always 6940 # use absolute paths for naming shared libraries, and exclude the 6941 # DT_RUNPATH tag from executables and libraries. But doing so 6942 # requires that you compile everything twice, which is a pain. 6943 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 6944 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 6945 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 6946 _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' 6947 else 6948 _LT_TAGVAR(ld_shlibs, $1)=no 6949 fi 6950 ;; 6951 esac 6952 ;; 6953 6954 sunos4*) 6955 _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' 6956 wlarc= 6957 _LT_TAGVAR(hardcode_direct, $1)=yes 6958 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 6959 ;; 6960 6961 *) 6962 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 6963 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 6964 _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' 6965 else 6966 _LT_TAGVAR(ld_shlibs, $1)=no 6967 fi 6968 ;; 6969 esac 6970 6971 if test "$_LT_TAGVAR(ld_shlibs, $1)" = no; then 6972 runpath_var= 6973 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 6974 _LT_TAGVAR(export_dynamic_flag_spec, $1)= 6975 _LT_TAGVAR(whole_archive_flag_spec, $1)= 6976 fi 6977 else 6978 # PORTME fill in a description of your system's linker (not GNU ld) 6979 case $host_os in 6980 aix3*) 6981 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 6982 _LT_TAGVAR(always_export_symbols, $1)=yes 6983 _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' 6984 # Note: this linker hardcodes the directories in LIBPATH if there 6985 # are no directories specified by -L. 6986 _LT_TAGVAR(hardcode_minus_L, $1)=yes 6987 if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then 6988 # Neither direct hardcoding nor static linking is supported with a 6989 # broken collect2. 6990 _LT_TAGVAR(hardcode_direct, $1)=unsupported 6991 fi 6992 ;; 6993 6994 aix[[4-9]]*) 6995 if test "$host_cpu" = ia64; then 6996 # On IA64, the linker does run time linking by default, so we don't 6997 # have to do anything special. 6998 aix_use_runtimelinking=no 6999 exp_sym_flag='-Bexport' 7000 no_entry_flag="" 7001 else 7002 # If we're using GNU nm, then we don't want the "-C" option. 7003 # -C means demangle to AIX nm, but means don't demangle with GNU nm 7004 # Also, AIX nm treats weak defined symbols like other global 7005 # defined symbols, whereas GNU nm marks them as "W". 7006 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then 7007 _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' 7008 else 7009 _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' 7010 fi 7011 aix_use_runtimelinking=no 7012 7013 # Test if we are trying to use run time linking or normal 7014 # AIX style linking. If -brtl is somewhere in LDFLAGS, we 7015 # need to do runtime linking. 7016 case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) 7017 for ld_flag in $LDFLAGS; do 7018 if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then 7019 aix_use_runtimelinking=yes 7020 break 7021 fi 7022 done 7023 ;; 7024 esac 7025 7026 exp_sym_flag='-bexport' 7027 no_entry_flag='-bnoentry' 7028 fi 7029 7030 # When large executables or shared objects are built, AIX ld can 7031 # have problems creating the table of contents. If linking a library 7032 # or program results in "error TOC overflow" add -mminimal-toc to 7033 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not 7034 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. 7035 7036 _LT_TAGVAR(archive_cmds, $1)='' 7037 _LT_TAGVAR(hardcode_direct, $1)=yes 7038 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 7039 _LT_TAGVAR(hardcode_libdir_separator, $1)=':' 7040 _LT_TAGVAR(link_all_deplibs, $1)=yes 7041 _LT_TAGVAR(file_list_spec, $1)='${wl}-f,' 7042 7043 if test "$GCC" = yes; then 7044 case $host_os in aix4.[[012]]|aix4.[[012]].*) 7045 # We only want to do this on AIX 4.2 and lower, the check 7046 # below for broken collect2 doesn't work under 4.3+ 7047 collect2name=`${CC} -print-prog-name=collect2` 7048 if test -f "$collect2name" && 7049 strings "$collect2name" | $GREP resolve_lib_name >/dev/null 7050 then 7051 # We have reworked collect2 7052 : 7053 else 7054 # We have old collect2 7055 _LT_TAGVAR(hardcode_direct, $1)=unsupported 7056 # It fails to find uninstalled libraries when the uninstalled 7057 # path is not listed in the libpath. Setting hardcode_minus_L 7058 # to unsupported forces relinking 7059 _LT_TAGVAR(hardcode_minus_L, $1)=yes 7060 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 7061 _LT_TAGVAR(hardcode_libdir_separator, $1)= 7062 fi 7063 ;; 7064 esac 7065 shared_flag='-shared' 7066 if test "$aix_use_runtimelinking" = yes; then 7067 shared_flag="$shared_flag "'${wl}-G' 7068 fi 7069 else 7070 # not using gcc 7071 if test "$host_cpu" = ia64; then 7072 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release 7073 # chokes on -Wl,-G. The following line is correct: 7074 shared_flag='-G' 7075 else 7076 if test "$aix_use_runtimelinking" = yes; then 7077 shared_flag='${wl}-G' 7078 else 7079 shared_flag='${wl}-bM:SRE' 7080 fi 7081 fi 7082 fi 7083 7084 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall' 7085 # It seems that -bexpall does not export symbols beginning with 7086 # underscore (_), so it is better to generate a list of symbols to export. 7087 _LT_TAGVAR(always_export_symbols, $1)=yes 7088 if test "$aix_use_runtimelinking" = yes; then 7089 # Warning - without using the other runtime loading flags (-brtl), 7090 # -berok will link without error, but may produce a broken library. 7091 _LT_TAGVAR(allow_undefined_flag, $1)='-berok' 7092 # Determine the default libpath from the value encoded in an 7093 # empty executable. 7094 _LT_SYS_MODULE_PATH_AIX 7095 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" 7096 _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" 7097 else 7098 if test "$host_cpu" = ia64; then 7099 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' 7100 _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" 7101 _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" 7102 else 7103 # Determine the default libpath from the value encoded in an 7104 # empty executable. 7105 _LT_SYS_MODULE_PATH_AIX 7106 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" 7107 # Warning - without using the other run time loading flags, 7108 # -berok will link without error, but may produce a broken library. 7109 _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' 7110 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' 7111 if test "$with_gnu_ld" = yes; then 7112 # We only use this code for GNU lds that support --whole-archive. 7113 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' 7114 else 7115 # Exported symbols can be pulled into shared objects from archives 7116 _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' 7117 fi 7118 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes 7119 # This is similar to how AIX traditionally builds its shared libraries. 7120 _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' 7121 fi 7122 fi 7123 ;; 7124 7125 amigaos*) 7126 case $host_cpu in 7127 powerpc) 7128 # see comment about AmigaOS4 .so support 7129 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 7130 _LT_TAGVAR(archive_expsym_cmds, $1)='' 7131 ;; 7132 m68k) 7133 _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)' 7134 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 7135 _LT_TAGVAR(hardcode_minus_L, $1)=yes 7136 ;; 7137 esac 7138 ;; 7139 7140 bsdi[[45]]*) 7141 _LT_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic 7142 ;; 7143 7144 cygwin* | mingw* | pw32* | cegcc*) 7145 # When not using gcc, we currently assume that we are using 7146 # Microsoft Visual C++. 7147 # hardcode_libdir_flag_spec is actually meaningless, as there is 7148 # no search path for DLLs. 7149 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' 7150 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 7151 # Tell ltmain to make .lib files, not .a files. 7152 libext=lib 7153 # Tell ltmain to make .dll files, not .so files. 7154 shrext_cmds=".dll" 7155 # FIXME: Setting linknames here is a bad hack. 7156 _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames=' 7157 # The linker will automatically build a .lib file if we build a DLL. 7158 _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' 7159 # FIXME: Should let the user specify the lib program. 7160 _LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs' 7161 _LT_TAGVAR(fix_srcfile_path, $1)='`cygpath -w "$srcfile"`' 7162 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 7163 ;; 7164 7165 darwin* | rhapsody*) 7166 _LT_DARWIN_LINKER_FEATURES($1) 7167 ;; 7168 7169 dgux*) 7170 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 7171 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 7172 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7173 ;; 7174 7175 freebsd1*) 7176 _LT_TAGVAR(ld_shlibs, $1)=no 7177 ;; 7178 7179 # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor 7180 # support. Future versions do this automatically, but an explicit c++rt0.o 7181 # does not break anything, and helps significantly (at the cost of a little 7182 # extra space). 7183 freebsd2.2*) 7184 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' 7185 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 7186 _LT_TAGVAR(hardcode_direct, $1)=yes 7187 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7188 ;; 7189 7190 # Unfortunately, older versions of FreeBSD 2 do not have this feature. 7191 freebsd2*) 7192 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' 7193 _LT_TAGVAR(hardcode_direct, $1)=yes 7194 _LT_TAGVAR(hardcode_minus_L, $1)=yes 7195 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7196 ;; 7197 7198 # FreeBSD 3 and greater uses gcc -shared to do shared libraries. 7199 freebsd* | dragonfly*) 7200 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' 7201 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 7202 _LT_TAGVAR(hardcode_direct, $1)=yes 7203 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7204 ;; 7205 7206 hpux9*) 7207 if test "$GCC" = yes; then 7208 _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' 7209 else 7210 _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' 7211 fi 7212 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 7213 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 7214 _LT_TAGVAR(hardcode_direct, $1)=yes 7215 7216 # hardcode_minus_L: Not really in the search PATH, 7217 # but as the default location of the library. 7218 _LT_TAGVAR(hardcode_minus_L, $1)=yes 7219 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 7220 ;; 7221 7222 hpux10*) 7223 if test "$GCC" = yes && test "$with_gnu_ld" = no; then 7224 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' 7225 else 7226 _LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' 7227 fi 7228 if test "$with_gnu_ld" = no; then 7229 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 7230 _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir' 7231 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 7232 _LT_TAGVAR(hardcode_direct, $1)=yes 7233 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 7234 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 7235 # hardcode_minus_L: Not really in the search PATH, 7236 # but as the default location of the library. 7237 _LT_TAGVAR(hardcode_minus_L, $1)=yes 7238 fi 7239 ;; 7240 7241 hpux11*) 7242 if test "$GCC" = yes && test "$with_gnu_ld" = no; then 7243 case $host_cpu in 7244 hppa*64*) 7245 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' 7246 ;; 7247 ia64*) 7248 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' 7249 ;; 7250 *) 7251 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' 7252 ;; 7253 esac 7254 else 7255 case $host_cpu in 7256 hppa*64*) 7257 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' 7258 ;; 7259 ia64*) 7260 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' 7261 ;; 7262 *) 7263 m4_if($1, [], [ 7264 # Older versions of the 11.00 compiler do not understand -b yet 7265 # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does) 7266 _LT_LINKER_OPTION([if $CC understands -b], 7267 _LT_TAGVAR(lt_cv_prog_compiler__b, $1), [-b], 7268 [_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'], 7269 [_LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'])], 7270 [_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags']) 7271 ;; 7272 esac 7273 fi 7274 if test "$with_gnu_ld" = no; then 7275 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 7276 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 7277 7278 case $host_cpu in 7279 hppa*64*|ia64*) 7280 _LT_TAGVAR(hardcode_direct, $1)=no 7281 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7282 ;; 7283 *) 7284 _LT_TAGVAR(hardcode_direct, $1)=yes 7285 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 7286 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 7287 7288 # hardcode_minus_L: Not really in the search PATH, 7289 # but as the default location of the library. 7290 _LT_TAGVAR(hardcode_minus_L, $1)=yes 7291 ;; 7292 esac 7293 fi 7294 ;; 7295 7296 irix5* | irix6* | nonstopux*) 7297 if test "$GCC" = yes; then 7298 _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' 7299 # Try to use the -exported_symbol ld option, if it does not 7300 # work, assume that -exports_file does not work either and 7301 # implicitly export all symbols. 7302 save_LDFLAGS="$LDFLAGS" 7303 LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null" 7304 AC_LINK_IFELSE(int foo(void) {}, 7305 _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' 7306 ) 7307 LDFLAGS="$save_LDFLAGS" 7308 else 7309 _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' 7310 _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' 7311 fi 7312 _LT_TAGVAR(archive_cmds_need_lc, $1)='no' 7313 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 7314 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 7315 _LT_TAGVAR(inherit_rpath, $1)=yes 7316 _LT_TAGVAR(link_all_deplibs, $1)=yes 7317 ;; 7318 7319 netbsd*) 7320 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then 7321 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out 7322 else 7323 _LT_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF 7324 fi 7325 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 7326 _LT_TAGVAR(hardcode_direct, $1)=yes 7327 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7328 ;; 7329 7330 newsos6) 7331 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 7332 _LT_TAGVAR(hardcode_direct, $1)=yes 7333 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 7334 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 7335 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7336 ;; 7337 7338 *nto* | *qnx*) 7339 ;; 7340 7341 openbsd*) 7342 if test -f /usr/libexec/ld.so; then 7343 _LT_TAGVAR(hardcode_direct, $1)=yes 7344 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7345 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 7346 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then 7347 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' 7348 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' 7349 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 7350 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 7351 else 7352 case $host_os in 7353 openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*) 7354 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' 7355 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 7356 ;; 7357 *) 7358 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' 7359 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 7360 ;; 7361 esac 7362 fi 7363 else 7364 _LT_TAGVAR(ld_shlibs, $1)=no 7365 fi 7366 ;; 7367 7368 os2*) 7369 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 7370 _LT_TAGVAR(hardcode_minus_L, $1)=yes 7371 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 7372 _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' 7373 _LT_TAGVAR(old_archive_from_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' 7374 ;; 7375 7376 osf3*) 7377 if test "$GCC" = yes; then 7378 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' 7379 _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' 7380 else 7381 _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' 7382 _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' 7383 fi 7384 _LT_TAGVAR(archive_cmds_need_lc, $1)='no' 7385 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 7386 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 7387 ;; 7388 7389 osf4* | osf5*) # as osf3* with the addition of -msym flag 7390 if test "$GCC" = yes; then 7391 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' 7392 _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' 7393 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 7394 else 7395 _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' 7396 _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' 7397 _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~ 7398 $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' 7399 7400 # Both c and cxx compiler support -rpath directly 7401 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' 7402 fi 7403 _LT_TAGVAR(archive_cmds_need_lc, $1)='no' 7404 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 7405 ;; 7406 7407 solaris*) 7408 _LT_TAGVAR(no_undefined_flag, $1)=' -z defs' 7409 if test "$GCC" = yes; then 7410 wlarc='${wl}' 7411 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' 7412 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 7413 $CC -shared ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' 7414 else 7415 case `$CC -V 2>&1` in 7416 *"Compilers 5.0"*) 7417 wlarc='' 7418 _LT_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_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 $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' 7421 ;; 7422 *) 7423 wlarc='${wl}' 7424 _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags' 7425 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 7426 $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' 7427 ;; 7428 esac 7429 fi 7430 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 7431 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7432 case $host_os in 7433 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; 7434 *) 7435 # The compiler driver will combine and reorder linker options, 7436 # but understands `-z linker_flag'. GCC discards it without `$wl', 7437 # but is careful enough not to reorder. 7438 # Supported since Solaris 2.6 (maybe 2.5.1?) 7439 if test "$GCC" = yes; then 7440 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' 7441 else 7442 _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' 7443 fi 7444 ;; 7445 esac 7446 _LT_TAGVAR(link_all_deplibs, $1)=yes 7447 ;; 7448 7449 sunos4*) 7450 if test "x$host_vendor" = xsequent; then 7451 # Use $CC to link under sequent, because it throws in some extra .o 7452 # files that make .init and .fini sections work. 7453 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' 7454 else 7455 _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' 7456 fi 7457 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 7458 _LT_TAGVAR(hardcode_direct, $1)=yes 7459 _LT_TAGVAR(hardcode_minus_L, $1)=yes 7460 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7461 ;; 7462 7463 sysv4) 7464 case $host_vendor in 7465 sni) 7466 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 7467 _LT_TAGVAR(hardcode_direct, $1)=yes # is this really true??? 7468 ;; 7469 siemens) 7470 ## LD is ld it makes a PLAMLIB 7471 ## CC just makes a GrossModule. 7472 _LT_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags' 7473 _LT_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs' 7474 _LT_TAGVAR(hardcode_direct, $1)=no 7475 ;; 7476 motorola) 7477 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 7478 _LT_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie 7479 ;; 7480 esac 7481 runpath_var='LD_RUN_PATH' 7482 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7483 ;; 7484 7485 sysv4.3*) 7486 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 7487 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7488 _LT_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport' 7489 ;; 7490 7491 sysv4*MP*) 7492 if test -d /usr/nec; then 7493 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 7494 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7495 runpath_var=LD_RUN_PATH 7496 hardcode_runpath_var=yes 7497 _LT_TAGVAR(ld_shlibs, $1)=yes 7498 fi 7499 ;; 7500 7501 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) 7502 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' 7503 _LT_TAGVAR(archive_cmds_need_lc, $1)=no 7504 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7505 runpath_var='LD_RUN_PATH' 7506 7507 if test "$GCC" = yes; then 7508 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 7509 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 7510 else 7511 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 7512 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 7513 fi 7514 ;; 7515 7516 sysv5* | sco3.2v5* | sco5v6*) 7517 # Note: We can NOT use -z defs as we might desire, because we do not 7518 # link with -lc, and that would cause any symbols used from libc to 7519 # always be unresolved, which means just about no library would 7520 # ever link correctly. If we're not using GNU ld we use -z text 7521 # though, which does catch some bad symbols but isn't as heavy-handed 7522 # as -z defs. 7523 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' 7524 _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs' 7525 _LT_TAGVAR(archive_cmds_need_lc, $1)=no 7526 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7527 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir' 7528 _LT_TAGVAR(hardcode_libdir_separator, $1)=':' 7529 _LT_TAGVAR(link_all_deplibs, $1)=yes 7530 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' 7531 runpath_var='LD_RUN_PATH' 7532 7533 if test "$GCC" = yes; then 7534 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 7535 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 7536 else 7537 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 7538 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 7539 fi 7540 ;; 7541 7542 uts4*) 7543 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 7544 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 7545 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 7546 ;; 7547 7548 *) 7549 _LT_TAGVAR(ld_shlibs, $1)=no 7550 ;; 7551 esac 7552 7553 if test x$host_vendor = xsni; then 7554 case $host in 7555 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) 7556 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Blargedynsym' 7557 ;; 7558 esac 7559 fi 7560 fi 7561]) 7562AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) 7563test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no 7564 7565_LT_TAGVAR(with_gnu_ld, $1)=$with_gnu_ld 7566 7567_LT_DECL([], [libext], [0], [Old archive suffix (normally "a")])dnl 7568_LT_DECL([], [shrext_cmds], [1], [Shared library suffix (normally ".so")])dnl 7569_LT_DECL([], [extract_expsyms_cmds], [2], 7570 [The commands to extract the exported symbol list from a shared archive]) 7571 7572# 7573# Do we need to explicitly link libc? 7574# 7575case "x$_LT_TAGVAR(archive_cmds_need_lc, $1)" in 7576x|xyes) 7577 # Assume -lc should be added 7578 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes 7579 7580 if test "$enable_shared" = yes && test "$GCC" = yes; then 7581 case $_LT_TAGVAR(archive_cmds, $1) in 7582 *'~'*) 7583 # FIXME: we may have to deal with multi-command sequences. 7584 ;; 7585 '$CC '*) 7586 # Test whether the compiler implicitly links with -lc since on some 7587 # systems, -lgcc has to come before -lc. If gcc already passes -lc 7588 # to ld, don't add -lc before -lgcc. 7589 AC_CACHE_CHECK([whether -lc should be explicitly linked in], 7590 [lt_cv_]_LT_TAGVAR(archive_cmds_need_lc, $1), 7591 [$RM conftest* 7592 echo "$lt_simple_compile_test_code" > conftest.$ac_ext 7593 7594 if AC_TRY_EVAL(ac_compile) 2>conftest.err; then 7595 soname=conftest 7596 lib=conftest 7597 libobjs=conftest.$ac_objext 7598 deplibs= 7599 wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) 7600 pic_flag=$_LT_TAGVAR(lt_prog_compiler_pic, $1) 7601 compiler_flags=-v 7602 linker_flags=-v 7603 verstring= 7604 output_objdir=. 7605 libname=conftest 7606 lt_save_allow_undefined_flag=$_LT_TAGVAR(allow_undefined_flag, $1) 7607 _LT_TAGVAR(allow_undefined_flag, $1)= 7608 if AC_TRY_EVAL(_LT_TAGVAR(archive_cmds, $1) 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 7609 then 7610 lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=no 7611 else 7612 lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=yes 7613 fi 7614 _LT_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag 7615 else 7616 cat conftest.err 1>&5 7617 fi 7618 $RM conftest* 7619 ]) 7620 _LT_TAGVAR(archive_cmds_need_lc, $1)=$lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1) 7621 ;; 7622 esac 7623 fi 7624 ;; 7625esac 7626 7627_LT_TAGDECL([build_libtool_need_lc], [archive_cmds_need_lc], [0], 7628 [Whether or not to add -lc for building shared libraries]) 7629_LT_TAGDECL([allow_libtool_libs_with_static_runtimes], 7630 [enable_shared_with_static_runtimes], [0], 7631 [Whether or not to disallow shared libs when runtime libs are static]) 7632_LT_TAGDECL([], [export_dynamic_flag_spec], [1], 7633 [Compiler flag to allow reflexive dlopens]) 7634_LT_TAGDECL([], [whole_archive_flag_spec], [1], 7635 [Compiler flag to generate shared objects directly from archives]) 7636_LT_TAGDECL([], [compiler_needs_object], [1], 7637 [Whether the compiler copes with passing no objects directly]) 7638_LT_TAGDECL([], [old_archive_from_new_cmds], [2], 7639 [Create an old-style archive from a shared archive]) 7640_LT_TAGDECL([], [old_archive_from_expsyms_cmds], [2], 7641 [Create a temporary old-style archive to link instead of a shared archive]) 7642_LT_TAGDECL([], [archive_cmds], [2], [Commands used to build a shared archive]) 7643_LT_TAGDECL([], [archive_expsym_cmds], [2]) 7644_LT_TAGDECL([], [module_cmds], [2], 7645 [Commands used to build a loadable module if different from building 7646 a shared archive.]) 7647_LT_TAGDECL([], [module_expsym_cmds], [2]) 7648_LT_TAGDECL([], [with_gnu_ld], [1], 7649 [Whether we are building with GNU ld or not]) 7650_LT_TAGDECL([], [allow_undefined_flag], [1], 7651 [Flag that allows shared libraries with undefined symbols to be built]) 7652_LT_TAGDECL([], [no_undefined_flag], [1], 7653 [Flag that enforces no undefined symbols]) 7654_LT_TAGDECL([], [hardcode_libdir_flag_spec], [1], 7655 [Flag to hardcode $libdir into a binary during linking. 7656 This must work even if $libdir does not exist]) 7657_LT_TAGDECL([], [hardcode_libdir_flag_spec_ld], [1], 7658 [[If ld is used when linking, flag to hardcode $libdir into a binary 7659 during linking. This must work even if $libdir does not exist]]) 7660_LT_TAGDECL([], [hardcode_libdir_separator], [1], 7661 [Whether we need a single "-rpath" flag with a separated argument]) 7662_LT_TAGDECL([], [hardcode_direct], [0], 7663 [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes 7664 DIR into the resulting binary]) 7665_LT_TAGDECL([], [hardcode_direct_absolute], [0], 7666 [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes 7667 DIR into the resulting binary and the resulting library dependency is 7668 "absolute", i.e impossible to change by setting ${shlibpath_var} if the 7669 library is relocated]) 7670_LT_TAGDECL([], [hardcode_minus_L], [0], 7671 [Set to "yes" if using the -LDIR flag during linking hardcodes DIR 7672 into the resulting binary]) 7673_LT_TAGDECL([], [hardcode_shlibpath_var], [0], 7674 [Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR 7675 into the resulting binary]) 7676_LT_TAGDECL([], [hardcode_automatic], [0], 7677 [Set to "yes" if building a shared library automatically hardcodes DIR 7678 into the library and all subsequent libraries and executables linked 7679 against it]) 7680_LT_TAGDECL([], [inherit_rpath], [0], 7681 [Set to yes if linker adds runtime paths of dependent libraries 7682 to runtime path list]) 7683_LT_TAGDECL([], [link_all_deplibs], [0], 7684 [Whether libtool must link a program against all its dependency libraries]) 7685_LT_TAGDECL([], [fix_srcfile_path], [1], 7686 [Fix the shell variable $srcfile for the compiler]) 7687_LT_TAGDECL([], [always_export_symbols], [0], 7688 [Set to "yes" if exported symbols are required]) 7689_LT_TAGDECL([], [export_symbols_cmds], [2], 7690 [The commands to list exported symbols]) 7691_LT_TAGDECL([], [exclude_expsyms], [1], 7692 [Symbols that should not be listed in the preloaded symbols]) 7693_LT_TAGDECL([], [include_expsyms], [1], 7694 [Symbols that must always be exported]) 7695_LT_TAGDECL([], [prelink_cmds], [2], 7696 [Commands necessary for linking programs (against libraries) with templates]) 7697_LT_TAGDECL([], [file_list_spec], [1], 7698 [Specify filename containing input files]) 7699dnl FIXME: Not yet implemented 7700dnl _LT_TAGDECL([], [thread_safe_flag_spec], [1], 7701dnl [Compiler flag to generate thread safe objects]) 7702])# _LT_LINKER_SHLIBS 7703 7704 7705# _LT_LANG_C_CONFIG([TAG]) 7706# ------------------------ 7707# Ensure that the configuration variables for a C compiler are suitably 7708# defined. These variables are subsequently used by _LT_CONFIG to write 7709# the compiler configuration to `libtool'. 7710m4_defun([_LT_LANG_C_CONFIG], 7711[m4_require([_LT_DECL_EGREP])dnl 7712lt_save_CC="$CC" 7713AC_LANG_PUSH(C) 7714 7715# Source file extension for C test sources. 7716ac_ext=c 7717 7718# Object file extension for compiled C test sources. 7719objext=o 7720_LT_TAGVAR(objext, $1)=$objext 7721 7722# Code to be used in simple compile tests 7723lt_simple_compile_test_code="int some_variable = 0;" 7724 7725# Code to be used in simple link tests 7726lt_simple_link_test_code='int main(){return(0);}' 7727 7728_LT_TAG_COMPILER 7729# Save the default compiler, since it gets overwritten when the other 7730# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP. 7731compiler_DEFAULT=$CC 7732 7733# save warnings/boilerplate of simple test code 7734_LT_COMPILER_BOILERPLATE 7735_LT_LINKER_BOILERPLATE 7736 7737if test -n "$compiler"; then 7738 _LT_COMPILER_NO_RTTI($1) 7739 _LT_COMPILER_PIC($1) 7740 _LT_COMPILER_C_O($1) 7741 _LT_COMPILER_FILE_LOCKS($1) 7742 _LT_LINKER_SHLIBS($1) 7743 _LT_SYS_DYNAMIC_LINKER($1) 7744 _LT_LINKER_HARDCODE_LIBPATH($1) 7745 LT_SYS_DLOPEN_SELF 7746 _LT_CMD_STRIPLIB 7747 7748 # Report which library types will actually be built 7749 AC_MSG_CHECKING([if libtool supports shared libraries]) 7750 AC_MSG_RESULT([$can_build_shared]) 7751 7752 AC_MSG_CHECKING([whether to build shared libraries]) 7753 test "$can_build_shared" = "no" && enable_shared=no 7754 7755 # On AIX, shared libraries and static libraries use the same namespace, and 7756 # are all built from PIC. 7757 case $host_os in 7758 aix3*) 7759 test "$enable_shared" = yes && enable_static=no 7760 if test -n "$RANLIB"; then 7761 archive_cmds="$archive_cmds~\$RANLIB \$lib" 7762 postinstall_cmds='$RANLIB $lib' 7763 fi 7764 ;; 7765 7766 aix[[4-9]]*) 7767 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then 7768 test "$enable_shared" = yes && enable_static=no 7769 fi 7770 ;; 7771 esac 7772 AC_MSG_RESULT([$enable_shared]) 7773 7774 AC_MSG_CHECKING([whether to build static libraries]) 7775 # Make sure either enable_shared or enable_static is yes. 7776 test "$enable_shared" = yes || enable_static=yes 7777 AC_MSG_RESULT([$enable_static]) 7778 7779 _LT_CONFIG($1) 7780fi 7781AC_LANG_POP 7782CC="$lt_save_CC" 7783])# _LT_LANG_C_CONFIG 7784 7785 7786# _LT_LANG_CXX_CONFIG([TAG]) 7787# -------------------------- 7788# Ensure that the configuration variables for a C++ compiler are suitably 7789# defined. These variables are subsequently used by _LT_CONFIG to write 7790# the compiler configuration to `libtool'. 7791m4_defun([_LT_LANG_CXX_CONFIG], 7792[m4_require([_LT_FILEUTILS_DEFAULTS])dnl 7793m4_require([_LT_DECL_EGREP])dnl 7794if test -n "$CXX" && ( test "X$CXX" != "Xno" && 7795 ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || 7796 (test "X$CXX" != "Xg++"))) ; then 7797 AC_PROG_CXXCPP 7798else 7799 _lt_caught_CXX_error=yes 7800fi 7801 7802AC_LANG_PUSH(C++) 7803_LT_TAGVAR(archive_cmds_need_lc, $1)=no 7804_LT_TAGVAR(allow_undefined_flag, $1)= 7805_LT_TAGVAR(always_export_symbols, $1)=no 7806_LT_TAGVAR(archive_expsym_cmds, $1)= 7807_LT_TAGVAR(compiler_needs_object, $1)=no 7808_LT_TAGVAR(export_dynamic_flag_spec, $1)= 7809_LT_TAGVAR(hardcode_direct, $1)=no 7810_LT_TAGVAR(hardcode_direct_absolute, $1)=no 7811_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 7812_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= 7813_LT_TAGVAR(hardcode_libdir_separator, $1)= 7814_LT_TAGVAR(hardcode_minus_L, $1)=no 7815_LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported 7816_LT_TAGVAR(hardcode_automatic, $1)=no 7817_LT_TAGVAR(inherit_rpath, $1)=no 7818_LT_TAGVAR(module_cmds, $1)= 7819_LT_TAGVAR(module_expsym_cmds, $1)= 7820_LT_TAGVAR(link_all_deplibs, $1)=unknown 7821_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 7822_LT_TAGVAR(reload_flag, $1)=$reload_flag 7823_LT_TAGVAR(reload_cmds, $1)=$reload_cmds 7824_LT_TAGVAR(no_undefined_flag, $1)= 7825_LT_TAGVAR(whole_archive_flag_spec, $1)= 7826_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no 7827 7828# Source file extension for C++ test sources. 7829ac_ext=cpp 7830 7831# Object file extension for compiled C++ test sources. 7832objext=o 7833_LT_TAGVAR(objext, $1)=$objext 7834 7835# No sense in running all these tests if we already determined that 7836# the CXX compiler isn't working. Some variables (like enable_shared) 7837# are currently assumed to apply to all compilers on this platform, 7838# and will be corrupted by setting them based on a non-working compiler. 7839if test "$_lt_caught_CXX_error" != yes; then 7840 # Code to be used in simple compile tests 7841 lt_simple_compile_test_code="int some_variable = 0;" 7842 7843 # Code to be used in simple link tests 7844 lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }' 7845 7846 # ltmain only uses $CC for tagged configurations so make sure $CC is set. 7847 _LT_TAG_COMPILER 7848 7849 # save warnings/boilerplate of simple test code 7850 _LT_COMPILER_BOILERPLATE 7851 _LT_LINKER_BOILERPLATE 7852 7853 # Allow CC to be a program name with arguments. 7854 lt_save_CC=$CC 7855 lt_save_LD=$LD 7856 lt_save_GCC=$GCC 7857 GCC=$GXX 7858 lt_save_with_gnu_ld=$with_gnu_ld 7859 lt_save_path_LD=$lt_cv_path_LD 7860 if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then 7861 lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx 7862 else 7863 $as_unset lt_cv_prog_gnu_ld 7864 fi 7865 if test -n "${lt_cv_path_LDCXX+set}"; then 7866 lt_cv_path_LD=$lt_cv_path_LDCXX 7867 else 7868 $as_unset lt_cv_path_LD 7869 fi 7870 test -z "${LDCXX+set}" || LD=$LDCXX 7871 CC=${CXX-"c++"} 7872 compiler=$CC 7873 _LT_TAGVAR(compiler, $1)=$CC 7874 _LT_CC_BASENAME([$compiler]) 7875 7876 if test -n "$compiler"; then 7877 # We don't want -fno-exception when compiling C++ code, so set the 7878 # no_builtin_flag separately 7879 if test "$GXX" = yes; then 7880 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' 7881 else 7882 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= 7883 fi 7884 7885 if test "$GXX" = yes; then 7886 # Set up default GNU C++ configuration 7887 7888 LT_PATH_LD 7889 7890 # Check if GNU C++ uses GNU ld as the underlying linker, since the 7891 # archiving commands below assume that GNU ld is being used. 7892 if test "$with_gnu_ld" = yes; then 7893 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' 7894 _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' 7895 7896 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 7897 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 7898 7899 # If archive_cmds runs LD, not CC, wlarc should be empty 7900 # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to 7901 # investigate it a little bit more. (MM) 7902 wlarc='${wl}' 7903 7904 # ancient GNU ld didn't support --whole-archive et. al. 7905 if eval "`$CC -print-prog-name=ld` --help 2>&1" | 7906 $GREP 'no-whole-archive' > /dev/null; then 7907 _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' 7908 else 7909 _LT_TAGVAR(whole_archive_flag_spec, $1)= 7910 fi 7911 else 7912 with_gnu_ld=no 7913 wlarc= 7914 7915 # A generic and very simple default shared library creation 7916 # command for GNU C++ for the case where it uses the native 7917 # linker, instead of GNU ld. If possible, this setting should 7918 # overridden to take advantage of the native linker features on 7919 # the platform it is being used on. 7920 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' 7921 fi 7922 7923 # Commands to make compiler produce verbose output that lists 7924 # what "hidden" libraries, object files and flags are used when 7925 # linking a shared library. 7926 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' 7927 7928 else 7929 GXX=no 7930 with_gnu_ld=no 7931 wlarc= 7932 fi 7933 7934 # PORTME: fill in a description of your system's C++ link characteristics 7935 AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) 7936 _LT_TAGVAR(ld_shlibs, $1)=yes 7937 case $host_os in 7938 aix3*) 7939 # FIXME: insert proper C++ library support 7940 _LT_TAGVAR(ld_shlibs, $1)=no 7941 ;; 7942 aix[[4-9]]*) 7943 if test "$host_cpu" = ia64; then 7944 # On IA64, the linker does run time linking by default, so we don't 7945 # have to do anything special. 7946 aix_use_runtimelinking=no 7947 exp_sym_flag='-Bexport' 7948 no_entry_flag="" 7949 else 7950 aix_use_runtimelinking=no 7951 7952 # Test if we are trying to use run time linking or normal 7953 # AIX style linking. If -brtl is somewhere in LDFLAGS, we 7954 # need to do runtime linking. 7955 case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) 7956 for ld_flag in $LDFLAGS; do 7957 case $ld_flag in 7958 *-brtl*) 7959 aix_use_runtimelinking=yes 7960 break 7961 ;; 7962 esac 7963 done 7964 ;; 7965 esac 7966 7967 exp_sym_flag='-bexport' 7968 no_entry_flag='-bnoentry' 7969 fi 7970 7971 # When large executables or shared objects are built, AIX ld can 7972 # have problems creating the table of contents. If linking a library 7973 # or program results in "error TOC overflow" add -mminimal-toc to 7974 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not 7975 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. 7976 7977 _LT_TAGVAR(archive_cmds, $1)='' 7978 _LT_TAGVAR(hardcode_direct, $1)=yes 7979 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 7980 _LT_TAGVAR(hardcode_libdir_separator, $1)=':' 7981 _LT_TAGVAR(link_all_deplibs, $1)=yes 7982 _LT_TAGVAR(file_list_spec, $1)='${wl}-f,' 7983 7984 if test "$GXX" = yes; then 7985 case $host_os in aix4.[[012]]|aix4.[[012]].*) 7986 # We only want to do this on AIX 4.2 and lower, the check 7987 # below for broken collect2 doesn't work under 4.3+ 7988 collect2name=`${CC} -print-prog-name=collect2` 7989 if test -f "$collect2name" && 7990 strings "$collect2name" | $GREP resolve_lib_name >/dev/null 7991 then 7992 # We have reworked collect2 7993 : 7994 else 7995 # We have old collect2 7996 _LT_TAGVAR(hardcode_direct, $1)=unsupported 7997 # It fails to find uninstalled libraries when the uninstalled 7998 # path is not listed in the libpath. Setting hardcode_minus_L 7999 # to unsupported forces relinking 8000 _LT_TAGVAR(hardcode_minus_L, $1)=yes 8001 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 8002 _LT_TAGVAR(hardcode_libdir_separator, $1)= 8003 fi 8004 esac 8005 shared_flag='-shared' 8006 if test "$aix_use_runtimelinking" = yes; then 8007 shared_flag="$shared_flag "'${wl}-G' 8008 fi 8009 else 8010 # not using gcc 8011 if test "$host_cpu" = ia64; then 8012 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release 8013 # chokes on -Wl,-G. The following line is correct: 8014 shared_flag='-G' 8015 else 8016 if test "$aix_use_runtimelinking" = yes; then 8017 shared_flag='${wl}-G' 8018 else 8019 shared_flag='${wl}-bM:SRE' 8020 fi 8021 fi 8022 fi 8023 8024 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall' 8025 # It seems that -bexpall does not export symbols beginning with 8026 # underscore (_), so it is better to generate a list of symbols to 8027 # export. 8028 _LT_TAGVAR(always_export_symbols, $1)=yes 8029 if test "$aix_use_runtimelinking" = yes; then 8030 # Warning - without using the other runtime loading flags (-brtl), 8031 # -berok will link without error, but may produce a broken library. 8032 _LT_TAGVAR(allow_undefined_flag, $1)='-berok' 8033 # Determine the default libpath from the value encoded in an empty 8034 # executable. 8035 _LT_SYS_MODULE_PATH_AIX 8036 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" 8037 8038 _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" 8039 else 8040 if test "$host_cpu" = ia64; then 8041 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' 8042 _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" 8043 _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" 8044 else 8045 # Determine the default libpath from the value encoded in an 8046 # empty executable. 8047 _LT_SYS_MODULE_PATH_AIX 8048 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" 8049 # Warning - without using the other run time loading flags, 8050 # -berok will link without error, but may produce a broken library. 8051 _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' 8052 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' 8053 if test "$with_gnu_ld" = yes; then 8054 # We only use this code for GNU lds that support --whole-archive. 8055 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' 8056 else 8057 # Exported symbols can be pulled into shared objects from archives 8058 _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' 8059 fi 8060 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes 8061 # This is similar to how AIX traditionally builds its shared 8062 # libraries. 8063 _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' 8064 fi 8065 fi 8066 ;; 8067 8068 beos*) 8069 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 8070 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 8071 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc 8072 # support --undefined. This deserves some investigation. FIXME 8073 _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 8074 else 8075 _LT_TAGVAR(ld_shlibs, $1)=no 8076 fi 8077 ;; 8078 8079 chorus*) 8080 case $cc_basename in 8081 *) 8082 # FIXME: insert proper C++ library support 8083 _LT_TAGVAR(ld_shlibs, $1)=no 8084 ;; 8085 esac 8086 ;; 8087 8088 cygwin* | mingw* | pw32* | cegcc*) 8089 # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, 8090 # as there is no search path for DLLs. 8091 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 8092 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols' 8093 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 8094 _LT_TAGVAR(always_export_symbols, $1)=no 8095 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 8096 8097 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then 8098 _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' 8099 # If the export-symbols file already is a .def file (1st line 8100 # is EXPORTS), use it as is; otherwise, prepend... 8101 _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then 8102 cp $export_symbols $output_objdir/$soname.def; 8103 else 8104 echo EXPORTS > $output_objdir/$soname.def; 8105 cat $export_symbols >> $output_objdir/$soname.def; 8106 fi~ 8107 $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' 8108 else 8109 _LT_TAGVAR(ld_shlibs, $1)=no 8110 fi 8111 ;; 8112 darwin* | rhapsody*) 8113 _LT_DARWIN_LINKER_FEATURES($1) 8114 ;; 8115 8116 dgux*) 8117 case $cc_basename in 8118 ec++*) 8119 # FIXME: insert proper C++ library support 8120 _LT_TAGVAR(ld_shlibs, $1)=no 8121 ;; 8122 ghcx*) 8123 # Green Hills C++ Compiler 8124 # FIXME: insert proper C++ library support 8125 _LT_TAGVAR(ld_shlibs, $1)=no 8126 ;; 8127 *) 8128 # FIXME: insert proper C++ library support 8129 _LT_TAGVAR(ld_shlibs, $1)=no 8130 ;; 8131 esac 8132 ;; 8133 8134 freebsd[[12]]*) 8135 # C++ shared libraries reported to be fairly broken before 8136 # switch to ELF 8137 _LT_TAGVAR(ld_shlibs, $1)=no 8138 ;; 8139 8140 freebsd-elf*) 8141 _LT_TAGVAR(archive_cmds_need_lc, $1)=no 8142 ;; 8143 8144 freebsd* | dragonfly*) 8145 # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF 8146 # conventions 8147 _LT_TAGVAR(ld_shlibs, $1)=yes 8148 ;; 8149 8150 gnu*) 8151 ;; 8152 8153 haiku*) 8154 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 8155 _LT_TAGVAR(link_all_deplibs, $1)=yes 8156 ;; 8157 8158 hpux9*) 8159 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 8160 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 8161 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 8162 _LT_TAGVAR(hardcode_direct, $1)=yes 8163 _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, 8164 # but as the default 8165 # location of the library. 8166 8167 case $cc_basename in 8168 CC*) 8169 # FIXME: insert proper C++ library support 8170 _LT_TAGVAR(ld_shlibs, $1)=no 8171 ;; 8172 aCC*) 8173 _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' 8174 # Commands to make compiler produce verbose output that lists 8175 # what "hidden" libraries, object files and flags are used when 8176 # linking a shared library. 8177 # 8178 # There doesn't appear to be a way to prevent this compiler from 8179 # explicitly linking system object files so we need to strip them 8180 # from the output so that they don't get included in the library 8181 # dependencies. 8182 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"' 8183 ;; 8184 *) 8185 if test "$GXX" = yes; then 8186 _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' 8187 else 8188 # FIXME: insert proper C++ library support 8189 _LT_TAGVAR(ld_shlibs, $1)=no 8190 fi 8191 ;; 8192 esac 8193 ;; 8194 8195 hpux10*|hpux11*) 8196 if test $with_gnu_ld = no; then 8197 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 8198 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 8199 8200 case $host_cpu in 8201 hppa*64*|ia64*) 8202 ;; 8203 *) 8204 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 8205 ;; 8206 esac 8207 fi 8208 case $host_cpu in 8209 hppa*64*|ia64*) 8210 _LT_TAGVAR(hardcode_direct, $1)=no 8211 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 8212 ;; 8213 *) 8214 _LT_TAGVAR(hardcode_direct, $1)=yes 8215 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 8216 _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, 8217 # but as the default 8218 # location of the library. 8219 ;; 8220 esac 8221 8222 case $cc_basename in 8223 CC*) 8224 # FIXME: insert proper C++ library support 8225 _LT_TAGVAR(ld_shlibs, $1)=no 8226 ;; 8227 aCC*) 8228 case $host_cpu in 8229 hppa*64*) 8230 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 8231 ;; 8232 ia64*) 8233 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 8234 ;; 8235 *) 8236 _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' 8237 ;; 8238 esac 8239 # Commands to make compiler produce verbose output that lists 8240 # what "hidden" libraries, object files and flags are used when 8241 # linking a shared library. 8242 # 8243 # There doesn't appear to be a way to prevent this compiler from 8244 # explicitly linking system object files so we need to strip them 8245 # from the output so that they don't get included in the library 8246 # dependencies. 8247 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"' 8248 ;; 8249 *) 8250 if test "$GXX" = yes; then 8251 if test $with_gnu_ld = no; then 8252 case $host_cpu in 8253 hppa*64*) 8254 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 8255 ;; 8256 ia64*) 8257 _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' 8258 ;; 8259 *) 8260 _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' 8261 ;; 8262 esac 8263 fi 8264 else 8265 # FIXME: insert proper C++ library support 8266 _LT_TAGVAR(ld_shlibs, $1)=no 8267 fi 8268 ;; 8269 esac 8270 ;; 8271 8272 interix[[3-9]]*) 8273 _LT_TAGVAR(hardcode_direct, $1)=no 8274 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 8275 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 8276 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 8277 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. 8278 # Instead, shared libraries are loaded at an image base (0x10000000 by 8279 # default) and relocated if they conflict, which is a slow very memory 8280 # consuming and fragmenting process. To avoid this, we pick a random, 8281 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link 8282 # time. Moving up from 0x10000000 also allows more sbrk(2) space. 8283 _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' 8284 _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' 8285 ;; 8286 irix5* | irix6*) 8287 case $cc_basename in 8288 CC*) 8289 # SGI C++ 8290 _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' 8291 8292 # Archives containing C++ object files must be created using 8293 # "CC -ar", where "CC" is the IRIX C++ compiler. This is 8294 # necessary to make sure instantiated templates are included 8295 # in the archive. 8296 _LT_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs' 8297 ;; 8298 *) 8299 if test "$GXX" = yes; then 8300 if test "$with_gnu_ld" = no; then 8301 _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' 8302 else 8303 _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' 8304 fi 8305 fi 8306 _LT_TAGVAR(link_all_deplibs, $1)=yes 8307 ;; 8308 esac 8309 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 8310 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 8311 _LT_TAGVAR(inherit_rpath, $1)=yes 8312 ;; 8313 8314 linux* | k*bsd*-gnu | kopensolaris*-gnu) 8315 case $cc_basename in 8316 KCC*) 8317 # Kuck and Associates, Inc. (KAI) C++ Compiler 8318 8319 # KCC will only create a shared library if the output file 8320 # ends with ".so" (or ".sl" for HP-UX), so rename the library 8321 # to its proper name (with version) after linking. 8322 _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' 8323 _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' 8324 # Commands to make compiler produce verbose output that lists 8325 # what "hidden" libraries, object files and flags are used when 8326 # linking a shared library. 8327 # 8328 # There doesn't appear to be a way to prevent this compiler from 8329 # explicitly linking system object files so we need to strip them 8330 # from the output so that they don't get included in the library 8331 # dependencies. 8332 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"' 8333 8334 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 8335 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 8336 8337 # Archives containing C++ object files must be created using 8338 # "CC -Bstatic", where "CC" is the KAI C++ compiler. 8339 _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' 8340 ;; 8341 icpc* | ecpc* ) 8342 # Intel C++ 8343 with_gnu_ld=yes 8344 # version 8.0 and above of icpc choke on multiply defined symbols 8345 # if we add $predep_objects and $postdep_objects, however 7.1 and 8346 # earlier do not add the objects themselves. 8347 case `$CC -V 2>&1` in 8348 *"Version 7."*) 8349 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' 8350 _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' 8351 ;; 8352 *) # Version 8.0 or newer 8353 tmp_idyn= 8354 case $host_cpu in 8355 ia64*) tmp_idyn=' -i_dynamic';; 8356 esac 8357 _LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 8358 _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' 8359 ;; 8360 esac 8361 _LT_TAGVAR(archive_cmds_need_lc, $1)=no 8362 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 8363 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 8364 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' 8365 ;; 8366 pgCC* | pgcpp*) 8367 # Portland Group C++ compiler 8368 case `$CC -V` in 8369 *pgCC\ [[1-5]].* | *pgcpp\ [[1-5]].*) 8370 _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~ 8371 rm -rf $tpldir~ 8372 $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~ 8373 compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"' 8374 _LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~ 8375 rm -rf $tpldir~ 8376 $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~ 8377 $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~ 8378 $RANLIB $oldlib' 8379 _LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~ 8380 rm -rf $tpldir~ 8381 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ 8382 $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' 8383 _LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~ 8384 rm -rf $tpldir~ 8385 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ 8386 $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' 8387 ;; 8388 *) # Version 6 and above use weak symbols 8389 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' 8390 _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' 8391 ;; 8392 esac 8393 8394 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir' 8395 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 8396 _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' 8397 ;; 8398 cxx*) 8399 # Compaq C++ 8400 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' 8401 _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' 8402 8403 runpath_var=LD_RUN_PATH 8404 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' 8405 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 8406 8407 # Commands to make compiler produce verbose output that lists 8408 # what "hidden" libraries, object files and flags are used when 8409 # linking a shared library. 8410 # 8411 # There doesn't appear to be a way to prevent this compiler from 8412 # explicitly linking system object files so we need to strip them 8413 # from the output so that they don't get included in the library 8414 # dependencies. 8415 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' 8416 ;; 8417 xl* | mpixl* | bgxl*) 8418 # IBM XL 8.0 on PPC, with GNU ld 8419 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 8420 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 8421 _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 8422 if test "x$supports_anon_versioning" = xyes; then 8423 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ 8424 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ 8425 echo "local: *; };" >> $output_objdir/$libname.ver~ 8426 $CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' 8427 fi 8428 ;; 8429 *) 8430 case `$CC -V 2>&1 | sed 5q` in 8431 *Sun\ C*) 8432 # Sun C++ 5.9 8433 _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' 8434 _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 8435 _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' 8436 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 8437 _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' 8438 _LT_TAGVAR(compiler_needs_object, $1)=yes 8439 8440 # Not sure whether something based on 8441 # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 8442 # would be better. 8443 output_verbose_link_cmd='func_echo_all' 8444 8445 # Archives containing C++ object files must be created using 8446 # "CC -xar", where "CC" is the Sun C++ compiler. This is 8447 # necessary to make sure instantiated templates are included 8448 # in the archive. 8449 _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' 8450 ;; 8451 esac 8452 ;; 8453 esac 8454 ;; 8455 8456 lynxos*) 8457 # FIXME: insert proper C++ library support 8458 _LT_TAGVAR(ld_shlibs, $1)=no 8459 ;; 8460 8461 m88k*) 8462 # FIXME: insert proper C++ library support 8463 _LT_TAGVAR(ld_shlibs, $1)=no 8464 ;; 8465 8466 mvs*) 8467 case $cc_basename in 8468 cxx*) 8469 # FIXME: insert proper C++ library support 8470 _LT_TAGVAR(ld_shlibs, $1)=no 8471 ;; 8472 *) 8473 # FIXME: insert proper C++ library support 8474 _LT_TAGVAR(ld_shlibs, $1)=no 8475 ;; 8476 esac 8477 ;; 8478 8479 netbsd*) 8480 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then 8481 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' 8482 wlarc= 8483 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 8484 _LT_TAGVAR(hardcode_direct, $1)=yes 8485 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 8486 fi 8487 # Workaround some broken pre-1.5 toolchains 8488 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' 8489 ;; 8490 8491 *nto* | *qnx*) 8492 _LT_TAGVAR(ld_shlibs, $1)=yes 8493 ;; 8494 8495 openbsd2*) 8496 # C++ shared libraries are fairly broken 8497 _LT_TAGVAR(ld_shlibs, $1)=no 8498 ;; 8499 8500 openbsd*) 8501 if test -f /usr/libexec/ld.so; then 8502 _LT_TAGVAR(hardcode_direct, $1)=yes 8503 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 8504 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 8505 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' 8506 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 8507 if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then 8508 _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' 8509 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 8510 _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' 8511 fi 8512 output_verbose_link_cmd=func_echo_all 8513 else 8514 _LT_TAGVAR(ld_shlibs, $1)=no 8515 fi 8516 ;; 8517 8518 osf3* | osf4* | osf5*) 8519 case $cc_basename in 8520 KCC*) 8521 # Kuck and Associates, Inc. (KAI) C++ Compiler 8522 8523 # KCC will only create a shared library if the output file 8524 # ends with ".so" (or ".sl" for HP-UX), so rename the library 8525 # to its proper name (with version) after linking. 8526 _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' 8527 8528 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 8529 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 8530 8531 # Archives containing C++ object files must be created using 8532 # the KAI C++ compiler. 8533 case $host in 8534 osf3*) _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;; 8535 *) _LT_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' ;; 8536 esac 8537 ;; 8538 RCC*) 8539 # Rational C++ 2.4.1 8540 # FIXME: insert proper C++ library support 8541 _LT_TAGVAR(ld_shlibs, $1)=no 8542 ;; 8543 cxx*) 8544 case $host in 8545 osf3*) 8546 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' 8547 _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' 8548 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 8549 ;; 8550 *) 8551 _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' 8552 _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' 8553 _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ 8554 echo "-hidden">> $lib.exp~ 8555 $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~ 8556 $RM $lib.exp' 8557 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' 8558 ;; 8559 esac 8560 8561 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 8562 8563 # Commands to make compiler produce verbose output that lists 8564 # what "hidden" libraries, object files and flags are used when 8565 # linking a shared library. 8566 # 8567 # There doesn't appear to be a way to prevent this compiler from 8568 # explicitly linking system object files so we need to strip them 8569 # from the output so that they don't get included in the library 8570 # dependencies. 8571 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"' 8572 ;; 8573 *) 8574 if test "$GXX" = yes && test "$with_gnu_ld" = no; then 8575 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' 8576 case $host in 8577 osf3*) 8578 _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' 8579 ;; 8580 *) 8581 _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' 8582 ;; 8583 esac 8584 8585 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 8586 _LT_TAGVAR(hardcode_libdir_separator, $1)=: 8587 8588 # Commands to make compiler produce verbose output that lists 8589 # what "hidden" libraries, object files and flags are used when 8590 # linking a shared library. 8591 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' 8592 8593 else 8594 # FIXME: insert proper C++ library support 8595 _LT_TAGVAR(ld_shlibs, $1)=no 8596 fi 8597 ;; 8598 esac 8599 ;; 8600 8601 psos*) 8602 # FIXME: insert proper C++ library support 8603 _LT_TAGVAR(ld_shlibs, $1)=no 8604 ;; 8605 8606 sunos4*) 8607 case $cc_basename in 8608 CC*) 8609 # Sun C++ 4.x 8610 # FIXME: insert proper C++ library support 8611 _LT_TAGVAR(ld_shlibs, $1)=no 8612 ;; 8613 lcc*) 8614 # Lucid 8615 # FIXME: insert proper C++ library support 8616 _LT_TAGVAR(ld_shlibs, $1)=no 8617 ;; 8618 *) 8619 # FIXME: insert proper C++ library support 8620 _LT_TAGVAR(ld_shlibs, $1)=no 8621 ;; 8622 esac 8623 ;; 8624 8625 solaris*) 8626 case $cc_basename in 8627 CC* | sunCC*) 8628 # Sun C++ 4.2, 5.x and Centerline C++ 8629 _LT_TAGVAR(archive_cmds_need_lc,$1)=yes 8630 _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' 8631 _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 8632 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 8633 $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' 8634 8635 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 8636 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 8637 case $host_os in 8638 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; 8639 *) 8640 # The compiler driver will combine and reorder linker options, 8641 # but understands `-z linker_flag'. 8642 # Supported since Solaris 2.6 (maybe 2.5.1?) 8643 _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' 8644 ;; 8645 esac 8646 _LT_TAGVAR(link_all_deplibs, $1)=yes 8647 8648 output_verbose_link_cmd='func_echo_all' 8649 8650 # Archives containing C++ object files must be created using 8651 # "CC -xar", where "CC" is the Sun C++ compiler. This is 8652 # necessary to make sure instantiated templates are included 8653 # in the archive. 8654 _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' 8655 ;; 8656 gcx*) 8657 # Green Hills C++ Compiler 8658 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' 8659 8660 # The C++ compiler must be used to create the archive. 8661 _LT_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs' 8662 ;; 8663 *) 8664 # GNU C++ compiler with Solaris linker 8665 if test "$GXX" = yes && test "$with_gnu_ld" = no; then 8666 _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs' 8667 if $CC --version | $GREP -v '^2\.7' > /dev/null; then 8668 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' 8669 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 8670 $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' 8671 8672 # Commands to make compiler produce verbose output that lists 8673 # what "hidden" libraries, object files and flags are used when 8674 # linking a shared library. 8675 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' 8676 else 8677 # g++ 2.7 appears to require `-G' NOT `-shared' on this 8678 # platform. 8679 _LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' 8680 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 8681 $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' 8682 8683 # Commands to make compiler produce verbose output that lists 8684 # what "hidden" libraries, object files and flags are used when 8685 # linking a shared library. 8686 output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' 8687 fi 8688 8689 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir' 8690 case $host_os in 8691 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; 8692 *) 8693 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' 8694 ;; 8695 esac 8696 fi 8697 ;; 8698 esac 8699 ;; 8700 8701 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) 8702 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' 8703 _LT_TAGVAR(archive_cmds_need_lc, $1)=no 8704 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 8705 runpath_var='LD_RUN_PATH' 8706 8707 case $cc_basename in 8708 CC*) 8709 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 8710 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 8711 ;; 8712 *) 8713 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 8714 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 8715 ;; 8716 esac 8717 ;; 8718 8719 sysv5* | sco3.2v5* | sco5v6*) 8720 # Note: We can NOT use -z defs as we might desire, because we do not 8721 # link with -lc, and that would cause any symbols used from libc to 8722 # always be unresolved, which means just about no library would 8723 # ever link correctly. If we're not using GNU ld we use -z text 8724 # though, which does catch some bad symbols but isn't as heavy-handed 8725 # as -z defs. 8726 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' 8727 _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs' 8728 _LT_TAGVAR(archive_cmds_need_lc, $1)=no 8729 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 8730 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir' 8731 _LT_TAGVAR(hardcode_libdir_separator, $1)=':' 8732 _LT_TAGVAR(link_all_deplibs, $1)=yes 8733 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' 8734 runpath_var='LD_RUN_PATH' 8735 8736 case $cc_basename in 8737 CC*) 8738 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 8739 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 8740 _LT_TAGVAR(old_archive_cmds, $1)='$CC -Tprelink_objects $oldobjs~ 8741 '"$_LT_TAGVAR(old_archive_cmds, $1)" 8742 _LT_TAGVAR(reload_cmds, $1)='$CC -Tprelink_objects $reload_objs~ 8743 '"$_LT_TAGVAR(reload_cmds, $1)" 8744 ;; 8745 *) 8746 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 8747 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 8748 ;; 8749 esac 8750 ;; 8751 8752 tandem*) 8753 case $cc_basename in 8754 NCC*) 8755 # NonStop-UX NCC 3.20 8756 # FIXME: insert proper C++ library support 8757 _LT_TAGVAR(ld_shlibs, $1)=no 8758 ;; 8759 *) 8760 # FIXME: insert proper C++ library support 8761 _LT_TAGVAR(ld_shlibs, $1)=no 8762 ;; 8763 esac 8764 ;; 8765 8766 vxworks*) 8767 # FIXME: insert proper C++ library support 8768 _LT_TAGVAR(ld_shlibs, $1)=no 8769 ;; 8770 8771 *) 8772 # FIXME: insert proper C++ library support 8773 _LT_TAGVAR(ld_shlibs, $1)=no 8774 ;; 8775 esac 8776 8777 AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) 8778 test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no 8779 8780 _LT_TAGVAR(GCC, $1)="$GXX" 8781 _LT_TAGVAR(LD, $1)="$LD" 8782 8783 ## CAVEAT EMPTOR: 8784 ## There is no encapsulation within the following macros, do not change 8785 ## the running order or otherwise move them around unless you know exactly 8786 ## what you are doing... 8787 _LT_SYS_HIDDEN_LIBDEPS($1) 8788 _LT_COMPILER_PIC($1) 8789 _LT_COMPILER_C_O($1) 8790 _LT_COMPILER_FILE_LOCKS($1) 8791 _LT_LINKER_SHLIBS($1) 8792 _LT_SYS_DYNAMIC_LINKER($1) 8793 _LT_LINKER_HARDCODE_LIBPATH($1) 8794 8795 _LT_CONFIG($1) 8796 fi # test -n "$compiler" 8797 8798 CC=$lt_save_CC 8799 LDCXX=$LD 8800 LD=$lt_save_LD 8801 GCC=$lt_save_GCC 8802 with_gnu_ld=$lt_save_with_gnu_ld 8803 lt_cv_path_LDCXX=$lt_cv_path_LD 8804 lt_cv_path_LD=$lt_save_path_LD 8805 lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld 8806 lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld 8807fi # test "$_lt_caught_CXX_error" != yes 8808 8809AC_LANG_POP 8810])# _LT_LANG_CXX_CONFIG 8811 8812 8813# _LT_SYS_HIDDEN_LIBDEPS([TAGNAME]) 8814# --------------------------------- 8815# Figure out "hidden" library dependencies from verbose 8816# compiler output when linking a shared library. 8817# Parse the compiler output and extract the necessary 8818# objects, libraries and library flags. 8819m4_defun([_LT_SYS_HIDDEN_LIBDEPS], 8820[m4_require([_LT_FILEUTILS_DEFAULTS])dnl 8821# Dependencies to place before and after the object being linked: 8822_LT_TAGVAR(predep_objects, $1)= 8823_LT_TAGVAR(postdep_objects, $1)= 8824_LT_TAGVAR(predeps, $1)= 8825_LT_TAGVAR(postdeps, $1)= 8826_LT_TAGVAR(compiler_lib_search_path, $1)= 8827 8828dnl we can't use the lt_simple_compile_test_code here, 8829dnl because it contains code intended for an executable, 8830dnl not a library. It's possible we should let each 8831dnl tag define a new lt_????_link_test_code variable, 8832dnl but it's only used here... 8833m4_if([$1], [], [cat > conftest.$ac_ext <<_LT_EOF 8834int a; 8835void foo (void) { a = 0; } 8836_LT_EOF 8837], [$1], [CXX], [cat > conftest.$ac_ext <<_LT_EOF 8838class Foo 8839{ 8840public: 8841 Foo (void) { a = 0; } 8842private: 8843 int a; 8844}; 8845_LT_EOF 8846], [$1], [F77], [cat > conftest.$ac_ext <<_LT_EOF 8847 subroutine foo 8848 implicit none 8849 integer*4 a 8850 a=0 8851 return 8852 end 8853_LT_EOF 8854], [$1], [FC], [cat > conftest.$ac_ext <<_LT_EOF 8855 subroutine foo 8856 implicit none 8857 integer a 8858 a=0 8859 return 8860 end 8861_LT_EOF 8862], [$1], [GCJ], [cat > conftest.$ac_ext <<_LT_EOF 8863public class foo { 8864 private int a; 8865 public void bar (void) { 8866 a = 0; 8867 } 8868}; 8869_LT_EOF 8870]) 8871dnl Parse the compiler output and extract the necessary 8872dnl objects, libraries and library flags. 8873if AC_TRY_EVAL(ac_compile); then 8874 # Parse the compiler output and extract the necessary 8875 # objects, libraries and library flags. 8876 8877 # Sentinel used to keep track of whether or not we are before 8878 # the conftest object file. 8879 pre_test_object_deps_done=no 8880 8881 for p in `eval "$output_verbose_link_cmd"`; do 8882 case $p in 8883 8884 -L* | -R* | -l*) 8885 # Some compilers place space between "-{L,R}" and the path. 8886 # Remove the space. 8887 if test $p = "-L" || 8888 test $p = "-R"; then 8889 prev=$p 8890 continue 8891 else 8892 prev= 8893 fi 8894 8895 if test "$pre_test_object_deps_done" = no; then 8896 case $p in 8897 -L* | -R*) 8898 # Internal compiler library paths should come after those 8899 # provided the user. The postdeps already come after the 8900 # user supplied libs so there is no need to process them. 8901 if test -z "$_LT_TAGVAR(compiler_lib_search_path, $1)"; then 8902 _LT_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}" 8903 else 8904 _LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}" 8905 fi 8906 ;; 8907 # The "-l" case would never come before the object being 8908 # linked, so don't bother handling this case. 8909 esac 8910 else 8911 if test -z "$_LT_TAGVAR(postdeps, $1)"; then 8912 _LT_TAGVAR(postdeps, $1)="${prev}${p}" 8913 else 8914 _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} ${prev}${p}" 8915 fi 8916 fi 8917 ;; 8918 8919 *.$objext) 8920 # This assumes that the test object file only shows up 8921 # once in the compiler output. 8922 if test "$p" = "conftest.$objext"; then 8923 pre_test_object_deps_done=yes 8924 continue 8925 fi 8926 8927 if test "$pre_test_object_deps_done" = no; then 8928 if test -z "$_LT_TAGVAR(predep_objects, $1)"; then 8929 _LT_TAGVAR(predep_objects, $1)="$p" 8930 else 8931 _LT_TAGVAR(predep_objects, $1)="$_LT_TAGVAR(predep_objects, $1) $p" 8932 fi 8933 else 8934 if test -z "$_LT_TAGVAR(postdep_objects, $1)"; then 8935 _LT_TAGVAR(postdep_objects, $1)="$p" 8936 else 8937 _LT_TAGVAR(postdep_objects, $1)="$_LT_TAGVAR(postdep_objects, $1) $p" 8938 fi 8939 fi 8940 ;; 8941 8942 *) ;; # Ignore the rest. 8943 8944 esac 8945 done 8946 8947 # Clean up. 8948 rm -f a.out a.exe 8949else 8950 echo "libtool.m4: error: problem compiling $1 test program" 8951fi 8952 8953$RM -f confest.$objext 8954 8955# PORTME: override above test on systems where it is broken 8956m4_if([$1], [CXX], 8957[case $host_os in 8958interix[[3-9]]*) 8959 # Interix 3.5 installs completely hosed .la files for C++, so rather than 8960 # hack all around it, let's just trust "g++" to DTRT. 8961 _LT_TAGVAR(predep_objects,$1)= 8962 _LT_TAGVAR(postdep_objects,$1)= 8963 _LT_TAGVAR(postdeps,$1)= 8964 ;; 8965 8966linux*) 8967 case `$CC -V 2>&1 | sed 5q` in 8968 *Sun\ C*) 8969 # Sun C++ 5.9 8970 8971 # The more standards-conforming stlport4 library is 8972 # incompatible with the Cstd library. Avoid specifying 8973 # it if it's in CXXFLAGS. Ignore libCrun as 8974 # -library=stlport4 depends on it. 8975 case " $CXX $CXXFLAGS " in 8976 *" -library=stlport4 "*) 8977 solaris_use_stlport4=yes 8978 ;; 8979 esac 8980 8981 if test "$solaris_use_stlport4" != yes; then 8982 _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun' 8983 fi 8984 ;; 8985 esac 8986 ;; 8987 8988solaris*) 8989 case $cc_basename in 8990 CC* | sunCC*) 8991 # The more standards-conforming stlport4 library is 8992 # incompatible with the Cstd library. Avoid specifying 8993 # it if it's in CXXFLAGS. Ignore libCrun as 8994 # -library=stlport4 depends on it. 8995 case " $CXX $CXXFLAGS " in 8996 *" -library=stlport4 "*) 8997 solaris_use_stlport4=yes 8998 ;; 8999 esac 9000 9001 # Adding this requires a known-good setup of shared libraries for 9002 # Sun compiler versions before 5.6, else PIC objects from an old 9003 # archive will be linked into the output, leading to subtle bugs. 9004 if test "$solaris_use_stlport4" != yes; then 9005 _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun' 9006 fi 9007 ;; 9008 esac 9009 ;; 9010esac 9011]) 9012 9013case " $_LT_TAGVAR(postdeps, $1) " in 9014*" -lc "*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;; 9015esac 9016 _LT_TAGVAR(compiler_lib_search_dirs, $1)= 9017if test -n "${_LT_TAGVAR(compiler_lib_search_path, $1)}"; then 9018 _LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | ${SED} -e 's! -L! !g' -e 's!^ !!'` 9019fi 9020_LT_TAGDECL([], [compiler_lib_search_dirs], [1], 9021 [The directories searched by this compiler when creating a shared library]) 9022_LT_TAGDECL([], [predep_objects], [1], 9023 [Dependencies to place before and after the objects being linked to 9024 create a shared library]) 9025_LT_TAGDECL([], [postdep_objects], [1]) 9026_LT_TAGDECL([], [predeps], [1]) 9027_LT_TAGDECL([], [postdeps], [1]) 9028_LT_TAGDECL([], [compiler_lib_search_path], [1], 9029 [The library search path used internally by the compiler when linking 9030 a shared library]) 9031])# _LT_SYS_HIDDEN_LIBDEPS 9032 9033 9034# _LT_LANG_F77_CONFIG([TAG]) 9035# -------------------------- 9036# Ensure that the configuration variables for a Fortran 77 compiler are 9037# suitably defined. These variables are subsequently used by _LT_CONFIG 9038# to write the compiler configuration to `libtool'. 9039m4_defun([_LT_LANG_F77_CONFIG], 9040[AC_LANG_PUSH(Fortran 77) 9041if test -z "$F77" || test "X$F77" = "Xno"; then 9042 _lt_disable_F77=yes 9043fi 9044 9045_LT_TAGVAR(archive_cmds_need_lc, $1)=no 9046_LT_TAGVAR(allow_undefined_flag, $1)= 9047_LT_TAGVAR(always_export_symbols, $1)=no 9048_LT_TAGVAR(archive_expsym_cmds, $1)= 9049_LT_TAGVAR(export_dynamic_flag_spec, $1)= 9050_LT_TAGVAR(hardcode_direct, $1)=no 9051_LT_TAGVAR(hardcode_direct_absolute, $1)=no 9052_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 9053_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= 9054_LT_TAGVAR(hardcode_libdir_separator, $1)= 9055_LT_TAGVAR(hardcode_minus_L, $1)=no 9056_LT_TAGVAR(hardcode_automatic, $1)=no 9057_LT_TAGVAR(inherit_rpath, $1)=no 9058_LT_TAGVAR(module_cmds, $1)= 9059_LT_TAGVAR(module_expsym_cmds, $1)= 9060_LT_TAGVAR(link_all_deplibs, $1)=unknown 9061_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 9062_LT_TAGVAR(reload_flag, $1)=$reload_flag 9063_LT_TAGVAR(reload_cmds, $1)=$reload_cmds 9064_LT_TAGVAR(no_undefined_flag, $1)= 9065_LT_TAGVAR(whole_archive_flag_spec, $1)= 9066_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no 9067 9068# Source file extension for f77 test sources. 9069ac_ext=f 9070 9071# Object file extension for compiled f77 test sources. 9072objext=o 9073_LT_TAGVAR(objext, $1)=$objext 9074 9075# No sense in running all these tests if we already determined that 9076# the F77 compiler isn't working. Some variables (like enable_shared) 9077# are currently assumed to apply to all compilers on this platform, 9078# and will be corrupted by setting them based on a non-working compiler. 9079if test "$_lt_disable_F77" != yes; then 9080 # Code to be used in simple compile tests 9081 lt_simple_compile_test_code="\ 9082 subroutine t 9083 return 9084 end 9085" 9086 9087 # Code to be used in simple link tests 9088 lt_simple_link_test_code="\ 9089 program t 9090 end 9091" 9092 9093 # ltmain only uses $CC for tagged configurations so make sure $CC is set. 9094 _LT_TAG_COMPILER 9095 9096 # save warnings/boilerplate of simple test code 9097 _LT_COMPILER_BOILERPLATE 9098 _LT_LINKER_BOILERPLATE 9099 9100 # Allow CC to be a program name with arguments. 9101 lt_save_CC="$CC" 9102 lt_save_GCC=$GCC 9103 CC=${F77-"f77"} 9104 compiler=$CC 9105 _LT_TAGVAR(compiler, $1)=$CC 9106 _LT_CC_BASENAME([$compiler]) 9107 GCC=$G77 9108 if test -n "$compiler"; then 9109 AC_MSG_CHECKING([if libtool supports shared libraries]) 9110 AC_MSG_RESULT([$can_build_shared]) 9111 9112 AC_MSG_CHECKING([whether to build shared libraries]) 9113 test "$can_build_shared" = "no" && enable_shared=no 9114 9115 # On AIX, shared libraries and static libraries use the same namespace, and 9116 # are all built from PIC. 9117 case $host_os in 9118 aix3*) 9119 test "$enable_shared" = yes && enable_static=no 9120 if test -n "$RANLIB"; then 9121 archive_cmds="$archive_cmds~\$RANLIB \$lib" 9122 postinstall_cmds='$RANLIB $lib' 9123 fi 9124 ;; 9125 aix[[4-9]]*) 9126 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then 9127 test "$enable_shared" = yes && enable_static=no 9128 fi 9129 ;; 9130 esac 9131 AC_MSG_RESULT([$enable_shared]) 9132 9133 AC_MSG_CHECKING([whether to build static libraries]) 9134 # Make sure either enable_shared or enable_static is yes. 9135 test "$enable_shared" = yes || enable_static=yes 9136 AC_MSG_RESULT([$enable_static]) 9137 9138 _LT_TAGVAR(GCC, $1)="$G77" 9139 _LT_TAGVAR(LD, $1)="$LD" 9140 9141 ## CAVEAT EMPTOR: 9142 ## There is no encapsulation within the following macros, do not change 9143 ## the running order or otherwise move them around unless you know exactly 9144 ## what you are doing... 9145 _LT_COMPILER_PIC($1) 9146 _LT_COMPILER_C_O($1) 9147 _LT_COMPILER_FILE_LOCKS($1) 9148 _LT_LINKER_SHLIBS($1) 9149 _LT_SYS_DYNAMIC_LINKER($1) 9150 _LT_LINKER_HARDCODE_LIBPATH($1) 9151 9152 _LT_CONFIG($1) 9153 fi # test -n "$compiler" 9154 9155 GCC=$lt_save_GCC 9156 CC="$lt_save_CC" 9157fi # test "$_lt_disable_F77" != yes 9158 9159AC_LANG_POP 9160])# _LT_LANG_F77_CONFIG 9161 9162 9163# _LT_LANG_FC_CONFIG([TAG]) 9164# ------------------------- 9165# Ensure that the configuration variables for a Fortran compiler are 9166# suitably defined. These variables are subsequently used by _LT_CONFIG 9167# to write the compiler configuration to `libtool'. 9168m4_defun([_LT_LANG_FC_CONFIG], 9169[AC_LANG_PUSH(Fortran) 9170 9171if test -z "$FC" || test "X$FC" = "Xno"; then 9172 _lt_disable_FC=yes 9173fi 9174 9175_LT_TAGVAR(archive_cmds_need_lc, $1)=no 9176_LT_TAGVAR(allow_undefined_flag, $1)= 9177_LT_TAGVAR(always_export_symbols, $1)=no 9178_LT_TAGVAR(archive_expsym_cmds, $1)= 9179_LT_TAGVAR(export_dynamic_flag_spec, $1)= 9180_LT_TAGVAR(hardcode_direct, $1)=no 9181_LT_TAGVAR(hardcode_direct_absolute, $1)=no 9182_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 9183_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= 9184_LT_TAGVAR(hardcode_libdir_separator, $1)= 9185_LT_TAGVAR(hardcode_minus_L, $1)=no 9186_LT_TAGVAR(hardcode_automatic, $1)=no 9187_LT_TAGVAR(inherit_rpath, $1)=no 9188_LT_TAGVAR(module_cmds, $1)= 9189_LT_TAGVAR(module_expsym_cmds, $1)= 9190_LT_TAGVAR(link_all_deplibs, $1)=unknown 9191_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 9192_LT_TAGVAR(reload_flag, $1)=$reload_flag 9193_LT_TAGVAR(reload_cmds, $1)=$reload_cmds 9194_LT_TAGVAR(no_undefined_flag, $1)= 9195_LT_TAGVAR(whole_archive_flag_spec, $1)= 9196_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no 9197 9198# Source file extension for fc test sources. 9199ac_ext=${ac_fc_srcext-f} 9200 9201# Object file extension for compiled fc test sources. 9202objext=o 9203_LT_TAGVAR(objext, $1)=$objext 9204 9205# No sense in running all these tests if we already determined that 9206# the FC compiler isn't working. Some variables (like enable_shared) 9207# are currently assumed to apply to all compilers on this platform, 9208# and will be corrupted by setting them based on a non-working compiler. 9209if test "$_lt_disable_FC" != yes; then 9210 # Code to be used in simple compile tests 9211 lt_simple_compile_test_code="\ 9212 subroutine t 9213 return 9214 end 9215" 9216 9217 # Code to be used in simple link tests 9218 lt_simple_link_test_code="\ 9219 program t 9220 end 9221" 9222 9223 # ltmain only uses $CC for tagged configurations so make sure $CC is set. 9224 _LT_TAG_COMPILER 9225 9226 # save warnings/boilerplate of simple test code 9227 _LT_COMPILER_BOILERPLATE 9228 _LT_LINKER_BOILERPLATE 9229 9230 # Allow CC to be a program name with arguments. 9231 lt_save_CC="$CC" 9232 lt_save_GCC=$GCC 9233 CC=${FC-"f95"} 9234 compiler=$CC 9235 GCC=$ac_cv_fc_compiler_gnu 9236 9237 _LT_TAGVAR(compiler, $1)=$CC 9238 _LT_CC_BASENAME([$compiler]) 9239 9240 if test -n "$compiler"; then 9241 AC_MSG_CHECKING([if libtool supports shared libraries]) 9242 AC_MSG_RESULT([$can_build_shared]) 9243 9244 AC_MSG_CHECKING([whether to build shared libraries]) 9245 test "$can_build_shared" = "no" && enable_shared=no 9246 9247 # On AIX, shared libraries and static libraries use the same namespace, and 9248 # are all built from PIC. 9249 case $host_os in 9250 aix3*) 9251 test "$enable_shared" = yes && enable_static=no 9252 if test -n "$RANLIB"; then 9253 archive_cmds="$archive_cmds~\$RANLIB \$lib" 9254 postinstall_cmds='$RANLIB $lib' 9255 fi 9256 ;; 9257 aix[[4-9]]*) 9258 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then 9259 test "$enable_shared" = yes && enable_static=no 9260 fi 9261 ;; 9262 esac 9263 AC_MSG_RESULT([$enable_shared]) 9264 9265 AC_MSG_CHECKING([whether to build static libraries]) 9266 # Make sure either enable_shared or enable_static is yes. 9267 test "$enable_shared" = yes || enable_static=yes 9268 AC_MSG_RESULT([$enable_static]) 9269 9270 _LT_TAGVAR(GCC, $1)="$ac_cv_fc_compiler_gnu" 9271 _LT_TAGVAR(LD, $1)="$LD" 9272 9273 ## CAVEAT EMPTOR: 9274 ## There is no encapsulation within the following macros, do not change 9275 ## the running order or otherwise move them around unless you know exactly 9276 ## what you are doing... 9277 _LT_SYS_HIDDEN_LIBDEPS($1) 9278 _LT_COMPILER_PIC($1) 9279 _LT_COMPILER_C_O($1) 9280 _LT_COMPILER_FILE_LOCKS($1) 9281 _LT_LINKER_SHLIBS($1) 9282 _LT_SYS_DYNAMIC_LINKER($1) 9283 _LT_LINKER_HARDCODE_LIBPATH($1) 9284 9285 _LT_CONFIG($1) 9286 fi # test -n "$compiler" 9287 9288 GCC=$lt_save_GCC 9289 CC="$lt_save_CC" 9290fi # test "$_lt_disable_FC" != yes 9291 9292AC_LANG_POP 9293])# _LT_LANG_FC_CONFIG 9294 9295 9296# _LT_LANG_GCJ_CONFIG([TAG]) 9297# -------------------------- 9298# Ensure that the configuration variables for the GNU Java Compiler compiler 9299# are suitably defined. These variables are subsequently used by _LT_CONFIG 9300# to write the compiler configuration to `libtool'. 9301m4_defun([_LT_LANG_GCJ_CONFIG], 9302[AC_REQUIRE([LT_PROG_GCJ])dnl 9303AC_LANG_SAVE 9304 9305# Source file extension for Java test sources. 9306ac_ext=java 9307 9308# Object file extension for compiled Java test sources. 9309objext=o 9310_LT_TAGVAR(objext, $1)=$objext 9311 9312# Code to be used in simple compile tests 9313lt_simple_compile_test_code="class foo {}" 9314 9315# Code to be used in simple link tests 9316lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }' 9317 9318# ltmain only uses $CC for tagged configurations so make sure $CC is set. 9319_LT_TAG_COMPILER 9320 9321# save warnings/boilerplate of simple test code 9322_LT_COMPILER_BOILERPLATE 9323_LT_LINKER_BOILERPLATE 9324 9325# Allow CC to be a program name with arguments. 9326lt_save_CC="$CC" 9327lt_save_GCC=$GCC 9328GCC=yes 9329CC=${GCJ-"gcj"} 9330compiler=$CC 9331_LT_TAGVAR(compiler, $1)=$CC 9332_LT_TAGVAR(LD, $1)="$LD" 9333_LT_CC_BASENAME([$compiler]) 9334 9335# GCJ did not exist at the time GCC didn't implicitly link libc in. 9336_LT_TAGVAR(archive_cmds_need_lc, $1)=no 9337 9338_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 9339_LT_TAGVAR(reload_flag, $1)=$reload_flag 9340_LT_TAGVAR(reload_cmds, $1)=$reload_cmds 9341 9342if test -n "$compiler"; then 9343 _LT_COMPILER_NO_RTTI($1) 9344 _LT_COMPILER_PIC($1) 9345 _LT_COMPILER_C_O($1) 9346 _LT_COMPILER_FILE_LOCKS($1) 9347 _LT_LINKER_SHLIBS($1) 9348 _LT_LINKER_HARDCODE_LIBPATH($1) 9349 9350 _LT_CONFIG($1) 9351fi 9352 9353AC_LANG_RESTORE 9354 9355GCC=$lt_save_GCC 9356CC="$lt_save_CC" 9357])# _LT_LANG_GCJ_CONFIG 9358 9359 9360# _LT_LANG_RC_CONFIG([TAG]) 9361# ------------------------- 9362# Ensure that the configuration variables for the Windows resource compiler 9363# are suitably defined. These variables are subsequently used by _LT_CONFIG 9364# to write the compiler configuration to `libtool'. 9365m4_defun([_LT_LANG_RC_CONFIG], 9366[AC_REQUIRE([LT_PROG_RC])dnl 9367AC_LANG_SAVE 9368 9369# Source file extension for RC test sources. 9370ac_ext=rc 9371 9372# Object file extension for compiled RC test sources. 9373objext=o 9374_LT_TAGVAR(objext, $1)=$objext 9375 9376# Code to be used in simple compile tests 9377lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }' 9378 9379# Code to be used in simple link tests 9380lt_simple_link_test_code="$lt_simple_compile_test_code" 9381 9382# ltmain only uses $CC for tagged configurations so make sure $CC is set. 9383_LT_TAG_COMPILER 9384 9385# save warnings/boilerplate of simple test code 9386_LT_COMPILER_BOILERPLATE 9387_LT_LINKER_BOILERPLATE 9388 9389# Allow CC to be a program name with arguments. 9390lt_save_CC="$CC" 9391lt_save_GCC=$GCC 9392GCC= 9393CC=${RC-"windres"} 9394compiler=$CC 9395_LT_TAGVAR(compiler, $1)=$CC 9396_LT_CC_BASENAME([$compiler]) 9397_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes 9398 9399if test -n "$compiler"; then 9400 : 9401 _LT_CONFIG($1) 9402fi 9403 9404GCC=$lt_save_GCC 9405AC_LANG_RESTORE 9406CC="$lt_save_CC" 9407])# _LT_LANG_RC_CONFIG 9408 9409 9410# LT_PROG_GCJ 9411# ----------- 9412AC_DEFUN([LT_PROG_GCJ], 9413[m4_ifdef([AC_PROG_GCJ], [AC_PROG_GCJ], 9414 [m4_ifdef([A][M_PROG_GCJ], [A][M_PROG_GCJ], 9415 [AC_CHECK_TOOL(GCJ, gcj,) 9416 test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2" 9417 AC_SUBST(GCJFLAGS)])])[]dnl 9418]) 9419 9420# Old name: 9421AU_ALIAS([LT_AC_PROG_GCJ], [LT_PROG_GCJ]) 9422dnl aclocal-1.4 backwards compatibility: 9423dnl AC_DEFUN([LT_AC_PROG_GCJ], []) 9424 9425 9426# LT_PROG_RC 9427# ---------- 9428AC_DEFUN([LT_PROG_RC], 9429[AC_CHECK_TOOL(RC, windres,) 9430]) 9431 9432# Old name: 9433AU_ALIAS([LT_AC_PROG_RC], [LT_PROG_RC]) 9434dnl aclocal-1.4 backwards compatibility: 9435dnl AC_DEFUN([LT_AC_PROG_RC], []) 9436 9437 9438# _LT_DECL_EGREP 9439# -------------- 9440# If we don't have a new enough Autoconf to choose the best grep 9441# available, choose the one first in the user's PATH. 9442m4_defun([_LT_DECL_EGREP], 9443[AC_REQUIRE([AC_PROG_EGREP])dnl 9444AC_REQUIRE([AC_PROG_FGREP])dnl 9445test -z "$GREP" && GREP=grep 9446_LT_DECL([], [GREP], [1], [A grep program that handles long lines]) 9447_LT_DECL([], [EGREP], [1], [An ERE matcher]) 9448_LT_DECL([], [FGREP], [1], [A literal string matcher]) 9449dnl Non-bleeding-edge autoconf doesn't subst GREP, so do it here too 9450AC_SUBST([GREP]) 9451]) 9452 9453 9454# _LT_DECL_OBJDUMP 9455# -------------- 9456# If we don't have a new enough Autoconf to choose the best objdump 9457# available, choose the one first in the user's PATH. 9458m4_defun([_LT_DECL_OBJDUMP], 9459[AC_CHECK_TOOL(OBJDUMP, objdump, false) 9460test -z "$OBJDUMP" && OBJDUMP=objdump 9461_LT_DECL([], [OBJDUMP], [1], [An object symbol dumper]) 9462AC_SUBST([OBJDUMP]) 9463]) 9464 9465 9466# _LT_DECL_SED 9467# ------------ 9468# Check for a fully-functional sed program, that truncates 9469# as few characters as possible. Prefer GNU sed if found. 9470m4_defun([_LT_DECL_SED], 9471[AC_PROG_SED 9472test -z "$SED" && SED=sed 9473Xsed="$SED -e 1s/^X//" 9474_LT_DECL([], [SED], [1], [A sed program that does not truncate output]) 9475_LT_DECL([], [Xsed], ["\$SED -e 1s/^X//"], 9476 [Sed that helps us avoid accidentally triggering echo(1) options like -n]) 9477])# _LT_DECL_SED 9478 9479m4_ifndef([AC_PROG_SED], [ 9480# NOTE: This macro has been submitted for inclusion into # 9481# GNU Autoconf as AC_PROG_SED. When it is available in # 9482# a released version of Autoconf we should remove this # 9483# macro and use it instead. # 9484 9485m4_defun([AC_PROG_SED], 9486[AC_MSG_CHECKING([for a sed that does not truncate output]) 9487AC_CACHE_VAL(lt_cv_path_SED, 9488[# Loop through the user's path and test for sed and gsed. 9489# Then use that list of sed's as ones to test for truncation. 9490as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9491for as_dir in $PATH 9492do 9493 IFS=$as_save_IFS 9494 test -z "$as_dir" && as_dir=. 9495 for lt_ac_prog in sed gsed; do 9496 for ac_exec_ext in '' $ac_executable_extensions; do 9497 if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then 9498 lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext" 9499 fi 9500 done 9501 done 9502done 9503IFS=$as_save_IFS 9504lt_ac_max=0 9505lt_ac_count=0 9506# Add /usr/xpg4/bin/sed as it is typically found on Solaris 9507# along with /bin/sed that truncates output. 9508for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do 9509 test ! -f $lt_ac_sed && continue 9510 cat /dev/null > conftest.in 9511 lt_ac_count=0 9512 echo $ECHO_N "0123456789$ECHO_C" >conftest.in 9513 # Check for GNU sed and select it if it is found. 9514 if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then 9515 lt_cv_path_SED=$lt_ac_sed 9516 break 9517 fi 9518 while true; do 9519 cat conftest.in conftest.in >conftest.tmp 9520 mv conftest.tmp conftest.in 9521 cp conftest.in conftest.nl 9522 echo >>conftest.nl 9523 $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break 9524 cmp -s conftest.out conftest.nl || break 9525 # 10000 chars as input seems more than enough 9526 test $lt_ac_count -gt 10 && break 9527 lt_ac_count=`expr $lt_ac_count + 1` 9528 if test $lt_ac_count -gt $lt_ac_max; then 9529 lt_ac_max=$lt_ac_count 9530 lt_cv_path_SED=$lt_ac_sed 9531 fi 9532 done 9533done 9534]) 9535SED=$lt_cv_path_SED 9536AC_SUBST([SED]) 9537AC_MSG_RESULT([$SED]) 9538])#AC_PROG_SED 9539])#m4_ifndef 9540 9541# Old name: 9542AU_ALIAS([LT_AC_PROG_SED], [AC_PROG_SED]) 9543dnl aclocal-1.4 backwards compatibility: 9544dnl AC_DEFUN([LT_AC_PROG_SED], []) 9545 9546 9547# _LT_CHECK_SHELL_FEATURES 9548# ------------------------ 9549# Find out whether the shell is Bourne or XSI compatible, 9550# or has some other useful features. 9551m4_defun([_LT_CHECK_SHELL_FEATURES], 9552[AC_MSG_CHECKING([whether the shell understands some XSI constructs]) 9553# Try some XSI features 9554xsi_shell=no 9555( _lt_dummy="a/b/c" 9556 test "${_lt_dummy##*/},${_lt_dummy%/*},"${_lt_dummy%"$_lt_dummy"}, \ 9557 = c,a/b,, \ 9558 && eval 'test $(( 1 + 1 )) -eq 2 \ 9559 && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \ 9560 && xsi_shell=yes 9561AC_MSG_RESULT([$xsi_shell]) 9562_LT_CONFIG_LIBTOOL_INIT([xsi_shell='$xsi_shell']) 9563 9564AC_MSG_CHECKING([whether the shell understands "+="]) 9565lt_shell_append=no 9566( foo=bar; set foo baz; eval "$[1]+=\$[2]" && test "$foo" = barbaz ) \ 9567 >/dev/null 2>&1 \ 9568 && lt_shell_append=yes 9569AC_MSG_RESULT([$lt_shell_append]) 9570_LT_CONFIG_LIBTOOL_INIT([lt_shell_append='$lt_shell_append']) 9571 9572if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then 9573 lt_unset=unset 9574else 9575 lt_unset=false 9576fi 9577_LT_DECL([], [lt_unset], [0], [whether the shell understands "unset"])dnl 9578 9579# test EBCDIC or ASCII 9580case `echo X|tr X '\101'` in 9581 A) # ASCII based system 9582 # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr 9583 lt_SP2NL='tr \040 \012' 9584 lt_NL2SP='tr \015\012 \040\040' 9585 ;; 9586 *) # EBCDIC based system 9587 lt_SP2NL='tr \100 \n' 9588 lt_NL2SP='tr \r\n \100\100' 9589 ;; 9590esac 9591_LT_DECL([SP2NL], [lt_SP2NL], [1], [turn spaces into newlines])dnl 9592_LT_DECL([NL2SP], [lt_NL2SP], [1], [turn newlines into spaces])dnl 9593])# _LT_CHECK_SHELL_FEATURES 9594 9595 9596# _LT_PROG_XSI_SHELLFNS 9597# --------------------- 9598# Bourne and XSI compatible variants of some useful shell functions. 9599m4_defun([_LT_PROG_XSI_SHELLFNS], 9600[case $xsi_shell in 9601 yes) 9602 cat << \_LT_EOF >> "$cfgfile" 9603 9604# func_dirname file append nondir_replacement 9605# Compute the dirname of FILE. If nonempty, add APPEND to the result, 9606# otherwise set result to NONDIR_REPLACEMENT. 9607func_dirname () 9608{ 9609 case ${1} in 9610 */*) func_dirname_result="${1%/*}${2}" ;; 9611 * ) func_dirname_result="${3}" ;; 9612 esac 9613} 9614 9615# func_basename file 9616func_basename () 9617{ 9618 func_basename_result="${1##*/}" 9619} 9620 9621# func_dirname_and_basename file append nondir_replacement 9622# perform func_basename and func_dirname in a single function 9623# call: 9624# dirname: Compute the dirname of FILE. If nonempty, 9625# add APPEND to the result, otherwise set result 9626# to NONDIR_REPLACEMENT. 9627# value returned in "$func_dirname_result" 9628# basename: Compute filename of FILE. 9629# value retuned in "$func_basename_result" 9630# Implementation must be kept synchronized with func_dirname 9631# and func_basename. For efficiency, we do not delegate to 9632# those functions but instead duplicate the functionality here. 9633func_dirname_and_basename () 9634{ 9635 case ${1} in 9636 */*) func_dirname_result="${1%/*}${2}" ;; 9637 * ) func_dirname_result="${3}" ;; 9638 esac 9639 func_basename_result="${1##*/}" 9640} 9641 9642# func_stripname prefix suffix name 9643# strip PREFIX and SUFFIX off of NAME. 9644# PREFIX and SUFFIX must not contain globbing or regex special 9645# characters, hashes, percent signs, but SUFFIX may contain a leading 9646# dot (in which case that matches only a dot). 9647func_stripname () 9648{ 9649 # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are 9650 # positional parameters, so assign one to ordinary parameter first. 9651 func_stripname_result=${3} 9652 func_stripname_result=${func_stripname_result#"${1}"} 9653 func_stripname_result=${func_stripname_result%"${2}"} 9654} 9655 9656# func_opt_split 9657func_opt_split () 9658{ 9659 func_opt_split_opt=${1%%=*} 9660 func_opt_split_arg=${1#*=} 9661} 9662 9663# func_lo2o object 9664func_lo2o () 9665{ 9666 case ${1} in 9667 *.lo) func_lo2o_result=${1%.lo}.${objext} ;; 9668 *) func_lo2o_result=${1} ;; 9669 esac 9670} 9671 9672# func_xform libobj-or-source 9673func_xform () 9674{ 9675 func_xform_result=${1%.*}.lo 9676} 9677 9678# func_arith arithmetic-term... 9679func_arith () 9680{ 9681 func_arith_result=$(( $[*] )) 9682} 9683 9684# func_len string 9685# STRING may not start with a hyphen. 9686func_len () 9687{ 9688 func_len_result=${#1} 9689} 9690 9691_LT_EOF 9692 ;; 9693 *) # Bourne compatible functions. 9694 cat << \_LT_EOF >> "$cfgfile" 9695 9696# func_dirname file append nondir_replacement 9697# Compute the dirname of FILE. If nonempty, add APPEND to the result, 9698# otherwise set result to NONDIR_REPLACEMENT. 9699func_dirname () 9700{ 9701 # Extract subdirectory from the argument. 9702 func_dirname_result=`$ECHO "${1}" | $SED "$dirname"` 9703 if test "X$func_dirname_result" = "X${1}"; then 9704 func_dirname_result="${3}" 9705 else 9706 func_dirname_result="$func_dirname_result${2}" 9707 fi 9708} 9709 9710# func_basename file 9711func_basename () 9712{ 9713 func_basename_result=`$ECHO "${1}" | $SED "$basename"` 9714} 9715 9716dnl func_dirname_and_basename 9717dnl A portable version of this function is already defined in general.m4sh 9718dnl so there is no need for it here. 9719 9720# func_stripname prefix suffix name 9721# strip PREFIX and SUFFIX off of NAME. 9722# PREFIX and SUFFIX must not contain globbing or regex special 9723# characters, hashes, percent signs, but SUFFIX may contain a leading 9724# dot (in which case that matches only a dot). 9725# func_strip_suffix prefix name 9726func_stripname () 9727{ 9728 case ${2} in 9729 .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;; 9730 *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;; 9731 esac 9732} 9733 9734# sed scripts: 9735my_sed_long_opt='1s/^\(-[[^=]]*\)=.*/\1/;q' 9736my_sed_long_arg='1s/^-[[^=]]*=//' 9737 9738# func_opt_split 9739func_opt_split () 9740{ 9741 func_opt_split_opt=`$ECHO "${1}" | $SED "$my_sed_long_opt"` 9742 func_opt_split_arg=`$ECHO "${1}" | $SED "$my_sed_long_arg"` 9743} 9744 9745# func_lo2o object 9746func_lo2o () 9747{ 9748 func_lo2o_result=`$ECHO "${1}" | $SED "$lo2o"` 9749} 9750 9751# func_xform libobj-or-source 9752func_xform () 9753{ 9754 func_xform_result=`$ECHO "${1}" | $SED 's/\.[[^.]]*$/.lo/'` 9755} 9756 9757# func_arith arithmetic-term... 9758func_arith () 9759{ 9760 func_arith_result=`expr "$[@]"` 9761} 9762 9763# func_len string 9764# STRING may not start with a hyphen. 9765func_len () 9766{ 9767 func_len_result=`expr "$[1]" : ".*" 2>/dev/null || echo $max_cmd_len` 9768} 9769 9770_LT_EOF 9771esac 9772 9773case $lt_shell_append in 9774 yes) 9775 cat << \_LT_EOF >> "$cfgfile" 9776 9777# func_append var value 9778# Append VALUE to the end of shell variable VAR. 9779func_append () 9780{ 9781 eval "$[1]+=\$[2]" 9782} 9783_LT_EOF 9784 ;; 9785 *) 9786 cat << \_LT_EOF >> "$cfgfile" 9787 9788# func_append var value 9789# Append VALUE to the end of shell variable VAR. 9790func_append () 9791{ 9792 eval "$[1]=\$$[1]\$[2]" 9793} 9794 9795_LT_EOF 9796 ;; 9797 esac 9798]) 9799 9800# Helper functions for option handling. -*- Autoconf -*- 9801# 9802# Copyright (C) 2004, 2005, 2007, 2008, 2009 Free Software Foundation, 9803# Inc. 9804# Written by Gary V. Vaughan, 2004 9805# 9806# This file is free software; the Free Software Foundation gives 9807# unlimited permission to copy and/or distribute it, with or without 9808# modifications, as long as this notice is preserved. 9809 9810# serial 7 ltoptions.m4 9811 9812# This is to help aclocal find these macros, as it can't see m4_define. 9813AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])]) 9814 9815 9816# _LT_MANGLE_OPTION(MACRO-NAME, OPTION-NAME) 9817# ------------------------------------------ 9818m4_define([_LT_MANGLE_OPTION], 9819[[_LT_OPTION_]m4_bpatsubst($1__$2, [[^a-zA-Z0-9_]], [_])]) 9820 9821 9822# _LT_SET_OPTION(MACRO-NAME, OPTION-NAME) 9823# --------------------------------------- 9824# Set option OPTION-NAME for macro MACRO-NAME, and if there is a 9825# matching handler defined, dispatch to it. Other OPTION-NAMEs are 9826# saved as a flag. 9827m4_define([_LT_SET_OPTION], 9828[m4_define(_LT_MANGLE_OPTION([$1], [$2]))dnl 9829m4_ifdef(_LT_MANGLE_DEFUN([$1], [$2]), 9830 _LT_MANGLE_DEFUN([$1], [$2]), 9831 [m4_warning([Unknown $1 option `$2'])])[]dnl 9832]) 9833 9834 9835# _LT_IF_OPTION(MACRO-NAME, OPTION-NAME, IF-SET, [IF-NOT-SET]) 9836# ------------------------------------------------------------ 9837# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. 9838m4_define([_LT_IF_OPTION], 9839[m4_ifdef(_LT_MANGLE_OPTION([$1], [$2]), [$3], [$4])]) 9840 9841 9842# _LT_UNLESS_OPTIONS(MACRO-NAME, OPTION-LIST, IF-NOT-SET) 9843# ------------------------------------------------------- 9844# Execute IF-NOT-SET unless all options in OPTION-LIST for MACRO-NAME 9845# are set. 9846m4_define([_LT_UNLESS_OPTIONS], 9847[m4_foreach([_LT_Option], m4_split(m4_normalize([$2])), 9848 [m4_ifdef(_LT_MANGLE_OPTION([$1], _LT_Option), 9849 [m4_define([$0_found])])])[]dnl 9850m4_ifdef([$0_found], [m4_undefine([$0_found])], [$3 9851])[]dnl 9852]) 9853 9854 9855# _LT_SET_OPTIONS(MACRO-NAME, OPTION-LIST) 9856# ---------------------------------------- 9857# OPTION-LIST is a space-separated list of Libtool options associated 9858# with MACRO-NAME. If any OPTION has a matching handler declared with 9859# LT_OPTION_DEFINE, dispatch to that macro; otherwise complain about 9860# the unknown option and exit. 9861m4_defun([_LT_SET_OPTIONS], 9862[# Set options 9863m4_foreach([_LT_Option], m4_split(m4_normalize([$2])), 9864 [_LT_SET_OPTION([$1], _LT_Option)]) 9865 9866m4_if([$1],[LT_INIT],[ 9867 dnl 9868 dnl Simply set some default values (i.e off) if boolean options were not 9869 dnl specified: 9870 _LT_UNLESS_OPTIONS([LT_INIT], [dlopen], [enable_dlopen=no 9871 ]) 9872 _LT_UNLESS_OPTIONS([LT_INIT], [win32-dll], [enable_win32_dll=no 9873 ]) 9874 dnl 9875 dnl If no reference was made to various pairs of opposing options, then 9876 dnl we run the default mode handler for the pair. For example, if neither 9877 dnl `shared' nor `disable-shared' was passed, we enable building of shared 9878 dnl archives by default: 9879 _LT_UNLESS_OPTIONS([LT_INIT], [shared disable-shared], [_LT_ENABLE_SHARED]) 9880 _LT_UNLESS_OPTIONS([LT_INIT], [static disable-static], [_LT_ENABLE_STATIC]) 9881 _LT_UNLESS_OPTIONS([LT_INIT], [pic-only no-pic], [_LT_WITH_PIC]) 9882 _LT_UNLESS_OPTIONS([LT_INIT], [fast-install disable-fast-install], 9883 [_LT_ENABLE_FAST_INSTALL]) 9884 ]) 9885])# _LT_SET_OPTIONS 9886 9887 9888 9889# _LT_MANGLE_DEFUN(MACRO-NAME, OPTION-NAME) 9890# ----------------------------------------- 9891m4_define([_LT_MANGLE_DEFUN], 9892[[_LT_OPTION_DEFUN_]m4_bpatsubst(m4_toupper([$1__$2]), [[^A-Z0-9_]], [_])]) 9893 9894 9895# LT_OPTION_DEFINE(MACRO-NAME, OPTION-NAME, CODE) 9896# ----------------------------------------------- 9897m4_define([LT_OPTION_DEFINE], 9898[m4_define(_LT_MANGLE_DEFUN([$1], [$2]), [$3])[]dnl 9899])# LT_OPTION_DEFINE 9900 9901 9902# dlopen 9903# ------ 9904LT_OPTION_DEFINE([LT_INIT], [dlopen], [enable_dlopen=yes 9905]) 9906 9907AU_DEFUN([AC_LIBTOOL_DLOPEN], 9908[_LT_SET_OPTION([LT_INIT], [dlopen]) 9909AC_DIAGNOSE([obsolete], 9910[$0: Remove this warning and the call to _LT_SET_OPTION when you 9911put the `dlopen' option into LT_INIT's first parameter.]) 9912]) 9913 9914dnl aclocal-1.4 backwards compatibility: 9915dnl AC_DEFUN([AC_LIBTOOL_DLOPEN], []) 9916 9917 9918# win32-dll 9919# --------- 9920# Declare package support for building win32 dll's. 9921LT_OPTION_DEFINE([LT_INIT], [win32-dll], 9922[enable_win32_dll=yes 9923 9924case $host in 9925*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-cegcc*) 9926 AC_CHECK_TOOL(AS, as, false) 9927 AC_CHECK_TOOL(DLLTOOL, dlltool, false) 9928 AC_CHECK_TOOL(OBJDUMP, objdump, false) 9929 ;; 9930esac 9931 9932test -z "$AS" && AS=as 9933_LT_DECL([], [AS], [1], [Assembler program])dnl 9934 9935test -z "$DLLTOOL" && DLLTOOL=dlltool 9936_LT_DECL([], [DLLTOOL], [1], [DLL creation program])dnl 9937 9938test -z "$OBJDUMP" && OBJDUMP=objdump 9939_LT_DECL([], [OBJDUMP], [1], [Object dumper program])dnl 9940])# win32-dll 9941 9942AU_DEFUN([AC_LIBTOOL_WIN32_DLL], 9943[AC_REQUIRE([AC_CANONICAL_HOST])dnl 9944_LT_SET_OPTION([LT_INIT], [win32-dll]) 9945AC_DIAGNOSE([obsolete], 9946[$0: Remove this warning and the call to _LT_SET_OPTION when you 9947put the `win32-dll' option into LT_INIT's first parameter.]) 9948]) 9949 9950dnl aclocal-1.4 backwards compatibility: 9951dnl AC_DEFUN([AC_LIBTOOL_WIN32_DLL], []) 9952 9953 9954# _LT_ENABLE_SHARED([DEFAULT]) 9955# ---------------------------- 9956# implement the --enable-shared flag, and supports the `shared' and 9957# `disable-shared' LT_INIT options. 9958# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. 9959m4_define([_LT_ENABLE_SHARED], 9960[m4_define([_LT_ENABLE_SHARED_DEFAULT], [m4_if($1, no, no, yes)])dnl 9961AC_ARG_ENABLE([shared], 9962 [AS_HELP_STRING([--enable-shared@<:@=PKGS@:>@], 9963 [build shared libraries @<:@default=]_LT_ENABLE_SHARED_DEFAULT[@:>@])], 9964 [p=${PACKAGE-default} 9965 case $enableval in 9966 yes) enable_shared=yes ;; 9967 no) enable_shared=no ;; 9968 *) 9969 enable_shared=no 9970 # Look at the argument we got. We use all the common list separators. 9971 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," 9972 for pkg in $enableval; do 9973 IFS="$lt_save_ifs" 9974 if test "X$pkg" = "X$p"; then 9975 enable_shared=yes 9976 fi 9977 done 9978 IFS="$lt_save_ifs" 9979 ;; 9980 esac], 9981 [enable_shared=]_LT_ENABLE_SHARED_DEFAULT) 9982 9983 _LT_DECL([build_libtool_libs], [enable_shared], [0], 9984 [Whether or not to build shared libraries]) 9985])# _LT_ENABLE_SHARED 9986 9987LT_OPTION_DEFINE([LT_INIT], [shared], [_LT_ENABLE_SHARED([yes])]) 9988LT_OPTION_DEFINE([LT_INIT], [disable-shared], [_LT_ENABLE_SHARED([no])]) 9989 9990# Old names: 9991AC_DEFUN([AC_ENABLE_SHARED], 9992[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[shared]) 9993]) 9994 9995AC_DEFUN([AC_DISABLE_SHARED], 9996[_LT_SET_OPTION([LT_INIT], [disable-shared]) 9997]) 9998 9999AU_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)]) 10000AU_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)]) 10001 10002dnl aclocal-1.4 backwards compatibility: 10003dnl AC_DEFUN([AM_ENABLE_SHARED], []) 10004dnl AC_DEFUN([AM_DISABLE_SHARED], []) 10005 10006 10007 10008# _LT_ENABLE_STATIC([DEFAULT]) 10009# ---------------------------- 10010# implement the --enable-static flag, and support the `static' and 10011# `disable-static' LT_INIT options. 10012# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. 10013m4_define([_LT_ENABLE_STATIC], 10014[m4_define([_LT_ENABLE_STATIC_DEFAULT], [m4_if($1, no, no, yes)])dnl 10015AC_ARG_ENABLE([static], 10016 [AS_HELP_STRING([--enable-static@<:@=PKGS@:>@], 10017 [build static libraries @<:@default=]_LT_ENABLE_STATIC_DEFAULT[@:>@])], 10018 [p=${PACKAGE-default} 10019 case $enableval in 10020 yes) enable_static=yes ;; 10021 no) enable_static=no ;; 10022 *) 10023 enable_static=no 10024 # Look at the argument we got. We use all the common list separators. 10025 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," 10026 for pkg in $enableval; do 10027 IFS="$lt_save_ifs" 10028 if test "X$pkg" = "X$p"; then 10029 enable_static=yes 10030 fi 10031 done 10032 IFS="$lt_save_ifs" 10033 ;; 10034 esac], 10035 [enable_static=]_LT_ENABLE_STATIC_DEFAULT) 10036 10037 _LT_DECL([build_old_libs], [enable_static], [0], 10038 [Whether or not to build static libraries]) 10039])# _LT_ENABLE_STATIC 10040 10041LT_OPTION_DEFINE([LT_INIT], [static], [_LT_ENABLE_STATIC([yes])]) 10042LT_OPTION_DEFINE([LT_INIT], [disable-static], [_LT_ENABLE_STATIC([no])]) 10043 10044# Old names: 10045AC_DEFUN([AC_ENABLE_STATIC], 10046[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[static]) 10047]) 10048 10049AC_DEFUN([AC_DISABLE_STATIC], 10050[_LT_SET_OPTION([LT_INIT], [disable-static]) 10051]) 10052 10053AU_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)]) 10054AU_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)]) 10055 10056dnl aclocal-1.4 backwards compatibility: 10057dnl AC_DEFUN([AM_ENABLE_STATIC], []) 10058dnl AC_DEFUN([AM_DISABLE_STATIC], []) 10059 10060 10061 10062# _LT_ENABLE_FAST_INSTALL([DEFAULT]) 10063# ---------------------------------- 10064# implement the --enable-fast-install flag, and support the `fast-install' 10065# and `disable-fast-install' LT_INIT options. 10066# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. 10067m4_define([_LT_ENABLE_FAST_INSTALL], 10068[m4_define([_LT_ENABLE_FAST_INSTALL_DEFAULT], [m4_if($1, no, no, yes)])dnl 10069AC_ARG_ENABLE([fast-install], 10070 [AS_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@], 10071 [optimize for fast installation @<:@default=]_LT_ENABLE_FAST_INSTALL_DEFAULT[@:>@])], 10072 [p=${PACKAGE-default} 10073 case $enableval in 10074 yes) enable_fast_install=yes ;; 10075 no) enable_fast_install=no ;; 10076 *) 10077 enable_fast_install=no 10078 # Look at the argument we got. We use all the common list separators. 10079 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," 10080 for pkg in $enableval; do 10081 IFS="$lt_save_ifs" 10082 if test "X$pkg" = "X$p"; then 10083 enable_fast_install=yes 10084 fi 10085 done 10086 IFS="$lt_save_ifs" 10087 ;; 10088 esac], 10089 [enable_fast_install=]_LT_ENABLE_FAST_INSTALL_DEFAULT) 10090 10091_LT_DECL([fast_install], [enable_fast_install], [0], 10092 [Whether or not to optimize for fast installation])dnl 10093])# _LT_ENABLE_FAST_INSTALL 10094 10095LT_OPTION_DEFINE([LT_INIT], [fast-install], [_LT_ENABLE_FAST_INSTALL([yes])]) 10096LT_OPTION_DEFINE([LT_INIT], [disable-fast-install], [_LT_ENABLE_FAST_INSTALL([no])]) 10097 10098# Old names: 10099AU_DEFUN([AC_ENABLE_FAST_INSTALL], 10100[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[fast-install]) 10101AC_DIAGNOSE([obsolete], 10102[$0: Remove this warning and the call to _LT_SET_OPTION when you put 10103the `fast-install' option into LT_INIT's first parameter.]) 10104]) 10105 10106AU_DEFUN([AC_DISABLE_FAST_INSTALL], 10107[_LT_SET_OPTION([LT_INIT], [disable-fast-install]) 10108AC_DIAGNOSE([obsolete], 10109[$0: Remove this warning and the call to _LT_SET_OPTION when you put 10110the `disable-fast-install' option into LT_INIT's first parameter.]) 10111]) 10112 10113dnl aclocal-1.4 backwards compatibility: 10114dnl AC_DEFUN([AC_ENABLE_FAST_INSTALL], []) 10115dnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], []) 10116 10117 10118# _LT_WITH_PIC([MODE]) 10119# -------------------- 10120# implement the --with-pic flag, and support the `pic-only' and `no-pic' 10121# LT_INIT options. 10122# MODE is either `yes' or `no'. If omitted, it defaults to `both'. 10123m4_define([_LT_WITH_PIC], 10124[AC_ARG_WITH([pic], 10125 [AS_HELP_STRING([--with-pic], 10126 [try to use only PIC/non-PIC objects @<:@default=use both@:>@])], 10127 [pic_mode="$withval"], 10128 [pic_mode=default]) 10129 10130test -z "$pic_mode" && pic_mode=m4_default([$1], [default]) 10131 10132_LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl 10133])# _LT_WITH_PIC 10134 10135LT_OPTION_DEFINE([LT_INIT], [pic-only], [_LT_WITH_PIC([yes])]) 10136LT_OPTION_DEFINE([LT_INIT], [no-pic], [_LT_WITH_PIC([no])]) 10137 10138# Old name: 10139AU_DEFUN([AC_LIBTOOL_PICMODE], 10140[_LT_SET_OPTION([LT_INIT], [pic-only]) 10141AC_DIAGNOSE([obsolete], 10142[$0: Remove this warning and the call to _LT_SET_OPTION when you 10143put the `pic-only' option into LT_INIT's first parameter.]) 10144]) 10145 10146dnl aclocal-1.4 backwards compatibility: 10147dnl AC_DEFUN([AC_LIBTOOL_PICMODE], []) 10148 10149 10150m4_define([_LTDL_MODE], []) 10151LT_OPTION_DEFINE([LTDL_INIT], [nonrecursive], 10152 [m4_define([_LTDL_MODE], [nonrecursive])]) 10153LT_OPTION_DEFINE([LTDL_INIT], [recursive], 10154 [m4_define([_LTDL_MODE], [recursive])]) 10155LT_OPTION_DEFINE([LTDL_INIT], [subproject], 10156 [m4_define([_LTDL_MODE], [subproject])]) 10157 10158m4_define([_LTDL_TYPE], []) 10159LT_OPTION_DEFINE([LTDL_INIT], [installable], 10160 [m4_define([_LTDL_TYPE], [installable])]) 10161LT_OPTION_DEFINE([LTDL_INIT], [convenience], 10162 [m4_define([_LTDL_TYPE], [convenience])]) 10163 10164# ltsugar.m4 -- libtool m4 base layer. -*-Autoconf-*- 10165# 10166# Copyright (C) 2004, 2005, 2007, 2008 Free Software Foundation, Inc. 10167# Written by Gary V. Vaughan, 2004 10168# 10169# This file is free software; the Free Software Foundation gives 10170# unlimited permission to copy and/or distribute it, with or without 10171# modifications, as long as this notice is preserved. 10172 10173# serial 6 ltsugar.m4 10174 10175# This is to help aclocal find these macros, as it can't see m4_define. 10176AC_DEFUN([LTSUGAR_VERSION], [m4_if([0.1])]) 10177 10178 10179# lt_join(SEP, ARG1, [ARG2...]) 10180# ----------------------------- 10181# Produce ARG1SEPARG2...SEPARGn, omitting [] arguments and their 10182# associated separator. 10183# Needed until we can rely on m4_join from Autoconf 2.62, since all earlier 10184# versions in m4sugar had bugs. 10185m4_define([lt_join], 10186[m4_if([$#], [1], [], 10187 [$#], [2], [[$2]], 10188 [m4_if([$2], [], [], [[$2]_])$0([$1], m4_shift(m4_shift($@)))])]) 10189m4_define([_lt_join], 10190[m4_if([$#$2], [2], [], 10191 [m4_if([$2], [], [], [[$1$2]])$0([$1], m4_shift(m4_shift($@)))])]) 10192 10193 10194# lt_car(LIST) 10195# lt_cdr(LIST) 10196# ------------ 10197# Manipulate m4 lists. 10198# These macros are necessary as long as will still need to support 10199# Autoconf-2.59 which quotes differently. 10200m4_define([lt_car], [[$1]]) 10201m4_define([lt_cdr], 10202[m4_if([$#], 0, [m4_fatal([$0: cannot be called without arguments])], 10203 [$#], 1, [], 10204 [m4_dquote(m4_shift($@))])]) 10205m4_define([lt_unquote], $1) 10206 10207 10208# lt_append(MACRO-NAME, STRING, [SEPARATOR]) 10209# ------------------------------------------ 10210# Redefine MACRO-NAME to hold its former content plus `SEPARATOR'`STRING'. 10211# Note that neither SEPARATOR nor STRING are expanded; they are appended 10212# to MACRO-NAME as is (leaving the expansion for when MACRO-NAME is invoked). 10213# No SEPARATOR is output if MACRO-NAME was previously undefined (different 10214# than defined and empty). 10215# 10216# This macro is needed until we can rely on Autoconf 2.62, since earlier 10217# versions of m4sugar mistakenly expanded SEPARATOR but not STRING. 10218m4_define([lt_append], 10219[m4_define([$1], 10220 m4_ifdef([$1], [m4_defn([$1])[$3]])[$2])]) 10221 10222 10223 10224# lt_combine(SEP, PREFIX-LIST, INFIX, SUFFIX1, [SUFFIX2...]) 10225# ---------------------------------------------------------- 10226# Produce a SEP delimited list of all paired combinations of elements of 10227# PREFIX-LIST with SUFFIX1 through SUFFIXn. Each element of the list 10228# has the form PREFIXmINFIXSUFFIXn. 10229# Needed until we can rely on m4_combine added in Autoconf 2.62. 10230m4_define([lt_combine], 10231[m4_if(m4_eval([$# > 3]), [1], 10232 [m4_pushdef([_Lt_sep], [m4_define([_Lt_sep], m4_defn([lt_car]))])]]dnl 10233[[m4_foreach([_Lt_prefix], [$2], 10234 [m4_foreach([_Lt_suffix], 10235 ]m4_dquote(m4_dquote(m4_shift(m4_shift(m4_shift($@)))))[, 10236 [_Lt_sep([$1])[]m4_defn([_Lt_prefix])[$3]m4_defn([_Lt_suffix])])])])]) 10237 10238 10239# lt_if_append_uniq(MACRO-NAME, VARNAME, [SEPARATOR], [UNIQ], [NOT-UNIQ]) 10240# ----------------------------------------------------------------------- 10241# Iff MACRO-NAME does not yet contain VARNAME, then append it (delimited 10242# by SEPARATOR if supplied) and expand UNIQ, else NOT-UNIQ. 10243m4_define([lt_if_append_uniq], 10244[m4_ifdef([$1], 10245 [m4_if(m4_index([$3]m4_defn([$1])[$3], [$3$2$3]), [-1], 10246 [lt_append([$1], [$2], [$3])$4], 10247 [$5])], 10248 [lt_append([$1], [$2], [$3])$4])]) 10249 10250 10251# lt_dict_add(DICT, KEY, VALUE) 10252# ----------------------------- 10253m4_define([lt_dict_add], 10254[m4_define([$1($2)], [$3])]) 10255 10256 10257# lt_dict_add_subkey(DICT, KEY, SUBKEY, VALUE) 10258# -------------------------------------------- 10259m4_define([lt_dict_add_subkey], 10260[m4_define([$1($2:$3)], [$4])]) 10261 10262 10263# lt_dict_fetch(DICT, KEY, [SUBKEY]) 10264# ---------------------------------- 10265m4_define([lt_dict_fetch], 10266[m4_ifval([$3], 10267 m4_ifdef([$1($2:$3)], [m4_defn([$1($2:$3)])]), 10268 m4_ifdef([$1($2)], [m4_defn([$1($2)])]))]) 10269 10270 10271# lt_if_dict_fetch(DICT, KEY, [SUBKEY], VALUE, IF-TRUE, [IF-FALSE]) 10272# ----------------------------------------------------------------- 10273m4_define([lt_if_dict_fetch], 10274[m4_if(lt_dict_fetch([$1], [$2], [$3]), [$4], 10275 [$5], 10276 [$6])]) 10277 10278 10279# lt_dict_filter(DICT, [SUBKEY], VALUE, [SEPARATOR], KEY, [...]) 10280# -------------------------------------------------------------- 10281m4_define([lt_dict_filter], 10282[m4_if([$5], [], [], 10283 [lt_join(m4_quote(m4_default([$4], [[, ]])), 10284 lt_unquote(m4_split(m4_normalize(m4_foreach(_Lt_key, lt_car([m4_shiftn(4, $@)]), 10285 [lt_if_dict_fetch([$1], _Lt_key, [$2], [$3], [_Lt_key ])])))))])[]dnl 10286]) 10287 10288# ltversion.m4 -- version numbers -*- Autoconf -*- 10289# 10290# Copyright (C) 2004 Free Software Foundation, Inc. 10291# Written by Scott James Remnant, 2004 10292# 10293# This file is free software; the Free Software Foundation gives 10294# unlimited permission to copy and/or distribute it, with or without 10295# modifications, as long as this notice is preserved. 10296 10297# Generated from ltversion.in. 10298 10299# serial 3175 ltversion.m4 10300# This file is part of GNU Libtool 10301 10302m4_define([LT_PACKAGE_VERSION], [2.2.10]) 10303m4_define([LT_PACKAGE_REVISION], [1.3175]) 10304 10305AC_DEFUN([LTVERSION_VERSION], 10306[macro_version='2.2.10' 10307macro_revision='1.3175' 10308_LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?]) 10309_LT_DECL(, macro_revision, 0) 10310]) 10311 10312# lt~obsolete.m4 -- aclocal satisfying obsolete definitions. -*-Autoconf-*- 10313# 10314# Copyright (C) 2004, 2005, 2007, 2009 Free Software Foundation, Inc. 10315# Written by Scott James Remnant, 2004. 10316# 10317# This file is free software; the Free Software Foundation gives 10318# unlimited permission to copy and/or distribute it, with or without 10319# modifications, as long as this notice is preserved. 10320 10321# serial 5 lt~obsolete.m4 10322 10323# These exist entirely to fool aclocal when bootstrapping libtool. 10324# 10325# In the past libtool.m4 has provided macros via AC_DEFUN (or AU_DEFUN) 10326# which have later been changed to m4_define as they aren't part of the 10327# exported API, or moved to Autoconf or Automake where they belong. 10328# 10329# The trouble is, aclocal is a bit thick. It'll see the old AC_DEFUN 10330# in /usr/share/aclocal/libtool.m4 and remember it, then when it sees us 10331# using a macro with the same name in our local m4/libtool.m4 it'll 10332# pull the old libtool.m4 in (it doesn't see our shiny new m4_define 10333# and doesn't know about Autoconf macros at all.) 10334# 10335# So we provide this file, which has a silly filename so it's always 10336# included after everything else. This provides aclocal with the 10337# AC_DEFUNs it wants, but when m4 processes it, it doesn't do anything 10338# because those macros already exist, or will be overwritten later. 10339# We use AC_DEFUN over AU_DEFUN for compatibility with aclocal-1.6. 10340# 10341# Anytime we withdraw an AC_DEFUN or AU_DEFUN, remember to add it here. 10342# Yes, that means every name once taken will need to remain here until 10343# we give up compatibility with versions before 1.7, at which point 10344# we need to keep only those names which we still refer to. 10345 10346# This is to help aclocal find these macros, as it can't see m4_define. 10347AC_DEFUN([LTOBSOLETE_VERSION], [m4_if([1])]) 10348 10349m4_ifndef([AC_LIBTOOL_LINKER_OPTION], [AC_DEFUN([AC_LIBTOOL_LINKER_OPTION])]) 10350m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP])]) 10351m4_ifndef([_LT_AC_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH])]) 10352m4_ifndef([_LT_AC_SHELL_INIT], [AC_DEFUN([_LT_AC_SHELL_INIT])]) 10353m4_ifndef([_LT_AC_SYS_LIBPATH_AIX], [AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX])]) 10354m4_ifndef([_LT_PROG_LTMAIN], [AC_DEFUN([_LT_PROG_LTMAIN])]) 10355m4_ifndef([_LT_AC_TAGVAR], [AC_DEFUN([_LT_AC_TAGVAR])]) 10356m4_ifndef([AC_LTDL_ENABLE_INSTALL], [AC_DEFUN([AC_LTDL_ENABLE_INSTALL])]) 10357m4_ifndef([AC_LTDL_PREOPEN], [AC_DEFUN([AC_LTDL_PREOPEN])]) 10358m4_ifndef([_LT_AC_SYS_COMPILER], [AC_DEFUN([_LT_AC_SYS_COMPILER])]) 10359m4_ifndef([_LT_AC_LOCK], [AC_DEFUN([_LT_AC_LOCK])]) 10360m4_ifndef([AC_LIBTOOL_SYS_OLD_ARCHIVE], [AC_DEFUN([AC_LIBTOOL_SYS_OLD_ARCHIVE])]) 10361m4_ifndef([_LT_AC_TRY_DLOPEN_SELF], [AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF])]) 10362m4_ifndef([AC_LIBTOOL_PROG_CC_C_O], [AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O])]) 10363m4_ifndef([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], [AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS])]) 10364m4_ifndef([AC_LIBTOOL_OBJDIR], [AC_DEFUN([AC_LIBTOOL_OBJDIR])]) 10365m4_ifndef([AC_LTDL_OBJDIR], [AC_DEFUN([AC_LTDL_OBJDIR])]) 10366m4_ifndef([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], [AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH])]) 10367m4_ifndef([AC_LIBTOOL_SYS_LIB_STRIP], [AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP])]) 10368m4_ifndef([AC_PATH_MAGIC], [AC_DEFUN([AC_PATH_MAGIC])]) 10369m4_ifndef([AC_PROG_LD_GNU], [AC_DEFUN([AC_PROG_LD_GNU])]) 10370m4_ifndef([AC_PROG_LD_RELOAD_FLAG], [AC_DEFUN([AC_PROG_LD_RELOAD_FLAG])]) 10371m4_ifndef([AC_DEPLIBS_CHECK_METHOD], [AC_DEFUN([AC_DEPLIBS_CHECK_METHOD])]) 10372m4_ifndef([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI])]) 10373m4_ifndef([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], [AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE])]) 10374m4_ifndef([AC_LIBTOOL_PROG_COMPILER_PIC], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC])]) 10375m4_ifndef([AC_LIBTOOL_PROG_LD_SHLIBS], [AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS])]) 10376m4_ifndef([AC_LIBTOOL_POSTDEP_PREDEP], [AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP])]) 10377m4_ifndef([LT_AC_PROG_EGREP], [AC_DEFUN([LT_AC_PROG_EGREP])]) 10378m4_ifndef([LT_AC_PROG_SED], [AC_DEFUN([LT_AC_PROG_SED])]) 10379m4_ifndef([_LT_CC_BASENAME], [AC_DEFUN([_LT_CC_BASENAME])]) 10380m4_ifndef([_LT_COMPILER_BOILERPLATE], [AC_DEFUN([_LT_COMPILER_BOILERPLATE])]) 10381m4_ifndef([_LT_LINKER_BOILERPLATE], [AC_DEFUN([_LT_LINKER_BOILERPLATE])]) 10382m4_ifndef([_AC_PROG_LIBTOOL], [AC_DEFUN([_AC_PROG_LIBTOOL])]) 10383m4_ifndef([AC_LIBTOOL_SETUP], [AC_DEFUN([AC_LIBTOOL_SETUP])]) 10384m4_ifndef([_LT_AC_CHECK_DLFCN], [AC_DEFUN([_LT_AC_CHECK_DLFCN])]) 10385m4_ifndef([AC_LIBTOOL_SYS_DYNAMIC_LINKER], [AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER])]) 10386m4_ifndef([_LT_AC_TAGCONFIG], [AC_DEFUN([_LT_AC_TAGCONFIG])]) 10387m4_ifndef([AC_DISABLE_FAST_INSTALL], [AC_DEFUN([AC_DISABLE_FAST_INSTALL])]) 10388m4_ifndef([_LT_AC_LANG_CXX], [AC_DEFUN([_LT_AC_LANG_CXX])]) 10389m4_ifndef([_LT_AC_LANG_F77], [AC_DEFUN([_LT_AC_LANG_F77])]) 10390m4_ifndef([_LT_AC_LANG_GCJ], [AC_DEFUN([_LT_AC_LANG_GCJ])]) 10391m4_ifndef([AC_LIBTOOL_LANG_C_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG])]) 10392m4_ifndef([_LT_AC_LANG_C_CONFIG], [AC_DEFUN([_LT_AC_LANG_C_CONFIG])]) 10393m4_ifndef([AC_LIBTOOL_LANG_CXX_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG])]) 10394m4_ifndef([_LT_AC_LANG_CXX_CONFIG], [AC_DEFUN([_LT_AC_LANG_CXX_CONFIG])]) 10395m4_ifndef([AC_LIBTOOL_LANG_F77_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG])]) 10396m4_ifndef([_LT_AC_LANG_F77_CONFIG], [AC_DEFUN([_LT_AC_LANG_F77_CONFIG])]) 10397m4_ifndef([AC_LIBTOOL_LANG_GCJ_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG])]) 10398m4_ifndef([_LT_AC_LANG_GCJ_CONFIG], [AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG])]) 10399m4_ifndef([AC_LIBTOOL_LANG_RC_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG])]) 10400m4_ifndef([_LT_AC_LANG_RC_CONFIG], [AC_DEFUN([_LT_AC_LANG_RC_CONFIG])]) 10401m4_ifndef([AC_LIBTOOL_CONFIG], [AC_DEFUN([AC_LIBTOOL_CONFIG])]) 10402m4_ifndef([_LT_AC_FILE_LTDLL_C], [AC_DEFUN([_LT_AC_FILE_LTDLL_C])]) 10403m4_ifndef([_LT_REQUIRED_DARWIN_CHECKS], [AC_DEFUN([_LT_REQUIRED_DARWIN_CHECKS])]) 10404m4_ifndef([_LT_AC_PROG_CXXCPP], [AC_DEFUN([_LT_AC_PROG_CXXCPP])]) 10405m4_ifndef([_LT_PREPARE_SED_QUOTE_VARS], [AC_DEFUN([_LT_PREPARE_SED_QUOTE_VARS])]) 10406m4_ifndef([_LT_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_PROG_ECHO_BACKSLASH])]) 10407m4_ifndef([_LT_PROG_F77], [AC_DEFUN([_LT_PROG_F77])]) 10408m4_ifndef([_LT_PROG_FC], [AC_DEFUN([_LT_PROG_FC])]) 10409m4_ifndef([_LT_PROG_CXX], [AC_DEFUN([_LT_PROG_CXX])]) 10410 10411