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