aclocal.m4 revision 238106
1238106Sdes# generated automatically by aclocal 1.11.1 -*- Autoconf -*- 2238106Sdes 3238106Sdes# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 4238106Sdes# 2005, 2006, 2007, 2008, 2009 Free Software Foundation, Inc. 5238106Sdes# This file is free software; the Free Software Foundation 6238106Sdes# gives unlimited permission to copy and/or distribute it, 7238106Sdes# with or without modifications, as long as this notice is preserved. 8238106Sdes 9238106Sdes# This program is distributed in the hope that it will be useful, 10238106Sdes# but WITHOUT ANY WARRANTY, to the extent permitted by law; without 11238106Sdes# even the implied warranty of MERCHANTABILITY or FITNESS FOR A 12238106Sdes# PARTICULAR PURPOSE. 13238106Sdes 14238106Sdes# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*- 15238106Sdes# 16238106Sdes# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 17238106Sdes# 2006, 2007, 2008, 2009, 2010 Free Software Foundation, 18238106Sdes# Inc. 19238106Sdes# Written by Gordon Matzigkeit, 1996 20238106Sdes# 21238106Sdes# This file is free software; the Free Software Foundation gives 22238106Sdes# unlimited permission to copy and/or distribute it, with or without 23238106Sdes# modifications, as long as this notice is preserved. 24238106Sdes 25238106Sdesm4_define([_LT_COPYING], [dnl 26238106Sdes# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 27238106Sdes# 2006, 2007, 2008, 2009, 2010 Free Software Foundation, 28238106Sdes# Inc. 29238106Sdes# Written by Gordon Matzigkeit, 1996 30238106Sdes# 31238106Sdes# This file is part of GNU Libtool. 32238106Sdes# 33238106Sdes# GNU Libtool is free software; you can redistribute it and/or 34238106Sdes# modify it under the terms of the GNU General Public License as 35238106Sdes# published by the Free Software Foundation; either version 2 of 36238106Sdes# the License, or (at your option) any later version. 37238106Sdes# 38238106Sdes# As a special exception to the GNU General Public License, 39238106Sdes# if you distribute this file as part of a program or library that 40238106Sdes# is built using GNU Libtool, you may include this file under the 41238106Sdes# same distribution terms that you use for the rest of that program. 42238106Sdes# 43238106Sdes# GNU Libtool is distributed in the hope that it will be useful, 44238106Sdes# but WITHOUT ANY WARRANTY; without even the implied warranty of 45238106Sdes# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 46238106Sdes# GNU General Public License for more details. 47238106Sdes# 48238106Sdes# You should have received a copy of the GNU General Public License 49238106Sdes# along with GNU Libtool; see the file COPYING. If not, a copy 50238106Sdes# can be downloaded from http://www.gnu.org/licenses/gpl.html, or 51238106Sdes# obtained by writing to the Free Software Foundation, Inc., 52238106Sdes# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 53238106Sdes]) 54238106Sdes 55238106Sdes# serial 57 LT_INIT 56238106Sdes 57238106Sdes 58238106Sdes# LT_PREREQ(VERSION) 59238106Sdes# ------------------ 60238106Sdes# Complain and exit if this libtool version is less that VERSION. 61238106Sdesm4_defun([LT_PREREQ], 62238106Sdes[m4_if(m4_version_compare(m4_defn([LT_PACKAGE_VERSION]), [$1]), -1, 63238106Sdes [m4_default([$3], 64238106Sdes [m4_fatal([Libtool version $1 or higher is required], 65238106Sdes 63)])], 66238106Sdes [$2])]) 67238106Sdes 68238106Sdes 69238106Sdes# _LT_CHECK_BUILDDIR 70238106Sdes# ------------------ 71238106Sdes# Complain if the absolute build directory name contains unusual characters 72238106Sdesm4_defun([_LT_CHECK_BUILDDIR], 73238106Sdes[case `pwd` in 74238106Sdes *\ * | *\ *) 75238106Sdes AC_MSG_WARN([Libtool does not cope well with whitespace in `pwd`]) ;; 76238106Sdesesac 77238106Sdes]) 78238106Sdes 79238106Sdes 80238106Sdes# LT_INIT([OPTIONS]) 81238106Sdes# ------------------ 82238106SdesAC_DEFUN([LT_INIT], 83238106Sdes[AC_PREREQ([2.58])dnl We use AC_INCLUDES_DEFAULT 84238106SdesAC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl 85238106SdesAC_BEFORE([$0], [LT_LANG])dnl 86238106SdesAC_BEFORE([$0], [LT_OUTPUT])dnl 87238106SdesAC_BEFORE([$0], [LTDL_INIT])dnl 88238106Sdesm4_require([_LT_CHECK_BUILDDIR])dnl 89238106Sdes 90238106Sdesdnl Autoconf doesn't catch unexpanded LT_ macros by default: 91238106Sdesm4_pattern_forbid([^_?LT_[A-Z_]+$])dnl 92238106Sdesm4_pattern_allow([^(_LT_EOF|LT_DLGLOBAL|LT_DLLAZY_OR_NOW|LT_MULTI_MODULE)$])dnl 93238106Sdesdnl aclocal doesn't pull ltoptions.m4, ltsugar.m4, or ltversion.m4 94238106Sdesdnl unless we require an AC_DEFUNed macro: 95238106SdesAC_REQUIRE([LTOPTIONS_VERSION])dnl 96238106SdesAC_REQUIRE([LTSUGAR_VERSION])dnl 97238106SdesAC_REQUIRE([LTVERSION_VERSION])dnl 98238106SdesAC_REQUIRE([LTOBSOLETE_VERSION])dnl 99238106Sdesm4_require([_LT_PROG_LTMAIN])dnl 100238106Sdes 101238106Sdes_LT_SHELL_INIT([SHELL=${CONFIG_SHELL-/bin/sh}]) 102238106Sdes 103238106Sdesdnl Parse OPTIONS 104238106Sdes_LT_SET_OPTIONS([$0], [$1]) 105238106Sdes 106238106Sdes# This can be used to rebuild libtool when needed 107238106SdesLIBTOOL_DEPS="$ltmain" 108238106Sdes 109238106Sdes# Always use our own libtool. 110238106SdesLIBTOOL='$(SHELL) $(top_builddir)/libtool' 111238106SdesAC_SUBST(LIBTOOL)dnl 112238106Sdes 113238106Sdes_LT_SETUP 114238106Sdes 115238106Sdes# Only expand once: 116238106Sdesm4_define([LT_INIT]) 117238106Sdes])# LT_INIT 118238106Sdes 119238106Sdes# Old names: 120238106SdesAU_ALIAS([AC_PROG_LIBTOOL], [LT_INIT]) 121238106SdesAU_ALIAS([AM_PROG_LIBTOOL], [LT_INIT]) 122238106Sdesdnl aclocal-1.4 backwards compatibility: 123238106Sdesdnl AC_DEFUN([AC_PROG_LIBTOOL], []) 124238106Sdesdnl AC_DEFUN([AM_PROG_LIBTOOL], []) 125238106Sdes 126238106Sdes 127238106Sdes# _LT_CC_BASENAME(CC) 128238106Sdes# ------------------- 129238106Sdes# Calculate cc_basename. Skip known compiler wrappers and cross-prefix. 130238106Sdesm4_defun([_LT_CC_BASENAME], 131238106Sdes[for cc_temp in $1""; do 132238106Sdes case $cc_temp in 133238106Sdes compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;; 134238106Sdes distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;; 135238106Sdes \-*) ;; 136238106Sdes *) break;; 137238106Sdes esac 138238106Sdesdone 139238106Sdescc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` 140238106Sdes]) 141238106Sdes 142238106Sdes 143238106Sdes# _LT_FILEUTILS_DEFAULTS 144238106Sdes# ---------------------- 145238106Sdes# It is okay to use these file commands and assume they have been set 146238106Sdes# sensibly after `m4_require([_LT_FILEUTILS_DEFAULTS])'. 147238106Sdesm4_defun([_LT_FILEUTILS_DEFAULTS], 148238106Sdes[: ${CP="cp -f"} 149238106Sdes: ${MV="mv -f"} 150238106Sdes: ${RM="rm -f"} 151238106Sdes])# _LT_FILEUTILS_DEFAULTS 152238106Sdes 153238106Sdes 154238106Sdes# _LT_SETUP 155238106Sdes# --------- 156238106Sdesm4_defun([_LT_SETUP], 157238106Sdes[AC_REQUIRE([AC_CANONICAL_HOST])dnl 158238106SdesAC_REQUIRE([AC_CANONICAL_BUILD])dnl 159238106SdesAC_REQUIRE([_LT_PREPARE_SED_QUOTE_VARS])dnl 160238106SdesAC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl 161238106Sdes 162238106Sdes_LT_DECL([], [host_alias], [0], [The host system])dnl 163238106Sdes_LT_DECL([], [host], [0])dnl 164238106Sdes_LT_DECL([], [host_os], [0])dnl 165238106Sdesdnl 166238106Sdes_LT_DECL([], [build_alias], [0], [The build system])dnl 167238106Sdes_LT_DECL([], [build], [0])dnl 168238106Sdes_LT_DECL([], [build_os], [0])dnl 169238106Sdesdnl 170238106SdesAC_REQUIRE([AC_PROG_CC])dnl 171238106SdesAC_REQUIRE([LT_PATH_LD])dnl 172238106SdesAC_REQUIRE([LT_PATH_NM])dnl 173238106Sdesdnl 174238106SdesAC_REQUIRE([AC_PROG_LN_S])dnl 175238106Sdestest -z "$LN_S" && LN_S="ln -s" 176238106Sdes_LT_DECL([], [LN_S], [1], [Whether we need soft or hard links])dnl 177238106Sdesdnl 178238106SdesAC_REQUIRE([LT_CMD_MAX_LEN])dnl 179238106Sdes_LT_DECL([objext], [ac_objext], [0], [Object file suffix (normally "o")])dnl 180238106Sdes_LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl 181238106Sdesdnl 182238106Sdesm4_require([_LT_FILEUTILS_DEFAULTS])dnl 183238106Sdesm4_require([_LT_CHECK_SHELL_FEATURES])dnl 184238106Sdesm4_require([_LT_PATH_CONVERSION_FUNCTIONS])dnl 185238106Sdesm4_require([_LT_CMD_RELOAD])dnl 186238106Sdesm4_require([_LT_CHECK_MAGIC_METHOD])dnl 187238106Sdesm4_require([_LT_CHECK_SHAREDLIB_FROM_LINKLIB])dnl 188238106Sdesm4_require([_LT_CMD_OLD_ARCHIVE])dnl 189238106Sdesm4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl 190238106Sdesm4_require([_LT_WITH_SYSROOT])dnl 191238106Sdes 192238106Sdes_LT_CONFIG_LIBTOOL_INIT([ 193238106Sdes# See if we are running on zsh, and set the options which allow our 194238106Sdes# commands through without removal of \ escapes INIT. 195238106Sdesif test -n "\${ZSH_VERSION+set}" ; then 196238106Sdes setopt NO_GLOB_SUBST 197238106Sdesfi 198238106Sdes]) 199238106Sdesif test -n "${ZSH_VERSION+set}" ; then 200238106Sdes setopt NO_GLOB_SUBST 201238106Sdesfi 202238106Sdes 203238106Sdes_LT_CHECK_OBJDIR 204238106Sdes 205238106Sdesm4_require([_LT_TAG_COMPILER])dnl 206238106Sdes 207238106Sdescase $host_os in 208238106Sdesaix3*) 209238106Sdes # AIX sometimes has problems with the GCC collect2 program. For some 210238106Sdes # reason, if we set the COLLECT_NAMES environment variable, the problems 211238106Sdes # vanish in a puff of smoke. 212238106Sdes if test "X${COLLECT_NAMES+set}" != Xset; then 213238106Sdes COLLECT_NAMES= 214238106Sdes export COLLECT_NAMES 215238106Sdes fi 216238106Sdes ;; 217238106Sdesesac 218238106Sdes 219238106Sdes# Global variables: 220238106Sdesofile=libtool 221238106Sdescan_build_shared=yes 222238106Sdes 223238106Sdes# All known linkers require a `.a' archive for static linking (except MSVC, 224238106Sdes# which needs '.lib'). 225238106Sdeslibext=a 226238106Sdes 227238106Sdeswith_gnu_ld="$lt_cv_prog_gnu_ld" 228238106Sdes 229238106Sdesold_CC="$CC" 230238106Sdesold_CFLAGS="$CFLAGS" 231238106Sdes 232238106Sdes# Set sane defaults for various variables 233238106Sdestest -z "$CC" && CC=cc 234238106Sdestest -z "$LTCC" && LTCC=$CC 235238106Sdestest -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS 236238106Sdestest -z "$LD" && LD=ld 237238106Sdestest -z "$ac_objext" && ac_objext=o 238238106Sdes 239238106Sdes_LT_CC_BASENAME([$compiler]) 240238106Sdes 241238106Sdes# Only perform the check for file, if the check method requires it 242238106Sdestest -z "$MAGIC_CMD" && MAGIC_CMD=file 243238106Sdescase $deplibs_check_method in 244238106Sdesfile_magic*) 245238106Sdes if test "$file_magic_cmd" = '$MAGIC_CMD'; then 246238106Sdes _LT_PATH_MAGIC 247238106Sdes fi 248238106Sdes ;; 249238106Sdesesac 250238106Sdes 251238106Sdes# Use C for the default configuration in the libtool script 252238106SdesLT_SUPPORTED_TAG([CC]) 253238106Sdes_LT_LANG_C_CONFIG 254238106Sdes_LT_LANG_DEFAULT_CONFIG 255238106Sdes_LT_CONFIG_COMMANDS 256238106Sdes])# _LT_SETUP 257238106Sdes 258238106Sdes 259238106Sdes# _LT_PREPARE_SED_QUOTE_VARS 260238106Sdes# -------------------------- 261238106Sdes# Define a few sed substitution that help us do robust quoting. 262238106Sdesm4_defun([_LT_PREPARE_SED_QUOTE_VARS], 263238106Sdes[# Backslashify metacharacters that are still active within 264238106Sdes# double-quoted strings. 265238106Sdessed_quote_subst='s/\([["`$\\]]\)/\\\1/g' 266238106Sdes 267238106Sdes# Same as above, but do not quote variable references. 268238106Sdesdouble_quote_subst='s/\([["`\\]]\)/\\\1/g' 269238106Sdes 270238106Sdes# Sed substitution to delay expansion of an escaped shell variable in a 271238106Sdes# double_quote_subst'ed string. 272238106Sdesdelay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' 273238106Sdes 274238106Sdes# Sed substitution to delay expansion of an escaped single quote. 275238106Sdesdelay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g' 276238106Sdes 277238106Sdes# Sed substitution to avoid accidental globbing in evaled expressions 278238106Sdesno_glob_subst='s/\*/\\\*/g' 279238106Sdes]) 280238106Sdes 281238106Sdes# _LT_PROG_LTMAIN 282238106Sdes# --------------- 283238106Sdes# Note that this code is called both from `configure', and `config.status' 284238106Sdes# now that we use AC_CONFIG_COMMANDS to generate libtool. Notably, 285238106Sdes# `config.status' has no value for ac_aux_dir unless we are using Automake, 286238106Sdes# so we pass a copy along to make sure it has a sensible value anyway. 287238106Sdesm4_defun([_LT_PROG_LTMAIN], 288238106Sdes[m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl 289238106Sdes_LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir']) 290238106Sdesltmain="$ac_aux_dir/ltmain.sh" 291238106Sdes])# _LT_PROG_LTMAIN 292238106Sdes 293238106Sdes 294238106Sdes 295238106Sdes# So that we can recreate a full libtool script including additional 296238106Sdes# tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS 297238106Sdes# in macros and then make a single call at the end using the `libtool' 298238106Sdes# label. 299238106Sdes 300238106Sdes 301238106Sdes# _LT_CONFIG_LIBTOOL_INIT([INIT-COMMANDS]) 302238106Sdes# ---------------------------------------- 303238106Sdes# Register INIT-COMMANDS to be passed to AC_CONFIG_COMMANDS later. 304238106Sdesm4_define([_LT_CONFIG_LIBTOOL_INIT], 305238106Sdes[m4_ifval([$1], 306238106Sdes [m4_append([_LT_OUTPUT_LIBTOOL_INIT], 307238106Sdes [$1 308238106Sdes])])]) 309238106Sdes 310238106Sdes# Initialize. 311238106Sdesm4_define([_LT_OUTPUT_LIBTOOL_INIT]) 312238106Sdes 313238106Sdes 314238106Sdes# _LT_CONFIG_LIBTOOL([COMMANDS]) 315238106Sdes# ------------------------------ 316238106Sdes# Register COMMANDS to be passed to AC_CONFIG_COMMANDS later. 317238106Sdesm4_define([_LT_CONFIG_LIBTOOL], 318238106Sdes[m4_ifval([$1], 319238106Sdes [m4_append([_LT_OUTPUT_LIBTOOL_COMMANDS], 320238106Sdes [$1 321238106Sdes])])]) 322238106Sdes 323238106Sdes# Initialize. 324238106Sdesm4_define([_LT_OUTPUT_LIBTOOL_COMMANDS]) 325238106Sdes 326238106Sdes 327238106Sdes# _LT_CONFIG_SAVE_COMMANDS([COMMANDS], [INIT_COMMANDS]) 328238106Sdes# ----------------------------------------------------- 329238106Sdesm4_defun([_LT_CONFIG_SAVE_COMMANDS], 330238106Sdes[_LT_CONFIG_LIBTOOL([$1]) 331238106Sdes_LT_CONFIG_LIBTOOL_INIT([$2]) 332238106Sdes]) 333238106Sdes 334238106Sdes 335238106Sdes# _LT_FORMAT_COMMENT([COMMENT]) 336238106Sdes# ----------------------------- 337238106Sdes# Add leading comment marks to the start of each line, and a trailing 338238106Sdes# full-stop to the whole comment if one is not present already. 339238106Sdesm4_define([_LT_FORMAT_COMMENT], 340238106Sdes[m4_ifval([$1], [ 341238106Sdesm4_bpatsubst([m4_bpatsubst([$1], [^ *], [# ])], 342238106Sdes [['`$\]], [\\\&])]m4_bmatch([$1], [[!?.]$], [], [.]) 343238106Sdes)]) 344238106Sdes 345238106Sdes 346238106Sdes 347238106Sdes 348238106Sdes 349238106Sdes# _LT_DECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION], [IS-TAGGED?]) 350238106Sdes# ------------------------------------------------------------------- 351238106Sdes# CONFIGNAME is the name given to the value in the libtool script. 352238106Sdes# VARNAME is the (base) name used in the configure script. 353238106Sdes# VALUE may be 0, 1 or 2 for a computed quote escaped value based on 354238106Sdes# VARNAME. Any other value will be used directly. 355238106Sdesm4_define([_LT_DECL], 356238106Sdes[lt_if_append_uniq([lt_decl_varnames], [$2], [, ], 357238106Sdes [lt_dict_add_subkey([lt_decl_dict], [$2], [libtool_name], 358238106Sdes [m4_ifval([$1], [$1], [$2])]) 359238106Sdes lt_dict_add_subkey([lt_decl_dict], [$2], [value], [$3]) 360238106Sdes m4_ifval([$4], 361238106Sdes [lt_dict_add_subkey([lt_decl_dict], [$2], [description], [$4])]) 362238106Sdes lt_dict_add_subkey([lt_decl_dict], [$2], 363238106Sdes [tagged?], [m4_ifval([$5], [yes], [no])])]) 364238106Sdes]) 365238106Sdes 366238106Sdes 367238106Sdes# _LT_TAGDECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION]) 368238106Sdes# -------------------------------------------------------- 369238106Sdesm4_define([_LT_TAGDECL], [_LT_DECL([$1], [$2], [$3], [$4], [yes])]) 370238106Sdes 371238106Sdes 372238106Sdes# lt_decl_tag_varnames([SEPARATOR], [VARNAME1...]) 373238106Sdes# ------------------------------------------------ 374238106Sdesm4_define([lt_decl_tag_varnames], 375238106Sdes[_lt_decl_filter([tagged?], [yes], $@)]) 376238106Sdes 377238106Sdes 378238106Sdes# _lt_decl_filter(SUBKEY, VALUE, [SEPARATOR], [VARNAME1..]) 379238106Sdes# --------------------------------------------------------- 380238106Sdesm4_define([_lt_decl_filter], 381238106Sdes[m4_case([$#], 382238106Sdes [0], [m4_fatal([$0: too few arguments: $#])], 383238106Sdes [1], [m4_fatal([$0: too few arguments: $#: $1])], 384238106Sdes [2], [lt_dict_filter([lt_decl_dict], [$1], [$2], [], lt_decl_varnames)], 385238106Sdes [3], [lt_dict_filter([lt_decl_dict], [$1], [$2], [$3], lt_decl_varnames)], 386238106Sdes [lt_dict_filter([lt_decl_dict], $@)])[]dnl 387238106Sdes]) 388238106Sdes 389238106Sdes 390238106Sdes# lt_decl_quote_varnames([SEPARATOR], [VARNAME1...]) 391238106Sdes# -------------------------------------------------- 392238106Sdesm4_define([lt_decl_quote_varnames], 393238106Sdes[_lt_decl_filter([value], [1], $@)]) 394238106Sdes 395238106Sdes 396238106Sdes# lt_decl_dquote_varnames([SEPARATOR], [VARNAME1...]) 397238106Sdes# --------------------------------------------------- 398238106Sdesm4_define([lt_decl_dquote_varnames], 399238106Sdes[_lt_decl_filter([value], [2], $@)]) 400238106Sdes 401238106Sdes 402238106Sdes# lt_decl_varnames_tagged([SEPARATOR], [VARNAME1...]) 403238106Sdes# --------------------------------------------------- 404238106Sdesm4_define([lt_decl_varnames_tagged], 405238106Sdes[m4_assert([$# <= 2])dnl 406238106Sdes_$0(m4_quote(m4_default([$1], [[, ]])), 407238106Sdes m4_ifval([$2], [[$2]], [m4_dquote(lt_decl_tag_varnames)]), 408238106Sdes m4_split(m4_normalize(m4_quote(_LT_TAGS)), [ ]))]) 409238106Sdesm4_define([_lt_decl_varnames_tagged], 410238106Sdes[m4_ifval([$3], [lt_combine([$1], [$2], [_], $3)])]) 411238106Sdes 412238106Sdes 413238106Sdes# lt_decl_all_varnames([SEPARATOR], [VARNAME1...]) 414238106Sdes# ------------------------------------------------ 415238106Sdesm4_define([lt_decl_all_varnames], 416238106Sdes[_$0(m4_quote(m4_default([$1], [[, ]])), 417238106Sdes m4_if([$2], [], 418238106Sdes m4_quote(lt_decl_varnames), 419238106Sdes m4_quote(m4_shift($@))))[]dnl 420238106Sdes]) 421238106Sdesm4_define([_lt_decl_all_varnames], 422238106Sdes[lt_join($@, lt_decl_varnames_tagged([$1], 423238106Sdes lt_decl_tag_varnames([[, ]], m4_shift($@))))dnl 424238106Sdes]) 425238106Sdes 426238106Sdes 427238106Sdes# _LT_CONFIG_STATUS_DECLARE([VARNAME]) 428238106Sdes# ------------------------------------ 429238106Sdes# Quote a variable value, and forward it to `config.status' so that its 430238106Sdes# declaration there will have the same value as in `configure'. VARNAME 431238106Sdes# must have a single quote delimited value for this to work. 432238106Sdesm4_define([_LT_CONFIG_STATUS_DECLARE], 433238106Sdes[$1='`$ECHO "$][$1" | $SED "$delay_single_quote_subst"`']) 434238106Sdes 435238106Sdes 436238106Sdes# _LT_CONFIG_STATUS_DECLARATIONS 437238106Sdes# ------------------------------ 438238106Sdes# We delimit libtool config variables with single quotes, so when 439238106Sdes# we write them to config.status, we have to be sure to quote all 440238106Sdes# embedded single quotes properly. In configure, this macro expands 441238106Sdes# each variable declared with _LT_DECL (and _LT_TAGDECL) into: 442238106Sdes# 443238106Sdes# <var>='`$ECHO "$<var>" | $SED "$delay_single_quote_subst"`' 444238106Sdesm4_defun([_LT_CONFIG_STATUS_DECLARATIONS], 445238106Sdes[m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames), 446238106Sdes [m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])]) 447238106Sdes 448238106Sdes 449238106Sdes# _LT_LIBTOOL_TAGS 450238106Sdes# ---------------- 451238106Sdes# Output comment and list of tags supported by the script 452238106Sdesm4_defun([_LT_LIBTOOL_TAGS], 453238106Sdes[_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl 454238106Sdesavailable_tags="_LT_TAGS"dnl 455238106Sdes]) 456238106Sdes 457238106Sdes 458238106Sdes# _LT_LIBTOOL_DECLARE(VARNAME, [TAG]) 459238106Sdes# ----------------------------------- 460238106Sdes# Extract the dictionary values for VARNAME (optionally with TAG) and 461238106Sdes# expand to a commented shell variable setting: 462238106Sdes# 463238106Sdes# # Some comment about what VAR is for. 464238106Sdes# visible_name=$lt_internal_name 465238106Sdesm4_define([_LT_LIBTOOL_DECLARE], 466238106Sdes[_LT_FORMAT_COMMENT(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], 467238106Sdes [description])))[]dnl 468238106Sdesm4_pushdef([_libtool_name], 469238106Sdes m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [libtool_name])))[]dnl 470238106Sdesm4_case(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [value])), 471238106Sdes [0], [_libtool_name=[$]$1], 472238106Sdes [1], [_libtool_name=$lt_[]$1], 473238106Sdes [2], [_libtool_name=$lt_[]$1], 474238106Sdes [_libtool_name=lt_dict_fetch([lt_decl_dict], [$1], [value])])[]dnl 475238106Sdesm4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl 476238106Sdes]) 477238106Sdes 478238106Sdes 479238106Sdes# _LT_LIBTOOL_CONFIG_VARS 480238106Sdes# ----------------------- 481238106Sdes# Produce commented declarations of non-tagged libtool config variables 482238106Sdes# suitable for insertion in the LIBTOOL CONFIG section of the `libtool' 483238106Sdes# script. Tagged libtool config variables (even for the LIBTOOL CONFIG 484238106Sdes# section) are produced by _LT_LIBTOOL_TAG_VARS. 485238106Sdesm4_defun([_LT_LIBTOOL_CONFIG_VARS], 486238106Sdes[m4_foreach([_lt_var], 487238106Sdes m4_quote(_lt_decl_filter([tagged?], [no], [], lt_decl_varnames)), 488238106Sdes [m4_n([_LT_LIBTOOL_DECLARE(_lt_var)])])]) 489238106Sdes 490238106Sdes 491238106Sdes# _LT_LIBTOOL_TAG_VARS(TAG) 492238106Sdes# ------------------------- 493238106Sdesm4_define([_LT_LIBTOOL_TAG_VARS], 494238106Sdes[m4_foreach([_lt_var], m4_quote(lt_decl_tag_varnames), 495238106Sdes [m4_n([_LT_LIBTOOL_DECLARE(_lt_var, [$1])])])]) 496238106Sdes 497238106Sdes 498238106Sdes# _LT_TAGVAR(VARNAME, [TAGNAME]) 499238106Sdes# ------------------------------ 500238106Sdesm4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])]) 501238106Sdes 502238106Sdes 503238106Sdes# _LT_CONFIG_COMMANDS 504238106Sdes# ------------------- 505238106Sdes# Send accumulated output to $CONFIG_STATUS. Thanks to the lists of 506238106Sdes# variables for single and double quote escaping we saved from calls 507238106Sdes# to _LT_DECL, we can put quote escaped variables declarations 508238106Sdes# into `config.status', and then the shell code to quote escape them in 509238106Sdes# for loops in `config.status'. Finally, any additional code accumulated 510238106Sdes# from calls to _LT_CONFIG_LIBTOOL_INIT is expanded. 511238106Sdesm4_defun([_LT_CONFIG_COMMANDS], 512238106Sdes[AC_PROVIDE_IFELSE([LT_OUTPUT], 513238106Sdes dnl If the libtool generation code has been placed in $CONFIG_LT, 514238106Sdes dnl instead of duplicating it all over again into config.status, 515238106Sdes dnl then we will have config.status run $CONFIG_LT later, so it 516238106Sdes dnl needs to know what name is stored there: 517238106Sdes [AC_CONFIG_COMMANDS([libtool], 518238106Sdes [$SHELL $CONFIG_LT || AS_EXIT(1)], [CONFIG_LT='$CONFIG_LT'])], 519238106Sdes dnl If the libtool generation code is destined for config.status, 520238106Sdes dnl expand the accumulated commands and init code now: 521238106Sdes [AC_CONFIG_COMMANDS([libtool], 522238106Sdes [_LT_OUTPUT_LIBTOOL_COMMANDS], [_LT_OUTPUT_LIBTOOL_COMMANDS_INIT])]) 523238106Sdes])#_LT_CONFIG_COMMANDS 524238106Sdes 525238106Sdes 526238106Sdes# Initialize. 527238106Sdesm4_define([_LT_OUTPUT_LIBTOOL_COMMANDS_INIT], 528238106Sdes[ 529238106Sdes 530238106Sdes# The HP-UX ksh and POSIX shell print the target directory to stdout 531238106Sdes# if CDPATH is set. 532238106Sdes(unset CDPATH) >/dev/null 2>&1 && unset CDPATH 533238106Sdes 534238106Sdessed_quote_subst='$sed_quote_subst' 535238106Sdesdouble_quote_subst='$double_quote_subst' 536238106Sdesdelay_variable_subst='$delay_variable_subst' 537238106Sdes_LT_CONFIG_STATUS_DECLARATIONS 538238106SdesLTCC='$LTCC' 539238106SdesLTCFLAGS='$LTCFLAGS' 540238106Sdescompiler='$compiler_DEFAULT' 541238106Sdes 542238106Sdes# A function that is used when there is no print builtin or printf. 543238106Sdesfunc_fallback_echo () 544238106Sdes{ 545238106Sdes eval 'cat <<_LTECHO_EOF 546238106Sdes\$[]1 547238106Sdes_LTECHO_EOF' 548238106Sdes} 549238106Sdes 550238106Sdes# Quote evaled strings. 551238106Sdesfor var in lt_decl_all_varnames([[ \ 552238106Sdes]], lt_decl_quote_varnames); do 553238106Sdes case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in 554238106Sdes *[[\\\\\\\`\\"\\\$]]*) 555238106Sdes eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" 556238106Sdes ;; 557238106Sdes *) 558238106Sdes eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" 559238106Sdes ;; 560238106Sdes esac 561238106Sdesdone 562238106Sdes 563238106Sdes# Double-quote double-evaled strings. 564238106Sdesfor var in lt_decl_all_varnames([[ \ 565238106Sdes]], lt_decl_dquote_varnames); do 566238106Sdes case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in 567238106Sdes *[[\\\\\\\`\\"\\\$]]*) 568238106Sdes eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" 569238106Sdes ;; 570238106Sdes *) 571238106Sdes eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" 572238106Sdes ;; 573238106Sdes esac 574238106Sdesdone 575238106Sdes 576238106Sdes_LT_OUTPUT_LIBTOOL_INIT 577238106Sdes]) 578238106Sdes 579238106Sdes# _LT_GENERATED_FILE_INIT(FILE, [COMMENT]) 580238106Sdes# ------------------------------------ 581238106Sdes# Generate a child script FILE with all initialization necessary to 582238106Sdes# reuse the environment learned by the parent script, and make the 583238106Sdes# file executable. If COMMENT is supplied, it is inserted after the 584238106Sdes# `#!' sequence but before initialization text begins. After this 585238106Sdes# macro, additional text can be appended to FILE to form the body of 586238106Sdes# the child script. The macro ends with non-zero status if the 587238106Sdes# file could not be fully written (such as if the disk is full). 588238106Sdesm4_ifdef([AS_INIT_GENERATED], 589238106Sdes[m4_defun([_LT_GENERATED_FILE_INIT],[AS_INIT_GENERATED($@)])], 590238106Sdes[m4_defun([_LT_GENERATED_FILE_INIT], 591238106Sdes[m4_require([AS_PREPARE])]dnl 592238106Sdes[m4_pushdef([AS_MESSAGE_LOG_FD])]dnl 593238106Sdes[lt_write_fail=0 594238106Sdescat >$1 <<_ASEOF || lt_write_fail=1 595238106Sdes#! $SHELL 596238106Sdes# Generated by $as_me. 597238106Sdes$2 598238106SdesSHELL=\${CONFIG_SHELL-$SHELL} 599238106Sdesexport SHELL 600238106Sdes_ASEOF 601238106Sdescat >>$1 <<\_ASEOF || lt_write_fail=1 602238106SdesAS_SHELL_SANITIZE 603238106Sdes_AS_PREPARE 604238106Sdesexec AS_MESSAGE_FD>&1 605238106Sdes_ASEOF 606238106Sdestest $lt_write_fail = 0 && chmod +x $1[]dnl 607238106Sdesm4_popdef([AS_MESSAGE_LOG_FD])])])# _LT_GENERATED_FILE_INIT 608238106Sdes 609238106Sdes# LT_OUTPUT 610238106Sdes# --------- 611238106Sdes# This macro allows early generation of the libtool script (before 612238106Sdes# AC_OUTPUT is called), incase it is used in configure for compilation 613238106Sdes# tests. 614238106SdesAC_DEFUN([LT_OUTPUT], 615238106Sdes[: ${CONFIG_LT=./config.lt} 616238106SdesAC_MSG_NOTICE([creating $CONFIG_LT]) 617238106Sdes_LT_GENERATED_FILE_INIT(["$CONFIG_LT"], 618238106Sdes[# Run this file to recreate a libtool stub with the current configuration.]) 619238106Sdes 620238106Sdescat >>"$CONFIG_LT" <<\_LTEOF 621238106Sdeslt_cl_silent=false 622238106Sdesexec AS_MESSAGE_LOG_FD>>config.log 623238106Sdes{ 624238106Sdes echo 625238106Sdes AS_BOX([Running $as_me.]) 626238106Sdes} >&AS_MESSAGE_LOG_FD 627238106Sdes 628238106Sdeslt_cl_help="\ 629238106Sdes\`$as_me' creates a local libtool stub from the current configuration, 630238106Sdesfor use in further configure time tests before the real libtool is 631238106Sdesgenerated. 632238106Sdes 633238106SdesUsage: $[0] [[OPTIONS]] 634238106Sdes 635238106Sdes -h, --help print this help, then exit 636238106Sdes -V, --version print version number, then exit 637238106Sdes -q, --quiet do not print progress messages 638238106Sdes -d, --debug don't remove temporary files 639238106Sdes 640238106SdesReport bugs to <bug-libtool@gnu.org>." 641238106Sdes 642238106Sdeslt_cl_version="\ 643238106Sdesm4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl 644238106Sdesm4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION]) 645238106Sdesconfigured by $[0], generated by m4_PACKAGE_STRING. 646238106Sdes 647238106SdesCopyright (C) 2010 Free Software Foundation, Inc. 648238106SdesThis config.lt script is free software; the Free Software Foundation 649238106Sdesgives unlimited permision to copy, distribute and modify it." 650238106Sdes 651238106Sdeswhile test $[#] != 0 652238106Sdesdo 653238106Sdes case $[1] in 654238106Sdes --version | --v* | -V ) 655238106Sdes echo "$lt_cl_version"; exit 0 ;; 656238106Sdes --help | --h* | -h ) 657238106Sdes echo "$lt_cl_help"; exit 0 ;; 658238106Sdes --debug | --d* | -d ) 659238106Sdes debug=: ;; 660238106Sdes --quiet | --q* | --silent | --s* | -q ) 661238106Sdes lt_cl_silent=: ;; 662238106Sdes 663238106Sdes -*) AC_MSG_ERROR([unrecognized option: $[1] 664238106SdesTry \`$[0] --help' for more information.]) ;; 665238106Sdes 666238106Sdes *) AC_MSG_ERROR([unrecognized argument: $[1] 667238106SdesTry \`$[0] --help' for more information.]) ;; 668238106Sdes esac 669238106Sdes shift 670238106Sdesdone 671238106Sdes 672238106Sdesif $lt_cl_silent; then 673238106Sdes exec AS_MESSAGE_FD>/dev/null 674238106Sdesfi 675238106Sdes_LTEOF 676238106Sdes 677238106Sdescat >>"$CONFIG_LT" <<_LTEOF 678238106Sdes_LT_OUTPUT_LIBTOOL_COMMANDS_INIT 679238106Sdes_LTEOF 680238106Sdes 681238106Sdescat >>"$CONFIG_LT" <<\_LTEOF 682238106SdesAC_MSG_NOTICE([creating $ofile]) 683238106Sdes_LT_OUTPUT_LIBTOOL_COMMANDS 684238106SdesAS_EXIT(0) 685238106Sdes_LTEOF 686238106Sdeschmod +x "$CONFIG_LT" 687238106Sdes 688238106Sdes# configure is writing to config.log, but config.lt does its own redirection, 689238106Sdes# appending to config.log, which fails on DOS, as config.log is still kept 690238106Sdes# open by configure. Here we exec the FD to /dev/null, effectively closing 691238106Sdes# config.log, so it can be properly (re)opened and appended to by config.lt. 692238106Sdeslt_cl_success=: 693238106Sdestest "$silent" = yes && 694238106Sdes lt_config_lt_args="$lt_config_lt_args --quiet" 695238106Sdesexec AS_MESSAGE_LOG_FD>/dev/null 696238106Sdes$SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false 697238106Sdesexec AS_MESSAGE_LOG_FD>>config.log 698238106Sdes$lt_cl_success || AS_EXIT(1) 699238106Sdes])# LT_OUTPUT 700238106Sdes 701238106Sdes 702238106Sdes# _LT_CONFIG(TAG) 703238106Sdes# --------------- 704238106Sdes# If TAG is the built-in tag, create an initial libtool script with a 705238106Sdes# default configuration from the untagged config vars. Otherwise add code 706238106Sdes# to config.status for appending the configuration named by TAG from the 707238106Sdes# matching tagged config vars. 708238106Sdesm4_defun([_LT_CONFIG], 709238106Sdes[m4_require([_LT_FILEUTILS_DEFAULTS])dnl 710238106Sdes_LT_CONFIG_SAVE_COMMANDS([ 711238106Sdes m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl 712238106Sdes m4_if(_LT_TAG, [C], [ 713238106Sdes # See if we are running on zsh, and set the options which allow our 714238106Sdes # commands through without removal of \ escapes. 715238106Sdes if test -n "${ZSH_VERSION+set}" ; then 716238106Sdes setopt NO_GLOB_SUBST 717238106Sdes fi 718238106Sdes 719238106Sdes cfgfile="${ofile}T" 720238106Sdes trap "$RM \"$cfgfile\"; exit 1" 1 2 15 721238106Sdes $RM "$cfgfile" 722238106Sdes 723238106Sdes cat <<_LT_EOF >> "$cfgfile" 724238106Sdes#! $SHELL 725238106Sdes 726238106Sdes# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services. 727238106Sdes# Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION 728238106Sdes# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: 729238106Sdes# NOTE: Changes made to this file will be lost: look at ltmain.sh. 730238106Sdes# 731238106Sdes_LT_COPYING 732238106Sdes_LT_LIBTOOL_TAGS 733238106Sdes 734238106Sdes# ### BEGIN LIBTOOL CONFIG 735238106Sdes_LT_LIBTOOL_CONFIG_VARS 736238106Sdes_LT_LIBTOOL_TAG_VARS 737238106Sdes# ### END LIBTOOL CONFIG 738238106Sdes 739238106Sdes_LT_EOF 740238106Sdes 741238106Sdes case $host_os in 742238106Sdes aix3*) 743238106Sdes cat <<\_LT_EOF >> "$cfgfile" 744238106Sdes# AIX sometimes has problems with the GCC collect2 program. For some 745238106Sdes# reason, if we set the COLLECT_NAMES environment variable, the problems 746238106Sdes# vanish in a puff of smoke. 747238106Sdesif test "X${COLLECT_NAMES+set}" != Xset; then 748238106Sdes COLLECT_NAMES= 749238106Sdes export COLLECT_NAMES 750238106Sdesfi 751238106Sdes_LT_EOF 752238106Sdes ;; 753238106Sdes esac 754238106Sdes 755238106Sdes _LT_PROG_LTMAIN 756238106Sdes 757238106Sdes # We use sed instead of cat because bash on DJGPP gets confused if 758238106Sdes # if finds mixed CR/LF and LF-only lines. Since sed operates in 759238106Sdes # text mode, it properly converts lines to CR/LF. This bash problem 760238106Sdes # is reportedly fixed, but why not run on old versions too? 761238106Sdes sed '$q' "$ltmain" >> "$cfgfile" \ 762238106Sdes || (rm -f "$cfgfile"; exit 1) 763238106Sdes 764238106Sdes _LT_PROG_REPLACE_SHELLFNS 765238106Sdes 766238106Sdes mv -f "$cfgfile" "$ofile" || 767238106Sdes (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") 768238106Sdes chmod +x "$ofile" 769238106Sdes], 770238106Sdes[cat <<_LT_EOF >> "$ofile" 771238106Sdes 772238106Sdesdnl Unfortunately we have to use $1 here, since _LT_TAG is not expanded 773238106Sdesdnl in a comment (ie after a #). 774238106Sdes# ### BEGIN LIBTOOL TAG CONFIG: $1 775238106Sdes_LT_LIBTOOL_TAG_VARS(_LT_TAG) 776238106Sdes# ### END LIBTOOL TAG CONFIG: $1 777238106Sdes_LT_EOF 778238106Sdes])dnl /m4_if 779238106Sdes], 780238106Sdes[m4_if([$1], [], [ 781238106Sdes PACKAGE='$PACKAGE' 782238106Sdes VERSION='$VERSION' 783238106Sdes TIMESTAMP='$TIMESTAMP' 784238106Sdes RM='$RM' 785238106Sdes ofile='$ofile'], []) 786238106Sdes])dnl /_LT_CONFIG_SAVE_COMMANDS 787238106Sdes])# _LT_CONFIG 788238106Sdes 789238106Sdes 790238106Sdes# LT_SUPPORTED_TAG(TAG) 791238106Sdes# --------------------- 792238106Sdes# Trace this macro to discover what tags are supported by the libtool 793238106Sdes# --tag option, using: 794238106Sdes# autoconf --trace 'LT_SUPPORTED_TAG:$1' 795238106SdesAC_DEFUN([LT_SUPPORTED_TAG], []) 796238106Sdes 797238106Sdes 798238106Sdes# C support is built-in for now 799238106Sdesm4_define([_LT_LANG_C_enabled], []) 800238106Sdesm4_define([_LT_TAGS], []) 801238106Sdes 802238106Sdes 803238106Sdes# LT_LANG(LANG) 804238106Sdes# ------------- 805238106Sdes# Enable libtool support for the given language if not already enabled. 806238106SdesAC_DEFUN([LT_LANG], 807238106Sdes[AC_BEFORE([$0], [LT_OUTPUT])dnl 808238106Sdesm4_case([$1], 809238106Sdes [C], [_LT_LANG(C)], 810238106Sdes [C++], [_LT_LANG(CXX)], 811238106Sdes [Java], [_LT_LANG(GCJ)], 812238106Sdes [Fortran 77], [_LT_LANG(F77)], 813238106Sdes [Fortran], [_LT_LANG(FC)], 814238106Sdes [Windows Resource], [_LT_LANG(RC)], 815238106Sdes [m4_ifdef([_LT_LANG_]$1[_CONFIG], 816238106Sdes [_LT_LANG($1)], 817238106Sdes [m4_fatal([$0: unsupported language: "$1"])])])dnl 818238106Sdes])# LT_LANG 819238106Sdes 820238106Sdes 821238106Sdes# _LT_LANG(LANGNAME) 822238106Sdes# ------------------ 823238106Sdesm4_defun([_LT_LANG], 824238106Sdes[m4_ifdef([_LT_LANG_]$1[_enabled], [], 825238106Sdes [LT_SUPPORTED_TAG([$1])dnl 826238106Sdes m4_append([_LT_TAGS], [$1 ])dnl 827238106Sdes m4_define([_LT_LANG_]$1[_enabled], [])dnl 828238106Sdes _LT_LANG_$1_CONFIG($1)])dnl 829238106Sdes])# _LT_LANG 830238106Sdes 831238106Sdes 832238106Sdes# _LT_LANG_DEFAULT_CONFIG 833238106Sdes# ----------------------- 834238106Sdesm4_defun([_LT_LANG_DEFAULT_CONFIG], 835238106Sdes[AC_PROVIDE_IFELSE([AC_PROG_CXX], 836238106Sdes [LT_LANG(CXX)], 837238106Sdes [m4_define([AC_PROG_CXX], defn([AC_PROG_CXX])[LT_LANG(CXX)])]) 838238106Sdes 839238106SdesAC_PROVIDE_IFELSE([AC_PROG_F77], 840238106Sdes [LT_LANG(F77)], 841238106Sdes [m4_define([AC_PROG_F77], defn([AC_PROG_F77])[LT_LANG(F77)])]) 842238106Sdes 843238106SdesAC_PROVIDE_IFELSE([AC_PROG_FC], 844238106Sdes [LT_LANG(FC)], 845238106Sdes [m4_define([AC_PROG_FC], defn([AC_PROG_FC])[LT_LANG(FC)])]) 846238106Sdes 847238106Sdesdnl The call to [A][M_PROG_GCJ] is quoted like that to stop aclocal 848238106Sdesdnl pulling things in needlessly. 849238106SdesAC_PROVIDE_IFELSE([AC_PROG_GCJ], 850238106Sdes [LT_LANG(GCJ)], 851238106Sdes [AC_PROVIDE_IFELSE([A][M_PROG_GCJ], 852238106Sdes [LT_LANG(GCJ)], 853238106Sdes [AC_PROVIDE_IFELSE([LT_PROG_GCJ], 854238106Sdes [LT_LANG(GCJ)], 855238106Sdes [m4_ifdef([AC_PROG_GCJ], 856238106Sdes [m4_define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[LT_LANG(GCJ)])]) 857238106Sdes m4_ifdef([A][M_PROG_GCJ], 858238106Sdes [m4_define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[LT_LANG(GCJ)])]) 859238106Sdes m4_ifdef([LT_PROG_GCJ], 860238106Sdes [m4_define([LT_PROG_GCJ], defn([LT_PROG_GCJ])[LT_LANG(GCJ)])])])])]) 861238106Sdes 862238106SdesAC_PROVIDE_IFELSE([LT_PROG_RC], 863238106Sdes [LT_LANG(RC)], 864238106Sdes [m4_define([LT_PROG_RC], defn([LT_PROG_RC])[LT_LANG(RC)])]) 865238106Sdes])# _LT_LANG_DEFAULT_CONFIG 866238106Sdes 867238106Sdes# Obsolete macros: 868238106SdesAU_DEFUN([AC_LIBTOOL_CXX], [LT_LANG(C++)]) 869238106SdesAU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)]) 870238106SdesAU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)]) 871238106SdesAU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)]) 872238106SdesAU_DEFUN([AC_LIBTOOL_RC], [LT_LANG(Windows Resource)]) 873238106Sdesdnl aclocal-1.4 backwards compatibility: 874238106Sdesdnl AC_DEFUN([AC_LIBTOOL_CXX], []) 875238106Sdesdnl AC_DEFUN([AC_LIBTOOL_F77], []) 876238106Sdesdnl AC_DEFUN([AC_LIBTOOL_FC], []) 877238106Sdesdnl AC_DEFUN([AC_LIBTOOL_GCJ], []) 878238106Sdesdnl AC_DEFUN([AC_LIBTOOL_RC], []) 879238106Sdes 880238106Sdes 881238106Sdes# _LT_TAG_COMPILER 882238106Sdes# ---------------- 883238106Sdesm4_defun([_LT_TAG_COMPILER], 884238106Sdes[AC_REQUIRE([AC_PROG_CC])dnl 885238106Sdes 886238106Sdes_LT_DECL([LTCC], [CC], [1], [A C compiler])dnl 887238106Sdes_LT_DECL([LTCFLAGS], [CFLAGS], [1], [LTCC compiler flags])dnl 888238106Sdes_LT_TAGDECL([CC], [compiler], [1], [A language specific compiler])dnl 889238106Sdes_LT_TAGDECL([with_gcc], [GCC], [0], [Is the compiler the GNU compiler?])dnl 890238106Sdes 891238106Sdes# If no C compiler was specified, use CC. 892238106SdesLTCC=${LTCC-"$CC"} 893238106Sdes 894238106Sdes# If no C compiler flags were specified, use CFLAGS. 895238106SdesLTCFLAGS=${LTCFLAGS-"$CFLAGS"} 896238106Sdes 897238106Sdes# Allow CC to be a program name with arguments. 898238106Sdescompiler=$CC 899238106Sdes])# _LT_TAG_COMPILER 900238106Sdes 901238106Sdes 902238106Sdes# _LT_COMPILER_BOILERPLATE 903238106Sdes# ------------------------ 904238106Sdes# Check for compiler boilerplate output or warnings with 905238106Sdes# the simple compiler test code. 906238106Sdesm4_defun([_LT_COMPILER_BOILERPLATE], 907238106Sdes[m4_require([_LT_DECL_SED])dnl 908238106Sdesac_outfile=conftest.$ac_objext 909238106Sdesecho "$lt_simple_compile_test_code" >conftest.$ac_ext 910238106Sdeseval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err 911238106Sdes_lt_compiler_boilerplate=`cat conftest.err` 912238106Sdes$RM conftest* 913238106Sdes])# _LT_COMPILER_BOILERPLATE 914238106Sdes 915238106Sdes 916238106Sdes# _LT_LINKER_BOILERPLATE 917238106Sdes# ---------------------- 918238106Sdes# Check for linker boilerplate output or warnings with 919238106Sdes# the simple link test code. 920238106Sdesm4_defun([_LT_LINKER_BOILERPLATE], 921238106Sdes[m4_require([_LT_DECL_SED])dnl 922238106Sdesac_outfile=conftest.$ac_objext 923238106Sdesecho "$lt_simple_link_test_code" >conftest.$ac_ext 924238106Sdeseval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err 925238106Sdes_lt_linker_boilerplate=`cat conftest.err` 926238106Sdes$RM -r conftest* 927238106Sdes])# _LT_LINKER_BOILERPLATE 928238106Sdes 929238106Sdes# _LT_REQUIRED_DARWIN_CHECKS 930238106Sdes# ------------------------- 931238106Sdesm4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[ 932238106Sdes case $host_os in 933238106Sdes rhapsody* | darwin*) 934238106Sdes AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:]) 935238106Sdes AC_CHECK_TOOL([NMEDIT], [nmedit], [:]) 936238106Sdes AC_CHECK_TOOL([LIPO], [lipo], [:]) 937238106Sdes AC_CHECK_TOOL([OTOOL], [otool], [:]) 938238106Sdes AC_CHECK_TOOL([OTOOL64], [otool64], [:]) 939238106Sdes _LT_DECL([], [DSYMUTIL], [1], 940238106Sdes [Tool to manipulate archived DWARF debug symbol files on Mac OS X]) 941238106Sdes _LT_DECL([], [NMEDIT], [1], 942238106Sdes [Tool to change global to local symbols on Mac OS X]) 943238106Sdes _LT_DECL([], [LIPO], [1], 944238106Sdes [Tool to manipulate fat objects and archives on Mac OS X]) 945238106Sdes _LT_DECL([], [OTOOL], [1], 946238106Sdes [ldd/readelf like tool for Mach-O binaries on Mac OS X]) 947238106Sdes _LT_DECL([], [OTOOL64], [1], 948238106Sdes [ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4]) 949238106Sdes 950238106Sdes AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod], 951238106Sdes [lt_cv_apple_cc_single_mod=no 952238106Sdes if test -z "${LT_MULTI_MODULE}"; then 953238106Sdes # By default we will add the -single_module flag. You can override 954238106Sdes # by either setting the environment variable LT_MULTI_MODULE 955238106Sdes # non-empty at configure time, or by adding -multi_module to the 956238106Sdes # link flags. 957238106Sdes rm -rf libconftest.dylib* 958238106Sdes echo "int foo(void){return 1;}" > conftest.c 959238106Sdes echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ 960238106Sdes-dynamiclib -Wl,-single_module conftest.c" >&AS_MESSAGE_LOG_FD 961238106Sdes $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ 962238106Sdes -dynamiclib -Wl,-single_module conftest.c 2>conftest.err 963238106Sdes _lt_result=$? 964238106Sdes if test -f libconftest.dylib && test ! -s conftest.err && test $_lt_result = 0; then 965238106Sdes lt_cv_apple_cc_single_mod=yes 966238106Sdes else 967238106Sdes cat conftest.err >&AS_MESSAGE_LOG_FD 968238106Sdes fi 969238106Sdes rm -rf libconftest.dylib* 970238106Sdes rm -f conftest.* 971238106Sdes fi]) 972238106Sdes AC_CACHE_CHECK([for -exported_symbols_list linker flag], 973238106Sdes [lt_cv_ld_exported_symbols_list], 974238106Sdes [lt_cv_ld_exported_symbols_list=no 975238106Sdes save_LDFLAGS=$LDFLAGS 976238106Sdes echo "_main" > conftest.sym 977238106Sdes LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" 978238106Sdes AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], 979238106Sdes [lt_cv_ld_exported_symbols_list=yes], 980238106Sdes [lt_cv_ld_exported_symbols_list=no]) 981238106Sdes LDFLAGS="$save_LDFLAGS" 982238106Sdes ]) 983238106Sdes AC_CACHE_CHECK([for -force_load linker flag],[lt_cv_ld_force_load], 984238106Sdes [lt_cv_ld_force_load=no 985238106Sdes cat > conftest.c << _LT_EOF 986238106Sdesint forced_loaded() { return 2;} 987238106Sdes_LT_EOF 988238106Sdes echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&AS_MESSAGE_LOG_FD 989238106Sdes $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD 990238106Sdes echo "$AR cru libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD 991238106Sdes $AR cru libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD 992238106Sdes echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD 993238106Sdes $RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD 994238106Sdes cat > conftest.c << _LT_EOF 995238106Sdesint main() { return 0;} 996238106Sdes_LT_EOF 997238106Sdes echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&AS_MESSAGE_LOG_FD 998238106Sdes $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err 999238106Sdes _lt_result=$? 1000238106Sdes if test -f conftest && test ! -s conftest.err && test $_lt_result = 0 && $GREP forced_load conftest 2>&1 >/dev/null; then 1001238106Sdes lt_cv_ld_force_load=yes 1002238106Sdes else 1003238106Sdes cat conftest.err >&AS_MESSAGE_LOG_FD 1004238106Sdes fi 1005238106Sdes rm -f conftest.err libconftest.a conftest conftest.c 1006238106Sdes rm -rf conftest.dSYM 1007238106Sdes ]) 1008238106Sdes case $host_os in 1009238106Sdes rhapsody* | darwin1.[[012]]) 1010238106Sdes _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;; 1011238106Sdes darwin1.*) 1012238106Sdes _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; 1013238106Sdes darwin*) # darwin 5.x on 1014238106Sdes # if running on 10.5 or later, the deployment target defaults 1015238106Sdes # to the OS version, if on x86, and 10.4, the deployment 1016238106Sdes # target defaults to 10.4. Don't you love it? 1017238106Sdes case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in 1018238106Sdes 10.0,*86*-darwin8*|10.0,*-darwin[[91]]*) 1019238106Sdes _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; 1020238106Sdes 10.[[012]]*) 1021238106Sdes _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; 1022238106Sdes 10.*) 1023238106Sdes _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; 1024238106Sdes esac 1025238106Sdes ;; 1026238106Sdes esac 1027238106Sdes if test "$lt_cv_apple_cc_single_mod" = "yes"; then 1028238106Sdes _lt_dar_single_mod='$single_module' 1029238106Sdes fi 1030238106Sdes if test "$lt_cv_ld_exported_symbols_list" = "yes"; then 1031238106Sdes _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym' 1032238106Sdes else 1033238106Sdes _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}' 1034238106Sdes fi 1035238106Sdes if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then 1036238106Sdes _lt_dsymutil='~$DSYMUTIL $lib || :' 1037238106Sdes else 1038238106Sdes _lt_dsymutil= 1039238106Sdes fi 1040238106Sdes ;; 1041238106Sdes esac 1042238106Sdes]) 1043238106Sdes 1044238106Sdes 1045238106Sdes# _LT_DARWIN_LINKER_FEATURES 1046238106Sdes# -------------------------- 1047238106Sdes# Checks for linker and compiler features on darwin 1048238106Sdesm4_defun([_LT_DARWIN_LINKER_FEATURES], 1049238106Sdes[ 1050238106Sdes m4_require([_LT_REQUIRED_DARWIN_CHECKS]) 1051238106Sdes _LT_TAGVAR(archive_cmds_need_lc, $1)=no 1052238106Sdes _LT_TAGVAR(hardcode_direct, $1)=no 1053238106Sdes _LT_TAGVAR(hardcode_automatic, $1)=yes 1054238106Sdes _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported 1055238106Sdes if test "$lt_cv_ld_force_load" = "yes"; then 1056238106Sdes _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\"`' 1057238106Sdes else 1058238106Sdes _LT_TAGVAR(whole_archive_flag_spec, $1)='' 1059238106Sdes fi 1060238106Sdes _LT_TAGVAR(link_all_deplibs, $1)=yes 1061238106Sdes _LT_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined" 1062238106Sdes case $cc_basename in 1063238106Sdes ifort*) _lt_dar_can_shared=yes ;; 1064238106Sdes *) _lt_dar_can_shared=$GCC ;; 1065238106Sdes esac 1066238106Sdes if test "$_lt_dar_can_shared" = "yes"; then 1067238106Sdes output_verbose_link_cmd=func_echo_all 1068238106Sdes _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}" 1069238106Sdes _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" 1070238106Sdes _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}" 1071238106Sdes _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}" 1072238106Sdes m4_if([$1], [CXX], 1073238106Sdes[ if test "$lt_cv_apple_cc_single_mod" != "yes"; then 1074238106Sdes _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}" 1075238106Sdes _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}" 1076238106Sdes fi 1077238106Sdes],[]) 1078238106Sdes else 1079238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 1080238106Sdes fi 1081238106Sdes]) 1082238106Sdes 1083238106Sdes# _LT_SYS_MODULE_PATH_AIX([TAGNAME]) 1084238106Sdes# ---------------------------------- 1085238106Sdes# Links a minimal program and checks the executable 1086238106Sdes# for the system default hardcoded library path. In most cases, 1087238106Sdes# this is /usr/lib:/lib, but when the MPI compilers are used 1088238106Sdes# the location of the communication and MPI libs are included too. 1089238106Sdes# If we don't find anything, use the default library path according 1090238106Sdes# to the aix ld manual. 1091238106Sdes# Store the results from the different compilers for each TAGNAME. 1092238106Sdes# Allow to override them for all tags through lt_cv_aix_libpath. 1093238106Sdesm4_defun([_LT_SYS_MODULE_PATH_AIX], 1094238106Sdes[m4_require([_LT_DECL_SED])dnl 1095238106Sdesif test "${lt_cv_aix_libpath+set}" = set; then 1096238106Sdes aix_libpath=$lt_cv_aix_libpath 1097238106Sdeselse 1098238106Sdes AC_CACHE_VAL([_LT_TAGVAR([lt_cv_aix_libpath_], [$1])], 1099238106Sdes [AC_LINK_IFELSE([AC_LANG_PROGRAM],[ 1100238106Sdes lt_aix_libpath_sed='[ 1101238106Sdes /Import File Strings/,/^$/ { 1102238106Sdes /^0/ { 1103238106Sdes s/^0 *\([^ ]*\) *$/\1/ 1104238106Sdes p 1105238106Sdes } 1106238106Sdes }]' 1107238106Sdes _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` 1108238106Sdes # Check for a 64-bit object if we didn't find anything. 1109238106Sdes if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then 1110238106Sdes _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` 1111238106Sdes fi],[]) 1112238106Sdes if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then 1113238106Sdes _LT_TAGVAR([lt_cv_aix_libpath_], [$1])="/usr/lib:/lib" 1114238106Sdes fi 1115238106Sdes ]) 1116238106Sdes aix_libpath=$_LT_TAGVAR([lt_cv_aix_libpath_], [$1]) 1117238106Sdesfi 1118238106Sdes])# _LT_SYS_MODULE_PATH_AIX 1119238106Sdes 1120238106Sdes 1121238106Sdes# _LT_SHELL_INIT(ARG) 1122238106Sdes# ------------------- 1123238106Sdesm4_define([_LT_SHELL_INIT], 1124238106Sdes[m4_divert_text([M4SH-INIT], [$1 1125238106Sdes])])# _LT_SHELL_INIT 1126238106Sdes 1127238106Sdes 1128238106Sdes 1129238106Sdes# _LT_PROG_ECHO_BACKSLASH 1130238106Sdes# ----------------------- 1131238106Sdes# Find how we can fake an echo command that does not interpret backslash. 1132238106Sdes# In particular, with Autoconf 2.60 or later we add some code to the start 1133238106Sdes# of the generated configure script which will find a shell with a builtin 1134238106Sdes# printf (which we can use as an echo command). 1135238106Sdesm4_defun([_LT_PROG_ECHO_BACKSLASH], 1136238106Sdes[ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' 1137238106SdesECHO=$ECHO$ECHO$ECHO$ECHO$ECHO 1138238106SdesECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO 1139238106Sdes 1140238106SdesAC_MSG_CHECKING([how to print strings]) 1141238106Sdes# Test print first, because it will be a builtin if present. 1142238106Sdesif test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \ 1143238106Sdes test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then 1144238106Sdes ECHO='print -r --' 1145238106Sdeselif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then 1146238106Sdes ECHO='printf %s\n' 1147238106Sdeselse 1148238106Sdes # Use this function as a fallback that always works. 1149238106Sdes func_fallback_echo () 1150238106Sdes { 1151238106Sdes eval 'cat <<_LTECHO_EOF 1152238106Sdes$[]1 1153238106Sdes_LTECHO_EOF' 1154238106Sdes } 1155238106Sdes ECHO='func_fallback_echo' 1156238106Sdesfi 1157238106Sdes 1158238106Sdes# func_echo_all arg... 1159238106Sdes# Invoke $ECHO with all args, space-separated. 1160238106Sdesfunc_echo_all () 1161238106Sdes{ 1162238106Sdes $ECHO "$*" 1163238106Sdes} 1164238106Sdes 1165238106Sdescase "$ECHO" in 1166238106Sdes printf*) AC_MSG_RESULT([printf]) ;; 1167238106Sdes print*) AC_MSG_RESULT([print -r]) ;; 1168238106Sdes *) AC_MSG_RESULT([cat]) ;; 1169238106Sdesesac 1170238106Sdes 1171238106Sdesm4_ifdef([_AS_DETECT_SUGGESTED], 1172238106Sdes[_AS_DETECT_SUGGESTED([ 1173238106Sdes test -n "${ZSH_VERSION+set}${BASH_VERSION+set}" || ( 1174238106Sdes ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' 1175238106Sdes ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO 1176238106Sdes ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO 1177238106Sdes PATH=/empty FPATH=/empty; export PATH FPATH 1178238106Sdes test "X`printf %s $ECHO`" = "X$ECHO" \ 1179238106Sdes || test "X`print -r -- $ECHO`" = "X$ECHO" )])]) 1180238106Sdes 1181238106Sdes_LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts]) 1182238106Sdes_LT_DECL([], [ECHO], [1], [An echo program that protects backslashes]) 1183238106Sdes])# _LT_PROG_ECHO_BACKSLASH 1184238106Sdes 1185238106Sdes 1186238106Sdes# _LT_WITH_SYSROOT 1187238106Sdes# ---------------- 1188238106SdesAC_DEFUN([_LT_WITH_SYSROOT], 1189238106Sdes[AC_MSG_CHECKING([for sysroot]) 1190238106SdesAC_ARG_WITH([sysroot], 1191238106Sdes[ --with-sysroot[=DIR] Search for dependent libraries within DIR 1192238106Sdes (or the compiler's sysroot if not specified).], 1193238106Sdes[], [with_sysroot=no]) 1194238106Sdes 1195238106Sdesdnl lt_sysroot will always be passed unquoted. We quote it here 1196238106Sdesdnl in case the user passed a directory name. 1197238106Sdeslt_sysroot= 1198238106Sdescase ${with_sysroot} in #( 1199238106Sdes yes) 1200238106Sdes if test "$GCC" = yes; then 1201238106Sdes lt_sysroot=`$CC --print-sysroot 2>/dev/null` 1202238106Sdes fi 1203238106Sdes ;; #( 1204238106Sdes /*) 1205238106Sdes lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"` 1206238106Sdes ;; #( 1207238106Sdes no|'') 1208238106Sdes ;; #( 1209238106Sdes *) 1210238106Sdes AC_MSG_RESULT([${with_sysroot}]) 1211238106Sdes AC_MSG_ERROR([The sysroot must be an absolute path.]) 1212238106Sdes ;; 1213238106Sdesesac 1214238106Sdes 1215238106Sdes AC_MSG_RESULT([${lt_sysroot:-no}]) 1216238106Sdes_LT_DECL([], [lt_sysroot], [0], [The root where to search for ]dnl 1217238106Sdes[dependent libraries, and in which our libraries should be installed.])]) 1218238106Sdes 1219238106Sdes# _LT_ENABLE_LOCK 1220238106Sdes# --------------- 1221238106Sdesm4_defun([_LT_ENABLE_LOCK], 1222238106Sdes[AC_ARG_ENABLE([libtool-lock], 1223238106Sdes [AS_HELP_STRING([--disable-libtool-lock], 1224238106Sdes [avoid locking (might break parallel builds)])]) 1225238106Sdestest "x$enable_libtool_lock" != xno && enable_libtool_lock=yes 1226238106Sdes 1227238106Sdes# Some flags need to be propagated to the compiler or linker for good 1228238106Sdes# libtool support. 1229238106Sdescase $host in 1230238106Sdesia64-*-hpux*) 1231238106Sdes # Find out which ABI we are using. 1232238106Sdes echo 'int i;' > conftest.$ac_ext 1233238106Sdes if AC_TRY_EVAL(ac_compile); then 1234238106Sdes case `/usr/bin/file conftest.$ac_objext` in 1235238106Sdes *ELF-32*) 1236238106Sdes HPUX_IA64_MODE="32" 1237238106Sdes ;; 1238238106Sdes *ELF-64*) 1239238106Sdes HPUX_IA64_MODE="64" 1240238106Sdes ;; 1241238106Sdes esac 1242238106Sdes fi 1243238106Sdes rm -rf conftest* 1244238106Sdes ;; 1245238106Sdes*-*-irix6*) 1246238106Sdes # Find out which ABI we are using. 1247238106Sdes echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext 1248238106Sdes if AC_TRY_EVAL(ac_compile); then 1249238106Sdes if test "$lt_cv_prog_gnu_ld" = yes; then 1250238106Sdes case `/usr/bin/file conftest.$ac_objext` in 1251238106Sdes *32-bit*) 1252238106Sdes LD="${LD-ld} -melf32bsmip" 1253238106Sdes ;; 1254238106Sdes *N32*) 1255238106Sdes LD="${LD-ld} -melf32bmipn32" 1256238106Sdes ;; 1257238106Sdes *64-bit*) 1258238106Sdes LD="${LD-ld} -melf64bmip" 1259238106Sdes ;; 1260238106Sdes esac 1261238106Sdes else 1262238106Sdes case `/usr/bin/file conftest.$ac_objext` in 1263238106Sdes *32-bit*) 1264238106Sdes LD="${LD-ld} -32" 1265238106Sdes ;; 1266238106Sdes *N32*) 1267238106Sdes LD="${LD-ld} -n32" 1268238106Sdes ;; 1269238106Sdes *64-bit*) 1270238106Sdes LD="${LD-ld} -64" 1271238106Sdes ;; 1272238106Sdes esac 1273238106Sdes fi 1274238106Sdes fi 1275238106Sdes rm -rf conftest* 1276238106Sdes ;; 1277238106Sdes 1278238106Sdesx86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \ 1279238106Sdess390*-*linux*|s390*-*tpf*|sparc*-*linux*) 1280238106Sdes # Find out which ABI we are using. 1281238106Sdes echo 'int i;' > conftest.$ac_ext 1282238106Sdes if AC_TRY_EVAL(ac_compile); then 1283238106Sdes case `/usr/bin/file conftest.o` in 1284238106Sdes *32-bit*) 1285238106Sdes case $host in 1286238106Sdes x86_64-*kfreebsd*-gnu) 1287238106Sdes LD="${LD-ld} -m elf_i386_fbsd" 1288238106Sdes ;; 1289238106Sdes x86_64-*linux*) 1290238106Sdes LD="${LD-ld} -m elf_i386" 1291238106Sdes ;; 1292238106Sdes ppc64-*linux*|powerpc64-*linux*) 1293238106Sdes LD="${LD-ld} -m elf32ppclinux" 1294238106Sdes ;; 1295238106Sdes s390x-*linux*) 1296238106Sdes LD="${LD-ld} -m elf_s390" 1297238106Sdes ;; 1298238106Sdes sparc64-*linux*) 1299238106Sdes LD="${LD-ld} -m elf32_sparc" 1300238106Sdes ;; 1301238106Sdes esac 1302238106Sdes ;; 1303238106Sdes *64-bit*) 1304238106Sdes case $host in 1305238106Sdes x86_64-*kfreebsd*-gnu) 1306238106Sdes LD="${LD-ld} -m elf_x86_64_fbsd" 1307238106Sdes ;; 1308238106Sdes x86_64-*linux*) 1309238106Sdes LD="${LD-ld} -m elf_x86_64" 1310238106Sdes ;; 1311238106Sdes ppc*-*linux*|powerpc*-*linux*) 1312238106Sdes LD="${LD-ld} -m elf64ppc" 1313238106Sdes ;; 1314238106Sdes s390*-*linux*|s390*-*tpf*) 1315238106Sdes LD="${LD-ld} -m elf64_s390" 1316238106Sdes ;; 1317238106Sdes sparc*-*linux*) 1318238106Sdes LD="${LD-ld} -m elf64_sparc" 1319238106Sdes ;; 1320238106Sdes esac 1321238106Sdes ;; 1322238106Sdes esac 1323238106Sdes fi 1324238106Sdes rm -rf conftest* 1325238106Sdes ;; 1326238106Sdes 1327238106Sdes*-*-sco3.2v5*) 1328238106Sdes # On SCO OpenServer 5, we need -belf to get full-featured binaries. 1329238106Sdes SAVE_CFLAGS="$CFLAGS" 1330238106Sdes CFLAGS="$CFLAGS -belf" 1331238106Sdes AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf, 1332238106Sdes [AC_LANG_PUSH(C) 1333238106Sdes AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no]) 1334238106Sdes AC_LANG_POP]) 1335238106Sdes if test x"$lt_cv_cc_needs_belf" != x"yes"; then 1336238106Sdes # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf 1337238106Sdes CFLAGS="$SAVE_CFLAGS" 1338238106Sdes fi 1339238106Sdes ;; 1340238106Sdessparc*-*solaris*) 1341238106Sdes # Find out which ABI we are using. 1342238106Sdes echo 'int i;' > conftest.$ac_ext 1343238106Sdes if AC_TRY_EVAL(ac_compile); then 1344238106Sdes case `/usr/bin/file conftest.o` in 1345238106Sdes *64-bit*) 1346238106Sdes case $lt_cv_prog_gnu_ld in 1347238106Sdes yes*) LD="${LD-ld} -m elf64_sparc" ;; 1348238106Sdes *) 1349238106Sdes if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then 1350238106Sdes LD="${LD-ld} -64" 1351238106Sdes fi 1352238106Sdes ;; 1353238106Sdes esac 1354238106Sdes ;; 1355238106Sdes esac 1356238106Sdes fi 1357238106Sdes rm -rf conftest* 1358238106Sdes ;; 1359238106Sdesesac 1360238106Sdes 1361238106Sdesneed_locks="$enable_libtool_lock" 1362238106Sdes])# _LT_ENABLE_LOCK 1363238106Sdes 1364238106Sdes 1365238106Sdes# _LT_PROG_AR 1366238106Sdes# ----------- 1367238106Sdesm4_defun([_LT_PROG_AR], 1368238106Sdes[AC_CHECK_TOOLS(AR, [ar], false) 1369238106Sdes: ${AR=ar} 1370238106Sdes: ${AR_FLAGS=cru} 1371238106Sdes_LT_DECL([], [AR], [1], [The archiver]) 1372238106Sdes_LT_DECL([], [AR_FLAGS], [1], [Flags to create an archive]) 1373238106Sdes 1374238106SdesAC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file], 1375238106Sdes [lt_cv_ar_at_file=no 1376238106Sdes AC_COMPILE_IFELSE([AC_LANG_PROGRAM], 1377238106Sdes [echo conftest.$ac_objext > conftest.lst 1378238106Sdes lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&AS_MESSAGE_LOG_FD' 1379238106Sdes AC_TRY_EVAL([lt_ar_try]) 1380238106Sdes if test "$ac_status" -eq 0; then 1381238106Sdes # Ensure the archiver fails upon bogus file names. 1382238106Sdes rm -f conftest.$ac_objext libconftest.a 1383238106Sdes AC_TRY_EVAL([lt_ar_try]) 1384238106Sdes if test "$ac_status" -ne 0; then 1385238106Sdes lt_cv_ar_at_file=@ 1386238106Sdes fi 1387238106Sdes fi 1388238106Sdes rm -f conftest.* libconftest.a 1389238106Sdes ]) 1390238106Sdes ]) 1391238106Sdes 1392238106Sdesif test "x$lt_cv_ar_at_file" = xno; then 1393238106Sdes archiver_list_spec= 1394238106Sdeselse 1395238106Sdes archiver_list_spec=$lt_cv_ar_at_file 1396238106Sdesfi 1397238106Sdes_LT_DECL([], [archiver_list_spec], [1], 1398238106Sdes [How to feed a file listing to the archiver]) 1399238106Sdes])# _LT_PROG_AR 1400238106Sdes 1401238106Sdes 1402238106Sdes# _LT_CMD_OLD_ARCHIVE 1403238106Sdes# ------------------- 1404238106Sdesm4_defun([_LT_CMD_OLD_ARCHIVE], 1405238106Sdes[_LT_PROG_AR 1406238106Sdes 1407238106SdesAC_CHECK_TOOL(STRIP, strip, :) 1408238106Sdestest -z "$STRIP" && STRIP=: 1409238106Sdes_LT_DECL([], [STRIP], [1], [A symbol stripping program]) 1410238106Sdes 1411238106SdesAC_CHECK_TOOL(RANLIB, ranlib, :) 1412238106Sdestest -z "$RANLIB" && RANLIB=: 1413238106Sdes_LT_DECL([], [RANLIB], [1], 1414238106Sdes [Commands used to install an old-style archive]) 1415238106Sdes 1416238106Sdes# Determine commands to create old-style static archives. 1417238106Sdesold_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' 1418238106Sdesold_postinstall_cmds='chmod 644 $oldlib' 1419238106Sdesold_postuninstall_cmds= 1420238106Sdes 1421238106Sdesif test -n "$RANLIB"; then 1422238106Sdes case $host_os in 1423238106Sdes openbsd*) 1424238106Sdes old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib" 1425238106Sdes ;; 1426238106Sdes *) 1427238106Sdes old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib" 1428238106Sdes ;; 1429238106Sdes esac 1430238106Sdes old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib" 1431238106Sdesfi 1432238106Sdes 1433238106Sdescase $host_os in 1434238106Sdes darwin*) 1435238106Sdes lock_old_archive_extraction=yes ;; 1436238106Sdes *) 1437238106Sdes lock_old_archive_extraction=no ;; 1438238106Sdesesac 1439238106Sdes_LT_DECL([], [old_postinstall_cmds], [2]) 1440238106Sdes_LT_DECL([], [old_postuninstall_cmds], [2]) 1441238106Sdes_LT_TAGDECL([], [old_archive_cmds], [2], 1442238106Sdes [Commands used to build an old-style archive]) 1443238106Sdes_LT_DECL([], [lock_old_archive_extraction], [0], 1444238106Sdes [Whether to use a lock for old archive extraction]) 1445238106Sdes])# _LT_CMD_OLD_ARCHIVE 1446238106Sdes 1447238106Sdes 1448238106Sdes# _LT_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, 1449238106Sdes# [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE]) 1450238106Sdes# ---------------------------------------------------------------- 1451238106Sdes# Check whether the given compiler option works 1452238106SdesAC_DEFUN([_LT_COMPILER_OPTION], 1453238106Sdes[m4_require([_LT_FILEUTILS_DEFAULTS])dnl 1454238106Sdesm4_require([_LT_DECL_SED])dnl 1455238106SdesAC_CACHE_CHECK([$1], [$2], 1456238106Sdes [$2=no 1457238106Sdes m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4]) 1458238106Sdes echo "$lt_simple_compile_test_code" > conftest.$ac_ext 1459238106Sdes lt_compiler_flag="$3" 1460238106Sdes # Insert the option either (1) after the last *FLAGS variable, or 1461238106Sdes # (2) before a word containing "conftest.", or (3) at the end. 1462238106Sdes # Note that $ac_compile itself does not contain backslashes and begins 1463238106Sdes # with a dollar sign (not a hyphen), so the echo should work correctly. 1464238106Sdes # The option is referenced via a variable to avoid confusing sed. 1465238106Sdes lt_compile=`echo "$ac_compile" | $SED \ 1466238106Sdes -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ 1467238106Sdes -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ 1468238106Sdes -e 's:$: $lt_compiler_flag:'` 1469238106Sdes (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD) 1470238106Sdes (eval "$lt_compile" 2>conftest.err) 1471238106Sdes ac_status=$? 1472238106Sdes cat conftest.err >&AS_MESSAGE_LOG_FD 1473238106Sdes echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD 1474238106Sdes if (exit $ac_status) && test -s "$ac_outfile"; then 1475238106Sdes # The compiler can only warn and ignore the option if not recognized 1476238106Sdes # So say no if there are warnings other than the usual output. 1477238106Sdes $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp 1478238106Sdes $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 1479238106Sdes if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then 1480238106Sdes $2=yes 1481238106Sdes fi 1482238106Sdes fi 1483238106Sdes $RM conftest* 1484238106Sdes]) 1485238106Sdes 1486238106Sdesif test x"[$]$2" = xyes; then 1487238106Sdes m4_if([$5], , :, [$5]) 1488238106Sdeselse 1489238106Sdes m4_if([$6], , :, [$6]) 1490238106Sdesfi 1491238106Sdes])# _LT_COMPILER_OPTION 1492238106Sdes 1493238106Sdes# Old name: 1494238106SdesAU_ALIAS([AC_LIBTOOL_COMPILER_OPTION], [_LT_COMPILER_OPTION]) 1495238106Sdesdnl aclocal-1.4 backwards compatibility: 1496238106Sdesdnl AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], []) 1497238106Sdes 1498238106Sdes 1499238106Sdes# _LT_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, 1500238106Sdes# [ACTION-SUCCESS], [ACTION-FAILURE]) 1501238106Sdes# ---------------------------------------------------- 1502238106Sdes# Check whether the given linker option works 1503238106SdesAC_DEFUN([_LT_LINKER_OPTION], 1504238106Sdes[m4_require([_LT_FILEUTILS_DEFAULTS])dnl 1505238106Sdesm4_require([_LT_DECL_SED])dnl 1506238106SdesAC_CACHE_CHECK([$1], [$2], 1507238106Sdes [$2=no 1508238106Sdes save_LDFLAGS="$LDFLAGS" 1509238106Sdes LDFLAGS="$LDFLAGS $3" 1510238106Sdes echo "$lt_simple_link_test_code" > conftest.$ac_ext 1511238106Sdes if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then 1512238106Sdes # The linker can only warn and ignore the option if not recognized 1513238106Sdes # So say no if there are warnings 1514238106Sdes if test -s conftest.err; then 1515238106Sdes # Append any errors to the config.log. 1516238106Sdes cat conftest.err 1>&AS_MESSAGE_LOG_FD 1517238106Sdes $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp 1518238106Sdes $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 1519238106Sdes if diff conftest.exp conftest.er2 >/dev/null; then 1520238106Sdes $2=yes 1521238106Sdes fi 1522238106Sdes else 1523238106Sdes $2=yes 1524238106Sdes fi 1525238106Sdes fi 1526238106Sdes $RM -r conftest* 1527238106Sdes LDFLAGS="$save_LDFLAGS" 1528238106Sdes]) 1529238106Sdes 1530238106Sdesif test x"[$]$2" = xyes; then 1531238106Sdes m4_if([$4], , :, [$4]) 1532238106Sdeselse 1533238106Sdes m4_if([$5], , :, [$5]) 1534238106Sdesfi 1535238106Sdes])# _LT_LINKER_OPTION 1536238106Sdes 1537238106Sdes# Old name: 1538238106SdesAU_ALIAS([AC_LIBTOOL_LINKER_OPTION], [_LT_LINKER_OPTION]) 1539238106Sdesdnl aclocal-1.4 backwards compatibility: 1540238106Sdesdnl AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], []) 1541238106Sdes 1542238106Sdes 1543238106Sdes# LT_CMD_MAX_LEN 1544238106Sdes#--------------- 1545238106SdesAC_DEFUN([LT_CMD_MAX_LEN], 1546238106Sdes[AC_REQUIRE([AC_CANONICAL_HOST])dnl 1547238106Sdes# find the maximum length of command line arguments 1548238106SdesAC_MSG_CHECKING([the maximum length of command line arguments]) 1549238106SdesAC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl 1550238106Sdes i=0 1551238106Sdes teststring="ABCD" 1552238106Sdes 1553238106Sdes case $build_os in 1554238106Sdes msdosdjgpp*) 1555238106Sdes # On DJGPP, this test can blow up pretty badly due to problems in libc 1556238106Sdes # (any single argument exceeding 2000 bytes causes a buffer overrun 1557238106Sdes # during glob expansion). Even if it were fixed, the result of this 1558238106Sdes # check would be larger than it should be. 1559238106Sdes lt_cv_sys_max_cmd_len=12288; # 12K is about right 1560238106Sdes ;; 1561238106Sdes 1562238106Sdes gnu*) 1563238106Sdes # Under GNU Hurd, this test is not required because there is 1564238106Sdes # no limit to the length of command line arguments. 1565238106Sdes # Libtool will interpret -1 as no limit whatsoever 1566238106Sdes lt_cv_sys_max_cmd_len=-1; 1567238106Sdes ;; 1568238106Sdes 1569238106Sdes cygwin* | mingw* | cegcc*) 1570238106Sdes # On Win9x/ME, this test blows up -- it succeeds, but takes 1571238106Sdes # about 5 minutes as the teststring grows exponentially. 1572238106Sdes # Worse, since 9x/ME are not pre-emptively multitasking, 1573238106Sdes # you end up with a "frozen" computer, even though with patience 1574238106Sdes # the test eventually succeeds (with a max line length of 256k). 1575238106Sdes # Instead, let's just punt: use the minimum linelength reported by 1576238106Sdes # all of the supported platforms: 8192 (on NT/2K/XP). 1577238106Sdes lt_cv_sys_max_cmd_len=8192; 1578238106Sdes ;; 1579238106Sdes 1580238106Sdes mint*) 1581238106Sdes # On MiNT this can take a long time and run out of memory. 1582238106Sdes lt_cv_sys_max_cmd_len=8192; 1583238106Sdes ;; 1584238106Sdes 1585238106Sdes amigaos*) 1586238106Sdes # On AmigaOS with pdksh, this test takes hours, literally. 1587238106Sdes # So we just punt and use a minimum line length of 8192. 1588238106Sdes lt_cv_sys_max_cmd_len=8192; 1589238106Sdes ;; 1590238106Sdes 1591238106Sdes netbsd* | freebsd* | openbsd* | darwin* | dragonfly*) 1592238106Sdes # This has been around since 386BSD, at least. Likely further. 1593238106Sdes if test -x /sbin/sysctl; then 1594238106Sdes lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` 1595238106Sdes elif test -x /usr/sbin/sysctl; then 1596238106Sdes lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` 1597238106Sdes else 1598238106Sdes lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs 1599238106Sdes fi 1600238106Sdes # And add a safety zone 1601238106Sdes lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` 1602238106Sdes lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` 1603238106Sdes ;; 1604238106Sdes 1605238106Sdes interix*) 1606238106Sdes # We know the value 262144 and hardcode it with a safety zone (like BSD) 1607238106Sdes lt_cv_sys_max_cmd_len=196608 1608238106Sdes ;; 1609238106Sdes 1610238106Sdes osf*) 1611238106Sdes # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure 1612238106Sdes # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not 1613238106Sdes # nice to cause kernel panics so lets avoid the loop below. 1614238106Sdes # First set a reasonable default. 1615238106Sdes lt_cv_sys_max_cmd_len=16384 1616238106Sdes # 1617238106Sdes if test -x /sbin/sysconfig; then 1618238106Sdes case `/sbin/sysconfig -q proc exec_disable_arg_limit` in 1619238106Sdes *1*) lt_cv_sys_max_cmd_len=-1 ;; 1620238106Sdes esac 1621238106Sdes fi 1622238106Sdes ;; 1623238106Sdes sco3.2v5*) 1624238106Sdes lt_cv_sys_max_cmd_len=102400 1625238106Sdes ;; 1626238106Sdes sysv5* | sco5v6* | sysv4.2uw2*) 1627238106Sdes kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` 1628238106Sdes if test -n "$kargmax"; then 1629238106Sdes lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'` 1630238106Sdes else 1631238106Sdes lt_cv_sys_max_cmd_len=32768 1632238106Sdes fi 1633238106Sdes ;; 1634238106Sdes *) 1635238106Sdes lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` 1636238106Sdes if test -n "$lt_cv_sys_max_cmd_len"; then 1637238106Sdes lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` 1638238106Sdes lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` 1639238106Sdes else 1640238106Sdes # Make teststring a little bigger before we do anything with it. 1641238106Sdes # a 1K string should be a reasonable start. 1642238106Sdes for i in 1 2 3 4 5 6 7 8 ; do 1643238106Sdes teststring=$teststring$teststring 1644238106Sdes done 1645238106Sdes SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} 1646238106Sdes # If test is not a shell built-in, we'll probably end up computing a 1647238106Sdes # maximum length that is only half of the actual maximum length, but 1648238106Sdes # we can't tell. 1649238106Sdes while { test "X"`func_fallback_echo "$teststring$teststring" 2>/dev/null` \ 1650238106Sdes = "X$teststring$teststring"; } >/dev/null 2>&1 && 1651238106Sdes test $i != 17 # 1/2 MB should be enough 1652238106Sdes do 1653238106Sdes i=`expr $i + 1` 1654238106Sdes teststring=$teststring$teststring 1655238106Sdes done 1656238106Sdes # Only check the string length outside the loop. 1657238106Sdes lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1` 1658238106Sdes teststring= 1659238106Sdes # Add a significant safety factor because C++ compilers can tack on 1660238106Sdes # massive amounts of additional arguments before passing them to the 1661238106Sdes # linker. It appears as though 1/2 is a usable value. 1662238106Sdes lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` 1663238106Sdes fi 1664238106Sdes ;; 1665238106Sdes esac 1666238106Sdes]) 1667238106Sdesif test -n $lt_cv_sys_max_cmd_len ; then 1668238106Sdes AC_MSG_RESULT($lt_cv_sys_max_cmd_len) 1669238106Sdeselse 1670238106Sdes AC_MSG_RESULT(none) 1671238106Sdesfi 1672238106Sdesmax_cmd_len=$lt_cv_sys_max_cmd_len 1673238106Sdes_LT_DECL([], [max_cmd_len], [0], 1674238106Sdes [What is the maximum length of a command?]) 1675238106Sdes])# LT_CMD_MAX_LEN 1676238106Sdes 1677238106Sdes# Old name: 1678238106SdesAU_ALIAS([AC_LIBTOOL_SYS_MAX_CMD_LEN], [LT_CMD_MAX_LEN]) 1679238106Sdesdnl aclocal-1.4 backwards compatibility: 1680238106Sdesdnl AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], []) 1681238106Sdes 1682238106Sdes 1683238106Sdes# _LT_HEADER_DLFCN 1684238106Sdes# ---------------- 1685238106Sdesm4_defun([_LT_HEADER_DLFCN], 1686238106Sdes[AC_CHECK_HEADERS([dlfcn.h], [], [], [AC_INCLUDES_DEFAULT])dnl 1687238106Sdes])# _LT_HEADER_DLFCN 1688238106Sdes 1689238106Sdes 1690238106Sdes# _LT_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE, 1691238106Sdes# ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING) 1692238106Sdes# ---------------------------------------------------------------- 1693238106Sdesm4_defun([_LT_TRY_DLOPEN_SELF], 1694238106Sdes[m4_require([_LT_HEADER_DLFCN])dnl 1695238106Sdesif test "$cross_compiling" = yes; then : 1696238106Sdes [$4] 1697238106Sdeselse 1698238106Sdes lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 1699238106Sdes lt_status=$lt_dlunknown 1700238106Sdes cat > conftest.$ac_ext <<_LT_EOF 1701238106Sdes[#line $LINENO "configure" 1702238106Sdes#include "confdefs.h" 1703238106Sdes 1704238106Sdes#if HAVE_DLFCN_H 1705238106Sdes#include <dlfcn.h> 1706238106Sdes#endif 1707238106Sdes 1708238106Sdes#include <stdio.h> 1709238106Sdes 1710238106Sdes#ifdef RTLD_GLOBAL 1711238106Sdes# define LT_DLGLOBAL RTLD_GLOBAL 1712238106Sdes#else 1713238106Sdes# ifdef DL_GLOBAL 1714238106Sdes# define LT_DLGLOBAL DL_GLOBAL 1715238106Sdes# else 1716238106Sdes# define LT_DLGLOBAL 0 1717238106Sdes# endif 1718238106Sdes#endif 1719238106Sdes 1720238106Sdes/* We may have to define LT_DLLAZY_OR_NOW in the command line if we 1721238106Sdes find out it does not work in some platform. */ 1722238106Sdes#ifndef LT_DLLAZY_OR_NOW 1723238106Sdes# ifdef RTLD_LAZY 1724238106Sdes# define LT_DLLAZY_OR_NOW RTLD_LAZY 1725238106Sdes# else 1726238106Sdes# ifdef DL_LAZY 1727238106Sdes# define LT_DLLAZY_OR_NOW DL_LAZY 1728238106Sdes# else 1729238106Sdes# ifdef RTLD_NOW 1730238106Sdes# define LT_DLLAZY_OR_NOW RTLD_NOW 1731238106Sdes# else 1732238106Sdes# ifdef DL_NOW 1733238106Sdes# define LT_DLLAZY_OR_NOW DL_NOW 1734238106Sdes# else 1735238106Sdes# define LT_DLLAZY_OR_NOW 0 1736238106Sdes# endif 1737238106Sdes# endif 1738238106Sdes# endif 1739238106Sdes# endif 1740238106Sdes#endif 1741238106Sdes 1742238106Sdes/* When -fvisbility=hidden is used, assume the code has been annotated 1743238106Sdes correspondingly for the symbols needed. */ 1744238106Sdes#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) 1745238106Sdesint fnord () __attribute__((visibility("default"))); 1746238106Sdes#endif 1747238106Sdes 1748238106Sdesint fnord () { return 42; } 1749238106Sdesint main () 1750238106Sdes{ 1751238106Sdes void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); 1752238106Sdes int status = $lt_dlunknown; 1753238106Sdes 1754238106Sdes if (self) 1755238106Sdes { 1756238106Sdes if (dlsym (self,"fnord")) status = $lt_dlno_uscore; 1757238106Sdes else 1758238106Sdes { 1759238106Sdes if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; 1760238106Sdes else puts (dlerror ()); 1761238106Sdes } 1762238106Sdes /* dlclose (self); */ 1763238106Sdes } 1764238106Sdes else 1765238106Sdes puts (dlerror ()); 1766238106Sdes 1767238106Sdes return status; 1768238106Sdes}] 1769238106Sdes_LT_EOF 1770238106Sdes if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then 1771238106Sdes (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null 1772238106Sdes lt_status=$? 1773238106Sdes case x$lt_status in 1774238106Sdes x$lt_dlno_uscore) $1 ;; 1775238106Sdes x$lt_dlneed_uscore) $2 ;; 1776238106Sdes x$lt_dlunknown|x*) $3 ;; 1777238106Sdes esac 1778238106Sdes else : 1779238106Sdes # compilation failed 1780238106Sdes $3 1781238106Sdes fi 1782238106Sdesfi 1783238106Sdesrm -fr conftest* 1784238106Sdes])# _LT_TRY_DLOPEN_SELF 1785238106Sdes 1786238106Sdes 1787238106Sdes# LT_SYS_DLOPEN_SELF 1788238106Sdes# ------------------ 1789238106SdesAC_DEFUN([LT_SYS_DLOPEN_SELF], 1790238106Sdes[m4_require([_LT_HEADER_DLFCN])dnl 1791238106Sdesif test "x$enable_dlopen" != xyes; then 1792238106Sdes enable_dlopen=unknown 1793238106Sdes enable_dlopen_self=unknown 1794238106Sdes enable_dlopen_self_static=unknown 1795238106Sdeselse 1796238106Sdes lt_cv_dlopen=no 1797238106Sdes lt_cv_dlopen_libs= 1798238106Sdes 1799238106Sdes case $host_os in 1800238106Sdes beos*) 1801238106Sdes lt_cv_dlopen="load_add_on" 1802238106Sdes lt_cv_dlopen_libs= 1803238106Sdes lt_cv_dlopen_self=yes 1804238106Sdes ;; 1805238106Sdes 1806238106Sdes mingw* | pw32* | cegcc*) 1807238106Sdes lt_cv_dlopen="LoadLibrary" 1808238106Sdes lt_cv_dlopen_libs= 1809238106Sdes ;; 1810238106Sdes 1811238106Sdes cygwin*) 1812238106Sdes lt_cv_dlopen="dlopen" 1813238106Sdes lt_cv_dlopen_libs= 1814238106Sdes ;; 1815238106Sdes 1816238106Sdes darwin*) 1817238106Sdes # if libdl is installed we need to link against it 1818238106Sdes AC_CHECK_LIB([dl], [dlopen], 1819238106Sdes [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[ 1820238106Sdes lt_cv_dlopen="dyld" 1821238106Sdes lt_cv_dlopen_libs= 1822238106Sdes lt_cv_dlopen_self=yes 1823238106Sdes ]) 1824238106Sdes ;; 1825238106Sdes 1826238106Sdes *) 1827238106Sdes AC_CHECK_FUNC([shl_load], 1828238106Sdes [lt_cv_dlopen="shl_load"], 1829238106Sdes [AC_CHECK_LIB([dld], [shl_load], 1830238106Sdes [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"], 1831238106Sdes [AC_CHECK_FUNC([dlopen], 1832238106Sdes [lt_cv_dlopen="dlopen"], 1833238106Sdes [AC_CHECK_LIB([dl], [dlopen], 1834238106Sdes [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"], 1835238106Sdes [AC_CHECK_LIB([svld], [dlopen], 1836238106Sdes [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"], 1837238106Sdes [AC_CHECK_LIB([dld], [dld_link], 1838238106Sdes [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"]) 1839238106Sdes ]) 1840238106Sdes ]) 1841238106Sdes ]) 1842238106Sdes ]) 1843238106Sdes ]) 1844238106Sdes ;; 1845238106Sdes esac 1846238106Sdes 1847238106Sdes if test "x$lt_cv_dlopen" != xno; then 1848238106Sdes enable_dlopen=yes 1849238106Sdes else 1850238106Sdes enable_dlopen=no 1851238106Sdes fi 1852238106Sdes 1853238106Sdes case $lt_cv_dlopen in 1854238106Sdes dlopen) 1855238106Sdes save_CPPFLAGS="$CPPFLAGS" 1856238106Sdes test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" 1857238106Sdes 1858238106Sdes save_LDFLAGS="$LDFLAGS" 1859238106Sdes wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" 1860238106Sdes 1861238106Sdes save_LIBS="$LIBS" 1862238106Sdes LIBS="$lt_cv_dlopen_libs $LIBS" 1863238106Sdes 1864238106Sdes AC_CACHE_CHECK([whether a program can dlopen itself], 1865238106Sdes lt_cv_dlopen_self, [dnl 1866238106Sdes _LT_TRY_DLOPEN_SELF( 1867238106Sdes lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes, 1868238106Sdes lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross) 1869238106Sdes ]) 1870238106Sdes 1871238106Sdes if test "x$lt_cv_dlopen_self" = xyes; then 1872238106Sdes wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" 1873238106Sdes AC_CACHE_CHECK([whether a statically linked program can dlopen itself], 1874238106Sdes lt_cv_dlopen_self_static, [dnl 1875238106Sdes _LT_TRY_DLOPEN_SELF( 1876238106Sdes lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes, 1877238106Sdes lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross) 1878238106Sdes ]) 1879238106Sdes fi 1880238106Sdes 1881238106Sdes CPPFLAGS="$save_CPPFLAGS" 1882238106Sdes LDFLAGS="$save_LDFLAGS" 1883238106Sdes LIBS="$save_LIBS" 1884238106Sdes ;; 1885238106Sdes esac 1886238106Sdes 1887238106Sdes case $lt_cv_dlopen_self in 1888238106Sdes yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; 1889238106Sdes *) enable_dlopen_self=unknown ;; 1890238106Sdes esac 1891238106Sdes 1892238106Sdes case $lt_cv_dlopen_self_static in 1893238106Sdes yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; 1894238106Sdes *) enable_dlopen_self_static=unknown ;; 1895238106Sdes esac 1896238106Sdesfi 1897238106Sdes_LT_DECL([dlopen_support], [enable_dlopen], [0], 1898238106Sdes [Whether dlopen is supported]) 1899238106Sdes_LT_DECL([dlopen_self], [enable_dlopen_self], [0], 1900238106Sdes [Whether dlopen of programs is supported]) 1901238106Sdes_LT_DECL([dlopen_self_static], [enable_dlopen_self_static], [0], 1902238106Sdes [Whether dlopen of statically linked programs is supported]) 1903238106Sdes])# LT_SYS_DLOPEN_SELF 1904238106Sdes 1905238106Sdes# Old name: 1906238106SdesAU_ALIAS([AC_LIBTOOL_DLOPEN_SELF], [LT_SYS_DLOPEN_SELF]) 1907238106Sdesdnl aclocal-1.4 backwards compatibility: 1908238106Sdesdnl AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], []) 1909238106Sdes 1910238106Sdes 1911238106Sdes# _LT_COMPILER_C_O([TAGNAME]) 1912238106Sdes# --------------------------- 1913238106Sdes# Check to see if options -c and -o are simultaneously supported by compiler. 1914238106Sdes# This macro does not hard code the compiler like AC_PROG_CC_C_O. 1915238106Sdesm4_defun([_LT_COMPILER_C_O], 1916238106Sdes[m4_require([_LT_DECL_SED])dnl 1917238106Sdesm4_require([_LT_FILEUTILS_DEFAULTS])dnl 1918238106Sdesm4_require([_LT_TAG_COMPILER])dnl 1919238106SdesAC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext], 1920238106Sdes [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)], 1921238106Sdes [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no 1922238106Sdes $RM -r conftest 2>/dev/null 1923238106Sdes mkdir conftest 1924238106Sdes cd conftest 1925238106Sdes mkdir out 1926238106Sdes echo "$lt_simple_compile_test_code" > conftest.$ac_ext 1927238106Sdes 1928238106Sdes lt_compiler_flag="-o out/conftest2.$ac_objext" 1929238106Sdes # Insert the option either (1) after the last *FLAGS variable, or 1930238106Sdes # (2) before a word containing "conftest.", or (3) at the end. 1931238106Sdes # Note that $ac_compile itself does not contain backslashes and begins 1932238106Sdes # with a dollar sign (not a hyphen), so the echo should work correctly. 1933238106Sdes lt_compile=`echo "$ac_compile" | $SED \ 1934238106Sdes -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ 1935238106Sdes -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ 1936238106Sdes -e 's:$: $lt_compiler_flag:'` 1937238106Sdes (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD) 1938238106Sdes (eval "$lt_compile" 2>out/conftest.err) 1939238106Sdes ac_status=$? 1940238106Sdes cat out/conftest.err >&AS_MESSAGE_LOG_FD 1941238106Sdes echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD 1942238106Sdes if (exit $ac_status) && test -s out/conftest2.$ac_objext 1943238106Sdes then 1944238106Sdes # The compiler can only warn and ignore the option if not recognized 1945238106Sdes # So say no if there are warnings 1946238106Sdes $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp 1947238106Sdes $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 1948238106Sdes if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then 1949238106Sdes _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes 1950238106Sdes fi 1951238106Sdes fi 1952238106Sdes chmod u+w . 2>&AS_MESSAGE_LOG_FD 1953238106Sdes $RM conftest* 1954238106Sdes # SGI C++ compiler will create directory out/ii_files/ for 1955238106Sdes # template instantiation 1956238106Sdes test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files 1957238106Sdes $RM out/* && rmdir out 1958238106Sdes cd .. 1959238106Sdes $RM -r conftest 1960238106Sdes $RM conftest* 1961238106Sdes]) 1962238106Sdes_LT_TAGDECL([compiler_c_o], [lt_cv_prog_compiler_c_o], [1], 1963238106Sdes [Does compiler simultaneously support -c and -o options?]) 1964238106Sdes])# _LT_COMPILER_C_O 1965238106Sdes 1966238106Sdes 1967238106Sdes# _LT_COMPILER_FILE_LOCKS([TAGNAME]) 1968238106Sdes# ---------------------------------- 1969238106Sdes# Check to see if we can do hard links to lock some files if needed 1970238106Sdesm4_defun([_LT_COMPILER_FILE_LOCKS], 1971238106Sdes[m4_require([_LT_ENABLE_LOCK])dnl 1972238106Sdesm4_require([_LT_FILEUTILS_DEFAULTS])dnl 1973238106Sdes_LT_COMPILER_C_O([$1]) 1974238106Sdes 1975238106Sdeshard_links="nottested" 1976238106Sdesif test "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then 1977238106Sdes # do not overwrite the value of need_locks provided by the user 1978238106Sdes AC_MSG_CHECKING([if we can lock with hard links]) 1979238106Sdes hard_links=yes 1980238106Sdes $RM conftest* 1981238106Sdes ln conftest.a conftest.b 2>/dev/null && hard_links=no 1982238106Sdes touch conftest.a 1983238106Sdes ln conftest.a conftest.b 2>&5 || hard_links=no 1984238106Sdes ln conftest.a conftest.b 2>/dev/null && hard_links=no 1985238106Sdes AC_MSG_RESULT([$hard_links]) 1986238106Sdes if test "$hard_links" = no; then 1987238106Sdes AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe]) 1988238106Sdes need_locks=warn 1989238106Sdes fi 1990238106Sdeselse 1991238106Sdes need_locks=no 1992238106Sdesfi 1993238106Sdes_LT_DECL([], [need_locks], [1], [Must we lock files when doing compilation?]) 1994238106Sdes])# _LT_COMPILER_FILE_LOCKS 1995238106Sdes 1996238106Sdes 1997238106Sdes# _LT_CHECK_OBJDIR 1998238106Sdes# ---------------- 1999238106Sdesm4_defun([_LT_CHECK_OBJDIR], 2000238106Sdes[AC_CACHE_CHECK([for objdir], [lt_cv_objdir], 2001238106Sdes[rm -f .libs 2>/dev/null 2002238106Sdesmkdir .libs 2>/dev/null 2003238106Sdesif test -d .libs; then 2004238106Sdes lt_cv_objdir=.libs 2005238106Sdeselse 2006238106Sdes # MS-DOS does not allow filenames that begin with a dot. 2007238106Sdes lt_cv_objdir=_libs 2008238106Sdesfi 2009238106Sdesrmdir .libs 2>/dev/null]) 2010238106Sdesobjdir=$lt_cv_objdir 2011238106Sdes_LT_DECL([], [objdir], [0], 2012238106Sdes [The name of the directory that contains temporary libtool files])dnl 2013238106Sdesm4_pattern_allow([LT_OBJDIR])dnl 2014238106SdesAC_DEFINE_UNQUOTED(LT_OBJDIR, "$lt_cv_objdir/", 2015238106Sdes [Define to the sub-directory in which libtool stores uninstalled libraries.]) 2016238106Sdes])# _LT_CHECK_OBJDIR 2017238106Sdes 2018238106Sdes 2019238106Sdes# _LT_LINKER_HARDCODE_LIBPATH([TAGNAME]) 2020238106Sdes# -------------------------------------- 2021238106Sdes# Check hardcoding attributes. 2022238106Sdesm4_defun([_LT_LINKER_HARDCODE_LIBPATH], 2023238106Sdes[AC_MSG_CHECKING([how to hardcode library paths into programs]) 2024238106Sdes_LT_TAGVAR(hardcode_action, $1)= 2025238106Sdesif test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" || 2026238106Sdes test -n "$_LT_TAGVAR(runpath_var, $1)" || 2027238106Sdes test "X$_LT_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then 2028238106Sdes 2029238106Sdes # We can hardcode non-existent directories. 2030238106Sdes if test "$_LT_TAGVAR(hardcode_direct, $1)" != no && 2031238106Sdes # If the only mechanism to avoid hardcoding is shlibpath_var, we 2032238106Sdes # have to relink, otherwise we might link with an installed library 2033238106Sdes # when we should be linking with a yet-to-be-installed one 2034238106Sdes ## test "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" != no && 2035238106Sdes test "$_LT_TAGVAR(hardcode_minus_L, $1)" != no; then 2036238106Sdes # Linking always hardcodes the temporary library directory. 2037238106Sdes _LT_TAGVAR(hardcode_action, $1)=relink 2038238106Sdes else 2039238106Sdes # We can link without hardcoding, and we can hardcode nonexisting dirs. 2040238106Sdes _LT_TAGVAR(hardcode_action, $1)=immediate 2041238106Sdes fi 2042238106Sdeselse 2043238106Sdes # We cannot hardcode anything, or else we can only hardcode existing 2044238106Sdes # directories. 2045238106Sdes _LT_TAGVAR(hardcode_action, $1)=unsupported 2046238106Sdesfi 2047238106SdesAC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)]) 2048238106Sdes 2049238106Sdesif test "$_LT_TAGVAR(hardcode_action, $1)" = relink || 2050238106Sdes test "$_LT_TAGVAR(inherit_rpath, $1)" = yes; then 2051238106Sdes # Fast installation is not supported 2052238106Sdes enable_fast_install=no 2053238106Sdeselif test "$shlibpath_overrides_runpath" = yes || 2054238106Sdes test "$enable_shared" = no; then 2055238106Sdes # Fast installation is not necessary 2056238106Sdes enable_fast_install=needless 2057238106Sdesfi 2058238106Sdes_LT_TAGDECL([], [hardcode_action], [0], 2059238106Sdes [How to hardcode a shared library path into an executable]) 2060238106Sdes])# _LT_LINKER_HARDCODE_LIBPATH 2061238106Sdes 2062238106Sdes 2063238106Sdes# _LT_CMD_STRIPLIB 2064238106Sdes# ---------------- 2065238106Sdesm4_defun([_LT_CMD_STRIPLIB], 2066238106Sdes[m4_require([_LT_DECL_EGREP]) 2067238106Sdesstriplib= 2068238106Sdesold_striplib= 2069238106SdesAC_MSG_CHECKING([whether stripping libraries is possible]) 2070238106Sdesif test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then 2071238106Sdes test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" 2072238106Sdes test -z "$striplib" && striplib="$STRIP --strip-unneeded" 2073238106Sdes AC_MSG_RESULT([yes]) 2074238106Sdeselse 2075238106Sdes# FIXME - insert some real tests, host_os isn't really good enough 2076238106Sdes case $host_os in 2077238106Sdes darwin*) 2078238106Sdes if test -n "$STRIP" ; then 2079238106Sdes striplib="$STRIP -x" 2080238106Sdes old_striplib="$STRIP -S" 2081238106Sdes AC_MSG_RESULT([yes]) 2082238106Sdes else 2083238106Sdes AC_MSG_RESULT([no]) 2084238106Sdes fi 2085238106Sdes ;; 2086238106Sdes *) 2087238106Sdes AC_MSG_RESULT([no]) 2088238106Sdes ;; 2089238106Sdes esac 2090238106Sdesfi 2091238106Sdes_LT_DECL([], [old_striplib], [1], [Commands to strip libraries]) 2092238106Sdes_LT_DECL([], [striplib], [1]) 2093238106Sdes])# _LT_CMD_STRIPLIB 2094238106Sdes 2095238106Sdes 2096238106Sdes# _LT_SYS_DYNAMIC_LINKER([TAG]) 2097238106Sdes# ----------------------------- 2098238106Sdes# PORTME Fill in your ld.so characteristics 2099238106Sdesm4_defun([_LT_SYS_DYNAMIC_LINKER], 2100238106Sdes[AC_REQUIRE([AC_CANONICAL_HOST])dnl 2101238106Sdesm4_require([_LT_DECL_EGREP])dnl 2102238106Sdesm4_require([_LT_FILEUTILS_DEFAULTS])dnl 2103238106Sdesm4_require([_LT_DECL_OBJDUMP])dnl 2104238106Sdesm4_require([_LT_DECL_SED])dnl 2105238106Sdesm4_require([_LT_CHECK_SHELL_FEATURES])dnl 2106238106SdesAC_MSG_CHECKING([dynamic linker characteristics]) 2107238106Sdesm4_if([$1], 2108238106Sdes [], [ 2109238106Sdesif test "$GCC" = yes; then 2110238106Sdes case $host_os in 2111238106Sdes darwin*) lt_awk_arg="/^libraries:/,/LR/" ;; 2112238106Sdes *) lt_awk_arg="/^libraries:/" ;; 2113238106Sdes esac 2114238106Sdes case $host_os in 2115238106Sdes mingw* | cegcc*) lt_sed_strip_eq="s,=\([[A-Za-z]]:\),\1,g" ;; 2116238106Sdes *) lt_sed_strip_eq="s,=/,/,g" ;; 2117238106Sdes esac 2118238106Sdes lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq` 2119238106Sdes case $lt_search_path_spec in 2120238106Sdes *\;*) 2121238106Sdes # if the path contains ";" then we assume it to be the separator 2122238106Sdes # otherwise default to the standard path separator (i.e. ":") - it is 2123238106Sdes # assumed that no part of a normal pathname contains ";" but that should 2124238106Sdes # okay in the real world where ";" in dirpaths is itself problematic. 2125238106Sdes lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'` 2126238106Sdes ;; 2127238106Sdes *) 2128238106Sdes lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"` 2129238106Sdes ;; 2130238106Sdes esac 2131238106Sdes # Ok, now we have the path, separated by spaces, we can step through it 2132238106Sdes # and add multilib dir if necessary. 2133238106Sdes lt_tmp_lt_search_path_spec= 2134238106Sdes lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` 2135238106Sdes for lt_sys_path in $lt_search_path_spec; do 2136238106Sdes if test -d "$lt_sys_path/$lt_multi_os_dir"; then 2137238106Sdes lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir" 2138238106Sdes else 2139238106Sdes test -d "$lt_sys_path" && \ 2140238106Sdes lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" 2141238106Sdes fi 2142238106Sdes done 2143238106Sdes lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk ' 2144238106SdesBEGIN {RS=" "; FS="/|\n";} { 2145238106Sdes lt_foo=""; 2146238106Sdes lt_count=0; 2147238106Sdes for (lt_i = NF; lt_i > 0; lt_i--) { 2148238106Sdes if ($lt_i != "" && $lt_i != ".") { 2149238106Sdes if ($lt_i == "..") { 2150238106Sdes lt_count++; 2151238106Sdes } else { 2152238106Sdes if (lt_count == 0) { 2153238106Sdes lt_foo="/" $lt_i lt_foo; 2154238106Sdes } else { 2155238106Sdes lt_count--; 2156238106Sdes } 2157238106Sdes } 2158238106Sdes } 2159238106Sdes } 2160238106Sdes if (lt_foo != "") { lt_freq[[lt_foo]]++; } 2161238106Sdes if (lt_freq[[lt_foo]] == 1) { print lt_foo; } 2162238106Sdes}'` 2163238106Sdes # AWK program above erroneously prepends '/' to C:/dos/paths 2164238106Sdes # for these hosts. 2165238106Sdes case $host_os in 2166238106Sdes mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ 2167238106Sdes $SED 's,/\([[A-Za-z]]:\),\1,g'` ;; 2168238106Sdes esac 2169238106Sdes sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP` 2170238106Sdeselse 2171238106Sdes sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" 2172238106Sdesfi]) 2173238106Sdeslibrary_names_spec= 2174238106Sdeslibname_spec='lib$name' 2175238106Sdessoname_spec= 2176238106Sdesshrext_cmds=".so" 2177238106Sdespostinstall_cmds= 2178238106Sdespostuninstall_cmds= 2179238106Sdesfinish_cmds= 2180238106Sdesfinish_eval= 2181238106Sdesshlibpath_var= 2182238106Sdesshlibpath_overrides_runpath=unknown 2183238106Sdesversion_type=none 2184238106Sdesdynamic_linker="$host_os ld.so" 2185238106Sdessys_lib_dlsearch_path_spec="/lib /usr/lib" 2186238106Sdesneed_lib_prefix=unknown 2187238106Sdeshardcode_into_libs=no 2188238106Sdes 2189238106Sdes# when you set need_version to no, make sure it does not cause -set_version 2190238106Sdes# flags to be left without arguments 2191238106Sdesneed_version=unknown 2192238106Sdes 2193238106Sdescase $host_os in 2194238106Sdesaix3*) 2195238106Sdes version_type=linux 2196238106Sdes library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' 2197238106Sdes shlibpath_var=LIBPATH 2198238106Sdes 2199238106Sdes # AIX 3 has no versioning support, so we append a major version to the name. 2200238106Sdes soname_spec='${libname}${release}${shared_ext}$major' 2201238106Sdes ;; 2202238106Sdes 2203238106Sdesaix[[4-9]]*) 2204238106Sdes version_type=linux 2205238106Sdes need_lib_prefix=no 2206238106Sdes need_version=no 2207238106Sdes hardcode_into_libs=yes 2208238106Sdes if test "$host_cpu" = ia64; then 2209238106Sdes # AIX 5 supports IA64 2210238106Sdes library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' 2211238106Sdes shlibpath_var=LD_LIBRARY_PATH 2212238106Sdes else 2213238106Sdes # With GCC up to 2.95.x, collect2 would create an import file 2214238106Sdes # for dependence libraries. The import file would start with 2215238106Sdes # the line `#! .'. This would cause the generated library to 2216238106Sdes # depend on `.', always an invalid library. This was fixed in 2217238106Sdes # development snapshots of GCC prior to 3.0. 2218238106Sdes case $host_os in 2219238106Sdes aix4 | aix4.[[01]] | aix4.[[01]].*) 2220238106Sdes if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' 2221238106Sdes echo ' yes ' 2222238106Sdes echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then 2223238106Sdes : 2224238106Sdes else 2225238106Sdes can_build_shared=no 2226238106Sdes fi 2227238106Sdes ;; 2228238106Sdes esac 2229238106Sdes # AIX (on Power*) has no versioning support, so currently we can not hardcode correct 2230238106Sdes # soname into executable. Probably we can add versioning support to 2231238106Sdes # collect2, so additional links can be useful in future. 2232238106Sdes if test "$aix_use_runtimelinking" = yes; then 2233238106Sdes # If using run time linking (on AIX 4.2 or later) use lib<name>.so 2234238106Sdes # instead of lib<name>.a to let people know that these are not 2235238106Sdes # typical AIX shared libraries. 2236238106Sdes library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 2237238106Sdes else 2238238106Sdes # We preserve .a as extension for shared libraries through AIX4.2 2239238106Sdes # and later when we are not doing run time linking. 2240238106Sdes library_names_spec='${libname}${release}.a $libname.a' 2241238106Sdes soname_spec='${libname}${release}${shared_ext}$major' 2242238106Sdes fi 2243238106Sdes shlibpath_var=LIBPATH 2244238106Sdes fi 2245238106Sdes ;; 2246238106Sdes 2247238106Sdesamigaos*) 2248238106Sdes case $host_cpu in 2249238106Sdes powerpc) 2250238106Sdes # Since July 2007 AmigaOS4 officially supports .so libraries. 2251238106Sdes # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. 2252238106Sdes library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 2253238106Sdes ;; 2254238106Sdes m68k) 2255238106Sdes library_names_spec='$libname.ixlibrary $libname.a' 2256238106Sdes # Create ${libname}_ixlibrary.a entries in /sys/libs. 2257238106Sdes finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' 2258238106Sdes ;; 2259238106Sdes esac 2260238106Sdes ;; 2261238106Sdes 2262238106Sdesbeos*) 2263238106Sdes library_names_spec='${libname}${shared_ext}' 2264238106Sdes dynamic_linker="$host_os ld.so" 2265238106Sdes shlibpath_var=LIBRARY_PATH 2266238106Sdes ;; 2267238106Sdes 2268238106Sdesbsdi[[45]]*) 2269238106Sdes version_type=linux 2270238106Sdes need_version=no 2271238106Sdes library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 2272238106Sdes soname_spec='${libname}${release}${shared_ext}$major' 2273238106Sdes finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' 2274238106Sdes shlibpath_var=LD_LIBRARY_PATH 2275238106Sdes sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" 2276238106Sdes sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" 2277238106Sdes # the default ld.so.conf also contains /usr/contrib/lib and 2278238106Sdes # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow 2279238106Sdes # libtool to hard-code these into programs 2280238106Sdes ;; 2281238106Sdes 2282238106Sdescygwin* | mingw* | pw32* | cegcc*) 2283238106Sdes version_type=windows 2284238106Sdes shrext_cmds=".dll" 2285238106Sdes need_version=no 2286238106Sdes need_lib_prefix=no 2287238106Sdes 2288238106Sdes case $GCC,$cc_basename in 2289238106Sdes yes,*) 2290238106Sdes # gcc 2291238106Sdes library_names_spec='$libname.dll.a' 2292238106Sdes # DLL is installed to $(libdir)/../bin by postinstall_cmds 2293238106Sdes postinstall_cmds='base_file=`basename \${file}`~ 2294238106Sdes dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ 2295238106Sdes dldir=$destdir/`dirname \$dlpath`~ 2296238106Sdes test -d \$dldir || mkdir -p \$dldir~ 2297238106Sdes $install_prog $dir/$dlname \$dldir/$dlname~ 2298238106Sdes chmod a+x \$dldir/$dlname~ 2299238106Sdes if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then 2300238106Sdes eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; 2301238106Sdes fi' 2302238106Sdes postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ 2303238106Sdes dlpath=$dir/\$dldll~ 2304238106Sdes $RM \$dlpath' 2305238106Sdes shlibpath_overrides_runpath=yes 2306238106Sdes 2307238106Sdes case $host_os in 2308238106Sdes cygwin*) 2309238106Sdes # Cygwin DLLs use 'cyg' prefix rather than 'lib' 2310238106Sdes soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' 2311238106Sdesm4_if([$1], [],[ 2312238106Sdes sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"]) 2313238106Sdes ;; 2314238106Sdes mingw* | cegcc*) 2315238106Sdes # MinGW DLLs use traditional 'lib' prefix 2316238106Sdes soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' 2317238106Sdes ;; 2318238106Sdes pw32*) 2319238106Sdes # pw32 DLLs use 'pw' prefix rather than 'lib' 2320238106Sdes library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' 2321238106Sdes ;; 2322238106Sdes esac 2323238106Sdes dynamic_linker='Win32 ld.exe' 2324238106Sdes ;; 2325238106Sdes 2326238106Sdes *,cl*) 2327238106Sdes # Native MSVC 2328238106Sdes libname_spec='$name' 2329238106Sdes soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' 2330238106Sdes library_names_spec='${libname}.dll.lib' 2331238106Sdes 2332238106Sdes case $build_os in 2333238106Sdes mingw*) 2334238106Sdes sys_lib_search_path_spec= 2335238106Sdes lt_save_ifs=$IFS 2336238106Sdes IFS=';' 2337238106Sdes for lt_path in $LIB 2338238106Sdes do 2339238106Sdes IFS=$lt_save_ifs 2340238106Sdes # Let DOS variable expansion print the short 8.3 style file name. 2341238106Sdes lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` 2342238106Sdes sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" 2343238106Sdes done 2344238106Sdes IFS=$lt_save_ifs 2345238106Sdes # Convert to MSYS style. 2346238106Sdes sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([[a-zA-Z]]\\):| /\\1|g' -e 's|^ ||'` 2347238106Sdes ;; 2348238106Sdes cygwin*) 2349238106Sdes # Convert to unix form, then to dos form, then back to unix form 2350238106Sdes # but this time dos style (no spaces!) so that the unix form looks 2351238106Sdes # like /cygdrive/c/PROGRA~1:/cygdr... 2352238106Sdes sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` 2353238106Sdes sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` 2354238106Sdes sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` 2355238106Sdes ;; 2356238106Sdes *) 2357238106Sdes sys_lib_search_path_spec="$LIB" 2358238106Sdes if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then 2359238106Sdes # It is most probably a Windows format PATH. 2360238106Sdes sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` 2361238106Sdes else 2362238106Sdes sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` 2363238106Sdes fi 2364238106Sdes # FIXME: find the short name or the path components, as spaces are 2365238106Sdes # common. (e.g. "Program Files" -> "PROGRA~1") 2366238106Sdes ;; 2367238106Sdes esac 2368238106Sdes 2369238106Sdes # DLL is installed to $(libdir)/../bin by postinstall_cmds 2370238106Sdes postinstall_cmds='base_file=`basename \${file}`~ 2371238106Sdes dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ 2372238106Sdes dldir=$destdir/`dirname \$dlpath`~ 2373238106Sdes test -d \$dldir || mkdir -p \$dldir~ 2374238106Sdes $install_prog $dir/$dlname \$dldir/$dlname' 2375238106Sdes postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ 2376238106Sdes dlpath=$dir/\$dldll~ 2377238106Sdes $RM \$dlpath' 2378238106Sdes shlibpath_overrides_runpath=yes 2379238106Sdes dynamic_linker='Win32 link.exe' 2380238106Sdes ;; 2381238106Sdes 2382238106Sdes *) 2383238106Sdes # Assume MSVC wrapper 2384238106Sdes library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib' 2385238106Sdes dynamic_linker='Win32 ld.exe' 2386238106Sdes ;; 2387238106Sdes esac 2388238106Sdes # FIXME: first we should search . and the directory the executable is in 2389238106Sdes shlibpath_var=PATH 2390238106Sdes ;; 2391238106Sdes 2392238106Sdesdarwin* | rhapsody*) 2393238106Sdes dynamic_linker="$host_os dyld" 2394238106Sdes version_type=darwin 2395238106Sdes need_lib_prefix=no 2396238106Sdes need_version=no 2397238106Sdes library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext' 2398238106Sdes soname_spec='${libname}${release}${major}$shared_ext' 2399238106Sdes shlibpath_overrides_runpath=yes 2400238106Sdes shlibpath_var=DYLD_LIBRARY_PATH 2401238106Sdes shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' 2402238106Sdesm4_if([$1], [],[ 2403238106Sdes sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"]) 2404238106Sdes sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' 2405238106Sdes ;; 2406238106Sdes 2407238106Sdesdgux*) 2408238106Sdes version_type=linux 2409238106Sdes need_lib_prefix=no 2410238106Sdes need_version=no 2411238106Sdes library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' 2412238106Sdes soname_spec='${libname}${release}${shared_ext}$major' 2413238106Sdes shlibpath_var=LD_LIBRARY_PATH 2414238106Sdes ;; 2415238106Sdes 2416238106Sdesfreebsd1*) 2417238106Sdes dynamic_linker=no 2418238106Sdes ;; 2419238106Sdes 2420238106Sdesfreebsd* | dragonfly*) 2421238106Sdes # DragonFly does not have aout. When/if they implement a new 2422238106Sdes # versioning mechanism, adjust this. 2423238106Sdes if test -x /usr/bin/objformat; then 2424238106Sdes objformat=`/usr/bin/objformat` 2425238106Sdes else 2426238106Sdes case $host_os in 2427238106Sdes freebsd[[123]]*) objformat=aout ;; 2428238106Sdes *) objformat=elf ;; 2429238106Sdes esac 2430238106Sdes fi 2431238106Sdes version_type=freebsd-$objformat 2432238106Sdes case $version_type in 2433238106Sdes freebsd-elf*) 2434238106Sdes library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' 2435238106Sdes need_version=no 2436238106Sdes need_lib_prefix=no 2437238106Sdes ;; 2438238106Sdes freebsd-*) 2439238106Sdes library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' 2440238106Sdes need_version=yes 2441238106Sdes ;; 2442238106Sdes esac 2443238106Sdes shlibpath_var=LD_LIBRARY_PATH 2444238106Sdes case $host_os in 2445238106Sdes freebsd2*) 2446238106Sdes shlibpath_overrides_runpath=yes 2447238106Sdes ;; 2448238106Sdes freebsd3.[[01]]* | freebsdelf3.[[01]]*) 2449238106Sdes shlibpath_overrides_runpath=yes 2450238106Sdes hardcode_into_libs=yes 2451238106Sdes ;; 2452238106Sdes freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \ 2453238106Sdes freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1) 2454238106Sdes shlibpath_overrides_runpath=no 2455238106Sdes hardcode_into_libs=yes 2456238106Sdes ;; 2457238106Sdes *) # from 4.6 on, and DragonFly 2458238106Sdes shlibpath_overrides_runpath=yes 2459238106Sdes hardcode_into_libs=yes 2460238106Sdes ;; 2461238106Sdes esac 2462238106Sdes ;; 2463238106Sdes 2464238106Sdesgnu*) 2465238106Sdes version_type=linux 2466238106Sdes need_lib_prefix=no 2467238106Sdes need_version=no 2468238106Sdes library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' 2469238106Sdes soname_spec='${libname}${release}${shared_ext}$major' 2470238106Sdes shlibpath_var=LD_LIBRARY_PATH 2471238106Sdes hardcode_into_libs=yes 2472238106Sdes ;; 2473238106Sdes 2474238106Sdeshaiku*) 2475238106Sdes version_type=linux 2476238106Sdes need_lib_prefix=no 2477238106Sdes need_version=no 2478238106Sdes dynamic_linker="$host_os runtime_loader" 2479238106Sdes library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' 2480238106Sdes soname_spec='${libname}${release}${shared_ext}$major' 2481238106Sdes shlibpath_var=LIBRARY_PATH 2482238106Sdes shlibpath_overrides_runpath=yes 2483238106Sdes sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' 2484238106Sdes hardcode_into_libs=yes 2485238106Sdes ;; 2486238106Sdes 2487238106Sdeshpux9* | hpux10* | hpux11*) 2488238106Sdes # Give a soname corresponding to the major version so that dld.sl refuses to 2489238106Sdes # link against other versions. 2490238106Sdes version_type=sunos 2491238106Sdes need_lib_prefix=no 2492238106Sdes need_version=no 2493238106Sdes case $host_cpu in 2494238106Sdes ia64*) 2495238106Sdes shrext_cmds='.so' 2496238106Sdes hardcode_into_libs=yes 2497238106Sdes dynamic_linker="$host_os dld.so" 2498238106Sdes shlibpath_var=LD_LIBRARY_PATH 2499238106Sdes shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. 2500238106Sdes library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 2501238106Sdes soname_spec='${libname}${release}${shared_ext}$major' 2502238106Sdes if test "X$HPUX_IA64_MODE" = X32; then 2503238106Sdes sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" 2504238106Sdes else 2505238106Sdes sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" 2506238106Sdes fi 2507238106Sdes sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec 2508238106Sdes ;; 2509238106Sdes hppa*64*) 2510238106Sdes shrext_cmds='.sl' 2511238106Sdes hardcode_into_libs=yes 2512238106Sdes dynamic_linker="$host_os dld.sl" 2513238106Sdes shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH 2514238106Sdes shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. 2515238106Sdes library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 2516238106Sdes soname_spec='${libname}${release}${shared_ext}$major' 2517238106Sdes sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" 2518238106Sdes sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec 2519238106Sdes ;; 2520238106Sdes *) 2521238106Sdes shrext_cmds='.sl' 2522238106Sdes dynamic_linker="$host_os dld.sl" 2523238106Sdes shlibpath_var=SHLIB_PATH 2524238106Sdes shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH 2525238106Sdes library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 2526238106Sdes soname_spec='${libname}${release}${shared_ext}$major' 2527238106Sdes ;; 2528238106Sdes esac 2529238106Sdes # HP-UX runs *really* slowly unless shared libraries are mode 555, ... 2530238106Sdes postinstall_cmds='chmod 555 $lib' 2531238106Sdes # or fails outright, so override atomically: 2532238106Sdes install_override_mode=555 2533238106Sdes ;; 2534238106Sdes 2535238106Sdesinterix[[3-9]]*) 2536238106Sdes version_type=linux 2537238106Sdes need_lib_prefix=no 2538238106Sdes need_version=no 2539238106Sdes library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' 2540238106Sdes soname_spec='${libname}${release}${shared_ext}$major' 2541238106Sdes dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' 2542238106Sdes shlibpath_var=LD_LIBRARY_PATH 2543238106Sdes shlibpath_overrides_runpath=no 2544238106Sdes hardcode_into_libs=yes 2545238106Sdes ;; 2546238106Sdes 2547238106Sdesirix5* | irix6* | nonstopux*) 2548238106Sdes case $host_os in 2549238106Sdes nonstopux*) version_type=nonstopux ;; 2550238106Sdes *) 2551238106Sdes if test "$lt_cv_prog_gnu_ld" = yes; then 2552238106Sdes version_type=linux 2553238106Sdes else 2554238106Sdes version_type=irix 2555238106Sdes fi ;; 2556238106Sdes esac 2557238106Sdes need_lib_prefix=no 2558238106Sdes need_version=no 2559238106Sdes soname_spec='${libname}${release}${shared_ext}$major' 2560238106Sdes library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' 2561238106Sdes case $host_os in 2562238106Sdes irix5* | nonstopux*) 2563238106Sdes libsuff= shlibsuff= 2564238106Sdes ;; 2565238106Sdes *) 2566238106Sdes case $LD in # libtool.m4 will add one of these switches to LD 2567238106Sdes *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") 2568238106Sdes libsuff= shlibsuff= libmagic=32-bit;; 2569238106Sdes *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") 2570238106Sdes libsuff=32 shlibsuff=N32 libmagic=N32;; 2571238106Sdes *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") 2572238106Sdes libsuff=64 shlibsuff=64 libmagic=64-bit;; 2573238106Sdes *) libsuff= shlibsuff= libmagic=never-match;; 2574238106Sdes esac 2575238106Sdes ;; 2576238106Sdes esac 2577238106Sdes shlibpath_var=LD_LIBRARY${shlibsuff}_PATH 2578238106Sdes shlibpath_overrides_runpath=no 2579238106Sdes sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" 2580238106Sdes sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" 2581238106Sdes hardcode_into_libs=yes 2582238106Sdes ;; 2583238106Sdes 2584238106Sdes# No shared lib support for Linux oldld, aout, or coff. 2585238106Sdeslinux*oldld* | linux*aout* | linux*coff*) 2586238106Sdes dynamic_linker=no 2587238106Sdes ;; 2588238106Sdes 2589238106Sdes# This must be Linux ELF. 2590238106Sdeslinux* | k*bsd*-gnu | kopensolaris*-gnu) 2591238106Sdes version_type=linux 2592238106Sdes need_lib_prefix=no 2593238106Sdes need_version=no 2594238106Sdes library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 2595238106Sdes soname_spec='${libname}${release}${shared_ext}$major' 2596238106Sdes finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' 2597238106Sdes shlibpath_var=LD_LIBRARY_PATH 2598238106Sdes shlibpath_overrides_runpath=no 2599238106Sdes 2600238106Sdes # Some binutils ld are patched to set DT_RUNPATH 2601238106Sdes AC_CACHE_VAL([lt_cv_shlibpath_overrides_runpath], 2602238106Sdes [lt_cv_shlibpath_overrides_runpath=no 2603238106Sdes save_LDFLAGS=$LDFLAGS 2604238106Sdes save_libdir=$libdir 2605238106Sdes eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \ 2606238106Sdes LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\"" 2607238106Sdes AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], 2608238106Sdes [AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null], 2609238106Sdes [lt_cv_shlibpath_overrides_runpath=yes])]) 2610238106Sdes LDFLAGS=$save_LDFLAGS 2611238106Sdes libdir=$save_libdir 2612238106Sdes ]) 2613238106Sdes shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath 2614238106Sdes 2615238106Sdes # This implies no fast_install, which is unacceptable. 2616238106Sdes # Some rework will be needed to allow for fast_install 2617238106Sdes # before this can be enabled. 2618238106Sdes hardcode_into_libs=yes 2619238106Sdes 2620238106Sdes # Add ABI-specific directories to the system library path. 2621238106Sdes sys_lib_dlsearch_path_spec="/lib64 /usr/lib64 /lib /usr/lib" 2622238106Sdes 2623238106Sdes # Append ld.so.conf contents to the search path 2624238106Sdes if test -f /etc/ld.so.conf; then 2625238106Sdes 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' ' '` 2626238106Sdes sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec $lt_ld_extra" 2627238106Sdes 2628238106Sdes fi 2629238106Sdes 2630238106Sdes # We used to test for /lib/ld.so.1 and disable shared libraries on 2631238106Sdes # powerpc, because MkLinux only supported shared libraries with the 2632238106Sdes # GNU dynamic linker. Since this was broken with cross compilers, 2633238106Sdes # most powerpc-linux boxes support dynamic linking these days and 2634238106Sdes # people can always --disable-shared, the test was removed, and we 2635238106Sdes # assume the GNU/Linux dynamic linker is in use. 2636238106Sdes dynamic_linker='GNU/Linux ld.so' 2637238106Sdes ;; 2638238106Sdes 2639238106Sdesnetbsd*) 2640238106Sdes version_type=sunos 2641238106Sdes need_lib_prefix=no 2642238106Sdes need_version=no 2643238106Sdes if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then 2644238106Sdes library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' 2645238106Sdes finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' 2646238106Sdes dynamic_linker='NetBSD (a.out) ld.so' 2647238106Sdes else 2648238106Sdes library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' 2649238106Sdes soname_spec='${libname}${release}${shared_ext}$major' 2650238106Sdes dynamic_linker='NetBSD ld.elf_so' 2651238106Sdes fi 2652238106Sdes shlibpath_var=LD_LIBRARY_PATH 2653238106Sdes shlibpath_overrides_runpath=yes 2654238106Sdes hardcode_into_libs=yes 2655238106Sdes ;; 2656238106Sdes 2657238106Sdesnewsos6) 2658238106Sdes version_type=linux 2659238106Sdes library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 2660238106Sdes shlibpath_var=LD_LIBRARY_PATH 2661238106Sdes shlibpath_overrides_runpath=yes 2662238106Sdes ;; 2663238106Sdes 2664238106Sdes*nto* | *qnx*) 2665238106Sdes version_type=qnx 2666238106Sdes need_lib_prefix=no 2667238106Sdes need_version=no 2668238106Sdes library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 2669238106Sdes soname_spec='${libname}${release}${shared_ext}$major' 2670238106Sdes shlibpath_var=LD_LIBRARY_PATH 2671238106Sdes shlibpath_overrides_runpath=no 2672238106Sdes hardcode_into_libs=yes 2673238106Sdes dynamic_linker='ldqnx.so' 2674238106Sdes ;; 2675238106Sdes 2676238106Sdesopenbsd*) 2677238106Sdes version_type=sunos 2678238106Sdes sys_lib_dlsearch_path_spec="/usr/lib" 2679238106Sdes need_lib_prefix=no 2680238106Sdes # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. 2681238106Sdes case $host_os in 2682238106Sdes openbsd3.3 | openbsd3.3.*) need_version=yes ;; 2683238106Sdes *) need_version=no ;; 2684238106Sdes esac 2685238106Sdes library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' 2686238106Sdes finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' 2687238106Sdes shlibpath_var=LD_LIBRARY_PATH 2688238106Sdes if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then 2689238106Sdes case $host_os in 2690238106Sdes openbsd2.[[89]] | openbsd2.[[89]].*) 2691238106Sdes shlibpath_overrides_runpath=no 2692238106Sdes ;; 2693238106Sdes *) 2694238106Sdes shlibpath_overrides_runpath=yes 2695238106Sdes ;; 2696238106Sdes esac 2697238106Sdes else 2698238106Sdes shlibpath_overrides_runpath=yes 2699238106Sdes fi 2700238106Sdes ;; 2701238106Sdes 2702238106Sdesos2*) 2703238106Sdes libname_spec='$name' 2704238106Sdes shrext_cmds=".dll" 2705238106Sdes need_lib_prefix=no 2706238106Sdes library_names_spec='$libname${shared_ext} $libname.a' 2707238106Sdes dynamic_linker='OS/2 ld.exe' 2708238106Sdes shlibpath_var=LIBPATH 2709238106Sdes ;; 2710238106Sdes 2711238106Sdesosf3* | osf4* | osf5*) 2712238106Sdes version_type=osf 2713238106Sdes need_lib_prefix=no 2714238106Sdes need_version=no 2715238106Sdes soname_spec='${libname}${release}${shared_ext}$major' 2716238106Sdes library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 2717238106Sdes shlibpath_var=LD_LIBRARY_PATH 2718238106Sdes sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" 2719238106Sdes sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" 2720238106Sdes ;; 2721238106Sdes 2722238106Sdesrdos*) 2723238106Sdes dynamic_linker=no 2724238106Sdes ;; 2725238106Sdes 2726238106Sdessolaris*) 2727238106Sdes version_type=linux 2728238106Sdes need_lib_prefix=no 2729238106Sdes need_version=no 2730238106Sdes library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 2731238106Sdes soname_spec='${libname}${release}${shared_ext}$major' 2732238106Sdes shlibpath_var=LD_LIBRARY_PATH 2733238106Sdes shlibpath_overrides_runpath=yes 2734238106Sdes hardcode_into_libs=yes 2735238106Sdes # ldd complains unless libraries are executable 2736238106Sdes postinstall_cmds='chmod +x $lib' 2737238106Sdes ;; 2738238106Sdes 2739238106Sdessunos4*) 2740238106Sdes version_type=sunos 2741238106Sdes library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' 2742238106Sdes finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' 2743238106Sdes shlibpath_var=LD_LIBRARY_PATH 2744238106Sdes shlibpath_overrides_runpath=yes 2745238106Sdes if test "$with_gnu_ld" = yes; then 2746238106Sdes need_lib_prefix=no 2747238106Sdes fi 2748238106Sdes need_version=yes 2749238106Sdes ;; 2750238106Sdes 2751238106Sdessysv4 | sysv4.3*) 2752238106Sdes version_type=linux 2753238106Sdes library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 2754238106Sdes soname_spec='${libname}${release}${shared_ext}$major' 2755238106Sdes shlibpath_var=LD_LIBRARY_PATH 2756238106Sdes case $host_vendor in 2757238106Sdes sni) 2758238106Sdes shlibpath_overrides_runpath=no 2759238106Sdes need_lib_prefix=no 2760238106Sdes runpath_var=LD_RUN_PATH 2761238106Sdes ;; 2762238106Sdes siemens) 2763238106Sdes need_lib_prefix=no 2764238106Sdes ;; 2765238106Sdes motorola) 2766238106Sdes need_lib_prefix=no 2767238106Sdes need_version=no 2768238106Sdes shlibpath_overrides_runpath=no 2769238106Sdes sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' 2770238106Sdes ;; 2771238106Sdes esac 2772238106Sdes ;; 2773238106Sdes 2774238106Sdessysv4*MP*) 2775238106Sdes if test -d /usr/nec ;then 2776238106Sdes version_type=linux 2777238106Sdes library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' 2778238106Sdes soname_spec='$libname${shared_ext}.$major' 2779238106Sdes shlibpath_var=LD_LIBRARY_PATH 2780238106Sdes fi 2781238106Sdes ;; 2782238106Sdes 2783238106Sdessysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) 2784238106Sdes version_type=freebsd-elf 2785238106Sdes need_lib_prefix=no 2786238106Sdes need_version=no 2787238106Sdes library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' 2788238106Sdes soname_spec='${libname}${release}${shared_ext}$major' 2789238106Sdes shlibpath_var=LD_LIBRARY_PATH 2790238106Sdes shlibpath_overrides_runpath=yes 2791238106Sdes hardcode_into_libs=yes 2792238106Sdes if test "$with_gnu_ld" = yes; then 2793238106Sdes sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' 2794238106Sdes else 2795238106Sdes sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' 2796238106Sdes case $host_os in 2797238106Sdes sco3.2v5*) 2798238106Sdes sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" 2799238106Sdes ;; 2800238106Sdes esac 2801238106Sdes fi 2802238106Sdes sys_lib_dlsearch_path_spec='/usr/lib' 2803238106Sdes ;; 2804238106Sdes 2805238106Sdestpf*) 2806238106Sdes # TPF is a cross-target only. Preferred cross-host = GNU/Linux. 2807238106Sdes version_type=linux 2808238106Sdes need_lib_prefix=no 2809238106Sdes need_version=no 2810238106Sdes library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 2811238106Sdes shlibpath_var=LD_LIBRARY_PATH 2812238106Sdes shlibpath_overrides_runpath=no 2813238106Sdes hardcode_into_libs=yes 2814238106Sdes ;; 2815238106Sdes 2816238106Sdesuts4*) 2817238106Sdes version_type=linux 2818238106Sdes library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 2819238106Sdes soname_spec='${libname}${release}${shared_ext}$major' 2820238106Sdes shlibpath_var=LD_LIBRARY_PATH 2821238106Sdes ;; 2822238106Sdes 2823238106Sdes*) 2824238106Sdes dynamic_linker=no 2825238106Sdes ;; 2826238106Sdesesac 2827238106SdesAC_MSG_RESULT([$dynamic_linker]) 2828238106Sdestest "$dynamic_linker" = no && can_build_shared=no 2829238106Sdes 2830238106Sdesvariables_saved_for_relink="PATH $shlibpath_var $runpath_var" 2831238106Sdesif test "$GCC" = yes; then 2832238106Sdes variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" 2833238106Sdesfi 2834238106Sdes 2835238106Sdesif test "${lt_cv_sys_lib_search_path_spec+set}" = set; then 2836238106Sdes sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" 2837238106Sdesfi 2838238106Sdesif test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then 2839238106Sdes sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" 2840238106Sdesfi 2841238106Sdes 2842238106Sdes_LT_DECL([], [variables_saved_for_relink], [1], 2843238106Sdes [Variables whose values should be saved in libtool wrapper scripts and 2844238106Sdes restored at link time]) 2845238106Sdes_LT_DECL([], [need_lib_prefix], [0], 2846238106Sdes [Do we need the "lib" prefix for modules?]) 2847238106Sdes_LT_DECL([], [need_version], [0], [Do we need a version for libraries?]) 2848238106Sdes_LT_DECL([], [version_type], [0], [Library versioning type]) 2849238106Sdes_LT_DECL([], [runpath_var], [0], [Shared library runtime path variable]) 2850238106Sdes_LT_DECL([], [shlibpath_var], [0],[Shared library path variable]) 2851238106Sdes_LT_DECL([], [shlibpath_overrides_runpath], [0], 2852238106Sdes [Is shlibpath searched before the hard-coded library search path?]) 2853238106Sdes_LT_DECL([], [libname_spec], [1], [Format of library name prefix]) 2854238106Sdes_LT_DECL([], [library_names_spec], [1], 2855238106Sdes [[List of archive names. First name is the real one, the rest are links. 2856238106Sdes The last name is the one that the linker finds with -lNAME]]) 2857238106Sdes_LT_DECL([], [soname_spec], [1], 2858238106Sdes [[The coded name of the library, if different from the real name]]) 2859238106Sdes_LT_DECL([], [install_override_mode], [1], 2860238106Sdes [Permission mode override for installation of shared libraries]) 2861238106Sdes_LT_DECL([], [postinstall_cmds], [2], 2862238106Sdes [Command to use after installation of a shared archive]) 2863238106Sdes_LT_DECL([], [postuninstall_cmds], [2], 2864238106Sdes [Command to use after uninstallation of a shared archive]) 2865238106Sdes_LT_DECL([], [finish_cmds], [2], 2866238106Sdes [Commands used to finish a libtool library installation in a directory]) 2867238106Sdes_LT_DECL([], [finish_eval], [1], 2868238106Sdes [[As "finish_cmds", except a single script fragment to be evaled but 2869238106Sdes not shown]]) 2870238106Sdes_LT_DECL([], [hardcode_into_libs], [0], 2871238106Sdes [Whether we should hardcode library paths into libraries]) 2872238106Sdes_LT_DECL([], [sys_lib_search_path_spec], [2], 2873238106Sdes [Compile-time system search path for libraries]) 2874238106Sdes_LT_DECL([], [sys_lib_dlsearch_path_spec], [2], 2875238106Sdes [Run-time system search path for libraries]) 2876238106Sdes])# _LT_SYS_DYNAMIC_LINKER 2877238106Sdes 2878238106Sdes 2879238106Sdes# _LT_PATH_TOOL_PREFIX(TOOL) 2880238106Sdes# -------------------------- 2881238106Sdes# find a file program which can recognize shared library 2882238106SdesAC_DEFUN([_LT_PATH_TOOL_PREFIX], 2883238106Sdes[m4_require([_LT_DECL_EGREP])dnl 2884238106SdesAC_MSG_CHECKING([for $1]) 2885238106SdesAC_CACHE_VAL(lt_cv_path_MAGIC_CMD, 2886238106Sdes[case $MAGIC_CMD in 2887238106Sdes[[\\/*] | ?:[\\/]*]) 2888238106Sdes lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. 2889238106Sdes ;; 2890238106Sdes*) 2891238106Sdes lt_save_MAGIC_CMD="$MAGIC_CMD" 2892238106Sdes lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR 2893238106Sdesdnl $ac_dummy forces splitting on constant user-supplied paths. 2894238106Sdesdnl POSIX.2 word splitting is done only on the output of word expansions, 2895238106Sdesdnl not every word. This closes a longstanding sh security hole. 2896238106Sdes ac_dummy="m4_if([$2], , $PATH, [$2])" 2897238106Sdes for ac_dir in $ac_dummy; do 2898238106Sdes IFS="$lt_save_ifs" 2899238106Sdes test -z "$ac_dir" && ac_dir=. 2900238106Sdes if test -f $ac_dir/$1; then 2901238106Sdes lt_cv_path_MAGIC_CMD="$ac_dir/$1" 2902238106Sdes if test -n "$file_magic_test_file"; then 2903238106Sdes case $deplibs_check_method in 2904238106Sdes "file_magic "*) 2905238106Sdes file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` 2906238106Sdes MAGIC_CMD="$lt_cv_path_MAGIC_CMD" 2907238106Sdes if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | 2908238106Sdes $EGREP "$file_magic_regex" > /dev/null; then 2909238106Sdes : 2910238106Sdes else 2911238106Sdes cat <<_LT_EOF 1>&2 2912238106Sdes 2913238106Sdes*** Warning: the command libtool uses to detect shared libraries, 2914238106Sdes*** $file_magic_cmd, produces output that libtool cannot recognize. 2915238106Sdes*** The result is that libtool may fail to recognize shared libraries 2916238106Sdes*** as such. This will affect the creation of libtool libraries that 2917238106Sdes*** depend on shared libraries, but programs linked with such libtool 2918238106Sdes*** libraries will work regardless of this problem. Nevertheless, you 2919238106Sdes*** may want to report the problem to your system manager and/or to 2920238106Sdes*** bug-libtool@gnu.org 2921238106Sdes 2922238106Sdes_LT_EOF 2923238106Sdes fi ;; 2924238106Sdes esac 2925238106Sdes fi 2926238106Sdes break 2927238106Sdes fi 2928238106Sdes done 2929238106Sdes IFS="$lt_save_ifs" 2930238106Sdes MAGIC_CMD="$lt_save_MAGIC_CMD" 2931238106Sdes ;; 2932238106Sdesesac]) 2933238106SdesMAGIC_CMD="$lt_cv_path_MAGIC_CMD" 2934238106Sdesif test -n "$MAGIC_CMD"; then 2935238106Sdes AC_MSG_RESULT($MAGIC_CMD) 2936238106Sdeselse 2937238106Sdes AC_MSG_RESULT(no) 2938238106Sdesfi 2939238106Sdes_LT_DECL([], [MAGIC_CMD], [0], 2940238106Sdes [Used to examine libraries when file_magic_cmd begins with "file"])dnl 2941238106Sdes])# _LT_PATH_TOOL_PREFIX 2942238106Sdes 2943238106Sdes# Old name: 2944238106SdesAU_ALIAS([AC_PATH_TOOL_PREFIX], [_LT_PATH_TOOL_PREFIX]) 2945238106Sdesdnl aclocal-1.4 backwards compatibility: 2946238106Sdesdnl AC_DEFUN([AC_PATH_TOOL_PREFIX], []) 2947238106Sdes 2948238106Sdes 2949238106Sdes# _LT_PATH_MAGIC 2950238106Sdes# -------------- 2951238106Sdes# find a file program which can recognize a shared library 2952238106Sdesm4_defun([_LT_PATH_MAGIC], 2953238106Sdes[_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH) 2954238106Sdesif test -z "$lt_cv_path_MAGIC_CMD"; then 2955238106Sdes if test -n "$ac_tool_prefix"; then 2956238106Sdes _LT_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH) 2957238106Sdes else 2958238106Sdes MAGIC_CMD=: 2959238106Sdes fi 2960238106Sdesfi 2961238106Sdes])# _LT_PATH_MAGIC 2962238106Sdes 2963238106Sdes 2964238106Sdes# LT_PATH_LD 2965238106Sdes# ---------- 2966238106Sdes# find the pathname to the GNU or non-GNU linker 2967238106SdesAC_DEFUN([LT_PATH_LD], 2968238106Sdes[AC_REQUIRE([AC_PROG_CC])dnl 2969238106SdesAC_REQUIRE([AC_CANONICAL_HOST])dnl 2970238106SdesAC_REQUIRE([AC_CANONICAL_BUILD])dnl 2971238106Sdesm4_require([_LT_DECL_SED])dnl 2972238106Sdesm4_require([_LT_DECL_EGREP])dnl 2973238106Sdesm4_require([_LT_PROG_ECHO_BACKSLASH])dnl 2974238106Sdes 2975238106SdesAC_ARG_WITH([gnu-ld], 2976238106Sdes [AS_HELP_STRING([--with-gnu-ld], 2977238106Sdes [assume the C compiler uses GNU ld @<:@default=no@:>@])], 2978238106Sdes [test "$withval" = no || with_gnu_ld=yes], 2979238106Sdes [with_gnu_ld=no])dnl 2980238106Sdes 2981238106Sdesac_prog=ld 2982238106Sdesif test "$GCC" = yes; then 2983238106Sdes # Check if gcc -print-prog-name=ld gives a path. 2984238106Sdes AC_MSG_CHECKING([for ld used by $CC]) 2985238106Sdes case $host in 2986238106Sdes *-*-mingw*) 2987238106Sdes # gcc leaves a trailing carriage return which upsets mingw 2988238106Sdes ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; 2989238106Sdes *) 2990238106Sdes ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; 2991238106Sdes esac 2992238106Sdes case $ac_prog in 2993238106Sdes # Accept absolute paths. 2994238106Sdes [[\\/]]* | ?:[[\\/]]*) 2995238106Sdes re_direlt='/[[^/]][[^/]]*/\.\./' 2996238106Sdes # Canonicalize the pathname of ld 2997238106Sdes ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` 2998238106Sdes while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do 2999238106Sdes ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` 3000238106Sdes done 3001238106Sdes test -z "$LD" && LD="$ac_prog" 3002238106Sdes ;; 3003238106Sdes "") 3004238106Sdes # If it fails, then pretend we aren't using GCC. 3005238106Sdes ac_prog=ld 3006238106Sdes ;; 3007238106Sdes *) 3008238106Sdes # If it is relative, then search for the first ld in PATH. 3009238106Sdes with_gnu_ld=unknown 3010238106Sdes ;; 3011238106Sdes esac 3012238106Sdeselif test "$with_gnu_ld" = yes; then 3013238106Sdes AC_MSG_CHECKING([for GNU ld]) 3014238106Sdeselse 3015238106Sdes AC_MSG_CHECKING([for non-GNU ld]) 3016238106Sdesfi 3017238106SdesAC_CACHE_VAL(lt_cv_path_LD, 3018238106Sdes[if test -z "$LD"; then 3019238106Sdes lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR 3020238106Sdes for ac_dir in $PATH; do 3021238106Sdes IFS="$lt_save_ifs" 3022238106Sdes test -z "$ac_dir" && ac_dir=. 3023238106Sdes if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then 3024238106Sdes lt_cv_path_LD="$ac_dir/$ac_prog" 3025238106Sdes # Check to see if the program is GNU ld. I'd rather use --version, 3026238106Sdes # but apparently some variants of GNU ld only accept -v. 3027238106Sdes # Break only if it was the GNU/non-GNU ld that we prefer. 3028238106Sdes case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in 3029238106Sdes *GNU* | *'with BFD'*) 3030238106Sdes test "$with_gnu_ld" != no && break 3031238106Sdes ;; 3032238106Sdes *) 3033238106Sdes test "$with_gnu_ld" != yes && break 3034238106Sdes ;; 3035238106Sdes esac 3036238106Sdes fi 3037238106Sdes done 3038238106Sdes IFS="$lt_save_ifs" 3039238106Sdeselse 3040238106Sdes lt_cv_path_LD="$LD" # Let the user override the test with a path. 3041238106Sdesfi]) 3042238106SdesLD="$lt_cv_path_LD" 3043238106Sdesif test -n "$LD"; then 3044238106Sdes AC_MSG_RESULT($LD) 3045238106Sdeselse 3046238106Sdes AC_MSG_RESULT(no) 3047238106Sdesfi 3048238106Sdestest -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH]) 3049238106Sdes_LT_PATH_LD_GNU 3050238106SdesAC_SUBST([LD]) 3051238106Sdes 3052238106Sdes_LT_TAGDECL([], [LD], [1], [The linker used to build libraries]) 3053238106Sdes])# LT_PATH_LD 3054238106Sdes 3055238106Sdes# Old names: 3056238106SdesAU_ALIAS([AM_PROG_LD], [LT_PATH_LD]) 3057238106SdesAU_ALIAS([AC_PROG_LD], [LT_PATH_LD]) 3058238106Sdesdnl aclocal-1.4 backwards compatibility: 3059238106Sdesdnl AC_DEFUN([AM_PROG_LD], []) 3060238106Sdesdnl AC_DEFUN([AC_PROG_LD], []) 3061238106Sdes 3062238106Sdes 3063238106Sdes# _LT_PATH_LD_GNU 3064238106Sdes#- -------------- 3065238106Sdesm4_defun([_LT_PATH_LD_GNU], 3066238106Sdes[AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld, 3067238106Sdes[# I'd rather use --version here, but apparently some GNU lds only accept -v. 3068238106Sdescase `$LD -v 2>&1 </dev/null` in 3069238106Sdes*GNU* | *'with BFD'*) 3070238106Sdes lt_cv_prog_gnu_ld=yes 3071238106Sdes ;; 3072238106Sdes*) 3073238106Sdes lt_cv_prog_gnu_ld=no 3074238106Sdes ;; 3075238106Sdesesac]) 3076238106Sdeswith_gnu_ld=$lt_cv_prog_gnu_ld 3077238106Sdes])# _LT_PATH_LD_GNU 3078238106Sdes 3079238106Sdes 3080238106Sdes# _LT_CMD_RELOAD 3081238106Sdes# -------------- 3082238106Sdes# find reload flag for linker 3083238106Sdes# -- PORTME Some linkers may need a different reload flag. 3084238106Sdesm4_defun([_LT_CMD_RELOAD], 3085238106Sdes[AC_CACHE_CHECK([for $LD option to reload object files], 3086238106Sdes lt_cv_ld_reload_flag, 3087238106Sdes [lt_cv_ld_reload_flag='-r']) 3088238106Sdesreload_flag=$lt_cv_ld_reload_flag 3089238106Sdescase $reload_flag in 3090238106Sdes"" | " "*) ;; 3091238106Sdes*) reload_flag=" $reload_flag" ;; 3092238106Sdesesac 3093238106Sdesreload_cmds='$LD$reload_flag -o $output$reload_objs' 3094238106Sdescase $host_os in 3095238106Sdes cygwin* | mingw* | pw32* | cegcc*) 3096238106Sdes if test "$GCC" != yes; then 3097238106Sdes reload_cmds=false 3098238106Sdes fi 3099238106Sdes ;; 3100238106Sdes darwin*) 3101238106Sdes if test "$GCC" = yes; then 3102238106Sdes reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs' 3103238106Sdes else 3104238106Sdes reload_cmds='$LD$reload_flag -o $output$reload_objs' 3105238106Sdes fi 3106238106Sdes ;; 3107238106Sdesesac 3108238106Sdes_LT_TAGDECL([], [reload_flag], [1], [How to create reloadable object files])dnl 3109238106Sdes_LT_TAGDECL([], [reload_cmds], [2])dnl 3110238106Sdes])# _LT_CMD_RELOAD 3111238106Sdes 3112238106Sdes 3113238106Sdes# _LT_CHECK_MAGIC_METHOD 3114238106Sdes# ---------------------- 3115238106Sdes# how to check for library dependencies 3116238106Sdes# -- PORTME fill in with the dynamic library characteristics 3117238106Sdesm4_defun([_LT_CHECK_MAGIC_METHOD], 3118238106Sdes[m4_require([_LT_DECL_EGREP]) 3119238106Sdesm4_require([_LT_DECL_OBJDUMP]) 3120238106SdesAC_CACHE_CHECK([how to recognize dependent libraries], 3121238106Sdeslt_cv_deplibs_check_method, 3122238106Sdes[lt_cv_file_magic_cmd='$MAGIC_CMD' 3123238106Sdeslt_cv_file_magic_test_file= 3124238106Sdeslt_cv_deplibs_check_method='unknown' 3125238106Sdes# Need to set the preceding variable on all platforms that support 3126238106Sdes# interlibrary dependencies. 3127238106Sdes# 'none' -- dependencies not supported. 3128238106Sdes# `unknown' -- same as none, but documents that we really don't know. 3129238106Sdes# 'pass_all' -- all dependencies passed with no checks. 3130238106Sdes# 'test_compile' -- check by making test program. 3131238106Sdes# 'file_magic [[regex]]' -- check by looking for files in library path 3132238106Sdes# which responds to the $file_magic_cmd with a given extended regex. 3133238106Sdes# If you have `file' or equivalent on your system and you're not sure 3134238106Sdes# whether `pass_all' will *always* work, you probably want this one. 3135238106Sdes 3136238106Sdescase $host_os in 3137238106Sdesaix[[4-9]]*) 3138238106Sdes lt_cv_deplibs_check_method=pass_all 3139238106Sdes ;; 3140238106Sdes 3141238106Sdesbeos*) 3142238106Sdes lt_cv_deplibs_check_method=pass_all 3143238106Sdes ;; 3144238106Sdes 3145238106Sdesbsdi[[45]]*) 3146238106Sdes lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)' 3147238106Sdes lt_cv_file_magic_cmd='/usr/bin/file -L' 3148238106Sdes lt_cv_file_magic_test_file=/shlib/libc.so 3149238106Sdes ;; 3150238106Sdes 3151238106Sdescygwin*) 3152238106Sdes # func_win32_libid is a shell function defined in ltmain.sh 3153238106Sdes lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' 3154238106Sdes lt_cv_file_magic_cmd='func_win32_libid' 3155238106Sdes ;; 3156238106Sdes 3157238106Sdesmingw* | pw32*) 3158238106Sdes # Base MSYS/MinGW do not provide the 'file' command needed by 3159238106Sdes # func_win32_libid shell function, so use a weaker test based on 'objdump', 3160238106Sdes # unless we find 'file', for example because we are cross-compiling. 3161238106Sdes # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin. 3162238106Sdes if ( test "$lt_cv_nm_interface" = "BSD nm" && file / ) >/dev/null 2>&1; then 3163238106Sdes lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' 3164238106Sdes lt_cv_file_magic_cmd='func_win32_libid' 3165238106Sdes else 3166238106Sdes # Keep this pattern in sync with the one in func_win32_libid. 3167238106Sdes lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' 3168238106Sdes lt_cv_file_magic_cmd='$OBJDUMP -f' 3169238106Sdes fi 3170238106Sdes ;; 3171238106Sdes 3172238106Sdescegcc*) 3173238106Sdes # use the weaker test based on 'objdump'. See mingw*. 3174238106Sdes lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?' 3175238106Sdes lt_cv_file_magic_cmd='$OBJDUMP -f' 3176238106Sdes ;; 3177238106Sdes 3178238106Sdesdarwin* | rhapsody*) 3179238106Sdes lt_cv_deplibs_check_method=pass_all 3180238106Sdes ;; 3181238106Sdes 3182238106Sdesfreebsd* | dragonfly*) 3183238106Sdes if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then 3184238106Sdes case $host_cpu in 3185238106Sdes i*86 ) 3186238106Sdes # Not sure whether the presence of OpenBSD here was a mistake. 3187238106Sdes # Let's accept both of them until this is cleared up. 3188238106Sdes lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library' 3189238106Sdes lt_cv_file_magic_cmd=/usr/bin/file 3190238106Sdes lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` 3191238106Sdes ;; 3192238106Sdes esac 3193238106Sdes else 3194238106Sdes lt_cv_deplibs_check_method=pass_all 3195238106Sdes fi 3196238106Sdes ;; 3197238106Sdes 3198238106Sdesgnu*) 3199238106Sdes lt_cv_deplibs_check_method=pass_all 3200238106Sdes ;; 3201238106Sdes 3202238106Sdeshaiku*) 3203238106Sdes lt_cv_deplibs_check_method=pass_all 3204238106Sdes ;; 3205238106Sdes 3206238106Sdeshpux10.20* | hpux11*) 3207238106Sdes lt_cv_file_magic_cmd=/usr/bin/file 3208238106Sdes case $host_cpu in 3209238106Sdes ia64*) 3210238106Sdes lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64' 3211238106Sdes lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so 3212238106Sdes ;; 3213238106Sdes hppa*64*) 3214238106Sdes [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]'] 3215238106Sdes lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl 3216238106Sdes ;; 3217238106Sdes *) 3218238106Sdes lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]]\.[[0-9]]) shared library' 3219238106Sdes lt_cv_file_magic_test_file=/usr/lib/libc.sl 3220238106Sdes ;; 3221238106Sdes esac 3222238106Sdes ;; 3223238106Sdes 3224238106Sdesinterix[[3-9]]*) 3225238106Sdes # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here 3226238106Sdes lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$' 3227238106Sdes ;; 3228238106Sdes 3229238106Sdesirix5* | irix6* | nonstopux*) 3230238106Sdes case $LD in 3231238106Sdes *-32|*"-32 ") libmagic=32-bit;; 3232238106Sdes *-n32|*"-n32 ") libmagic=N32;; 3233238106Sdes *-64|*"-64 ") libmagic=64-bit;; 3234238106Sdes *) libmagic=never-match;; 3235238106Sdes esac 3236238106Sdes lt_cv_deplibs_check_method=pass_all 3237238106Sdes ;; 3238238106Sdes 3239238106Sdes# This must be Linux ELF. 3240238106Sdeslinux* | k*bsd*-gnu | kopensolaris*-gnu) 3241238106Sdes lt_cv_deplibs_check_method=pass_all 3242238106Sdes ;; 3243238106Sdes 3244238106Sdesnetbsd*) 3245238106Sdes if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then 3246238106Sdes lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' 3247238106Sdes else 3248238106Sdes lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$' 3249238106Sdes fi 3250238106Sdes ;; 3251238106Sdes 3252238106Sdesnewos6*) 3253238106Sdes lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)' 3254238106Sdes lt_cv_file_magic_cmd=/usr/bin/file 3255238106Sdes lt_cv_file_magic_test_file=/usr/lib/libnls.so 3256238106Sdes ;; 3257238106Sdes 3258238106Sdes*nto* | *qnx*) 3259238106Sdes lt_cv_deplibs_check_method=pass_all 3260238106Sdes ;; 3261238106Sdes 3262238106Sdesopenbsd*) 3263238106Sdes if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then 3264238106Sdes lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$' 3265238106Sdes else 3266238106Sdes lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' 3267238106Sdes fi 3268238106Sdes ;; 3269238106Sdes 3270238106Sdesosf3* | osf4* | osf5*) 3271238106Sdes lt_cv_deplibs_check_method=pass_all 3272238106Sdes ;; 3273238106Sdes 3274238106Sdesrdos*) 3275238106Sdes lt_cv_deplibs_check_method=pass_all 3276238106Sdes ;; 3277238106Sdes 3278238106Sdessolaris*) 3279238106Sdes lt_cv_deplibs_check_method=pass_all 3280238106Sdes ;; 3281238106Sdes 3282238106Sdessysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) 3283238106Sdes lt_cv_deplibs_check_method=pass_all 3284238106Sdes ;; 3285238106Sdes 3286238106Sdessysv4 | sysv4.3*) 3287238106Sdes case $host_vendor in 3288238106Sdes motorola) 3289238106Sdes 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]]' 3290238106Sdes lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` 3291238106Sdes ;; 3292238106Sdes ncr) 3293238106Sdes lt_cv_deplibs_check_method=pass_all 3294238106Sdes ;; 3295238106Sdes sequent) 3296238106Sdes lt_cv_file_magic_cmd='/bin/file' 3297238106Sdes lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )' 3298238106Sdes ;; 3299238106Sdes sni) 3300238106Sdes lt_cv_file_magic_cmd='/bin/file' 3301238106Sdes lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib" 3302238106Sdes lt_cv_file_magic_test_file=/lib/libc.so 3303238106Sdes ;; 3304238106Sdes siemens) 3305238106Sdes lt_cv_deplibs_check_method=pass_all 3306238106Sdes ;; 3307238106Sdes pc) 3308238106Sdes lt_cv_deplibs_check_method=pass_all 3309238106Sdes ;; 3310238106Sdes esac 3311238106Sdes ;; 3312238106Sdes 3313238106Sdestpf*) 3314238106Sdes lt_cv_deplibs_check_method=pass_all 3315238106Sdes ;; 3316238106Sdesesac 3317238106Sdes]) 3318238106Sdes 3319238106Sdesfile_magic_glob= 3320238106Sdeswant_nocaseglob=no 3321238106Sdesif test "$build" = "$host"; then 3322238106Sdes case $host_os in 3323238106Sdes mingw* | pw32*) 3324238106Sdes if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then 3325238106Sdes want_nocaseglob=yes 3326238106Sdes else 3327238106Sdes file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[[\1]]\/[[\1]]\/g;/g"` 3328238106Sdes fi 3329238106Sdes ;; 3330238106Sdes esac 3331238106Sdesfi 3332238106Sdes 3333238106Sdesfile_magic_cmd=$lt_cv_file_magic_cmd 3334238106Sdesdeplibs_check_method=$lt_cv_deplibs_check_method 3335238106Sdestest -z "$deplibs_check_method" && deplibs_check_method=unknown 3336238106Sdes 3337238106Sdes_LT_DECL([], [deplibs_check_method], [1], 3338238106Sdes [Method to check whether dependent libraries are shared objects]) 3339238106Sdes_LT_DECL([], [file_magic_cmd], [1], 3340238106Sdes [Command to use when deplibs_check_method = "file_magic"]) 3341238106Sdes_LT_DECL([], [file_magic_glob], [1], 3342238106Sdes [How to find potential files when deplibs_check_method = "file_magic"]) 3343238106Sdes_LT_DECL([], [want_nocaseglob], [1], 3344238106Sdes [Find potential files using nocaseglob when deplibs_check_method = "file_magic"]) 3345238106Sdes])# _LT_CHECK_MAGIC_METHOD 3346238106Sdes 3347238106Sdes 3348238106Sdes# LT_PATH_NM 3349238106Sdes# ---------- 3350238106Sdes# find the pathname to a BSD- or MS-compatible name lister 3351238106SdesAC_DEFUN([LT_PATH_NM], 3352238106Sdes[AC_REQUIRE([AC_PROG_CC])dnl 3353238106SdesAC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM, 3354238106Sdes[if test -n "$NM"; then 3355238106Sdes # Let the user override the test. 3356238106Sdes lt_cv_path_NM="$NM" 3357238106Sdeselse 3358238106Sdes lt_nm_to_check="${ac_tool_prefix}nm" 3359238106Sdes if test -n "$ac_tool_prefix" && test "$build" = "$host"; then 3360238106Sdes lt_nm_to_check="$lt_nm_to_check nm" 3361238106Sdes fi 3362238106Sdes for lt_tmp_nm in $lt_nm_to_check; do 3363238106Sdes lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR 3364238106Sdes for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do 3365238106Sdes IFS="$lt_save_ifs" 3366238106Sdes test -z "$ac_dir" && ac_dir=. 3367238106Sdes tmp_nm="$ac_dir/$lt_tmp_nm" 3368238106Sdes if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then 3369238106Sdes # Check to see if the nm accepts a BSD-compat flag. 3370238106Sdes # Adding the `sed 1q' prevents false positives on HP-UX, which says: 3371238106Sdes # nm: unknown option "B" ignored 3372238106Sdes # Tru64's nm complains that /dev/null is an invalid object file 3373238106Sdes case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in 3374238106Sdes */dev/null* | *'Invalid file or object type'*) 3375238106Sdes lt_cv_path_NM="$tmp_nm -B" 3376238106Sdes break 3377238106Sdes ;; 3378238106Sdes *) 3379238106Sdes case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in 3380238106Sdes */dev/null*) 3381238106Sdes lt_cv_path_NM="$tmp_nm -p" 3382238106Sdes break 3383238106Sdes ;; 3384238106Sdes *) 3385238106Sdes lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but 3386238106Sdes continue # so that we can try to find one that supports BSD flags 3387238106Sdes ;; 3388238106Sdes esac 3389238106Sdes ;; 3390238106Sdes esac 3391238106Sdes fi 3392238106Sdes done 3393238106Sdes IFS="$lt_save_ifs" 3394238106Sdes done 3395238106Sdes : ${lt_cv_path_NM=no} 3396238106Sdesfi]) 3397238106Sdesif test "$lt_cv_path_NM" != "no"; then 3398238106Sdes NM="$lt_cv_path_NM" 3399238106Sdeselse 3400238106Sdes # Didn't find any BSD compatible name lister, look for dumpbin. 3401238106Sdes if test -n "$DUMPBIN"; then : 3402238106Sdes # Let the user override the test. 3403238106Sdes else 3404238106Sdes AC_CHECK_TOOLS(DUMPBIN, [dumpbin "link -dump"], :) 3405238106Sdes case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in 3406238106Sdes *COFF*) 3407238106Sdes DUMPBIN="$DUMPBIN -symbols" 3408238106Sdes ;; 3409238106Sdes *) 3410238106Sdes DUMPBIN=: 3411238106Sdes ;; 3412238106Sdes esac 3413238106Sdes fi 3414238106Sdes AC_SUBST([DUMPBIN]) 3415238106Sdes if test "$DUMPBIN" != ":"; then 3416238106Sdes NM="$DUMPBIN" 3417238106Sdes fi 3418238106Sdesfi 3419238106Sdestest -z "$NM" && NM=nm 3420238106SdesAC_SUBST([NM]) 3421238106Sdes_LT_DECL([], [NM], [1], [A BSD- or MS-compatible name lister])dnl 3422238106Sdes 3423238106SdesAC_CACHE_CHECK([the name lister ($NM) interface], [lt_cv_nm_interface], 3424238106Sdes [lt_cv_nm_interface="BSD nm" 3425238106Sdes echo "int some_variable = 0;" > conftest.$ac_ext 3426238106Sdes (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&AS_MESSAGE_LOG_FD) 3427238106Sdes (eval "$ac_compile" 2>conftest.err) 3428238106Sdes cat conftest.err >&AS_MESSAGE_LOG_FD 3429238106Sdes (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD) 3430238106Sdes (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) 3431238106Sdes cat conftest.err >&AS_MESSAGE_LOG_FD 3432238106Sdes (eval echo "\"\$as_me:$LINENO: output\"" >&AS_MESSAGE_LOG_FD) 3433238106Sdes cat conftest.out >&AS_MESSAGE_LOG_FD 3434238106Sdes if $GREP 'External.*some_variable' conftest.out > /dev/null; then 3435238106Sdes lt_cv_nm_interface="MS dumpbin" 3436238106Sdes fi 3437238106Sdes rm -f conftest*]) 3438238106Sdes])# LT_PATH_NM 3439238106Sdes 3440238106Sdes# Old names: 3441238106SdesAU_ALIAS([AM_PROG_NM], [LT_PATH_NM]) 3442238106SdesAU_ALIAS([AC_PROG_NM], [LT_PATH_NM]) 3443238106Sdesdnl aclocal-1.4 backwards compatibility: 3444238106Sdesdnl AC_DEFUN([AM_PROG_NM], []) 3445238106Sdesdnl AC_DEFUN([AC_PROG_NM], []) 3446238106Sdes 3447238106Sdes# _LT_CHECK_SHAREDLIB_FROM_LINKLIB 3448238106Sdes# -------------------------------- 3449238106Sdes# how to determine the name of the shared library 3450238106Sdes# associated with a specific link library. 3451238106Sdes# -- PORTME fill in with the dynamic library characteristics 3452238106Sdesm4_defun([_LT_CHECK_SHAREDLIB_FROM_LINKLIB], 3453238106Sdes[m4_require([_LT_DECL_EGREP]) 3454238106Sdesm4_require([_LT_DECL_OBJDUMP]) 3455238106Sdesm4_require([_LT_DECL_DLLTOOL]) 3456238106SdesAC_CACHE_CHECK([how to associate runtime and link libraries], 3457238106Sdeslt_cv_sharedlib_from_linklib_cmd, 3458238106Sdes[lt_cv_sharedlib_from_linklib_cmd='unknown' 3459238106Sdes 3460238106Sdescase $host_os in 3461238106Sdescygwin* | mingw* | pw32* | cegcc*) 3462238106Sdes # two different shell functions defined in ltmain.sh 3463238106Sdes # decide which to use based on capabilities of $DLLTOOL 3464238106Sdes case `$DLLTOOL --help 2>&1` in 3465238106Sdes *--identify-strict*) 3466238106Sdes lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib 3467238106Sdes ;; 3468238106Sdes *) 3469238106Sdes lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback 3470238106Sdes ;; 3471238106Sdes esac 3472238106Sdes ;; 3473238106Sdes*) 3474238106Sdes # fallback: assume linklib IS sharedlib 3475238106Sdes lt_cv_sharedlib_from_linklib_cmd="$ECHO" 3476238106Sdes ;; 3477238106Sdesesac 3478238106Sdes]) 3479238106Sdessharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd 3480238106Sdestest -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO 3481238106Sdes 3482238106Sdes_LT_DECL([], [sharedlib_from_linklib_cmd], [1], 3483238106Sdes [Command to associate shared and link libraries]) 3484238106Sdes])# _LT_CHECK_SHAREDLIB_FROM_LINKLIB 3485238106Sdes 3486238106Sdes 3487238106Sdes# _LT_PATH_MANIFEST_TOOL 3488238106Sdes# ---------------------- 3489238106Sdes# locate the manifest tool 3490238106Sdesm4_defun([_LT_PATH_MANIFEST_TOOL], 3491238106Sdes[AC_CHECK_TOOL(MANIFEST_TOOL, mt, :) 3492238106Sdestest -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt 3493238106SdesAC_CACHE_CHECK([if $MANIFEST_TOOL is a manifest tool], [lt_cv_path_mainfest_tool], 3494238106Sdes [lt_cv_path_mainfest_tool=no 3495238106Sdes echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&AS_MESSAGE_LOG_FD 3496238106Sdes $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out 3497238106Sdes cat conftest.err >&AS_MESSAGE_LOG_FD 3498238106Sdes if $GREP 'Manifest Tool' conftest.out > /dev/null; then 3499238106Sdes lt_cv_path_mainfest_tool=yes 3500238106Sdes fi 3501238106Sdes rm -f conftest*]) 3502238106Sdesif test "x$lt_cv_path_mainfest_tool" != xyes; then 3503238106Sdes MANIFEST_TOOL=: 3504238106Sdesfi 3505238106Sdes_LT_DECL([], [MANIFEST_TOOL], [1], [Manifest tool])dnl 3506238106Sdes])# _LT_PATH_MANIFEST_TOOL 3507238106Sdes 3508238106Sdes 3509238106Sdes# LT_LIB_M 3510238106Sdes# -------- 3511238106Sdes# check for math library 3512238106SdesAC_DEFUN([LT_LIB_M], 3513238106Sdes[AC_REQUIRE([AC_CANONICAL_HOST])dnl 3514238106SdesLIBM= 3515238106Sdescase $host in 3516238106Sdes*-*-beos* | *-*-cegcc* | *-*-cygwin* | *-*-haiku* | *-*-pw32* | *-*-darwin*) 3517238106Sdes # These system don't have libm, or don't need it 3518238106Sdes ;; 3519238106Sdes*-ncr-sysv4.3*) 3520238106Sdes AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw") 3521238106Sdes AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm") 3522238106Sdes ;; 3523238106Sdes*) 3524238106Sdes AC_CHECK_LIB(m, cos, LIBM="-lm") 3525238106Sdes ;; 3526238106Sdesesac 3527238106SdesAC_SUBST([LIBM]) 3528238106Sdes])# LT_LIB_M 3529238106Sdes 3530238106Sdes# Old name: 3531238106SdesAU_ALIAS([AC_CHECK_LIBM], [LT_LIB_M]) 3532238106Sdesdnl aclocal-1.4 backwards compatibility: 3533238106Sdesdnl AC_DEFUN([AC_CHECK_LIBM], []) 3534238106Sdes 3535238106Sdes 3536238106Sdes# _LT_COMPILER_NO_RTTI([TAGNAME]) 3537238106Sdes# ------------------------------- 3538238106Sdesm4_defun([_LT_COMPILER_NO_RTTI], 3539238106Sdes[m4_require([_LT_TAG_COMPILER])dnl 3540238106Sdes 3541238106Sdes_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= 3542238106Sdes 3543238106Sdesif test "$GCC" = yes; then 3544238106Sdes case $cc_basename in 3545238106Sdes nvcc*) 3546238106Sdes _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -Xcompiler -fno-builtin' ;; 3547238106Sdes *) 3548238106Sdes _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' ;; 3549238106Sdes esac 3550238106Sdes 3551238106Sdes _LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions], 3552238106Sdes lt_cv_prog_compiler_rtti_exceptions, 3553238106Sdes [-fno-rtti -fno-exceptions], [], 3554238106Sdes [_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"]) 3555238106Sdesfi 3556238106Sdes_LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1], 3557238106Sdes [Compiler flag to turn off builtin functions]) 3558238106Sdes])# _LT_COMPILER_NO_RTTI 3559238106Sdes 3560238106Sdes 3561238106Sdes# _LT_CMD_GLOBAL_SYMBOLS 3562238106Sdes# ---------------------- 3563238106Sdesm4_defun([_LT_CMD_GLOBAL_SYMBOLS], 3564238106Sdes[AC_REQUIRE([AC_CANONICAL_HOST])dnl 3565238106SdesAC_REQUIRE([AC_PROG_CC])dnl 3566238106SdesAC_REQUIRE([AC_PROG_AWK])dnl 3567238106SdesAC_REQUIRE([LT_PATH_NM])dnl 3568238106SdesAC_REQUIRE([LT_PATH_LD])dnl 3569238106Sdesm4_require([_LT_DECL_SED])dnl 3570238106Sdesm4_require([_LT_DECL_EGREP])dnl 3571238106Sdesm4_require([_LT_TAG_COMPILER])dnl 3572238106Sdes 3573238106Sdes# Check for command to grab the raw symbol name followed by C symbol from nm. 3574238106SdesAC_MSG_CHECKING([command to parse $NM output from $compiler object]) 3575238106SdesAC_CACHE_VAL([lt_cv_sys_global_symbol_pipe], 3576238106Sdes[ 3577238106Sdes# These are sane defaults that work on at least a few old systems. 3578238106Sdes# [They come from Ultrix. What could be older than Ultrix?!! ;)] 3579238106Sdes 3580238106Sdes# Character class describing NM global symbol codes. 3581238106Sdessymcode='[[BCDEGRST]]' 3582238106Sdes 3583238106Sdes# Regexp to match symbols that can be accessed directly from C. 3584238106Sdessympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)' 3585238106Sdes 3586238106Sdes# Define system-specific variables. 3587238106Sdescase $host_os in 3588238106Sdesaix*) 3589238106Sdes symcode='[[BCDT]]' 3590238106Sdes ;; 3591238106Sdescygwin* | mingw* | pw32* | cegcc*) 3592238106Sdes symcode='[[ABCDGISTW]]' 3593238106Sdes ;; 3594238106Sdeshpux*) 3595238106Sdes if test "$host_cpu" = ia64; then 3596238106Sdes symcode='[[ABCDEGRST]]' 3597238106Sdes fi 3598238106Sdes ;; 3599238106Sdesirix* | nonstopux*) 3600238106Sdes symcode='[[BCDEGRST]]' 3601238106Sdes ;; 3602238106Sdesosf*) 3603238106Sdes symcode='[[BCDEGQRST]]' 3604238106Sdes ;; 3605238106Sdessolaris*) 3606238106Sdes symcode='[[BDRT]]' 3607238106Sdes ;; 3608238106Sdessco3.2v5*) 3609238106Sdes symcode='[[DT]]' 3610238106Sdes ;; 3611238106Sdessysv4.2uw2*) 3612238106Sdes symcode='[[DT]]' 3613238106Sdes ;; 3614238106Sdessysv5* | sco5v6* | unixware* | OpenUNIX*) 3615238106Sdes symcode='[[ABDT]]' 3616238106Sdes ;; 3617238106Sdessysv4) 3618238106Sdes symcode='[[DFNSTU]]' 3619238106Sdes ;; 3620238106Sdesesac 3621238106Sdes 3622238106Sdes# If we're using GNU nm, then use its standard symbol codes. 3623238106Sdescase `$NM -V 2>&1` in 3624238106Sdes*GNU* | *'with BFD'*) 3625238106Sdes symcode='[[ABCDGIRSTW]]' ;; 3626238106Sdesesac 3627238106Sdes 3628238106Sdes# Transform an extracted symbol line into a proper C declaration. 3629238106Sdes# Some systems (esp. on ia64) link data and code symbols differently, 3630238106Sdes# so use this general approach. 3631238106Sdeslt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" 3632238106Sdes 3633238106Sdes# Transform an extracted symbol line into symbol name and symbol address 3634238106Sdeslt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\)[[ ]]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p'" 3635238106Sdeslt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([[^ ]]*\)[[ ]]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \(lib[[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"lib\2\", (void *) \&\2},/p'" 3636238106Sdes 3637238106Sdes# Handle CRLF in mingw tool chain 3638238106Sdesopt_cr= 3639238106Sdescase $build_os in 3640238106Sdesmingw*) 3641238106Sdes opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp 3642238106Sdes ;; 3643238106Sdesesac 3644238106Sdes 3645238106Sdes# Try without a prefix underscore, then with it. 3646238106Sdesfor ac_symprfx in "" "_"; do 3647238106Sdes 3648238106Sdes # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. 3649238106Sdes symxfrm="\\1 $ac_symprfx\\2 \\2" 3650238106Sdes 3651238106Sdes # Write the raw and C identifiers. 3652238106Sdes if test "$lt_cv_nm_interface" = "MS dumpbin"; then 3653238106Sdes # Fake it for dumpbin and say T for any non-static function 3654238106Sdes # and D for any global variable. 3655238106Sdes # Also find C++ and __fastcall symbols from MSVC++, 3656238106Sdes # which start with @ or ?. 3657238106Sdes lt_cv_sys_global_symbol_pipe="$AWK ['"\ 3658238106Sdes" {last_section=section; section=\$ 3};"\ 3659238106Sdes" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\ 3660238106Sdes" \$ 0!~/External *\|/{next};"\ 3661238106Sdes" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\ 3662238106Sdes" {if(hide[section]) next};"\ 3663238106Sdes" {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\ 3664238106Sdes" {split(\$ 0, a, /\||\r/); split(a[2], s)};"\ 3665238106Sdes" s[1]~/^[@?]/{print s[1], s[1]; next};"\ 3666238106Sdes" s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\ 3667238106Sdes" ' prfx=^$ac_symprfx]" 3668238106Sdes else 3669238106Sdes lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" 3670238106Sdes fi 3671238106Sdes lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'" 3672238106Sdes 3673238106Sdes # Check to see that the pipe works correctly. 3674238106Sdes pipe_works=no 3675238106Sdes 3676238106Sdes rm -f conftest* 3677238106Sdes cat > conftest.$ac_ext <<_LT_EOF 3678238106Sdes#ifdef __cplusplus 3679238106Sdesextern "C" { 3680238106Sdes#endif 3681238106Sdeschar nm_test_var; 3682238106Sdesvoid nm_test_func(void); 3683238106Sdesvoid nm_test_func(void){} 3684238106Sdes#ifdef __cplusplus 3685238106Sdes} 3686238106Sdes#endif 3687238106Sdesint main(){nm_test_var='a';nm_test_func();return(0);} 3688238106Sdes_LT_EOF 3689238106Sdes 3690238106Sdes if AC_TRY_EVAL(ac_compile); then 3691238106Sdes # Now try to grab the symbols. 3692238106Sdes nlist=conftest.nm 3693238106Sdes if AC_TRY_EVAL(NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) && test -s "$nlist"; then 3694238106Sdes # Try sorting and uniquifying the output. 3695238106Sdes if sort "$nlist" | uniq > "$nlist"T; then 3696238106Sdes mv -f "$nlist"T "$nlist" 3697238106Sdes else 3698238106Sdes rm -f "$nlist"T 3699238106Sdes fi 3700238106Sdes 3701238106Sdes # Make sure that we snagged all the symbols we need. 3702238106Sdes if $GREP ' nm_test_var$' "$nlist" >/dev/null; then 3703238106Sdes if $GREP ' nm_test_func$' "$nlist" >/dev/null; then 3704238106Sdes cat <<_LT_EOF > conftest.$ac_ext 3705238106Sdes/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ 3706238106Sdes#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE) 3707238106Sdes/* DATA imports from DLLs on WIN32 con't be const, because runtime 3708238106Sdes relocations are performed -- see ld's documentation on pseudo-relocs. */ 3709238106Sdes# define LT@&t@_DLSYM_CONST 3710238106Sdes#elif defined(__osf__) 3711238106Sdes/* This system does not cope well with relocations in const data. */ 3712238106Sdes# define LT@&t@_DLSYM_CONST 3713238106Sdes#else 3714238106Sdes# define LT@&t@_DLSYM_CONST const 3715238106Sdes#endif 3716238106Sdes 3717238106Sdes#ifdef __cplusplus 3718238106Sdesextern "C" { 3719238106Sdes#endif 3720238106Sdes 3721238106Sdes_LT_EOF 3722238106Sdes # Now generate the symbol file. 3723238106Sdes eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext' 3724238106Sdes 3725238106Sdes cat <<_LT_EOF >> conftest.$ac_ext 3726238106Sdes 3727238106Sdes/* The mapping between symbol names and symbols. */ 3728238106SdesLT@&t@_DLSYM_CONST struct { 3729238106Sdes const char *name; 3730238106Sdes void *address; 3731238106Sdes} 3732238106Sdeslt__PROGRAM__LTX_preloaded_symbols[[]] = 3733238106Sdes{ 3734238106Sdes { "@PROGRAM@", (void *) 0 }, 3735238106Sdes_LT_EOF 3736238106Sdes $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext 3737238106Sdes cat <<\_LT_EOF >> conftest.$ac_ext 3738238106Sdes {0, (void *) 0} 3739238106Sdes}; 3740238106Sdes 3741238106Sdes/* This works around a problem in FreeBSD linker */ 3742238106Sdes#ifdef FREEBSD_WORKAROUND 3743238106Sdesstatic const void *lt_preloaded_setup() { 3744238106Sdes return lt__PROGRAM__LTX_preloaded_symbols; 3745238106Sdes} 3746238106Sdes#endif 3747238106Sdes 3748238106Sdes#ifdef __cplusplus 3749238106Sdes} 3750238106Sdes#endif 3751238106Sdes_LT_EOF 3752238106Sdes # Now try linking the two files. 3753238106Sdes mv conftest.$ac_objext conftstm.$ac_objext 3754238106Sdes lt_globsym_save_LIBS=$LIBS 3755238106Sdes lt_globsym_save_CFLAGS=$CFLAGS 3756238106Sdes LIBS="conftstm.$ac_objext" 3757238106Sdes CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)" 3758238106Sdes if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then 3759238106Sdes pipe_works=yes 3760238106Sdes fi 3761238106Sdes LIBS=$lt_globsym_save_LIBS 3762238106Sdes CFLAGS=$lt_globsym_save_CFLAGS 3763238106Sdes else 3764238106Sdes echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD 3765238106Sdes fi 3766238106Sdes else 3767238106Sdes echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD 3768238106Sdes fi 3769238106Sdes else 3770238106Sdes echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD 3771238106Sdes fi 3772238106Sdes else 3773238106Sdes echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD 3774238106Sdes cat conftest.$ac_ext >&5 3775238106Sdes fi 3776238106Sdes rm -rf conftest* conftst* 3777238106Sdes 3778238106Sdes # Do not use the global_symbol_pipe unless it works. 3779238106Sdes if test "$pipe_works" = yes; then 3780238106Sdes break 3781238106Sdes else 3782238106Sdes lt_cv_sys_global_symbol_pipe= 3783238106Sdes fi 3784238106Sdesdone 3785238106Sdes]) 3786238106Sdesif test -z "$lt_cv_sys_global_symbol_pipe"; then 3787238106Sdes lt_cv_sys_global_symbol_to_cdecl= 3788238106Sdesfi 3789238106Sdesif test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then 3790238106Sdes AC_MSG_RESULT(failed) 3791238106Sdeselse 3792238106Sdes AC_MSG_RESULT(ok) 3793238106Sdesfi 3794238106Sdes 3795238106Sdes# Response file support. 3796238106Sdesif test "$lt_cv_nm_interface" = "MS dumpbin"; then 3797238106Sdes nm_file_list_spec='@' 3798238106Sdeselif $NM --help 2>/dev/null | grep '[[@]]FILE' >/dev/null; then 3799238106Sdes nm_file_list_spec='@' 3800238106Sdesfi 3801238106Sdes 3802238106Sdes_LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1], 3803238106Sdes [Take the output of nm and produce a listing of raw symbols and C names]) 3804238106Sdes_LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1], 3805238106Sdes [Transform the output of nm in a proper C declaration]) 3806238106Sdes_LT_DECL([global_symbol_to_c_name_address], 3807238106Sdes [lt_cv_sys_global_symbol_to_c_name_address], [1], 3808238106Sdes [Transform the output of nm in a C name address pair]) 3809238106Sdes_LT_DECL([global_symbol_to_c_name_address_lib_prefix], 3810238106Sdes [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1], 3811238106Sdes [Transform the output of nm in a C name address pair when lib prefix is needed]) 3812238106Sdes_LT_DECL([], [nm_file_list_spec], [1], 3813238106Sdes [Specify filename containing input files for $NM]) 3814238106Sdes]) # _LT_CMD_GLOBAL_SYMBOLS 3815238106Sdes 3816238106Sdes 3817238106Sdes# _LT_COMPILER_PIC([TAGNAME]) 3818238106Sdes# --------------------------- 3819238106Sdesm4_defun([_LT_COMPILER_PIC], 3820238106Sdes[m4_require([_LT_TAG_COMPILER])dnl 3821238106Sdes_LT_TAGVAR(lt_prog_compiler_wl, $1)= 3822238106Sdes_LT_TAGVAR(lt_prog_compiler_pic, $1)= 3823238106Sdes_LT_TAGVAR(lt_prog_compiler_static, $1)= 3824238106Sdes 3825238106Sdesm4_if([$1], [CXX], [ 3826238106Sdes # C++ specific cases for pic, static, wl, etc. 3827238106Sdes if test "$GXX" = yes; then 3828238106Sdes _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 3829238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 3830238106Sdes 3831238106Sdes case $host_os in 3832238106Sdes aix*) 3833238106Sdes # All AIX code is PIC. 3834238106Sdes if test "$host_cpu" = ia64; then 3835238106Sdes # AIX 5 now supports IA64 processor 3836238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 3837238106Sdes fi 3838238106Sdes ;; 3839238106Sdes 3840238106Sdes amigaos*) 3841238106Sdes case $host_cpu in 3842238106Sdes powerpc) 3843238106Sdes # see comment about AmigaOS4 .so support 3844238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 3845238106Sdes ;; 3846238106Sdes m68k) 3847238106Sdes # FIXME: we need at least 68020 code to build shared libraries, but 3848238106Sdes # adding the `-m68020' flag to GCC prevents building anything better, 3849238106Sdes # like `-m68040'. 3850238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' 3851238106Sdes ;; 3852238106Sdes esac 3853238106Sdes ;; 3854238106Sdes 3855238106Sdes beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) 3856238106Sdes # PIC is the default for these OSes. 3857238106Sdes ;; 3858238106Sdes mingw* | cygwin* | os2* | pw32* | cegcc*) 3859238106Sdes # This hack is so that the source file can tell whether it is being 3860238106Sdes # built for inclusion in a dll (and should export symbols for example). 3861238106Sdes # Although the cygwin gcc ignores -fPIC, still need this for old-style 3862238106Sdes # (--disable-auto-import) libraries 3863238106Sdes m4_if([$1], [GCJ], [], 3864238106Sdes [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) 3865238106Sdes ;; 3866238106Sdes darwin* | rhapsody*) 3867238106Sdes # PIC is the default on this platform 3868238106Sdes # Common symbols not allowed in MH_DYLIB files 3869238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' 3870238106Sdes ;; 3871238106Sdes *djgpp*) 3872238106Sdes # DJGPP does not support shared libraries at all 3873238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)= 3874238106Sdes ;; 3875238106Sdes haiku*) 3876238106Sdes # PIC is the default for Haiku. 3877238106Sdes # The "-static" flag exists, but is broken. 3878238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)= 3879238106Sdes ;; 3880238106Sdes interix[[3-9]]*) 3881238106Sdes # Interix 3.x gcc -fpic/-fPIC options generate broken code. 3882238106Sdes # Instead, we relocate shared libraries at runtime. 3883238106Sdes ;; 3884238106Sdes sysv4*MP*) 3885238106Sdes if test -d /usr/nec; then 3886238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic 3887238106Sdes fi 3888238106Sdes ;; 3889238106Sdes hpux*) 3890238106Sdes # PIC is the default for 64-bit PA HP-UX, but not for 32-bit 3891238106Sdes # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag 3892238106Sdes # sets the default TLS model and affects inlining. 3893238106Sdes case $host_cpu in 3894238106Sdes hppa*64*) 3895238106Sdes ;; 3896238106Sdes *) 3897238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 3898238106Sdes ;; 3899238106Sdes esac 3900238106Sdes ;; 3901238106Sdes *qnx* | *nto*) 3902238106Sdes # QNX uses GNU C++, but need to define -shared option too, otherwise 3903238106Sdes # it will coredump. 3904238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' 3905238106Sdes ;; 3906238106Sdes *) 3907238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 3908238106Sdes ;; 3909238106Sdes esac 3910238106Sdes else 3911238106Sdes case $host_os in 3912238106Sdes aix[[4-9]]*) 3913238106Sdes # All AIX code is PIC. 3914238106Sdes if test "$host_cpu" = ia64; then 3915238106Sdes # AIX 5 now supports IA64 processor 3916238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 3917238106Sdes else 3918238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' 3919238106Sdes fi 3920238106Sdes ;; 3921238106Sdes chorus*) 3922238106Sdes case $cc_basename in 3923238106Sdes cxch68*) 3924238106Sdes # Green Hills C++ Compiler 3925238106Sdes # _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" 3926238106Sdes ;; 3927238106Sdes esac 3928238106Sdes ;; 3929238106Sdes mingw* | cygwin* | os2* | pw32* | cegcc*) 3930238106Sdes # This hack is so that the source file can tell whether it is being 3931238106Sdes # built for inclusion in a dll (and should export symbols for example). 3932238106Sdes m4_if([$1], [GCJ], [], 3933238106Sdes [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) 3934238106Sdes ;; 3935238106Sdes dgux*) 3936238106Sdes case $cc_basename in 3937238106Sdes ec++*) 3938238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 3939238106Sdes ;; 3940238106Sdes ghcx*) 3941238106Sdes # Green Hills C++ Compiler 3942238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 3943238106Sdes ;; 3944238106Sdes *) 3945238106Sdes ;; 3946238106Sdes esac 3947238106Sdes ;; 3948238106Sdes freebsd* | dragonfly*) 3949238106Sdes # FreeBSD uses GNU C++ 3950238106Sdes ;; 3951238106Sdes hpux9* | hpux10* | hpux11*) 3952238106Sdes case $cc_basename in 3953238106Sdes CC*) 3954238106Sdes _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 3955238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' 3956238106Sdes if test "$host_cpu" != ia64; then 3957238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' 3958238106Sdes fi 3959238106Sdes ;; 3960238106Sdes aCC*) 3961238106Sdes _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 3962238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' 3963238106Sdes case $host_cpu in 3964238106Sdes hppa*64*|ia64*) 3965238106Sdes # +Z the default 3966238106Sdes ;; 3967238106Sdes *) 3968238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' 3969238106Sdes ;; 3970238106Sdes esac 3971238106Sdes ;; 3972238106Sdes *) 3973238106Sdes ;; 3974238106Sdes esac 3975238106Sdes ;; 3976238106Sdes interix*) 3977238106Sdes # This is c89, which is MS Visual C++ (no shared libs) 3978238106Sdes # Anyone wants to do a port? 3979238106Sdes ;; 3980238106Sdes irix5* | irix6* | nonstopux*) 3981238106Sdes case $cc_basename in 3982238106Sdes CC*) 3983238106Sdes _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 3984238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 3985238106Sdes # CC pic flag -KPIC is the default. 3986238106Sdes ;; 3987238106Sdes *) 3988238106Sdes ;; 3989238106Sdes esac 3990238106Sdes ;; 3991238106Sdes linux* | k*bsd*-gnu | kopensolaris*-gnu) 3992238106Sdes case $cc_basename in 3993238106Sdes KCC*) 3994238106Sdes # KAI C++ Compiler 3995238106Sdes _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' 3996238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 3997238106Sdes ;; 3998238106Sdes ecpc* ) 3999238106Sdes # old Intel C++ for x86_64 which still supported -KPIC. 4000238106Sdes _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4001238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4002238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 4003238106Sdes ;; 4004238106Sdes icpc* ) 4005238106Sdes # Intel C++, used to be incompatible with GCC. 4006238106Sdes # ICC 10 doesn't accept -KPIC any more. 4007238106Sdes _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4008238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 4009238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 4010238106Sdes ;; 4011238106Sdes pgCC* | pgcpp*) 4012238106Sdes # Portland Group C++ compiler 4013238106Sdes _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4014238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' 4015238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4016238106Sdes ;; 4017238106Sdes cxx*) 4018238106Sdes # Compaq C++ 4019238106Sdes # Make sure the PIC flag is empty. It appears that all Alpha 4020238106Sdes # Linux and Compaq Tru64 Unix objects are PIC. 4021238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)= 4022238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 4023238106Sdes ;; 4024238106Sdes xlc* | xlC* | bgxl[[cC]]* | mpixl[[cC]]*) 4025238106Sdes # IBM XL 8.0, 9.0 on PPC and BlueGene 4026238106Sdes _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4027238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' 4028238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' 4029238106Sdes ;; 4030238106Sdes *) 4031238106Sdes case `$CC -V 2>&1 | sed 5q` in 4032238106Sdes *Sun\ C*) 4033238106Sdes # Sun C++ 5.9 4034238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4035238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4036238106Sdes _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' 4037238106Sdes ;; 4038238106Sdes esac 4039238106Sdes ;; 4040238106Sdes esac 4041238106Sdes ;; 4042238106Sdes lynxos*) 4043238106Sdes ;; 4044238106Sdes m88k*) 4045238106Sdes ;; 4046238106Sdes mvs*) 4047238106Sdes case $cc_basename in 4048238106Sdes cxx*) 4049238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall' 4050238106Sdes ;; 4051238106Sdes *) 4052238106Sdes ;; 4053238106Sdes esac 4054238106Sdes ;; 4055238106Sdes netbsd*) 4056238106Sdes ;; 4057238106Sdes *qnx* | *nto*) 4058238106Sdes # QNX uses GNU C++, but need to define -shared option too, otherwise 4059238106Sdes # it will coredump. 4060238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' 4061238106Sdes ;; 4062238106Sdes osf3* | osf4* | osf5*) 4063238106Sdes case $cc_basename in 4064238106Sdes KCC*) 4065238106Sdes _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' 4066238106Sdes ;; 4067238106Sdes RCC*) 4068238106Sdes # Rational C++ 2.4.1 4069238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 4070238106Sdes ;; 4071238106Sdes cxx*) 4072238106Sdes # Digital/Compaq C++ 4073238106Sdes _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4074238106Sdes # Make sure the PIC flag is empty. It appears that all Alpha 4075238106Sdes # Linux and Compaq Tru64 Unix objects are PIC. 4076238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)= 4077238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 4078238106Sdes ;; 4079238106Sdes *) 4080238106Sdes ;; 4081238106Sdes esac 4082238106Sdes ;; 4083238106Sdes psos*) 4084238106Sdes ;; 4085238106Sdes solaris*) 4086238106Sdes case $cc_basename in 4087238106Sdes CC* | sunCC*) 4088238106Sdes # Sun C++ 4.2, 5.x and Centerline C++ 4089238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4090238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4091238106Sdes _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' 4092238106Sdes ;; 4093238106Sdes gcx*) 4094238106Sdes # Green Hills C++ Compiler 4095238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' 4096238106Sdes ;; 4097238106Sdes *) 4098238106Sdes ;; 4099238106Sdes esac 4100238106Sdes ;; 4101238106Sdes sunos4*) 4102238106Sdes case $cc_basename in 4103238106Sdes CC*) 4104238106Sdes # Sun C++ 4.x 4105238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 4106238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4107238106Sdes ;; 4108238106Sdes lcc*) 4109238106Sdes # Lucid 4110238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 4111238106Sdes ;; 4112238106Sdes *) 4113238106Sdes ;; 4114238106Sdes esac 4115238106Sdes ;; 4116238106Sdes sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) 4117238106Sdes case $cc_basename in 4118238106Sdes CC*) 4119238106Sdes _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4120238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4121238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4122238106Sdes ;; 4123238106Sdes esac 4124238106Sdes ;; 4125238106Sdes tandem*) 4126238106Sdes case $cc_basename in 4127238106Sdes NCC*) 4128238106Sdes # NonStop-UX NCC 3.20 4129238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4130238106Sdes ;; 4131238106Sdes *) 4132238106Sdes ;; 4133238106Sdes esac 4134238106Sdes ;; 4135238106Sdes vxworks*) 4136238106Sdes ;; 4137238106Sdes *) 4138238106Sdes _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 4139238106Sdes ;; 4140238106Sdes esac 4141238106Sdes fi 4142238106Sdes], 4143238106Sdes[ 4144238106Sdes if test "$GCC" = yes; then 4145238106Sdes _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4146238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 4147238106Sdes 4148238106Sdes case $host_os in 4149238106Sdes aix*) 4150238106Sdes # All AIX code is PIC. 4151238106Sdes if test "$host_cpu" = ia64; then 4152238106Sdes # AIX 5 now supports IA64 processor 4153238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4154238106Sdes fi 4155238106Sdes ;; 4156238106Sdes 4157238106Sdes amigaos*) 4158238106Sdes case $host_cpu in 4159238106Sdes powerpc) 4160238106Sdes # see comment about AmigaOS4 .so support 4161238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 4162238106Sdes ;; 4163238106Sdes m68k) 4164238106Sdes # FIXME: we need at least 68020 code to build shared libraries, but 4165238106Sdes # adding the `-m68020' flag to GCC prevents building anything better, 4166238106Sdes # like `-m68040'. 4167238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' 4168238106Sdes ;; 4169238106Sdes esac 4170238106Sdes ;; 4171238106Sdes 4172238106Sdes beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) 4173238106Sdes # PIC is the default for these OSes. 4174238106Sdes ;; 4175238106Sdes 4176238106Sdes mingw* | cygwin* | pw32* | os2* | cegcc*) 4177238106Sdes # This hack is so that the source file can tell whether it is being 4178238106Sdes # built for inclusion in a dll (and should export symbols for example). 4179238106Sdes # Although the cygwin gcc ignores -fPIC, still need this for old-style 4180238106Sdes # (--disable-auto-import) libraries 4181238106Sdes m4_if([$1], [GCJ], [], 4182238106Sdes [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) 4183238106Sdes ;; 4184238106Sdes 4185238106Sdes darwin* | rhapsody*) 4186238106Sdes # PIC is the default on this platform 4187238106Sdes # Common symbols not allowed in MH_DYLIB files 4188238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' 4189238106Sdes ;; 4190238106Sdes 4191238106Sdes haiku*) 4192238106Sdes # PIC is the default for Haiku. 4193238106Sdes # The "-static" flag exists, but is broken. 4194238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)= 4195238106Sdes ;; 4196238106Sdes 4197238106Sdes hpux*) 4198238106Sdes # PIC is the default for 64-bit PA HP-UX, but not for 32-bit 4199238106Sdes # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag 4200238106Sdes # sets the default TLS model and affects inlining. 4201238106Sdes case $host_cpu in 4202238106Sdes hppa*64*) 4203238106Sdes # +Z the default 4204238106Sdes ;; 4205238106Sdes *) 4206238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 4207238106Sdes ;; 4208238106Sdes esac 4209238106Sdes ;; 4210238106Sdes 4211238106Sdes interix[[3-9]]*) 4212238106Sdes # Interix 3.x gcc -fpic/-fPIC options generate broken code. 4213238106Sdes # Instead, we relocate shared libraries at runtime. 4214238106Sdes ;; 4215238106Sdes 4216238106Sdes msdosdjgpp*) 4217238106Sdes # Just because we use GCC doesn't mean we suddenly get shared libraries 4218238106Sdes # on systems that don't support them. 4219238106Sdes _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 4220238106Sdes enable_shared=no 4221238106Sdes ;; 4222238106Sdes 4223238106Sdes *nto* | *qnx*) 4224238106Sdes # QNX uses GNU C++, but need to define -shared option too, otherwise 4225238106Sdes # it will coredump. 4226238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' 4227238106Sdes ;; 4228238106Sdes 4229238106Sdes sysv4*MP*) 4230238106Sdes if test -d /usr/nec; then 4231238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic 4232238106Sdes fi 4233238106Sdes ;; 4234238106Sdes 4235238106Sdes *) 4236238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 4237238106Sdes ;; 4238238106Sdes esac 4239238106Sdes 4240238106Sdes case $cc_basename in 4241238106Sdes nvcc*) # Cuda Compiler Driver 2.2 4242238106Sdes _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Xlinker ' 4243238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Xcompiler -fPIC' 4244238106Sdes ;; 4245238106Sdes esac 4246238106Sdes else 4247238106Sdes # PORTME Check for flag to pass linker flags through the system compiler. 4248238106Sdes case $host_os in 4249238106Sdes aix*) 4250238106Sdes _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4251238106Sdes if test "$host_cpu" = ia64; then 4252238106Sdes # AIX 5 now supports IA64 processor 4253238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4254238106Sdes else 4255238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' 4256238106Sdes fi 4257238106Sdes ;; 4258238106Sdes 4259238106Sdes mingw* | cygwin* | pw32* | os2* | cegcc*) 4260238106Sdes # This hack is so that the source file can tell whether it is being 4261238106Sdes # built for inclusion in a dll (and should export symbols for example). 4262238106Sdes m4_if([$1], [GCJ], [], 4263238106Sdes [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) 4264238106Sdes ;; 4265238106Sdes 4266238106Sdes hpux9* | hpux10* | hpux11*) 4267238106Sdes _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4268238106Sdes # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but 4269238106Sdes # not for PA HP-UX. 4270238106Sdes case $host_cpu in 4271238106Sdes hppa*64*|ia64*) 4272238106Sdes # +Z the default 4273238106Sdes ;; 4274238106Sdes *) 4275238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' 4276238106Sdes ;; 4277238106Sdes esac 4278238106Sdes # Is there a better lt_prog_compiler_static that works with the bundled CC? 4279238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' 4280238106Sdes ;; 4281238106Sdes 4282238106Sdes irix5* | irix6* | nonstopux*) 4283238106Sdes _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4284238106Sdes # PIC (with -KPIC) is the default. 4285238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 4286238106Sdes ;; 4287238106Sdes 4288238106Sdes linux* | k*bsd*-gnu | kopensolaris*-gnu) 4289238106Sdes case $cc_basename in 4290238106Sdes # old Intel for x86_64 which still supported -KPIC. 4291238106Sdes ecc*) 4292238106Sdes _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4293238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4294238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 4295238106Sdes ;; 4296238106Sdes # icc used to be incompatible with GCC. 4297238106Sdes # ICC 10 doesn't accept -KPIC any more. 4298238106Sdes icc* | ifort*) 4299238106Sdes _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4300238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 4301238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 4302238106Sdes ;; 4303238106Sdes # Lahey Fortran 8.1. 4304238106Sdes lf95*) 4305238106Sdes _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4306238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='--shared' 4307238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='--static' 4308238106Sdes ;; 4309238106Sdes nagfor*) 4310238106Sdes # NAG Fortran compiler 4311238106Sdes _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,' 4312238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' 4313238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4314238106Sdes ;; 4315238106Sdes pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) 4316238106Sdes # Portland Group compilers (*not* the Pentium gcc compiler, 4317238106Sdes # which looks to be a dead project) 4318238106Sdes _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4319238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' 4320238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4321238106Sdes ;; 4322238106Sdes ccc*) 4323238106Sdes _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4324238106Sdes # All Alpha code is PIC. 4325238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 4326238106Sdes ;; 4327238106Sdes xl* | bgxl* | bgf* | mpixl*) 4328238106Sdes # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene 4329238106Sdes _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4330238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' 4331238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' 4332238106Sdes ;; 4333238106Sdes *) 4334238106Sdes case `$CC -V 2>&1 | sed 5q` in 4335238106Sdes *Sun\ F* | *Sun*Fortran*) 4336238106Sdes # Sun Fortran 8.3 passes all unrecognized flags to the linker 4337238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4338238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4339238106Sdes _LT_TAGVAR(lt_prog_compiler_wl, $1)='' 4340238106Sdes ;; 4341238106Sdes *Sun\ C*) 4342238106Sdes # Sun C 5.9 4343238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4344238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4345238106Sdes _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4346238106Sdes ;; 4347238106Sdes esac 4348238106Sdes ;; 4349238106Sdes esac 4350238106Sdes ;; 4351238106Sdes 4352238106Sdes newsos6) 4353238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4354238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4355238106Sdes ;; 4356238106Sdes 4357238106Sdes *nto* | *qnx*) 4358238106Sdes # QNX uses GNU C++, but need to define -shared option too, otherwise 4359238106Sdes # it will coredump. 4360238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' 4361238106Sdes ;; 4362238106Sdes 4363238106Sdes osf3* | osf4* | osf5*) 4364238106Sdes _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4365238106Sdes # All OSF/1 code is PIC. 4366238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 4367238106Sdes ;; 4368238106Sdes 4369238106Sdes rdos*) 4370238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 4371238106Sdes ;; 4372238106Sdes 4373238106Sdes solaris*) 4374238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4375238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4376238106Sdes case $cc_basename in 4377238106Sdes f77* | f90* | f95* | sunf77* | sunf90* | sunf95*) 4378238106Sdes _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';; 4379238106Sdes *) 4380238106Sdes _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';; 4381238106Sdes esac 4382238106Sdes ;; 4383238106Sdes 4384238106Sdes sunos4*) 4385238106Sdes _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' 4386238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' 4387238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4388238106Sdes ;; 4389238106Sdes 4390238106Sdes sysv4 | sysv4.2uw2* | sysv4.3*) 4391238106Sdes _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4392238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4393238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4394238106Sdes ;; 4395238106Sdes 4396238106Sdes sysv4*MP*) 4397238106Sdes if test -d /usr/nec ;then 4398238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic' 4399238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4400238106Sdes fi 4401238106Sdes ;; 4402238106Sdes 4403238106Sdes sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) 4404238106Sdes _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4405238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4406238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4407238106Sdes ;; 4408238106Sdes 4409238106Sdes unicos*) 4410238106Sdes _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4411238106Sdes _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 4412238106Sdes ;; 4413238106Sdes 4414238106Sdes uts4*) 4415238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 4416238106Sdes _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4417238106Sdes ;; 4418238106Sdes 4419238106Sdes *) 4420238106Sdes _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 4421238106Sdes ;; 4422238106Sdes esac 4423238106Sdes fi 4424238106Sdes]) 4425238106Sdescase $host_os in 4426238106Sdes # For platforms which do not support PIC, -DPIC is meaningless: 4427238106Sdes *djgpp*) 4428238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)= 4429238106Sdes ;; 4430238106Sdes *) 4431238106Sdes _LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])" 4432238106Sdes ;; 4433238106Sdesesac 4434238106Sdes 4435238106SdesAC_CACHE_CHECK([for $compiler option to produce PIC], 4436238106Sdes [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)], 4437238106Sdes [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_prog_compiler_pic, $1)]) 4438238106Sdes_LT_TAGVAR(lt_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_cv_prog_compiler_pic, $1) 4439238106Sdes 4440238106Sdes# 4441238106Sdes# Check to make sure the PIC flag actually works. 4442238106Sdes# 4443238106Sdesif test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then 4444238106Sdes _LT_COMPILER_OPTION([if $compiler PIC flag $_LT_TAGVAR(lt_prog_compiler_pic, $1) works], 4445238106Sdes [_LT_TAGVAR(lt_cv_prog_compiler_pic_works, $1)], 4446238106Sdes [$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])], [], 4447238106Sdes [case $_LT_TAGVAR(lt_prog_compiler_pic, $1) in 4448238106Sdes "" | " "*) ;; 4449238106Sdes *) _LT_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_TAGVAR(lt_prog_compiler_pic, $1)" ;; 4450238106Sdes esac], 4451238106Sdes [_LT_TAGVAR(lt_prog_compiler_pic, $1)= 4452238106Sdes _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no]) 4453238106Sdesfi 4454238106Sdes_LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1], 4455238106Sdes [Additional compiler flags for building library objects]) 4456238106Sdes 4457238106Sdes_LT_TAGDECL([wl], [lt_prog_compiler_wl], [1], 4458238106Sdes [How to pass a linker flag through the compiler]) 4459238106Sdes# 4460238106Sdes# Check to make sure the static flag actually works. 4461238106Sdes# 4462238106Sdeswl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_TAGVAR(lt_prog_compiler_static, $1)\" 4463238106Sdes_LT_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works], 4464238106Sdes _LT_TAGVAR(lt_cv_prog_compiler_static_works, $1), 4465238106Sdes $lt_tmp_static_flag, 4466238106Sdes [], 4467238106Sdes [_LT_TAGVAR(lt_prog_compiler_static, $1)=]) 4468238106Sdes_LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1], 4469238106Sdes [Compiler flag to prevent dynamic linking]) 4470238106Sdes])# _LT_COMPILER_PIC 4471238106Sdes 4472238106Sdes 4473238106Sdes# _LT_LINKER_SHLIBS([TAGNAME]) 4474238106Sdes# ---------------------------- 4475238106Sdes# See if the linker supports building shared libraries. 4476238106Sdesm4_defun([_LT_LINKER_SHLIBS], 4477238106Sdes[AC_REQUIRE([LT_PATH_LD])dnl 4478238106SdesAC_REQUIRE([LT_PATH_NM])dnl 4479238106Sdesm4_require([_LT_PATH_MANIFEST_TOOL])dnl 4480238106Sdesm4_require([_LT_FILEUTILS_DEFAULTS])dnl 4481238106Sdesm4_require([_LT_DECL_EGREP])dnl 4482238106Sdesm4_require([_LT_DECL_SED])dnl 4483238106Sdesm4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl 4484238106Sdesm4_require([_LT_TAG_COMPILER])dnl 4485238106SdesAC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) 4486238106Sdesm4_if([$1], [CXX], [ 4487238106Sdes _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' 4488238106Sdes _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] 4489238106Sdes case $host_os in 4490238106Sdes aix[[4-9]]*) 4491238106Sdes # If we're using GNU nm, then we don't want the "-C" option. 4492238106Sdes # -C means demangle to AIX nm, but means don't demangle with GNU nm 4493238106Sdes # Also, AIX nm treats weak defined symbols like other global defined 4494238106Sdes # symbols, whereas GNU nm marks them as "W". 4495238106Sdes if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then 4496238106Sdes _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' 4497238106Sdes else 4498238106Sdes _LT_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' 4499238106Sdes fi 4500238106Sdes ;; 4501238106Sdes pw32*) 4502238106Sdes _LT_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds" 4503238106Sdes ;; 4504238106Sdes cygwin* | mingw* | cegcc*) 4505238106Sdes case $cc_basename in 4506238106Sdes cl*) ;; 4507238106Sdes *) 4508238106Sdes _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' 4509238106Sdes _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'] 4510238106Sdes ;; 4511238106Sdes esac 4512238106Sdes ;; 4513238106Sdes *) 4514238106Sdes _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' 4515238106Sdes ;; 4516238106Sdes esac 4517238106Sdes], [ 4518238106Sdes runpath_var= 4519238106Sdes _LT_TAGVAR(allow_undefined_flag, $1)= 4520238106Sdes _LT_TAGVAR(always_export_symbols, $1)=no 4521238106Sdes _LT_TAGVAR(archive_cmds, $1)= 4522238106Sdes _LT_TAGVAR(archive_expsym_cmds, $1)= 4523238106Sdes _LT_TAGVAR(compiler_needs_object, $1)=no 4524238106Sdes _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no 4525238106Sdes _LT_TAGVAR(export_dynamic_flag_spec, $1)= 4526238106Sdes _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' 4527238106Sdes _LT_TAGVAR(hardcode_automatic, $1)=no 4528238106Sdes _LT_TAGVAR(hardcode_direct, $1)=no 4529238106Sdes _LT_TAGVAR(hardcode_direct_absolute, $1)=no 4530238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 4531238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= 4532238106Sdes _LT_TAGVAR(hardcode_libdir_separator, $1)= 4533238106Sdes _LT_TAGVAR(hardcode_minus_L, $1)=no 4534238106Sdes _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported 4535238106Sdes _LT_TAGVAR(inherit_rpath, $1)=no 4536238106Sdes _LT_TAGVAR(link_all_deplibs, $1)=unknown 4537238106Sdes _LT_TAGVAR(module_cmds, $1)= 4538238106Sdes _LT_TAGVAR(module_expsym_cmds, $1)= 4539238106Sdes _LT_TAGVAR(old_archive_from_new_cmds, $1)= 4540238106Sdes _LT_TAGVAR(old_archive_from_expsyms_cmds, $1)= 4541238106Sdes _LT_TAGVAR(thread_safe_flag_spec, $1)= 4542238106Sdes _LT_TAGVAR(whole_archive_flag_spec, $1)= 4543238106Sdes # include_expsyms should be a list of space-separated symbols to be *always* 4544238106Sdes # included in the symbol list 4545238106Sdes _LT_TAGVAR(include_expsyms, $1)= 4546238106Sdes # exclude_expsyms can be an extended regexp of symbols to exclude 4547238106Sdes # it will be wrapped by ` (' and `)$', so one must not match beginning or 4548238106Sdes # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', 4549238106Sdes # as well as any symbol that contains `d'. 4550238106Sdes _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] 4551238106Sdes # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out 4552238106Sdes # platforms (ab)use it in PIC code, but their linkers get confused if 4553238106Sdes # the symbol is explicitly referenced. Since portable code cannot 4554238106Sdes # rely on this symbol name, it's probably fine to never include it in 4555238106Sdes # preloaded symbol tables. 4556238106Sdes # Exclude shared library initialization/finalization symbols. 4557238106Sdesdnl Note also adjust exclude_expsyms for C++ above. 4558238106Sdes extract_expsyms_cmds= 4559238106Sdes 4560238106Sdes case $host_os in 4561238106Sdes cygwin* | mingw* | pw32* | cegcc*) 4562238106Sdes # FIXME: the MSVC++ port hasn't been tested in a loooong time 4563238106Sdes # When not using gcc, we currently assume that we are using 4564238106Sdes # Microsoft Visual C++. 4565238106Sdes if test "$GCC" != yes; then 4566238106Sdes with_gnu_ld=no 4567238106Sdes fi 4568238106Sdes ;; 4569238106Sdes interix*) 4570238106Sdes # we just hope/assume this is gcc and not c89 (= MSVC++) 4571238106Sdes with_gnu_ld=yes 4572238106Sdes ;; 4573238106Sdes openbsd*) 4574238106Sdes with_gnu_ld=no 4575238106Sdes ;; 4576238106Sdes esac 4577238106Sdes 4578238106Sdes _LT_TAGVAR(ld_shlibs, $1)=yes 4579238106Sdes 4580238106Sdes # On some targets, GNU ld is compatible enough with the native linker 4581238106Sdes # that we're better off using the native interface for both. 4582238106Sdes lt_use_gnu_ld_interface=no 4583238106Sdes if test "$with_gnu_ld" = yes; then 4584238106Sdes case $host_os in 4585238106Sdes aix*) 4586238106Sdes # The AIX port of GNU ld has always aspired to compatibility 4587238106Sdes # with the native linker. However, as the warning in the GNU ld 4588238106Sdes # block says, versions before 2.19.5* couldn't really create working 4589238106Sdes # shared libraries, regardless of the interface used. 4590238106Sdes case `$LD -v 2>&1` in 4591238106Sdes *\ \(GNU\ Binutils\)\ 2.19.5*) ;; 4592238106Sdes *\ \(GNU\ Binutils\)\ 2.[[2-9]]*) ;; 4593238106Sdes *\ \(GNU\ Binutils\)\ [[3-9]]*) ;; 4594238106Sdes *) 4595238106Sdes lt_use_gnu_ld_interface=yes 4596238106Sdes ;; 4597238106Sdes esac 4598238106Sdes ;; 4599238106Sdes *) 4600238106Sdes lt_use_gnu_ld_interface=yes 4601238106Sdes ;; 4602238106Sdes esac 4603238106Sdes fi 4604238106Sdes 4605238106Sdes if test "$lt_use_gnu_ld_interface" = yes; then 4606238106Sdes # If archive_cmds runs LD, not CC, wlarc should be empty 4607238106Sdes wlarc='${wl}' 4608238106Sdes 4609238106Sdes # Set some defaults for GNU ld with shared library support. These 4610238106Sdes # are reset later if shared libraries are not supported. Putting them 4611238106Sdes # here allows them to be overridden if necessary. 4612238106Sdes runpath_var=LD_RUN_PATH 4613238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 4614238106Sdes _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 4615238106Sdes # ancient GNU ld didn't support --whole-archive et. al. 4616238106Sdes if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then 4617238106Sdes _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' 4618238106Sdes else 4619238106Sdes _LT_TAGVAR(whole_archive_flag_spec, $1)= 4620238106Sdes fi 4621238106Sdes supports_anon_versioning=no 4622238106Sdes case `$LD -v 2>&1` in 4623238106Sdes *GNU\ gold*) supports_anon_versioning=yes ;; 4624238106Sdes *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11 4625238106Sdes *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... 4626238106Sdes *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... 4627238106Sdes *\ 2.11.*) ;; # other 2.11 versions 4628238106Sdes *) supports_anon_versioning=yes ;; 4629238106Sdes esac 4630238106Sdes 4631238106Sdes # See if GNU ld supports shared libraries. 4632238106Sdes case $host_os in 4633238106Sdes aix[[3-9]]*) 4634238106Sdes # On AIX/PPC, the GNU linker is very broken 4635238106Sdes if test "$host_cpu" != ia64; then 4636238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 4637238106Sdes cat <<_LT_EOF 1>&2 4638238106Sdes 4639238106Sdes*** Warning: the GNU linker, at least up to release 2.19, is reported 4640238106Sdes*** to be unable to reliably create shared libraries on AIX. 4641238106Sdes*** Therefore, libtool is disabling shared libraries support. If you 4642238106Sdes*** really care for shared libraries, you may want to install binutils 4643238106Sdes*** 2.20 or above, or modify your PATH so that a non-GNU linker is found. 4644238106Sdes*** You will then need to restart the configuration process. 4645238106Sdes 4646238106Sdes_LT_EOF 4647238106Sdes fi 4648238106Sdes ;; 4649238106Sdes 4650238106Sdes amigaos*) 4651238106Sdes case $host_cpu in 4652238106Sdes powerpc) 4653238106Sdes # see comment about AmigaOS4 .so support 4654238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 4655238106Sdes _LT_TAGVAR(archive_expsym_cmds, $1)='' 4656238106Sdes ;; 4657238106Sdes m68k) 4658238106Sdes _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)' 4659238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 4660238106Sdes _LT_TAGVAR(hardcode_minus_L, $1)=yes 4661238106Sdes ;; 4662238106Sdes esac 4663238106Sdes ;; 4664238106Sdes 4665238106Sdes beos*) 4666238106Sdes if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 4667238106Sdes _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 4668238106Sdes # Joseph Beckenbach <jrb3@best.com> says some releases of gcc 4669238106Sdes # support --undefined. This deserves some investigation. FIXME 4670238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 4671238106Sdes else 4672238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 4673238106Sdes fi 4674238106Sdes ;; 4675238106Sdes 4676238106Sdes cygwin* | mingw* | pw32* | cegcc*) 4677238106Sdes # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, 4678238106Sdes # as there is no search path for DLLs. 4679238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 4680238106Sdes _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols' 4681238106Sdes _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 4682238106Sdes _LT_TAGVAR(always_export_symbols, $1)=no 4683238106Sdes _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 4684238106Sdes _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' 4685238106Sdes _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'] 4686238106Sdes 4687238106Sdes if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then 4688238106Sdes _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' 4689238106Sdes # If the export-symbols file already is a .def file (1st line 4690238106Sdes # is EXPORTS), use it as is; otherwise, prepend... 4691238106Sdes _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then 4692238106Sdes cp $export_symbols $output_objdir/$soname.def; 4693238106Sdes else 4694238106Sdes echo EXPORTS > $output_objdir/$soname.def; 4695238106Sdes cat $export_symbols >> $output_objdir/$soname.def; 4696238106Sdes fi~ 4697238106Sdes $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' 4698238106Sdes else 4699238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 4700238106Sdes fi 4701238106Sdes ;; 4702238106Sdes 4703238106Sdes haiku*) 4704238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 4705238106Sdes _LT_TAGVAR(link_all_deplibs, $1)=yes 4706238106Sdes ;; 4707238106Sdes 4708238106Sdes interix[[3-9]]*) 4709238106Sdes _LT_TAGVAR(hardcode_direct, $1)=no 4710238106Sdes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 4711238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 4712238106Sdes _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 4713238106Sdes # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. 4714238106Sdes # Instead, shared libraries are loaded at an image base (0x10000000 by 4715238106Sdes # default) and relocated if they conflict, which is a slow very memory 4716238106Sdes # consuming and fragmenting process. To avoid this, we pick a random, 4717238106Sdes # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link 4718238106Sdes # time. Moving up from 0x10000000 also allows more sbrk(2) space. 4719238106Sdes _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' 4720238106Sdes _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' 4721238106Sdes ;; 4722238106Sdes 4723238106Sdes gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) 4724238106Sdes tmp_diet=no 4725238106Sdes if test "$host_os" = linux-dietlibc; then 4726238106Sdes case $cc_basename in 4727238106Sdes diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn) 4728238106Sdes esac 4729238106Sdes fi 4730238106Sdes if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ 4731238106Sdes && test "$tmp_diet" = no 4732238106Sdes then 4733238106Sdes tmp_addflag=' $pic_flag' 4734238106Sdes tmp_sharedflag='-shared' 4735238106Sdes case $cc_basename,$host_cpu in 4736238106Sdes pgcc*) # Portland Group C compiler 4737238106Sdes _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' 4738238106Sdes tmp_addflag=' $pic_flag' 4739238106Sdes ;; 4740238106Sdes pgf77* | pgf90* | pgf95* | pgfortran*) 4741238106Sdes # Portland Group f77 and f90 compilers 4742238106Sdes _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' 4743238106Sdes tmp_addflag=' $pic_flag -Mnomain' ;; 4744238106Sdes ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 4745238106Sdes tmp_addflag=' -i_dynamic' ;; 4746238106Sdes efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 4747238106Sdes tmp_addflag=' -i_dynamic -nofor_main' ;; 4748238106Sdes ifc* | ifort*) # Intel Fortran compiler 4749238106Sdes tmp_addflag=' -nofor_main' ;; 4750238106Sdes lf95*) # Lahey Fortran 8.1 4751238106Sdes _LT_TAGVAR(whole_archive_flag_spec, $1)= 4752238106Sdes tmp_sharedflag='--shared' ;; 4753238106Sdes xl[[cC]]* | bgxl[[cC]]* | mpixl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below) 4754238106Sdes tmp_sharedflag='-qmkshrobj' 4755238106Sdes tmp_addflag= ;; 4756238106Sdes nvcc*) # Cuda Compiler Driver 2.2 4757238106Sdes _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' 4758238106Sdes _LT_TAGVAR(compiler_needs_object, $1)=yes 4759238106Sdes ;; 4760238106Sdes esac 4761238106Sdes case `$CC -V 2>&1 | sed 5q` in 4762238106Sdes *Sun\ C*) # Sun C 5.9 4763238106Sdes _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' 4764238106Sdes _LT_TAGVAR(compiler_needs_object, $1)=yes 4765238106Sdes tmp_sharedflag='-G' ;; 4766238106Sdes *Sun\ F*) # Sun Fortran 8.3 4767238106Sdes tmp_sharedflag='-G' ;; 4768238106Sdes esac 4769238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 4770238106Sdes 4771238106Sdes if test "x$supports_anon_versioning" = xyes; then 4772238106Sdes _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ 4773238106Sdes cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ 4774238106Sdes echo "local: *; };" >> $output_objdir/$libname.ver~ 4775238106Sdes $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' 4776238106Sdes fi 4777238106Sdes 4778238106Sdes case $cc_basename in 4779238106Sdes xlf* | bgf* | bgxlf* | mpixlf*) 4780238106Sdes # IBM XL Fortran 10.1 on PPC cannot create shared libs itself 4781238106Sdes _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive' 4782238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 4783238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='-rpath $libdir' 4784238106Sdes _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib' 4785238106Sdes if test "x$supports_anon_versioning" = xyes; then 4786238106Sdes _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ 4787238106Sdes cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ 4788238106Sdes echo "local: *; };" >> $output_objdir/$libname.ver~ 4789238106Sdes $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' 4790238106Sdes fi 4791238106Sdes ;; 4792238106Sdes esac 4793238106Sdes else 4794238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 4795238106Sdes fi 4796238106Sdes ;; 4797238106Sdes 4798238106Sdes netbsd*) 4799238106Sdes if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then 4800238106Sdes _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' 4801238106Sdes wlarc= 4802238106Sdes else 4803238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 4804238106Sdes _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' 4805238106Sdes fi 4806238106Sdes ;; 4807238106Sdes 4808238106Sdes solaris*) 4809238106Sdes if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then 4810238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 4811238106Sdes cat <<_LT_EOF 1>&2 4812238106Sdes 4813238106Sdes*** Warning: The releases 2.8.* of the GNU linker cannot reliably 4814238106Sdes*** create shared libraries on Solaris systems. Therefore, libtool 4815238106Sdes*** is disabling shared libraries support. We urge you to upgrade GNU 4816238106Sdes*** binutils to release 2.9.1 or newer. Another option is to modify 4817238106Sdes*** your PATH or compiler configuration so that the native linker is 4818238106Sdes*** used, and then restart. 4819238106Sdes 4820238106Sdes_LT_EOF 4821238106Sdes elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 4822238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 4823238106Sdes _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' 4824238106Sdes else 4825238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 4826238106Sdes fi 4827238106Sdes ;; 4828238106Sdes 4829238106Sdes sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) 4830238106Sdes case `$LD -v 2>&1` in 4831238106Sdes *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*) 4832238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 4833238106Sdes cat <<_LT_EOF 1>&2 4834238106Sdes 4835238106Sdes*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not 4836238106Sdes*** reliably create shared libraries on SCO systems. Therefore, libtool 4837238106Sdes*** is disabling shared libraries support. We urge you to upgrade GNU 4838238106Sdes*** binutils to release 2.16.91.0.3 or newer. Another option is to modify 4839238106Sdes*** your PATH or compiler configuration so that the native linker is 4840238106Sdes*** used, and then restart. 4841238106Sdes 4842238106Sdes_LT_EOF 4843238106Sdes ;; 4844238106Sdes *) 4845238106Sdes # For security reasons, it is highly recommended that you always 4846238106Sdes # use absolute paths for naming shared libraries, and exclude the 4847238106Sdes # DT_RUNPATH tag from executables and libraries. But doing so 4848238106Sdes # requires that you compile everything twice, which is a pain. 4849238106Sdes if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 4850238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 4851238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 4852238106Sdes _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' 4853238106Sdes else 4854238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 4855238106Sdes fi 4856238106Sdes ;; 4857238106Sdes esac 4858238106Sdes ;; 4859238106Sdes 4860238106Sdes sunos4*) 4861238106Sdes _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' 4862238106Sdes wlarc= 4863238106Sdes _LT_TAGVAR(hardcode_direct, $1)=yes 4864238106Sdes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 4865238106Sdes ;; 4866238106Sdes 4867238106Sdes *) 4868238106Sdes if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 4869238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 4870238106Sdes _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' 4871238106Sdes else 4872238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 4873238106Sdes fi 4874238106Sdes ;; 4875238106Sdes esac 4876238106Sdes 4877238106Sdes if test "$_LT_TAGVAR(ld_shlibs, $1)" = no; then 4878238106Sdes runpath_var= 4879238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 4880238106Sdes _LT_TAGVAR(export_dynamic_flag_spec, $1)= 4881238106Sdes _LT_TAGVAR(whole_archive_flag_spec, $1)= 4882238106Sdes fi 4883238106Sdes else 4884238106Sdes # PORTME fill in a description of your system's linker (not GNU ld) 4885238106Sdes case $host_os in 4886238106Sdes aix3*) 4887238106Sdes _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 4888238106Sdes _LT_TAGVAR(always_export_symbols, $1)=yes 4889238106Sdes _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' 4890238106Sdes # Note: this linker hardcodes the directories in LIBPATH if there 4891238106Sdes # are no directories specified by -L. 4892238106Sdes _LT_TAGVAR(hardcode_minus_L, $1)=yes 4893238106Sdes if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then 4894238106Sdes # Neither direct hardcoding nor static linking is supported with a 4895238106Sdes # broken collect2. 4896238106Sdes _LT_TAGVAR(hardcode_direct, $1)=unsupported 4897238106Sdes fi 4898238106Sdes ;; 4899238106Sdes 4900238106Sdes aix[[4-9]]*) 4901238106Sdes if test "$host_cpu" = ia64; then 4902238106Sdes # On IA64, the linker does run time linking by default, so we don't 4903238106Sdes # have to do anything special. 4904238106Sdes aix_use_runtimelinking=no 4905238106Sdes exp_sym_flag='-Bexport' 4906238106Sdes no_entry_flag="" 4907238106Sdes else 4908238106Sdes # If we're using GNU nm, then we don't want the "-C" option. 4909238106Sdes # -C means demangle to AIX nm, but means don't demangle with GNU nm 4910238106Sdes # Also, AIX nm treats weak defined symbols like other global 4911238106Sdes # defined symbols, whereas GNU nm marks them as "W". 4912238106Sdes if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then 4913238106Sdes _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' 4914238106Sdes else 4915238106Sdes _LT_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' 4916238106Sdes fi 4917238106Sdes aix_use_runtimelinking=no 4918238106Sdes 4919238106Sdes # Test if we are trying to use run time linking or normal 4920238106Sdes # AIX style linking. If -brtl is somewhere in LDFLAGS, we 4921238106Sdes # need to do runtime linking. 4922238106Sdes case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) 4923238106Sdes for ld_flag in $LDFLAGS; do 4924238106Sdes if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then 4925238106Sdes aix_use_runtimelinking=yes 4926238106Sdes break 4927238106Sdes fi 4928238106Sdes done 4929238106Sdes ;; 4930238106Sdes esac 4931238106Sdes 4932238106Sdes exp_sym_flag='-bexport' 4933238106Sdes no_entry_flag='-bnoentry' 4934238106Sdes fi 4935238106Sdes 4936238106Sdes # When large executables or shared objects are built, AIX ld can 4937238106Sdes # have problems creating the table of contents. If linking a library 4938238106Sdes # or program results in "error TOC overflow" add -mminimal-toc to 4939238106Sdes # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not 4940238106Sdes # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. 4941238106Sdes 4942238106Sdes _LT_TAGVAR(archive_cmds, $1)='' 4943238106Sdes _LT_TAGVAR(hardcode_direct, $1)=yes 4944238106Sdes _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 4945238106Sdes _LT_TAGVAR(hardcode_libdir_separator, $1)=':' 4946238106Sdes _LT_TAGVAR(link_all_deplibs, $1)=yes 4947238106Sdes _LT_TAGVAR(file_list_spec, $1)='${wl}-f,' 4948238106Sdes 4949238106Sdes if test "$GCC" = yes; then 4950238106Sdes case $host_os in aix4.[[012]]|aix4.[[012]].*) 4951238106Sdes # We only want to do this on AIX 4.2 and lower, the check 4952238106Sdes # below for broken collect2 doesn't work under 4.3+ 4953238106Sdes collect2name=`${CC} -print-prog-name=collect2` 4954238106Sdes if test -f "$collect2name" && 4955238106Sdes strings "$collect2name" | $GREP resolve_lib_name >/dev/null 4956238106Sdes then 4957238106Sdes # We have reworked collect2 4958238106Sdes : 4959238106Sdes else 4960238106Sdes # We have old collect2 4961238106Sdes _LT_TAGVAR(hardcode_direct, $1)=unsupported 4962238106Sdes # It fails to find uninstalled libraries when the uninstalled 4963238106Sdes # path is not listed in the libpath. Setting hardcode_minus_L 4964238106Sdes # to unsupported forces relinking 4965238106Sdes _LT_TAGVAR(hardcode_minus_L, $1)=yes 4966238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 4967238106Sdes _LT_TAGVAR(hardcode_libdir_separator, $1)= 4968238106Sdes fi 4969238106Sdes ;; 4970238106Sdes esac 4971238106Sdes shared_flag='-shared' 4972238106Sdes if test "$aix_use_runtimelinking" = yes; then 4973238106Sdes shared_flag="$shared_flag "'${wl}-G' 4974238106Sdes fi 4975238106Sdes else 4976238106Sdes # not using gcc 4977238106Sdes if test "$host_cpu" = ia64; then 4978238106Sdes # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release 4979238106Sdes # chokes on -Wl,-G. The following line is correct: 4980238106Sdes shared_flag='-G' 4981238106Sdes else 4982238106Sdes if test "$aix_use_runtimelinking" = yes; then 4983238106Sdes shared_flag='${wl}-G' 4984238106Sdes else 4985238106Sdes shared_flag='${wl}-bM:SRE' 4986238106Sdes fi 4987238106Sdes fi 4988238106Sdes fi 4989238106Sdes 4990238106Sdes _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall' 4991238106Sdes # It seems that -bexpall does not export symbols beginning with 4992238106Sdes # underscore (_), so it is better to generate a list of symbols to export. 4993238106Sdes _LT_TAGVAR(always_export_symbols, $1)=yes 4994238106Sdes if test "$aix_use_runtimelinking" = yes; then 4995238106Sdes # Warning - without using the other runtime loading flags (-brtl), 4996238106Sdes # -berok will link without error, but may produce a broken library. 4997238106Sdes _LT_TAGVAR(allow_undefined_flag, $1)='-berok' 4998238106Sdes # Determine the default libpath from the value encoded in an 4999238106Sdes # empty executable. 5000238106Sdes _LT_SYS_MODULE_PATH_AIX([$1]) 5001238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" 5002238106Sdes _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" 5003238106Sdes else 5004238106Sdes if test "$host_cpu" = ia64; then 5005238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' 5006238106Sdes _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" 5007238106Sdes _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" 5008238106Sdes else 5009238106Sdes # Determine the default libpath from the value encoded in an 5010238106Sdes # empty executable. 5011238106Sdes _LT_SYS_MODULE_PATH_AIX([$1]) 5012238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" 5013238106Sdes # Warning - without using the other run time loading flags, 5014238106Sdes # -berok will link without error, but may produce a broken library. 5015238106Sdes _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' 5016238106Sdes _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' 5017238106Sdes if test "$with_gnu_ld" = yes; then 5018238106Sdes # We only use this code for GNU lds that support --whole-archive. 5019238106Sdes _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' 5020238106Sdes else 5021238106Sdes # Exported symbols can be pulled into shared objects from archives 5022238106Sdes _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' 5023238106Sdes fi 5024238106Sdes _LT_TAGVAR(archive_cmds_need_lc, $1)=yes 5025238106Sdes # This is similar to how AIX traditionally builds its shared libraries. 5026238106Sdes _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' 5027238106Sdes fi 5028238106Sdes fi 5029238106Sdes ;; 5030238106Sdes 5031238106Sdes amigaos*) 5032238106Sdes case $host_cpu in 5033238106Sdes powerpc) 5034238106Sdes # see comment about AmigaOS4 .so support 5035238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 5036238106Sdes _LT_TAGVAR(archive_expsym_cmds, $1)='' 5037238106Sdes ;; 5038238106Sdes m68k) 5039238106Sdes _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)' 5040238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 5041238106Sdes _LT_TAGVAR(hardcode_minus_L, $1)=yes 5042238106Sdes ;; 5043238106Sdes esac 5044238106Sdes ;; 5045238106Sdes 5046238106Sdes bsdi[[45]]*) 5047238106Sdes _LT_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic 5048238106Sdes ;; 5049238106Sdes 5050238106Sdes cygwin* | mingw* | pw32* | cegcc*) 5051238106Sdes # When not using gcc, we currently assume that we are using 5052238106Sdes # Microsoft Visual C++. 5053238106Sdes # hardcode_libdir_flag_spec is actually meaningless, as there is 5054238106Sdes # no search path for DLLs. 5055238106Sdes case $cc_basename in 5056238106Sdes cl*) 5057238106Sdes # Native MSVC 5058238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' 5059238106Sdes _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 5060238106Sdes _LT_TAGVAR(always_export_symbols, $1)=yes 5061238106Sdes _LT_TAGVAR(file_list_spec, $1)='@' 5062238106Sdes # Tell ltmain to make .lib files, not .a files. 5063238106Sdes libext=lib 5064238106Sdes # Tell ltmain to make .dll files, not .so files. 5065238106Sdes shrext_cmds=".dll" 5066238106Sdes # FIXME: Setting linknames here is a bad hack. 5067238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames=' 5068238106Sdes _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then 5069238106Sdes sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp; 5070238106Sdes else 5071238106Sdes sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp; 5072238106Sdes fi~ 5073238106Sdes $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ 5074238106Sdes linknames=' 5075238106Sdes # The linker will not automatically build a static lib if we build a DLL. 5076238106Sdes # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' 5077238106Sdes _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 5078238106Sdes _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' 5079238106Sdes # Don't use ranlib 5080238106Sdes _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib' 5081238106Sdes _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~ 5082238106Sdes lt_tool_outputfile="@TOOL_OUTPUT@"~ 5083238106Sdes case $lt_outputfile in 5084238106Sdes *.exe|*.EXE) ;; 5085238106Sdes *) 5086238106Sdes lt_outputfile="$lt_outputfile.exe" 5087238106Sdes lt_tool_outputfile="$lt_tool_outputfile.exe" 5088238106Sdes ;; 5089238106Sdes esac~ 5090238106Sdes if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then 5091238106Sdes $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; 5092238106Sdes $RM "$lt_outputfile.manifest"; 5093238106Sdes fi' 5094238106Sdes ;; 5095238106Sdes *) 5096238106Sdes # Assume MSVC wrapper 5097238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' 5098238106Sdes _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 5099238106Sdes # Tell ltmain to make .lib files, not .a files. 5100238106Sdes libext=lib 5101238106Sdes # Tell ltmain to make .dll files, not .so files. 5102238106Sdes shrext_cmds=".dll" 5103238106Sdes # FIXME: Setting linknames here is a bad hack. 5104238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames=' 5105238106Sdes # The linker will automatically build a .lib file if we build a DLL. 5106238106Sdes _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' 5107238106Sdes # FIXME: Should let the user specify the lib program. 5108238106Sdes _LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs' 5109238106Sdes _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 5110238106Sdes ;; 5111238106Sdes esac 5112238106Sdes ;; 5113238106Sdes 5114238106Sdes darwin* | rhapsody*) 5115238106Sdes _LT_DARWIN_LINKER_FEATURES($1) 5116238106Sdes ;; 5117238106Sdes 5118238106Sdes dgux*) 5119238106Sdes _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 5120238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 5121238106Sdes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5122238106Sdes ;; 5123238106Sdes 5124238106Sdes freebsd1*) 5125238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 5126238106Sdes ;; 5127238106Sdes 5128238106Sdes # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor 5129238106Sdes # support. Future versions do this automatically, but an explicit c++rt0.o 5130238106Sdes # does not break anything, and helps significantly (at the cost of a little 5131238106Sdes # extra space). 5132238106Sdes freebsd2.2*) 5133238106Sdes _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' 5134238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 5135238106Sdes _LT_TAGVAR(hardcode_direct, $1)=yes 5136238106Sdes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5137238106Sdes ;; 5138238106Sdes 5139238106Sdes # Unfortunately, older versions of FreeBSD 2 do not have this feature. 5140238106Sdes freebsd2*) 5141238106Sdes _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' 5142238106Sdes _LT_TAGVAR(hardcode_direct, $1)=yes 5143238106Sdes _LT_TAGVAR(hardcode_minus_L, $1)=yes 5144238106Sdes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5145238106Sdes ;; 5146238106Sdes 5147238106Sdes # FreeBSD 3 and greater uses gcc -shared to do shared libraries. 5148238106Sdes freebsd* | dragonfly*) 5149238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' 5150238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 5151238106Sdes _LT_TAGVAR(hardcode_direct, $1)=yes 5152238106Sdes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5153238106Sdes ;; 5154238106Sdes 5155238106Sdes hpux9*) 5156238106Sdes if test "$GCC" = yes; then 5157238106Sdes _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 $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' 5158238106Sdes else 5159238106Sdes _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' 5160238106Sdes fi 5161238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 5162238106Sdes _LT_TAGVAR(hardcode_libdir_separator, $1)=: 5163238106Sdes _LT_TAGVAR(hardcode_direct, $1)=yes 5164238106Sdes 5165238106Sdes # hardcode_minus_L: Not really in the search PATH, 5166238106Sdes # but as the default location of the library. 5167238106Sdes _LT_TAGVAR(hardcode_minus_L, $1)=yes 5168238106Sdes _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 5169238106Sdes ;; 5170238106Sdes 5171238106Sdes hpux10*) 5172238106Sdes if test "$GCC" = yes && test "$with_gnu_ld" = no; then 5173238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' 5174238106Sdes else 5175238106Sdes _LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' 5176238106Sdes fi 5177238106Sdes if test "$with_gnu_ld" = no; then 5178238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 5179238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir' 5180238106Sdes _LT_TAGVAR(hardcode_libdir_separator, $1)=: 5181238106Sdes _LT_TAGVAR(hardcode_direct, $1)=yes 5182238106Sdes _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 5183238106Sdes _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 5184238106Sdes # hardcode_minus_L: Not really in the search PATH, 5185238106Sdes # but as the default location of the library. 5186238106Sdes _LT_TAGVAR(hardcode_minus_L, $1)=yes 5187238106Sdes fi 5188238106Sdes ;; 5189238106Sdes 5190238106Sdes hpux11*) 5191238106Sdes if test "$GCC" = yes && test "$with_gnu_ld" = no; then 5192238106Sdes case $host_cpu in 5193238106Sdes hppa*64*) 5194238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' 5195238106Sdes ;; 5196238106Sdes ia64*) 5197238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' 5198238106Sdes ;; 5199238106Sdes *) 5200238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' 5201238106Sdes ;; 5202238106Sdes esac 5203238106Sdes else 5204238106Sdes case $host_cpu in 5205238106Sdes hppa*64*) 5206238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' 5207238106Sdes ;; 5208238106Sdes ia64*) 5209238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' 5210238106Sdes ;; 5211238106Sdes *) 5212238106Sdes m4_if($1, [], [ 5213238106Sdes # Older versions of the 11.00 compiler do not understand -b yet 5214238106Sdes # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does) 5215238106Sdes _LT_LINKER_OPTION([if $CC understands -b], 5216238106Sdes _LT_TAGVAR(lt_cv_prog_compiler__b, $1), [-b], 5217238106Sdes [_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'], 5218238106Sdes [_LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'])], 5219238106Sdes [_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags']) 5220238106Sdes ;; 5221238106Sdes esac 5222238106Sdes fi 5223238106Sdes if test "$with_gnu_ld" = no; then 5224238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 5225238106Sdes _LT_TAGVAR(hardcode_libdir_separator, $1)=: 5226238106Sdes 5227238106Sdes case $host_cpu in 5228238106Sdes hppa*64*|ia64*) 5229238106Sdes _LT_TAGVAR(hardcode_direct, $1)=no 5230238106Sdes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5231238106Sdes ;; 5232238106Sdes *) 5233238106Sdes _LT_TAGVAR(hardcode_direct, $1)=yes 5234238106Sdes _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 5235238106Sdes _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 5236238106Sdes 5237238106Sdes # hardcode_minus_L: Not really in the search PATH, 5238238106Sdes # but as the default location of the library. 5239238106Sdes _LT_TAGVAR(hardcode_minus_L, $1)=yes 5240238106Sdes ;; 5241238106Sdes esac 5242238106Sdes fi 5243238106Sdes ;; 5244238106Sdes 5245238106Sdes irix5* | irix6* | nonstopux*) 5246238106Sdes if test "$GCC" = yes; then 5247238106Sdes _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' 5248238106Sdes # Try to use the -exported_symbol ld option, if it does not 5249238106Sdes # work, assume that -exports_file does not work either and 5250238106Sdes # implicitly export all symbols. 5251238106Sdes # This should be the same for all languages, so no per-tag cache variable. 5252238106Sdes AC_CACHE_CHECK([whether the $host_os linker accepts -exported_symbol], 5253238106Sdes [lt_cv_irix_exported_symbol], 5254238106Sdes [save_LDFLAGS="$LDFLAGS" 5255238106Sdes LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null" 5256238106Sdes AC_LINK_IFELSE( 5257238106Sdes [AC_LANG_SOURCE( 5258238106Sdes [AC_LANG_CASE([C], [[int foo (void) { return 0; }]], 5259238106Sdes [C++], [[int foo (void) { return 0; }]], 5260238106Sdes [Fortran 77], [[ 5261238106Sdes subroutine foo 5262238106Sdes end]], 5263238106Sdes [Fortran], [[ 5264238106Sdes subroutine foo 5265238106Sdes end]])])], 5266238106Sdes [lt_cv_irix_exported_symbol=yes], 5267238106Sdes [lt_cv_irix_exported_symbol=no]) 5268238106Sdes LDFLAGS="$save_LDFLAGS"]) 5269238106Sdes if test "$lt_cv_irix_exported_symbol" = yes; then 5270238106Sdes _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' 5271238106Sdes fi 5272238106Sdes else 5273238106Sdes _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' 5274238106Sdes _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' 5275238106Sdes fi 5276238106Sdes _LT_TAGVAR(archive_cmds_need_lc, $1)='no' 5277238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 5278238106Sdes _LT_TAGVAR(hardcode_libdir_separator, $1)=: 5279238106Sdes _LT_TAGVAR(inherit_rpath, $1)=yes 5280238106Sdes _LT_TAGVAR(link_all_deplibs, $1)=yes 5281238106Sdes ;; 5282238106Sdes 5283238106Sdes netbsd*) 5284238106Sdes if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then 5285238106Sdes _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out 5286238106Sdes else 5287238106Sdes _LT_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF 5288238106Sdes fi 5289238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 5290238106Sdes _LT_TAGVAR(hardcode_direct, $1)=yes 5291238106Sdes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5292238106Sdes ;; 5293238106Sdes 5294238106Sdes newsos6) 5295238106Sdes _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 5296238106Sdes _LT_TAGVAR(hardcode_direct, $1)=yes 5297238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 5298238106Sdes _LT_TAGVAR(hardcode_libdir_separator, $1)=: 5299238106Sdes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5300238106Sdes ;; 5301238106Sdes 5302238106Sdes *nto* | *qnx*) 5303238106Sdes ;; 5304238106Sdes 5305238106Sdes openbsd*) 5306238106Sdes if test -f /usr/libexec/ld.so; then 5307238106Sdes _LT_TAGVAR(hardcode_direct, $1)=yes 5308238106Sdes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5309238106Sdes _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 5310238106Sdes if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then 5311238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' 5312238106Sdes _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' 5313238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 5314238106Sdes _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 5315238106Sdes else 5316238106Sdes case $host_os in 5317238106Sdes openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*) 5318238106Sdes _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' 5319238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 5320238106Sdes ;; 5321238106Sdes *) 5322238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' 5323238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 5324238106Sdes ;; 5325238106Sdes esac 5326238106Sdes fi 5327238106Sdes else 5328238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 5329238106Sdes fi 5330238106Sdes ;; 5331238106Sdes 5332238106Sdes os2*) 5333238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 5334238106Sdes _LT_TAGVAR(hardcode_minus_L, $1)=yes 5335238106Sdes _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 5336238106Sdes _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~echo DATA >> $output_objdir/$libname.def~echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def' 5337238106Sdes _LT_TAGVAR(old_archive_from_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' 5338238106Sdes ;; 5339238106Sdes 5340238106Sdes osf3*) 5341238106Sdes if test "$GCC" = yes; then 5342238106Sdes _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' 5343238106Sdes _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' 5344238106Sdes else 5345238106Sdes _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' 5346238106Sdes _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' 5347238106Sdes fi 5348238106Sdes _LT_TAGVAR(archive_cmds_need_lc, $1)='no' 5349238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 5350238106Sdes _LT_TAGVAR(hardcode_libdir_separator, $1)=: 5351238106Sdes ;; 5352238106Sdes 5353238106Sdes osf4* | osf5*) # as osf3* with the addition of -msym flag 5354238106Sdes if test "$GCC" = yes; then 5355238106Sdes _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' 5356238106Sdes _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' 5357238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 5358238106Sdes else 5359238106Sdes _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' 5360238106Sdes _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' 5361238106Sdes _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~ 5362238106Sdes $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' 5363238106Sdes 5364238106Sdes # Both c and cxx compiler support -rpath directly 5365238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' 5366238106Sdes fi 5367238106Sdes _LT_TAGVAR(archive_cmds_need_lc, $1)='no' 5368238106Sdes _LT_TAGVAR(hardcode_libdir_separator, $1)=: 5369238106Sdes ;; 5370238106Sdes 5371238106Sdes solaris*) 5372238106Sdes _LT_TAGVAR(no_undefined_flag, $1)=' -z defs' 5373238106Sdes if test "$GCC" = yes; then 5374238106Sdes wlarc='${wl}' 5375238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' 5376238106Sdes _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 5377238106Sdes $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' 5378238106Sdes else 5379238106Sdes case `$CC -V 2>&1` in 5380238106Sdes *"Compilers 5.0"*) 5381238106Sdes wlarc='' 5382238106Sdes _LT_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' 5383238106Sdes _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 5384238106Sdes $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' 5385238106Sdes ;; 5386238106Sdes *) 5387238106Sdes wlarc='${wl}' 5388238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags' 5389238106Sdes _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 5390238106Sdes $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' 5391238106Sdes ;; 5392238106Sdes esac 5393238106Sdes fi 5394238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 5395238106Sdes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5396238106Sdes case $host_os in 5397238106Sdes solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; 5398238106Sdes *) 5399238106Sdes # The compiler driver will combine and reorder linker options, 5400238106Sdes # but understands `-z linker_flag'. GCC discards it without `$wl', 5401238106Sdes # but is careful enough not to reorder. 5402238106Sdes # Supported since Solaris 2.6 (maybe 2.5.1?) 5403238106Sdes if test "$GCC" = yes; then 5404238106Sdes _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' 5405238106Sdes else 5406238106Sdes _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' 5407238106Sdes fi 5408238106Sdes ;; 5409238106Sdes esac 5410238106Sdes _LT_TAGVAR(link_all_deplibs, $1)=yes 5411238106Sdes ;; 5412238106Sdes 5413238106Sdes sunos4*) 5414238106Sdes if test "x$host_vendor" = xsequent; then 5415238106Sdes # Use $CC to link under sequent, because it throws in some extra .o 5416238106Sdes # files that make .init and .fini sections work. 5417238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' 5418238106Sdes else 5419238106Sdes _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' 5420238106Sdes fi 5421238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 5422238106Sdes _LT_TAGVAR(hardcode_direct, $1)=yes 5423238106Sdes _LT_TAGVAR(hardcode_minus_L, $1)=yes 5424238106Sdes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5425238106Sdes ;; 5426238106Sdes 5427238106Sdes sysv4) 5428238106Sdes case $host_vendor in 5429238106Sdes sni) 5430238106Sdes _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 5431238106Sdes _LT_TAGVAR(hardcode_direct, $1)=yes # is this really true??? 5432238106Sdes ;; 5433238106Sdes siemens) 5434238106Sdes ## LD is ld it makes a PLAMLIB 5435238106Sdes ## CC just makes a GrossModule. 5436238106Sdes _LT_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags' 5437238106Sdes _LT_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs' 5438238106Sdes _LT_TAGVAR(hardcode_direct, $1)=no 5439238106Sdes ;; 5440238106Sdes motorola) 5441238106Sdes _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 5442238106Sdes _LT_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie 5443238106Sdes ;; 5444238106Sdes esac 5445238106Sdes runpath_var='LD_RUN_PATH' 5446238106Sdes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5447238106Sdes ;; 5448238106Sdes 5449238106Sdes sysv4.3*) 5450238106Sdes _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 5451238106Sdes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5452238106Sdes _LT_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport' 5453238106Sdes ;; 5454238106Sdes 5455238106Sdes sysv4*MP*) 5456238106Sdes if test -d /usr/nec; then 5457238106Sdes _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 5458238106Sdes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5459238106Sdes runpath_var=LD_RUN_PATH 5460238106Sdes hardcode_runpath_var=yes 5461238106Sdes _LT_TAGVAR(ld_shlibs, $1)=yes 5462238106Sdes fi 5463238106Sdes ;; 5464238106Sdes 5465238106Sdes sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) 5466238106Sdes _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' 5467238106Sdes _LT_TAGVAR(archive_cmds_need_lc, $1)=no 5468238106Sdes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5469238106Sdes runpath_var='LD_RUN_PATH' 5470238106Sdes 5471238106Sdes if test "$GCC" = yes; then 5472238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 5473238106Sdes _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 5474238106Sdes else 5475238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 5476238106Sdes _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 5477238106Sdes fi 5478238106Sdes ;; 5479238106Sdes 5480238106Sdes sysv5* | sco3.2v5* | sco5v6*) 5481238106Sdes # Note: We can NOT use -z defs as we might desire, because we do not 5482238106Sdes # link with -lc, and that would cause any symbols used from libc to 5483238106Sdes # always be unresolved, which means just about no library would 5484238106Sdes # ever link correctly. If we're not using GNU ld we use -z text 5485238106Sdes # though, which does catch some bad symbols but isn't as heavy-handed 5486238106Sdes # as -z defs. 5487238106Sdes _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' 5488238106Sdes _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs' 5489238106Sdes _LT_TAGVAR(archive_cmds_need_lc, $1)=no 5490238106Sdes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5491238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir' 5492238106Sdes _LT_TAGVAR(hardcode_libdir_separator, $1)=':' 5493238106Sdes _LT_TAGVAR(link_all_deplibs, $1)=yes 5494238106Sdes _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' 5495238106Sdes runpath_var='LD_RUN_PATH' 5496238106Sdes 5497238106Sdes if test "$GCC" = yes; then 5498238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 5499238106Sdes _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 5500238106Sdes else 5501238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 5502238106Sdes _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 5503238106Sdes fi 5504238106Sdes ;; 5505238106Sdes 5506238106Sdes uts4*) 5507238106Sdes _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 5508238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 5509238106Sdes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5510238106Sdes ;; 5511238106Sdes 5512238106Sdes *) 5513238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 5514238106Sdes ;; 5515238106Sdes esac 5516238106Sdes 5517238106Sdes if test x$host_vendor = xsni; then 5518238106Sdes case $host in 5519238106Sdes sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) 5520238106Sdes _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Blargedynsym' 5521238106Sdes ;; 5522238106Sdes esac 5523238106Sdes fi 5524238106Sdes fi 5525238106Sdes]) 5526238106SdesAC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) 5527238106Sdestest "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no 5528238106Sdes 5529238106Sdes_LT_TAGVAR(with_gnu_ld, $1)=$with_gnu_ld 5530238106Sdes 5531238106Sdes_LT_DECL([], [libext], [0], [Old archive suffix (normally "a")])dnl 5532238106Sdes_LT_DECL([], [shrext_cmds], [1], [Shared library suffix (normally ".so")])dnl 5533238106Sdes_LT_DECL([], [extract_expsyms_cmds], [2], 5534238106Sdes [The commands to extract the exported symbol list from a shared archive]) 5535238106Sdes 5536238106Sdes# 5537238106Sdes# Do we need to explicitly link libc? 5538238106Sdes# 5539238106Sdescase "x$_LT_TAGVAR(archive_cmds_need_lc, $1)" in 5540238106Sdesx|xyes) 5541238106Sdes # Assume -lc should be added 5542238106Sdes _LT_TAGVAR(archive_cmds_need_lc, $1)=yes 5543238106Sdes 5544238106Sdes if test "$enable_shared" = yes && test "$GCC" = yes; then 5545238106Sdes case $_LT_TAGVAR(archive_cmds, $1) in 5546238106Sdes *'~'*) 5547238106Sdes # FIXME: we may have to deal with multi-command sequences. 5548238106Sdes ;; 5549238106Sdes '$CC '*) 5550238106Sdes # Test whether the compiler implicitly links with -lc since on some 5551238106Sdes # systems, -lgcc has to come before -lc. If gcc already passes -lc 5552238106Sdes # to ld, don't add -lc before -lgcc. 5553238106Sdes AC_CACHE_CHECK([whether -lc should be explicitly linked in], 5554238106Sdes [lt_cv_]_LT_TAGVAR(archive_cmds_need_lc, $1), 5555238106Sdes [$RM conftest* 5556238106Sdes echo "$lt_simple_compile_test_code" > conftest.$ac_ext 5557238106Sdes 5558238106Sdes if AC_TRY_EVAL(ac_compile) 2>conftest.err; then 5559238106Sdes soname=conftest 5560238106Sdes lib=conftest 5561238106Sdes libobjs=conftest.$ac_objext 5562238106Sdes deplibs= 5563238106Sdes wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) 5564238106Sdes pic_flag=$_LT_TAGVAR(lt_prog_compiler_pic, $1) 5565238106Sdes compiler_flags=-v 5566238106Sdes linker_flags=-v 5567238106Sdes verstring= 5568238106Sdes output_objdir=. 5569238106Sdes libname=conftest 5570238106Sdes lt_save_allow_undefined_flag=$_LT_TAGVAR(allow_undefined_flag, $1) 5571238106Sdes _LT_TAGVAR(allow_undefined_flag, $1)= 5572238106Sdes if AC_TRY_EVAL(_LT_TAGVAR(archive_cmds, $1) 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 5573238106Sdes then 5574238106Sdes lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=no 5575238106Sdes else 5576238106Sdes lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=yes 5577238106Sdes fi 5578238106Sdes _LT_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag 5579238106Sdes else 5580238106Sdes cat conftest.err 1>&5 5581238106Sdes fi 5582238106Sdes $RM conftest* 5583238106Sdes ]) 5584238106Sdes _LT_TAGVAR(archive_cmds_need_lc, $1)=$lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1) 5585238106Sdes ;; 5586238106Sdes esac 5587238106Sdes fi 5588238106Sdes ;; 5589238106Sdesesac 5590238106Sdes 5591238106Sdes_LT_TAGDECL([build_libtool_need_lc], [archive_cmds_need_lc], [0], 5592238106Sdes [Whether or not to add -lc for building shared libraries]) 5593238106Sdes_LT_TAGDECL([allow_libtool_libs_with_static_runtimes], 5594238106Sdes [enable_shared_with_static_runtimes], [0], 5595238106Sdes [Whether or not to disallow shared libs when runtime libs are static]) 5596238106Sdes_LT_TAGDECL([], [export_dynamic_flag_spec], [1], 5597238106Sdes [Compiler flag to allow reflexive dlopens]) 5598238106Sdes_LT_TAGDECL([], [whole_archive_flag_spec], [1], 5599238106Sdes [Compiler flag to generate shared objects directly from archives]) 5600238106Sdes_LT_TAGDECL([], [compiler_needs_object], [1], 5601238106Sdes [Whether the compiler copes with passing no objects directly]) 5602238106Sdes_LT_TAGDECL([], [old_archive_from_new_cmds], [2], 5603238106Sdes [Create an old-style archive from a shared archive]) 5604238106Sdes_LT_TAGDECL([], [old_archive_from_expsyms_cmds], [2], 5605238106Sdes [Create a temporary old-style archive to link instead of a shared archive]) 5606238106Sdes_LT_TAGDECL([], [archive_cmds], [2], [Commands used to build a shared archive]) 5607238106Sdes_LT_TAGDECL([], [archive_expsym_cmds], [2]) 5608238106Sdes_LT_TAGDECL([], [module_cmds], [2], 5609238106Sdes [Commands used to build a loadable module if different from building 5610238106Sdes a shared archive.]) 5611238106Sdes_LT_TAGDECL([], [module_expsym_cmds], [2]) 5612238106Sdes_LT_TAGDECL([], [with_gnu_ld], [1], 5613238106Sdes [Whether we are building with GNU ld or not]) 5614238106Sdes_LT_TAGDECL([], [allow_undefined_flag], [1], 5615238106Sdes [Flag that allows shared libraries with undefined symbols to be built]) 5616238106Sdes_LT_TAGDECL([], [no_undefined_flag], [1], 5617238106Sdes [Flag that enforces no undefined symbols]) 5618238106Sdes_LT_TAGDECL([], [hardcode_libdir_flag_spec], [1], 5619238106Sdes [Flag to hardcode $libdir into a binary during linking. 5620238106Sdes This must work even if $libdir does not exist]) 5621238106Sdes_LT_TAGDECL([], [hardcode_libdir_flag_spec_ld], [1], 5622238106Sdes [[If ld is used when linking, flag to hardcode $libdir into a binary 5623238106Sdes during linking. This must work even if $libdir does not exist]]) 5624238106Sdes_LT_TAGDECL([], [hardcode_libdir_separator], [1], 5625238106Sdes [Whether we need a single "-rpath" flag with a separated argument]) 5626238106Sdes_LT_TAGDECL([], [hardcode_direct], [0], 5627238106Sdes [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes 5628238106Sdes DIR into the resulting binary]) 5629238106Sdes_LT_TAGDECL([], [hardcode_direct_absolute], [0], 5630238106Sdes [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes 5631238106Sdes DIR into the resulting binary and the resulting library dependency is 5632238106Sdes "absolute", i.e impossible to change by setting ${shlibpath_var} if the 5633238106Sdes library is relocated]) 5634238106Sdes_LT_TAGDECL([], [hardcode_minus_L], [0], 5635238106Sdes [Set to "yes" if using the -LDIR flag during linking hardcodes DIR 5636238106Sdes into the resulting binary]) 5637238106Sdes_LT_TAGDECL([], [hardcode_shlibpath_var], [0], 5638238106Sdes [Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR 5639238106Sdes into the resulting binary]) 5640238106Sdes_LT_TAGDECL([], [hardcode_automatic], [0], 5641238106Sdes [Set to "yes" if building a shared library automatically hardcodes DIR 5642238106Sdes into the library and all subsequent libraries and executables linked 5643238106Sdes against it]) 5644238106Sdes_LT_TAGDECL([], [inherit_rpath], [0], 5645238106Sdes [Set to yes if linker adds runtime paths of dependent libraries 5646238106Sdes to runtime path list]) 5647238106Sdes_LT_TAGDECL([], [link_all_deplibs], [0], 5648238106Sdes [Whether libtool must link a program against all its dependency libraries]) 5649238106Sdes_LT_TAGDECL([], [always_export_symbols], [0], 5650238106Sdes [Set to "yes" if exported symbols are required]) 5651238106Sdes_LT_TAGDECL([], [export_symbols_cmds], [2], 5652238106Sdes [The commands to list exported symbols]) 5653238106Sdes_LT_TAGDECL([], [exclude_expsyms], [1], 5654238106Sdes [Symbols that should not be listed in the preloaded symbols]) 5655238106Sdes_LT_TAGDECL([], [include_expsyms], [1], 5656238106Sdes [Symbols that must always be exported]) 5657238106Sdes_LT_TAGDECL([], [prelink_cmds], [2], 5658238106Sdes [Commands necessary for linking programs (against libraries) with templates]) 5659238106Sdes_LT_TAGDECL([], [postlink_cmds], [2], 5660238106Sdes [Commands necessary for finishing linking programs]) 5661238106Sdes_LT_TAGDECL([], [file_list_spec], [1], 5662238106Sdes [Specify filename containing input files]) 5663238106Sdesdnl FIXME: Not yet implemented 5664238106Sdesdnl _LT_TAGDECL([], [thread_safe_flag_spec], [1], 5665238106Sdesdnl [Compiler flag to generate thread safe objects]) 5666238106Sdes])# _LT_LINKER_SHLIBS 5667238106Sdes 5668238106Sdes 5669238106Sdes# _LT_LANG_C_CONFIG([TAG]) 5670238106Sdes# ------------------------ 5671238106Sdes# Ensure that the configuration variables for a C compiler are suitably 5672238106Sdes# defined. These variables are subsequently used by _LT_CONFIG to write 5673238106Sdes# the compiler configuration to `libtool'. 5674238106Sdesm4_defun([_LT_LANG_C_CONFIG], 5675238106Sdes[m4_require([_LT_DECL_EGREP])dnl 5676238106Sdeslt_save_CC="$CC" 5677238106SdesAC_LANG_PUSH(C) 5678238106Sdes 5679238106Sdes# Source file extension for C test sources. 5680238106Sdesac_ext=c 5681238106Sdes 5682238106Sdes# Object file extension for compiled C test sources. 5683238106Sdesobjext=o 5684238106Sdes_LT_TAGVAR(objext, $1)=$objext 5685238106Sdes 5686238106Sdes# Code to be used in simple compile tests 5687238106Sdeslt_simple_compile_test_code="int some_variable = 0;" 5688238106Sdes 5689238106Sdes# Code to be used in simple link tests 5690238106Sdeslt_simple_link_test_code='int main(){return(0);}' 5691238106Sdes 5692238106Sdes_LT_TAG_COMPILER 5693238106Sdes# Save the default compiler, since it gets overwritten when the other 5694238106Sdes# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP. 5695238106Sdescompiler_DEFAULT=$CC 5696238106Sdes 5697238106Sdes# save warnings/boilerplate of simple test code 5698238106Sdes_LT_COMPILER_BOILERPLATE 5699238106Sdes_LT_LINKER_BOILERPLATE 5700238106Sdes 5701238106Sdesif test -n "$compiler"; then 5702238106Sdes _LT_COMPILER_NO_RTTI($1) 5703238106Sdes _LT_COMPILER_PIC($1) 5704238106Sdes _LT_COMPILER_C_O($1) 5705238106Sdes _LT_COMPILER_FILE_LOCKS($1) 5706238106Sdes _LT_LINKER_SHLIBS($1) 5707238106Sdes _LT_SYS_DYNAMIC_LINKER($1) 5708238106Sdes _LT_LINKER_HARDCODE_LIBPATH($1) 5709238106Sdes LT_SYS_DLOPEN_SELF 5710238106Sdes _LT_CMD_STRIPLIB 5711238106Sdes 5712238106Sdes # Report which library types will actually be built 5713238106Sdes AC_MSG_CHECKING([if libtool supports shared libraries]) 5714238106Sdes AC_MSG_RESULT([$can_build_shared]) 5715238106Sdes 5716238106Sdes AC_MSG_CHECKING([whether to build shared libraries]) 5717238106Sdes test "$can_build_shared" = "no" && enable_shared=no 5718238106Sdes 5719238106Sdes # On AIX, shared libraries and static libraries use the same namespace, and 5720238106Sdes # are all built from PIC. 5721238106Sdes case $host_os in 5722238106Sdes aix3*) 5723238106Sdes test "$enable_shared" = yes && enable_static=no 5724238106Sdes if test -n "$RANLIB"; then 5725238106Sdes archive_cmds="$archive_cmds~\$RANLIB \$lib" 5726238106Sdes postinstall_cmds='$RANLIB $lib' 5727238106Sdes fi 5728238106Sdes ;; 5729238106Sdes 5730238106Sdes aix[[4-9]]*) 5731238106Sdes if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then 5732238106Sdes test "$enable_shared" = yes && enable_static=no 5733238106Sdes fi 5734238106Sdes ;; 5735238106Sdes esac 5736238106Sdes AC_MSG_RESULT([$enable_shared]) 5737238106Sdes 5738238106Sdes AC_MSG_CHECKING([whether to build static libraries]) 5739238106Sdes # Make sure either enable_shared or enable_static is yes. 5740238106Sdes test "$enable_shared" = yes || enable_static=yes 5741238106Sdes AC_MSG_RESULT([$enable_static]) 5742238106Sdes 5743238106Sdes _LT_CONFIG($1) 5744238106Sdesfi 5745238106SdesAC_LANG_POP 5746238106SdesCC="$lt_save_CC" 5747238106Sdes])# _LT_LANG_C_CONFIG 5748238106Sdes 5749238106Sdes 5750238106Sdes# _LT_LANG_CXX_CONFIG([TAG]) 5751238106Sdes# -------------------------- 5752238106Sdes# Ensure that the configuration variables for a C++ compiler are suitably 5753238106Sdes# defined. These variables are subsequently used by _LT_CONFIG to write 5754238106Sdes# the compiler configuration to `libtool'. 5755238106Sdesm4_defun([_LT_LANG_CXX_CONFIG], 5756238106Sdes[m4_require([_LT_FILEUTILS_DEFAULTS])dnl 5757238106Sdesm4_require([_LT_DECL_EGREP])dnl 5758238106Sdesm4_require([_LT_PATH_MANIFEST_TOOL])dnl 5759238106Sdesif test -n "$CXX" && ( test "X$CXX" != "Xno" && 5760238106Sdes ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || 5761238106Sdes (test "X$CXX" != "Xg++"))) ; then 5762238106Sdes AC_PROG_CXXCPP 5763238106Sdeselse 5764238106Sdes _lt_caught_CXX_error=yes 5765238106Sdesfi 5766238106Sdes 5767238106SdesAC_LANG_PUSH(C++) 5768238106Sdes_LT_TAGVAR(archive_cmds_need_lc, $1)=no 5769238106Sdes_LT_TAGVAR(allow_undefined_flag, $1)= 5770238106Sdes_LT_TAGVAR(always_export_symbols, $1)=no 5771238106Sdes_LT_TAGVAR(archive_expsym_cmds, $1)= 5772238106Sdes_LT_TAGVAR(compiler_needs_object, $1)=no 5773238106Sdes_LT_TAGVAR(export_dynamic_flag_spec, $1)= 5774238106Sdes_LT_TAGVAR(hardcode_direct, $1)=no 5775238106Sdes_LT_TAGVAR(hardcode_direct_absolute, $1)=no 5776238106Sdes_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 5777238106Sdes_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= 5778238106Sdes_LT_TAGVAR(hardcode_libdir_separator, $1)= 5779238106Sdes_LT_TAGVAR(hardcode_minus_L, $1)=no 5780238106Sdes_LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported 5781238106Sdes_LT_TAGVAR(hardcode_automatic, $1)=no 5782238106Sdes_LT_TAGVAR(inherit_rpath, $1)=no 5783238106Sdes_LT_TAGVAR(module_cmds, $1)= 5784238106Sdes_LT_TAGVAR(module_expsym_cmds, $1)= 5785238106Sdes_LT_TAGVAR(link_all_deplibs, $1)=unknown 5786238106Sdes_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 5787238106Sdes_LT_TAGVAR(reload_flag, $1)=$reload_flag 5788238106Sdes_LT_TAGVAR(reload_cmds, $1)=$reload_cmds 5789238106Sdes_LT_TAGVAR(no_undefined_flag, $1)= 5790238106Sdes_LT_TAGVAR(whole_archive_flag_spec, $1)= 5791238106Sdes_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no 5792238106Sdes 5793238106Sdes# Source file extension for C++ test sources. 5794238106Sdesac_ext=cpp 5795238106Sdes 5796238106Sdes# Object file extension for compiled C++ test sources. 5797238106Sdesobjext=o 5798238106Sdes_LT_TAGVAR(objext, $1)=$objext 5799238106Sdes 5800238106Sdes# No sense in running all these tests if we already determined that 5801238106Sdes# the CXX compiler isn't working. Some variables (like enable_shared) 5802238106Sdes# are currently assumed to apply to all compilers on this platform, 5803238106Sdes# and will be corrupted by setting them based on a non-working compiler. 5804238106Sdesif test "$_lt_caught_CXX_error" != yes; then 5805238106Sdes # Code to be used in simple compile tests 5806238106Sdes lt_simple_compile_test_code="int some_variable = 0;" 5807238106Sdes 5808238106Sdes # Code to be used in simple link tests 5809238106Sdes lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }' 5810238106Sdes 5811238106Sdes # ltmain only uses $CC for tagged configurations so make sure $CC is set. 5812238106Sdes _LT_TAG_COMPILER 5813238106Sdes 5814238106Sdes # save warnings/boilerplate of simple test code 5815238106Sdes _LT_COMPILER_BOILERPLATE 5816238106Sdes _LT_LINKER_BOILERPLATE 5817238106Sdes 5818238106Sdes # Allow CC to be a program name with arguments. 5819238106Sdes lt_save_CC=$CC 5820238106Sdes lt_save_CFLAGS=$CFLAGS 5821238106Sdes lt_save_LD=$LD 5822238106Sdes lt_save_GCC=$GCC 5823238106Sdes GCC=$GXX 5824238106Sdes lt_save_with_gnu_ld=$with_gnu_ld 5825238106Sdes lt_save_path_LD=$lt_cv_path_LD 5826238106Sdes if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then 5827238106Sdes lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx 5828238106Sdes else 5829238106Sdes $as_unset lt_cv_prog_gnu_ld 5830238106Sdes fi 5831238106Sdes if test -n "${lt_cv_path_LDCXX+set}"; then 5832238106Sdes lt_cv_path_LD=$lt_cv_path_LDCXX 5833238106Sdes else 5834238106Sdes $as_unset lt_cv_path_LD 5835238106Sdes fi 5836238106Sdes test -z "${LDCXX+set}" || LD=$LDCXX 5837238106Sdes CC=${CXX-"c++"} 5838238106Sdes CFLAGS=$CXXFLAGS 5839238106Sdes compiler=$CC 5840238106Sdes _LT_TAGVAR(compiler, $1)=$CC 5841238106Sdes _LT_CC_BASENAME([$compiler]) 5842238106Sdes 5843238106Sdes if test -n "$compiler"; then 5844238106Sdes # We don't want -fno-exception when compiling C++ code, so set the 5845238106Sdes # no_builtin_flag separately 5846238106Sdes if test "$GXX" = yes; then 5847238106Sdes _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' 5848238106Sdes else 5849238106Sdes _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= 5850238106Sdes fi 5851238106Sdes 5852238106Sdes if test "$GXX" = yes; then 5853238106Sdes # Set up default GNU C++ configuration 5854238106Sdes 5855238106Sdes LT_PATH_LD 5856238106Sdes 5857238106Sdes # Check if GNU C++ uses GNU ld as the underlying linker, since the 5858238106Sdes # archiving commands below assume that GNU ld is being used. 5859238106Sdes if test "$with_gnu_ld" = yes; then 5860238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' 5861238106Sdes _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' 5862238106Sdes 5863238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 5864238106Sdes _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 5865238106Sdes 5866238106Sdes # If archive_cmds runs LD, not CC, wlarc should be empty 5867238106Sdes # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to 5868238106Sdes # investigate it a little bit more. (MM) 5869238106Sdes wlarc='${wl}' 5870238106Sdes 5871238106Sdes # ancient GNU ld didn't support --whole-archive et. al. 5872238106Sdes if eval "`$CC -print-prog-name=ld` --help 2>&1" | 5873238106Sdes $GREP 'no-whole-archive' > /dev/null; then 5874238106Sdes _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' 5875238106Sdes else 5876238106Sdes _LT_TAGVAR(whole_archive_flag_spec, $1)= 5877238106Sdes fi 5878238106Sdes else 5879238106Sdes with_gnu_ld=no 5880238106Sdes wlarc= 5881238106Sdes 5882238106Sdes # A generic and very simple default shared library creation 5883238106Sdes # command for GNU C++ for the case where it uses the native 5884238106Sdes # linker, instead of GNU ld. If possible, this setting should 5885238106Sdes # overridden to take advantage of the native linker features on 5886238106Sdes # the platform it is being used on. 5887238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' 5888238106Sdes fi 5889238106Sdes 5890238106Sdes # Commands to make compiler produce verbose output that lists 5891238106Sdes # what "hidden" libraries, object files and flags are used when 5892238106Sdes # linking a shared library. 5893238106Sdes output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' 5894238106Sdes 5895238106Sdes else 5896238106Sdes GXX=no 5897238106Sdes with_gnu_ld=no 5898238106Sdes wlarc= 5899238106Sdes fi 5900238106Sdes 5901238106Sdes # PORTME: fill in a description of your system's C++ link characteristics 5902238106Sdes AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) 5903238106Sdes _LT_TAGVAR(ld_shlibs, $1)=yes 5904238106Sdes case $host_os in 5905238106Sdes aix3*) 5906238106Sdes # FIXME: insert proper C++ library support 5907238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 5908238106Sdes ;; 5909238106Sdes aix[[4-9]]*) 5910238106Sdes if test "$host_cpu" = ia64; then 5911238106Sdes # On IA64, the linker does run time linking by default, so we don't 5912238106Sdes # have to do anything special. 5913238106Sdes aix_use_runtimelinking=no 5914238106Sdes exp_sym_flag='-Bexport' 5915238106Sdes no_entry_flag="" 5916238106Sdes else 5917238106Sdes aix_use_runtimelinking=no 5918238106Sdes 5919238106Sdes # Test if we are trying to use run time linking or normal 5920238106Sdes # AIX style linking. If -brtl is somewhere in LDFLAGS, we 5921238106Sdes # need to do runtime linking. 5922238106Sdes case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) 5923238106Sdes for ld_flag in $LDFLAGS; do 5924238106Sdes case $ld_flag in 5925238106Sdes *-brtl*) 5926238106Sdes aix_use_runtimelinking=yes 5927238106Sdes break 5928238106Sdes ;; 5929238106Sdes esac 5930238106Sdes done 5931238106Sdes ;; 5932238106Sdes esac 5933238106Sdes 5934238106Sdes exp_sym_flag='-bexport' 5935238106Sdes no_entry_flag='-bnoentry' 5936238106Sdes fi 5937238106Sdes 5938238106Sdes # When large executables or shared objects are built, AIX ld can 5939238106Sdes # have problems creating the table of contents. If linking a library 5940238106Sdes # or program results in "error TOC overflow" add -mminimal-toc to 5941238106Sdes # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not 5942238106Sdes # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. 5943238106Sdes 5944238106Sdes _LT_TAGVAR(archive_cmds, $1)='' 5945238106Sdes _LT_TAGVAR(hardcode_direct, $1)=yes 5946238106Sdes _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 5947238106Sdes _LT_TAGVAR(hardcode_libdir_separator, $1)=':' 5948238106Sdes _LT_TAGVAR(link_all_deplibs, $1)=yes 5949238106Sdes _LT_TAGVAR(file_list_spec, $1)='${wl}-f,' 5950238106Sdes 5951238106Sdes if test "$GXX" = yes; then 5952238106Sdes case $host_os in aix4.[[012]]|aix4.[[012]].*) 5953238106Sdes # We only want to do this on AIX 4.2 and lower, the check 5954238106Sdes # below for broken collect2 doesn't work under 4.3+ 5955238106Sdes collect2name=`${CC} -print-prog-name=collect2` 5956238106Sdes if test -f "$collect2name" && 5957238106Sdes strings "$collect2name" | $GREP resolve_lib_name >/dev/null 5958238106Sdes then 5959238106Sdes # We have reworked collect2 5960238106Sdes : 5961238106Sdes else 5962238106Sdes # We have old collect2 5963238106Sdes _LT_TAGVAR(hardcode_direct, $1)=unsupported 5964238106Sdes # It fails to find uninstalled libraries when the uninstalled 5965238106Sdes # path is not listed in the libpath. Setting hardcode_minus_L 5966238106Sdes # to unsupported forces relinking 5967238106Sdes _LT_TAGVAR(hardcode_minus_L, $1)=yes 5968238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 5969238106Sdes _LT_TAGVAR(hardcode_libdir_separator, $1)= 5970238106Sdes fi 5971238106Sdes esac 5972238106Sdes shared_flag='-shared' 5973238106Sdes if test "$aix_use_runtimelinking" = yes; then 5974238106Sdes shared_flag="$shared_flag "'${wl}-G' 5975238106Sdes fi 5976238106Sdes else 5977238106Sdes # not using gcc 5978238106Sdes if test "$host_cpu" = ia64; then 5979238106Sdes # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release 5980238106Sdes # chokes on -Wl,-G. The following line is correct: 5981238106Sdes shared_flag='-G' 5982238106Sdes else 5983238106Sdes if test "$aix_use_runtimelinking" = yes; then 5984238106Sdes shared_flag='${wl}-G' 5985238106Sdes else 5986238106Sdes shared_flag='${wl}-bM:SRE' 5987238106Sdes fi 5988238106Sdes fi 5989238106Sdes fi 5990238106Sdes 5991238106Sdes _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall' 5992238106Sdes # It seems that -bexpall does not export symbols beginning with 5993238106Sdes # underscore (_), so it is better to generate a list of symbols to 5994238106Sdes # export. 5995238106Sdes _LT_TAGVAR(always_export_symbols, $1)=yes 5996238106Sdes if test "$aix_use_runtimelinking" = yes; then 5997238106Sdes # Warning - without using the other runtime loading flags (-brtl), 5998238106Sdes # -berok will link without error, but may produce a broken library. 5999238106Sdes _LT_TAGVAR(allow_undefined_flag, $1)='-berok' 6000238106Sdes # Determine the default libpath from the value encoded in an empty 6001238106Sdes # executable. 6002238106Sdes _LT_SYS_MODULE_PATH_AIX([$1]) 6003238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" 6004238106Sdes 6005238106Sdes _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" 6006238106Sdes else 6007238106Sdes if test "$host_cpu" = ia64; then 6008238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' 6009238106Sdes _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" 6010238106Sdes _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" 6011238106Sdes else 6012238106Sdes # Determine the default libpath from the value encoded in an 6013238106Sdes # empty executable. 6014238106Sdes _LT_SYS_MODULE_PATH_AIX([$1]) 6015238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" 6016238106Sdes # Warning - without using the other run time loading flags, 6017238106Sdes # -berok will link without error, but may produce a broken library. 6018238106Sdes _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' 6019238106Sdes _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' 6020238106Sdes if test "$with_gnu_ld" = yes; then 6021238106Sdes # We only use this code for GNU lds that support --whole-archive. 6022238106Sdes _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' 6023238106Sdes else 6024238106Sdes # Exported symbols can be pulled into shared objects from archives 6025238106Sdes _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' 6026238106Sdes fi 6027238106Sdes _LT_TAGVAR(archive_cmds_need_lc, $1)=yes 6028238106Sdes # This is similar to how AIX traditionally builds its shared 6029238106Sdes # libraries. 6030238106Sdes _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' 6031238106Sdes fi 6032238106Sdes fi 6033238106Sdes ;; 6034238106Sdes 6035238106Sdes beos*) 6036238106Sdes if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 6037238106Sdes _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 6038238106Sdes # Joseph Beckenbach <jrb3@best.com> says some releases of gcc 6039238106Sdes # support --undefined. This deserves some investigation. FIXME 6040238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 6041238106Sdes else 6042238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 6043238106Sdes fi 6044238106Sdes ;; 6045238106Sdes 6046238106Sdes chorus*) 6047238106Sdes case $cc_basename in 6048238106Sdes *) 6049238106Sdes # FIXME: insert proper C++ library support 6050238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 6051238106Sdes ;; 6052238106Sdes esac 6053238106Sdes ;; 6054238106Sdes 6055238106Sdes cygwin* | mingw* | pw32* | cegcc*) 6056238106Sdes case $GXX,$cc_basename in 6057238106Sdes ,cl* | no,cl*) 6058238106Sdes # Native MSVC 6059238106Sdes # hardcode_libdir_flag_spec is actually meaningless, as there is 6060238106Sdes # no search path for DLLs. 6061238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' 6062238106Sdes _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 6063238106Sdes _LT_TAGVAR(always_export_symbols, $1)=yes 6064238106Sdes _LT_TAGVAR(file_list_spec, $1)='@' 6065238106Sdes # Tell ltmain to make .lib files, not .a files. 6066238106Sdes libext=lib 6067238106Sdes # Tell ltmain to make .dll files, not .so files. 6068238106Sdes shrext_cmds=".dll" 6069238106Sdes # FIXME: Setting linknames here is a bad hack. 6070238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames=' 6071238106Sdes _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then 6072238106Sdes $SED -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp; 6073238106Sdes else 6074238106Sdes $SED -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp; 6075238106Sdes fi~ 6076238106Sdes $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ 6077238106Sdes linknames=' 6078238106Sdes # The linker will not automatically build a static lib if we build a DLL. 6079238106Sdes # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' 6080238106Sdes _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 6081238106Sdes # Don't use ranlib 6082238106Sdes _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib' 6083238106Sdes _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~ 6084238106Sdes lt_tool_outputfile="@TOOL_OUTPUT@"~ 6085238106Sdes case $lt_outputfile in 6086238106Sdes *.exe|*.EXE) ;; 6087238106Sdes *) 6088238106Sdes lt_outputfile="$lt_outputfile.exe" 6089238106Sdes lt_tool_outputfile="$lt_tool_outputfile.exe" 6090238106Sdes ;; 6091238106Sdes esac~ 6092238106Sdes func_to_tool_file "$lt_outputfile"~ 6093238106Sdes if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then 6094238106Sdes $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; 6095238106Sdes $RM "$lt_outputfile.manifest"; 6096238106Sdes fi' 6097238106Sdes ;; 6098238106Sdes *) 6099238106Sdes # g++ 6100238106Sdes # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, 6101238106Sdes # as there is no search path for DLLs. 6102238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 6103238106Sdes _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols' 6104238106Sdes _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 6105238106Sdes _LT_TAGVAR(always_export_symbols, $1)=no 6106238106Sdes _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 6107238106Sdes 6108238106Sdes if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then 6109238106Sdes _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' 6110238106Sdes # If the export-symbols file already is a .def file (1st line 6111238106Sdes # is EXPORTS), use it as is; otherwise, prepend... 6112238106Sdes _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then 6113238106Sdes cp $export_symbols $output_objdir/$soname.def; 6114238106Sdes else 6115238106Sdes echo EXPORTS > $output_objdir/$soname.def; 6116238106Sdes cat $export_symbols >> $output_objdir/$soname.def; 6117238106Sdes fi~ 6118238106Sdes $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' 6119238106Sdes else 6120238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 6121238106Sdes fi 6122238106Sdes ;; 6123238106Sdes esac 6124238106Sdes ;; 6125238106Sdes darwin* | rhapsody*) 6126238106Sdes _LT_DARWIN_LINKER_FEATURES($1) 6127238106Sdes ;; 6128238106Sdes 6129238106Sdes dgux*) 6130238106Sdes case $cc_basename in 6131238106Sdes ec++*) 6132238106Sdes # FIXME: insert proper C++ library support 6133238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 6134238106Sdes ;; 6135238106Sdes ghcx*) 6136238106Sdes # Green Hills C++ Compiler 6137238106Sdes # FIXME: insert proper C++ library support 6138238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 6139238106Sdes ;; 6140238106Sdes *) 6141238106Sdes # FIXME: insert proper C++ library support 6142238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 6143238106Sdes ;; 6144238106Sdes esac 6145238106Sdes ;; 6146238106Sdes 6147238106Sdes freebsd[[12]]*) 6148238106Sdes # C++ shared libraries reported to be fairly broken before 6149238106Sdes # switch to ELF 6150238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 6151238106Sdes ;; 6152238106Sdes 6153238106Sdes freebsd-elf*) 6154238106Sdes _LT_TAGVAR(archive_cmds_need_lc, $1)=no 6155238106Sdes ;; 6156238106Sdes 6157238106Sdes freebsd* | dragonfly*) 6158238106Sdes # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF 6159238106Sdes # conventions 6160238106Sdes _LT_TAGVAR(ld_shlibs, $1)=yes 6161238106Sdes ;; 6162238106Sdes 6163238106Sdes gnu*) 6164238106Sdes ;; 6165238106Sdes 6166238106Sdes haiku*) 6167238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 6168238106Sdes _LT_TAGVAR(link_all_deplibs, $1)=yes 6169238106Sdes ;; 6170238106Sdes 6171238106Sdes hpux9*) 6172238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 6173238106Sdes _LT_TAGVAR(hardcode_libdir_separator, $1)=: 6174238106Sdes _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 6175238106Sdes _LT_TAGVAR(hardcode_direct, $1)=yes 6176238106Sdes _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, 6177238106Sdes # but as the default 6178238106Sdes # location of the library. 6179238106Sdes 6180238106Sdes case $cc_basename in 6181238106Sdes CC*) 6182238106Sdes # FIXME: insert proper C++ library support 6183238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 6184238106Sdes ;; 6185238106Sdes aCC*) 6186238106Sdes _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' 6187238106Sdes # Commands to make compiler produce verbose output that lists 6188238106Sdes # what "hidden" libraries, object files and flags are used when 6189238106Sdes # linking a shared library. 6190238106Sdes # 6191238106Sdes # There doesn't appear to be a way to prevent this compiler from 6192238106Sdes # explicitly linking system object files so we need to strip them 6193238106Sdes # from the output so that they don't get included in the library 6194238106Sdes # dependencies. 6195238106Sdes 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"' 6196238106Sdes ;; 6197238106Sdes *) 6198238106Sdes if test "$GXX" = yes; then 6199238106Sdes _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 $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' 6200238106Sdes else 6201238106Sdes # FIXME: insert proper C++ library support 6202238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 6203238106Sdes fi 6204238106Sdes ;; 6205238106Sdes esac 6206238106Sdes ;; 6207238106Sdes 6208238106Sdes hpux10*|hpux11*) 6209238106Sdes if test $with_gnu_ld = no; then 6210238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 6211238106Sdes _LT_TAGVAR(hardcode_libdir_separator, $1)=: 6212238106Sdes 6213238106Sdes case $host_cpu in 6214238106Sdes hppa*64*|ia64*) 6215238106Sdes ;; 6216238106Sdes *) 6217238106Sdes _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 6218238106Sdes ;; 6219238106Sdes esac 6220238106Sdes fi 6221238106Sdes case $host_cpu in 6222238106Sdes hppa*64*|ia64*) 6223238106Sdes _LT_TAGVAR(hardcode_direct, $1)=no 6224238106Sdes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 6225238106Sdes ;; 6226238106Sdes *) 6227238106Sdes _LT_TAGVAR(hardcode_direct, $1)=yes 6228238106Sdes _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 6229238106Sdes _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, 6230238106Sdes # but as the default 6231238106Sdes # location of the library. 6232238106Sdes ;; 6233238106Sdes esac 6234238106Sdes 6235238106Sdes case $cc_basename in 6236238106Sdes CC*) 6237238106Sdes # FIXME: insert proper C++ library support 6238238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 6239238106Sdes ;; 6240238106Sdes aCC*) 6241238106Sdes case $host_cpu in 6242238106Sdes hppa*64*) 6243238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 6244238106Sdes ;; 6245238106Sdes ia64*) 6246238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 6247238106Sdes ;; 6248238106Sdes *) 6249238106Sdes _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' 6250238106Sdes ;; 6251238106Sdes esac 6252238106Sdes # Commands to make compiler produce verbose output that lists 6253238106Sdes # what "hidden" libraries, object files and flags are used when 6254238106Sdes # linking a shared library. 6255238106Sdes # 6256238106Sdes # There doesn't appear to be a way to prevent this compiler from 6257238106Sdes # explicitly linking system object files so we need to strip them 6258238106Sdes # from the output so that they don't get included in the library 6259238106Sdes # dependencies. 6260238106Sdes 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"' 6261238106Sdes ;; 6262238106Sdes *) 6263238106Sdes if test "$GXX" = yes; then 6264238106Sdes if test $with_gnu_ld = no; then 6265238106Sdes case $host_cpu in 6266238106Sdes hppa*64*) 6267238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 6268238106Sdes ;; 6269238106Sdes ia64*) 6270238106Sdes _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' 6271238106Sdes ;; 6272238106Sdes *) 6273238106Sdes _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' 6274238106Sdes ;; 6275238106Sdes esac 6276238106Sdes fi 6277238106Sdes else 6278238106Sdes # FIXME: insert proper C++ library support 6279238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 6280238106Sdes fi 6281238106Sdes ;; 6282238106Sdes esac 6283238106Sdes ;; 6284238106Sdes 6285238106Sdes interix[[3-9]]*) 6286238106Sdes _LT_TAGVAR(hardcode_direct, $1)=no 6287238106Sdes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 6288238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 6289238106Sdes _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 6290238106Sdes # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. 6291238106Sdes # Instead, shared libraries are loaded at an image base (0x10000000 by 6292238106Sdes # default) and relocated if they conflict, which is a slow very memory 6293238106Sdes # consuming and fragmenting process. To avoid this, we pick a random, 6294238106Sdes # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link 6295238106Sdes # time. Moving up from 0x10000000 also allows more sbrk(2) space. 6296238106Sdes _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' 6297238106Sdes _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' 6298238106Sdes ;; 6299238106Sdes irix5* | irix6*) 6300238106Sdes case $cc_basename in 6301238106Sdes CC*) 6302238106Sdes # SGI C++ 6303238106Sdes _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' 6304238106Sdes 6305238106Sdes # Archives containing C++ object files must be created using 6306238106Sdes # "CC -ar", where "CC" is the IRIX C++ compiler. This is 6307238106Sdes # necessary to make sure instantiated templates are included 6308238106Sdes # in the archive. 6309238106Sdes _LT_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs' 6310238106Sdes ;; 6311238106Sdes *) 6312238106Sdes if test "$GXX" = yes; then 6313238106Sdes if test "$with_gnu_ld" = no; then 6314238106Sdes _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' 6315238106Sdes else 6316238106Sdes _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' 6317238106Sdes fi 6318238106Sdes fi 6319238106Sdes _LT_TAGVAR(link_all_deplibs, $1)=yes 6320238106Sdes ;; 6321238106Sdes esac 6322238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 6323238106Sdes _LT_TAGVAR(hardcode_libdir_separator, $1)=: 6324238106Sdes _LT_TAGVAR(inherit_rpath, $1)=yes 6325238106Sdes ;; 6326238106Sdes 6327238106Sdes linux* | k*bsd*-gnu | kopensolaris*-gnu) 6328238106Sdes case $cc_basename in 6329238106Sdes KCC*) 6330238106Sdes # Kuck and Associates, Inc. (KAI) C++ Compiler 6331238106Sdes 6332238106Sdes # KCC will only create a shared library if the output file 6333238106Sdes # ends with ".so" (or ".sl" for HP-UX), so rename the library 6334238106Sdes # to its proper name (with version) after linking. 6335238106Sdes _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' 6336238106Sdes _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' 6337238106Sdes # Commands to make compiler produce verbose output that lists 6338238106Sdes # what "hidden" libraries, object files and flags are used when 6339238106Sdes # linking a shared library. 6340238106Sdes # 6341238106Sdes # There doesn't appear to be a way to prevent this compiler from 6342238106Sdes # explicitly linking system object files so we need to strip them 6343238106Sdes # from the output so that they don't get included in the library 6344238106Sdes # dependencies. 6345238106Sdes 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"' 6346238106Sdes 6347238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 6348238106Sdes _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 6349238106Sdes 6350238106Sdes # Archives containing C++ object files must be created using 6351238106Sdes # "CC -Bstatic", where "CC" is the KAI C++ compiler. 6352238106Sdes _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' 6353238106Sdes ;; 6354238106Sdes icpc* | ecpc* ) 6355238106Sdes # Intel C++ 6356238106Sdes with_gnu_ld=yes 6357238106Sdes # version 8.0 and above of icpc choke on multiply defined symbols 6358238106Sdes # if we add $predep_objects and $postdep_objects, however 7.1 and 6359238106Sdes # earlier do not add the objects themselves. 6360238106Sdes case `$CC -V 2>&1` in 6361238106Sdes *"Version 7."*) 6362238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' 6363238106Sdes _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' 6364238106Sdes ;; 6365238106Sdes *) # Version 8.0 or newer 6366238106Sdes tmp_idyn= 6367238106Sdes case $host_cpu in 6368238106Sdes ia64*) tmp_idyn=' -i_dynamic';; 6369238106Sdes esac 6370238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 6371238106Sdes _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' 6372238106Sdes ;; 6373238106Sdes esac 6374238106Sdes _LT_TAGVAR(archive_cmds_need_lc, $1)=no 6375238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 6376238106Sdes _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 6377238106Sdes _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' 6378238106Sdes ;; 6379238106Sdes pgCC* | pgcpp*) 6380238106Sdes # Portland Group C++ compiler 6381238106Sdes case `$CC -V` in 6382238106Sdes *pgCC\ [[1-5]].* | *pgcpp\ [[1-5]].*) 6383238106Sdes _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~ 6384238106Sdes rm -rf $tpldir~ 6385238106Sdes $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~ 6386238106Sdes compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"' 6387238106Sdes _LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~ 6388238106Sdes rm -rf $tpldir~ 6389238106Sdes $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~ 6390238106Sdes $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~ 6391238106Sdes $RANLIB $oldlib' 6392238106Sdes _LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~ 6393238106Sdes rm -rf $tpldir~ 6394238106Sdes $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ 6395238106Sdes $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' 6396238106Sdes _LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~ 6397238106Sdes rm -rf $tpldir~ 6398238106Sdes $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ 6399238106Sdes $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' 6400238106Sdes ;; 6401238106Sdes *) # Version 6 and above use weak symbols 6402238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' 6403238106Sdes _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' 6404238106Sdes ;; 6405238106Sdes esac 6406238106Sdes 6407238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir' 6408238106Sdes _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 6409238106Sdes _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' 6410238106Sdes ;; 6411238106Sdes cxx*) 6412238106Sdes # Compaq C++ 6413238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' 6414238106Sdes _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' 6415238106Sdes 6416238106Sdes runpath_var=LD_RUN_PATH 6417238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' 6418238106Sdes _LT_TAGVAR(hardcode_libdir_separator, $1)=: 6419238106Sdes 6420238106Sdes # Commands to make compiler produce verbose output that lists 6421238106Sdes # what "hidden" libraries, object files and flags are used when 6422238106Sdes # linking a shared library. 6423238106Sdes # 6424238106Sdes # There doesn't appear to be a way to prevent this compiler from 6425238106Sdes # explicitly linking system object files so we need to strip them 6426238106Sdes # from the output so that they don't get included in the library 6427238106Sdes # dependencies. 6428238106Sdes 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' 6429238106Sdes ;; 6430238106Sdes xl* | mpixl* | bgxl*) 6431238106Sdes # IBM XL 8.0 on PPC, with GNU ld 6432238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 6433238106Sdes _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 6434238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 6435238106Sdes if test "x$supports_anon_versioning" = xyes; then 6436238106Sdes _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ 6437238106Sdes cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ 6438238106Sdes echo "local: *; };" >> $output_objdir/$libname.ver~ 6439238106Sdes $CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' 6440238106Sdes fi 6441238106Sdes ;; 6442238106Sdes *) 6443238106Sdes case `$CC -V 2>&1 | sed 5q` in 6444238106Sdes *Sun\ C*) 6445238106Sdes # Sun C++ 5.9 6446238106Sdes _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' 6447238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 6448238106Sdes _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' 6449238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 6450238106Sdes _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' 6451238106Sdes _LT_TAGVAR(compiler_needs_object, $1)=yes 6452238106Sdes 6453238106Sdes # Not sure whether something based on 6454238106Sdes # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 6455238106Sdes # would be better. 6456238106Sdes output_verbose_link_cmd='func_echo_all' 6457238106Sdes 6458238106Sdes # Archives containing C++ object files must be created using 6459238106Sdes # "CC -xar", where "CC" is the Sun C++ compiler. This is 6460238106Sdes # necessary to make sure instantiated templates are included 6461238106Sdes # in the archive. 6462238106Sdes _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' 6463238106Sdes ;; 6464238106Sdes esac 6465238106Sdes ;; 6466238106Sdes esac 6467238106Sdes ;; 6468238106Sdes 6469238106Sdes lynxos*) 6470238106Sdes # FIXME: insert proper C++ library support 6471238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 6472238106Sdes ;; 6473238106Sdes 6474238106Sdes m88k*) 6475238106Sdes # FIXME: insert proper C++ library support 6476238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 6477238106Sdes ;; 6478238106Sdes 6479238106Sdes mvs*) 6480238106Sdes case $cc_basename in 6481238106Sdes cxx*) 6482238106Sdes # FIXME: insert proper C++ library support 6483238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 6484238106Sdes ;; 6485238106Sdes *) 6486238106Sdes # FIXME: insert proper C++ library support 6487238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 6488238106Sdes ;; 6489238106Sdes esac 6490238106Sdes ;; 6491238106Sdes 6492238106Sdes netbsd*) 6493238106Sdes if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then 6494238106Sdes _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' 6495238106Sdes wlarc= 6496238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 6497238106Sdes _LT_TAGVAR(hardcode_direct, $1)=yes 6498238106Sdes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 6499238106Sdes fi 6500238106Sdes # Workaround some broken pre-1.5 toolchains 6501238106Sdes output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' 6502238106Sdes ;; 6503238106Sdes 6504238106Sdes *nto* | *qnx*) 6505238106Sdes _LT_TAGVAR(ld_shlibs, $1)=yes 6506238106Sdes ;; 6507238106Sdes 6508238106Sdes openbsd2*) 6509238106Sdes # C++ shared libraries are fairly broken 6510238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 6511238106Sdes ;; 6512238106Sdes 6513238106Sdes openbsd*) 6514238106Sdes if test -f /usr/libexec/ld.so; then 6515238106Sdes _LT_TAGVAR(hardcode_direct, $1)=yes 6516238106Sdes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 6517238106Sdes _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 6518238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' 6519238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 6520238106Sdes if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then 6521238106Sdes _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' 6522238106Sdes _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 6523238106Sdes _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' 6524238106Sdes fi 6525238106Sdes output_verbose_link_cmd=func_echo_all 6526238106Sdes else 6527238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 6528238106Sdes fi 6529238106Sdes ;; 6530238106Sdes 6531238106Sdes osf3* | osf4* | osf5*) 6532238106Sdes case $cc_basename in 6533238106Sdes KCC*) 6534238106Sdes # Kuck and Associates, Inc. (KAI) C++ Compiler 6535238106Sdes 6536238106Sdes # KCC will only create a shared library if the output file 6537238106Sdes # ends with ".so" (or ".sl" for HP-UX), so rename the library 6538238106Sdes # to its proper name (with version) after linking. 6539238106Sdes _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' 6540238106Sdes 6541238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 6542238106Sdes _LT_TAGVAR(hardcode_libdir_separator, $1)=: 6543238106Sdes 6544238106Sdes # Archives containing C++ object files must be created using 6545238106Sdes # the KAI C++ compiler. 6546238106Sdes case $host in 6547238106Sdes osf3*) _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;; 6548238106Sdes *) _LT_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' ;; 6549238106Sdes esac 6550238106Sdes ;; 6551238106Sdes RCC*) 6552238106Sdes # Rational C++ 2.4.1 6553238106Sdes # FIXME: insert proper C++ library support 6554238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 6555238106Sdes ;; 6556238106Sdes cxx*) 6557238106Sdes case $host in 6558238106Sdes osf3*) 6559238106Sdes _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' 6560238106Sdes _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' 6561238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 6562238106Sdes ;; 6563238106Sdes *) 6564238106Sdes _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' 6565238106Sdes _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' 6566238106Sdes _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ 6567238106Sdes echo "-hidden">> $lib.exp~ 6568238106Sdes $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~ 6569238106Sdes $RM $lib.exp' 6570238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' 6571238106Sdes ;; 6572238106Sdes esac 6573238106Sdes 6574238106Sdes _LT_TAGVAR(hardcode_libdir_separator, $1)=: 6575238106Sdes 6576238106Sdes # Commands to make compiler produce verbose output that lists 6577238106Sdes # what "hidden" libraries, object files and flags are used when 6578238106Sdes # linking a shared library. 6579238106Sdes # 6580238106Sdes # There doesn't appear to be a way to prevent this compiler from 6581238106Sdes # explicitly linking system object files so we need to strip them 6582238106Sdes # from the output so that they don't get included in the library 6583238106Sdes # dependencies. 6584238106Sdes 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"' 6585238106Sdes ;; 6586238106Sdes *) 6587238106Sdes if test "$GXX" = yes && test "$with_gnu_ld" = no; then 6588238106Sdes _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' 6589238106Sdes case $host in 6590238106Sdes osf3*) 6591238106Sdes _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' 6592238106Sdes ;; 6593238106Sdes *) 6594238106Sdes _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' 6595238106Sdes ;; 6596238106Sdes esac 6597238106Sdes 6598238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 6599238106Sdes _LT_TAGVAR(hardcode_libdir_separator, $1)=: 6600238106Sdes 6601238106Sdes # Commands to make compiler produce verbose output that lists 6602238106Sdes # what "hidden" libraries, object files and flags are used when 6603238106Sdes # linking a shared library. 6604238106Sdes output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' 6605238106Sdes 6606238106Sdes else 6607238106Sdes # FIXME: insert proper C++ library support 6608238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 6609238106Sdes fi 6610238106Sdes ;; 6611238106Sdes esac 6612238106Sdes ;; 6613238106Sdes 6614238106Sdes psos*) 6615238106Sdes # FIXME: insert proper C++ library support 6616238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 6617238106Sdes ;; 6618238106Sdes 6619238106Sdes sunos4*) 6620238106Sdes case $cc_basename in 6621238106Sdes CC*) 6622238106Sdes # Sun C++ 4.x 6623238106Sdes # FIXME: insert proper C++ library support 6624238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 6625238106Sdes ;; 6626238106Sdes lcc*) 6627238106Sdes # Lucid 6628238106Sdes # FIXME: insert proper C++ library support 6629238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 6630238106Sdes ;; 6631238106Sdes *) 6632238106Sdes # FIXME: insert proper C++ library support 6633238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 6634238106Sdes ;; 6635238106Sdes esac 6636238106Sdes ;; 6637238106Sdes 6638238106Sdes solaris*) 6639238106Sdes case $cc_basename in 6640238106Sdes CC* | sunCC*) 6641238106Sdes # Sun C++ 4.2, 5.x and Centerline C++ 6642238106Sdes _LT_TAGVAR(archive_cmds_need_lc,$1)=yes 6643238106Sdes _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' 6644238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 6645238106Sdes _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 6646238106Sdes $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' 6647238106Sdes 6648238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 6649238106Sdes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 6650238106Sdes case $host_os in 6651238106Sdes solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; 6652238106Sdes *) 6653238106Sdes # The compiler driver will combine and reorder linker options, 6654238106Sdes # but understands `-z linker_flag'. 6655238106Sdes # Supported since Solaris 2.6 (maybe 2.5.1?) 6656238106Sdes _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' 6657238106Sdes ;; 6658238106Sdes esac 6659238106Sdes _LT_TAGVAR(link_all_deplibs, $1)=yes 6660238106Sdes 6661238106Sdes output_verbose_link_cmd='func_echo_all' 6662238106Sdes 6663238106Sdes # Archives containing C++ object files must be created using 6664238106Sdes # "CC -xar", where "CC" is the Sun C++ compiler. This is 6665238106Sdes # necessary to make sure instantiated templates are included 6666238106Sdes # in the archive. 6667238106Sdes _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' 6668238106Sdes ;; 6669238106Sdes gcx*) 6670238106Sdes # Green Hills C++ Compiler 6671238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' 6672238106Sdes 6673238106Sdes # The C++ compiler must be used to create the archive. 6674238106Sdes _LT_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs' 6675238106Sdes ;; 6676238106Sdes *) 6677238106Sdes # GNU C++ compiler with Solaris linker 6678238106Sdes if test "$GXX" = yes && test "$with_gnu_ld" = no; then 6679238106Sdes _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs' 6680238106Sdes if $CC --version | $GREP -v '^2\.7' > /dev/null; then 6681238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' 6682238106Sdes _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 6683238106Sdes $CC -shared $pic_flag -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' 6684238106Sdes 6685238106Sdes # Commands to make compiler produce verbose output that lists 6686238106Sdes # what "hidden" libraries, object files and flags are used when 6687238106Sdes # linking a shared library. 6688238106Sdes output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' 6689238106Sdes else 6690238106Sdes # g++ 2.7 appears to require `-G' NOT `-shared' on this 6691238106Sdes # platform. 6692238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' 6693238106Sdes _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 6694238106Sdes $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' 6695238106Sdes 6696238106Sdes # Commands to make compiler produce verbose output that lists 6697238106Sdes # what "hidden" libraries, object files and flags are used when 6698238106Sdes # linking a shared library. 6699238106Sdes output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' 6700238106Sdes fi 6701238106Sdes 6702238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir' 6703238106Sdes case $host_os in 6704238106Sdes solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; 6705238106Sdes *) 6706238106Sdes _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' 6707238106Sdes ;; 6708238106Sdes esac 6709238106Sdes fi 6710238106Sdes ;; 6711238106Sdes esac 6712238106Sdes ;; 6713238106Sdes 6714238106Sdes sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) 6715238106Sdes _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' 6716238106Sdes _LT_TAGVAR(archive_cmds_need_lc, $1)=no 6717238106Sdes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 6718238106Sdes runpath_var='LD_RUN_PATH' 6719238106Sdes 6720238106Sdes case $cc_basename in 6721238106Sdes CC*) 6722238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 6723238106Sdes _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 6724238106Sdes ;; 6725238106Sdes *) 6726238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 6727238106Sdes _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 6728238106Sdes ;; 6729238106Sdes esac 6730238106Sdes ;; 6731238106Sdes 6732238106Sdes sysv5* | sco3.2v5* | sco5v6*) 6733238106Sdes # Note: We can NOT use -z defs as we might desire, because we do not 6734238106Sdes # link with -lc, and that would cause any symbols used from libc to 6735238106Sdes # always be unresolved, which means just about no library would 6736238106Sdes # ever link correctly. If we're not using GNU ld we use -z text 6737238106Sdes # though, which does catch some bad symbols but isn't as heavy-handed 6738238106Sdes # as -z defs. 6739238106Sdes _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' 6740238106Sdes _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs' 6741238106Sdes _LT_TAGVAR(archive_cmds_need_lc, $1)=no 6742238106Sdes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 6743238106Sdes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir' 6744238106Sdes _LT_TAGVAR(hardcode_libdir_separator, $1)=':' 6745238106Sdes _LT_TAGVAR(link_all_deplibs, $1)=yes 6746238106Sdes _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' 6747238106Sdes runpath_var='LD_RUN_PATH' 6748238106Sdes 6749238106Sdes case $cc_basename in 6750238106Sdes CC*) 6751238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 6752238106Sdes _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 6753238106Sdes _LT_TAGVAR(old_archive_cmds, $1)='$CC -Tprelink_objects $oldobjs~ 6754238106Sdes '"$_LT_TAGVAR(old_archive_cmds, $1)" 6755238106Sdes _LT_TAGVAR(reload_cmds, $1)='$CC -Tprelink_objects $reload_objs~ 6756238106Sdes '"$_LT_TAGVAR(reload_cmds, $1)" 6757238106Sdes ;; 6758238106Sdes *) 6759238106Sdes _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 6760238106Sdes _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 6761238106Sdes ;; 6762238106Sdes esac 6763238106Sdes ;; 6764238106Sdes 6765238106Sdes tandem*) 6766238106Sdes case $cc_basename in 6767238106Sdes NCC*) 6768238106Sdes # NonStop-UX NCC 3.20 6769238106Sdes # FIXME: insert proper C++ library support 6770238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 6771238106Sdes ;; 6772238106Sdes *) 6773238106Sdes # FIXME: insert proper C++ library support 6774238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 6775238106Sdes ;; 6776238106Sdes esac 6777238106Sdes ;; 6778238106Sdes 6779238106Sdes vxworks*) 6780238106Sdes # FIXME: insert proper C++ library support 6781238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 6782238106Sdes ;; 6783238106Sdes 6784238106Sdes *) 6785238106Sdes # FIXME: insert proper C++ library support 6786238106Sdes _LT_TAGVAR(ld_shlibs, $1)=no 6787238106Sdes ;; 6788238106Sdes esac 6789238106Sdes 6790238106Sdes AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) 6791238106Sdes test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no 6792238106Sdes 6793238106Sdes _LT_TAGVAR(GCC, $1)="$GXX" 6794238106Sdes _LT_TAGVAR(LD, $1)="$LD" 6795238106Sdes 6796238106Sdes ## CAVEAT EMPTOR: 6797238106Sdes ## There is no encapsulation within the following macros, do not change 6798238106Sdes ## the running order or otherwise move them around unless you know exactly 6799238106Sdes ## what you are doing... 6800238106Sdes _LT_SYS_HIDDEN_LIBDEPS($1) 6801238106Sdes _LT_COMPILER_PIC($1) 6802238106Sdes _LT_COMPILER_C_O($1) 6803238106Sdes _LT_COMPILER_FILE_LOCKS($1) 6804238106Sdes _LT_LINKER_SHLIBS($1) 6805238106Sdes _LT_SYS_DYNAMIC_LINKER($1) 6806238106Sdes _LT_LINKER_HARDCODE_LIBPATH($1) 6807238106Sdes 6808238106Sdes _LT_CONFIG($1) 6809238106Sdes fi # test -n "$compiler" 6810238106Sdes 6811238106Sdes CC=$lt_save_CC 6812238106Sdes CFLAGS=$lt_save_CFLAGS 6813238106Sdes LDCXX=$LD 6814238106Sdes LD=$lt_save_LD 6815238106Sdes GCC=$lt_save_GCC 6816238106Sdes with_gnu_ld=$lt_save_with_gnu_ld 6817238106Sdes lt_cv_path_LDCXX=$lt_cv_path_LD 6818238106Sdes lt_cv_path_LD=$lt_save_path_LD 6819238106Sdes lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld 6820238106Sdes lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld 6821238106Sdesfi # test "$_lt_caught_CXX_error" != yes 6822238106Sdes 6823238106SdesAC_LANG_POP 6824238106Sdes])# _LT_LANG_CXX_CONFIG 6825238106Sdes 6826238106Sdes 6827238106Sdes# _LT_FUNC_STRIPNAME_CNF 6828238106Sdes# ---------------------- 6829238106Sdes# func_stripname_cnf prefix suffix name 6830238106Sdes# strip PREFIX and SUFFIX off of NAME. 6831238106Sdes# PREFIX and SUFFIX must not contain globbing or regex special 6832238106Sdes# characters, hashes, percent signs, but SUFFIX may contain a leading 6833238106Sdes# dot (in which case that matches only a dot). 6834238106Sdes# 6835238106Sdes# This function is identical to the (non-XSI) version of func_stripname, 6836238106Sdes# except this one can be used by m4 code that may be executed by configure, 6837238106Sdes# rather than the libtool script. 6838238106Sdesm4_defun([_LT_FUNC_STRIPNAME_CNF],[dnl 6839238106SdesAC_REQUIRE([_LT_DECL_SED]) 6840238106SdesAC_REQUIRE([_LT_PROG_ECHO_BACKSLASH]) 6841238106Sdesfunc_stripname_cnf () 6842238106Sdes{ 6843238106Sdes case ${2} in 6844238106Sdes .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;; 6845238106Sdes *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;; 6846238106Sdes esac 6847238106Sdes} # func_stripname_cnf 6848238106Sdes])# _LT_FUNC_STRIPNAME_CNF 6849238106Sdes 6850238106Sdes# _LT_SYS_HIDDEN_LIBDEPS([TAGNAME]) 6851238106Sdes# --------------------------------- 6852238106Sdes# Figure out "hidden" library dependencies from verbose 6853238106Sdes# compiler output when linking a shared library. 6854238106Sdes# Parse the compiler output and extract the necessary 6855238106Sdes# objects, libraries and library flags. 6856238106Sdesm4_defun([_LT_SYS_HIDDEN_LIBDEPS], 6857238106Sdes[m4_require([_LT_FILEUTILS_DEFAULTS])dnl 6858238106SdesAC_REQUIRE([_LT_FUNC_STRIPNAME_CNF])dnl 6859238106Sdes# Dependencies to place before and after the object being linked: 6860238106Sdes_LT_TAGVAR(predep_objects, $1)= 6861238106Sdes_LT_TAGVAR(postdep_objects, $1)= 6862238106Sdes_LT_TAGVAR(predeps, $1)= 6863238106Sdes_LT_TAGVAR(postdeps, $1)= 6864238106Sdes_LT_TAGVAR(compiler_lib_search_path, $1)= 6865238106Sdes 6866238106Sdesdnl we can't use the lt_simple_compile_test_code here, 6867238106Sdesdnl because it contains code intended for an executable, 6868238106Sdesdnl not a library. It's possible we should let each 6869238106Sdesdnl tag define a new lt_????_link_test_code variable, 6870238106Sdesdnl but it's only used here... 6871238106Sdesm4_if([$1], [], [cat > conftest.$ac_ext <<_LT_EOF 6872238106Sdesint a; 6873238106Sdesvoid foo (void) { a = 0; } 6874238106Sdes_LT_EOF 6875238106Sdes], [$1], [CXX], [cat > conftest.$ac_ext <<_LT_EOF 6876238106Sdesclass Foo 6877238106Sdes{ 6878238106Sdespublic: 6879238106Sdes Foo (void) { a = 0; } 6880238106Sdesprivate: 6881238106Sdes int a; 6882238106Sdes}; 6883238106Sdes_LT_EOF 6884238106Sdes], [$1], [F77], [cat > conftest.$ac_ext <<_LT_EOF 6885238106Sdes subroutine foo 6886238106Sdes implicit none 6887238106Sdes integer*4 a 6888238106Sdes a=0 6889238106Sdes return 6890238106Sdes end 6891238106Sdes_LT_EOF 6892238106Sdes], [$1], [FC], [cat > conftest.$ac_ext <<_LT_EOF 6893238106Sdes subroutine foo 6894238106Sdes implicit none 6895238106Sdes integer a 6896238106Sdes a=0 6897238106Sdes return 6898238106Sdes end 6899238106Sdes_LT_EOF 6900238106Sdes], [$1], [GCJ], [cat > conftest.$ac_ext <<_LT_EOF 6901238106Sdespublic class foo { 6902238106Sdes private int a; 6903238106Sdes public void bar (void) { 6904238106Sdes a = 0; 6905238106Sdes } 6906238106Sdes}; 6907238106Sdes_LT_EOF 6908238106Sdes]) 6909238106Sdes 6910238106Sdes_lt_libdeps_save_CFLAGS=$CFLAGS 6911238106Sdescase "$CC $CFLAGS " in #( 6912238106Sdes*\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;; 6913238106Sdes*\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;; 6914238106Sdesesac 6915238106Sdes 6916238106Sdesdnl Parse the compiler output and extract the necessary 6917238106Sdesdnl objects, libraries and library flags. 6918238106Sdesif AC_TRY_EVAL(ac_compile); then 6919238106Sdes # Parse the compiler output and extract the necessary 6920238106Sdes # objects, libraries and library flags. 6921238106Sdes 6922238106Sdes # Sentinel used to keep track of whether or not we are before 6923238106Sdes # the conftest object file. 6924238106Sdes pre_test_object_deps_done=no 6925238106Sdes 6926238106Sdes for p in `eval "$output_verbose_link_cmd"`; do 6927238106Sdes case ${prev}${p} in 6928238106Sdes 6929238106Sdes -L* | -R* | -l*) 6930238106Sdes # Some compilers place space between "-{L,R}" and the path. 6931238106Sdes # Remove the space. 6932238106Sdes if test $p = "-L" || 6933238106Sdes test $p = "-R"; then 6934238106Sdes prev=$p 6935238106Sdes continue 6936238106Sdes fi 6937238106Sdes 6938238106Sdes # Expand the sysroot to ease extracting the directories later. 6939238106Sdes if test -z "$prev"; then 6940238106Sdes case $p in 6941238106Sdes -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;; 6942238106Sdes -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;; 6943238106Sdes -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;; 6944238106Sdes esac 6945238106Sdes fi 6946238106Sdes case $p in 6947238106Sdes =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;; 6948238106Sdes esac 6949238106Sdes if test "$pre_test_object_deps_done" = no; then 6950238106Sdes case ${prev} in 6951238106Sdes -L | -R) 6952238106Sdes # Internal compiler library paths should come after those 6953238106Sdes # provided the user. The postdeps already come after the 6954238106Sdes # user supplied libs so there is no need to process them. 6955238106Sdes if test -z "$_LT_TAGVAR(compiler_lib_search_path, $1)"; then 6956238106Sdes _LT_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}" 6957238106Sdes else 6958238106Sdes _LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}" 6959238106Sdes fi 6960238106Sdes ;; 6961238106Sdes # The "-l" case would never come before the object being 6962238106Sdes # linked, so don't bother handling this case. 6963238106Sdes esac 6964238106Sdes else 6965238106Sdes if test -z "$_LT_TAGVAR(postdeps, $1)"; then 6966238106Sdes _LT_TAGVAR(postdeps, $1)="${prev}${p}" 6967238106Sdes else 6968238106Sdes _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} ${prev}${p}" 6969238106Sdes fi 6970238106Sdes fi 6971238106Sdes prev= 6972238106Sdes ;; 6973238106Sdes 6974238106Sdes *.lto.$objext) ;; # Ignore GCC LTO objects 6975238106Sdes *.$objext) 6976238106Sdes # This assumes that the test object file only shows up 6977238106Sdes # once in the compiler output. 6978238106Sdes if test "$p" = "conftest.$objext"; then 6979238106Sdes pre_test_object_deps_done=yes 6980238106Sdes continue 6981238106Sdes fi 6982238106Sdes 6983238106Sdes if test "$pre_test_object_deps_done" = no; then 6984238106Sdes if test -z "$_LT_TAGVAR(predep_objects, $1)"; then 6985238106Sdes _LT_TAGVAR(predep_objects, $1)="$p" 6986238106Sdes else 6987238106Sdes _LT_TAGVAR(predep_objects, $1)="$_LT_TAGVAR(predep_objects, $1) $p" 6988238106Sdes fi 6989238106Sdes else 6990238106Sdes if test -z "$_LT_TAGVAR(postdep_objects, $1)"; then 6991238106Sdes _LT_TAGVAR(postdep_objects, $1)="$p" 6992238106Sdes else 6993238106Sdes _LT_TAGVAR(postdep_objects, $1)="$_LT_TAGVAR(postdep_objects, $1) $p" 6994238106Sdes fi 6995238106Sdes fi 6996238106Sdes ;; 6997238106Sdes 6998238106Sdes *) ;; # Ignore the rest. 6999238106Sdes 7000238106Sdes esac 7001238106Sdes done 7002238106Sdes 7003238106Sdes # Clean up. 7004238106Sdes rm -f a.out a.exe 7005238106Sdeselse 7006238106Sdes echo "libtool.m4: error: problem compiling $1 test program" 7007238106Sdesfi 7008238106Sdes 7009238106Sdes$RM -f confest.$objext 7010238106SdesCFLAGS=$_lt_libdeps_save_CFLAGS 7011238106Sdes 7012238106Sdes# PORTME: override above test on systems where it is broken 7013238106Sdesm4_if([$1], [CXX], 7014238106Sdes[case $host_os in 7015238106Sdesinterix[[3-9]]*) 7016238106Sdes # Interix 3.5 installs completely hosed .la files for C++, so rather than 7017238106Sdes # hack all around it, let's just trust "g++" to DTRT. 7018238106Sdes _LT_TAGVAR(predep_objects,$1)= 7019238106Sdes _LT_TAGVAR(postdep_objects,$1)= 7020238106Sdes _LT_TAGVAR(postdeps,$1)= 7021238106Sdes ;; 7022238106Sdes 7023238106Sdeslinux*) 7024238106Sdes case `$CC -V 2>&1 | sed 5q` in 7025238106Sdes *Sun\ C*) 7026238106Sdes # Sun C++ 5.9 7027238106Sdes 7028238106Sdes # The more standards-conforming stlport4 library is 7029238106Sdes # incompatible with the Cstd library. Avoid specifying 7030238106Sdes # it if it's in CXXFLAGS. Ignore libCrun as 7031238106Sdes # -library=stlport4 depends on it. 7032238106Sdes case " $CXX $CXXFLAGS " in 7033238106Sdes *" -library=stlport4 "*) 7034238106Sdes solaris_use_stlport4=yes 7035238106Sdes ;; 7036238106Sdes esac 7037238106Sdes 7038238106Sdes if test "$solaris_use_stlport4" != yes; then 7039238106Sdes _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun' 7040238106Sdes fi 7041238106Sdes ;; 7042238106Sdes esac 7043238106Sdes ;; 7044238106Sdes 7045238106Sdessolaris*) 7046238106Sdes case $cc_basename in 7047238106Sdes CC* | sunCC*) 7048238106Sdes # The more standards-conforming stlport4 library is 7049238106Sdes # incompatible with the Cstd library. Avoid specifying 7050238106Sdes # it if it's in CXXFLAGS. Ignore libCrun as 7051238106Sdes # -library=stlport4 depends on it. 7052238106Sdes case " $CXX $CXXFLAGS " in 7053238106Sdes *" -library=stlport4 "*) 7054238106Sdes solaris_use_stlport4=yes 7055238106Sdes ;; 7056238106Sdes esac 7057238106Sdes 7058238106Sdes # Adding this requires a known-good setup of shared libraries for 7059238106Sdes # Sun compiler versions before 5.6, else PIC objects from an old 7060238106Sdes # archive will be linked into the output, leading to subtle bugs. 7061238106Sdes if test "$solaris_use_stlport4" != yes; then 7062238106Sdes _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun' 7063238106Sdes fi 7064238106Sdes ;; 7065238106Sdes esac 7066238106Sdes ;; 7067238106Sdesesac 7068238106Sdes]) 7069238106Sdes 7070238106Sdescase " $_LT_TAGVAR(postdeps, $1) " in 7071238106Sdes*" -lc "*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;; 7072238106Sdesesac 7073238106Sdes _LT_TAGVAR(compiler_lib_search_dirs, $1)= 7074238106Sdesif test -n "${_LT_TAGVAR(compiler_lib_search_path, $1)}"; then 7075238106Sdes _LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | ${SED} -e 's! -L! !g' -e 's!^ !!'` 7076238106Sdesfi 7077238106Sdes_LT_TAGDECL([], [compiler_lib_search_dirs], [1], 7078238106Sdes [The directories searched by this compiler when creating a shared library]) 7079238106Sdes_LT_TAGDECL([], [predep_objects], [1], 7080238106Sdes [Dependencies to place before and after the objects being linked to 7081238106Sdes create a shared library]) 7082238106Sdes_LT_TAGDECL([], [postdep_objects], [1]) 7083238106Sdes_LT_TAGDECL([], [predeps], [1]) 7084238106Sdes_LT_TAGDECL([], [postdeps], [1]) 7085238106Sdes_LT_TAGDECL([], [compiler_lib_search_path], [1], 7086238106Sdes [The library search path used internally by the compiler when linking 7087238106Sdes a shared library]) 7088238106Sdes])# _LT_SYS_HIDDEN_LIBDEPS 7089238106Sdes 7090238106Sdes 7091238106Sdes# _LT_LANG_F77_CONFIG([TAG]) 7092238106Sdes# -------------------------- 7093238106Sdes# Ensure that the configuration variables for a Fortran 77 compiler are 7094238106Sdes# suitably defined. These variables are subsequently used by _LT_CONFIG 7095238106Sdes# to write the compiler configuration to `libtool'. 7096238106Sdesm4_defun([_LT_LANG_F77_CONFIG], 7097238106Sdes[AC_LANG_PUSH(Fortran 77) 7098238106Sdesif test -z "$F77" || test "X$F77" = "Xno"; then 7099238106Sdes _lt_disable_F77=yes 7100238106Sdesfi 7101238106Sdes 7102238106Sdes_LT_TAGVAR(archive_cmds_need_lc, $1)=no 7103238106Sdes_LT_TAGVAR(allow_undefined_flag, $1)= 7104238106Sdes_LT_TAGVAR(always_export_symbols, $1)=no 7105238106Sdes_LT_TAGVAR(archive_expsym_cmds, $1)= 7106238106Sdes_LT_TAGVAR(export_dynamic_flag_spec, $1)= 7107238106Sdes_LT_TAGVAR(hardcode_direct, $1)=no 7108238106Sdes_LT_TAGVAR(hardcode_direct_absolute, $1)=no 7109238106Sdes_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 7110238106Sdes_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= 7111238106Sdes_LT_TAGVAR(hardcode_libdir_separator, $1)= 7112238106Sdes_LT_TAGVAR(hardcode_minus_L, $1)=no 7113238106Sdes_LT_TAGVAR(hardcode_automatic, $1)=no 7114238106Sdes_LT_TAGVAR(inherit_rpath, $1)=no 7115238106Sdes_LT_TAGVAR(module_cmds, $1)= 7116238106Sdes_LT_TAGVAR(module_expsym_cmds, $1)= 7117238106Sdes_LT_TAGVAR(link_all_deplibs, $1)=unknown 7118238106Sdes_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 7119238106Sdes_LT_TAGVAR(reload_flag, $1)=$reload_flag 7120238106Sdes_LT_TAGVAR(reload_cmds, $1)=$reload_cmds 7121238106Sdes_LT_TAGVAR(no_undefined_flag, $1)= 7122238106Sdes_LT_TAGVAR(whole_archive_flag_spec, $1)= 7123238106Sdes_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no 7124238106Sdes 7125238106Sdes# Source file extension for f77 test sources. 7126238106Sdesac_ext=f 7127238106Sdes 7128238106Sdes# Object file extension for compiled f77 test sources. 7129238106Sdesobjext=o 7130238106Sdes_LT_TAGVAR(objext, $1)=$objext 7131238106Sdes 7132238106Sdes# No sense in running all these tests if we already determined that 7133238106Sdes# the F77 compiler isn't working. Some variables (like enable_shared) 7134238106Sdes# are currently assumed to apply to all compilers on this platform, 7135238106Sdes# and will be corrupted by setting them based on a non-working compiler. 7136238106Sdesif test "$_lt_disable_F77" != yes; then 7137238106Sdes # Code to be used in simple compile tests 7138238106Sdes lt_simple_compile_test_code="\ 7139238106Sdes subroutine t 7140238106Sdes return 7141238106Sdes end 7142238106Sdes" 7143238106Sdes 7144238106Sdes # Code to be used in simple link tests 7145238106Sdes lt_simple_link_test_code="\ 7146238106Sdes program t 7147238106Sdes end 7148238106Sdes" 7149238106Sdes 7150238106Sdes # ltmain only uses $CC for tagged configurations so make sure $CC is set. 7151238106Sdes _LT_TAG_COMPILER 7152238106Sdes 7153238106Sdes # save warnings/boilerplate of simple test code 7154238106Sdes _LT_COMPILER_BOILERPLATE 7155238106Sdes _LT_LINKER_BOILERPLATE 7156238106Sdes 7157238106Sdes # Allow CC to be a program name with arguments. 7158238106Sdes lt_save_CC="$CC" 7159238106Sdes lt_save_GCC=$GCC 7160238106Sdes lt_save_CFLAGS=$CFLAGS 7161238106Sdes CC=${F77-"f77"} 7162238106Sdes CFLAGS=$FFLAGS 7163238106Sdes compiler=$CC 7164238106Sdes _LT_TAGVAR(compiler, $1)=$CC 7165238106Sdes _LT_CC_BASENAME([$compiler]) 7166238106Sdes GCC=$G77 7167238106Sdes if test -n "$compiler"; then 7168238106Sdes AC_MSG_CHECKING([if libtool supports shared libraries]) 7169238106Sdes AC_MSG_RESULT([$can_build_shared]) 7170238106Sdes 7171238106Sdes AC_MSG_CHECKING([whether to build shared libraries]) 7172238106Sdes test "$can_build_shared" = "no" && enable_shared=no 7173238106Sdes 7174238106Sdes # On AIX, shared libraries and static libraries use the same namespace, and 7175238106Sdes # are all built from PIC. 7176238106Sdes case $host_os in 7177238106Sdes aix3*) 7178238106Sdes test "$enable_shared" = yes && enable_static=no 7179238106Sdes if test -n "$RANLIB"; then 7180238106Sdes archive_cmds="$archive_cmds~\$RANLIB \$lib" 7181238106Sdes postinstall_cmds='$RANLIB $lib' 7182238106Sdes fi 7183238106Sdes ;; 7184238106Sdes aix[[4-9]]*) 7185238106Sdes if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then 7186238106Sdes test "$enable_shared" = yes && enable_static=no 7187238106Sdes fi 7188238106Sdes ;; 7189238106Sdes esac 7190238106Sdes AC_MSG_RESULT([$enable_shared]) 7191238106Sdes 7192238106Sdes AC_MSG_CHECKING([whether to build static libraries]) 7193238106Sdes # Make sure either enable_shared or enable_static is yes. 7194238106Sdes test "$enable_shared" = yes || enable_static=yes 7195238106Sdes AC_MSG_RESULT([$enable_static]) 7196238106Sdes 7197238106Sdes _LT_TAGVAR(GCC, $1)="$G77" 7198238106Sdes _LT_TAGVAR(LD, $1)="$LD" 7199238106Sdes 7200238106Sdes ## CAVEAT EMPTOR: 7201238106Sdes ## There is no encapsulation within the following macros, do not change 7202238106Sdes ## the running order or otherwise move them around unless you know exactly 7203238106Sdes ## what you are doing... 7204238106Sdes _LT_COMPILER_PIC($1) 7205238106Sdes _LT_COMPILER_C_O($1) 7206238106Sdes _LT_COMPILER_FILE_LOCKS($1) 7207238106Sdes _LT_LINKER_SHLIBS($1) 7208238106Sdes _LT_SYS_DYNAMIC_LINKER($1) 7209238106Sdes _LT_LINKER_HARDCODE_LIBPATH($1) 7210238106Sdes 7211238106Sdes _LT_CONFIG($1) 7212238106Sdes fi # test -n "$compiler" 7213238106Sdes 7214238106Sdes GCC=$lt_save_GCC 7215238106Sdes CC="$lt_save_CC" 7216238106Sdes CFLAGS="$lt_save_CFLAGS" 7217238106Sdesfi # test "$_lt_disable_F77" != yes 7218238106Sdes 7219238106SdesAC_LANG_POP 7220238106Sdes])# _LT_LANG_F77_CONFIG 7221238106Sdes 7222238106Sdes 7223238106Sdes# _LT_LANG_FC_CONFIG([TAG]) 7224238106Sdes# ------------------------- 7225238106Sdes# Ensure that the configuration variables for a Fortran compiler are 7226238106Sdes# suitably defined. These variables are subsequently used by _LT_CONFIG 7227238106Sdes# to write the compiler configuration to `libtool'. 7228238106Sdesm4_defun([_LT_LANG_FC_CONFIG], 7229238106Sdes[AC_LANG_PUSH(Fortran) 7230238106Sdes 7231238106Sdesif test -z "$FC" || test "X$FC" = "Xno"; then 7232238106Sdes _lt_disable_FC=yes 7233238106Sdesfi 7234238106Sdes 7235238106Sdes_LT_TAGVAR(archive_cmds_need_lc, $1)=no 7236238106Sdes_LT_TAGVAR(allow_undefined_flag, $1)= 7237238106Sdes_LT_TAGVAR(always_export_symbols, $1)=no 7238238106Sdes_LT_TAGVAR(archive_expsym_cmds, $1)= 7239238106Sdes_LT_TAGVAR(export_dynamic_flag_spec, $1)= 7240238106Sdes_LT_TAGVAR(hardcode_direct, $1)=no 7241238106Sdes_LT_TAGVAR(hardcode_direct_absolute, $1)=no 7242238106Sdes_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 7243238106Sdes_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= 7244238106Sdes_LT_TAGVAR(hardcode_libdir_separator, $1)= 7245238106Sdes_LT_TAGVAR(hardcode_minus_L, $1)=no 7246238106Sdes_LT_TAGVAR(hardcode_automatic, $1)=no 7247238106Sdes_LT_TAGVAR(inherit_rpath, $1)=no 7248238106Sdes_LT_TAGVAR(module_cmds, $1)= 7249238106Sdes_LT_TAGVAR(module_expsym_cmds, $1)= 7250238106Sdes_LT_TAGVAR(link_all_deplibs, $1)=unknown 7251238106Sdes_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 7252238106Sdes_LT_TAGVAR(reload_flag, $1)=$reload_flag 7253238106Sdes_LT_TAGVAR(reload_cmds, $1)=$reload_cmds 7254238106Sdes_LT_TAGVAR(no_undefined_flag, $1)= 7255238106Sdes_LT_TAGVAR(whole_archive_flag_spec, $1)= 7256238106Sdes_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no 7257238106Sdes 7258238106Sdes# Source file extension for fc test sources. 7259238106Sdesac_ext=${ac_fc_srcext-f} 7260238106Sdes 7261238106Sdes# Object file extension for compiled fc test sources. 7262238106Sdesobjext=o 7263238106Sdes_LT_TAGVAR(objext, $1)=$objext 7264238106Sdes 7265238106Sdes# No sense in running all these tests if we already determined that 7266238106Sdes# the FC compiler isn't working. Some variables (like enable_shared) 7267238106Sdes# are currently assumed to apply to all compilers on this platform, 7268238106Sdes# and will be corrupted by setting them based on a non-working compiler. 7269238106Sdesif test "$_lt_disable_FC" != yes; then 7270238106Sdes # Code to be used in simple compile tests 7271238106Sdes lt_simple_compile_test_code="\ 7272238106Sdes subroutine t 7273238106Sdes return 7274238106Sdes end 7275238106Sdes" 7276238106Sdes 7277238106Sdes # Code to be used in simple link tests 7278238106Sdes lt_simple_link_test_code="\ 7279238106Sdes program t 7280238106Sdes end 7281238106Sdes" 7282238106Sdes 7283238106Sdes # ltmain only uses $CC for tagged configurations so make sure $CC is set. 7284238106Sdes _LT_TAG_COMPILER 7285238106Sdes 7286238106Sdes # save warnings/boilerplate of simple test code 7287238106Sdes _LT_COMPILER_BOILERPLATE 7288238106Sdes _LT_LINKER_BOILERPLATE 7289238106Sdes 7290238106Sdes # Allow CC to be a program name with arguments. 7291238106Sdes lt_save_CC="$CC" 7292238106Sdes lt_save_GCC=$GCC 7293238106Sdes lt_save_CFLAGS=$CFLAGS 7294238106Sdes CC=${FC-"f95"} 7295238106Sdes CFLAGS=$FCFLAGS 7296238106Sdes compiler=$CC 7297238106Sdes GCC=$ac_cv_fc_compiler_gnu 7298238106Sdes 7299238106Sdes _LT_TAGVAR(compiler, $1)=$CC 7300238106Sdes _LT_CC_BASENAME([$compiler]) 7301238106Sdes 7302238106Sdes if test -n "$compiler"; then 7303238106Sdes AC_MSG_CHECKING([if libtool supports shared libraries]) 7304238106Sdes AC_MSG_RESULT([$can_build_shared]) 7305238106Sdes 7306238106Sdes AC_MSG_CHECKING([whether to build shared libraries]) 7307238106Sdes test "$can_build_shared" = "no" && enable_shared=no 7308238106Sdes 7309238106Sdes # On AIX, shared libraries and static libraries use the same namespace, and 7310238106Sdes # are all built from PIC. 7311238106Sdes case $host_os in 7312238106Sdes aix3*) 7313238106Sdes test "$enable_shared" = yes && enable_static=no 7314238106Sdes if test -n "$RANLIB"; then 7315238106Sdes archive_cmds="$archive_cmds~\$RANLIB \$lib" 7316238106Sdes postinstall_cmds='$RANLIB $lib' 7317238106Sdes fi 7318238106Sdes ;; 7319238106Sdes aix[[4-9]]*) 7320238106Sdes if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then 7321238106Sdes test "$enable_shared" = yes && enable_static=no 7322238106Sdes fi 7323238106Sdes ;; 7324238106Sdes esac 7325238106Sdes AC_MSG_RESULT([$enable_shared]) 7326238106Sdes 7327238106Sdes AC_MSG_CHECKING([whether to build static libraries]) 7328238106Sdes # Make sure either enable_shared or enable_static is yes. 7329238106Sdes test "$enable_shared" = yes || enable_static=yes 7330238106Sdes AC_MSG_RESULT([$enable_static]) 7331238106Sdes 7332238106Sdes _LT_TAGVAR(GCC, $1)="$ac_cv_fc_compiler_gnu" 7333238106Sdes _LT_TAGVAR(LD, $1)="$LD" 7334238106Sdes 7335238106Sdes ## CAVEAT EMPTOR: 7336238106Sdes ## There is no encapsulation within the following macros, do not change 7337238106Sdes ## the running order or otherwise move them around unless you know exactly 7338238106Sdes ## what you are doing... 7339238106Sdes _LT_SYS_HIDDEN_LIBDEPS($1) 7340238106Sdes _LT_COMPILER_PIC($1) 7341238106Sdes _LT_COMPILER_C_O($1) 7342238106Sdes _LT_COMPILER_FILE_LOCKS($1) 7343238106Sdes _LT_LINKER_SHLIBS($1) 7344238106Sdes _LT_SYS_DYNAMIC_LINKER($1) 7345238106Sdes _LT_LINKER_HARDCODE_LIBPATH($1) 7346238106Sdes 7347238106Sdes _LT_CONFIG($1) 7348238106Sdes fi # test -n "$compiler" 7349238106Sdes 7350238106Sdes GCC=$lt_save_GCC 7351238106Sdes CC=$lt_save_CC 7352238106Sdes CFLAGS=$lt_save_CFLAGS 7353238106Sdesfi # test "$_lt_disable_FC" != yes 7354238106Sdes 7355238106SdesAC_LANG_POP 7356238106Sdes])# _LT_LANG_FC_CONFIG 7357238106Sdes 7358238106Sdes 7359238106Sdes# _LT_LANG_GCJ_CONFIG([TAG]) 7360238106Sdes# -------------------------- 7361238106Sdes# Ensure that the configuration variables for the GNU Java Compiler compiler 7362238106Sdes# are suitably defined. These variables are subsequently used by _LT_CONFIG 7363238106Sdes# to write the compiler configuration to `libtool'. 7364238106Sdesm4_defun([_LT_LANG_GCJ_CONFIG], 7365238106Sdes[AC_REQUIRE([LT_PROG_GCJ])dnl 7366238106SdesAC_LANG_SAVE 7367238106Sdes 7368238106Sdes# Source file extension for Java test sources. 7369238106Sdesac_ext=java 7370238106Sdes 7371238106Sdes# Object file extension for compiled Java test sources. 7372238106Sdesobjext=o 7373238106Sdes_LT_TAGVAR(objext, $1)=$objext 7374238106Sdes 7375238106Sdes# Code to be used in simple compile tests 7376238106Sdeslt_simple_compile_test_code="class foo {}" 7377238106Sdes 7378238106Sdes# Code to be used in simple link tests 7379238106Sdeslt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }' 7380238106Sdes 7381238106Sdes# ltmain only uses $CC for tagged configurations so make sure $CC is set. 7382238106Sdes_LT_TAG_COMPILER 7383238106Sdes 7384238106Sdes# save warnings/boilerplate of simple test code 7385238106Sdes_LT_COMPILER_BOILERPLATE 7386238106Sdes_LT_LINKER_BOILERPLATE 7387238106Sdes 7388238106Sdes# Allow CC to be a program name with arguments. 7389238106Sdeslt_save_CC=$CC 7390238106Sdeslt_save_CFLAGS=$CFLAGS 7391238106Sdeslt_save_GCC=$GCC 7392238106SdesGCC=yes 7393238106SdesCC=${GCJ-"gcj"} 7394238106SdesCFLAGS=$GCJFLAGS 7395238106Sdescompiler=$CC 7396238106Sdes_LT_TAGVAR(compiler, $1)=$CC 7397238106Sdes_LT_TAGVAR(LD, $1)="$LD" 7398238106Sdes_LT_CC_BASENAME([$compiler]) 7399238106Sdes 7400238106Sdes# GCJ did not exist at the time GCC didn't implicitly link libc in. 7401238106Sdes_LT_TAGVAR(archive_cmds_need_lc, $1)=no 7402238106Sdes 7403238106Sdes_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 7404238106Sdes_LT_TAGVAR(reload_flag, $1)=$reload_flag 7405238106Sdes_LT_TAGVAR(reload_cmds, $1)=$reload_cmds 7406238106Sdes 7407238106Sdesif test -n "$compiler"; then 7408238106Sdes _LT_COMPILER_NO_RTTI($1) 7409238106Sdes _LT_COMPILER_PIC($1) 7410238106Sdes _LT_COMPILER_C_O($1) 7411238106Sdes _LT_COMPILER_FILE_LOCKS($1) 7412238106Sdes _LT_LINKER_SHLIBS($1) 7413238106Sdes _LT_LINKER_HARDCODE_LIBPATH($1) 7414238106Sdes 7415238106Sdes _LT_CONFIG($1) 7416238106Sdesfi 7417238106Sdes 7418238106SdesAC_LANG_RESTORE 7419238106Sdes 7420238106SdesGCC=$lt_save_GCC 7421238106SdesCC=$lt_save_CC 7422238106SdesCFLAGS=$lt_save_CFLAGS 7423238106Sdes])# _LT_LANG_GCJ_CONFIG 7424238106Sdes 7425238106Sdes 7426238106Sdes# _LT_LANG_RC_CONFIG([TAG]) 7427238106Sdes# ------------------------- 7428238106Sdes# Ensure that the configuration variables for the Windows resource compiler 7429238106Sdes# are suitably defined. These variables are subsequently used by _LT_CONFIG 7430238106Sdes# to write the compiler configuration to `libtool'. 7431238106Sdesm4_defun([_LT_LANG_RC_CONFIG], 7432238106Sdes[AC_REQUIRE([LT_PROG_RC])dnl 7433238106SdesAC_LANG_SAVE 7434238106Sdes 7435238106Sdes# Source file extension for RC test sources. 7436238106Sdesac_ext=rc 7437238106Sdes 7438238106Sdes# Object file extension for compiled RC test sources. 7439238106Sdesobjext=o 7440238106Sdes_LT_TAGVAR(objext, $1)=$objext 7441238106Sdes 7442238106Sdes# Code to be used in simple compile tests 7443238106Sdeslt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }' 7444238106Sdes 7445238106Sdes# Code to be used in simple link tests 7446238106Sdeslt_simple_link_test_code="$lt_simple_compile_test_code" 7447238106Sdes 7448238106Sdes# ltmain only uses $CC for tagged configurations so make sure $CC is set. 7449238106Sdes_LT_TAG_COMPILER 7450238106Sdes 7451238106Sdes# save warnings/boilerplate of simple test code 7452238106Sdes_LT_COMPILER_BOILERPLATE 7453238106Sdes_LT_LINKER_BOILERPLATE 7454238106Sdes 7455238106Sdes# Allow CC to be a program name with arguments. 7456238106Sdeslt_save_CC="$CC" 7457238106Sdeslt_save_CFLAGS=$CFLAGS 7458238106Sdeslt_save_GCC=$GCC 7459238106SdesGCC= 7460238106SdesCC=${RC-"windres"} 7461238106SdesCFLAGS= 7462238106Sdescompiler=$CC 7463238106Sdes_LT_TAGVAR(compiler, $1)=$CC 7464238106Sdes_LT_CC_BASENAME([$compiler]) 7465238106Sdes_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes 7466238106Sdes 7467238106Sdesif test -n "$compiler"; then 7468238106Sdes : 7469238106Sdes _LT_CONFIG($1) 7470238106Sdesfi 7471238106Sdes 7472238106SdesGCC=$lt_save_GCC 7473238106SdesAC_LANG_RESTORE 7474238106SdesCC=$lt_save_CC 7475238106SdesCFLAGS=$lt_save_CFLAGS 7476238106Sdes])# _LT_LANG_RC_CONFIG 7477238106Sdes 7478238106Sdes 7479238106Sdes# LT_PROG_GCJ 7480238106Sdes# ----------- 7481238106SdesAC_DEFUN([LT_PROG_GCJ], 7482238106Sdes[m4_ifdef([AC_PROG_GCJ], [AC_PROG_GCJ], 7483238106Sdes [m4_ifdef([A][M_PROG_GCJ], [A][M_PROG_GCJ], 7484238106Sdes [AC_CHECK_TOOL(GCJ, gcj,) 7485238106Sdes test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2" 7486238106Sdes AC_SUBST(GCJFLAGS)])])[]dnl 7487238106Sdes]) 7488238106Sdes 7489238106Sdes# Old name: 7490238106SdesAU_ALIAS([LT_AC_PROG_GCJ], [LT_PROG_GCJ]) 7491238106Sdesdnl aclocal-1.4 backwards compatibility: 7492238106Sdesdnl AC_DEFUN([LT_AC_PROG_GCJ], []) 7493238106Sdes 7494238106Sdes 7495238106Sdes# LT_PROG_RC 7496238106Sdes# ---------- 7497238106SdesAC_DEFUN([LT_PROG_RC], 7498238106Sdes[AC_CHECK_TOOL(RC, windres,) 7499238106Sdes]) 7500238106Sdes 7501238106Sdes# Old name: 7502238106SdesAU_ALIAS([LT_AC_PROG_RC], [LT_PROG_RC]) 7503238106Sdesdnl aclocal-1.4 backwards compatibility: 7504238106Sdesdnl AC_DEFUN([LT_AC_PROG_RC], []) 7505238106Sdes 7506238106Sdes 7507238106Sdes# _LT_DECL_EGREP 7508238106Sdes# -------------- 7509238106Sdes# If we don't have a new enough Autoconf to choose the best grep 7510238106Sdes# available, choose the one first in the user's PATH. 7511238106Sdesm4_defun([_LT_DECL_EGREP], 7512238106Sdes[AC_REQUIRE([AC_PROG_EGREP])dnl 7513238106SdesAC_REQUIRE([AC_PROG_FGREP])dnl 7514238106Sdestest -z "$GREP" && GREP=grep 7515238106Sdes_LT_DECL([], [GREP], [1], [A grep program that handles long lines]) 7516238106Sdes_LT_DECL([], [EGREP], [1], [An ERE matcher]) 7517238106Sdes_LT_DECL([], [FGREP], [1], [A literal string matcher]) 7518238106Sdesdnl Non-bleeding-edge autoconf doesn't subst GREP, so do it here too 7519238106SdesAC_SUBST([GREP]) 7520238106Sdes]) 7521238106Sdes 7522238106Sdes 7523238106Sdes# _LT_DECL_OBJDUMP 7524238106Sdes# -------------- 7525238106Sdes# If we don't have a new enough Autoconf to choose the best objdump 7526238106Sdes# available, choose the one first in the user's PATH. 7527238106Sdesm4_defun([_LT_DECL_OBJDUMP], 7528238106Sdes[AC_CHECK_TOOL(OBJDUMP, objdump, false) 7529238106Sdestest -z "$OBJDUMP" && OBJDUMP=objdump 7530238106Sdes_LT_DECL([], [OBJDUMP], [1], [An object symbol dumper]) 7531238106SdesAC_SUBST([OBJDUMP]) 7532238106Sdes]) 7533238106Sdes 7534238106Sdes# _LT_DECL_DLLTOOL 7535238106Sdes# ---------------- 7536238106Sdes# Ensure DLLTOOL variable is set. 7537238106Sdesm4_defun([_LT_DECL_DLLTOOL], 7538238106Sdes[AC_CHECK_TOOL(DLLTOOL, dlltool, false) 7539238106Sdestest -z "$DLLTOOL" && DLLTOOL=dlltool 7540238106Sdes_LT_DECL([], [DLLTOOL], [1], [DLL creation program]) 7541238106SdesAC_SUBST([DLLTOOL]) 7542238106Sdes]) 7543238106Sdes 7544238106Sdes# _LT_DECL_SED 7545238106Sdes# ------------ 7546238106Sdes# Check for a fully-functional sed program, that truncates 7547238106Sdes# as few characters as possible. Prefer GNU sed if found. 7548238106Sdesm4_defun([_LT_DECL_SED], 7549238106Sdes[AC_PROG_SED 7550238106Sdestest -z "$SED" && SED=sed 7551238106SdesXsed="$SED -e 1s/^X//" 7552238106Sdes_LT_DECL([], [SED], [1], [A sed program that does not truncate output]) 7553238106Sdes_LT_DECL([], [Xsed], ["\$SED -e 1s/^X//"], 7554238106Sdes [Sed that helps us avoid accidentally triggering echo(1) options like -n]) 7555238106Sdes])# _LT_DECL_SED 7556238106Sdes 7557238106Sdesm4_ifndef([AC_PROG_SED], [ 7558238106Sdes# NOTE: This macro has been submitted for inclusion into # 7559238106Sdes# GNU Autoconf as AC_PROG_SED. When it is available in # 7560238106Sdes# a released version of Autoconf we should remove this # 7561238106Sdes# macro and use it instead. # 7562238106Sdes 7563238106Sdesm4_defun([AC_PROG_SED], 7564238106Sdes[AC_MSG_CHECKING([for a sed that does not truncate output]) 7565238106SdesAC_CACHE_VAL(lt_cv_path_SED, 7566238106Sdes[# Loop through the user's path and test for sed and gsed. 7567238106Sdes# Then use that list of sed's as ones to test for truncation. 7568238106Sdesas_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7569238106Sdesfor as_dir in $PATH 7570238106Sdesdo 7571238106Sdes IFS=$as_save_IFS 7572238106Sdes test -z "$as_dir" && as_dir=. 7573238106Sdes for lt_ac_prog in sed gsed; do 7574238106Sdes for ac_exec_ext in '' $ac_executable_extensions; do 7575238106Sdes if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then 7576238106Sdes lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext" 7577238106Sdes fi 7578238106Sdes done 7579238106Sdes done 7580238106Sdesdone 7581238106SdesIFS=$as_save_IFS 7582238106Sdeslt_ac_max=0 7583238106Sdeslt_ac_count=0 7584238106Sdes# Add /usr/xpg4/bin/sed as it is typically found on Solaris 7585238106Sdes# along with /bin/sed that truncates output. 7586238106Sdesfor lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do 7587238106Sdes test ! -f $lt_ac_sed && continue 7588238106Sdes cat /dev/null > conftest.in 7589238106Sdes lt_ac_count=0 7590238106Sdes echo $ECHO_N "0123456789$ECHO_C" >conftest.in 7591238106Sdes # Check for GNU sed and select it if it is found. 7592238106Sdes if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then 7593238106Sdes lt_cv_path_SED=$lt_ac_sed 7594238106Sdes break 7595238106Sdes fi 7596238106Sdes while true; do 7597238106Sdes cat conftest.in conftest.in >conftest.tmp 7598238106Sdes mv conftest.tmp conftest.in 7599238106Sdes cp conftest.in conftest.nl 7600238106Sdes echo >>conftest.nl 7601238106Sdes $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break 7602238106Sdes cmp -s conftest.out conftest.nl || break 7603238106Sdes # 10000 chars as input seems more than enough 7604238106Sdes test $lt_ac_count -gt 10 && break 7605238106Sdes lt_ac_count=`expr $lt_ac_count + 1` 7606238106Sdes if test $lt_ac_count -gt $lt_ac_max; then 7607238106Sdes lt_ac_max=$lt_ac_count 7608238106Sdes lt_cv_path_SED=$lt_ac_sed 7609238106Sdes fi 7610238106Sdes done 7611238106Sdesdone 7612238106Sdes]) 7613238106SdesSED=$lt_cv_path_SED 7614238106SdesAC_SUBST([SED]) 7615238106SdesAC_MSG_RESULT([$SED]) 7616238106Sdes])#AC_PROG_SED 7617238106Sdes])#m4_ifndef 7618238106Sdes 7619238106Sdes# Old name: 7620238106SdesAU_ALIAS([LT_AC_PROG_SED], [AC_PROG_SED]) 7621238106Sdesdnl aclocal-1.4 backwards compatibility: 7622238106Sdesdnl AC_DEFUN([LT_AC_PROG_SED], []) 7623238106Sdes 7624238106Sdes 7625238106Sdes# _LT_CHECK_SHELL_FEATURES 7626238106Sdes# ------------------------ 7627238106Sdes# Find out whether the shell is Bourne or XSI compatible, 7628238106Sdes# or has some other useful features. 7629238106Sdesm4_defun([_LT_CHECK_SHELL_FEATURES], 7630238106Sdes[AC_MSG_CHECKING([whether the shell understands some XSI constructs]) 7631238106Sdes# Try some XSI features 7632238106Sdesxsi_shell=no 7633238106Sdes( _lt_dummy="a/b/c" 7634238106Sdes test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \ 7635238106Sdes = c,a/b,b/c, \ 7636238106Sdes && eval 'test $(( 1 + 1 )) -eq 2 \ 7637238106Sdes && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \ 7638238106Sdes && xsi_shell=yes 7639238106SdesAC_MSG_RESULT([$xsi_shell]) 7640238106Sdes_LT_CONFIG_LIBTOOL_INIT([xsi_shell='$xsi_shell']) 7641238106Sdes 7642238106SdesAC_MSG_CHECKING([whether the shell understands "+="]) 7643238106Sdeslt_shell_append=no 7644238106Sdes( foo=bar; set foo baz; eval "$[1]+=\$[2]" && test "$foo" = barbaz ) \ 7645238106Sdes >/dev/null 2>&1 \ 7646238106Sdes && lt_shell_append=yes 7647238106SdesAC_MSG_RESULT([$lt_shell_append]) 7648238106Sdes_LT_CONFIG_LIBTOOL_INIT([lt_shell_append='$lt_shell_append']) 7649238106Sdes 7650238106Sdesif ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then 7651238106Sdes lt_unset=unset 7652238106Sdeselse 7653238106Sdes lt_unset=false 7654238106Sdesfi 7655238106Sdes_LT_DECL([], [lt_unset], [0], [whether the shell understands "unset"])dnl 7656238106Sdes 7657238106Sdes# test EBCDIC or ASCII 7658238106Sdescase `echo X|tr X '\101'` in 7659238106Sdes A) # ASCII based system 7660238106Sdes # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr 7661238106Sdes lt_SP2NL='tr \040 \012' 7662238106Sdes lt_NL2SP='tr \015\012 \040\040' 7663238106Sdes ;; 7664238106Sdes *) # EBCDIC based system 7665238106Sdes lt_SP2NL='tr \100 \n' 7666238106Sdes lt_NL2SP='tr \r\n \100\100' 7667238106Sdes ;; 7668238106Sdesesac 7669238106Sdes_LT_DECL([SP2NL], [lt_SP2NL], [1], [turn spaces into newlines])dnl 7670238106Sdes_LT_DECL([NL2SP], [lt_NL2SP], [1], [turn newlines into spaces])dnl 7671238106Sdes])# _LT_CHECK_SHELL_FEATURES 7672238106Sdes 7673238106Sdes 7674238106Sdes# _LT_PROG_FUNCTION_REPLACE (FUNCNAME, REPLACEMENT-BODY) 7675238106Sdes# ------------------------------------------------------ 7676238106Sdes# In `$cfgfile', look for function FUNCNAME delimited by `^FUNCNAME ()$' and 7677238106Sdes# '^} FUNCNAME ', and replace its body with REPLACEMENT-BODY. 7678238106Sdesm4_defun([_LT_PROG_FUNCTION_REPLACE], 7679238106Sdes[dnl { 7680238106Sdessed -e '/^$1 ()$/,/^} # $1 /c\ 7681238106Sdes$1 ()\ 7682238106Sdes{\ 7683238106Sdesm4_bpatsubsts([$2], [$], [\\], [^\([ ]\)], [\\\1]) 7684238106Sdes} # Extended-shell $1 implementation' "$cfgfile" > $cfgfile.tmp \ 7685238106Sdes && mv -f "$cfgfile.tmp" "$cfgfile" \ 7686238106Sdes || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") 7687238106Sdestest 0 -eq $? || _lt_function_replace_fail=: 7688238106Sdes]) 7689238106Sdes 7690238106Sdes 7691238106Sdes# _LT_PROG_REPLACE_SHELLFNS 7692238106Sdes# ------------------------- 7693238106Sdes# Replace existing portable implementations of several shell functions with 7694238106Sdes# equivalent extended shell implementations where those features are available.. 7695238106Sdesm4_defun([_LT_PROG_REPLACE_SHELLFNS], 7696238106Sdes[if test x"$xsi_shell" = xyes; then 7697238106Sdes _LT_PROG_FUNCTION_REPLACE([func_dirname], [dnl 7698238106Sdes case ${1} in 7699238106Sdes */*) func_dirname_result="${1%/*}${2}" ;; 7700238106Sdes * ) func_dirname_result="${3}" ;; 7701238106Sdes esac]) 7702238106Sdes 7703238106Sdes _LT_PROG_FUNCTION_REPLACE([func_basename], [dnl 7704238106Sdes func_basename_result="${1##*/}"]) 7705238106Sdes 7706238106Sdes _LT_PROG_FUNCTION_REPLACE([func_dirname_and_basename], [dnl 7707238106Sdes case ${1} in 7708238106Sdes */*) func_dirname_result="${1%/*}${2}" ;; 7709238106Sdes * ) func_dirname_result="${3}" ;; 7710238106Sdes esac 7711238106Sdes func_basename_result="${1##*/}"]) 7712238106Sdes 7713238106Sdes _LT_PROG_FUNCTION_REPLACE([func_stripname], [dnl 7714238106Sdes # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are 7715238106Sdes # positional parameters, so assign one to ordinary parameter first. 7716238106Sdes func_stripname_result=${3} 7717238106Sdes func_stripname_result=${func_stripname_result#"${1}"} 7718238106Sdes func_stripname_result=${func_stripname_result%"${2}"}]) 7719238106Sdes 7720238106Sdes _LT_PROG_FUNCTION_REPLACE([func_split_long_opt], [dnl 7721238106Sdes func_split_long_opt_name=${1%%=*} 7722238106Sdes func_split_long_opt_arg=${1#*=}]) 7723238106Sdes 7724238106Sdes _LT_PROG_FUNCTION_REPLACE([func_split_short_opt], [dnl 7725238106Sdes func_split_short_opt_arg=${1#??} 7726238106Sdes func_split_short_opt_name=${1%"$func_split_short_opt_arg"}]) 7727238106Sdes 7728238106Sdes _LT_PROG_FUNCTION_REPLACE([func_lo2o], [dnl 7729238106Sdes case ${1} in 7730238106Sdes *.lo) func_lo2o_result=${1%.lo}.${objext} ;; 7731238106Sdes *) func_lo2o_result=${1} ;; 7732238106Sdes esac]) 7733238106Sdes 7734238106Sdes _LT_PROG_FUNCTION_REPLACE([func_xform], [ func_xform_result=${1%.*}.lo]) 7735238106Sdes 7736238106Sdes _LT_PROG_FUNCTION_REPLACE([func_arith], [ func_arith_result=$(( $[*] ))]) 7737238106Sdes 7738238106Sdes _LT_PROG_FUNCTION_REPLACE([func_len], [ func_len_result=${#1}]) 7739238106Sdesfi 7740238106Sdes 7741238106Sdesif test x"$lt_shell_append" = xyes; then 7742238106Sdes _LT_PROG_FUNCTION_REPLACE([func_append], [ eval "${1}+=\\${2}"]) 7743238106Sdes 7744238106Sdes _LT_PROG_FUNCTION_REPLACE([func_append_quoted], [dnl 7745238106Sdes func_quote_for_eval "${2}" 7746238106Sdesdnl m4 expansion turns \\\\ into \\, and then the shell eval turns that into \ 7747238106Sdes eval "${1}+=\\\\ \\$func_quote_for_eval_result"]) 7748238106Sdes 7749238106Sdes # Save a `func_append' function call where possible by direct use of '+=' 7750238106Sdes sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \ 7751238106Sdes && mv -f "$cfgfile.tmp" "$cfgfile" \ 7752238106Sdes || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") 7753238106Sdes test 0 -eq $? || _lt_function_replace_fail=: 7754238106Sdeselse 7755238106Sdes # Save a `func_append' function call even when '+=' is not available 7756238106Sdes sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \ 7757238106Sdes && mv -f "$cfgfile.tmp" "$cfgfile" \ 7758238106Sdes || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") 7759238106Sdes test 0 -eq $? || _lt_function_replace_fail=: 7760238106Sdesfi 7761238106Sdes 7762238106Sdesif test x"$_lt_function_replace_fail" = x":"; then 7763238106Sdes AC_MSG_WARN([Unable to substitute extended shell functions in $ofile]) 7764238106Sdesfi 7765238106Sdes]) 7766238106Sdes 7767238106Sdes# _LT_PATH_CONVERSION_FUNCTIONS 7768238106Sdes# ----------------------------- 7769238106Sdes# Determine which file name conversion functions should be used by 7770238106Sdes# func_to_host_file (and, implicitly, by func_to_host_path). These are needed 7771238106Sdes# for certain cross-compile configurations and native mingw. 7772238106Sdesm4_defun([_LT_PATH_CONVERSION_FUNCTIONS], 7773238106Sdes[AC_REQUIRE([AC_CANONICAL_HOST])dnl 7774238106SdesAC_REQUIRE([AC_CANONICAL_BUILD])dnl 7775238106SdesAC_MSG_CHECKING([how to convert $build file names to $host format]) 7776238106SdesAC_CACHE_VAL(lt_cv_to_host_file_cmd, 7777238106Sdes[case $host in 7778238106Sdes *-*-mingw* ) 7779238106Sdes case $build in 7780238106Sdes *-*-mingw* ) # actually msys 7781238106Sdes lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32 7782238106Sdes ;; 7783238106Sdes *-*-cygwin* ) 7784238106Sdes lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32 7785238106Sdes ;; 7786238106Sdes * ) # otherwise, assume *nix 7787238106Sdes lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32 7788238106Sdes ;; 7789238106Sdes esac 7790238106Sdes ;; 7791238106Sdes *-*-cygwin* ) 7792238106Sdes case $build in 7793238106Sdes *-*-mingw* ) # actually msys 7794238106Sdes lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin 7795238106Sdes ;; 7796238106Sdes *-*-cygwin* ) 7797238106Sdes lt_cv_to_host_file_cmd=func_convert_file_noop 7798238106Sdes ;; 7799238106Sdes * ) # otherwise, assume *nix 7800238106Sdes lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin 7801238106Sdes ;; 7802238106Sdes esac 7803238106Sdes ;; 7804238106Sdes * ) # unhandled hosts (and "normal" native builds) 7805238106Sdes lt_cv_to_host_file_cmd=func_convert_file_noop 7806238106Sdes ;; 7807238106Sdesesac 7808238106Sdes]) 7809238106Sdesto_host_file_cmd=$lt_cv_to_host_file_cmd 7810238106SdesAC_MSG_RESULT([$lt_cv_to_host_file_cmd]) 7811238106Sdes_LT_DECL([to_host_file_cmd], [lt_cv_to_host_file_cmd], 7812238106Sdes [0], [convert $build file names to $host format])dnl 7813238106Sdes 7814238106SdesAC_MSG_CHECKING([how to convert $build file names to toolchain format]) 7815238106SdesAC_CACHE_VAL(lt_cv_to_tool_file_cmd, 7816238106Sdes[#assume ordinary cross tools, or native build. 7817238106Sdeslt_cv_to_tool_file_cmd=func_convert_file_noop 7818238106Sdescase $host in 7819238106Sdes *-*-mingw* ) 7820238106Sdes case $build in 7821238106Sdes *-*-mingw* ) # actually msys 7822238106Sdes lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32 7823238106Sdes ;; 7824238106Sdes esac 7825238106Sdes ;; 7826238106Sdesesac 7827238106Sdes]) 7828238106Sdesto_tool_file_cmd=$lt_cv_to_tool_file_cmd 7829238106SdesAC_MSG_RESULT([$lt_cv_to_tool_file_cmd]) 7830238106Sdes_LT_DECL([to_tool_file_cmd], [lt_cv_to_tool_file_cmd], 7831238106Sdes [0], [convert $build files to toolchain format])dnl 7832238106Sdes])# _LT_PATH_CONVERSION_FUNCTIONS 7833238106Sdes 7834238106Sdes# Helper functions for option handling. -*- Autoconf -*- 7835238106Sdes# 7836238106Sdes# Copyright (C) 2004, 2005, 2007, 2008, 2009 Free Software Foundation, 7837238106Sdes# Inc. 7838238106Sdes# Written by Gary V. Vaughan, 2004 7839238106Sdes# 7840238106Sdes# This file is free software; the Free Software Foundation gives 7841238106Sdes# unlimited permission to copy and/or distribute it, with or without 7842238106Sdes# modifications, as long as this notice is preserved. 7843238106Sdes 7844238106Sdes# serial 7 ltoptions.m4 7845238106Sdes 7846238106Sdes# This is to help aclocal find these macros, as it can't see m4_define. 7847238106SdesAC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])]) 7848238106Sdes 7849238106Sdes 7850238106Sdes# _LT_MANGLE_OPTION(MACRO-NAME, OPTION-NAME) 7851238106Sdes# ------------------------------------------ 7852238106Sdesm4_define([_LT_MANGLE_OPTION], 7853238106Sdes[[_LT_OPTION_]m4_bpatsubst($1__$2, [[^a-zA-Z0-9_]], [_])]) 7854238106Sdes 7855238106Sdes 7856238106Sdes# _LT_SET_OPTION(MACRO-NAME, OPTION-NAME) 7857238106Sdes# --------------------------------------- 7858238106Sdes# Set option OPTION-NAME for macro MACRO-NAME, and if there is a 7859238106Sdes# matching handler defined, dispatch to it. Other OPTION-NAMEs are 7860238106Sdes# saved as a flag. 7861238106Sdesm4_define([_LT_SET_OPTION], 7862238106Sdes[m4_define(_LT_MANGLE_OPTION([$1], [$2]))dnl 7863238106Sdesm4_ifdef(_LT_MANGLE_DEFUN([$1], [$2]), 7864238106Sdes _LT_MANGLE_DEFUN([$1], [$2]), 7865238106Sdes [m4_warning([Unknown $1 option `$2'])])[]dnl 7866238106Sdes]) 7867238106Sdes 7868238106Sdes 7869238106Sdes# _LT_IF_OPTION(MACRO-NAME, OPTION-NAME, IF-SET, [IF-NOT-SET]) 7870238106Sdes# ------------------------------------------------------------ 7871238106Sdes# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. 7872238106Sdesm4_define([_LT_IF_OPTION], 7873238106Sdes[m4_ifdef(_LT_MANGLE_OPTION([$1], [$2]), [$3], [$4])]) 7874238106Sdes 7875238106Sdes 7876238106Sdes# _LT_UNLESS_OPTIONS(MACRO-NAME, OPTION-LIST, IF-NOT-SET) 7877238106Sdes# ------------------------------------------------------- 7878238106Sdes# Execute IF-NOT-SET unless all options in OPTION-LIST for MACRO-NAME 7879238106Sdes# are set. 7880238106Sdesm4_define([_LT_UNLESS_OPTIONS], 7881238106Sdes[m4_foreach([_LT_Option], m4_split(m4_normalize([$2])), 7882238106Sdes [m4_ifdef(_LT_MANGLE_OPTION([$1], _LT_Option), 7883238106Sdes [m4_define([$0_found])])])[]dnl 7884238106Sdesm4_ifdef([$0_found], [m4_undefine([$0_found])], [$3 7885238106Sdes])[]dnl 7886238106Sdes]) 7887238106Sdes 7888238106Sdes 7889238106Sdes# _LT_SET_OPTIONS(MACRO-NAME, OPTION-LIST) 7890238106Sdes# ---------------------------------------- 7891238106Sdes# OPTION-LIST is a space-separated list of Libtool options associated 7892238106Sdes# with MACRO-NAME. If any OPTION has a matching handler declared with 7893238106Sdes# LT_OPTION_DEFINE, dispatch to that macro; otherwise complain about 7894238106Sdes# the unknown option and exit. 7895238106Sdesm4_defun([_LT_SET_OPTIONS], 7896238106Sdes[# Set options 7897238106Sdesm4_foreach([_LT_Option], m4_split(m4_normalize([$2])), 7898238106Sdes [_LT_SET_OPTION([$1], _LT_Option)]) 7899238106Sdes 7900238106Sdesm4_if([$1],[LT_INIT],[ 7901238106Sdes dnl 7902238106Sdes dnl Simply set some default values (i.e off) if boolean options were not 7903238106Sdes dnl specified: 7904238106Sdes _LT_UNLESS_OPTIONS([LT_INIT], [dlopen], [enable_dlopen=no 7905238106Sdes ]) 7906238106Sdes _LT_UNLESS_OPTIONS([LT_INIT], [win32-dll], [enable_win32_dll=no 7907238106Sdes ]) 7908238106Sdes dnl 7909238106Sdes dnl If no reference was made to various pairs of opposing options, then 7910238106Sdes dnl we run the default mode handler for the pair. For example, if neither 7911238106Sdes dnl `shared' nor `disable-shared' was passed, we enable building of shared 7912238106Sdes dnl archives by default: 7913238106Sdes _LT_UNLESS_OPTIONS([LT_INIT], [shared disable-shared], [_LT_ENABLE_SHARED]) 7914238106Sdes _LT_UNLESS_OPTIONS([LT_INIT], [static disable-static], [_LT_ENABLE_STATIC]) 7915238106Sdes _LT_UNLESS_OPTIONS([LT_INIT], [pic-only no-pic], [_LT_WITH_PIC]) 7916238106Sdes _LT_UNLESS_OPTIONS([LT_INIT], [fast-install disable-fast-install], 7917238106Sdes [_LT_ENABLE_FAST_INSTALL]) 7918238106Sdes ]) 7919238106Sdes])# _LT_SET_OPTIONS 7920238106Sdes 7921238106Sdes 7922238106Sdes 7923238106Sdes# _LT_MANGLE_DEFUN(MACRO-NAME, OPTION-NAME) 7924238106Sdes# ----------------------------------------- 7925238106Sdesm4_define([_LT_MANGLE_DEFUN], 7926238106Sdes[[_LT_OPTION_DEFUN_]m4_bpatsubst(m4_toupper([$1__$2]), [[^A-Z0-9_]], [_])]) 7927238106Sdes 7928238106Sdes 7929238106Sdes# LT_OPTION_DEFINE(MACRO-NAME, OPTION-NAME, CODE) 7930238106Sdes# ----------------------------------------------- 7931238106Sdesm4_define([LT_OPTION_DEFINE], 7932238106Sdes[m4_define(_LT_MANGLE_DEFUN([$1], [$2]), [$3])[]dnl 7933238106Sdes])# LT_OPTION_DEFINE 7934238106Sdes 7935238106Sdes 7936238106Sdes# dlopen 7937238106Sdes# ------ 7938238106SdesLT_OPTION_DEFINE([LT_INIT], [dlopen], [enable_dlopen=yes 7939238106Sdes]) 7940238106Sdes 7941238106SdesAU_DEFUN([AC_LIBTOOL_DLOPEN], 7942238106Sdes[_LT_SET_OPTION([LT_INIT], [dlopen]) 7943238106SdesAC_DIAGNOSE([obsolete], 7944238106Sdes[$0: Remove this warning and the call to _LT_SET_OPTION when you 7945238106Sdesput the `dlopen' option into LT_INIT's first parameter.]) 7946238106Sdes]) 7947238106Sdes 7948238106Sdesdnl aclocal-1.4 backwards compatibility: 7949238106Sdesdnl AC_DEFUN([AC_LIBTOOL_DLOPEN], []) 7950238106Sdes 7951238106Sdes 7952238106Sdes# win32-dll 7953238106Sdes# --------- 7954238106Sdes# Declare package support for building win32 dll's. 7955238106SdesLT_OPTION_DEFINE([LT_INIT], [win32-dll], 7956238106Sdes[enable_win32_dll=yes 7957238106Sdes 7958238106Sdescase $host in 7959238106Sdes*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-cegcc*) 7960238106Sdes AC_CHECK_TOOL(AS, as, false) 7961238106Sdes AC_CHECK_TOOL(DLLTOOL, dlltool, false) 7962238106Sdes AC_CHECK_TOOL(OBJDUMP, objdump, false) 7963238106Sdes ;; 7964238106Sdesesac 7965238106Sdes 7966238106Sdestest -z "$AS" && AS=as 7967238106Sdes_LT_DECL([], [AS], [1], [Assembler program])dnl 7968238106Sdes 7969238106Sdestest -z "$DLLTOOL" && DLLTOOL=dlltool 7970238106Sdes_LT_DECL([], [DLLTOOL], [1], [DLL creation program])dnl 7971238106Sdes 7972238106Sdestest -z "$OBJDUMP" && OBJDUMP=objdump 7973238106Sdes_LT_DECL([], [OBJDUMP], [1], [Object dumper program])dnl 7974238106Sdes])# win32-dll 7975238106Sdes 7976238106SdesAU_DEFUN([AC_LIBTOOL_WIN32_DLL], 7977238106Sdes[AC_REQUIRE([AC_CANONICAL_HOST])dnl 7978238106Sdes_LT_SET_OPTION([LT_INIT], [win32-dll]) 7979238106SdesAC_DIAGNOSE([obsolete], 7980238106Sdes[$0: Remove this warning and the call to _LT_SET_OPTION when you 7981238106Sdesput the `win32-dll' option into LT_INIT's first parameter.]) 7982238106Sdes]) 7983238106Sdes 7984238106Sdesdnl aclocal-1.4 backwards compatibility: 7985238106Sdesdnl AC_DEFUN([AC_LIBTOOL_WIN32_DLL], []) 7986238106Sdes 7987238106Sdes 7988238106Sdes# _LT_ENABLE_SHARED([DEFAULT]) 7989238106Sdes# ---------------------------- 7990238106Sdes# implement the --enable-shared flag, and supports the `shared' and 7991238106Sdes# `disable-shared' LT_INIT options. 7992238106Sdes# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. 7993238106Sdesm4_define([_LT_ENABLE_SHARED], 7994238106Sdes[m4_define([_LT_ENABLE_SHARED_DEFAULT], [m4_if($1, no, no, yes)])dnl 7995238106SdesAC_ARG_ENABLE([shared], 7996238106Sdes [AS_HELP_STRING([--enable-shared@<:@=PKGS@:>@], 7997238106Sdes [build shared libraries @<:@default=]_LT_ENABLE_SHARED_DEFAULT[@:>@])], 7998238106Sdes [p=${PACKAGE-default} 7999238106Sdes case $enableval in 8000238106Sdes yes) enable_shared=yes ;; 8001238106Sdes no) enable_shared=no ;; 8002238106Sdes *) 8003238106Sdes enable_shared=no 8004238106Sdes # Look at the argument we got. We use all the common list separators. 8005238106Sdes lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," 8006238106Sdes for pkg in $enableval; do 8007238106Sdes IFS="$lt_save_ifs" 8008238106Sdes if test "X$pkg" = "X$p"; then 8009238106Sdes enable_shared=yes 8010238106Sdes fi 8011238106Sdes done 8012238106Sdes IFS="$lt_save_ifs" 8013238106Sdes ;; 8014238106Sdes esac], 8015238106Sdes [enable_shared=]_LT_ENABLE_SHARED_DEFAULT) 8016238106Sdes 8017238106Sdes _LT_DECL([build_libtool_libs], [enable_shared], [0], 8018238106Sdes [Whether or not to build shared libraries]) 8019238106Sdes])# _LT_ENABLE_SHARED 8020238106Sdes 8021238106SdesLT_OPTION_DEFINE([LT_INIT], [shared], [_LT_ENABLE_SHARED([yes])]) 8022238106SdesLT_OPTION_DEFINE([LT_INIT], [disable-shared], [_LT_ENABLE_SHARED([no])]) 8023238106Sdes 8024238106Sdes# Old names: 8025238106SdesAC_DEFUN([AC_ENABLE_SHARED], 8026238106Sdes[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[shared]) 8027238106Sdes]) 8028238106Sdes 8029238106SdesAC_DEFUN([AC_DISABLE_SHARED], 8030238106Sdes[_LT_SET_OPTION([LT_INIT], [disable-shared]) 8031238106Sdes]) 8032238106Sdes 8033238106SdesAU_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)]) 8034238106SdesAU_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)]) 8035238106Sdes 8036238106Sdesdnl aclocal-1.4 backwards compatibility: 8037238106Sdesdnl AC_DEFUN([AM_ENABLE_SHARED], []) 8038238106Sdesdnl AC_DEFUN([AM_DISABLE_SHARED], []) 8039238106Sdes 8040238106Sdes 8041238106Sdes 8042238106Sdes# _LT_ENABLE_STATIC([DEFAULT]) 8043238106Sdes# ---------------------------- 8044238106Sdes# implement the --enable-static flag, and support the `static' and 8045238106Sdes# `disable-static' LT_INIT options. 8046238106Sdes# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. 8047238106Sdesm4_define([_LT_ENABLE_STATIC], 8048238106Sdes[m4_define([_LT_ENABLE_STATIC_DEFAULT], [m4_if($1, no, no, yes)])dnl 8049238106SdesAC_ARG_ENABLE([static], 8050238106Sdes [AS_HELP_STRING([--enable-static@<:@=PKGS@:>@], 8051238106Sdes [build static libraries @<:@default=]_LT_ENABLE_STATIC_DEFAULT[@:>@])], 8052238106Sdes [p=${PACKAGE-default} 8053238106Sdes case $enableval in 8054238106Sdes yes) enable_static=yes ;; 8055238106Sdes no) enable_static=no ;; 8056238106Sdes *) 8057238106Sdes enable_static=no 8058238106Sdes # Look at the argument we got. We use all the common list separators. 8059238106Sdes lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," 8060238106Sdes for pkg in $enableval; do 8061238106Sdes IFS="$lt_save_ifs" 8062238106Sdes if test "X$pkg" = "X$p"; then 8063238106Sdes enable_static=yes 8064238106Sdes fi 8065238106Sdes done 8066238106Sdes IFS="$lt_save_ifs" 8067238106Sdes ;; 8068238106Sdes esac], 8069238106Sdes [enable_static=]_LT_ENABLE_STATIC_DEFAULT) 8070238106Sdes 8071238106Sdes _LT_DECL([build_old_libs], [enable_static], [0], 8072238106Sdes [Whether or not to build static libraries]) 8073238106Sdes])# _LT_ENABLE_STATIC 8074238106Sdes 8075238106SdesLT_OPTION_DEFINE([LT_INIT], [static], [_LT_ENABLE_STATIC([yes])]) 8076238106SdesLT_OPTION_DEFINE([LT_INIT], [disable-static], [_LT_ENABLE_STATIC([no])]) 8077238106Sdes 8078238106Sdes# Old names: 8079238106SdesAC_DEFUN([AC_ENABLE_STATIC], 8080238106Sdes[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[static]) 8081238106Sdes]) 8082238106Sdes 8083238106SdesAC_DEFUN([AC_DISABLE_STATIC], 8084238106Sdes[_LT_SET_OPTION([LT_INIT], [disable-static]) 8085238106Sdes]) 8086238106Sdes 8087238106SdesAU_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)]) 8088238106SdesAU_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)]) 8089238106Sdes 8090238106Sdesdnl aclocal-1.4 backwards compatibility: 8091238106Sdesdnl AC_DEFUN([AM_ENABLE_STATIC], []) 8092238106Sdesdnl AC_DEFUN([AM_DISABLE_STATIC], []) 8093238106Sdes 8094238106Sdes 8095238106Sdes 8096238106Sdes# _LT_ENABLE_FAST_INSTALL([DEFAULT]) 8097238106Sdes# ---------------------------------- 8098238106Sdes# implement the --enable-fast-install flag, and support the `fast-install' 8099238106Sdes# and `disable-fast-install' LT_INIT options. 8100238106Sdes# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. 8101238106Sdesm4_define([_LT_ENABLE_FAST_INSTALL], 8102238106Sdes[m4_define([_LT_ENABLE_FAST_INSTALL_DEFAULT], [m4_if($1, no, no, yes)])dnl 8103238106SdesAC_ARG_ENABLE([fast-install], 8104238106Sdes [AS_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@], 8105238106Sdes [optimize for fast installation @<:@default=]_LT_ENABLE_FAST_INSTALL_DEFAULT[@:>@])], 8106238106Sdes [p=${PACKAGE-default} 8107238106Sdes case $enableval in 8108238106Sdes yes) enable_fast_install=yes ;; 8109238106Sdes no) enable_fast_install=no ;; 8110238106Sdes *) 8111238106Sdes enable_fast_install=no 8112238106Sdes # Look at the argument we got. We use all the common list separators. 8113238106Sdes lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," 8114238106Sdes for pkg in $enableval; do 8115238106Sdes IFS="$lt_save_ifs" 8116238106Sdes if test "X$pkg" = "X$p"; then 8117238106Sdes enable_fast_install=yes 8118238106Sdes fi 8119238106Sdes done 8120238106Sdes IFS="$lt_save_ifs" 8121238106Sdes ;; 8122238106Sdes esac], 8123238106Sdes [enable_fast_install=]_LT_ENABLE_FAST_INSTALL_DEFAULT) 8124238106Sdes 8125238106Sdes_LT_DECL([fast_install], [enable_fast_install], [0], 8126238106Sdes [Whether or not to optimize for fast installation])dnl 8127238106Sdes])# _LT_ENABLE_FAST_INSTALL 8128238106Sdes 8129238106SdesLT_OPTION_DEFINE([LT_INIT], [fast-install], [_LT_ENABLE_FAST_INSTALL([yes])]) 8130238106SdesLT_OPTION_DEFINE([LT_INIT], [disable-fast-install], [_LT_ENABLE_FAST_INSTALL([no])]) 8131238106Sdes 8132238106Sdes# Old names: 8133238106SdesAU_DEFUN([AC_ENABLE_FAST_INSTALL], 8134238106Sdes[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[fast-install]) 8135238106SdesAC_DIAGNOSE([obsolete], 8136238106Sdes[$0: Remove this warning and the call to _LT_SET_OPTION when you put 8137238106Sdesthe `fast-install' option into LT_INIT's first parameter.]) 8138238106Sdes]) 8139238106Sdes 8140238106SdesAU_DEFUN([AC_DISABLE_FAST_INSTALL], 8141238106Sdes[_LT_SET_OPTION([LT_INIT], [disable-fast-install]) 8142238106SdesAC_DIAGNOSE([obsolete], 8143238106Sdes[$0: Remove this warning and the call to _LT_SET_OPTION when you put 8144238106Sdesthe `disable-fast-install' option into LT_INIT's first parameter.]) 8145238106Sdes]) 8146238106Sdes 8147238106Sdesdnl aclocal-1.4 backwards compatibility: 8148238106Sdesdnl AC_DEFUN([AC_ENABLE_FAST_INSTALL], []) 8149238106Sdesdnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], []) 8150238106Sdes 8151238106Sdes 8152238106Sdes# _LT_WITH_PIC([MODE]) 8153238106Sdes# -------------------- 8154238106Sdes# implement the --with-pic flag, and support the `pic-only' and `no-pic' 8155238106Sdes# LT_INIT options. 8156238106Sdes# MODE is either `yes' or `no'. If omitted, it defaults to `both'. 8157238106Sdesm4_define([_LT_WITH_PIC], 8158238106Sdes[AC_ARG_WITH([pic], 8159238106Sdes [AS_HELP_STRING([--with-pic], 8160238106Sdes [try to use only PIC/non-PIC objects @<:@default=use both@:>@])], 8161238106Sdes [pic_mode="$withval"], 8162238106Sdes [pic_mode=default]) 8163238106Sdes 8164238106Sdestest -z "$pic_mode" && pic_mode=m4_default([$1], [default]) 8165238106Sdes 8166238106Sdes_LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl 8167238106Sdes])# _LT_WITH_PIC 8168238106Sdes 8169238106SdesLT_OPTION_DEFINE([LT_INIT], [pic-only], [_LT_WITH_PIC([yes])]) 8170238106SdesLT_OPTION_DEFINE([LT_INIT], [no-pic], [_LT_WITH_PIC([no])]) 8171238106Sdes 8172238106Sdes# Old name: 8173238106SdesAU_DEFUN([AC_LIBTOOL_PICMODE], 8174238106Sdes[_LT_SET_OPTION([LT_INIT], [pic-only]) 8175238106SdesAC_DIAGNOSE([obsolete], 8176238106Sdes[$0: Remove this warning and the call to _LT_SET_OPTION when you 8177238106Sdesput the `pic-only' option into LT_INIT's first parameter.]) 8178238106Sdes]) 8179238106Sdes 8180238106Sdesdnl aclocal-1.4 backwards compatibility: 8181238106Sdesdnl AC_DEFUN([AC_LIBTOOL_PICMODE], []) 8182238106Sdes 8183238106Sdes 8184238106Sdesm4_define([_LTDL_MODE], []) 8185238106SdesLT_OPTION_DEFINE([LTDL_INIT], [nonrecursive], 8186238106Sdes [m4_define([_LTDL_MODE], [nonrecursive])]) 8187238106SdesLT_OPTION_DEFINE([LTDL_INIT], [recursive], 8188238106Sdes [m4_define([_LTDL_MODE], [recursive])]) 8189238106SdesLT_OPTION_DEFINE([LTDL_INIT], [subproject], 8190238106Sdes [m4_define([_LTDL_MODE], [subproject])]) 8191238106Sdes 8192238106Sdesm4_define([_LTDL_TYPE], []) 8193238106SdesLT_OPTION_DEFINE([LTDL_INIT], [installable], 8194238106Sdes [m4_define([_LTDL_TYPE], [installable])]) 8195238106SdesLT_OPTION_DEFINE([LTDL_INIT], [convenience], 8196238106Sdes [m4_define([_LTDL_TYPE], [convenience])]) 8197238106Sdes 8198238106Sdes# ltsugar.m4 -- libtool m4 base layer. -*-Autoconf-*- 8199238106Sdes# 8200238106Sdes# Copyright (C) 2004, 2005, 2007, 2008 Free Software Foundation, Inc. 8201238106Sdes# Written by Gary V. Vaughan, 2004 8202238106Sdes# 8203238106Sdes# This file is free software; the Free Software Foundation gives 8204238106Sdes# unlimited permission to copy and/or distribute it, with or without 8205238106Sdes# modifications, as long as this notice is preserved. 8206238106Sdes 8207238106Sdes# serial 6 ltsugar.m4 8208238106Sdes 8209238106Sdes# This is to help aclocal find these macros, as it can't see m4_define. 8210238106SdesAC_DEFUN([LTSUGAR_VERSION], [m4_if([0.1])]) 8211238106Sdes 8212238106Sdes 8213238106Sdes# lt_join(SEP, ARG1, [ARG2...]) 8214238106Sdes# ----------------------------- 8215238106Sdes# Produce ARG1SEPARG2...SEPARGn, omitting [] arguments and their 8216238106Sdes# associated separator. 8217238106Sdes# Needed until we can rely on m4_join from Autoconf 2.62, since all earlier 8218238106Sdes# versions in m4sugar had bugs. 8219238106Sdesm4_define([lt_join], 8220238106Sdes[m4_if([$#], [1], [], 8221238106Sdes [$#], [2], [[$2]], 8222238106Sdes [m4_if([$2], [], [], [[$2]_])$0([$1], m4_shift(m4_shift($@)))])]) 8223238106Sdesm4_define([_lt_join], 8224238106Sdes[m4_if([$#$2], [2], [], 8225238106Sdes [m4_if([$2], [], [], [[$1$2]])$0([$1], m4_shift(m4_shift($@)))])]) 8226238106Sdes 8227238106Sdes 8228238106Sdes# lt_car(LIST) 8229238106Sdes# lt_cdr(LIST) 8230238106Sdes# ------------ 8231238106Sdes# Manipulate m4 lists. 8232238106Sdes# These macros are necessary as long as will still need to support 8233238106Sdes# Autoconf-2.59 which quotes differently. 8234238106Sdesm4_define([lt_car], [[$1]]) 8235238106Sdesm4_define([lt_cdr], 8236238106Sdes[m4_if([$#], 0, [m4_fatal([$0: cannot be called without arguments])], 8237238106Sdes [$#], 1, [], 8238238106Sdes [m4_dquote(m4_shift($@))])]) 8239238106Sdesm4_define([lt_unquote], $1) 8240238106Sdes 8241238106Sdes 8242238106Sdes# lt_append(MACRO-NAME, STRING, [SEPARATOR]) 8243238106Sdes# ------------------------------------------ 8244238106Sdes# Redefine MACRO-NAME to hold its former content plus `SEPARATOR'`STRING'. 8245238106Sdes# Note that neither SEPARATOR nor STRING are expanded; they are appended 8246238106Sdes# to MACRO-NAME as is (leaving the expansion for when MACRO-NAME is invoked). 8247238106Sdes# No SEPARATOR is output if MACRO-NAME was previously undefined (different 8248238106Sdes# than defined and empty). 8249238106Sdes# 8250238106Sdes# This macro is needed until we can rely on Autoconf 2.62, since earlier 8251238106Sdes# versions of m4sugar mistakenly expanded SEPARATOR but not STRING. 8252238106Sdesm4_define([lt_append], 8253238106Sdes[m4_define([$1], 8254238106Sdes m4_ifdef([$1], [m4_defn([$1])[$3]])[$2])]) 8255238106Sdes 8256238106Sdes 8257238106Sdes 8258238106Sdes# lt_combine(SEP, PREFIX-LIST, INFIX, SUFFIX1, [SUFFIX2...]) 8259238106Sdes# ---------------------------------------------------------- 8260238106Sdes# Produce a SEP delimited list of all paired combinations of elements of 8261238106Sdes# PREFIX-LIST with SUFFIX1 through SUFFIXn. Each element of the list 8262238106Sdes# has the form PREFIXmINFIXSUFFIXn. 8263238106Sdes# Needed until we can rely on m4_combine added in Autoconf 2.62. 8264238106Sdesm4_define([lt_combine], 8265238106Sdes[m4_if(m4_eval([$# > 3]), [1], 8266238106Sdes [m4_pushdef([_Lt_sep], [m4_define([_Lt_sep], m4_defn([lt_car]))])]]dnl 8267238106Sdes[[m4_foreach([_Lt_prefix], [$2], 8268238106Sdes [m4_foreach([_Lt_suffix], 8269238106Sdes ]m4_dquote(m4_dquote(m4_shift(m4_shift(m4_shift($@)))))[, 8270238106Sdes [_Lt_sep([$1])[]m4_defn([_Lt_prefix])[$3]m4_defn([_Lt_suffix])])])])]) 8271238106Sdes 8272238106Sdes 8273238106Sdes# lt_if_append_uniq(MACRO-NAME, VARNAME, [SEPARATOR], [UNIQ], [NOT-UNIQ]) 8274238106Sdes# ----------------------------------------------------------------------- 8275238106Sdes# Iff MACRO-NAME does not yet contain VARNAME, then append it (delimited 8276238106Sdes# by SEPARATOR if supplied) and expand UNIQ, else NOT-UNIQ. 8277238106Sdesm4_define([lt_if_append_uniq], 8278238106Sdes[m4_ifdef([$1], 8279238106Sdes [m4_if(m4_index([$3]m4_defn([$1])[$3], [$3$2$3]), [-1], 8280238106Sdes [lt_append([$1], [$2], [$3])$4], 8281238106Sdes [$5])], 8282238106Sdes [lt_append([$1], [$2], [$3])$4])]) 8283238106Sdes 8284238106Sdes 8285238106Sdes# lt_dict_add(DICT, KEY, VALUE) 8286238106Sdes# ----------------------------- 8287238106Sdesm4_define([lt_dict_add], 8288238106Sdes[m4_define([$1($2)], [$3])]) 8289238106Sdes 8290238106Sdes 8291238106Sdes# lt_dict_add_subkey(DICT, KEY, SUBKEY, VALUE) 8292238106Sdes# -------------------------------------------- 8293238106Sdesm4_define([lt_dict_add_subkey], 8294238106Sdes[m4_define([$1($2:$3)], [$4])]) 8295238106Sdes 8296238106Sdes 8297238106Sdes# lt_dict_fetch(DICT, KEY, [SUBKEY]) 8298238106Sdes# ---------------------------------- 8299238106Sdesm4_define([lt_dict_fetch], 8300238106Sdes[m4_ifval([$3], 8301238106Sdes m4_ifdef([$1($2:$3)], [m4_defn([$1($2:$3)])]), 8302238106Sdes m4_ifdef([$1($2)], [m4_defn([$1($2)])]))]) 8303238106Sdes 8304238106Sdes 8305238106Sdes# lt_if_dict_fetch(DICT, KEY, [SUBKEY], VALUE, IF-TRUE, [IF-FALSE]) 8306238106Sdes# ----------------------------------------------------------------- 8307238106Sdesm4_define([lt_if_dict_fetch], 8308238106Sdes[m4_if(lt_dict_fetch([$1], [$2], [$3]), [$4], 8309238106Sdes [$5], 8310238106Sdes [$6])]) 8311238106Sdes 8312238106Sdes 8313238106Sdes# lt_dict_filter(DICT, [SUBKEY], VALUE, [SEPARATOR], KEY, [...]) 8314238106Sdes# -------------------------------------------------------------- 8315238106Sdesm4_define([lt_dict_filter], 8316238106Sdes[m4_if([$5], [], [], 8317238106Sdes [lt_join(m4_quote(m4_default([$4], [[, ]])), 8318238106Sdes lt_unquote(m4_split(m4_normalize(m4_foreach(_Lt_key, lt_car([m4_shiftn(4, $@)]), 8319238106Sdes [lt_if_dict_fetch([$1], _Lt_key, [$2], [$3], [_Lt_key ])])))))])[]dnl 8320238106Sdes]) 8321238106Sdes 8322238106Sdes# ltversion.m4 -- version numbers -*- Autoconf -*- 8323238106Sdes# 8324238106Sdes# Copyright (C) 2004 Free Software Foundation, Inc. 8325238106Sdes# Written by Scott James Remnant, 2004 8326238106Sdes# 8327238106Sdes# This file is free software; the Free Software Foundation gives 8328238106Sdes# unlimited permission to copy and/or distribute it, with or without 8329238106Sdes# modifications, as long as this notice is preserved. 8330238106Sdes 8331238106Sdes# @configure_input@ 8332238106Sdes 8333238106Sdes# serial 3293 ltversion.m4 8334238106Sdes# This file is part of GNU Libtool 8335238106Sdes 8336238106Sdesm4_define([LT_PACKAGE_VERSION], [2.4]) 8337238106Sdesm4_define([LT_PACKAGE_REVISION], [1.3293]) 8338238106Sdes 8339238106SdesAC_DEFUN([LTVERSION_VERSION], 8340238106Sdes[macro_version='2.4' 8341238106Sdesmacro_revision='1.3293' 8342238106Sdes_LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?]) 8343238106Sdes_LT_DECL(, macro_revision, 0) 8344238106Sdes]) 8345238106Sdes 8346238106Sdes# lt~obsolete.m4 -- aclocal satisfying obsolete definitions. -*-Autoconf-*- 8347238106Sdes# 8348238106Sdes# Copyright (C) 2004, 2005, 2007, 2009 Free Software Foundation, Inc. 8349238106Sdes# Written by Scott James Remnant, 2004. 8350238106Sdes# 8351238106Sdes# This file is free software; the Free Software Foundation gives 8352238106Sdes# unlimited permission to copy and/or distribute it, with or without 8353238106Sdes# modifications, as long as this notice is preserved. 8354238106Sdes 8355238106Sdes# serial 5 lt~obsolete.m4 8356238106Sdes 8357238106Sdes# These exist entirely to fool aclocal when bootstrapping libtool. 8358238106Sdes# 8359238106Sdes# In the past libtool.m4 has provided macros via AC_DEFUN (or AU_DEFUN) 8360238106Sdes# which have later been changed to m4_define as they aren't part of the 8361238106Sdes# exported API, or moved to Autoconf or Automake where they belong. 8362238106Sdes# 8363238106Sdes# The trouble is, aclocal is a bit thick. It'll see the old AC_DEFUN 8364238106Sdes# in /usr/share/aclocal/libtool.m4 and remember it, then when it sees us 8365238106Sdes# using a macro with the same name in our local m4/libtool.m4 it'll 8366238106Sdes# pull the old libtool.m4 in (it doesn't see our shiny new m4_define 8367238106Sdes# and doesn't know about Autoconf macros at all.) 8368238106Sdes# 8369238106Sdes# So we provide this file, which has a silly filename so it's always 8370238106Sdes# included after everything else. This provides aclocal with the 8371238106Sdes# AC_DEFUNs it wants, but when m4 processes it, it doesn't do anything 8372238106Sdes# because those macros already exist, or will be overwritten later. 8373238106Sdes# We use AC_DEFUN over AU_DEFUN for compatibility with aclocal-1.6. 8374238106Sdes# 8375238106Sdes# Anytime we withdraw an AC_DEFUN or AU_DEFUN, remember to add it here. 8376238106Sdes# Yes, that means every name once taken will need to remain here until 8377238106Sdes# we give up compatibility with versions before 1.7, at which point 8378238106Sdes# we need to keep only those names which we still refer to. 8379238106Sdes 8380238106Sdes# This is to help aclocal find these macros, as it can't see m4_define. 8381238106SdesAC_DEFUN([LTOBSOLETE_VERSION], [m4_if([1])]) 8382238106Sdes 8383238106Sdesm4_ifndef([AC_LIBTOOL_LINKER_OPTION], [AC_DEFUN([AC_LIBTOOL_LINKER_OPTION])]) 8384238106Sdesm4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP])]) 8385238106Sdesm4_ifndef([_LT_AC_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH])]) 8386238106Sdesm4_ifndef([_LT_AC_SHELL_INIT], [AC_DEFUN([_LT_AC_SHELL_INIT])]) 8387238106Sdesm4_ifndef([_LT_AC_SYS_LIBPATH_AIX], [AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX])]) 8388238106Sdesm4_ifndef([_LT_PROG_LTMAIN], [AC_DEFUN([_LT_PROG_LTMAIN])]) 8389238106Sdesm4_ifndef([_LT_AC_TAGVAR], [AC_DEFUN([_LT_AC_TAGVAR])]) 8390238106Sdesm4_ifndef([AC_LTDL_ENABLE_INSTALL], [AC_DEFUN([AC_LTDL_ENABLE_INSTALL])]) 8391238106Sdesm4_ifndef([AC_LTDL_PREOPEN], [AC_DEFUN([AC_LTDL_PREOPEN])]) 8392238106Sdesm4_ifndef([_LT_AC_SYS_COMPILER], [AC_DEFUN([_LT_AC_SYS_COMPILER])]) 8393238106Sdesm4_ifndef([_LT_AC_LOCK], [AC_DEFUN([_LT_AC_LOCK])]) 8394238106Sdesm4_ifndef([AC_LIBTOOL_SYS_OLD_ARCHIVE], [AC_DEFUN([AC_LIBTOOL_SYS_OLD_ARCHIVE])]) 8395238106Sdesm4_ifndef([_LT_AC_TRY_DLOPEN_SELF], [AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF])]) 8396238106Sdesm4_ifndef([AC_LIBTOOL_PROG_CC_C_O], [AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O])]) 8397238106Sdesm4_ifndef([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], [AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS])]) 8398238106Sdesm4_ifndef([AC_LIBTOOL_OBJDIR], [AC_DEFUN([AC_LIBTOOL_OBJDIR])]) 8399238106Sdesm4_ifndef([AC_LTDL_OBJDIR], [AC_DEFUN([AC_LTDL_OBJDIR])]) 8400238106Sdesm4_ifndef([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], [AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH])]) 8401238106Sdesm4_ifndef([AC_LIBTOOL_SYS_LIB_STRIP], [AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP])]) 8402238106Sdesm4_ifndef([AC_PATH_MAGIC], [AC_DEFUN([AC_PATH_MAGIC])]) 8403238106Sdesm4_ifndef([AC_PROG_LD_GNU], [AC_DEFUN([AC_PROG_LD_GNU])]) 8404238106Sdesm4_ifndef([AC_PROG_LD_RELOAD_FLAG], [AC_DEFUN([AC_PROG_LD_RELOAD_FLAG])]) 8405238106Sdesm4_ifndef([AC_DEPLIBS_CHECK_METHOD], [AC_DEFUN([AC_DEPLIBS_CHECK_METHOD])]) 8406238106Sdesm4_ifndef([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI])]) 8407238106Sdesm4_ifndef([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], [AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE])]) 8408238106Sdesm4_ifndef([AC_LIBTOOL_PROG_COMPILER_PIC], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC])]) 8409238106Sdesm4_ifndef([AC_LIBTOOL_PROG_LD_SHLIBS], [AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS])]) 8410238106Sdesm4_ifndef([AC_LIBTOOL_POSTDEP_PREDEP], [AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP])]) 8411238106Sdesm4_ifndef([LT_AC_PROG_EGREP], [AC_DEFUN([LT_AC_PROG_EGREP])]) 8412238106Sdesm4_ifndef([LT_AC_PROG_SED], [AC_DEFUN([LT_AC_PROG_SED])]) 8413238106Sdesm4_ifndef([_LT_CC_BASENAME], [AC_DEFUN([_LT_CC_BASENAME])]) 8414238106Sdesm4_ifndef([_LT_COMPILER_BOILERPLATE], [AC_DEFUN([_LT_COMPILER_BOILERPLATE])]) 8415238106Sdesm4_ifndef([_LT_LINKER_BOILERPLATE], [AC_DEFUN([_LT_LINKER_BOILERPLATE])]) 8416238106Sdesm4_ifndef([_AC_PROG_LIBTOOL], [AC_DEFUN([_AC_PROG_LIBTOOL])]) 8417238106Sdesm4_ifndef([AC_LIBTOOL_SETUP], [AC_DEFUN([AC_LIBTOOL_SETUP])]) 8418238106Sdesm4_ifndef([_LT_AC_CHECK_DLFCN], [AC_DEFUN([_LT_AC_CHECK_DLFCN])]) 8419238106Sdesm4_ifndef([AC_LIBTOOL_SYS_DYNAMIC_LINKER], [AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER])]) 8420238106Sdesm4_ifndef([_LT_AC_TAGCONFIG], [AC_DEFUN([_LT_AC_TAGCONFIG])]) 8421238106Sdesm4_ifndef([AC_DISABLE_FAST_INSTALL], [AC_DEFUN([AC_DISABLE_FAST_INSTALL])]) 8422238106Sdesm4_ifndef([_LT_AC_LANG_CXX], [AC_DEFUN([_LT_AC_LANG_CXX])]) 8423238106Sdesm4_ifndef([_LT_AC_LANG_F77], [AC_DEFUN([_LT_AC_LANG_F77])]) 8424238106Sdesm4_ifndef([_LT_AC_LANG_GCJ], [AC_DEFUN([_LT_AC_LANG_GCJ])]) 8425238106Sdesm4_ifndef([AC_LIBTOOL_LANG_C_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG])]) 8426238106Sdesm4_ifndef([_LT_AC_LANG_C_CONFIG], [AC_DEFUN([_LT_AC_LANG_C_CONFIG])]) 8427238106Sdesm4_ifndef([AC_LIBTOOL_LANG_CXX_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG])]) 8428238106Sdesm4_ifndef([_LT_AC_LANG_CXX_CONFIG], [AC_DEFUN([_LT_AC_LANG_CXX_CONFIG])]) 8429238106Sdesm4_ifndef([AC_LIBTOOL_LANG_F77_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG])]) 8430238106Sdesm4_ifndef([_LT_AC_LANG_F77_CONFIG], [AC_DEFUN([_LT_AC_LANG_F77_CONFIG])]) 8431238106Sdesm4_ifndef([AC_LIBTOOL_LANG_GCJ_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG])]) 8432238106Sdesm4_ifndef([_LT_AC_LANG_GCJ_CONFIG], [AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG])]) 8433238106Sdesm4_ifndef([AC_LIBTOOL_LANG_RC_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG])]) 8434238106Sdesm4_ifndef([_LT_AC_LANG_RC_CONFIG], [AC_DEFUN([_LT_AC_LANG_RC_CONFIG])]) 8435238106Sdesm4_ifndef([AC_LIBTOOL_CONFIG], [AC_DEFUN([AC_LIBTOOL_CONFIG])]) 8436238106Sdesm4_ifndef([_LT_AC_FILE_LTDLL_C], [AC_DEFUN([_LT_AC_FILE_LTDLL_C])]) 8437238106Sdesm4_ifndef([_LT_REQUIRED_DARWIN_CHECKS], [AC_DEFUN([_LT_REQUIRED_DARWIN_CHECKS])]) 8438238106Sdesm4_ifndef([_LT_AC_PROG_CXXCPP], [AC_DEFUN([_LT_AC_PROG_CXXCPP])]) 8439238106Sdesm4_ifndef([_LT_PREPARE_SED_QUOTE_VARS], [AC_DEFUN([_LT_PREPARE_SED_QUOTE_VARS])]) 8440238106Sdesm4_ifndef([_LT_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_PROG_ECHO_BACKSLASH])]) 8441238106Sdesm4_ifndef([_LT_PROG_F77], [AC_DEFUN([_LT_PROG_F77])]) 8442238106Sdesm4_ifndef([_LT_PROG_FC], [AC_DEFUN([_LT_PROG_FC])]) 8443238106Sdesm4_ifndef([_LT_PROG_CXX], [AC_DEFUN([_LT_PROG_CXX])]) 8444238106Sdes 8445