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