1247738Sbapt# generated automatically by aclocal 1.11.1 -*- Autoconf -*- 2247738Sbapt 3247738Sbapt# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 4247738Sbapt# 2005, 2006, 2007, 2008, 2009 Free Software Foundation, Inc. 5247738Sbapt# This file is free software; the Free Software Foundation 6247738Sbapt# gives unlimited permission to copy and/or distribute it, 7247738Sbapt# with or without modifications, as long as this notice is preserved. 8247738Sbapt 9247738Sbapt# This program is distributed in the hope that it will be useful, 10247738Sbapt# but WITHOUT ANY WARRANTY, to the extent permitted by law; without 11247738Sbapt# even the implied warranty of MERCHANTABILITY or FITNESS FOR A 12247738Sbapt# PARTICULAR PURPOSE. 13247738Sbapt 14247738Sbaptm4_ifndef([AC_AUTOCONF_VERSION], 15247738Sbapt [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl 16247738Sbaptm4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.67],, 17247738Sbapt[m4_warning([this file was generated for autoconf 2.67. 18247738SbaptYou have another version of autoconf. It may work, but is not guaranteed to. 19247738SbaptIf you have problems, you may need to regenerate the build system entirely. 20247738SbaptTo do so, use the procedure documented by the package, typically `autoreconf'.])]) 21247738Sbapt 22247738Sbapt# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*- 23247738Sbapt# 24247738Sbapt# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 25247738Sbapt# 2006, 2007, 2008 Free Software Foundation, Inc. 26247738Sbapt# Written by Gordon Matzigkeit, 1996 27247738Sbapt# 28247738Sbapt# This file is free software; the Free Software Foundation gives 29247738Sbapt# unlimited permission to copy and/or distribute it, with or without 30247738Sbapt# modifications, as long as this notice is preserved. 31247738Sbapt 32247738Sbaptm4_define([_LT_COPYING], [dnl 33247738Sbapt# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 34247738Sbapt# 2006, 2007, 2008 Free Software Foundation, Inc. 35247738Sbapt# Written by Gordon Matzigkeit, 1996 36247738Sbapt# 37247738Sbapt# This file is part of GNU Libtool. 38247738Sbapt# 39247738Sbapt# GNU Libtool is free software; you can redistribute it and/or 40247738Sbapt# modify it under the terms of the GNU General Public License as 41247738Sbapt# published by the Free Software Foundation; either version 2 of 42247738Sbapt# the License, or (at your option) any later version. 43247738Sbapt# 44247738Sbapt# As a special exception to the GNU General Public License, 45247738Sbapt# if you distribute this file as part of a program or library that 46247738Sbapt# is built using GNU Libtool, you may include this file under the 47247738Sbapt# same distribution terms that you use for the rest of that program. 48247738Sbapt# 49247738Sbapt# GNU Libtool is distributed in the hope that it will be useful, 50247738Sbapt# but WITHOUT ANY WARRANTY; without even the implied warranty of 51247738Sbapt# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 52247738Sbapt# GNU General Public License for more details. 53247738Sbapt# 54247738Sbapt# You should have received a copy of the GNU General Public License 55247738Sbapt# along with GNU Libtool; see the file COPYING. If not, a copy 56247738Sbapt# can be downloaded from http://www.gnu.org/licenses/gpl.html, or 57247738Sbapt# obtained by writing to the Free Software Foundation, Inc., 58247738Sbapt# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 59247738Sbapt]) 60247738Sbapt 61247738Sbapt# serial 56 LT_INIT 62247738Sbapt 63247738Sbapt 64247738Sbapt# LT_PREREQ(VERSION) 65247738Sbapt# ------------------ 66247738Sbapt# Complain and exit if this libtool version is less that VERSION. 67247738Sbaptm4_defun([LT_PREREQ], 68247738Sbapt[m4_if(m4_version_compare(m4_defn([LT_PACKAGE_VERSION]), [$1]), -1, 69247738Sbapt [m4_default([$3], 70247738Sbapt [m4_fatal([Libtool version $1 or higher is required], 71247738Sbapt 63)])], 72247738Sbapt [$2])]) 73247738Sbapt 74247738Sbapt 75247738Sbapt# _LT_CHECK_BUILDDIR 76247738Sbapt# ------------------ 77247738Sbapt# Complain if the absolute build directory name contains unusual characters 78247738Sbaptm4_defun([_LT_CHECK_BUILDDIR], 79247738Sbapt[case `pwd` in 80247738Sbapt *\ * | *\ *) 81247738Sbapt AC_MSG_WARN([Libtool does not cope well with whitespace in `pwd`]) ;; 82247738Sbaptesac 83247738Sbapt]) 84247738Sbapt 85247738Sbapt 86247738Sbapt# LT_INIT([OPTIONS]) 87247738Sbapt# ------------------ 88247738SbaptAC_DEFUN([LT_INIT], 89247738Sbapt[AC_PREREQ([2.58])dnl We use AC_INCLUDES_DEFAULT 90247738SbaptAC_BEFORE([$0], [LT_LANG])dnl 91247738SbaptAC_BEFORE([$0], [LT_OUTPUT])dnl 92247738SbaptAC_BEFORE([$0], [LTDL_INIT])dnl 93247738Sbaptm4_require([_LT_CHECK_BUILDDIR])dnl 94247738Sbapt 95247738Sbaptdnl Autoconf doesn't catch unexpanded LT_ macros by default: 96247738Sbaptm4_pattern_forbid([^_?LT_[A-Z_]+$])dnl 97247738Sbaptm4_pattern_allow([^(_LT_EOF|LT_DLGLOBAL|LT_DLLAZY_OR_NOW|LT_MULTI_MODULE)$])dnl 98247738Sbaptdnl aclocal doesn't pull ltoptions.m4, ltsugar.m4, or ltversion.m4 99247738Sbaptdnl unless we require an AC_DEFUNed macro: 100247738SbaptAC_REQUIRE([LTOPTIONS_VERSION])dnl 101247738SbaptAC_REQUIRE([LTSUGAR_VERSION])dnl 102247738SbaptAC_REQUIRE([LTVERSION_VERSION])dnl 103247738SbaptAC_REQUIRE([LTOBSOLETE_VERSION])dnl 104247738Sbaptm4_require([_LT_PROG_LTMAIN])dnl 105247738Sbapt 106247738Sbaptdnl Parse OPTIONS 107247738Sbapt_LT_SET_OPTIONS([$0], [$1]) 108247738Sbapt 109247738Sbapt# This can be used to rebuild libtool when needed 110247738SbaptLIBTOOL_DEPS="$ltmain" 111247738Sbapt 112247738Sbapt# Always use our own libtool. 113247738SbaptLIBTOOL='$(SHELL) $(top_builddir)/libtool' 114247738SbaptAC_SUBST(LIBTOOL)dnl 115247738Sbapt 116247738Sbapt_LT_SETUP 117247738Sbapt 118247738Sbapt# Only expand once: 119247738Sbaptm4_define([LT_INIT]) 120247738Sbapt])# LT_INIT 121247738Sbapt 122247738Sbapt# Old names: 123247738SbaptAU_ALIAS([AC_PROG_LIBTOOL], [LT_INIT]) 124247738SbaptAU_ALIAS([AM_PROG_LIBTOOL], [LT_INIT]) 125247738Sbaptdnl aclocal-1.4 backwards compatibility: 126247738Sbaptdnl AC_DEFUN([AC_PROG_LIBTOOL], []) 127247738Sbaptdnl AC_DEFUN([AM_PROG_LIBTOOL], []) 128247738Sbapt 129247738Sbapt 130247738Sbapt# _LT_CC_BASENAME(CC) 131247738Sbapt# ------------------- 132247738Sbapt# Calculate cc_basename. Skip known compiler wrappers and cross-prefix. 133247738Sbaptm4_defun([_LT_CC_BASENAME], 134247738Sbapt[for cc_temp in $1""; do 135247738Sbapt case $cc_temp in 136247738Sbapt compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;; 137247738Sbapt distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;; 138247738Sbapt \-*) ;; 139247738Sbapt *) break;; 140247738Sbapt esac 141247738Sbaptdone 142247738Sbaptcc_basename=`$ECHO "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` 143247738Sbapt]) 144247738Sbapt 145247738Sbapt 146247738Sbapt# _LT_FILEUTILS_DEFAULTS 147247738Sbapt# ---------------------- 148247738Sbapt# It is okay to use these file commands and assume they have been set 149247738Sbapt# sensibly after `m4_require([_LT_FILEUTILS_DEFAULTS])'. 150247738Sbaptm4_defun([_LT_FILEUTILS_DEFAULTS], 151247738Sbapt[: ${CP="cp -f"} 152247738Sbapt: ${MV="mv -f"} 153247738Sbapt: ${RM="rm -f"} 154247738Sbapt])# _LT_FILEUTILS_DEFAULTS 155247738Sbapt 156247738Sbapt 157247738Sbapt# _LT_SETUP 158247738Sbapt# --------- 159247738Sbaptm4_defun([_LT_SETUP], 160247738Sbapt[AC_REQUIRE([AC_CANONICAL_HOST])dnl 161247738SbaptAC_REQUIRE([AC_CANONICAL_BUILD])dnl 162247738Sbapt_LT_DECL([], [host_alias], [0], [The host system])dnl 163247738Sbapt_LT_DECL([], [host], [0])dnl 164247738Sbapt_LT_DECL([], [host_os], [0])dnl 165247738Sbaptdnl 166247738Sbapt_LT_DECL([], [build_alias], [0], [The build system])dnl 167247738Sbapt_LT_DECL([], [build], [0])dnl 168247738Sbapt_LT_DECL([], [build_os], [0])dnl 169247738Sbaptdnl 170247738SbaptAC_REQUIRE([AC_PROG_CC])dnl 171247738SbaptAC_REQUIRE([LT_PATH_LD])dnl 172247738SbaptAC_REQUIRE([LT_PATH_NM])dnl 173247738Sbaptdnl 174247738SbaptAC_REQUIRE([AC_PROG_LN_S])dnl 175247738Sbapttest -z "$LN_S" && LN_S="ln -s" 176247738Sbapt_LT_DECL([], [LN_S], [1], [Whether we need soft or hard links])dnl 177247738Sbaptdnl 178247738SbaptAC_REQUIRE([LT_CMD_MAX_LEN])dnl 179247738Sbapt_LT_DECL([objext], [ac_objext], [0], [Object file suffix (normally "o")])dnl 180247738Sbapt_LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl 181247738Sbaptdnl 182247738Sbaptm4_require([_LT_FILEUTILS_DEFAULTS])dnl 183247738Sbaptm4_require([_LT_CHECK_SHELL_FEATURES])dnl 184247738Sbaptm4_require([_LT_CMD_RELOAD])dnl 185247738Sbaptm4_require([_LT_CHECK_MAGIC_METHOD])dnl 186247738Sbaptm4_require([_LT_CMD_OLD_ARCHIVE])dnl 187247738Sbaptm4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl 188247738Sbapt 189247738Sbapt_LT_CONFIG_LIBTOOL_INIT([ 190247738Sbapt# See if we are running on zsh, and set the options which allow our 191247738Sbapt# commands through without removal of \ escapes INIT. 192247738Sbaptif test -n "\${ZSH_VERSION+set}" ; then 193247738Sbapt setopt NO_GLOB_SUBST 194247738Sbaptfi 195247738Sbapt]) 196247738Sbaptif test -n "${ZSH_VERSION+set}" ; then 197247738Sbapt setopt NO_GLOB_SUBST 198247738Sbaptfi 199247738Sbapt 200247738Sbapt_LT_CHECK_OBJDIR 201247738Sbapt 202247738Sbaptm4_require([_LT_TAG_COMPILER])dnl 203247738Sbapt_LT_PROG_ECHO_BACKSLASH 204247738Sbapt 205247738Sbaptcase $host_os in 206247738Sbaptaix3*) 207247738Sbapt # AIX sometimes has problems with the GCC collect2 program. For some 208247738Sbapt # reason, if we set the COLLECT_NAMES environment variable, the problems 209247738Sbapt # vanish in a puff of smoke. 210247738Sbapt if test "X${COLLECT_NAMES+set}" != Xset; then 211247738Sbapt COLLECT_NAMES= 212247738Sbapt export COLLECT_NAMES 213247738Sbapt fi 214247738Sbapt ;; 215247738Sbaptesac 216247738Sbapt 217247738Sbapt# Sed substitution that helps us do robust quoting. It backslashifies 218247738Sbapt# metacharacters that are still active within double-quoted strings. 219247738Sbaptsed_quote_subst='s/\([["`$\\]]\)/\\\1/g' 220247738Sbapt 221247738Sbapt# Same as above, but do not quote variable references. 222247738Sbaptdouble_quote_subst='s/\([["`\\]]\)/\\\1/g' 223247738Sbapt 224247738Sbapt# Sed substitution to delay expansion of an escaped shell variable in a 225247738Sbapt# double_quote_subst'ed string. 226247738Sbaptdelay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' 227247738Sbapt 228247738Sbapt# Sed substitution to delay expansion of an escaped single quote. 229247738Sbaptdelay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g' 230247738Sbapt 231247738Sbapt# Sed substitution to avoid accidental globbing in evaled expressions 232247738Sbaptno_glob_subst='s/\*/\\\*/g' 233247738Sbapt 234247738Sbapt# Global variables: 235247738Sbaptofile=libtool 236247738Sbaptcan_build_shared=yes 237247738Sbapt 238247738Sbapt# All known linkers require a `.a' archive for static linking (except MSVC, 239247738Sbapt# which needs '.lib'). 240247738Sbaptlibext=a 241247738Sbapt 242247738Sbaptwith_gnu_ld="$lt_cv_prog_gnu_ld" 243247738Sbapt 244247738Sbaptold_CC="$CC" 245247738Sbaptold_CFLAGS="$CFLAGS" 246247738Sbapt 247247738Sbapt# Set sane defaults for various variables 248247738Sbapttest -z "$CC" && CC=cc 249247738Sbapttest -z "$LTCC" && LTCC=$CC 250247738Sbapttest -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS 251247738Sbapttest -z "$LD" && LD=ld 252247738Sbapttest -z "$ac_objext" && ac_objext=o 253247738Sbapt 254247738Sbapt_LT_CC_BASENAME([$compiler]) 255247738Sbapt 256247738Sbapt# Only perform the check for file, if the check method requires it 257247738Sbapttest -z "$MAGIC_CMD" && MAGIC_CMD=file 258247738Sbaptcase $deplibs_check_method in 259247738Sbaptfile_magic*) 260247738Sbapt if test "$file_magic_cmd" = '$MAGIC_CMD'; then 261247738Sbapt _LT_PATH_MAGIC 262247738Sbapt fi 263247738Sbapt ;; 264247738Sbaptesac 265247738Sbapt 266247738Sbapt# Use C for the default configuration in the libtool script 267247738SbaptLT_SUPPORTED_TAG([CC]) 268247738Sbapt_LT_LANG_C_CONFIG 269247738Sbapt_LT_LANG_DEFAULT_CONFIG 270247738Sbapt_LT_CONFIG_COMMANDS 271247738Sbapt])# _LT_SETUP 272247738Sbapt 273247738Sbapt 274247738Sbapt# _LT_PROG_LTMAIN 275247738Sbapt# --------------- 276247738Sbapt# Note that this code is called both from `configure', and `config.status' 277247738Sbapt# now that we use AC_CONFIG_COMMANDS to generate libtool. Notably, 278247738Sbapt# `config.status' has no value for ac_aux_dir unless we are using Automake, 279247738Sbapt# so we pass a copy along to make sure it has a sensible value anyway. 280247738Sbaptm4_defun([_LT_PROG_LTMAIN], 281247738Sbapt[m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl 282247738Sbapt_LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir']) 283247738Sbaptltmain="$ac_aux_dir/ltmain.sh" 284247738Sbapt])# _LT_PROG_LTMAIN 285247738Sbapt 286247738Sbapt 287247738Sbapt 288247738Sbapt# So that we can recreate a full libtool script including additional 289247738Sbapt# tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS 290247738Sbapt# in macros and then make a single call at the end using the `libtool' 291247738Sbapt# label. 292247738Sbapt 293247738Sbapt 294247738Sbapt# _LT_CONFIG_LIBTOOL_INIT([INIT-COMMANDS]) 295247738Sbapt# ---------------------------------------- 296247738Sbapt# Register INIT-COMMANDS to be passed to AC_CONFIG_COMMANDS later. 297247738Sbaptm4_define([_LT_CONFIG_LIBTOOL_INIT], 298247738Sbapt[m4_ifval([$1], 299247738Sbapt [m4_append([_LT_OUTPUT_LIBTOOL_INIT], 300247738Sbapt [$1 301247738Sbapt])])]) 302247738Sbapt 303247738Sbapt# Initialize. 304247738Sbaptm4_define([_LT_OUTPUT_LIBTOOL_INIT]) 305247738Sbapt 306247738Sbapt 307247738Sbapt# _LT_CONFIG_LIBTOOL([COMMANDS]) 308247738Sbapt# ------------------------------ 309247738Sbapt# Register COMMANDS to be passed to AC_CONFIG_COMMANDS later. 310247738Sbaptm4_define([_LT_CONFIG_LIBTOOL], 311247738Sbapt[m4_ifval([$1], 312247738Sbapt [m4_append([_LT_OUTPUT_LIBTOOL_COMMANDS], 313247738Sbapt [$1 314247738Sbapt])])]) 315247738Sbapt 316247738Sbapt# Initialize. 317247738Sbaptm4_define([_LT_OUTPUT_LIBTOOL_COMMANDS]) 318247738Sbapt 319247738Sbapt 320247738Sbapt# _LT_CONFIG_SAVE_COMMANDS([COMMANDS], [INIT_COMMANDS]) 321247738Sbapt# ----------------------------------------------------- 322247738Sbaptm4_defun([_LT_CONFIG_SAVE_COMMANDS], 323247738Sbapt[_LT_CONFIG_LIBTOOL([$1]) 324247738Sbapt_LT_CONFIG_LIBTOOL_INIT([$2]) 325247738Sbapt]) 326247738Sbapt 327247738Sbapt 328247738Sbapt# _LT_FORMAT_COMMENT([COMMENT]) 329247738Sbapt# ----------------------------- 330247738Sbapt# Add leading comment marks to the start of each line, and a trailing 331247738Sbapt# full-stop to the whole comment if one is not present already. 332247738Sbaptm4_define([_LT_FORMAT_COMMENT], 333247738Sbapt[m4_ifval([$1], [ 334247738Sbaptm4_bpatsubst([m4_bpatsubst([$1], [^ *], [# ])], 335247738Sbapt [['`$\]], [\\\&])]m4_bmatch([$1], [[!?.]$], [], [.]) 336247738Sbapt)]) 337247738Sbapt 338247738Sbapt 339247738Sbapt 340247738Sbapt 341247738Sbapt 342247738Sbapt# _LT_DECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION], [IS-TAGGED?]) 343247738Sbapt# ------------------------------------------------------------------- 344247738Sbapt# CONFIGNAME is the name given to the value in the libtool script. 345247738Sbapt# VARNAME is the (base) name used in the configure script. 346247738Sbapt# VALUE may be 0, 1 or 2 for a computed quote escaped value based on 347247738Sbapt# VARNAME. Any other value will be used directly. 348247738Sbaptm4_define([_LT_DECL], 349247738Sbapt[lt_if_append_uniq([lt_decl_varnames], [$2], [, ], 350247738Sbapt [lt_dict_add_subkey([lt_decl_dict], [$2], [libtool_name], 351247738Sbapt [m4_ifval([$1], [$1], [$2])]) 352247738Sbapt lt_dict_add_subkey([lt_decl_dict], [$2], [value], [$3]) 353247738Sbapt m4_ifval([$4], 354247738Sbapt [lt_dict_add_subkey([lt_decl_dict], [$2], [description], [$4])]) 355247738Sbapt lt_dict_add_subkey([lt_decl_dict], [$2], 356247738Sbapt [tagged?], [m4_ifval([$5], [yes], [no])])]) 357247738Sbapt]) 358247738Sbapt 359247738Sbapt 360247738Sbapt# _LT_TAGDECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION]) 361247738Sbapt# -------------------------------------------------------- 362247738Sbaptm4_define([_LT_TAGDECL], [_LT_DECL([$1], [$2], [$3], [$4], [yes])]) 363247738Sbapt 364247738Sbapt 365247738Sbapt# lt_decl_tag_varnames([SEPARATOR], [VARNAME1...]) 366247738Sbapt# ------------------------------------------------ 367247738Sbaptm4_define([lt_decl_tag_varnames], 368247738Sbapt[_lt_decl_filter([tagged?], [yes], $@)]) 369247738Sbapt 370247738Sbapt 371247738Sbapt# _lt_decl_filter(SUBKEY, VALUE, [SEPARATOR], [VARNAME1..]) 372247738Sbapt# --------------------------------------------------------- 373247738Sbaptm4_define([_lt_decl_filter], 374247738Sbapt[m4_case([$#], 375247738Sbapt [0], [m4_fatal([$0: too few arguments: $#])], 376247738Sbapt [1], [m4_fatal([$0: too few arguments: $#: $1])], 377247738Sbapt [2], [lt_dict_filter([lt_decl_dict], [$1], [$2], [], lt_decl_varnames)], 378247738Sbapt [3], [lt_dict_filter([lt_decl_dict], [$1], [$2], [$3], lt_decl_varnames)], 379247738Sbapt [lt_dict_filter([lt_decl_dict], $@)])[]dnl 380247738Sbapt]) 381247738Sbapt 382247738Sbapt 383247738Sbapt# lt_decl_quote_varnames([SEPARATOR], [VARNAME1...]) 384247738Sbapt# -------------------------------------------------- 385247738Sbaptm4_define([lt_decl_quote_varnames], 386247738Sbapt[_lt_decl_filter([value], [1], $@)]) 387247738Sbapt 388247738Sbapt 389247738Sbapt# lt_decl_dquote_varnames([SEPARATOR], [VARNAME1...]) 390247738Sbapt# --------------------------------------------------- 391247738Sbaptm4_define([lt_decl_dquote_varnames], 392247738Sbapt[_lt_decl_filter([value], [2], $@)]) 393247738Sbapt 394247738Sbapt 395247738Sbapt# lt_decl_varnames_tagged([SEPARATOR], [VARNAME1...]) 396247738Sbapt# --------------------------------------------------- 397247738Sbaptm4_define([lt_decl_varnames_tagged], 398247738Sbapt[m4_assert([$# <= 2])dnl 399247738Sbapt_$0(m4_quote(m4_default([$1], [[, ]])), 400247738Sbapt m4_ifval([$2], [[$2]], [m4_dquote(lt_decl_tag_varnames)]), 401247738Sbapt m4_split(m4_normalize(m4_quote(_LT_TAGS)), [ ]))]) 402247738Sbaptm4_define([_lt_decl_varnames_tagged], 403247738Sbapt[m4_ifval([$3], [lt_combine([$1], [$2], [_], $3)])]) 404247738Sbapt 405247738Sbapt 406247738Sbapt# lt_decl_all_varnames([SEPARATOR], [VARNAME1...]) 407247738Sbapt# ------------------------------------------------ 408247738Sbaptm4_define([lt_decl_all_varnames], 409247738Sbapt[_$0(m4_quote(m4_default([$1], [[, ]])), 410247738Sbapt m4_if([$2], [], 411247738Sbapt m4_quote(lt_decl_varnames), 412247738Sbapt m4_quote(m4_shift($@))))[]dnl 413247738Sbapt]) 414247738Sbaptm4_define([_lt_decl_all_varnames], 415247738Sbapt[lt_join($@, lt_decl_varnames_tagged([$1], 416247738Sbapt lt_decl_tag_varnames([[, ]], m4_shift($@))))dnl 417247738Sbapt]) 418247738Sbapt 419247738Sbapt 420247738Sbapt# _LT_CONFIG_STATUS_DECLARE([VARNAME]) 421247738Sbapt# ------------------------------------ 422247738Sbapt# Quote a variable value, and forward it to `config.status' so that its 423247738Sbapt# declaration there will have the same value as in `configure'. VARNAME 424247738Sbapt# must have a single quote delimited value for this to work. 425247738Sbaptm4_define([_LT_CONFIG_STATUS_DECLARE], 426247738Sbapt[$1='`$ECHO "X$][$1" | $Xsed -e "$delay_single_quote_subst"`']) 427247738Sbapt 428247738Sbapt 429247738Sbapt# _LT_CONFIG_STATUS_DECLARATIONS 430247738Sbapt# ------------------------------ 431247738Sbapt# We delimit libtool config variables with single quotes, so when 432247738Sbapt# we write them to config.status, we have to be sure to quote all 433247738Sbapt# embedded single quotes properly. In configure, this macro expands 434247738Sbapt# each variable declared with _LT_DECL (and _LT_TAGDECL) into: 435247738Sbapt# 436247738Sbapt# <var>='`$ECHO "X$<var>" | $Xsed -e "$delay_single_quote_subst"`' 437247738Sbaptm4_defun([_LT_CONFIG_STATUS_DECLARATIONS], 438247738Sbapt[m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames), 439247738Sbapt [m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])]) 440247738Sbapt 441247738Sbapt 442247738Sbapt# _LT_LIBTOOL_TAGS 443247738Sbapt# ---------------- 444247738Sbapt# Output comment and list of tags supported by the script 445247738Sbaptm4_defun([_LT_LIBTOOL_TAGS], 446247738Sbapt[_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl 447247738Sbaptavailable_tags="_LT_TAGS"dnl 448247738Sbapt]) 449247738Sbapt 450247738Sbapt 451247738Sbapt# _LT_LIBTOOL_DECLARE(VARNAME, [TAG]) 452247738Sbapt# ----------------------------------- 453247738Sbapt# Extract the dictionary values for VARNAME (optionally with TAG) and 454247738Sbapt# expand to a commented shell variable setting: 455247738Sbapt# 456247738Sbapt# # Some comment about what VAR is for. 457247738Sbapt# visible_name=$lt_internal_name 458247738Sbaptm4_define([_LT_LIBTOOL_DECLARE], 459247738Sbapt[_LT_FORMAT_COMMENT(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], 460247738Sbapt [description])))[]dnl 461247738Sbaptm4_pushdef([_libtool_name], 462247738Sbapt m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [libtool_name])))[]dnl 463247738Sbaptm4_case(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [value])), 464247738Sbapt [0], [_libtool_name=[$]$1], 465247738Sbapt [1], [_libtool_name=$lt_[]$1], 466247738Sbapt [2], [_libtool_name=$lt_[]$1], 467247738Sbapt [_libtool_name=lt_dict_fetch([lt_decl_dict], [$1], [value])])[]dnl 468247738Sbaptm4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl 469247738Sbapt]) 470247738Sbapt 471247738Sbapt 472247738Sbapt# _LT_LIBTOOL_CONFIG_VARS 473247738Sbapt# ----------------------- 474247738Sbapt# Produce commented declarations of non-tagged libtool config variables 475247738Sbapt# suitable for insertion in the LIBTOOL CONFIG section of the `libtool' 476247738Sbapt# script. Tagged libtool config variables (even for the LIBTOOL CONFIG 477247738Sbapt# section) are produced by _LT_LIBTOOL_TAG_VARS. 478247738Sbaptm4_defun([_LT_LIBTOOL_CONFIG_VARS], 479247738Sbapt[m4_foreach([_lt_var], 480247738Sbapt m4_quote(_lt_decl_filter([tagged?], [no], [], lt_decl_varnames)), 481247738Sbapt [m4_n([_LT_LIBTOOL_DECLARE(_lt_var)])])]) 482247738Sbapt 483247738Sbapt 484247738Sbapt# _LT_LIBTOOL_TAG_VARS(TAG) 485247738Sbapt# ------------------------- 486247738Sbaptm4_define([_LT_LIBTOOL_TAG_VARS], 487247738Sbapt[m4_foreach([_lt_var], m4_quote(lt_decl_tag_varnames), 488247738Sbapt [m4_n([_LT_LIBTOOL_DECLARE(_lt_var, [$1])])])]) 489247738Sbapt 490247738Sbapt 491247738Sbapt# _LT_TAGVAR(VARNAME, [TAGNAME]) 492247738Sbapt# ------------------------------ 493247738Sbaptm4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])]) 494247738Sbapt 495247738Sbapt 496247738Sbapt# _LT_CONFIG_COMMANDS 497247738Sbapt# ------------------- 498247738Sbapt# Send accumulated output to $CONFIG_STATUS. Thanks to the lists of 499247738Sbapt# variables for single and double quote escaping we saved from calls 500247738Sbapt# to _LT_DECL, we can put quote escaped variables declarations 501247738Sbapt# into `config.status', and then the shell code to quote escape them in 502247738Sbapt# for loops in `config.status'. Finally, any additional code accumulated 503247738Sbapt# from calls to _LT_CONFIG_LIBTOOL_INIT is expanded. 504247738Sbaptm4_defun([_LT_CONFIG_COMMANDS], 505247738Sbapt[AC_PROVIDE_IFELSE([LT_OUTPUT], 506247738Sbapt dnl If the libtool generation code has been placed in $CONFIG_LT, 507247738Sbapt dnl instead of duplicating it all over again into config.status, 508247738Sbapt dnl then we will have config.status run $CONFIG_LT later, so it 509247738Sbapt dnl needs to know what name is stored there: 510247738Sbapt [AC_CONFIG_COMMANDS([libtool], 511247738Sbapt [$SHELL $CONFIG_LT || AS_EXIT(1)], [CONFIG_LT='$CONFIG_LT'])], 512247738Sbapt dnl If the libtool generation code is destined for config.status, 513247738Sbapt dnl expand the accumulated commands and init code now: 514247738Sbapt [AC_CONFIG_COMMANDS([libtool], 515247738Sbapt [_LT_OUTPUT_LIBTOOL_COMMANDS], [_LT_OUTPUT_LIBTOOL_COMMANDS_INIT])]) 516247738Sbapt])#_LT_CONFIG_COMMANDS 517247738Sbapt 518247738Sbapt 519247738Sbapt# Initialize. 520247738Sbaptm4_define([_LT_OUTPUT_LIBTOOL_COMMANDS_INIT], 521247738Sbapt[ 522247738Sbapt 523247738Sbapt# The HP-UX ksh and POSIX shell print the target directory to stdout 524247738Sbapt# if CDPATH is set. 525247738Sbapt(unset CDPATH) >/dev/null 2>&1 && unset CDPATH 526247738Sbapt 527247738Sbaptsed_quote_subst='$sed_quote_subst' 528247738Sbaptdouble_quote_subst='$double_quote_subst' 529247738Sbaptdelay_variable_subst='$delay_variable_subst' 530247738Sbapt_LT_CONFIG_STATUS_DECLARATIONS 531247738SbaptLTCC='$LTCC' 532247738SbaptLTCFLAGS='$LTCFLAGS' 533247738Sbaptcompiler='$compiler_DEFAULT' 534247738Sbapt 535247738Sbapt# Quote evaled strings. 536247738Sbaptfor var in lt_decl_all_varnames([[ \ 537247738Sbapt]], lt_decl_quote_varnames); do 538247738Sbapt case \`eval \\\\\$ECHO "X\\\\\$\$var"\` in 539247738Sbapt *[[\\\\\\\`\\"\\\$]]*) 540247738Sbapt eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"X\\\$\$var\\" | \\\$Xsed -e \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" 541247738Sbapt ;; 542247738Sbapt *) 543247738Sbapt eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" 544247738Sbapt ;; 545247738Sbapt esac 546247738Sbaptdone 547247738Sbapt 548247738Sbapt# Double-quote double-evaled strings. 549247738Sbaptfor var in lt_decl_all_varnames([[ \ 550247738Sbapt]], lt_decl_dquote_varnames); do 551247738Sbapt case \`eval \\\\\$ECHO "X\\\\\$\$var"\` in 552247738Sbapt *[[\\\\\\\`\\"\\\$]]*) 553247738Sbapt eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"X\\\$\$var\\" | \\\$Xsed -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" 554247738Sbapt ;; 555247738Sbapt *) 556247738Sbapt eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" 557247738Sbapt ;; 558247738Sbapt esac 559247738Sbaptdone 560247738Sbapt 561247738Sbapt# Fix-up fallback echo if it was mangled by the above quoting rules. 562247738Sbaptcase \$lt_ECHO in 563247738Sbapt*'\\\[$]0 --fallback-echo"')dnl " 564247738Sbapt lt_ECHO=\`\$ECHO "X\$lt_ECHO" | \$Xsed -e 's/\\\\\\\\\\\\\\\[$]0 --fallback-echo"\[$]/\[$]0 --fallback-echo"/'\` 565247738Sbapt ;; 566247738Sbaptesac 567247738Sbapt 568247738Sbapt_LT_OUTPUT_LIBTOOL_INIT 569247738Sbapt]) 570247738Sbapt 571247738Sbapt 572247738Sbapt# LT_OUTPUT 573247738Sbapt# --------- 574247738Sbapt# This macro allows early generation of the libtool script (before 575247738Sbapt# AC_OUTPUT is called), incase it is used in configure for compilation 576247738Sbapt# tests. 577247738SbaptAC_DEFUN([LT_OUTPUT], 578247738Sbapt[: ${CONFIG_LT=./config.lt} 579247738SbaptAC_MSG_NOTICE([creating $CONFIG_LT]) 580247738Sbaptcat >"$CONFIG_LT" <<_LTEOF 581247738Sbapt#! $SHELL 582247738Sbapt# Generated by $as_me. 583247738Sbapt# Run this file to recreate a libtool stub with the current configuration. 584247738Sbapt 585247738Sbaptlt_cl_silent=false 586247738SbaptSHELL=\${CONFIG_SHELL-$SHELL} 587247738Sbapt_LTEOF 588247738Sbapt 589247738Sbaptcat >>"$CONFIG_LT" <<\_LTEOF 590247738SbaptAS_SHELL_SANITIZE 591247738Sbapt_AS_PREPARE 592247738Sbapt 593247738Sbaptexec AS_MESSAGE_FD>&1 594247738Sbaptexec AS_MESSAGE_LOG_FD>>config.log 595247738Sbapt{ 596247738Sbapt echo 597247738Sbapt AS_BOX([Running $as_me.]) 598247738Sbapt} >&AS_MESSAGE_LOG_FD 599247738Sbapt 600247738Sbaptlt_cl_help="\ 601247738Sbapt\`$as_me' creates a local libtool stub from the current configuration, 602247738Sbaptfor use in further configure time tests before the real libtool is 603247738Sbaptgenerated. 604247738Sbapt 605247738SbaptUsage: $[0] [[OPTIONS]] 606247738Sbapt 607247738Sbapt -h, --help print this help, then exit 608247738Sbapt -V, --version print version number, then exit 609247738Sbapt -q, --quiet do not print progress messages 610247738Sbapt -d, --debug don't remove temporary files 611247738Sbapt 612247738SbaptReport bugs to <bug-libtool@gnu.org>." 613247738Sbapt 614247738Sbaptlt_cl_version="\ 615247738Sbaptm4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl 616247738Sbaptm4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION]) 617247738Sbaptconfigured by $[0], generated by m4_PACKAGE_STRING. 618247738Sbapt 619247738SbaptCopyright (C) 2008 Free Software Foundation, Inc. 620247738SbaptThis config.lt script is free software; the Free Software Foundation 621247738Sbaptgives unlimited permision to copy, distribute and modify it." 622247738Sbapt 623247738Sbaptwhile test $[#] != 0 624247738Sbaptdo 625247738Sbapt case $[1] in 626247738Sbapt --version | --v* | -V ) 627247738Sbapt echo "$lt_cl_version"; exit 0 ;; 628247738Sbapt --help | --h* | -h ) 629247738Sbapt echo "$lt_cl_help"; exit 0 ;; 630247738Sbapt --debug | --d* | -d ) 631247738Sbapt debug=: ;; 632247738Sbapt --quiet | --q* | --silent | --s* | -q ) 633247738Sbapt lt_cl_silent=: ;; 634247738Sbapt 635247738Sbapt -*) AC_MSG_ERROR([unrecognized option: $[1] 636247738SbaptTry \`$[0] --help' for more information.]) ;; 637247738Sbapt 638247738Sbapt *) AC_MSG_ERROR([unrecognized argument: $[1] 639247738SbaptTry \`$[0] --help' for more information.]) ;; 640247738Sbapt esac 641247738Sbapt shift 642247738Sbaptdone 643247738Sbapt 644247738Sbaptif $lt_cl_silent; then 645247738Sbapt exec AS_MESSAGE_FD>/dev/null 646247738Sbaptfi 647247738Sbapt_LTEOF 648247738Sbapt 649247738Sbaptcat >>"$CONFIG_LT" <<_LTEOF 650247738Sbapt_LT_OUTPUT_LIBTOOL_COMMANDS_INIT 651247738Sbapt_LTEOF 652247738Sbapt 653247738Sbaptcat >>"$CONFIG_LT" <<\_LTEOF 654247738SbaptAC_MSG_NOTICE([creating $ofile]) 655247738Sbapt_LT_OUTPUT_LIBTOOL_COMMANDS 656247738SbaptAS_EXIT(0) 657247738Sbapt_LTEOF 658247738Sbaptchmod +x "$CONFIG_LT" 659247738Sbapt 660247738Sbapt# configure is writing to config.log, but config.lt does its own redirection, 661247738Sbapt# appending to config.log, which fails on DOS, as config.log is still kept 662247738Sbapt# open by configure. Here we exec the FD to /dev/null, effectively closing 663247738Sbapt# config.log, so it can be properly (re)opened and appended to by config.lt. 664247738Sbaptif test "$no_create" != yes; then 665247738Sbapt lt_cl_success=: 666247738Sbapt test "$silent" = yes && 667247738Sbapt lt_config_lt_args="$lt_config_lt_args --quiet" 668247738Sbapt exec AS_MESSAGE_LOG_FD>/dev/null 669247738Sbapt $SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false 670247738Sbapt exec AS_MESSAGE_LOG_FD>>config.log 671247738Sbapt $lt_cl_success || AS_EXIT(1) 672247738Sbaptfi 673247738Sbapt])# LT_OUTPUT 674247738Sbapt 675247738Sbapt 676247738Sbapt# _LT_CONFIG(TAG) 677247738Sbapt# --------------- 678247738Sbapt# If TAG is the built-in tag, create an initial libtool script with a 679247738Sbapt# default configuration from the untagged config vars. Otherwise add code 680247738Sbapt# to config.status for appending the configuration named by TAG from the 681247738Sbapt# matching tagged config vars. 682247738Sbaptm4_defun([_LT_CONFIG], 683247738Sbapt[m4_require([_LT_FILEUTILS_DEFAULTS])dnl 684247738Sbapt_LT_CONFIG_SAVE_COMMANDS([ 685247738Sbapt m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl 686247738Sbapt m4_if(_LT_TAG, [C], [ 687247738Sbapt # See if we are running on zsh, and set the options which allow our 688247738Sbapt # commands through without removal of \ escapes. 689247738Sbapt if test -n "${ZSH_VERSION+set}" ; then 690247738Sbapt setopt NO_GLOB_SUBST 691247738Sbapt fi 692247738Sbapt 693247738Sbapt cfgfile="${ofile}T" 694247738Sbapt trap "$RM \"$cfgfile\"; exit 1" 1 2 15 695247738Sbapt $RM "$cfgfile" 696247738Sbapt 697247738Sbapt cat <<_LT_EOF >> "$cfgfile" 698247738Sbapt#! $SHELL 699247738Sbapt 700247738Sbapt# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services. 701247738Sbapt# Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION 702247738Sbapt# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: 703247738Sbapt# NOTE: Changes made to this file will be lost: look at ltmain.sh. 704247738Sbapt# 705247738Sbapt_LT_COPYING 706247738Sbapt_LT_LIBTOOL_TAGS 707247738Sbapt 708247738Sbapt# ### BEGIN LIBTOOL CONFIG 709247738Sbapt_LT_LIBTOOL_CONFIG_VARS 710247738Sbapt_LT_LIBTOOL_TAG_VARS 711247738Sbapt# ### END LIBTOOL CONFIG 712247738Sbapt 713247738Sbapt_LT_EOF 714247738Sbapt 715247738Sbapt case $host_os in 716247738Sbapt aix3*) 717247738Sbapt cat <<\_LT_EOF >> "$cfgfile" 718247738Sbapt# AIX sometimes has problems with the GCC collect2 program. For some 719247738Sbapt# reason, if we set the COLLECT_NAMES environment variable, the problems 720247738Sbapt# vanish in a puff of smoke. 721247738Sbaptif test "X${COLLECT_NAMES+set}" != Xset; then 722247738Sbapt COLLECT_NAMES= 723247738Sbapt export COLLECT_NAMES 724247738Sbaptfi 725247738Sbapt_LT_EOF 726247738Sbapt ;; 727247738Sbapt esac 728247738Sbapt 729247738Sbapt _LT_PROG_LTMAIN 730247738Sbapt 731247738Sbapt # We use sed instead of cat because bash on DJGPP gets confused if 732247738Sbapt # if finds mixed CR/LF and LF-only lines. Since sed operates in 733247738Sbapt # text mode, it properly converts lines to CR/LF. This bash problem 734247738Sbapt # is reportedly fixed, but why not run on old versions too? 735247738Sbapt sed '/^# Generated shell functions inserted here/q' "$ltmain" >> "$cfgfile" \ 736247738Sbapt || (rm -f "$cfgfile"; exit 1) 737247738Sbapt 738247738Sbapt _LT_PROG_XSI_SHELLFNS 739247738Sbapt 740247738Sbapt sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \ 741247738Sbapt || (rm -f "$cfgfile"; exit 1) 742247738Sbapt 743247738Sbapt mv -f "$cfgfile" "$ofile" || 744247738Sbapt (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") 745247738Sbapt chmod +x "$ofile" 746247738Sbapt], 747247738Sbapt[cat <<_LT_EOF >> "$ofile" 748247738Sbapt 749247738Sbaptdnl Unfortunately we have to use $1 here, since _LT_TAG is not expanded 750247738Sbaptdnl in a comment (ie after a #). 751247738Sbapt# ### BEGIN LIBTOOL TAG CONFIG: $1 752247738Sbapt_LT_LIBTOOL_TAG_VARS(_LT_TAG) 753247738Sbapt# ### END LIBTOOL TAG CONFIG: $1 754247738Sbapt_LT_EOF 755247738Sbapt])dnl /m4_if 756247738Sbapt], 757247738Sbapt[m4_if([$1], [], [ 758247738Sbapt PACKAGE='$PACKAGE' 759247738Sbapt VERSION='$VERSION' 760247738Sbapt TIMESTAMP='$TIMESTAMP' 761247738Sbapt RM='$RM' 762247738Sbapt ofile='$ofile'], []) 763247738Sbapt])dnl /_LT_CONFIG_SAVE_COMMANDS 764247738Sbapt])# _LT_CONFIG 765247738Sbapt 766247738Sbapt 767247738Sbapt# LT_SUPPORTED_TAG(TAG) 768247738Sbapt# --------------------- 769247738Sbapt# Trace this macro to discover what tags are supported by the libtool 770247738Sbapt# --tag option, using: 771247738Sbapt# autoconf --trace 'LT_SUPPORTED_TAG:$1' 772247738SbaptAC_DEFUN([LT_SUPPORTED_TAG], []) 773247738Sbapt 774247738Sbapt 775247738Sbapt# C support is built-in for now 776247738Sbaptm4_define([_LT_LANG_C_enabled], []) 777247738Sbaptm4_define([_LT_TAGS], []) 778247738Sbapt 779247738Sbapt 780247738Sbapt# LT_LANG(LANG) 781247738Sbapt# ------------- 782247738Sbapt# Enable libtool support for the given language if not already enabled. 783247738SbaptAC_DEFUN([LT_LANG], 784247738Sbapt[AC_BEFORE([$0], [LT_OUTPUT])dnl 785247738Sbaptm4_case([$1], 786247738Sbapt [C], [_LT_LANG(C)], 787247738Sbapt [C++], [_LT_LANG(CXX)], 788247738Sbapt [Java], [_LT_LANG(GCJ)], 789247738Sbapt [Fortran 77], [_LT_LANG(F77)], 790247738Sbapt [Fortran], [_LT_LANG(FC)], 791247738Sbapt [Windows Resource], [_LT_LANG(RC)], 792247738Sbapt [m4_ifdef([_LT_LANG_]$1[_CONFIG], 793247738Sbapt [_LT_LANG($1)], 794247738Sbapt [m4_fatal([$0: unsupported language: "$1"])])])dnl 795247738Sbapt])# LT_LANG 796247738Sbapt 797247738Sbapt 798247738Sbapt# _LT_LANG(LANGNAME) 799247738Sbapt# ------------------ 800247738Sbaptm4_defun([_LT_LANG], 801247738Sbapt[m4_ifdef([_LT_LANG_]$1[_enabled], [], 802247738Sbapt [LT_SUPPORTED_TAG([$1])dnl 803247738Sbapt m4_append([_LT_TAGS], [$1 ])dnl 804247738Sbapt m4_define([_LT_LANG_]$1[_enabled], [])dnl 805247738Sbapt _LT_LANG_$1_CONFIG($1)])dnl 806247738Sbapt])# _LT_LANG 807247738Sbapt 808247738Sbapt 809247738Sbapt# _LT_LANG_DEFAULT_CONFIG 810247738Sbapt# ----------------------- 811247738Sbaptm4_defun([_LT_LANG_DEFAULT_CONFIG], 812247738Sbapt[AC_PROVIDE_IFELSE([AC_PROG_CXX], 813247738Sbapt [LT_LANG(CXX)], 814247738Sbapt [m4_define([AC_PROG_CXX], defn([AC_PROG_CXX])[LT_LANG(CXX)])]) 815247738Sbapt 816247738SbaptAC_PROVIDE_IFELSE([AC_PROG_F77], 817247738Sbapt [LT_LANG(F77)], 818247738Sbapt [m4_define([AC_PROG_F77], defn([AC_PROG_F77])[LT_LANG(F77)])]) 819247738Sbapt 820247738SbaptAC_PROVIDE_IFELSE([AC_PROG_FC], 821247738Sbapt [LT_LANG(FC)], 822247738Sbapt [m4_define([AC_PROG_FC], defn([AC_PROG_FC])[LT_LANG(FC)])]) 823247738Sbapt 824247738Sbaptdnl The call to [A][M_PROG_GCJ] is quoted like that to stop aclocal 825247738Sbaptdnl pulling things in needlessly. 826247738SbaptAC_PROVIDE_IFELSE([AC_PROG_GCJ], 827247738Sbapt [LT_LANG(GCJ)], 828247738Sbapt [AC_PROVIDE_IFELSE([A][M_PROG_GCJ], 829247738Sbapt [LT_LANG(GCJ)], 830247738Sbapt [AC_PROVIDE_IFELSE([LT_PROG_GCJ], 831247738Sbapt [LT_LANG(GCJ)], 832247738Sbapt [m4_ifdef([AC_PROG_GCJ], 833247738Sbapt [m4_define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[LT_LANG(GCJ)])]) 834247738Sbapt m4_ifdef([A][M_PROG_GCJ], 835247738Sbapt [m4_define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[LT_LANG(GCJ)])]) 836247738Sbapt m4_ifdef([LT_PROG_GCJ], 837247738Sbapt [m4_define([LT_PROG_GCJ], defn([LT_PROG_GCJ])[LT_LANG(GCJ)])])])])]) 838247738Sbapt 839247738SbaptAC_PROVIDE_IFELSE([LT_PROG_RC], 840247738Sbapt [LT_LANG(RC)], 841247738Sbapt [m4_define([LT_PROG_RC], defn([LT_PROG_RC])[LT_LANG(RC)])]) 842247738Sbapt])# _LT_LANG_DEFAULT_CONFIG 843247738Sbapt 844247738Sbapt# Obsolete macros: 845247738SbaptAU_DEFUN([AC_LIBTOOL_CXX], [LT_LANG(C++)]) 846247738SbaptAU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)]) 847247738SbaptAU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)]) 848247738SbaptAU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)]) 849247738Sbaptdnl aclocal-1.4 backwards compatibility: 850247738Sbaptdnl AC_DEFUN([AC_LIBTOOL_CXX], []) 851247738Sbaptdnl AC_DEFUN([AC_LIBTOOL_F77], []) 852247738Sbaptdnl AC_DEFUN([AC_LIBTOOL_FC], []) 853247738Sbaptdnl AC_DEFUN([AC_LIBTOOL_GCJ], []) 854247738Sbapt 855247738Sbapt 856247738Sbapt# _LT_TAG_COMPILER 857247738Sbapt# ---------------- 858247738Sbaptm4_defun([_LT_TAG_COMPILER], 859247738Sbapt[AC_REQUIRE([AC_PROG_CC])dnl 860247738Sbapt 861247738Sbapt_LT_DECL([LTCC], [CC], [1], [A C compiler])dnl 862247738Sbapt_LT_DECL([LTCFLAGS], [CFLAGS], [1], [LTCC compiler flags])dnl 863247738Sbapt_LT_TAGDECL([CC], [compiler], [1], [A language specific compiler])dnl 864247738Sbapt_LT_TAGDECL([with_gcc], [GCC], [0], [Is the compiler the GNU compiler?])dnl 865247738Sbapt 866247738Sbapt# If no C compiler was specified, use CC. 867247738SbaptLTCC=${LTCC-"$CC"} 868247738Sbapt 869247738Sbapt# If no C compiler flags were specified, use CFLAGS. 870247738SbaptLTCFLAGS=${LTCFLAGS-"$CFLAGS"} 871247738Sbapt 872247738Sbapt# Allow CC to be a program name with arguments. 873247738Sbaptcompiler=$CC 874247738Sbapt])# _LT_TAG_COMPILER 875247738Sbapt 876247738Sbapt 877247738Sbapt# _LT_COMPILER_BOILERPLATE 878247738Sbapt# ------------------------ 879247738Sbapt# Check for compiler boilerplate output or warnings with 880247738Sbapt# the simple compiler test code. 881247738Sbaptm4_defun([_LT_COMPILER_BOILERPLATE], 882247738Sbapt[m4_require([_LT_DECL_SED])dnl 883247738Sbaptac_outfile=conftest.$ac_objext 884247738Sbaptecho "$lt_simple_compile_test_code" >conftest.$ac_ext 885247738Sbapteval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err 886247738Sbapt_lt_compiler_boilerplate=`cat conftest.err` 887247738Sbapt$RM conftest* 888247738Sbapt])# _LT_COMPILER_BOILERPLATE 889247738Sbapt 890247738Sbapt 891247738Sbapt# _LT_LINKER_BOILERPLATE 892247738Sbapt# ---------------------- 893247738Sbapt# Check for linker boilerplate output or warnings with 894247738Sbapt# the simple link test code. 895247738Sbaptm4_defun([_LT_LINKER_BOILERPLATE], 896247738Sbapt[m4_require([_LT_DECL_SED])dnl 897247738Sbaptac_outfile=conftest.$ac_objext 898247738Sbaptecho "$lt_simple_link_test_code" >conftest.$ac_ext 899247738Sbapteval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err 900247738Sbapt_lt_linker_boilerplate=`cat conftest.err` 901247738Sbapt$RM -r conftest* 902247738Sbapt])# _LT_LINKER_BOILERPLATE 903247738Sbapt 904247738Sbapt# _LT_REQUIRED_DARWIN_CHECKS 905247738Sbapt# ------------------------- 906247738Sbaptm4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[ 907247738Sbapt case $host_os in 908247738Sbapt rhapsody* | darwin*) 909247738Sbapt AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:]) 910247738Sbapt AC_CHECK_TOOL([NMEDIT], [nmedit], [:]) 911247738Sbapt AC_CHECK_TOOL([LIPO], [lipo], [:]) 912247738Sbapt AC_CHECK_TOOL([OTOOL], [otool], [:]) 913247738Sbapt AC_CHECK_TOOL([OTOOL64], [otool64], [:]) 914247738Sbapt _LT_DECL([], [DSYMUTIL], [1], 915247738Sbapt [Tool to manipulate archived DWARF debug symbol files on Mac OS X]) 916247738Sbapt _LT_DECL([], [NMEDIT], [1], 917247738Sbapt [Tool to change global to local symbols on Mac OS X]) 918247738Sbapt _LT_DECL([], [LIPO], [1], 919247738Sbapt [Tool to manipulate fat objects and archives on Mac OS X]) 920247738Sbapt _LT_DECL([], [OTOOL], [1], 921247738Sbapt [ldd/readelf like tool for Mach-O binaries on Mac OS X]) 922247738Sbapt _LT_DECL([], [OTOOL64], [1], 923247738Sbapt [ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4]) 924247738Sbapt 925247738Sbapt AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod], 926247738Sbapt [lt_cv_apple_cc_single_mod=no 927247738Sbapt if test -z "${LT_MULTI_MODULE}"; then 928247738Sbapt # By default we will add the -single_module flag. You can override 929247738Sbapt # by either setting the environment variable LT_MULTI_MODULE 930247738Sbapt # non-empty at configure time, or by adding -multi_module to the 931247738Sbapt # link flags. 932247738Sbapt rm -rf libconftest.dylib* 933247738Sbapt echo "int foo(void){return 1;}" > conftest.c 934247738Sbapt echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ 935247738Sbapt-dynamiclib -Wl,-single_module conftest.c" >&AS_MESSAGE_LOG_FD 936247738Sbapt $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ 937247738Sbapt -dynamiclib -Wl,-single_module conftest.c 2>conftest.err 938247738Sbapt _lt_result=$? 939247738Sbapt if test -f libconftest.dylib && test ! -s conftest.err && test $_lt_result = 0; then 940247738Sbapt lt_cv_apple_cc_single_mod=yes 941247738Sbapt else 942247738Sbapt cat conftest.err >&AS_MESSAGE_LOG_FD 943247738Sbapt fi 944247738Sbapt rm -rf libconftest.dylib* 945247738Sbapt rm -f conftest.* 946247738Sbapt fi]) 947247738Sbapt AC_CACHE_CHECK([for -exported_symbols_list linker flag], 948247738Sbapt [lt_cv_ld_exported_symbols_list], 949247738Sbapt [lt_cv_ld_exported_symbols_list=no 950247738Sbapt save_LDFLAGS=$LDFLAGS 951247738Sbapt echo "_main" > conftest.sym 952247738Sbapt LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" 953247738Sbapt AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], 954247738Sbapt [lt_cv_ld_exported_symbols_list=yes], 955247738Sbapt [lt_cv_ld_exported_symbols_list=no]) 956247738Sbapt LDFLAGS="$save_LDFLAGS" 957247738Sbapt ]) 958247738Sbapt case $host_os in 959247738Sbapt rhapsody* | darwin1.[[012]]) 960247738Sbapt _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;; 961247738Sbapt darwin1.*) 962247738Sbapt _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; 963247738Sbapt darwin*) # darwin 5.x on 964247738Sbapt # if running on 10.5 or later, the deployment target defaults 965247738Sbapt # to the OS version, if on x86, and 10.4, the deployment 966247738Sbapt # target defaults to 10.4. Don't you love it? 967247738Sbapt case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in 968247738Sbapt 10.0,*86*-darwin8*|10.0,*-darwin[[91]]*) 969247738Sbapt _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; 970247738Sbapt 10.[[012]]*) 971247738Sbapt _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; 972247738Sbapt 10.*) 973247738Sbapt _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; 974247738Sbapt esac 975247738Sbapt ;; 976247738Sbapt esac 977247738Sbapt if test "$lt_cv_apple_cc_single_mod" = "yes"; then 978247738Sbapt _lt_dar_single_mod='$single_module' 979247738Sbapt fi 980247738Sbapt if test "$lt_cv_ld_exported_symbols_list" = "yes"; then 981247738Sbapt _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym' 982247738Sbapt else 983247738Sbapt _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}' 984247738Sbapt fi 985247738Sbapt if test "$DSYMUTIL" != ":"; then 986247738Sbapt _lt_dsymutil='~$DSYMUTIL $lib || :' 987247738Sbapt else 988247738Sbapt _lt_dsymutil= 989247738Sbapt fi 990247738Sbapt ;; 991247738Sbapt esac 992247738Sbapt]) 993247738Sbapt 994247738Sbapt 995247738Sbapt# _LT_DARWIN_LINKER_FEATURES 996247738Sbapt# -------------------------- 997247738Sbapt# Checks for linker and compiler features on darwin 998247738Sbaptm4_defun([_LT_DARWIN_LINKER_FEATURES], 999247738Sbapt[ 1000247738Sbapt m4_require([_LT_REQUIRED_DARWIN_CHECKS]) 1001247738Sbapt _LT_TAGVAR(archive_cmds_need_lc, $1)=no 1002247738Sbapt _LT_TAGVAR(hardcode_direct, $1)=no 1003247738Sbapt _LT_TAGVAR(hardcode_automatic, $1)=yes 1004247738Sbapt _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported 1005247738Sbapt _LT_TAGVAR(whole_archive_flag_spec, $1)='' 1006247738Sbapt _LT_TAGVAR(link_all_deplibs, $1)=yes 1007247738Sbapt _LT_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined" 1008247738Sbapt case $cc_basename in 1009247738Sbapt ifort*) _lt_dar_can_shared=yes ;; 1010247738Sbapt *) _lt_dar_can_shared=$GCC ;; 1011247738Sbapt esac 1012247738Sbapt if test "$_lt_dar_can_shared" = "yes"; then 1013247738Sbapt output_verbose_link_cmd=echo 1014247738Sbapt _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}" 1015247738Sbapt _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" 1016247738Sbapt _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}" 1017247738Sbapt _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}" 1018247738Sbapt m4_if([$1], [CXX], 1019247738Sbapt[ if test "$lt_cv_apple_cc_single_mod" != "yes"; then 1020247738Sbapt _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}" 1021247738Sbapt _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}" 1022247738Sbapt fi 1023247738Sbapt],[]) 1024247738Sbapt else 1025247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 1026247738Sbapt fi 1027247738Sbapt]) 1028247738Sbapt 1029247738Sbapt# _LT_SYS_MODULE_PATH_AIX 1030247738Sbapt# ----------------------- 1031247738Sbapt# Links a minimal program and checks the executable 1032247738Sbapt# for the system default hardcoded library path. In most cases, 1033247738Sbapt# this is /usr/lib:/lib, but when the MPI compilers are used 1034247738Sbapt# the location of the communication and MPI libs are included too. 1035247738Sbapt# If we don't find anything, use the default library path according 1036247738Sbapt# to the aix ld manual. 1037247738Sbaptm4_defun([_LT_SYS_MODULE_PATH_AIX], 1038247738Sbapt[m4_require([_LT_DECL_SED])dnl 1039247738SbaptAC_LINK_IFELSE(AC_LANG_PROGRAM,[ 1040247738Sbaptlt_aix_libpath_sed=' 1041247738Sbapt /Import File Strings/,/^$/ { 1042247738Sbapt /^0/ { 1043247738Sbapt s/^0 *\(.*\)$/\1/ 1044247738Sbapt p 1045247738Sbapt } 1046247738Sbapt }' 1047247738Sbaptaix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` 1048247738Sbapt# Check for a 64-bit object if we didn't find anything. 1049247738Sbaptif test -z "$aix_libpath"; then 1050247738Sbapt aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` 1051247738Sbaptfi],[]) 1052247738Sbaptif test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi 1053247738Sbapt])# _LT_SYS_MODULE_PATH_AIX 1054247738Sbapt 1055247738Sbapt 1056247738Sbapt# _LT_SHELL_INIT(ARG) 1057247738Sbapt# ------------------- 1058247738Sbaptm4_define([_LT_SHELL_INIT], 1059247738Sbapt[ifdef([AC_DIVERSION_NOTICE], 1060247738Sbapt [AC_DIVERT_PUSH(AC_DIVERSION_NOTICE)], 1061247738Sbapt [AC_DIVERT_PUSH(NOTICE)]) 1062247738Sbapt$1 1063247738SbaptAC_DIVERT_POP 1064247738Sbapt])# _LT_SHELL_INIT 1065247738Sbapt 1066247738Sbapt 1067247738Sbapt# _LT_PROG_ECHO_BACKSLASH 1068247738Sbapt# ----------------------- 1069247738Sbapt# Add some code to the start of the generated configure script which 1070247738Sbapt# will find an echo command which doesn't interpret backslashes. 1071247738Sbaptm4_defun([_LT_PROG_ECHO_BACKSLASH], 1072247738Sbapt[_LT_SHELL_INIT([ 1073247738Sbapt# Check that we are running under the correct shell. 1074247738SbaptSHELL=${CONFIG_SHELL-/bin/sh} 1075247738Sbapt 1076247738Sbaptcase X$lt_ECHO in 1077247738SbaptX*--fallback-echo) 1078247738Sbapt # Remove one level of quotation (which was required for Make). 1079247738Sbapt ECHO=`echo "$lt_ECHO" | sed 's,\\\\\[$]\\[$]0,'[$]0','` 1080247738Sbapt ;; 1081247738Sbaptesac 1082247738Sbapt 1083247738SbaptECHO=${lt_ECHO-echo} 1084247738Sbaptif test "X[$]1" = X--no-reexec; then 1085247738Sbapt # Discard the --no-reexec flag, and continue. 1086247738Sbapt shift 1087247738Sbaptelif test "X[$]1" = X--fallback-echo; then 1088247738Sbapt # Avoid inline document here, it may be left over 1089247738Sbapt : 1090247738Sbaptelif test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' ; then 1091247738Sbapt # Yippee, $ECHO works! 1092247738Sbapt : 1093247738Sbaptelse 1094247738Sbapt # Restart under the correct shell. 1095247738Sbapt exec $SHELL "[$]0" --no-reexec ${1+"[$]@"} 1096247738Sbaptfi 1097247738Sbapt 1098247738Sbaptif test "X[$]1" = X--fallback-echo; then 1099247738Sbapt # used as fallback echo 1100247738Sbapt shift 1101247738Sbapt cat <<_LT_EOF 1102247738Sbapt[$]* 1103247738Sbapt_LT_EOF 1104247738Sbapt exit 0 1105247738Sbaptfi 1106247738Sbapt 1107247738Sbapt# The HP-UX ksh and POSIX shell print the target directory to stdout 1108247738Sbapt# if CDPATH is set. 1109247738Sbapt(unset CDPATH) >/dev/null 2>&1 && unset CDPATH 1110247738Sbapt 1111247738Sbaptif test -z "$lt_ECHO"; then 1112247738Sbapt if test "X${echo_test_string+set}" != Xset; then 1113247738Sbapt # find a string as large as possible, as long as the shell can cope with it 1114247738Sbapt for cmd in 'sed 50q "[$]0"' 'sed 20q "[$]0"' 'sed 10q "[$]0"' 'sed 2q "[$]0"' 'echo test'; do 1115247738Sbapt # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ... 1116247738Sbapt if { echo_test_string=`eval $cmd`; } 2>/dev/null && 1117247738Sbapt { test "X$echo_test_string" = "X$echo_test_string"; } 2>/dev/null 1118247738Sbapt then 1119247738Sbapt break 1120247738Sbapt fi 1121247738Sbapt done 1122247738Sbapt fi 1123247738Sbapt 1124247738Sbapt if test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' && 1125247738Sbapt echo_testing_string=`{ $ECHO "$echo_test_string"; } 2>/dev/null` && 1126247738Sbapt test "X$echo_testing_string" = "X$echo_test_string"; then 1127247738Sbapt : 1128247738Sbapt else 1129247738Sbapt # The Solaris, AIX, and Digital Unix default echo programs unquote 1130247738Sbapt # backslashes. This makes it impossible to quote backslashes using 1131247738Sbapt # echo "$something" | sed 's/\\/\\\\/g' 1132247738Sbapt # 1133247738Sbapt # So, first we look for a working echo in the user's PATH. 1134247738Sbapt 1135247738Sbapt lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR 1136247738Sbapt for dir in $PATH /usr/ucb; do 1137247738Sbapt IFS="$lt_save_ifs" 1138247738Sbapt if (test -f $dir/echo || test -f $dir/echo$ac_exeext) && 1139247738Sbapt test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' && 1140247738Sbapt echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` && 1141247738Sbapt test "X$echo_testing_string" = "X$echo_test_string"; then 1142247738Sbapt ECHO="$dir/echo" 1143247738Sbapt break 1144247738Sbapt fi 1145247738Sbapt done 1146247738Sbapt IFS="$lt_save_ifs" 1147247738Sbapt 1148247738Sbapt if test "X$ECHO" = Xecho; then 1149247738Sbapt # We didn't find a better echo, so look for alternatives. 1150247738Sbapt if test "X`{ print -r '\t'; } 2>/dev/null`" = 'X\t' && 1151247738Sbapt echo_testing_string=`{ print -r "$echo_test_string"; } 2>/dev/null` && 1152247738Sbapt test "X$echo_testing_string" = "X$echo_test_string"; then 1153247738Sbapt # This shell has a builtin print -r that does the trick. 1154247738Sbapt ECHO='print -r' 1155247738Sbapt elif { test -f /bin/ksh || test -f /bin/ksh$ac_exeext; } && 1156247738Sbapt test "X$CONFIG_SHELL" != X/bin/ksh; then 1157247738Sbapt # If we have ksh, try running configure again with it. 1158247738Sbapt ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh} 1159247738Sbapt export ORIGINAL_CONFIG_SHELL 1160247738Sbapt CONFIG_SHELL=/bin/ksh 1161247738Sbapt export CONFIG_SHELL 1162247738Sbapt exec $CONFIG_SHELL "[$]0" --no-reexec ${1+"[$]@"} 1163247738Sbapt else 1164247738Sbapt # Try using printf. 1165247738Sbapt ECHO='printf %s\n' 1166247738Sbapt if test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' && 1167247738Sbapt echo_testing_string=`{ $ECHO "$echo_test_string"; } 2>/dev/null` && 1168247738Sbapt test "X$echo_testing_string" = "X$echo_test_string"; then 1169247738Sbapt # Cool, printf works 1170247738Sbapt : 1171247738Sbapt elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` && 1172247738Sbapt test "X$echo_testing_string" = 'X\t' && 1173247738Sbapt echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` && 1174247738Sbapt test "X$echo_testing_string" = "X$echo_test_string"; then 1175247738Sbapt CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL 1176247738Sbapt export CONFIG_SHELL 1177247738Sbapt SHELL="$CONFIG_SHELL" 1178247738Sbapt export SHELL 1179247738Sbapt ECHO="$CONFIG_SHELL [$]0 --fallback-echo" 1180247738Sbapt elif echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` && 1181247738Sbapt test "X$echo_testing_string" = 'X\t' && 1182247738Sbapt echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` && 1183247738Sbapt test "X$echo_testing_string" = "X$echo_test_string"; then 1184247738Sbapt ECHO="$CONFIG_SHELL [$]0 --fallback-echo" 1185247738Sbapt else 1186247738Sbapt # maybe with a smaller string... 1187247738Sbapt prev=: 1188247738Sbapt 1189247738Sbapt for cmd in 'echo test' 'sed 2q "[$]0"' 'sed 10q "[$]0"' 'sed 20q "[$]0"' 'sed 50q "[$]0"'; do 1190247738Sbapt if { test "X$echo_test_string" = "X`eval $cmd`"; } 2>/dev/null 1191247738Sbapt then 1192247738Sbapt break 1193247738Sbapt fi 1194247738Sbapt prev="$cmd" 1195247738Sbapt done 1196247738Sbapt 1197247738Sbapt if test "$prev" != 'sed 50q "[$]0"'; then 1198247738Sbapt echo_test_string=`eval $prev` 1199247738Sbapt export echo_test_string 1200247738Sbapt exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "[$]0" ${1+"[$]@"} 1201247738Sbapt else 1202247738Sbapt # Oops. We lost completely, so just stick with echo. 1203247738Sbapt ECHO=echo 1204247738Sbapt fi 1205247738Sbapt fi 1206247738Sbapt fi 1207247738Sbapt fi 1208247738Sbapt fi 1209247738Sbaptfi 1210247738Sbapt 1211247738Sbapt# Copy echo and quote the copy suitably for passing to libtool from 1212247738Sbapt# the Makefile, instead of quoting the original, which is used later. 1213247738Sbaptlt_ECHO=$ECHO 1214247738Sbaptif test "X$lt_ECHO" = "X$CONFIG_SHELL [$]0 --fallback-echo"; then 1215247738Sbapt lt_ECHO="$CONFIG_SHELL \\\$\[$]0 --fallback-echo" 1216247738Sbaptfi 1217247738Sbapt 1218247738SbaptAC_SUBST(lt_ECHO) 1219247738Sbapt]) 1220247738Sbapt_LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts]) 1221247738Sbapt_LT_DECL([], [ECHO], [1], 1222247738Sbapt [An echo program that does not interpret backslashes]) 1223247738Sbapt])# _LT_PROG_ECHO_BACKSLASH 1224247738Sbapt 1225247738Sbapt 1226247738Sbapt# _LT_ENABLE_LOCK 1227247738Sbapt# --------------- 1228247738Sbaptm4_defun([_LT_ENABLE_LOCK], 1229247738Sbapt[AC_ARG_ENABLE([libtool-lock], 1230247738Sbapt [AS_HELP_STRING([--disable-libtool-lock], 1231247738Sbapt [avoid locking (might break parallel builds)])]) 1232247738Sbapttest "x$enable_libtool_lock" != xno && enable_libtool_lock=yes 1233247738Sbapt 1234247738Sbapt# Some flags need to be propagated to the compiler or linker for good 1235247738Sbapt# libtool support. 1236247738Sbaptcase $host in 1237247738Sbaptia64-*-hpux*) 1238247738Sbapt # Find out which ABI we are using. 1239247738Sbapt echo 'int i;' > conftest.$ac_ext 1240247738Sbapt if AC_TRY_EVAL(ac_compile); then 1241247738Sbapt case `/usr/bin/file conftest.$ac_objext` in 1242247738Sbapt *ELF-32*) 1243247738Sbapt HPUX_IA64_MODE="32" 1244247738Sbapt ;; 1245247738Sbapt *ELF-64*) 1246247738Sbapt HPUX_IA64_MODE="64" 1247247738Sbapt ;; 1248247738Sbapt esac 1249247738Sbapt fi 1250247738Sbapt rm -rf conftest* 1251247738Sbapt ;; 1252247738Sbapt*-*-irix6*) 1253247738Sbapt # Find out which ABI we are using. 1254247738Sbapt echo '[#]line __oline__ "configure"' > conftest.$ac_ext 1255247738Sbapt if AC_TRY_EVAL(ac_compile); then 1256247738Sbapt if test "$lt_cv_prog_gnu_ld" = yes; then 1257247738Sbapt case `/usr/bin/file conftest.$ac_objext` in 1258247738Sbapt *32-bit*) 1259247738Sbapt LD="${LD-ld} -melf32bsmip" 1260247738Sbapt ;; 1261247738Sbapt *N32*) 1262247738Sbapt LD="${LD-ld} -melf32bmipn32" 1263247738Sbapt ;; 1264247738Sbapt *64-bit*) 1265247738Sbapt LD="${LD-ld} -melf64bmip" 1266247738Sbapt ;; 1267247738Sbapt esac 1268247738Sbapt else 1269247738Sbapt case `/usr/bin/file conftest.$ac_objext` in 1270247738Sbapt *32-bit*) 1271247738Sbapt LD="${LD-ld} -32" 1272247738Sbapt ;; 1273247738Sbapt *N32*) 1274247738Sbapt LD="${LD-ld} -n32" 1275247738Sbapt ;; 1276247738Sbapt *64-bit*) 1277247738Sbapt LD="${LD-ld} -64" 1278247738Sbapt ;; 1279247738Sbapt esac 1280247738Sbapt fi 1281247738Sbapt fi 1282247738Sbapt rm -rf conftest* 1283247738Sbapt ;; 1284247738Sbapt 1285247738Sbaptx86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \ 1286247738Sbapts390*-*linux*|s390*-*tpf*|sparc*-*linux*) 1287247738Sbapt # Find out which ABI we are using. 1288247738Sbapt echo 'int i;' > conftest.$ac_ext 1289247738Sbapt if AC_TRY_EVAL(ac_compile); then 1290247738Sbapt case `/usr/bin/file conftest.o` in 1291247738Sbapt *32-bit*) 1292247738Sbapt case $host in 1293247738Sbapt x86_64-*kfreebsd*-gnu) 1294247738Sbapt LD="${LD-ld} -m elf_i386_fbsd" 1295247738Sbapt ;; 1296247738Sbapt x86_64-*linux*) 1297247738Sbapt LD="${LD-ld} -m elf_i386" 1298247738Sbapt ;; 1299247738Sbapt ppc64-*linux*|powerpc64-*linux*) 1300247738Sbapt LD="${LD-ld} -m elf32ppclinux" 1301247738Sbapt ;; 1302247738Sbapt s390x-*linux*) 1303247738Sbapt LD="${LD-ld} -m elf_s390" 1304247738Sbapt ;; 1305247738Sbapt sparc64-*linux*) 1306247738Sbapt LD="${LD-ld} -m elf32_sparc" 1307247738Sbapt ;; 1308247738Sbapt esac 1309247738Sbapt ;; 1310247738Sbapt *64-bit*) 1311247738Sbapt case $host in 1312247738Sbapt x86_64-*kfreebsd*-gnu) 1313247738Sbapt LD="${LD-ld} -m elf_x86_64_fbsd" 1314247738Sbapt ;; 1315247738Sbapt x86_64-*linux*) 1316247738Sbapt LD="${LD-ld} -m elf_x86_64" 1317247738Sbapt ;; 1318247738Sbapt ppc*-*linux*|powerpc*-*linux*) 1319247738Sbapt LD="${LD-ld} -m elf64ppc" 1320247738Sbapt ;; 1321247738Sbapt s390*-*linux*|s390*-*tpf*) 1322247738Sbapt LD="${LD-ld} -m elf64_s390" 1323247738Sbapt ;; 1324247738Sbapt sparc*-*linux*) 1325247738Sbapt LD="${LD-ld} -m elf64_sparc" 1326247738Sbapt ;; 1327247738Sbapt esac 1328247738Sbapt ;; 1329247738Sbapt esac 1330247738Sbapt fi 1331247738Sbapt rm -rf conftest* 1332247738Sbapt ;; 1333247738Sbapt 1334247738Sbapt*-*-sco3.2v5*) 1335247738Sbapt # On SCO OpenServer 5, we need -belf to get full-featured binaries. 1336247738Sbapt SAVE_CFLAGS="$CFLAGS" 1337247738Sbapt CFLAGS="$CFLAGS -belf" 1338247738Sbapt AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf, 1339247738Sbapt [AC_LANG_PUSH(C) 1340247738Sbapt AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no]) 1341247738Sbapt AC_LANG_POP]) 1342247738Sbapt if test x"$lt_cv_cc_needs_belf" != x"yes"; then 1343247738Sbapt # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf 1344247738Sbapt CFLAGS="$SAVE_CFLAGS" 1345247738Sbapt fi 1346247738Sbapt ;; 1347247738Sbaptsparc*-*solaris*) 1348247738Sbapt # Find out which ABI we are using. 1349247738Sbapt echo 'int i;' > conftest.$ac_ext 1350247738Sbapt if AC_TRY_EVAL(ac_compile); then 1351247738Sbapt case `/usr/bin/file conftest.o` in 1352247738Sbapt *64-bit*) 1353247738Sbapt case $lt_cv_prog_gnu_ld in 1354247738Sbapt yes*) LD="${LD-ld} -m elf64_sparc" ;; 1355247738Sbapt *) 1356247738Sbapt if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then 1357247738Sbapt LD="${LD-ld} -64" 1358247738Sbapt fi 1359247738Sbapt ;; 1360247738Sbapt esac 1361247738Sbapt ;; 1362247738Sbapt esac 1363247738Sbapt fi 1364247738Sbapt rm -rf conftest* 1365247738Sbapt ;; 1366247738Sbaptesac 1367247738Sbapt 1368247738Sbaptneed_locks="$enable_libtool_lock" 1369247738Sbapt])# _LT_ENABLE_LOCK 1370247738Sbapt 1371247738Sbapt 1372247738Sbapt# _LT_CMD_OLD_ARCHIVE 1373247738Sbapt# ------------------- 1374247738Sbaptm4_defun([_LT_CMD_OLD_ARCHIVE], 1375247738Sbapt[AC_CHECK_TOOL(AR, ar, false) 1376247738Sbapttest -z "$AR" && AR=ar 1377247738Sbapttest -z "$AR_FLAGS" && AR_FLAGS=cru 1378247738Sbapt_LT_DECL([], [AR], [1], [The archiver]) 1379247738Sbapt_LT_DECL([], [AR_FLAGS], [1]) 1380247738Sbapt 1381247738SbaptAC_CHECK_TOOL(STRIP, strip, :) 1382247738Sbapttest -z "$STRIP" && STRIP=: 1383247738Sbapt_LT_DECL([], [STRIP], [1], [A symbol stripping program]) 1384247738Sbapt 1385247738SbaptAC_CHECK_TOOL(RANLIB, ranlib, :) 1386247738Sbapttest -z "$RANLIB" && RANLIB=: 1387247738Sbapt_LT_DECL([], [RANLIB], [1], 1388247738Sbapt [Commands used to install an old-style archive]) 1389247738Sbapt 1390247738Sbapt# Determine commands to create old-style static archives. 1391247738Sbaptold_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' 1392247738Sbaptold_postinstall_cmds='chmod 644 $oldlib' 1393247738Sbaptold_postuninstall_cmds= 1394247738Sbapt 1395247738Sbaptif test -n "$RANLIB"; then 1396247738Sbapt case $host_os in 1397247738Sbapt openbsd*) 1398247738Sbapt old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib" 1399247738Sbapt ;; 1400247738Sbapt *) 1401247738Sbapt old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib" 1402247738Sbapt ;; 1403247738Sbapt esac 1404247738Sbapt old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib" 1405247738Sbaptfi 1406247738Sbapt_LT_DECL([], [old_postinstall_cmds], [2]) 1407247738Sbapt_LT_DECL([], [old_postuninstall_cmds], [2]) 1408247738Sbapt_LT_TAGDECL([], [old_archive_cmds], [2], 1409247738Sbapt [Commands used to build an old-style archive]) 1410247738Sbapt])# _LT_CMD_OLD_ARCHIVE 1411247738Sbapt 1412247738Sbapt 1413247738Sbapt# _LT_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, 1414247738Sbapt# [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE]) 1415247738Sbapt# ---------------------------------------------------------------- 1416247738Sbapt# Check whether the given compiler option works 1417247738SbaptAC_DEFUN([_LT_COMPILER_OPTION], 1418247738Sbapt[m4_require([_LT_FILEUTILS_DEFAULTS])dnl 1419247738Sbaptm4_require([_LT_DECL_SED])dnl 1420247738SbaptAC_CACHE_CHECK([$1], [$2], 1421247738Sbapt [$2=no 1422247738Sbapt m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4]) 1423247738Sbapt echo "$lt_simple_compile_test_code" > conftest.$ac_ext 1424247738Sbapt lt_compiler_flag="$3" 1425247738Sbapt # Insert the option either (1) after the last *FLAGS variable, or 1426247738Sbapt # (2) before a word containing "conftest.", or (3) at the end. 1427247738Sbapt # Note that $ac_compile itself does not contain backslashes and begins 1428247738Sbapt # with a dollar sign (not a hyphen), so the echo should work correctly. 1429247738Sbapt # The option is referenced via a variable to avoid confusing sed. 1430247738Sbapt lt_compile=`echo "$ac_compile" | $SED \ 1431247738Sbapt -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ 1432247738Sbapt -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ 1433247738Sbapt -e 's:$: $lt_compiler_flag:'` 1434247738Sbapt (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD) 1435247738Sbapt (eval "$lt_compile" 2>conftest.err) 1436247738Sbapt ac_status=$? 1437247738Sbapt cat conftest.err >&AS_MESSAGE_LOG_FD 1438247738Sbapt echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD 1439247738Sbapt if (exit $ac_status) && test -s "$ac_outfile"; then 1440247738Sbapt # The compiler can only warn and ignore the option if not recognized 1441247738Sbapt # So say no if there are warnings other than the usual output. 1442247738Sbapt $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp 1443247738Sbapt $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 1444247738Sbapt if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then 1445247738Sbapt $2=yes 1446247738Sbapt fi 1447247738Sbapt fi 1448247738Sbapt $RM conftest* 1449247738Sbapt]) 1450247738Sbapt 1451247738Sbaptif test x"[$]$2" = xyes; then 1452247738Sbapt m4_if([$5], , :, [$5]) 1453247738Sbaptelse 1454247738Sbapt m4_if([$6], , :, [$6]) 1455247738Sbaptfi 1456247738Sbapt])# _LT_COMPILER_OPTION 1457247738Sbapt 1458247738Sbapt# Old name: 1459247738SbaptAU_ALIAS([AC_LIBTOOL_COMPILER_OPTION], [_LT_COMPILER_OPTION]) 1460247738Sbaptdnl aclocal-1.4 backwards compatibility: 1461247738Sbaptdnl AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], []) 1462247738Sbapt 1463247738Sbapt 1464247738Sbapt# _LT_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, 1465247738Sbapt# [ACTION-SUCCESS], [ACTION-FAILURE]) 1466247738Sbapt# ---------------------------------------------------- 1467247738Sbapt# Check whether the given linker option works 1468247738SbaptAC_DEFUN([_LT_LINKER_OPTION], 1469247738Sbapt[m4_require([_LT_FILEUTILS_DEFAULTS])dnl 1470247738Sbaptm4_require([_LT_DECL_SED])dnl 1471247738SbaptAC_CACHE_CHECK([$1], [$2], 1472247738Sbapt [$2=no 1473247738Sbapt save_LDFLAGS="$LDFLAGS" 1474247738Sbapt LDFLAGS="$LDFLAGS $3" 1475247738Sbapt echo "$lt_simple_link_test_code" > conftest.$ac_ext 1476247738Sbapt if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then 1477247738Sbapt # The linker can only warn and ignore the option if not recognized 1478247738Sbapt # So say no if there are warnings 1479247738Sbapt if test -s conftest.err; then 1480247738Sbapt # Append any errors to the config.log. 1481247738Sbapt cat conftest.err 1>&AS_MESSAGE_LOG_FD 1482247738Sbapt $ECHO "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp 1483247738Sbapt $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 1484247738Sbapt if diff conftest.exp conftest.er2 >/dev/null; then 1485247738Sbapt $2=yes 1486247738Sbapt fi 1487247738Sbapt else 1488247738Sbapt $2=yes 1489247738Sbapt fi 1490247738Sbapt fi 1491247738Sbapt $RM -r conftest* 1492247738Sbapt LDFLAGS="$save_LDFLAGS" 1493247738Sbapt]) 1494247738Sbapt 1495247738Sbaptif test x"[$]$2" = xyes; then 1496247738Sbapt m4_if([$4], , :, [$4]) 1497247738Sbaptelse 1498247738Sbapt m4_if([$5], , :, [$5]) 1499247738Sbaptfi 1500247738Sbapt])# _LT_LINKER_OPTION 1501247738Sbapt 1502247738Sbapt# Old name: 1503247738SbaptAU_ALIAS([AC_LIBTOOL_LINKER_OPTION], [_LT_LINKER_OPTION]) 1504247738Sbaptdnl aclocal-1.4 backwards compatibility: 1505247738Sbaptdnl AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], []) 1506247738Sbapt 1507247738Sbapt 1508247738Sbapt# LT_CMD_MAX_LEN 1509247738Sbapt#--------------- 1510247738SbaptAC_DEFUN([LT_CMD_MAX_LEN], 1511247738Sbapt[AC_REQUIRE([AC_CANONICAL_HOST])dnl 1512247738Sbapt# find the maximum length of command line arguments 1513247738SbaptAC_MSG_CHECKING([the maximum length of command line arguments]) 1514247738SbaptAC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl 1515247738Sbapt i=0 1516247738Sbapt teststring="ABCD" 1517247738Sbapt 1518247738Sbapt case $build_os in 1519247738Sbapt msdosdjgpp*) 1520247738Sbapt # On DJGPP, this test can blow up pretty badly due to problems in libc 1521247738Sbapt # (any single argument exceeding 2000 bytes causes a buffer overrun 1522247738Sbapt # during glob expansion). Even if it were fixed, the result of this 1523247738Sbapt # check would be larger than it should be. 1524247738Sbapt lt_cv_sys_max_cmd_len=12288; # 12K is about right 1525247738Sbapt ;; 1526247738Sbapt 1527247738Sbapt gnu*) 1528247738Sbapt # Under GNU Hurd, this test is not required because there is 1529247738Sbapt # no limit to the length of command line arguments. 1530247738Sbapt # Libtool will interpret -1 as no limit whatsoever 1531247738Sbapt lt_cv_sys_max_cmd_len=-1; 1532247738Sbapt ;; 1533247738Sbapt 1534247738Sbapt cygwin* | mingw* | cegcc*) 1535247738Sbapt # On Win9x/ME, this test blows up -- it succeeds, but takes 1536247738Sbapt # about 5 minutes as the teststring grows exponentially. 1537247738Sbapt # Worse, since 9x/ME are not pre-emptively multitasking, 1538247738Sbapt # you end up with a "frozen" computer, even though with patience 1539247738Sbapt # the test eventually succeeds (with a max line length of 256k). 1540247738Sbapt # Instead, let's just punt: use the minimum linelength reported by 1541247738Sbapt # all of the supported platforms: 8192 (on NT/2K/XP). 1542247738Sbapt lt_cv_sys_max_cmd_len=8192; 1543247738Sbapt ;; 1544247738Sbapt 1545247738Sbapt amigaos*) 1546247738Sbapt # On AmigaOS with pdksh, this test takes hours, literally. 1547247738Sbapt # So we just punt and use a minimum line length of 8192. 1548247738Sbapt lt_cv_sys_max_cmd_len=8192; 1549247738Sbapt ;; 1550247738Sbapt 1551247738Sbapt netbsd* | freebsd* | openbsd* | darwin* | dragonfly*) 1552247738Sbapt # This has been around since 386BSD, at least. Likely further. 1553247738Sbapt if test -x /sbin/sysctl; then 1554247738Sbapt lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` 1555247738Sbapt elif test -x /usr/sbin/sysctl; then 1556247738Sbapt lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` 1557247738Sbapt else 1558247738Sbapt lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs 1559247738Sbapt fi 1560247738Sbapt # And add a safety zone 1561247738Sbapt lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` 1562247738Sbapt lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` 1563247738Sbapt ;; 1564247738Sbapt 1565247738Sbapt interix*) 1566247738Sbapt # We know the value 262144 and hardcode it with a safety zone (like BSD) 1567247738Sbapt lt_cv_sys_max_cmd_len=196608 1568247738Sbapt ;; 1569247738Sbapt 1570247738Sbapt osf*) 1571247738Sbapt # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure 1572247738Sbapt # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not 1573247738Sbapt # nice to cause kernel panics so lets avoid the loop below. 1574247738Sbapt # First set a reasonable default. 1575247738Sbapt lt_cv_sys_max_cmd_len=16384 1576247738Sbapt # 1577247738Sbapt if test -x /sbin/sysconfig; then 1578247738Sbapt case `/sbin/sysconfig -q proc exec_disable_arg_limit` in 1579247738Sbapt *1*) lt_cv_sys_max_cmd_len=-1 ;; 1580247738Sbapt esac 1581247738Sbapt fi 1582247738Sbapt ;; 1583247738Sbapt sco3.2v5*) 1584247738Sbapt lt_cv_sys_max_cmd_len=102400 1585247738Sbapt ;; 1586247738Sbapt sysv5* | sco5v6* | sysv4.2uw2*) 1587247738Sbapt kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` 1588247738Sbapt if test -n "$kargmax"; then 1589247738Sbapt lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'` 1590247738Sbapt else 1591247738Sbapt lt_cv_sys_max_cmd_len=32768 1592247738Sbapt fi 1593247738Sbapt ;; 1594247738Sbapt *) 1595247738Sbapt lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` 1596247738Sbapt if test -n "$lt_cv_sys_max_cmd_len"; then 1597247738Sbapt lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` 1598247738Sbapt lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` 1599247738Sbapt else 1600247738Sbapt # Make teststring a little bigger before we do anything with it. 1601247738Sbapt # a 1K string should be a reasonable start. 1602247738Sbapt for i in 1 2 3 4 5 6 7 8 ; do 1603247738Sbapt teststring=$teststring$teststring 1604247738Sbapt done 1605247738Sbapt SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} 1606247738Sbapt # If test is not a shell built-in, we'll probably end up computing a 1607247738Sbapt # maximum length that is only half of the actual maximum length, but 1608247738Sbapt # we can't tell. 1609247738Sbapt while { test "X"`$SHELL [$]0 --fallback-echo "X$teststring$teststring" 2>/dev/null` \ 1610247738Sbapt = "XX$teststring$teststring"; } >/dev/null 2>&1 && 1611247738Sbapt test $i != 17 # 1/2 MB should be enough 1612247738Sbapt do 1613247738Sbapt i=`expr $i + 1` 1614247738Sbapt teststring=$teststring$teststring 1615247738Sbapt done 1616247738Sbapt # Only check the string length outside the loop. 1617247738Sbapt lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1` 1618247738Sbapt teststring= 1619247738Sbapt # Add a significant safety factor because C++ compilers can tack on 1620247738Sbapt # massive amounts of additional arguments before passing them to the 1621247738Sbapt # linker. It appears as though 1/2 is a usable value. 1622247738Sbapt lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` 1623247738Sbapt fi 1624247738Sbapt ;; 1625247738Sbapt esac 1626247738Sbapt]) 1627247738Sbaptif test -n $lt_cv_sys_max_cmd_len ; then 1628247738Sbapt AC_MSG_RESULT($lt_cv_sys_max_cmd_len) 1629247738Sbaptelse 1630247738Sbapt AC_MSG_RESULT(none) 1631247738Sbaptfi 1632247738Sbaptmax_cmd_len=$lt_cv_sys_max_cmd_len 1633247738Sbapt_LT_DECL([], [max_cmd_len], [0], 1634247738Sbapt [What is the maximum length of a command?]) 1635247738Sbapt])# LT_CMD_MAX_LEN 1636247738Sbapt 1637247738Sbapt# Old name: 1638247738SbaptAU_ALIAS([AC_LIBTOOL_SYS_MAX_CMD_LEN], [LT_CMD_MAX_LEN]) 1639247738Sbaptdnl aclocal-1.4 backwards compatibility: 1640247738Sbaptdnl AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], []) 1641247738Sbapt 1642247738Sbapt 1643247738Sbapt# _LT_HEADER_DLFCN 1644247738Sbapt# ---------------- 1645247738Sbaptm4_defun([_LT_HEADER_DLFCN], 1646247738Sbapt[AC_CHECK_HEADERS([dlfcn.h], [], [], [AC_INCLUDES_DEFAULT])dnl 1647247738Sbapt])# _LT_HEADER_DLFCN 1648247738Sbapt 1649247738Sbapt 1650247738Sbapt# _LT_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE, 1651247738Sbapt# ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING) 1652247738Sbapt# ---------------------------------------------------------------- 1653247738Sbaptm4_defun([_LT_TRY_DLOPEN_SELF], 1654247738Sbapt[m4_require([_LT_HEADER_DLFCN])dnl 1655247738Sbaptif test "$cross_compiling" = yes; then : 1656247738Sbapt [$4] 1657247738Sbaptelse 1658247738Sbapt lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 1659247738Sbapt lt_status=$lt_dlunknown 1660247738Sbapt cat > conftest.$ac_ext <<_LT_EOF 1661247738Sbapt[#line __oline__ "configure" 1662247738Sbapt#include "confdefs.h" 1663247738Sbapt 1664247738Sbapt#if HAVE_DLFCN_H 1665247738Sbapt#include <dlfcn.h> 1666247738Sbapt#endif 1667247738Sbapt 1668247738Sbapt#include <stdio.h> 1669247738Sbapt 1670247738Sbapt#ifdef RTLD_GLOBAL 1671247738Sbapt# define LT_DLGLOBAL RTLD_GLOBAL 1672247738Sbapt#else 1673247738Sbapt# ifdef DL_GLOBAL 1674247738Sbapt# define LT_DLGLOBAL DL_GLOBAL 1675247738Sbapt# else 1676247738Sbapt# define LT_DLGLOBAL 0 1677247738Sbapt# endif 1678247738Sbapt#endif 1679247738Sbapt 1680247738Sbapt/* We may have to define LT_DLLAZY_OR_NOW in the command line if we 1681247738Sbapt find out it does not work in some platform. */ 1682247738Sbapt#ifndef LT_DLLAZY_OR_NOW 1683247738Sbapt# ifdef RTLD_LAZY 1684247738Sbapt# define LT_DLLAZY_OR_NOW RTLD_LAZY 1685247738Sbapt# else 1686247738Sbapt# ifdef DL_LAZY 1687247738Sbapt# define LT_DLLAZY_OR_NOW DL_LAZY 1688247738Sbapt# else 1689247738Sbapt# ifdef RTLD_NOW 1690247738Sbapt# define LT_DLLAZY_OR_NOW RTLD_NOW 1691247738Sbapt# else 1692247738Sbapt# ifdef DL_NOW 1693247738Sbapt# define LT_DLLAZY_OR_NOW DL_NOW 1694247738Sbapt# else 1695247738Sbapt# define LT_DLLAZY_OR_NOW 0 1696247738Sbapt# endif 1697247738Sbapt# endif 1698247738Sbapt# endif 1699247738Sbapt# endif 1700247738Sbapt#endif 1701247738Sbapt 1702247738Sbaptvoid fnord() { int i=42;} 1703247738Sbaptint main () 1704247738Sbapt{ 1705247738Sbapt void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); 1706247738Sbapt int status = $lt_dlunknown; 1707247738Sbapt 1708247738Sbapt if (self) 1709247738Sbapt { 1710247738Sbapt if (dlsym (self,"fnord")) status = $lt_dlno_uscore; 1711247738Sbapt else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; 1712247738Sbapt /* dlclose (self); */ 1713247738Sbapt } 1714247738Sbapt else 1715247738Sbapt puts (dlerror ()); 1716247738Sbapt 1717247738Sbapt return status; 1718247738Sbapt}] 1719247738Sbapt_LT_EOF 1720247738Sbapt if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then 1721247738Sbapt (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null 1722247738Sbapt lt_status=$? 1723247738Sbapt case x$lt_status in 1724247738Sbapt x$lt_dlno_uscore) $1 ;; 1725247738Sbapt x$lt_dlneed_uscore) $2 ;; 1726247738Sbapt x$lt_dlunknown|x*) $3 ;; 1727247738Sbapt esac 1728247738Sbapt else : 1729247738Sbapt # compilation failed 1730247738Sbapt $3 1731247738Sbapt fi 1732247738Sbaptfi 1733247738Sbaptrm -fr conftest* 1734247738Sbapt])# _LT_TRY_DLOPEN_SELF 1735247738Sbapt 1736247738Sbapt 1737247738Sbapt# LT_SYS_DLOPEN_SELF 1738247738Sbapt# ------------------ 1739247738SbaptAC_DEFUN([LT_SYS_DLOPEN_SELF], 1740247738Sbapt[m4_require([_LT_HEADER_DLFCN])dnl 1741247738Sbaptif test "x$enable_dlopen" != xyes; then 1742247738Sbapt enable_dlopen=unknown 1743247738Sbapt enable_dlopen_self=unknown 1744247738Sbapt enable_dlopen_self_static=unknown 1745247738Sbaptelse 1746247738Sbapt lt_cv_dlopen=no 1747247738Sbapt lt_cv_dlopen_libs= 1748247738Sbapt 1749247738Sbapt case $host_os in 1750247738Sbapt beos*) 1751247738Sbapt lt_cv_dlopen="load_add_on" 1752247738Sbapt lt_cv_dlopen_libs= 1753247738Sbapt lt_cv_dlopen_self=yes 1754247738Sbapt ;; 1755247738Sbapt 1756247738Sbapt mingw* | pw32* | cegcc*) 1757247738Sbapt lt_cv_dlopen="LoadLibrary" 1758247738Sbapt lt_cv_dlopen_libs= 1759247738Sbapt ;; 1760247738Sbapt 1761247738Sbapt cygwin*) 1762247738Sbapt lt_cv_dlopen="dlopen" 1763247738Sbapt lt_cv_dlopen_libs= 1764247738Sbapt ;; 1765247738Sbapt 1766247738Sbapt darwin*) 1767247738Sbapt # if libdl is installed we need to link against it 1768247738Sbapt AC_CHECK_LIB([dl], [dlopen], 1769247738Sbapt [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[ 1770247738Sbapt lt_cv_dlopen="dyld" 1771247738Sbapt lt_cv_dlopen_libs= 1772247738Sbapt lt_cv_dlopen_self=yes 1773247738Sbapt ]) 1774247738Sbapt ;; 1775247738Sbapt 1776247738Sbapt *) 1777247738Sbapt AC_CHECK_FUNC([shl_load], 1778247738Sbapt [lt_cv_dlopen="shl_load"], 1779247738Sbapt [AC_CHECK_LIB([dld], [shl_load], 1780247738Sbapt [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"], 1781247738Sbapt [AC_CHECK_FUNC([dlopen], 1782247738Sbapt [lt_cv_dlopen="dlopen"], 1783247738Sbapt [AC_CHECK_LIB([dl], [dlopen], 1784247738Sbapt [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"], 1785247738Sbapt [AC_CHECK_LIB([svld], [dlopen], 1786247738Sbapt [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"], 1787247738Sbapt [AC_CHECK_LIB([dld], [dld_link], 1788247738Sbapt [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"]) 1789247738Sbapt ]) 1790247738Sbapt ]) 1791247738Sbapt ]) 1792247738Sbapt ]) 1793247738Sbapt ]) 1794247738Sbapt ;; 1795247738Sbapt esac 1796247738Sbapt 1797247738Sbapt if test "x$lt_cv_dlopen" != xno; then 1798247738Sbapt enable_dlopen=yes 1799247738Sbapt else 1800247738Sbapt enable_dlopen=no 1801247738Sbapt fi 1802247738Sbapt 1803247738Sbapt case $lt_cv_dlopen in 1804247738Sbapt dlopen) 1805247738Sbapt save_CPPFLAGS="$CPPFLAGS" 1806247738Sbapt test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" 1807247738Sbapt 1808247738Sbapt save_LDFLAGS="$LDFLAGS" 1809247738Sbapt wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" 1810247738Sbapt 1811247738Sbapt save_LIBS="$LIBS" 1812247738Sbapt LIBS="$lt_cv_dlopen_libs $LIBS" 1813247738Sbapt 1814247738Sbapt AC_CACHE_CHECK([whether a program can dlopen itself], 1815247738Sbapt lt_cv_dlopen_self, [dnl 1816247738Sbapt _LT_TRY_DLOPEN_SELF( 1817247738Sbapt lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes, 1818247738Sbapt lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross) 1819247738Sbapt ]) 1820247738Sbapt 1821247738Sbapt if test "x$lt_cv_dlopen_self" = xyes; then 1822247738Sbapt wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" 1823247738Sbapt AC_CACHE_CHECK([whether a statically linked program can dlopen itself], 1824247738Sbapt lt_cv_dlopen_self_static, [dnl 1825247738Sbapt _LT_TRY_DLOPEN_SELF( 1826247738Sbapt lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes, 1827247738Sbapt lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross) 1828247738Sbapt ]) 1829247738Sbapt fi 1830247738Sbapt 1831247738Sbapt CPPFLAGS="$save_CPPFLAGS" 1832247738Sbapt LDFLAGS="$save_LDFLAGS" 1833247738Sbapt LIBS="$save_LIBS" 1834247738Sbapt ;; 1835247738Sbapt esac 1836247738Sbapt 1837247738Sbapt case $lt_cv_dlopen_self in 1838247738Sbapt yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; 1839247738Sbapt *) enable_dlopen_self=unknown ;; 1840247738Sbapt esac 1841247738Sbapt 1842247738Sbapt case $lt_cv_dlopen_self_static in 1843247738Sbapt yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; 1844247738Sbapt *) enable_dlopen_self_static=unknown ;; 1845247738Sbapt esac 1846247738Sbaptfi 1847247738Sbapt_LT_DECL([dlopen_support], [enable_dlopen], [0], 1848247738Sbapt [Whether dlopen is supported]) 1849247738Sbapt_LT_DECL([dlopen_self], [enable_dlopen_self], [0], 1850247738Sbapt [Whether dlopen of programs is supported]) 1851247738Sbapt_LT_DECL([dlopen_self_static], [enable_dlopen_self_static], [0], 1852247738Sbapt [Whether dlopen of statically linked programs is supported]) 1853247738Sbapt])# LT_SYS_DLOPEN_SELF 1854247738Sbapt 1855247738Sbapt# Old name: 1856247738SbaptAU_ALIAS([AC_LIBTOOL_DLOPEN_SELF], [LT_SYS_DLOPEN_SELF]) 1857247738Sbaptdnl aclocal-1.4 backwards compatibility: 1858247738Sbaptdnl AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], []) 1859247738Sbapt 1860247738Sbapt 1861247738Sbapt# _LT_COMPILER_C_O([TAGNAME]) 1862247738Sbapt# --------------------------- 1863247738Sbapt# Check to see if options -c and -o are simultaneously supported by compiler. 1864247738Sbapt# This macro does not hard code the compiler like AC_PROG_CC_C_O. 1865247738Sbaptm4_defun([_LT_COMPILER_C_O], 1866247738Sbapt[m4_require([_LT_DECL_SED])dnl 1867247738Sbaptm4_require([_LT_FILEUTILS_DEFAULTS])dnl 1868247738Sbaptm4_require([_LT_TAG_COMPILER])dnl 1869247738SbaptAC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext], 1870247738Sbapt [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)], 1871247738Sbapt [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no 1872247738Sbapt $RM -r conftest 2>/dev/null 1873247738Sbapt mkdir conftest 1874247738Sbapt cd conftest 1875247738Sbapt mkdir out 1876247738Sbapt echo "$lt_simple_compile_test_code" > conftest.$ac_ext 1877247738Sbapt 1878247738Sbapt lt_compiler_flag="-o out/conftest2.$ac_objext" 1879247738Sbapt # Insert the option either (1) after the last *FLAGS variable, or 1880247738Sbapt # (2) before a word containing "conftest.", or (3) at the end. 1881247738Sbapt # Note that $ac_compile itself does not contain backslashes and begins 1882247738Sbapt # with a dollar sign (not a hyphen), so the echo should work correctly. 1883247738Sbapt lt_compile=`echo "$ac_compile" | $SED \ 1884247738Sbapt -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ 1885247738Sbapt -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ 1886247738Sbapt -e 's:$: $lt_compiler_flag:'` 1887247738Sbapt (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD) 1888247738Sbapt (eval "$lt_compile" 2>out/conftest.err) 1889247738Sbapt ac_status=$? 1890247738Sbapt cat out/conftest.err >&AS_MESSAGE_LOG_FD 1891247738Sbapt echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD 1892247738Sbapt if (exit $ac_status) && test -s out/conftest2.$ac_objext 1893247738Sbapt then 1894247738Sbapt # The compiler can only warn and ignore the option if not recognized 1895247738Sbapt # So say no if there are warnings 1896247738Sbapt $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp 1897247738Sbapt $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 1898247738Sbapt if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then 1899247738Sbapt _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes 1900247738Sbapt fi 1901247738Sbapt fi 1902247738Sbapt chmod u+w . 2>&AS_MESSAGE_LOG_FD 1903247738Sbapt $RM conftest* 1904247738Sbapt # SGI C++ compiler will create directory out/ii_files/ for 1905247738Sbapt # template instantiation 1906247738Sbapt test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files 1907247738Sbapt $RM out/* && rmdir out 1908247738Sbapt cd .. 1909247738Sbapt $RM -r conftest 1910247738Sbapt $RM conftest* 1911247738Sbapt]) 1912247738Sbapt_LT_TAGDECL([compiler_c_o], [lt_cv_prog_compiler_c_o], [1], 1913247738Sbapt [Does compiler simultaneously support -c and -o options?]) 1914247738Sbapt])# _LT_COMPILER_C_O 1915247738Sbapt 1916247738Sbapt 1917247738Sbapt# _LT_COMPILER_FILE_LOCKS([TAGNAME]) 1918247738Sbapt# ---------------------------------- 1919247738Sbapt# Check to see if we can do hard links to lock some files if needed 1920247738Sbaptm4_defun([_LT_COMPILER_FILE_LOCKS], 1921247738Sbapt[m4_require([_LT_ENABLE_LOCK])dnl 1922247738Sbaptm4_require([_LT_FILEUTILS_DEFAULTS])dnl 1923247738Sbapt_LT_COMPILER_C_O([$1]) 1924247738Sbapt 1925247738Sbapthard_links="nottested" 1926247738Sbaptif test "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then 1927247738Sbapt # do not overwrite the value of need_locks provided by the user 1928247738Sbapt AC_MSG_CHECKING([if we can lock with hard links]) 1929247738Sbapt hard_links=yes 1930247738Sbapt $RM conftest* 1931247738Sbapt ln conftest.a conftest.b 2>/dev/null && hard_links=no 1932247738Sbapt touch conftest.a 1933247738Sbapt ln conftest.a conftest.b 2>&5 || hard_links=no 1934247738Sbapt ln conftest.a conftest.b 2>/dev/null && hard_links=no 1935247738Sbapt AC_MSG_RESULT([$hard_links]) 1936247738Sbapt if test "$hard_links" = no; then 1937247738Sbapt AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe]) 1938247738Sbapt need_locks=warn 1939247738Sbapt fi 1940247738Sbaptelse 1941247738Sbapt need_locks=no 1942247738Sbaptfi 1943247738Sbapt_LT_DECL([], [need_locks], [1], [Must we lock files when doing compilation?]) 1944247738Sbapt])# _LT_COMPILER_FILE_LOCKS 1945247738Sbapt 1946247738Sbapt 1947247738Sbapt# _LT_CHECK_OBJDIR 1948247738Sbapt# ---------------- 1949247738Sbaptm4_defun([_LT_CHECK_OBJDIR], 1950247738Sbapt[AC_CACHE_CHECK([for objdir], [lt_cv_objdir], 1951247738Sbapt[rm -f .libs 2>/dev/null 1952247738Sbaptmkdir .libs 2>/dev/null 1953247738Sbaptif test -d .libs; then 1954247738Sbapt lt_cv_objdir=.libs 1955247738Sbaptelse 1956247738Sbapt # MS-DOS does not allow filenames that begin with a dot. 1957247738Sbapt lt_cv_objdir=_libs 1958247738Sbaptfi 1959247738Sbaptrmdir .libs 2>/dev/null]) 1960247738Sbaptobjdir=$lt_cv_objdir 1961247738Sbapt_LT_DECL([], [objdir], [0], 1962247738Sbapt [The name of the directory that contains temporary libtool files])dnl 1963247738Sbaptm4_pattern_allow([LT_OBJDIR])dnl 1964247738SbaptAC_DEFINE_UNQUOTED(LT_OBJDIR, "$lt_cv_objdir/", 1965247738Sbapt [Define to the sub-directory in which libtool stores uninstalled libraries.]) 1966247738Sbapt])# _LT_CHECK_OBJDIR 1967247738Sbapt 1968247738Sbapt 1969247738Sbapt# _LT_LINKER_HARDCODE_LIBPATH([TAGNAME]) 1970247738Sbapt# -------------------------------------- 1971247738Sbapt# Check hardcoding attributes. 1972247738Sbaptm4_defun([_LT_LINKER_HARDCODE_LIBPATH], 1973247738Sbapt[AC_MSG_CHECKING([how to hardcode library paths into programs]) 1974247738Sbapt_LT_TAGVAR(hardcode_action, $1)= 1975247738Sbaptif test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" || 1976247738Sbapt test -n "$_LT_TAGVAR(runpath_var, $1)" || 1977247738Sbapt test "X$_LT_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then 1978247738Sbapt 1979247738Sbapt # We can hardcode non-existent directories. 1980247738Sbapt if test "$_LT_TAGVAR(hardcode_direct, $1)" != no && 1981247738Sbapt # If the only mechanism to avoid hardcoding is shlibpath_var, we 1982247738Sbapt # have to relink, otherwise we might link with an installed library 1983247738Sbapt # when we should be linking with a yet-to-be-installed one 1984247738Sbapt ## test "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" != no && 1985247738Sbapt test "$_LT_TAGVAR(hardcode_minus_L, $1)" != no; then 1986247738Sbapt # Linking always hardcodes the temporary library directory. 1987247738Sbapt _LT_TAGVAR(hardcode_action, $1)=relink 1988247738Sbapt else 1989247738Sbapt # We can link without hardcoding, and we can hardcode nonexisting dirs. 1990247738Sbapt _LT_TAGVAR(hardcode_action, $1)=immediate 1991247738Sbapt fi 1992247738Sbaptelse 1993247738Sbapt # We cannot hardcode anything, or else we can only hardcode existing 1994247738Sbapt # directories. 1995247738Sbapt _LT_TAGVAR(hardcode_action, $1)=unsupported 1996247738Sbaptfi 1997247738SbaptAC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)]) 1998247738Sbapt 1999247738Sbaptif test "$_LT_TAGVAR(hardcode_action, $1)" = relink || 2000247738Sbapt test "$_LT_TAGVAR(inherit_rpath, $1)" = yes; then 2001247738Sbapt # Fast installation is not supported 2002247738Sbapt enable_fast_install=no 2003247738Sbaptelif test "$shlibpath_overrides_runpath" = yes || 2004247738Sbapt test "$enable_shared" = no; then 2005247738Sbapt # Fast installation is not necessary 2006247738Sbapt enable_fast_install=needless 2007247738Sbaptfi 2008247738Sbapt_LT_TAGDECL([], [hardcode_action], [0], 2009247738Sbapt [How to hardcode a shared library path into an executable]) 2010247738Sbapt])# _LT_LINKER_HARDCODE_LIBPATH 2011247738Sbapt 2012247738Sbapt 2013247738Sbapt# _LT_CMD_STRIPLIB 2014247738Sbapt# ---------------- 2015247738Sbaptm4_defun([_LT_CMD_STRIPLIB], 2016247738Sbapt[m4_require([_LT_DECL_EGREP]) 2017247738Sbaptstriplib= 2018247738Sbaptold_striplib= 2019247738SbaptAC_MSG_CHECKING([whether stripping libraries is possible]) 2020247738Sbaptif test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then 2021247738Sbapt test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" 2022247738Sbapt test -z "$striplib" && striplib="$STRIP --strip-unneeded" 2023247738Sbapt AC_MSG_RESULT([yes]) 2024247738Sbaptelse 2025247738Sbapt# FIXME - insert some real tests, host_os isn't really good enough 2026247738Sbapt case $host_os in 2027247738Sbapt darwin*) 2028247738Sbapt if test -n "$STRIP" ; then 2029247738Sbapt striplib="$STRIP -x" 2030247738Sbapt old_striplib="$STRIP -S" 2031247738Sbapt AC_MSG_RESULT([yes]) 2032247738Sbapt else 2033247738Sbapt AC_MSG_RESULT([no]) 2034247738Sbapt fi 2035247738Sbapt ;; 2036247738Sbapt *) 2037247738Sbapt AC_MSG_RESULT([no]) 2038247738Sbapt ;; 2039247738Sbapt esac 2040247738Sbaptfi 2041247738Sbapt_LT_DECL([], [old_striplib], [1], [Commands to strip libraries]) 2042247738Sbapt_LT_DECL([], [striplib], [1]) 2043247738Sbapt])# _LT_CMD_STRIPLIB 2044247738Sbapt 2045247738Sbapt 2046247738Sbapt# _LT_SYS_DYNAMIC_LINKER([TAG]) 2047247738Sbapt# ----------------------------- 2048247738Sbapt# PORTME Fill in your ld.so characteristics 2049247738Sbaptm4_defun([_LT_SYS_DYNAMIC_LINKER], 2050247738Sbapt[AC_REQUIRE([AC_CANONICAL_HOST])dnl 2051247738Sbaptm4_require([_LT_DECL_EGREP])dnl 2052247738Sbaptm4_require([_LT_FILEUTILS_DEFAULTS])dnl 2053247738Sbaptm4_require([_LT_DECL_OBJDUMP])dnl 2054247738Sbaptm4_require([_LT_DECL_SED])dnl 2055247738SbaptAC_MSG_CHECKING([dynamic linker characteristics]) 2056247738Sbaptm4_if([$1], 2057247738Sbapt [], [ 2058247738Sbaptif test "$GCC" = yes; then 2059247738Sbapt case $host_os in 2060247738Sbapt darwin*) lt_awk_arg="/^libraries:/,/LR/" ;; 2061247738Sbapt *) lt_awk_arg="/^libraries:/" ;; 2062247738Sbapt esac 2063247738Sbapt lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e "s,=/,/,g"` 2064247738Sbapt if $ECHO "$lt_search_path_spec" | $GREP ';' >/dev/null ; then 2065247738Sbapt # if the path contains ";" then we assume it to be the separator 2066247738Sbapt # otherwise default to the standard path separator (i.e. ":") - it is 2067247738Sbapt # assumed that no part of a normal pathname contains ";" but that should 2068247738Sbapt # okay in the real world where ";" in dirpaths is itself problematic. 2069247738Sbapt lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED -e 's/;/ /g'` 2070247738Sbapt else 2071247738Sbapt lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` 2072247738Sbapt fi 2073247738Sbapt # Ok, now we have the path, separated by spaces, we can step through it 2074247738Sbapt # and add multilib dir if necessary. 2075247738Sbapt lt_tmp_lt_search_path_spec= 2076247738Sbapt lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` 2077247738Sbapt for lt_sys_path in $lt_search_path_spec; do 2078247738Sbapt if test -d "$lt_sys_path/$lt_multi_os_dir"; then 2079247738Sbapt lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir" 2080247738Sbapt else 2081247738Sbapt test -d "$lt_sys_path" && \ 2082247738Sbapt lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" 2083247738Sbapt fi 2084247738Sbapt done 2085247738Sbapt lt_search_path_spec=`$ECHO $lt_tmp_lt_search_path_spec | awk ' 2086247738SbaptBEGIN {RS=" "; FS="/|\n";} { 2087247738Sbapt lt_foo=""; 2088247738Sbapt lt_count=0; 2089247738Sbapt for (lt_i = NF; lt_i > 0; lt_i--) { 2090247738Sbapt if ($lt_i != "" && $lt_i != ".") { 2091247738Sbapt if ($lt_i == "..") { 2092247738Sbapt lt_count++; 2093247738Sbapt } else { 2094247738Sbapt if (lt_count == 0) { 2095247738Sbapt lt_foo="/" $lt_i lt_foo; 2096247738Sbapt } else { 2097247738Sbapt lt_count--; 2098247738Sbapt } 2099247738Sbapt } 2100247738Sbapt } 2101247738Sbapt } 2102247738Sbapt if (lt_foo != "") { lt_freq[[lt_foo]]++; } 2103247738Sbapt if (lt_freq[[lt_foo]] == 1) { print lt_foo; } 2104247738Sbapt}'` 2105247738Sbapt sys_lib_search_path_spec=`$ECHO $lt_search_path_spec` 2106247738Sbaptelse 2107247738Sbapt sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" 2108247738Sbaptfi]) 2109247738Sbaptlibrary_names_spec= 2110247738Sbaptlibname_spec='lib$name' 2111247738Sbaptsoname_spec= 2112247738Sbaptshrext_cmds=".so" 2113247738Sbaptpostinstall_cmds= 2114247738Sbaptpostuninstall_cmds= 2115247738Sbaptfinish_cmds= 2116247738Sbaptfinish_eval= 2117247738Sbaptshlibpath_var= 2118247738Sbaptshlibpath_overrides_runpath=unknown 2119247738Sbaptversion_type=none 2120247738Sbaptdynamic_linker="$host_os ld.so" 2121247738Sbaptsys_lib_dlsearch_path_spec="/lib /usr/lib" 2122247738Sbaptneed_lib_prefix=unknown 2123247738Sbapthardcode_into_libs=no 2124247738Sbapt 2125247738Sbapt# when you set need_version to no, make sure it does not cause -set_version 2126247738Sbapt# flags to be left without arguments 2127247738Sbaptneed_version=unknown 2128247738Sbapt 2129247738Sbaptcase $host_os in 2130247738Sbaptaix3*) 2131247738Sbapt version_type=linux 2132247738Sbapt library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' 2133247738Sbapt shlibpath_var=LIBPATH 2134247738Sbapt 2135247738Sbapt # AIX 3 has no versioning support, so we append a major version to the name. 2136247738Sbapt soname_spec='${libname}${release}${shared_ext}$major' 2137247738Sbapt ;; 2138247738Sbapt 2139247738Sbaptaix[[4-9]]*) 2140247738Sbapt version_type=linux 2141247738Sbapt need_lib_prefix=no 2142247738Sbapt need_version=no 2143247738Sbapt hardcode_into_libs=yes 2144247738Sbapt if test "$host_cpu" = ia64; then 2145247738Sbapt # AIX 5 supports IA64 2146247738Sbapt library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' 2147247738Sbapt shlibpath_var=LD_LIBRARY_PATH 2148247738Sbapt else 2149247738Sbapt # With GCC up to 2.95.x, collect2 would create an import file 2150247738Sbapt # for dependence libraries. The import file would start with 2151247738Sbapt # the line `#! .'. This would cause the generated library to 2152247738Sbapt # depend on `.', always an invalid library. This was fixed in 2153247738Sbapt # development snapshots of GCC prior to 3.0. 2154247738Sbapt case $host_os in 2155247738Sbapt aix4 | aix4.[[01]] | aix4.[[01]].*) 2156247738Sbapt if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' 2157247738Sbapt echo ' yes ' 2158247738Sbapt echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then 2159247738Sbapt : 2160247738Sbapt else 2161247738Sbapt can_build_shared=no 2162247738Sbapt fi 2163247738Sbapt ;; 2164247738Sbapt esac 2165247738Sbapt # AIX (on Power*) has no versioning support, so currently we can not hardcode correct 2166247738Sbapt # soname into executable. Probably we can add versioning support to 2167247738Sbapt # collect2, so additional links can be useful in future. 2168247738Sbapt if test "$aix_use_runtimelinking" = yes; then 2169247738Sbapt # If using run time linking (on AIX 4.2 or later) use lib<name>.so 2170247738Sbapt # instead of lib<name>.a to let people know that these are not 2171247738Sbapt # typical AIX shared libraries. 2172247738Sbapt library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 2173247738Sbapt else 2174247738Sbapt # We preserve .a as extension for shared libraries through AIX4.2 2175247738Sbapt # and later when we are not doing run time linking. 2176247738Sbapt library_names_spec='${libname}${release}.a $libname.a' 2177247738Sbapt soname_spec='${libname}${release}${shared_ext}$major' 2178247738Sbapt fi 2179247738Sbapt shlibpath_var=LIBPATH 2180247738Sbapt fi 2181247738Sbapt ;; 2182247738Sbapt 2183247738Sbaptamigaos*) 2184247738Sbapt case $host_cpu in 2185247738Sbapt powerpc) 2186247738Sbapt # Since July 2007 AmigaOS4 officially supports .so libraries. 2187247738Sbapt # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. 2188247738Sbapt library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 2189247738Sbapt ;; 2190247738Sbapt m68k) 2191247738Sbapt library_names_spec='$libname.ixlibrary $libname.a' 2192247738Sbapt # Create ${libname}_ixlibrary.a entries in /sys/libs. 2193247738Sbapt finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$ECHO "X$lib" | $Xsed -e '\''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' 2194247738Sbapt ;; 2195247738Sbapt esac 2196247738Sbapt ;; 2197247738Sbapt 2198247738Sbaptbeos*) 2199247738Sbapt library_names_spec='${libname}${shared_ext}' 2200247738Sbapt dynamic_linker="$host_os ld.so" 2201247738Sbapt shlibpath_var=LIBRARY_PATH 2202247738Sbapt ;; 2203247738Sbapt 2204247738Sbaptbsdi[[45]]*) 2205247738Sbapt version_type=linux 2206247738Sbapt need_version=no 2207247738Sbapt library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 2208247738Sbapt soname_spec='${libname}${release}${shared_ext}$major' 2209247738Sbapt finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' 2210247738Sbapt shlibpath_var=LD_LIBRARY_PATH 2211247738Sbapt sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" 2212247738Sbapt sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" 2213247738Sbapt # the default ld.so.conf also contains /usr/contrib/lib and 2214247738Sbapt # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow 2215247738Sbapt # libtool to hard-code these into programs 2216247738Sbapt ;; 2217247738Sbapt 2218247738Sbaptcygwin* | mingw* | pw32* | cegcc*) 2219247738Sbapt version_type=windows 2220247738Sbapt shrext_cmds=".dll" 2221247738Sbapt need_version=no 2222247738Sbapt need_lib_prefix=no 2223247738Sbapt 2224247738Sbapt case $GCC,$host_os in 2225247738Sbapt yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*) 2226247738Sbapt library_names_spec='$libname.dll.a' 2227247738Sbapt # DLL is installed to $(libdir)/../bin by postinstall_cmds 2228247738Sbapt postinstall_cmds='base_file=`basename \${file}`~ 2229247738Sbapt dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ 2230247738Sbapt dldir=$destdir/`dirname \$dlpath`~ 2231247738Sbapt test -d \$dldir || mkdir -p \$dldir~ 2232247738Sbapt $install_prog $dir/$dlname \$dldir/$dlname~ 2233247738Sbapt chmod a+x \$dldir/$dlname~ 2234247738Sbapt if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then 2235247738Sbapt eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; 2236247738Sbapt fi' 2237247738Sbapt postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ 2238247738Sbapt dlpath=$dir/\$dldll~ 2239247738Sbapt $RM \$dlpath' 2240247738Sbapt shlibpath_overrides_runpath=yes 2241247738Sbapt 2242247738Sbapt case $host_os in 2243247738Sbapt cygwin*) 2244247738Sbapt # Cygwin DLLs use 'cyg' prefix rather than 'lib' 2245247738Sbapt soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' 2246247738Sbapt sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib" 2247247738Sbapt ;; 2248247738Sbapt mingw* | cegcc*) 2249247738Sbapt # MinGW DLLs use traditional 'lib' prefix 2250247738Sbapt soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' 2251247738Sbapt sys_lib_search_path_spec=`$CC -print-search-dirs | $GREP "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` 2252247738Sbapt if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then 2253247738Sbapt # It is most probably a Windows format PATH printed by 2254247738Sbapt # mingw gcc, but we are running on Cygwin. Gcc prints its search 2255247738Sbapt # path with ; separators, and with drive letters. We can handle the 2256247738Sbapt # drive letters (cygwin fileutils understands them), so leave them, 2257247738Sbapt # especially as we might pass files found there to a mingw objdump, 2258247738Sbapt # which wouldn't understand a cygwinified path. Ahh. 2259247738Sbapt sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` 2260247738Sbapt else 2261247738Sbapt sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` 2262247738Sbapt fi 2263247738Sbapt ;; 2264247738Sbapt pw32*) 2265247738Sbapt # pw32 DLLs use 'pw' prefix rather than 'lib' 2266247738Sbapt library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' 2267247738Sbapt ;; 2268247738Sbapt esac 2269247738Sbapt ;; 2270247738Sbapt 2271247738Sbapt *) 2272247738Sbapt library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib' 2273247738Sbapt ;; 2274247738Sbapt esac 2275247738Sbapt dynamic_linker='Win32 ld.exe' 2276247738Sbapt # FIXME: first we should search . and the directory the executable is in 2277247738Sbapt shlibpath_var=PATH 2278247738Sbapt ;; 2279247738Sbapt 2280247738Sbaptdarwin* | rhapsody*) 2281247738Sbapt dynamic_linker="$host_os dyld" 2282247738Sbapt version_type=darwin 2283247738Sbapt need_lib_prefix=no 2284247738Sbapt need_version=no 2285247738Sbapt library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext' 2286247738Sbapt soname_spec='${libname}${release}${major}$shared_ext' 2287247738Sbapt shlibpath_overrides_runpath=yes 2288247738Sbapt shlibpath_var=DYLD_LIBRARY_PATH 2289247738Sbapt shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' 2290247738Sbaptm4_if([$1], [],[ 2291247738Sbapt sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"]) 2292247738Sbapt sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' 2293247738Sbapt ;; 2294247738Sbapt 2295247738Sbaptdgux*) 2296247738Sbapt version_type=linux 2297247738Sbapt need_lib_prefix=no 2298247738Sbapt need_version=no 2299247738Sbapt library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' 2300247738Sbapt soname_spec='${libname}${release}${shared_ext}$major' 2301247738Sbapt shlibpath_var=LD_LIBRARY_PATH 2302247738Sbapt ;; 2303247738Sbapt 2304247738Sbaptfreebsd1*) 2305247738Sbapt dynamic_linker=no 2306247738Sbapt ;; 2307247738Sbapt 2308247738Sbaptfreebsd* | dragonfly*) 2309247738Sbapt # DragonFly does not have aout. When/if they implement a new 2310247738Sbapt # versioning mechanism, adjust this. 2311247738Sbapt if test -x /usr/bin/objformat; then 2312247738Sbapt objformat=`/usr/bin/objformat` 2313247738Sbapt else 2314247738Sbapt case $host_os in 2315247738Sbapt freebsd[[123]]*) objformat=aout ;; 2316247738Sbapt *) objformat=elf ;; 2317247738Sbapt esac 2318247738Sbapt fi 2319247738Sbapt version_type=freebsd-$objformat 2320247738Sbapt case $version_type in 2321247738Sbapt freebsd-elf*) 2322247738Sbapt library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' 2323247738Sbapt need_version=no 2324247738Sbapt need_lib_prefix=no 2325247738Sbapt ;; 2326247738Sbapt freebsd-*) 2327247738Sbapt library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' 2328247738Sbapt need_version=yes 2329247738Sbapt ;; 2330247738Sbapt esac 2331247738Sbapt shlibpath_var=LD_LIBRARY_PATH 2332247738Sbapt case $host_os in 2333247738Sbapt freebsd2*) 2334247738Sbapt shlibpath_overrides_runpath=yes 2335247738Sbapt ;; 2336247738Sbapt freebsd3.[[01]]* | freebsdelf3.[[01]]*) 2337247738Sbapt shlibpath_overrides_runpath=yes 2338247738Sbapt hardcode_into_libs=yes 2339247738Sbapt ;; 2340247738Sbapt freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \ 2341247738Sbapt freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1) 2342247738Sbapt shlibpath_overrides_runpath=no 2343247738Sbapt hardcode_into_libs=yes 2344247738Sbapt ;; 2345247738Sbapt *) # from 4.6 on, and DragonFly 2346247738Sbapt shlibpath_overrides_runpath=yes 2347247738Sbapt hardcode_into_libs=yes 2348247738Sbapt ;; 2349247738Sbapt esac 2350247738Sbapt ;; 2351247738Sbapt 2352247738Sbaptgnu*) 2353247738Sbapt version_type=linux 2354247738Sbapt need_lib_prefix=no 2355247738Sbapt need_version=no 2356247738Sbapt library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' 2357247738Sbapt soname_spec='${libname}${release}${shared_ext}$major' 2358247738Sbapt shlibpath_var=LD_LIBRARY_PATH 2359247738Sbapt hardcode_into_libs=yes 2360247738Sbapt ;; 2361247738Sbapt 2362247738Sbapthpux9* | hpux10* | hpux11*) 2363247738Sbapt # Give a soname corresponding to the major version so that dld.sl refuses to 2364247738Sbapt # link against other versions. 2365247738Sbapt version_type=sunos 2366247738Sbapt need_lib_prefix=no 2367247738Sbapt need_version=no 2368247738Sbapt case $host_cpu in 2369247738Sbapt ia64*) 2370247738Sbapt shrext_cmds='.so' 2371247738Sbapt hardcode_into_libs=yes 2372247738Sbapt dynamic_linker="$host_os dld.so" 2373247738Sbapt shlibpath_var=LD_LIBRARY_PATH 2374247738Sbapt shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. 2375247738Sbapt library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 2376247738Sbapt soname_spec='${libname}${release}${shared_ext}$major' 2377247738Sbapt if test "X$HPUX_IA64_MODE" = X32; then 2378247738Sbapt sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" 2379247738Sbapt else 2380247738Sbapt sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" 2381247738Sbapt fi 2382247738Sbapt sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec 2383247738Sbapt ;; 2384247738Sbapt hppa*64*) 2385247738Sbapt shrext_cmds='.sl' 2386247738Sbapt hardcode_into_libs=yes 2387247738Sbapt dynamic_linker="$host_os dld.sl" 2388247738Sbapt shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH 2389247738Sbapt shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. 2390247738Sbapt library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 2391247738Sbapt soname_spec='${libname}${release}${shared_ext}$major' 2392247738Sbapt sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" 2393247738Sbapt sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec 2394247738Sbapt ;; 2395247738Sbapt *) 2396247738Sbapt shrext_cmds='.sl' 2397247738Sbapt dynamic_linker="$host_os dld.sl" 2398247738Sbapt shlibpath_var=SHLIB_PATH 2399247738Sbapt shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH 2400247738Sbapt library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 2401247738Sbapt soname_spec='${libname}${release}${shared_ext}$major' 2402247738Sbapt ;; 2403247738Sbapt esac 2404247738Sbapt # HP-UX runs *really* slowly unless shared libraries are mode 555. 2405247738Sbapt postinstall_cmds='chmod 555 $lib' 2406247738Sbapt ;; 2407247738Sbapt 2408247738Sbaptinterix[[3-9]]*) 2409247738Sbapt version_type=linux 2410247738Sbapt need_lib_prefix=no 2411247738Sbapt need_version=no 2412247738Sbapt library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' 2413247738Sbapt soname_spec='${libname}${release}${shared_ext}$major' 2414247738Sbapt dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' 2415247738Sbapt shlibpath_var=LD_LIBRARY_PATH 2416247738Sbapt shlibpath_overrides_runpath=no 2417247738Sbapt hardcode_into_libs=yes 2418247738Sbapt ;; 2419247738Sbapt 2420247738Sbaptirix5* | irix6* | nonstopux*) 2421247738Sbapt case $host_os in 2422247738Sbapt nonstopux*) version_type=nonstopux ;; 2423247738Sbapt *) 2424247738Sbapt if test "$lt_cv_prog_gnu_ld" = yes; then 2425247738Sbapt version_type=linux 2426247738Sbapt else 2427247738Sbapt version_type=irix 2428247738Sbapt fi ;; 2429247738Sbapt esac 2430247738Sbapt need_lib_prefix=no 2431247738Sbapt need_version=no 2432247738Sbapt soname_spec='${libname}${release}${shared_ext}$major' 2433247738Sbapt library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' 2434247738Sbapt case $host_os in 2435247738Sbapt irix5* | nonstopux*) 2436247738Sbapt libsuff= shlibsuff= 2437247738Sbapt ;; 2438247738Sbapt *) 2439247738Sbapt case $LD in # libtool.m4 will add one of these switches to LD 2440247738Sbapt *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") 2441247738Sbapt libsuff= shlibsuff= libmagic=32-bit;; 2442247738Sbapt *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") 2443247738Sbapt libsuff=32 shlibsuff=N32 libmagic=N32;; 2444247738Sbapt *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") 2445247738Sbapt libsuff=64 shlibsuff=64 libmagic=64-bit;; 2446247738Sbapt *) libsuff= shlibsuff= libmagic=never-match;; 2447247738Sbapt esac 2448247738Sbapt ;; 2449247738Sbapt esac 2450247738Sbapt shlibpath_var=LD_LIBRARY${shlibsuff}_PATH 2451247738Sbapt shlibpath_overrides_runpath=no 2452247738Sbapt sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" 2453247738Sbapt sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" 2454247738Sbapt hardcode_into_libs=yes 2455247738Sbapt ;; 2456247738Sbapt 2457247738Sbapt# No shared lib support for Linux oldld, aout, or coff. 2458247738Sbaptlinux*oldld* | linux*aout* | linux*coff*) 2459247738Sbapt dynamic_linker=no 2460247738Sbapt ;; 2461247738Sbapt 2462247738Sbapt# This must be Linux ELF. 2463247738Sbaptlinux* | k*bsd*-gnu | kopensolaris*-gnu) 2464247738Sbapt version_type=linux 2465247738Sbapt need_lib_prefix=no 2466247738Sbapt need_version=no 2467247738Sbapt library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 2468247738Sbapt soname_spec='${libname}${release}${shared_ext}$major' 2469247738Sbapt finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' 2470247738Sbapt shlibpath_var=LD_LIBRARY_PATH 2471247738Sbapt shlibpath_overrides_runpath=no 2472247738Sbapt # Some binutils ld are patched to set DT_RUNPATH 2473247738Sbapt save_LDFLAGS=$LDFLAGS 2474247738Sbapt save_libdir=$libdir 2475247738Sbapt eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \ 2476247738Sbapt LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\"" 2477247738Sbapt AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], 2478247738Sbapt [AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null], 2479247738Sbapt [shlibpath_overrides_runpath=yes])]) 2480247738Sbapt LDFLAGS=$save_LDFLAGS 2481247738Sbapt libdir=$save_libdir 2482247738Sbapt 2483247738Sbapt # This implies no fast_install, which is unacceptable. 2484247738Sbapt # Some rework will be needed to allow for fast_install 2485247738Sbapt # before this can be enabled. 2486247738Sbapt hardcode_into_libs=yes 2487247738Sbapt 2488247738Sbapt # Append ld.so.conf contents to the search path 2489247738Sbapt if test -f /etc/ld.so.conf; then 2490247738Sbapt 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;/^$/d' | tr '\n' ' '` 2491247738Sbapt sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" 2492247738Sbapt fi 2493247738Sbapt 2494247738Sbapt # We used to test for /lib/ld.so.1 and disable shared libraries on 2495247738Sbapt # powerpc, because MkLinux only supported shared libraries with the 2496247738Sbapt # GNU dynamic linker. Since this was broken with cross compilers, 2497247738Sbapt # most powerpc-linux boxes support dynamic linking these days and 2498247738Sbapt # people can always --disable-shared, the test was removed, and we 2499247738Sbapt # assume the GNU/Linux dynamic linker is in use. 2500247738Sbapt dynamic_linker='GNU/Linux ld.so' 2501247738Sbapt ;; 2502247738Sbapt 2503247738Sbaptnetbsdelf*-gnu) 2504247738Sbapt version_type=linux 2505247738Sbapt need_lib_prefix=no 2506247738Sbapt need_version=no 2507247738Sbapt library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' 2508247738Sbapt soname_spec='${libname}${release}${shared_ext}$major' 2509247738Sbapt shlibpath_var=LD_LIBRARY_PATH 2510247738Sbapt shlibpath_overrides_runpath=no 2511247738Sbapt hardcode_into_libs=yes 2512247738Sbapt dynamic_linker='NetBSD ld.elf_so' 2513247738Sbapt ;; 2514247738Sbapt 2515247738Sbaptnetbsd*) 2516247738Sbapt version_type=sunos 2517247738Sbapt need_lib_prefix=no 2518247738Sbapt need_version=no 2519247738Sbapt if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then 2520247738Sbapt library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' 2521247738Sbapt finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' 2522247738Sbapt dynamic_linker='NetBSD (a.out) ld.so' 2523247738Sbapt else 2524247738Sbapt library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' 2525247738Sbapt soname_spec='${libname}${release}${shared_ext}$major' 2526247738Sbapt dynamic_linker='NetBSD ld.elf_so' 2527247738Sbapt fi 2528247738Sbapt shlibpath_var=LD_LIBRARY_PATH 2529247738Sbapt shlibpath_overrides_runpath=yes 2530247738Sbapt hardcode_into_libs=yes 2531247738Sbapt ;; 2532247738Sbapt 2533247738Sbaptnewsos6) 2534247738Sbapt version_type=linux 2535247738Sbapt library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 2536247738Sbapt shlibpath_var=LD_LIBRARY_PATH 2537247738Sbapt shlibpath_overrides_runpath=yes 2538247738Sbapt ;; 2539247738Sbapt 2540247738Sbapt*nto* | *qnx*) 2541247738Sbapt version_type=qnx 2542247738Sbapt need_lib_prefix=no 2543247738Sbapt need_version=no 2544247738Sbapt library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 2545247738Sbapt soname_spec='${libname}${release}${shared_ext}$major' 2546247738Sbapt shlibpath_var=LD_LIBRARY_PATH 2547247738Sbapt shlibpath_overrides_runpath=no 2548247738Sbapt hardcode_into_libs=yes 2549247738Sbapt dynamic_linker='ldqnx.so' 2550247738Sbapt ;; 2551247738Sbapt 2552247738Sbaptopenbsd*) 2553247738Sbapt version_type=sunos 2554247738Sbapt sys_lib_dlsearch_path_spec="/usr/lib" 2555247738Sbapt need_lib_prefix=no 2556247738Sbapt # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. 2557247738Sbapt case $host_os in 2558247738Sbapt openbsd3.3 | openbsd3.3.*) need_version=yes ;; 2559247738Sbapt *) need_version=no ;; 2560247738Sbapt esac 2561247738Sbapt library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' 2562247738Sbapt finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' 2563247738Sbapt shlibpath_var=LD_LIBRARY_PATH 2564247738Sbapt if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then 2565247738Sbapt case $host_os in 2566247738Sbapt openbsd2.[[89]] | openbsd2.[[89]].*) 2567247738Sbapt shlibpath_overrides_runpath=no 2568247738Sbapt ;; 2569247738Sbapt *) 2570247738Sbapt shlibpath_overrides_runpath=yes 2571247738Sbapt ;; 2572247738Sbapt esac 2573247738Sbapt else 2574247738Sbapt shlibpath_overrides_runpath=yes 2575247738Sbapt fi 2576247738Sbapt ;; 2577247738Sbapt 2578247738Sbaptos2*) 2579247738Sbapt libname_spec='$name' 2580247738Sbapt shrext_cmds=".dll" 2581247738Sbapt need_lib_prefix=no 2582247738Sbapt library_names_spec='$libname${shared_ext} $libname.a' 2583247738Sbapt dynamic_linker='OS/2 ld.exe' 2584247738Sbapt shlibpath_var=LIBPATH 2585247738Sbapt ;; 2586247738Sbapt 2587247738Sbaptosf3* | osf4* | osf5*) 2588247738Sbapt version_type=osf 2589247738Sbapt need_lib_prefix=no 2590247738Sbapt need_version=no 2591247738Sbapt soname_spec='${libname}${release}${shared_ext}$major' 2592247738Sbapt library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 2593247738Sbapt shlibpath_var=LD_LIBRARY_PATH 2594247738Sbapt sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" 2595247738Sbapt sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" 2596247738Sbapt ;; 2597247738Sbapt 2598247738Sbaptrdos*) 2599247738Sbapt dynamic_linker=no 2600247738Sbapt ;; 2601247738Sbapt 2602247738Sbaptsolaris*) 2603247738Sbapt version_type=linux 2604247738Sbapt need_lib_prefix=no 2605247738Sbapt need_version=no 2606247738Sbapt library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 2607247738Sbapt soname_spec='${libname}${release}${shared_ext}$major' 2608247738Sbapt shlibpath_var=LD_LIBRARY_PATH 2609247738Sbapt shlibpath_overrides_runpath=yes 2610247738Sbapt hardcode_into_libs=yes 2611247738Sbapt # ldd complains unless libraries are executable 2612247738Sbapt postinstall_cmds='chmod +x $lib' 2613247738Sbapt ;; 2614247738Sbapt 2615247738Sbaptsunos4*) 2616247738Sbapt version_type=sunos 2617247738Sbapt library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' 2618247738Sbapt finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' 2619247738Sbapt shlibpath_var=LD_LIBRARY_PATH 2620247738Sbapt shlibpath_overrides_runpath=yes 2621247738Sbapt if test "$with_gnu_ld" = yes; then 2622247738Sbapt need_lib_prefix=no 2623247738Sbapt fi 2624247738Sbapt need_version=yes 2625247738Sbapt ;; 2626247738Sbapt 2627247738Sbaptsysv4 | sysv4.3*) 2628247738Sbapt version_type=linux 2629247738Sbapt library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 2630247738Sbapt soname_spec='${libname}${release}${shared_ext}$major' 2631247738Sbapt shlibpath_var=LD_LIBRARY_PATH 2632247738Sbapt case $host_vendor in 2633247738Sbapt sni) 2634247738Sbapt shlibpath_overrides_runpath=no 2635247738Sbapt need_lib_prefix=no 2636247738Sbapt runpath_var=LD_RUN_PATH 2637247738Sbapt ;; 2638247738Sbapt siemens) 2639247738Sbapt need_lib_prefix=no 2640247738Sbapt ;; 2641247738Sbapt motorola) 2642247738Sbapt need_lib_prefix=no 2643247738Sbapt need_version=no 2644247738Sbapt shlibpath_overrides_runpath=no 2645247738Sbapt sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' 2646247738Sbapt ;; 2647247738Sbapt esac 2648247738Sbapt ;; 2649247738Sbapt 2650247738Sbaptsysv4*MP*) 2651247738Sbapt if test -d /usr/nec ;then 2652247738Sbapt version_type=linux 2653247738Sbapt library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' 2654247738Sbapt soname_spec='$libname${shared_ext}.$major' 2655247738Sbapt shlibpath_var=LD_LIBRARY_PATH 2656247738Sbapt fi 2657247738Sbapt ;; 2658247738Sbapt 2659247738Sbaptsysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) 2660247738Sbapt version_type=freebsd-elf 2661247738Sbapt need_lib_prefix=no 2662247738Sbapt need_version=no 2663247738Sbapt library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' 2664247738Sbapt soname_spec='${libname}${release}${shared_ext}$major' 2665247738Sbapt shlibpath_var=LD_LIBRARY_PATH 2666247738Sbapt shlibpath_overrides_runpath=yes 2667247738Sbapt hardcode_into_libs=yes 2668247738Sbapt if test "$with_gnu_ld" = yes; then 2669247738Sbapt sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' 2670247738Sbapt else 2671247738Sbapt sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' 2672247738Sbapt case $host_os in 2673247738Sbapt sco3.2v5*) 2674247738Sbapt sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" 2675247738Sbapt ;; 2676247738Sbapt esac 2677247738Sbapt fi 2678247738Sbapt sys_lib_dlsearch_path_spec='/usr/lib' 2679247738Sbapt ;; 2680247738Sbapt 2681247738Sbapttpf*) 2682247738Sbapt # TPF is a cross-target only. Preferred cross-host = GNU/Linux. 2683247738Sbapt version_type=linux 2684247738Sbapt need_lib_prefix=no 2685247738Sbapt need_version=no 2686247738Sbapt library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 2687247738Sbapt shlibpath_var=LD_LIBRARY_PATH 2688247738Sbapt shlibpath_overrides_runpath=no 2689247738Sbapt hardcode_into_libs=yes 2690247738Sbapt ;; 2691247738Sbapt 2692247738Sbaptuts4*) 2693247738Sbapt version_type=linux 2694247738Sbapt library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 2695247738Sbapt soname_spec='${libname}${release}${shared_ext}$major' 2696247738Sbapt shlibpath_var=LD_LIBRARY_PATH 2697247738Sbapt ;; 2698247738Sbapt 2699247738Sbapt*) 2700247738Sbapt dynamic_linker=no 2701247738Sbapt ;; 2702247738Sbaptesac 2703247738SbaptAC_MSG_RESULT([$dynamic_linker]) 2704247738Sbapttest "$dynamic_linker" = no && can_build_shared=no 2705247738Sbapt 2706247738Sbaptvariables_saved_for_relink="PATH $shlibpath_var $runpath_var" 2707247738Sbaptif test "$GCC" = yes; then 2708247738Sbapt variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" 2709247738Sbaptfi 2710247738Sbapt 2711247738Sbaptif test "${lt_cv_sys_lib_search_path_spec+set}" = set; then 2712247738Sbapt sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" 2713247738Sbaptfi 2714247738Sbaptif test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then 2715247738Sbapt sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" 2716247738Sbaptfi 2717247738Sbapt 2718247738Sbapt_LT_DECL([], [variables_saved_for_relink], [1], 2719247738Sbapt [Variables whose values should be saved in libtool wrapper scripts and 2720247738Sbapt restored at link time]) 2721247738Sbapt_LT_DECL([], [need_lib_prefix], [0], 2722247738Sbapt [Do we need the "lib" prefix for modules?]) 2723247738Sbapt_LT_DECL([], [need_version], [0], [Do we need a version for libraries?]) 2724247738Sbapt_LT_DECL([], [version_type], [0], [Library versioning type]) 2725247738Sbapt_LT_DECL([], [runpath_var], [0], [Shared library runtime path variable]) 2726247738Sbapt_LT_DECL([], [shlibpath_var], [0],[Shared library path variable]) 2727247738Sbapt_LT_DECL([], [shlibpath_overrides_runpath], [0], 2728247738Sbapt [Is shlibpath searched before the hard-coded library search path?]) 2729247738Sbapt_LT_DECL([], [libname_spec], [1], [Format of library name prefix]) 2730247738Sbapt_LT_DECL([], [library_names_spec], [1], 2731247738Sbapt [[List of archive names. First name is the real one, the rest are links. 2732247738Sbapt The last name is the one that the linker finds with -lNAME]]) 2733247738Sbapt_LT_DECL([], [soname_spec], [1], 2734247738Sbapt [[The coded name of the library, if different from the real name]]) 2735247738Sbapt_LT_DECL([], [postinstall_cmds], [2], 2736247738Sbapt [Command to use after installation of a shared archive]) 2737247738Sbapt_LT_DECL([], [postuninstall_cmds], [2], 2738247738Sbapt [Command to use after uninstallation of a shared archive]) 2739247738Sbapt_LT_DECL([], [finish_cmds], [2], 2740247738Sbapt [Commands used to finish a libtool library installation in a directory]) 2741247738Sbapt_LT_DECL([], [finish_eval], [1], 2742247738Sbapt [[As "finish_cmds", except a single script fragment to be evaled but 2743247738Sbapt not shown]]) 2744247738Sbapt_LT_DECL([], [hardcode_into_libs], [0], 2745247738Sbapt [Whether we should hardcode library paths into libraries]) 2746247738Sbapt_LT_DECL([], [sys_lib_search_path_spec], [2], 2747247738Sbapt [Compile-time system search path for libraries]) 2748247738Sbapt_LT_DECL([], [sys_lib_dlsearch_path_spec], [2], 2749247738Sbapt [Run-time system search path for libraries]) 2750247738Sbapt])# _LT_SYS_DYNAMIC_LINKER 2751247738Sbapt 2752247738Sbapt 2753247738Sbapt# _LT_PATH_TOOL_PREFIX(TOOL) 2754247738Sbapt# -------------------------- 2755247738Sbapt# find a file program which can recognize shared library 2756247738SbaptAC_DEFUN([_LT_PATH_TOOL_PREFIX], 2757247738Sbapt[m4_require([_LT_DECL_EGREP])dnl 2758247738SbaptAC_MSG_CHECKING([for $1]) 2759247738SbaptAC_CACHE_VAL(lt_cv_path_MAGIC_CMD, 2760247738Sbapt[case $MAGIC_CMD in 2761247738Sbapt[[\\/*] | ?:[\\/]*]) 2762247738Sbapt lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. 2763247738Sbapt ;; 2764247738Sbapt*) 2765247738Sbapt lt_save_MAGIC_CMD="$MAGIC_CMD" 2766247738Sbapt lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR 2767247738Sbaptdnl $ac_dummy forces splitting on constant user-supplied paths. 2768247738Sbaptdnl POSIX.2 word splitting is done only on the output of word expansions, 2769247738Sbaptdnl not every word. This closes a longstanding sh security hole. 2770247738Sbapt ac_dummy="m4_if([$2], , $PATH, [$2])" 2771247738Sbapt for ac_dir in $ac_dummy; do 2772247738Sbapt IFS="$lt_save_ifs" 2773247738Sbapt test -z "$ac_dir" && ac_dir=. 2774247738Sbapt if test -f $ac_dir/$1; then 2775247738Sbapt lt_cv_path_MAGIC_CMD="$ac_dir/$1" 2776247738Sbapt if test -n "$file_magic_test_file"; then 2777247738Sbapt case $deplibs_check_method in 2778247738Sbapt "file_magic "*) 2779247738Sbapt file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` 2780247738Sbapt MAGIC_CMD="$lt_cv_path_MAGIC_CMD" 2781247738Sbapt if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | 2782247738Sbapt $EGREP "$file_magic_regex" > /dev/null; then 2783247738Sbapt : 2784247738Sbapt else 2785247738Sbapt cat <<_LT_EOF 1>&2 2786247738Sbapt 2787247738Sbapt*** Warning: the command libtool uses to detect shared libraries, 2788247738Sbapt*** $file_magic_cmd, produces output that libtool cannot recognize. 2789247738Sbapt*** The result is that libtool may fail to recognize shared libraries 2790247738Sbapt*** as such. This will affect the creation of libtool libraries that 2791247738Sbapt*** depend on shared libraries, but programs linked with such libtool 2792247738Sbapt*** libraries will work regardless of this problem. Nevertheless, you 2793247738Sbapt*** may want to report the problem to your system manager and/or to 2794247738Sbapt*** bug-libtool@gnu.org 2795247738Sbapt 2796247738Sbapt_LT_EOF 2797247738Sbapt fi ;; 2798247738Sbapt esac 2799247738Sbapt fi 2800247738Sbapt break 2801247738Sbapt fi 2802247738Sbapt done 2803247738Sbapt IFS="$lt_save_ifs" 2804247738Sbapt MAGIC_CMD="$lt_save_MAGIC_CMD" 2805247738Sbapt ;; 2806247738Sbaptesac]) 2807247738SbaptMAGIC_CMD="$lt_cv_path_MAGIC_CMD" 2808247738Sbaptif test -n "$MAGIC_CMD"; then 2809247738Sbapt AC_MSG_RESULT($MAGIC_CMD) 2810247738Sbaptelse 2811247738Sbapt AC_MSG_RESULT(no) 2812247738Sbaptfi 2813247738Sbapt_LT_DECL([], [MAGIC_CMD], [0], 2814247738Sbapt [Used to examine libraries when file_magic_cmd begins with "file"])dnl 2815247738Sbapt])# _LT_PATH_TOOL_PREFIX 2816247738Sbapt 2817247738Sbapt# Old name: 2818247738SbaptAU_ALIAS([AC_PATH_TOOL_PREFIX], [_LT_PATH_TOOL_PREFIX]) 2819247738Sbaptdnl aclocal-1.4 backwards compatibility: 2820247738Sbaptdnl AC_DEFUN([AC_PATH_TOOL_PREFIX], []) 2821247738Sbapt 2822247738Sbapt 2823247738Sbapt# _LT_PATH_MAGIC 2824247738Sbapt# -------------- 2825247738Sbapt# find a file program which can recognize a shared library 2826247738Sbaptm4_defun([_LT_PATH_MAGIC], 2827247738Sbapt[_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH) 2828247738Sbaptif test -z "$lt_cv_path_MAGIC_CMD"; then 2829247738Sbapt if test -n "$ac_tool_prefix"; then 2830247738Sbapt _LT_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH) 2831247738Sbapt else 2832247738Sbapt MAGIC_CMD=: 2833247738Sbapt fi 2834247738Sbaptfi 2835247738Sbapt])# _LT_PATH_MAGIC 2836247738Sbapt 2837247738Sbapt 2838247738Sbapt# LT_PATH_LD 2839247738Sbapt# ---------- 2840247738Sbapt# find the pathname to the GNU or non-GNU linker 2841247738SbaptAC_DEFUN([LT_PATH_LD], 2842247738Sbapt[AC_REQUIRE([AC_PROG_CC])dnl 2843247738SbaptAC_REQUIRE([AC_CANONICAL_HOST])dnl 2844247738SbaptAC_REQUIRE([AC_CANONICAL_BUILD])dnl 2845247738Sbaptm4_require([_LT_DECL_SED])dnl 2846247738Sbaptm4_require([_LT_DECL_EGREP])dnl 2847247738Sbapt 2848247738SbaptAC_ARG_WITH([gnu-ld], 2849247738Sbapt [AS_HELP_STRING([--with-gnu-ld], 2850247738Sbapt [assume the C compiler uses GNU ld @<:@default=no@:>@])], 2851247738Sbapt [test "$withval" = no || with_gnu_ld=yes], 2852247738Sbapt [with_gnu_ld=no])dnl 2853247738Sbapt 2854247738Sbaptac_prog=ld 2855247738Sbaptif test "$GCC" = yes; then 2856247738Sbapt # Check if gcc -print-prog-name=ld gives a path. 2857247738Sbapt AC_MSG_CHECKING([for ld used by $CC]) 2858247738Sbapt case $host in 2859247738Sbapt *-*-mingw*) 2860247738Sbapt # gcc leaves a trailing carriage return which upsets mingw 2861247738Sbapt ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; 2862247738Sbapt *) 2863247738Sbapt ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; 2864247738Sbapt esac 2865247738Sbapt case $ac_prog in 2866247738Sbapt # Accept absolute paths. 2867247738Sbapt [[\\/]]* | ?:[[\\/]]*) 2868247738Sbapt re_direlt='/[[^/]][[^/]]*/\.\./' 2869247738Sbapt # Canonicalize the pathname of ld 2870247738Sbapt ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` 2871247738Sbapt while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do 2872247738Sbapt ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` 2873247738Sbapt done 2874247738Sbapt test -z "$LD" && LD="$ac_prog" 2875247738Sbapt ;; 2876247738Sbapt "") 2877247738Sbapt # If it fails, then pretend we aren't using GCC. 2878247738Sbapt ac_prog=ld 2879247738Sbapt ;; 2880247738Sbapt *) 2881247738Sbapt # If it is relative, then search for the first ld in PATH. 2882247738Sbapt with_gnu_ld=unknown 2883247738Sbapt ;; 2884247738Sbapt esac 2885247738Sbaptelif test "$with_gnu_ld" = yes; then 2886247738Sbapt AC_MSG_CHECKING([for GNU ld]) 2887247738Sbaptelse 2888247738Sbapt AC_MSG_CHECKING([for non-GNU ld]) 2889247738Sbaptfi 2890247738SbaptAC_CACHE_VAL(lt_cv_path_LD, 2891247738Sbapt[if test -z "$LD"; then 2892247738Sbapt lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR 2893247738Sbapt for ac_dir in $PATH; do 2894247738Sbapt IFS="$lt_save_ifs" 2895247738Sbapt test -z "$ac_dir" && ac_dir=. 2896247738Sbapt if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then 2897247738Sbapt lt_cv_path_LD="$ac_dir/$ac_prog" 2898247738Sbapt # Check to see if the program is GNU ld. I'd rather use --version, 2899247738Sbapt # but apparently some variants of GNU ld only accept -v. 2900247738Sbapt # Break only if it was the GNU/non-GNU ld that we prefer. 2901247738Sbapt case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in 2902247738Sbapt *GNU* | *'with BFD'*) 2903247738Sbapt test "$with_gnu_ld" != no && break 2904247738Sbapt ;; 2905247738Sbapt *) 2906247738Sbapt test "$with_gnu_ld" != yes && break 2907247738Sbapt ;; 2908247738Sbapt esac 2909247738Sbapt fi 2910247738Sbapt done 2911247738Sbapt IFS="$lt_save_ifs" 2912247738Sbaptelse 2913247738Sbapt lt_cv_path_LD="$LD" # Let the user override the test with a path. 2914247738Sbaptfi]) 2915247738SbaptLD="$lt_cv_path_LD" 2916247738Sbaptif test -n "$LD"; then 2917247738Sbapt AC_MSG_RESULT($LD) 2918247738Sbaptelse 2919247738Sbapt AC_MSG_RESULT(no) 2920247738Sbaptfi 2921247738Sbapttest -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH]) 2922247738Sbapt_LT_PATH_LD_GNU 2923247738SbaptAC_SUBST([LD]) 2924247738Sbapt 2925247738Sbapt_LT_TAGDECL([], [LD], [1], [The linker used to build libraries]) 2926247738Sbapt])# LT_PATH_LD 2927247738Sbapt 2928247738Sbapt# Old names: 2929247738SbaptAU_ALIAS([AM_PROG_LD], [LT_PATH_LD]) 2930247738SbaptAU_ALIAS([AC_PROG_LD], [LT_PATH_LD]) 2931247738Sbaptdnl aclocal-1.4 backwards compatibility: 2932247738Sbaptdnl AC_DEFUN([AM_PROG_LD], []) 2933247738Sbaptdnl AC_DEFUN([AC_PROG_LD], []) 2934247738Sbapt 2935247738Sbapt 2936247738Sbapt# _LT_PATH_LD_GNU 2937247738Sbapt#- -------------- 2938247738Sbaptm4_defun([_LT_PATH_LD_GNU], 2939247738Sbapt[AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld, 2940247738Sbapt[# I'd rather use --version here, but apparently some GNU lds only accept -v. 2941247738Sbaptcase `$LD -v 2>&1 </dev/null` in 2942247738Sbapt*GNU* | *'with BFD'*) 2943247738Sbapt lt_cv_prog_gnu_ld=yes 2944247738Sbapt ;; 2945247738Sbapt*) 2946247738Sbapt lt_cv_prog_gnu_ld=no 2947247738Sbapt ;; 2948247738Sbaptesac]) 2949247738Sbaptwith_gnu_ld=$lt_cv_prog_gnu_ld 2950247738Sbapt])# _LT_PATH_LD_GNU 2951247738Sbapt 2952247738Sbapt 2953247738Sbapt# _LT_CMD_RELOAD 2954247738Sbapt# -------------- 2955247738Sbapt# find reload flag for linker 2956247738Sbapt# -- PORTME Some linkers may need a different reload flag. 2957247738Sbaptm4_defun([_LT_CMD_RELOAD], 2958247738Sbapt[AC_CACHE_CHECK([for $LD option to reload object files], 2959247738Sbapt lt_cv_ld_reload_flag, 2960247738Sbapt [lt_cv_ld_reload_flag='-r']) 2961247738Sbaptreload_flag=$lt_cv_ld_reload_flag 2962247738Sbaptcase $reload_flag in 2963247738Sbapt"" | " "*) ;; 2964247738Sbapt*) reload_flag=" $reload_flag" ;; 2965247738Sbaptesac 2966247738Sbaptreload_cmds='$LD$reload_flag -o $output$reload_objs' 2967247738Sbaptcase $host_os in 2968247738Sbapt darwin*) 2969247738Sbapt if test "$GCC" = yes; then 2970247738Sbapt reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs' 2971247738Sbapt else 2972247738Sbapt reload_cmds='$LD$reload_flag -o $output$reload_objs' 2973247738Sbapt fi 2974247738Sbapt ;; 2975247738Sbaptesac 2976247738Sbapt_LT_DECL([], [reload_flag], [1], [How to create reloadable object files])dnl 2977247738Sbapt_LT_DECL([], [reload_cmds], [2])dnl 2978247738Sbapt])# _LT_CMD_RELOAD 2979247738Sbapt 2980247738Sbapt 2981247738Sbapt# _LT_CHECK_MAGIC_METHOD 2982247738Sbapt# ---------------------- 2983247738Sbapt# how to check for library dependencies 2984247738Sbapt# -- PORTME fill in with the dynamic library characteristics 2985247738Sbaptm4_defun([_LT_CHECK_MAGIC_METHOD], 2986247738Sbapt[m4_require([_LT_DECL_EGREP]) 2987247738Sbaptm4_require([_LT_DECL_OBJDUMP]) 2988247738SbaptAC_CACHE_CHECK([how to recognize dependent libraries], 2989247738Sbaptlt_cv_deplibs_check_method, 2990247738Sbapt[lt_cv_file_magic_cmd='$MAGIC_CMD' 2991247738Sbaptlt_cv_file_magic_test_file= 2992247738Sbaptlt_cv_deplibs_check_method='unknown' 2993247738Sbapt# Need to set the preceding variable on all platforms that support 2994247738Sbapt# interlibrary dependencies. 2995247738Sbapt# 'none' -- dependencies not supported. 2996247738Sbapt# `unknown' -- same as none, but documents that we really don't know. 2997247738Sbapt# 'pass_all' -- all dependencies passed with no checks. 2998247738Sbapt# 'test_compile' -- check by making test program. 2999247738Sbapt# 'file_magic [[regex]]' -- check by looking for files in library path 3000247738Sbapt# which responds to the $file_magic_cmd with a given extended regex. 3001247738Sbapt# If you have `file' or equivalent on your system and you're not sure 3002247738Sbapt# whether `pass_all' will *always* work, you probably want this one. 3003247738Sbapt 3004247738Sbaptcase $host_os in 3005247738Sbaptaix[[4-9]]*) 3006247738Sbapt lt_cv_deplibs_check_method=pass_all 3007247738Sbapt ;; 3008247738Sbapt 3009247738Sbaptbeos*) 3010247738Sbapt lt_cv_deplibs_check_method=pass_all 3011247738Sbapt ;; 3012247738Sbapt 3013247738Sbaptbsdi[[45]]*) 3014247738Sbapt lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)' 3015247738Sbapt lt_cv_file_magic_cmd='/usr/bin/file -L' 3016247738Sbapt lt_cv_file_magic_test_file=/shlib/libc.so 3017247738Sbapt ;; 3018247738Sbapt 3019247738Sbaptcygwin*) 3020247738Sbapt # func_win32_libid is a shell function defined in ltmain.sh 3021247738Sbapt lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' 3022247738Sbapt lt_cv_file_magic_cmd='func_win32_libid' 3023247738Sbapt ;; 3024247738Sbapt 3025247738Sbaptmingw* | pw32*) 3026247738Sbapt # Base MSYS/MinGW do not provide the 'file' command needed by 3027247738Sbapt # func_win32_libid shell function, so use a weaker test based on 'objdump', 3028247738Sbapt # unless we find 'file', for example because we are cross-compiling. 3029247738Sbapt if ( file / ) >/dev/null 2>&1; then 3030247738Sbapt lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' 3031247738Sbapt lt_cv_file_magic_cmd='func_win32_libid' 3032247738Sbapt else 3033247738Sbapt lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?' 3034247738Sbapt lt_cv_file_magic_cmd='$OBJDUMP -f' 3035247738Sbapt fi 3036247738Sbapt ;; 3037247738Sbapt 3038247738Sbaptcegcc) 3039247738Sbapt # use the weaker test based on 'objdump'. See mingw*. 3040247738Sbapt lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?' 3041247738Sbapt lt_cv_file_magic_cmd='$OBJDUMP -f' 3042247738Sbapt ;; 3043247738Sbapt 3044247738Sbaptdarwin* | rhapsody*) 3045247738Sbapt lt_cv_deplibs_check_method=pass_all 3046247738Sbapt ;; 3047247738Sbapt 3048247738Sbaptfreebsd* | dragonfly*) 3049247738Sbapt if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then 3050247738Sbapt case $host_cpu in 3051247738Sbapt i*86 ) 3052247738Sbapt # Not sure whether the presence of OpenBSD here was a mistake. 3053247738Sbapt # Let's accept both of them until this is cleared up. 3054247738Sbapt lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library' 3055247738Sbapt lt_cv_file_magic_cmd=/usr/bin/file 3056247738Sbapt lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` 3057247738Sbapt ;; 3058247738Sbapt esac 3059247738Sbapt else 3060247738Sbapt lt_cv_deplibs_check_method=pass_all 3061247738Sbapt fi 3062247738Sbapt ;; 3063247738Sbapt 3064247738Sbaptgnu*) 3065247738Sbapt lt_cv_deplibs_check_method=pass_all 3066247738Sbapt ;; 3067247738Sbapt 3068247738Sbapthpux10.20* | hpux11*) 3069247738Sbapt lt_cv_file_magic_cmd=/usr/bin/file 3070247738Sbapt case $host_cpu in 3071247738Sbapt ia64*) 3072247738Sbapt lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64' 3073247738Sbapt lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so 3074247738Sbapt ;; 3075247738Sbapt hppa*64*) 3076247738Sbapt [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - PA-RISC [0-9].[0-9]'] 3077247738Sbapt lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl 3078247738Sbapt ;; 3079247738Sbapt *) 3080247738Sbapt lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]].[[0-9]]) shared library' 3081247738Sbapt lt_cv_file_magic_test_file=/usr/lib/libc.sl 3082247738Sbapt ;; 3083247738Sbapt esac 3084247738Sbapt ;; 3085247738Sbapt 3086247738Sbaptinterix[[3-9]]*) 3087247738Sbapt # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here 3088247738Sbapt lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$' 3089247738Sbapt ;; 3090247738Sbapt 3091247738Sbaptirix5* | irix6* | nonstopux*) 3092247738Sbapt case $LD in 3093247738Sbapt *-32|*"-32 ") libmagic=32-bit;; 3094247738Sbapt *-n32|*"-n32 ") libmagic=N32;; 3095247738Sbapt *-64|*"-64 ") libmagic=64-bit;; 3096247738Sbapt *) libmagic=never-match;; 3097247738Sbapt esac 3098247738Sbapt lt_cv_deplibs_check_method=pass_all 3099247738Sbapt ;; 3100247738Sbapt 3101247738Sbapt# This must be Linux ELF. 3102247738Sbaptlinux* | k*bsd*-gnu | kopensolaris*-gnu) 3103247738Sbapt lt_cv_deplibs_check_method=pass_all 3104247738Sbapt ;; 3105247738Sbapt 3106247738Sbaptnetbsd* | netbsdelf*-gnu) 3107247738Sbapt if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then 3108247738Sbapt lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' 3109247738Sbapt else 3110247738Sbapt lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$' 3111247738Sbapt fi 3112247738Sbapt ;; 3113247738Sbapt 3114247738Sbaptnewos6*) 3115247738Sbapt lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)' 3116247738Sbapt lt_cv_file_magic_cmd=/usr/bin/file 3117247738Sbapt lt_cv_file_magic_test_file=/usr/lib/libnls.so 3118247738Sbapt ;; 3119247738Sbapt 3120247738Sbapt*nto* | *qnx*) 3121247738Sbapt lt_cv_deplibs_check_method=pass_all 3122247738Sbapt ;; 3123247738Sbapt 3124247738Sbaptopenbsd*) 3125247738Sbapt if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then 3126247738Sbapt lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$' 3127247738Sbapt else 3128247738Sbapt lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' 3129247738Sbapt fi 3130247738Sbapt ;; 3131247738Sbapt 3132247738Sbaptosf3* | osf4* | osf5*) 3133247738Sbapt lt_cv_deplibs_check_method=pass_all 3134247738Sbapt ;; 3135247738Sbapt 3136247738Sbaptrdos*) 3137247738Sbapt lt_cv_deplibs_check_method=pass_all 3138247738Sbapt ;; 3139247738Sbapt 3140247738Sbaptsolaris*) 3141247738Sbapt lt_cv_deplibs_check_method=pass_all 3142247738Sbapt ;; 3143247738Sbapt 3144247738Sbaptsysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) 3145247738Sbapt lt_cv_deplibs_check_method=pass_all 3146247738Sbapt ;; 3147247738Sbapt 3148247738Sbaptsysv4 | sysv4.3*) 3149247738Sbapt case $host_vendor in 3150247738Sbapt motorola) 3151247738Sbapt 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]]' 3152247738Sbapt lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` 3153247738Sbapt ;; 3154247738Sbapt ncr) 3155247738Sbapt lt_cv_deplibs_check_method=pass_all 3156247738Sbapt ;; 3157247738Sbapt sequent) 3158247738Sbapt lt_cv_file_magic_cmd='/bin/file' 3159247738Sbapt lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )' 3160247738Sbapt ;; 3161247738Sbapt sni) 3162247738Sbapt lt_cv_file_magic_cmd='/bin/file' 3163247738Sbapt lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib" 3164247738Sbapt lt_cv_file_magic_test_file=/lib/libc.so 3165247738Sbapt ;; 3166247738Sbapt siemens) 3167247738Sbapt lt_cv_deplibs_check_method=pass_all 3168247738Sbapt ;; 3169247738Sbapt pc) 3170247738Sbapt lt_cv_deplibs_check_method=pass_all 3171247738Sbapt ;; 3172247738Sbapt esac 3173247738Sbapt ;; 3174247738Sbapt 3175247738Sbapttpf*) 3176247738Sbapt lt_cv_deplibs_check_method=pass_all 3177247738Sbapt ;; 3178247738Sbaptesac 3179247738Sbapt]) 3180247738Sbaptfile_magic_cmd=$lt_cv_file_magic_cmd 3181247738Sbaptdeplibs_check_method=$lt_cv_deplibs_check_method 3182247738Sbapttest -z "$deplibs_check_method" && deplibs_check_method=unknown 3183247738Sbapt 3184247738Sbapt_LT_DECL([], [deplibs_check_method], [1], 3185247738Sbapt [Method to check whether dependent libraries are shared objects]) 3186247738Sbapt_LT_DECL([], [file_magic_cmd], [1], 3187247738Sbapt [Command to use when deplibs_check_method == "file_magic"]) 3188247738Sbapt])# _LT_CHECK_MAGIC_METHOD 3189247738Sbapt 3190247738Sbapt 3191247738Sbapt# LT_PATH_NM 3192247738Sbapt# ---------- 3193247738Sbapt# find the pathname to a BSD- or MS-compatible name lister 3194247738SbaptAC_DEFUN([LT_PATH_NM], 3195247738Sbapt[AC_REQUIRE([AC_PROG_CC])dnl 3196247738SbaptAC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM, 3197247738Sbapt[if test -n "$NM"; then 3198247738Sbapt # Let the user override the test. 3199247738Sbapt lt_cv_path_NM="$NM" 3200247738Sbaptelse 3201247738Sbapt lt_nm_to_check="${ac_tool_prefix}nm" 3202247738Sbapt if test -n "$ac_tool_prefix" && test "$build" = "$host"; then 3203247738Sbapt lt_nm_to_check="$lt_nm_to_check nm" 3204247738Sbapt fi 3205247738Sbapt for lt_tmp_nm in $lt_nm_to_check; do 3206247738Sbapt lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR 3207247738Sbapt for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do 3208247738Sbapt IFS="$lt_save_ifs" 3209247738Sbapt test -z "$ac_dir" && ac_dir=. 3210247738Sbapt tmp_nm="$ac_dir/$lt_tmp_nm" 3211247738Sbapt if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then 3212247738Sbapt # Check to see if the nm accepts a BSD-compat flag. 3213247738Sbapt # Adding the `sed 1q' prevents false positives on HP-UX, which says: 3214247738Sbapt # nm: unknown option "B" ignored 3215247738Sbapt # Tru64's nm complains that /dev/null is an invalid object file 3216247738Sbapt case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in 3217247738Sbapt */dev/null* | *'Invalid file or object type'*) 3218247738Sbapt lt_cv_path_NM="$tmp_nm -B" 3219247738Sbapt break 3220247738Sbapt ;; 3221247738Sbapt *) 3222247738Sbapt case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in 3223247738Sbapt */dev/null*) 3224247738Sbapt lt_cv_path_NM="$tmp_nm -p" 3225247738Sbapt break 3226247738Sbapt ;; 3227247738Sbapt *) 3228247738Sbapt lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but 3229247738Sbapt continue # so that we can try to find one that supports BSD flags 3230247738Sbapt ;; 3231247738Sbapt esac 3232247738Sbapt ;; 3233247738Sbapt esac 3234247738Sbapt fi 3235247738Sbapt done 3236247738Sbapt IFS="$lt_save_ifs" 3237247738Sbapt done 3238247738Sbapt : ${lt_cv_path_NM=no} 3239247738Sbaptfi]) 3240247738Sbaptif test "$lt_cv_path_NM" != "no"; then 3241247738Sbapt NM="$lt_cv_path_NM" 3242247738Sbaptelse 3243247738Sbapt # Didn't find any BSD compatible name lister, look for dumpbin. 3244247738Sbapt AC_CHECK_TOOLS(DUMPBIN, ["dumpbin -symbols" "link -dump -symbols"], :) 3245247738Sbapt AC_SUBST([DUMPBIN]) 3246247738Sbapt if test "$DUMPBIN" != ":"; then 3247247738Sbapt NM="$DUMPBIN" 3248247738Sbapt fi 3249247738Sbaptfi 3250247738Sbapttest -z "$NM" && NM=nm 3251247738SbaptAC_SUBST([NM]) 3252247738Sbapt_LT_DECL([], [NM], [1], [A BSD- or MS-compatible name lister])dnl 3253247738Sbapt 3254247738SbaptAC_CACHE_CHECK([the name lister ($NM) interface], [lt_cv_nm_interface], 3255247738Sbapt [lt_cv_nm_interface="BSD nm" 3256247738Sbapt echo "int some_variable = 0;" > conftest.$ac_ext 3257247738Sbapt (eval echo "\"\$as_me:__oline__: $ac_compile\"" >&AS_MESSAGE_LOG_FD) 3258247738Sbapt (eval "$ac_compile" 2>conftest.err) 3259247738Sbapt cat conftest.err >&AS_MESSAGE_LOG_FD 3260247738Sbapt (eval echo "\"\$as_me:__oline__: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD) 3261247738Sbapt (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) 3262247738Sbapt cat conftest.err >&AS_MESSAGE_LOG_FD 3263247738Sbapt (eval echo "\"\$as_me:__oline__: output\"" >&AS_MESSAGE_LOG_FD) 3264247738Sbapt cat conftest.out >&AS_MESSAGE_LOG_FD 3265247738Sbapt if $GREP 'External.*some_variable' conftest.out > /dev/null; then 3266247738Sbapt lt_cv_nm_interface="MS dumpbin" 3267247738Sbapt fi 3268247738Sbapt rm -f conftest*]) 3269247738Sbapt])# LT_PATH_NM 3270247738Sbapt 3271247738Sbapt# Old names: 3272247738SbaptAU_ALIAS([AM_PROG_NM], [LT_PATH_NM]) 3273247738SbaptAU_ALIAS([AC_PROG_NM], [LT_PATH_NM]) 3274247738Sbaptdnl aclocal-1.4 backwards compatibility: 3275247738Sbaptdnl AC_DEFUN([AM_PROG_NM], []) 3276247738Sbaptdnl AC_DEFUN([AC_PROG_NM], []) 3277247738Sbapt 3278247738Sbapt 3279247738Sbapt# LT_LIB_M 3280247738Sbapt# -------- 3281247738Sbapt# check for math library 3282247738SbaptAC_DEFUN([LT_LIB_M], 3283247738Sbapt[AC_REQUIRE([AC_CANONICAL_HOST])dnl 3284247738SbaptLIBM= 3285247738Sbaptcase $host in 3286247738Sbapt*-*-beos* | *-*-cygwin* | *-*-pw32* | *-*-darwin*) 3287247738Sbapt # These system don't have libm, or don't need it 3288247738Sbapt ;; 3289247738Sbapt*-ncr-sysv4.3*) 3290247738Sbapt AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw") 3291247738Sbapt AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm") 3292247738Sbapt ;; 3293247738Sbapt*) 3294247738Sbapt AC_CHECK_LIB(m, cos, LIBM="-lm") 3295247738Sbapt ;; 3296247738Sbaptesac 3297247738SbaptAC_SUBST([LIBM]) 3298247738Sbapt])# LT_LIB_M 3299247738Sbapt 3300247738Sbapt# Old name: 3301247738SbaptAU_ALIAS([AC_CHECK_LIBM], [LT_LIB_M]) 3302247738Sbaptdnl aclocal-1.4 backwards compatibility: 3303247738Sbaptdnl AC_DEFUN([AC_CHECK_LIBM], []) 3304247738Sbapt 3305247738Sbapt 3306247738Sbapt# _LT_COMPILER_NO_RTTI([TAGNAME]) 3307247738Sbapt# ------------------------------- 3308247738Sbaptm4_defun([_LT_COMPILER_NO_RTTI], 3309247738Sbapt[m4_require([_LT_TAG_COMPILER])dnl 3310247738Sbapt 3311247738Sbapt_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= 3312247738Sbapt 3313247738Sbaptif test "$GCC" = yes; then 3314247738Sbapt _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' 3315247738Sbapt 3316247738Sbapt _LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions], 3317247738Sbapt lt_cv_prog_compiler_rtti_exceptions, 3318247738Sbapt [-fno-rtti -fno-exceptions], [], 3319247738Sbapt [_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"]) 3320247738Sbaptfi 3321247738Sbapt_LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1], 3322247738Sbapt [Compiler flag to turn off builtin functions]) 3323247738Sbapt])# _LT_COMPILER_NO_RTTI 3324247738Sbapt 3325247738Sbapt 3326247738Sbapt# _LT_CMD_GLOBAL_SYMBOLS 3327247738Sbapt# ---------------------- 3328247738Sbaptm4_defun([_LT_CMD_GLOBAL_SYMBOLS], 3329247738Sbapt[AC_REQUIRE([AC_CANONICAL_HOST])dnl 3330247738SbaptAC_REQUIRE([AC_PROG_CC])dnl 3331247738SbaptAC_REQUIRE([LT_PATH_NM])dnl 3332247738SbaptAC_REQUIRE([LT_PATH_LD])dnl 3333247738Sbaptm4_require([_LT_DECL_SED])dnl 3334247738Sbaptm4_require([_LT_DECL_EGREP])dnl 3335247738Sbaptm4_require([_LT_TAG_COMPILER])dnl 3336247738Sbapt 3337247738Sbapt# Check for command to grab the raw symbol name followed by C symbol from nm. 3338247738SbaptAC_MSG_CHECKING([command to parse $NM output from $compiler object]) 3339247738SbaptAC_CACHE_VAL([lt_cv_sys_global_symbol_pipe], 3340247738Sbapt[ 3341247738Sbapt# These are sane defaults that work on at least a few old systems. 3342247738Sbapt# [They come from Ultrix. What could be older than Ultrix?!! ;)] 3343247738Sbapt 3344247738Sbapt# Character class describing NM global symbol codes. 3345247738Sbaptsymcode='[[BCDEGRST]]' 3346247738Sbapt 3347247738Sbapt# Regexp to match symbols that can be accessed directly from C. 3348247738Sbaptsympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)' 3349247738Sbapt 3350247738Sbapt# Define system-specific variables. 3351247738Sbaptcase $host_os in 3352247738Sbaptaix*) 3353247738Sbapt symcode='[[BCDT]]' 3354247738Sbapt ;; 3355247738Sbaptcygwin* | mingw* | pw32* | cegcc*) 3356247738Sbapt symcode='[[ABCDGISTW]]' 3357247738Sbapt ;; 3358247738Sbapthpux*) 3359247738Sbapt if test "$host_cpu" = ia64; then 3360247738Sbapt symcode='[[ABCDEGRST]]' 3361247738Sbapt fi 3362247738Sbapt ;; 3363247738Sbaptirix* | nonstopux*) 3364247738Sbapt symcode='[[BCDEGRST]]' 3365247738Sbapt ;; 3366247738Sbaptosf*) 3367247738Sbapt symcode='[[BCDEGQRST]]' 3368247738Sbapt ;; 3369247738Sbaptsolaris*) 3370247738Sbapt symcode='[[BDRT]]' 3371247738Sbapt ;; 3372247738Sbaptsco3.2v5*) 3373247738Sbapt symcode='[[DT]]' 3374247738Sbapt ;; 3375247738Sbaptsysv4.2uw2*) 3376247738Sbapt symcode='[[DT]]' 3377247738Sbapt ;; 3378247738Sbaptsysv5* | sco5v6* | unixware* | OpenUNIX*) 3379247738Sbapt symcode='[[ABDT]]' 3380247738Sbapt ;; 3381247738Sbaptsysv4) 3382247738Sbapt symcode='[[DFNSTU]]' 3383247738Sbapt ;; 3384247738Sbaptesac 3385247738Sbapt 3386247738Sbapt# If we're using GNU nm, then use its standard symbol codes. 3387247738Sbaptcase `$NM -V 2>&1` in 3388247738Sbapt*GNU* | *'with BFD'*) 3389247738Sbapt symcode='[[ABCDGIRSTW]]' ;; 3390247738Sbaptesac 3391247738Sbapt 3392247738Sbapt# Transform an extracted symbol line into a proper C declaration. 3393247738Sbapt# Some systems (esp. on ia64) link data and code symbols differently, 3394247738Sbapt# so use this general approach. 3395247738Sbaptlt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" 3396247738Sbapt 3397247738Sbapt# Transform an extracted symbol line into symbol name and symbol address 3398247738Sbaptlt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p'" 3399247738Sbaptlt_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'" 3400247738Sbapt 3401247738Sbapt# Handle CRLF in mingw tool chain 3402247738Sbaptopt_cr= 3403247738Sbaptcase $build_os in 3404247738Sbaptmingw*) 3405247738Sbapt opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp 3406247738Sbapt ;; 3407247738Sbaptesac 3408247738Sbapt 3409247738Sbapt# Try without a prefix underscore, then with it. 3410247738Sbaptfor ac_symprfx in "" "_"; do 3411247738Sbapt 3412247738Sbapt # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. 3413247738Sbapt symxfrm="\\1 $ac_symprfx\\2 \\2" 3414247738Sbapt 3415247738Sbapt # Write the raw and C identifiers. 3416247738Sbapt if test "$lt_cv_nm_interface" = "MS dumpbin"; then 3417247738Sbapt # Fake it for dumpbin and say T for any non-static function 3418247738Sbapt # and D for any global variable. 3419247738Sbapt # Also find C++ and __fastcall symbols from MSVC++, 3420247738Sbapt # which start with @ or ?. 3421247738Sbapt lt_cv_sys_global_symbol_pipe="$AWK ['"\ 3422247738Sbapt" {last_section=section; section=\$ 3};"\ 3423247738Sbapt" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\ 3424247738Sbapt" \$ 0!~/External *\|/{next};"\ 3425247738Sbapt" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\ 3426247738Sbapt" {if(hide[section]) next};"\ 3427247738Sbapt" {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\ 3428247738Sbapt" {split(\$ 0, a, /\||\r/); split(a[2], s)};"\ 3429247738Sbapt" s[1]~/^[@?]/{print s[1], s[1]; next};"\ 3430247738Sbapt" s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\ 3431247738Sbapt" ' prfx=^$ac_symprfx]" 3432247738Sbapt else 3433247738Sbapt lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" 3434247738Sbapt fi 3435247738Sbapt 3436247738Sbapt # Check to see that the pipe works correctly. 3437247738Sbapt pipe_works=no 3438247738Sbapt 3439247738Sbapt rm -f conftest* 3440247738Sbapt cat > conftest.$ac_ext <<_LT_EOF 3441247738Sbapt#ifdef __cplusplus 3442247738Sbaptextern "C" { 3443247738Sbapt#endif 3444247738Sbaptchar nm_test_var; 3445247738Sbaptvoid nm_test_func(void); 3446247738Sbaptvoid nm_test_func(void){} 3447247738Sbapt#ifdef __cplusplus 3448247738Sbapt} 3449247738Sbapt#endif 3450247738Sbaptint main(){nm_test_var='a';nm_test_func();return(0);} 3451247738Sbapt_LT_EOF 3452247738Sbapt 3453247738Sbapt if AC_TRY_EVAL(ac_compile); then 3454247738Sbapt # Now try to grab the symbols. 3455247738Sbapt nlist=conftest.nm 3456247738Sbapt if AC_TRY_EVAL(NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) && test -s "$nlist"; then 3457247738Sbapt # Try sorting and uniquifying the output. 3458247738Sbapt if sort "$nlist" | uniq > "$nlist"T; then 3459247738Sbapt mv -f "$nlist"T "$nlist" 3460247738Sbapt else 3461247738Sbapt rm -f "$nlist"T 3462247738Sbapt fi 3463247738Sbapt 3464247738Sbapt # Make sure that we snagged all the symbols we need. 3465247738Sbapt if $GREP ' nm_test_var$' "$nlist" >/dev/null; then 3466247738Sbapt if $GREP ' nm_test_func$' "$nlist" >/dev/null; then 3467247738Sbapt cat <<_LT_EOF > conftest.$ac_ext 3468247738Sbapt#ifdef __cplusplus 3469247738Sbaptextern "C" { 3470247738Sbapt#endif 3471247738Sbapt 3472247738Sbapt_LT_EOF 3473247738Sbapt # Now generate the symbol file. 3474247738Sbapt eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext' 3475247738Sbapt 3476247738Sbapt cat <<_LT_EOF >> conftest.$ac_ext 3477247738Sbapt 3478247738Sbapt/* The mapping between symbol names and symbols. */ 3479247738Sbaptconst struct { 3480247738Sbapt const char *name; 3481247738Sbapt void *address; 3482247738Sbapt} 3483247738Sbaptlt__PROGRAM__LTX_preloaded_symbols[[]] = 3484247738Sbapt{ 3485247738Sbapt { "@PROGRAM@", (void *) 0 }, 3486247738Sbapt_LT_EOF 3487247738Sbapt $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext 3488247738Sbapt cat <<\_LT_EOF >> conftest.$ac_ext 3489247738Sbapt {0, (void *) 0} 3490247738Sbapt}; 3491247738Sbapt 3492247738Sbapt/* This works around a problem in FreeBSD linker */ 3493247738Sbapt#ifdef FREEBSD_WORKAROUND 3494247738Sbaptstatic const void *lt_preloaded_setup() { 3495247738Sbapt return lt__PROGRAM__LTX_preloaded_symbols; 3496247738Sbapt} 3497247738Sbapt#endif 3498247738Sbapt 3499247738Sbapt#ifdef __cplusplus 3500247738Sbapt} 3501247738Sbapt#endif 3502247738Sbapt_LT_EOF 3503247738Sbapt # Now try linking the two files. 3504247738Sbapt mv conftest.$ac_objext conftstm.$ac_objext 3505247738Sbapt lt_save_LIBS="$LIBS" 3506247738Sbapt lt_save_CFLAGS="$CFLAGS" 3507247738Sbapt LIBS="conftstm.$ac_objext" 3508247738Sbapt CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)" 3509247738Sbapt if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then 3510247738Sbapt pipe_works=yes 3511247738Sbapt fi 3512247738Sbapt LIBS="$lt_save_LIBS" 3513247738Sbapt CFLAGS="$lt_save_CFLAGS" 3514247738Sbapt else 3515247738Sbapt echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD 3516247738Sbapt fi 3517247738Sbapt else 3518247738Sbapt echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD 3519247738Sbapt fi 3520247738Sbapt else 3521247738Sbapt echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD 3522247738Sbapt fi 3523247738Sbapt else 3524247738Sbapt echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD 3525247738Sbapt cat conftest.$ac_ext >&5 3526247738Sbapt fi 3527247738Sbapt rm -rf conftest* conftst* 3528247738Sbapt 3529247738Sbapt # Do not use the global_symbol_pipe unless it works. 3530247738Sbapt if test "$pipe_works" = yes; then 3531247738Sbapt break 3532247738Sbapt else 3533247738Sbapt lt_cv_sys_global_symbol_pipe= 3534247738Sbapt fi 3535247738Sbaptdone 3536247738Sbapt]) 3537247738Sbaptif test -z "$lt_cv_sys_global_symbol_pipe"; then 3538247738Sbapt lt_cv_sys_global_symbol_to_cdecl= 3539247738Sbaptfi 3540247738Sbaptif test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then 3541247738Sbapt AC_MSG_RESULT(failed) 3542247738Sbaptelse 3543247738Sbapt AC_MSG_RESULT(ok) 3544247738Sbaptfi 3545247738Sbapt 3546247738Sbapt_LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1], 3547247738Sbapt [Take the output of nm and produce a listing of raw symbols and C names]) 3548247738Sbapt_LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1], 3549247738Sbapt [Transform the output of nm in a proper C declaration]) 3550247738Sbapt_LT_DECL([global_symbol_to_c_name_address], 3551247738Sbapt [lt_cv_sys_global_symbol_to_c_name_address], [1], 3552247738Sbapt [Transform the output of nm in a C name address pair]) 3553247738Sbapt_LT_DECL([global_symbol_to_c_name_address_lib_prefix], 3554247738Sbapt [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1], 3555247738Sbapt [Transform the output of nm in a C name address pair when lib prefix is needed]) 3556247738Sbapt]) # _LT_CMD_GLOBAL_SYMBOLS 3557247738Sbapt 3558247738Sbapt 3559247738Sbapt# _LT_COMPILER_PIC([TAGNAME]) 3560247738Sbapt# --------------------------- 3561247738Sbaptm4_defun([_LT_COMPILER_PIC], 3562247738Sbapt[m4_require([_LT_TAG_COMPILER])dnl 3563247738Sbapt_LT_TAGVAR(lt_prog_compiler_wl, $1)= 3564247738Sbapt_LT_TAGVAR(lt_prog_compiler_pic, $1)= 3565247738Sbapt_LT_TAGVAR(lt_prog_compiler_static, $1)= 3566247738Sbapt 3567247738SbaptAC_MSG_CHECKING([for $compiler option to produce PIC]) 3568247738Sbaptm4_if([$1], [CXX], [ 3569247738Sbapt # C++ specific cases for pic, static, wl, etc. 3570247738Sbapt if test "$GXX" = yes; then 3571247738Sbapt _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 3572247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 3573247738Sbapt 3574247738Sbapt case $host_os in 3575247738Sbapt aix*) 3576247738Sbapt # All AIX code is PIC. 3577247738Sbapt if test "$host_cpu" = ia64; then 3578247738Sbapt # AIX 5 now supports IA64 processor 3579247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 3580247738Sbapt fi 3581247738Sbapt ;; 3582247738Sbapt 3583247738Sbapt amigaos*) 3584247738Sbapt case $host_cpu in 3585247738Sbapt powerpc) 3586247738Sbapt # see comment about AmigaOS4 .so support 3587247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 3588247738Sbapt ;; 3589247738Sbapt m68k) 3590247738Sbapt # FIXME: we need at least 68020 code to build shared libraries, but 3591247738Sbapt # adding the `-m68020' flag to GCC prevents building anything better, 3592247738Sbapt # like `-m68040'. 3593247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' 3594247738Sbapt ;; 3595247738Sbapt esac 3596247738Sbapt ;; 3597247738Sbapt 3598247738Sbapt beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) 3599247738Sbapt # PIC is the default for these OSes. 3600247738Sbapt ;; 3601247738Sbapt mingw* | cygwin* | os2* | pw32* | cegcc*) 3602247738Sbapt # This hack is so that the source file can tell whether it is being 3603247738Sbapt # built for inclusion in a dll (and should export symbols for example). 3604247738Sbapt # Although the cygwin gcc ignores -fPIC, still need this for old-style 3605247738Sbapt # (--disable-auto-import) libraries 3606247738Sbapt m4_if([$1], [GCJ], [], 3607247738Sbapt [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) 3608247738Sbapt ;; 3609247738Sbapt darwin* | rhapsody*) 3610247738Sbapt # PIC is the default on this platform 3611247738Sbapt # Common symbols not allowed in MH_DYLIB files 3612247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' 3613247738Sbapt ;; 3614247738Sbapt *djgpp*) 3615247738Sbapt # DJGPP does not support shared libraries at all 3616247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)= 3617247738Sbapt ;; 3618247738Sbapt interix[[3-9]]*) 3619247738Sbapt # Interix 3.x gcc -fpic/-fPIC options generate broken code. 3620247738Sbapt # Instead, we relocate shared libraries at runtime. 3621247738Sbapt ;; 3622247738Sbapt sysv4*MP*) 3623247738Sbapt if test -d /usr/nec; then 3624247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic 3625247738Sbapt fi 3626247738Sbapt ;; 3627247738Sbapt hpux*) 3628247738Sbapt # PIC is the default for 64-bit PA HP-UX, but not for 32-bit 3629247738Sbapt # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag 3630247738Sbapt # sets the default TLS model and affects inlining. 3631247738Sbapt case $host_cpu in 3632247738Sbapt hppa*64*) 3633247738Sbapt ;; 3634247738Sbapt *) 3635247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 3636247738Sbapt ;; 3637247738Sbapt esac 3638247738Sbapt ;; 3639247738Sbapt *qnx* | *nto*) 3640247738Sbapt # QNX uses GNU C++, but need to define -shared option too, otherwise 3641247738Sbapt # it will coredump. 3642247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' 3643247738Sbapt ;; 3644247738Sbapt *) 3645247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 3646247738Sbapt ;; 3647247738Sbapt esac 3648247738Sbapt else 3649247738Sbapt case $host_os in 3650247738Sbapt aix[[4-9]]*) 3651247738Sbapt # All AIX code is PIC. 3652247738Sbapt if test "$host_cpu" = ia64; then 3653247738Sbapt # AIX 5 now supports IA64 processor 3654247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 3655247738Sbapt else 3656247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' 3657247738Sbapt fi 3658247738Sbapt ;; 3659247738Sbapt chorus*) 3660247738Sbapt case $cc_basename in 3661247738Sbapt cxch68*) 3662247738Sbapt # Green Hills C++ Compiler 3663247738Sbapt # _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" 3664247738Sbapt ;; 3665247738Sbapt esac 3666247738Sbapt ;; 3667247738Sbapt dgux*) 3668247738Sbapt case $cc_basename in 3669247738Sbapt ec++*) 3670247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 3671247738Sbapt ;; 3672247738Sbapt ghcx*) 3673247738Sbapt # Green Hills C++ Compiler 3674247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 3675247738Sbapt ;; 3676247738Sbapt *) 3677247738Sbapt ;; 3678247738Sbapt esac 3679247738Sbapt ;; 3680247738Sbapt freebsd* | dragonfly*) 3681247738Sbapt # FreeBSD uses GNU C++ 3682247738Sbapt ;; 3683247738Sbapt hpux9* | hpux10* | hpux11*) 3684247738Sbapt case $cc_basename in 3685247738Sbapt CC*) 3686247738Sbapt _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 3687247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' 3688247738Sbapt if test "$host_cpu" != ia64; then 3689247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' 3690247738Sbapt fi 3691247738Sbapt ;; 3692247738Sbapt aCC*) 3693247738Sbapt _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 3694247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' 3695247738Sbapt case $host_cpu in 3696247738Sbapt hppa*64*|ia64*) 3697247738Sbapt # +Z the default 3698247738Sbapt ;; 3699247738Sbapt *) 3700247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' 3701247738Sbapt ;; 3702247738Sbapt esac 3703247738Sbapt ;; 3704247738Sbapt *) 3705247738Sbapt ;; 3706247738Sbapt esac 3707247738Sbapt ;; 3708247738Sbapt interix*) 3709247738Sbapt # This is c89, which is MS Visual C++ (no shared libs) 3710247738Sbapt # Anyone wants to do a port? 3711247738Sbapt ;; 3712247738Sbapt irix5* | irix6* | nonstopux*) 3713247738Sbapt case $cc_basename in 3714247738Sbapt CC*) 3715247738Sbapt _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 3716247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 3717247738Sbapt # CC pic flag -KPIC is the default. 3718247738Sbapt ;; 3719247738Sbapt *) 3720247738Sbapt ;; 3721247738Sbapt esac 3722247738Sbapt ;; 3723247738Sbapt linux* | k*bsd*-gnu | kopensolaris*-gnu) 3724247738Sbapt case $cc_basename in 3725247738Sbapt KCC*) 3726247738Sbapt # KAI C++ Compiler 3727247738Sbapt _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' 3728247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 3729247738Sbapt ;; 3730247738Sbapt ecpc* ) 3731247738Sbapt # old Intel C++ for x86_64 which still supported -KPIC. 3732247738Sbapt _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 3733247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 3734247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 3735247738Sbapt ;; 3736247738Sbapt icpc* ) 3737247738Sbapt # Intel C++, used to be incompatible with GCC. 3738247738Sbapt # ICC 10 doesn't accept -KPIC any more. 3739247738Sbapt _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 3740247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 3741247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 3742247738Sbapt ;; 3743247738Sbapt pgCC* | pgcpp*) 3744247738Sbapt # Portland Group C++ compiler 3745247738Sbapt _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 3746247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' 3747247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 3748247738Sbapt ;; 3749247738Sbapt cxx*) 3750247738Sbapt # Compaq C++ 3751247738Sbapt # Make sure the PIC flag is empty. It appears that all Alpha 3752247738Sbapt # Linux and Compaq Tru64 Unix objects are PIC. 3753247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)= 3754247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 3755247738Sbapt ;; 3756247738Sbapt xlc* | xlC*) 3757247738Sbapt # IBM XL 8.0 on PPC 3758247738Sbapt _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 3759247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' 3760247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' 3761247738Sbapt ;; 3762247738Sbapt *) 3763247738Sbapt case `$CC -V 2>&1 | sed 5q` in 3764247738Sbapt *Sun\ C*) 3765247738Sbapt # Sun C++ 5.9 3766247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 3767247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 3768247738Sbapt _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' 3769247738Sbapt ;; 3770247738Sbapt esac 3771247738Sbapt ;; 3772247738Sbapt esac 3773247738Sbapt ;; 3774247738Sbapt lynxos*) 3775247738Sbapt ;; 3776247738Sbapt m88k*) 3777247738Sbapt ;; 3778247738Sbapt mvs*) 3779247738Sbapt case $cc_basename in 3780247738Sbapt cxx*) 3781247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall' 3782247738Sbapt ;; 3783247738Sbapt *) 3784247738Sbapt ;; 3785247738Sbapt esac 3786247738Sbapt ;; 3787247738Sbapt netbsd* | netbsdelf*-gnu) 3788247738Sbapt ;; 3789247738Sbapt *qnx* | *nto*) 3790247738Sbapt # QNX uses GNU C++, but need to define -shared option too, otherwise 3791247738Sbapt # it will coredump. 3792247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' 3793247738Sbapt ;; 3794247738Sbapt osf3* | osf4* | osf5*) 3795247738Sbapt case $cc_basename in 3796247738Sbapt KCC*) 3797247738Sbapt _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' 3798247738Sbapt ;; 3799247738Sbapt RCC*) 3800247738Sbapt # Rational C++ 2.4.1 3801247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 3802247738Sbapt ;; 3803247738Sbapt cxx*) 3804247738Sbapt # Digital/Compaq C++ 3805247738Sbapt _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 3806247738Sbapt # Make sure the PIC flag is empty. It appears that all Alpha 3807247738Sbapt # Linux and Compaq Tru64 Unix objects are PIC. 3808247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)= 3809247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 3810247738Sbapt ;; 3811247738Sbapt *) 3812247738Sbapt ;; 3813247738Sbapt esac 3814247738Sbapt ;; 3815247738Sbapt psos*) 3816247738Sbapt ;; 3817247738Sbapt solaris*) 3818247738Sbapt case $cc_basename in 3819247738Sbapt CC*) 3820247738Sbapt # Sun C++ 4.2, 5.x and Centerline C++ 3821247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 3822247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 3823247738Sbapt _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' 3824247738Sbapt ;; 3825247738Sbapt gcx*) 3826247738Sbapt # Green Hills C++ Compiler 3827247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' 3828247738Sbapt ;; 3829247738Sbapt *) 3830247738Sbapt ;; 3831247738Sbapt esac 3832247738Sbapt ;; 3833247738Sbapt sunos4*) 3834247738Sbapt case $cc_basename in 3835247738Sbapt CC*) 3836247738Sbapt # Sun C++ 4.x 3837247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 3838247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 3839247738Sbapt ;; 3840247738Sbapt lcc*) 3841247738Sbapt # Lucid 3842247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 3843247738Sbapt ;; 3844247738Sbapt *) 3845247738Sbapt ;; 3846247738Sbapt esac 3847247738Sbapt ;; 3848247738Sbapt sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) 3849247738Sbapt case $cc_basename in 3850247738Sbapt CC*) 3851247738Sbapt _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 3852247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 3853247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 3854247738Sbapt ;; 3855247738Sbapt esac 3856247738Sbapt ;; 3857247738Sbapt tandem*) 3858247738Sbapt case $cc_basename in 3859247738Sbapt NCC*) 3860247738Sbapt # NonStop-UX NCC 3.20 3861247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 3862247738Sbapt ;; 3863247738Sbapt *) 3864247738Sbapt ;; 3865247738Sbapt esac 3866247738Sbapt ;; 3867247738Sbapt vxworks*) 3868247738Sbapt ;; 3869247738Sbapt *) 3870247738Sbapt _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 3871247738Sbapt ;; 3872247738Sbapt esac 3873247738Sbapt fi 3874247738Sbapt], 3875247738Sbapt[ 3876247738Sbapt if test "$GCC" = yes; then 3877247738Sbapt _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 3878247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 3879247738Sbapt 3880247738Sbapt case $host_os in 3881247738Sbapt aix*) 3882247738Sbapt # All AIX code is PIC. 3883247738Sbapt if test "$host_cpu" = ia64; then 3884247738Sbapt # AIX 5 now supports IA64 processor 3885247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 3886247738Sbapt fi 3887247738Sbapt ;; 3888247738Sbapt 3889247738Sbapt amigaos*) 3890247738Sbapt case $host_cpu in 3891247738Sbapt powerpc) 3892247738Sbapt # see comment about AmigaOS4 .so support 3893247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 3894247738Sbapt ;; 3895247738Sbapt m68k) 3896247738Sbapt # FIXME: we need at least 68020 code to build shared libraries, but 3897247738Sbapt # adding the `-m68020' flag to GCC prevents building anything better, 3898247738Sbapt # like `-m68040'. 3899247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' 3900247738Sbapt ;; 3901247738Sbapt esac 3902247738Sbapt ;; 3903247738Sbapt 3904247738Sbapt beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) 3905247738Sbapt # PIC is the default for these OSes. 3906247738Sbapt ;; 3907247738Sbapt 3908247738Sbapt mingw* | cygwin* | pw32* | os2* | cegcc*) 3909247738Sbapt # This hack is so that the source file can tell whether it is being 3910247738Sbapt # built for inclusion in a dll (and should export symbols for example). 3911247738Sbapt # Although the cygwin gcc ignores -fPIC, still need this for old-style 3912247738Sbapt # (--disable-auto-import) libraries 3913247738Sbapt m4_if([$1], [GCJ], [], 3914247738Sbapt [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) 3915247738Sbapt ;; 3916247738Sbapt 3917247738Sbapt darwin* | rhapsody*) 3918247738Sbapt # PIC is the default on this platform 3919247738Sbapt # Common symbols not allowed in MH_DYLIB files 3920247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' 3921247738Sbapt ;; 3922247738Sbapt 3923247738Sbapt hpux*) 3924247738Sbapt # PIC is the default for 64-bit PA HP-UX, but not for 32-bit 3925247738Sbapt # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag 3926247738Sbapt # sets the default TLS model and affects inlining. 3927247738Sbapt case $host_cpu in 3928247738Sbapt hppa*64*) 3929247738Sbapt # +Z the default 3930247738Sbapt ;; 3931247738Sbapt *) 3932247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 3933247738Sbapt ;; 3934247738Sbapt esac 3935247738Sbapt ;; 3936247738Sbapt 3937247738Sbapt interix[[3-9]]*) 3938247738Sbapt # Interix 3.x gcc -fpic/-fPIC options generate broken code. 3939247738Sbapt # Instead, we relocate shared libraries at runtime. 3940247738Sbapt ;; 3941247738Sbapt 3942247738Sbapt msdosdjgpp*) 3943247738Sbapt # Just because we use GCC doesn't mean we suddenly get shared libraries 3944247738Sbapt # on systems that don't support them. 3945247738Sbapt _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 3946247738Sbapt enable_shared=no 3947247738Sbapt ;; 3948247738Sbapt 3949247738Sbapt *nto* | *qnx*) 3950247738Sbapt # QNX uses GNU C++, but need to define -shared option too, otherwise 3951247738Sbapt # it will coredump. 3952247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' 3953247738Sbapt ;; 3954247738Sbapt 3955247738Sbapt sysv4*MP*) 3956247738Sbapt if test -d /usr/nec; then 3957247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic 3958247738Sbapt fi 3959247738Sbapt ;; 3960247738Sbapt 3961247738Sbapt *) 3962247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 3963247738Sbapt ;; 3964247738Sbapt esac 3965247738Sbapt else 3966247738Sbapt # PORTME Check for flag to pass linker flags through the system compiler. 3967247738Sbapt case $host_os in 3968247738Sbapt aix*) 3969247738Sbapt _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 3970247738Sbapt if test "$host_cpu" = ia64; then 3971247738Sbapt # AIX 5 now supports IA64 processor 3972247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 3973247738Sbapt else 3974247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' 3975247738Sbapt fi 3976247738Sbapt ;; 3977247738Sbapt 3978247738Sbapt mingw* | cygwin* | pw32* | os2* | cegcc*) 3979247738Sbapt # This hack is so that the source file can tell whether it is being 3980247738Sbapt # built for inclusion in a dll (and should export symbols for example). 3981247738Sbapt m4_if([$1], [GCJ], [], 3982247738Sbapt [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) 3983247738Sbapt ;; 3984247738Sbapt 3985247738Sbapt hpux9* | hpux10* | hpux11*) 3986247738Sbapt _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 3987247738Sbapt # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but 3988247738Sbapt # not for PA HP-UX. 3989247738Sbapt case $host_cpu in 3990247738Sbapt hppa*64*|ia64*) 3991247738Sbapt # +Z the default 3992247738Sbapt ;; 3993247738Sbapt *) 3994247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' 3995247738Sbapt ;; 3996247738Sbapt esac 3997247738Sbapt # Is there a better lt_prog_compiler_static that works with the bundled CC? 3998247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' 3999247738Sbapt ;; 4000247738Sbapt 4001247738Sbapt irix5* | irix6* | nonstopux*) 4002247738Sbapt _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4003247738Sbapt # PIC (with -KPIC) is the default. 4004247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 4005247738Sbapt ;; 4006247738Sbapt 4007247738Sbapt linux* | k*bsd*-gnu | kopensolaris*-gnu) 4008247738Sbapt case $cc_basename in 4009247738Sbapt # old Intel for x86_64 which still supported -KPIC. 4010247738Sbapt ecc*) 4011247738Sbapt _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4012247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4013247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 4014247738Sbapt ;; 4015247738Sbapt # icc used to be incompatible with GCC. 4016247738Sbapt # ICC 10 doesn't accept -KPIC any more. 4017247738Sbapt icc* | ifort*) 4018247738Sbapt _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4019247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 4020247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 4021247738Sbapt ;; 4022247738Sbapt # Lahey Fortran 8.1. 4023247738Sbapt lf95*) 4024247738Sbapt _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4025247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='--shared' 4026247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='--static' 4027247738Sbapt ;; 4028247738Sbapt pgcc* | pgf77* | pgf90* | pgf95*) 4029247738Sbapt # Portland Group compilers (*not* the Pentium gcc compiler, 4030247738Sbapt # which looks to be a dead project) 4031247738Sbapt _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4032247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' 4033247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4034247738Sbapt ;; 4035247738Sbapt ccc*) 4036247738Sbapt _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4037247738Sbapt # All Alpha code is PIC. 4038247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 4039247738Sbapt ;; 4040247738Sbapt xl*) 4041247738Sbapt # IBM XL C 8.0/Fortran 10.1 on PPC 4042247738Sbapt _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4043247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' 4044247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' 4045247738Sbapt ;; 4046247738Sbapt *) 4047247738Sbapt case `$CC -V 2>&1 | sed 5q` in 4048247738Sbapt *Sun\ C*) 4049247738Sbapt # Sun C 5.9 4050247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4051247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4052247738Sbapt _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4053247738Sbapt ;; 4054247738Sbapt *Sun\ F*) 4055247738Sbapt # Sun Fortran 8.3 passes all unrecognized flags to the linker 4056247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4057247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4058247738Sbapt _LT_TAGVAR(lt_prog_compiler_wl, $1)='' 4059247738Sbapt ;; 4060247738Sbapt esac 4061247738Sbapt ;; 4062247738Sbapt esac 4063247738Sbapt ;; 4064247738Sbapt 4065247738Sbapt newsos6) 4066247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4067247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4068247738Sbapt ;; 4069247738Sbapt 4070247738Sbapt *nto* | *qnx*) 4071247738Sbapt # QNX uses GNU C++, but need to define -shared option too, otherwise 4072247738Sbapt # it will coredump. 4073247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' 4074247738Sbapt ;; 4075247738Sbapt 4076247738Sbapt osf3* | osf4* | osf5*) 4077247738Sbapt _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4078247738Sbapt # All OSF/1 code is PIC. 4079247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 4080247738Sbapt ;; 4081247738Sbapt 4082247738Sbapt rdos*) 4083247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 4084247738Sbapt ;; 4085247738Sbapt 4086247738Sbapt solaris*) 4087247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4088247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4089247738Sbapt case $cc_basename in 4090247738Sbapt f77* | f90* | f95*) 4091247738Sbapt _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';; 4092247738Sbapt *) 4093247738Sbapt _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';; 4094247738Sbapt esac 4095247738Sbapt ;; 4096247738Sbapt 4097247738Sbapt sunos4*) 4098247738Sbapt _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' 4099247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' 4100247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4101247738Sbapt ;; 4102247738Sbapt 4103247738Sbapt sysv4 | sysv4.2uw2* | sysv4.3*) 4104247738Sbapt _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4105247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4106247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4107247738Sbapt ;; 4108247738Sbapt 4109247738Sbapt sysv4*MP*) 4110247738Sbapt if test -d /usr/nec ;then 4111247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic' 4112247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4113247738Sbapt fi 4114247738Sbapt ;; 4115247738Sbapt 4116247738Sbapt sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) 4117247738Sbapt _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4118247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 4119247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4120247738Sbapt ;; 4121247738Sbapt 4122247738Sbapt unicos*) 4123247738Sbapt _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4124247738Sbapt _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 4125247738Sbapt ;; 4126247738Sbapt 4127247738Sbapt uts4*) 4128247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 4129247738Sbapt _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 4130247738Sbapt ;; 4131247738Sbapt 4132247738Sbapt *) 4133247738Sbapt _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 4134247738Sbapt ;; 4135247738Sbapt esac 4136247738Sbapt fi 4137247738Sbapt]) 4138247738Sbaptcase $host_os in 4139247738Sbapt # For platforms which do not support PIC, -DPIC is meaningless: 4140247738Sbapt *djgpp*) 4141247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)= 4142247738Sbapt ;; 4143247738Sbapt *) 4144247738Sbapt _LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])" 4145247738Sbapt ;; 4146247738Sbaptesac 4147247738SbaptAC_MSG_RESULT([$_LT_TAGVAR(lt_prog_compiler_pic, $1)]) 4148247738Sbapt_LT_TAGDECL([wl], [lt_prog_compiler_wl], [1], 4149247738Sbapt [How to pass a linker flag through the compiler]) 4150247738Sbapt 4151247738Sbapt# 4152247738Sbapt# Check to make sure the PIC flag actually works. 4153247738Sbapt# 4154247738Sbaptif test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then 4155247738Sbapt _LT_COMPILER_OPTION([if $compiler PIC flag $_LT_TAGVAR(lt_prog_compiler_pic, $1) works], 4156247738Sbapt [_LT_TAGVAR(lt_cv_prog_compiler_pic_works, $1)], 4157247738Sbapt [$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])], [], 4158247738Sbapt [case $_LT_TAGVAR(lt_prog_compiler_pic, $1) in 4159247738Sbapt "" | " "*) ;; 4160247738Sbapt *) _LT_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_TAGVAR(lt_prog_compiler_pic, $1)" ;; 4161247738Sbapt esac], 4162247738Sbapt [_LT_TAGVAR(lt_prog_compiler_pic, $1)= 4163247738Sbapt _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no]) 4164247738Sbaptfi 4165247738Sbapt_LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1], 4166247738Sbapt [Additional compiler flags for building library objects]) 4167247738Sbapt 4168247738Sbapt# 4169247738Sbapt# Check to make sure the static flag actually works. 4170247738Sbapt# 4171247738Sbaptwl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_TAGVAR(lt_prog_compiler_static, $1)\" 4172247738Sbapt_LT_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works], 4173247738Sbapt _LT_TAGVAR(lt_cv_prog_compiler_static_works, $1), 4174247738Sbapt $lt_tmp_static_flag, 4175247738Sbapt [], 4176247738Sbapt [_LT_TAGVAR(lt_prog_compiler_static, $1)=]) 4177247738Sbapt_LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1], 4178247738Sbapt [Compiler flag to prevent dynamic linking]) 4179247738Sbapt])# _LT_COMPILER_PIC 4180247738Sbapt 4181247738Sbapt 4182247738Sbapt# _LT_LINKER_SHLIBS([TAGNAME]) 4183247738Sbapt# ---------------------------- 4184247738Sbapt# See if the linker supports building shared libraries. 4185247738Sbaptm4_defun([_LT_LINKER_SHLIBS], 4186247738Sbapt[AC_REQUIRE([LT_PATH_LD])dnl 4187247738SbaptAC_REQUIRE([LT_PATH_NM])dnl 4188247738Sbaptm4_require([_LT_FILEUTILS_DEFAULTS])dnl 4189247738Sbaptm4_require([_LT_DECL_EGREP])dnl 4190247738Sbaptm4_require([_LT_DECL_SED])dnl 4191247738Sbaptm4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl 4192247738Sbaptm4_require([_LT_TAG_COMPILER])dnl 4193247738SbaptAC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) 4194247738Sbaptm4_if([$1], [CXX], [ 4195247738Sbapt _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' 4196247738Sbapt case $host_os in 4197247738Sbapt aix[[4-9]]*) 4198247738Sbapt # If we're using GNU nm, then we don't want the "-C" option. 4199247738Sbapt # -C means demangle to AIX nm, but means don't demangle with GNU nm 4200247738Sbapt if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then 4201247738Sbapt _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' 4202247738Sbapt else 4203247738Sbapt _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' 4204247738Sbapt fi 4205247738Sbapt ;; 4206247738Sbapt pw32*) 4207247738Sbapt _LT_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds" 4208247738Sbapt ;; 4209247738Sbapt cygwin* | mingw* | cegcc*) 4210247738Sbapt _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;/^.*[[ ]]__nm__/s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols' 4211247738Sbapt ;; 4212247738Sbapt linux* | k*bsd*-gnu) 4213247738Sbapt _LT_TAGVAR(link_all_deplibs, $1)=no 4214247738Sbapt ;; 4215247738Sbapt *) 4216247738Sbapt _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' 4217247738Sbapt ;; 4218247738Sbapt esac 4219247738Sbapt _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] 4220247738Sbapt], [ 4221247738Sbapt runpath_var= 4222247738Sbapt _LT_TAGVAR(allow_undefined_flag, $1)= 4223247738Sbapt _LT_TAGVAR(always_export_symbols, $1)=no 4224247738Sbapt _LT_TAGVAR(archive_cmds, $1)= 4225247738Sbapt _LT_TAGVAR(archive_expsym_cmds, $1)= 4226247738Sbapt _LT_TAGVAR(compiler_needs_object, $1)=no 4227247738Sbapt _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no 4228247738Sbapt _LT_TAGVAR(export_dynamic_flag_spec, $1)= 4229247738Sbapt _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' 4230247738Sbapt _LT_TAGVAR(hardcode_automatic, $1)=no 4231247738Sbapt _LT_TAGVAR(hardcode_direct, $1)=no 4232247738Sbapt _LT_TAGVAR(hardcode_direct_absolute, $1)=no 4233247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 4234247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= 4235247738Sbapt _LT_TAGVAR(hardcode_libdir_separator, $1)= 4236247738Sbapt _LT_TAGVAR(hardcode_minus_L, $1)=no 4237247738Sbapt _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported 4238247738Sbapt _LT_TAGVAR(inherit_rpath, $1)=no 4239247738Sbapt _LT_TAGVAR(link_all_deplibs, $1)=unknown 4240247738Sbapt _LT_TAGVAR(module_cmds, $1)= 4241247738Sbapt _LT_TAGVAR(module_expsym_cmds, $1)= 4242247738Sbapt _LT_TAGVAR(old_archive_from_new_cmds, $1)= 4243247738Sbapt _LT_TAGVAR(old_archive_from_expsyms_cmds, $1)= 4244247738Sbapt _LT_TAGVAR(thread_safe_flag_spec, $1)= 4245247738Sbapt _LT_TAGVAR(whole_archive_flag_spec, $1)= 4246247738Sbapt # include_expsyms should be a list of space-separated symbols to be *always* 4247247738Sbapt # included in the symbol list 4248247738Sbapt _LT_TAGVAR(include_expsyms, $1)= 4249247738Sbapt # exclude_expsyms can be an extended regexp of symbols to exclude 4250247738Sbapt # it will be wrapped by ` (' and `)$', so one must not match beginning or 4251247738Sbapt # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', 4252247738Sbapt # as well as any symbol that contains `d'. 4253247738Sbapt _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] 4254247738Sbapt # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out 4255247738Sbapt # platforms (ab)use it in PIC code, but their linkers get confused if 4256247738Sbapt # the symbol is explicitly referenced. Since portable code cannot 4257247738Sbapt # rely on this symbol name, it's probably fine to never include it in 4258247738Sbapt # preloaded symbol tables. 4259247738Sbapt # Exclude shared library initialization/finalization symbols. 4260247738Sbaptdnl Note also adjust exclude_expsyms for C++ above. 4261247738Sbapt extract_expsyms_cmds= 4262247738Sbapt 4263247738Sbapt case $host_os in 4264247738Sbapt cygwin* | mingw* | pw32* | cegcc*) 4265247738Sbapt # FIXME: the MSVC++ port hasn't been tested in a loooong time 4266247738Sbapt # When not using gcc, we currently assume that we are using 4267247738Sbapt # Microsoft Visual C++. 4268247738Sbapt if test "$GCC" != yes; then 4269247738Sbapt with_gnu_ld=no 4270247738Sbapt fi 4271247738Sbapt ;; 4272247738Sbapt interix*) 4273247738Sbapt # we just hope/assume this is gcc and not c89 (= MSVC++) 4274247738Sbapt with_gnu_ld=yes 4275247738Sbapt ;; 4276247738Sbapt openbsd*) 4277247738Sbapt with_gnu_ld=no 4278247738Sbapt ;; 4279247738Sbapt linux* | k*bsd*-gnu) 4280247738Sbapt _LT_TAGVAR(link_all_deplibs, $1)=no 4281247738Sbapt ;; 4282247738Sbapt esac 4283247738Sbapt 4284247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=yes 4285247738Sbapt if test "$with_gnu_ld" = yes; then 4286247738Sbapt # If archive_cmds runs LD, not CC, wlarc should be empty 4287247738Sbapt wlarc='${wl}' 4288247738Sbapt 4289247738Sbapt # Set some defaults for GNU ld with shared library support. These 4290247738Sbapt # are reset later if shared libraries are not supported. Putting them 4291247738Sbapt # here allows them to be overridden if necessary. 4292247738Sbapt runpath_var=LD_RUN_PATH 4293247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 4294247738Sbapt _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 4295247738Sbapt # ancient GNU ld didn't support --whole-archive et. al. 4296247738Sbapt if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then 4297247738Sbapt _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' 4298247738Sbapt else 4299247738Sbapt _LT_TAGVAR(whole_archive_flag_spec, $1)= 4300247738Sbapt fi 4301247738Sbapt supports_anon_versioning=no 4302247738Sbapt case `$LD -v 2>&1` in 4303247738Sbapt *GNU\ gold*) supports_anon_versioning=yes ;; 4304247738Sbapt *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11 4305247738Sbapt *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... 4306247738Sbapt *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... 4307247738Sbapt *\ 2.11.*) ;; # other 2.11 versions 4308247738Sbapt *) supports_anon_versioning=yes ;; 4309247738Sbapt esac 4310247738Sbapt 4311247738Sbapt # See if GNU ld supports shared libraries. 4312247738Sbapt case $host_os in 4313247738Sbapt aix[[3-9]]*) 4314247738Sbapt # On AIX/PPC, the GNU linker is very broken 4315247738Sbapt if test "$host_cpu" != ia64; then 4316247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 4317247738Sbapt cat <<_LT_EOF 1>&2 4318247738Sbapt 4319247738Sbapt*** Warning: the GNU linker, at least up to release 2.9.1, is reported 4320247738Sbapt*** to be unable to reliably create shared libraries on AIX. 4321247738Sbapt*** Therefore, libtool is disabling shared libraries support. If you 4322247738Sbapt*** really care for shared libraries, you may want to modify your PATH 4323247738Sbapt*** so that a non-GNU linker is found, and then restart. 4324247738Sbapt 4325247738Sbapt_LT_EOF 4326247738Sbapt fi 4327247738Sbapt ;; 4328247738Sbapt 4329247738Sbapt amigaos*) 4330247738Sbapt case $host_cpu in 4331247738Sbapt powerpc) 4332247738Sbapt # see comment about AmigaOS4 .so support 4333247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 4334247738Sbapt _LT_TAGVAR(archive_expsym_cmds, $1)='' 4335247738Sbapt ;; 4336247738Sbapt m68k) 4337247738Sbapt _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)' 4338247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 4339247738Sbapt _LT_TAGVAR(hardcode_minus_L, $1)=yes 4340247738Sbapt ;; 4341247738Sbapt esac 4342247738Sbapt ;; 4343247738Sbapt 4344247738Sbapt beos*) 4345247738Sbapt if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 4346247738Sbapt _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 4347247738Sbapt # Joseph Beckenbach <jrb3@best.com> says some releases of gcc 4348247738Sbapt # support --undefined. This deserves some investigation. FIXME 4349247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 4350247738Sbapt else 4351247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 4352247738Sbapt fi 4353247738Sbapt ;; 4354247738Sbapt 4355247738Sbapt cygwin* | mingw* | pw32* | cegcc*) 4356247738Sbapt # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, 4357247738Sbapt # as there is no search path for DLLs. 4358247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 4359247738Sbapt _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 4360247738Sbapt _LT_TAGVAR(always_export_symbols, $1)=no 4361247738Sbapt _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 4362247738Sbapt _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' 4363247738Sbapt 4364247738Sbapt if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then 4365247738Sbapt _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' 4366247738Sbapt # If the export-symbols file already is a .def file (1st line 4367247738Sbapt # is EXPORTS), use it as is; otherwise, prepend... 4368247738Sbapt _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then 4369247738Sbapt cp $export_symbols $output_objdir/$soname.def; 4370247738Sbapt else 4371247738Sbapt echo EXPORTS > $output_objdir/$soname.def; 4372247738Sbapt cat $export_symbols >> $output_objdir/$soname.def; 4373247738Sbapt fi~ 4374247738Sbapt $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' 4375247738Sbapt else 4376247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 4377247738Sbapt fi 4378247738Sbapt ;; 4379247738Sbapt 4380247738Sbapt interix[[3-9]]*) 4381247738Sbapt _LT_TAGVAR(hardcode_direct, $1)=no 4382247738Sbapt _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 4383247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 4384247738Sbapt _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 4385247738Sbapt # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. 4386247738Sbapt # Instead, shared libraries are loaded at an image base (0x10000000 by 4387247738Sbapt # default) and relocated if they conflict, which is a slow very memory 4388247738Sbapt # consuming and fragmenting process. To avoid this, we pick a random, 4389247738Sbapt # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link 4390247738Sbapt # time. Moving up from 0x10000000 also allows more sbrk(2) space. 4391247738Sbapt _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' 4392247738Sbapt _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' 4393247738Sbapt ;; 4394247738Sbapt 4395247738Sbapt gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) 4396247738Sbapt tmp_diet=no 4397247738Sbapt if test "$host_os" = linux-dietlibc; then 4398247738Sbapt case $cc_basename in 4399247738Sbapt diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn) 4400247738Sbapt esac 4401247738Sbapt fi 4402247738Sbapt if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ 4403247738Sbapt && test "$tmp_diet" = no 4404247738Sbapt then 4405247738Sbapt tmp_addflag= 4406247738Sbapt tmp_sharedflag='-shared' 4407247738Sbapt case $cc_basename,$host_cpu in 4408247738Sbapt pgcc*) # Portland Group C compiler 4409247738Sbapt _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive' 4410247738Sbapt tmp_addflag=' $pic_flag' 4411247738Sbapt ;; 4412247738Sbapt pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers 4413247738Sbapt _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive' 4414247738Sbapt tmp_addflag=' $pic_flag -Mnomain' ;; 4415247738Sbapt ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 4416247738Sbapt tmp_addflag=' -i_dynamic' ;; 4417247738Sbapt efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 4418247738Sbapt tmp_addflag=' -i_dynamic -nofor_main' ;; 4419247738Sbapt ifc* | ifort*) # Intel Fortran compiler 4420247738Sbapt tmp_addflag=' -nofor_main' ;; 4421247738Sbapt lf95*) # Lahey Fortran 8.1 4422247738Sbapt _LT_TAGVAR(whole_archive_flag_spec, $1)= 4423247738Sbapt tmp_sharedflag='--shared' ;; 4424247738Sbapt xl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below) 4425247738Sbapt tmp_sharedflag='-qmkshrobj' 4426247738Sbapt tmp_addflag= ;; 4427247738Sbapt esac 4428247738Sbapt case `$CC -V 2>&1 | sed 5q` in 4429247738Sbapt *Sun\ C*) # Sun C 5.9 4430247738Sbapt _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; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive' 4431247738Sbapt _LT_TAGVAR(compiler_needs_object, $1)=yes 4432247738Sbapt tmp_sharedflag='-G' ;; 4433247738Sbapt *Sun\ F*) # Sun Fortran 8.3 4434247738Sbapt tmp_sharedflag='-G' ;; 4435247738Sbapt esac 4436247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 4437247738Sbapt 4438247738Sbapt if test "x$supports_anon_versioning" = xyes; then 4439247738Sbapt _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ 4440247738Sbapt cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ 4441247738Sbapt echo "local: *; };" >> $output_objdir/$libname.ver~ 4442247738Sbapt $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' 4443247738Sbapt fi 4444247738Sbapt 4445247738Sbapt case $cc_basename in 4446247738Sbapt xlf*) 4447247738Sbapt # IBM XL Fortran 10.1 on PPC cannot create shared libs itself 4448247738Sbapt _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive' 4449247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 4450247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='-rpath $libdir' 4451247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $compiler_flags -soname $soname -o $lib' 4452247738Sbapt if test "x$supports_anon_versioning" = xyes; then 4453247738Sbapt _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ 4454247738Sbapt cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ 4455247738Sbapt echo "local: *; };" >> $output_objdir/$libname.ver~ 4456247738Sbapt $LD -shared $libobjs $deplibs $compiler_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' 4457247738Sbapt fi 4458247738Sbapt ;; 4459247738Sbapt esac 4460247738Sbapt else 4461247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 4462247738Sbapt fi 4463247738Sbapt ;; 4464247738Sbapt 4465247738Sbapt netbsd* | netbsdelf*-gnu) 4466247738Sbapt if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then 4467247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' 4468247738Sbapt wlarc= 4469247738Sbapt else 4470247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 4471247738Sbapt _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' 4472247738Sbapt fi 4473247738Sbapt ;; 4474247738Sbapt 4475247738Sbapt solaris*) 4476247738Sbapt if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then 4477247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 4478247738Sbapt cat <<_LT_EOF 1>&2 4479247738Sbapt 4480247738Sbapt*** Warning: The releases 2.8.* of the GNU linker cannot reliably 4481247738Sbapt*** create shared libraries on Solaris systems. Therefore, libtool 4482247738Sbapt*** is disabling shared libraries support. We urge you to upgrade GNU 4483247738Sbapt*** binutils to release 2.9.1 or newer. Another option is to modify 4484247738Sbapt*** your PATH or compiler configuration so that the native linker is 4485247738Sbapt*** used, and then restart. 4486247738Sbapt 4487247738Sbapt_LT_EOF 4488247738Sbapt elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 4489247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 4490247738Sbapt _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' 4491247738Sbapt else 4492247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 4493247738Sbapt fi 4494247738Sbapt ;; 4495247738Sbapt 4496247738Sbapt sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) 4497247738Sbapt case `$LD -v 2>&1` in 4498247738Sbapt *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*) 4499247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 4500247738Sbapt cat <<_LT_EOF 1>&2 4501247738Sbapt 4502247738Sbapt*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not 4503247738Sbapt*** reliably create shared libraries on SCO systems. Therefore, libtool 4504247738Sbapt*** is disabling shared libraries support. We urge you to upgrade GNU 4505247738Sbapt*** binutils to release 2.16.91.0.3 or newer. Another option is to modify 4506247738Sbapt*** your PATH or compiler configuration so that the native linker is 4507247738Sbapt*** used, and then restart. 4508247738Sbapt 4509247738Sbapt_LT_EOF 4510247738Sbapt ;; 4511247738Sbapt *) 4512247738Sbapt # For security reasons, it is highly recommended that you always 4513247738Sbapt # use absolute paths for naming shared libraries, and exclude the 4514247738Sbapt # DT_RUNPATH tag from executables and libraries. But doing so 4515247738Sbapt # requires that you compile everything twice, which is a pain. 4516247738Sbapt if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 4517247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 4518247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 4519247738Sbapt _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' 4520247738Sbapt else 4521247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 4522247738Sbapt fi 4523247738Sbapt ;; 4524247738Sbapt esac 4525247738Sbapt ;; 4526247738Sbapt 4527247738Sbapt sunos4*) 4528247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' 4529247738Sbapt wlarc= 4530247738Sbapt _LT_TAGVAR(hardcode_direct, $1)=yes 4531247738Sbapt _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 4532247738Sbapt ;; 4533247738Sbapt 4534247738Sbapt *) 4535247738Sbapt if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 4536247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 4537247738Sbapt _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' 4538247738Sbapt else 4539247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 4540247738Sbapt fi 4541247738Sbapt ;; 4542247738Sbapt esac 4543247738Sbapt 4544247738Sbapt if test "$_LT_TAGVAR(ld_shlibs, $1)" = no; then 4545247738Sbapt runpath_var= 4546247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 4547247738Sbapt _LT_TAGVAR(export_dynamic_flag_spec, $1)= 4548247738Sbapt _LT_TAGVAR(whole_archive_flag_spec, $1)= 4549247738Sbapt fi 4550247738Sbapt else 4551247738Sbapt # PORTME fill in a description of your system's linker (not GNU ld) 4552247738Sbapt case $host_os in 4553247738Sbapt aix3*) 4554247738Sbapt _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 4555247738Sbapt _LT_TAGVAR(always_export_symbols, $1)=yes 4556247738Sbapt _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' 4557247738Sbapt # Note: this linker hardcodes the directories in LIBPATH if there 4558247738Sbapt # are no directories specified by -L. 4559247738Sbapt _LT_TAGVAR(hardcode_minus_L, $1)=yes 4560247738Sbapt if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then 4561247738Sbapt # Neither direct hardcoding nor static linking is supported with a 4562247738Sbapt # broken collect2. 4563247738Sbapt _LT_TAGVAR(hardcode_direct, $1)=unsupported 4564247738Sbapt fi 4565247738Sbapt ;; 4566247738Sbapt 4567247738Sbapt aix[[4-9]]*) 4568247738Sbapt if test "$host_cpu" = ia64; then 4569247738Sbapt # On IA64, the linker does run time linking by default, so we don't 4570247738Sbapt # have to do anything special. 4571247738Sbapt aix_use_runtimelinking=no 4572247738Sbapt exp_sym_flag='-Bexport' 4573247738Sbapt no_entry_flag="" 4574247738Sbapt else 4575247738Sbapt # If we're using GNU nm, then we don't want the "-C" option. 4576247738Sbapt # -C means demangle to AIX nm, but means don't demangle with GNU nm 4577247738Sbapt if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then 4578247738Sbapt _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' 4579247738Sbapt else 4580247738Sbapt _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' 4581247738Sbapt fi 4582247738Sbapt aix_use_runtimelinking=no 4583247738Sbapt 4584247738Sbapt # Test if we are trying to use run time linking or normal 4585247738Sbapt # AIX style linking. If -brtl is somewhere in LDFLAGS, we 4586247738Sbapt # need to do runtime linking. 4587247738Sbapt case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) 4588247738Sbapt for ld_flag in $LDFLAGS; do 4589247738Sbapt if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then 4590247738Sbapt aix_use_runtimelinking=yes 4591247738Sbapt break 4592247738Sbapt fi 4593247738Sbapt done 4594247738Sbapt ;; 4595247738Sbapt esac 4596247738Sbapt 4597247738Sbapt exp_sym_flag='-bexport' 4598247738Sbapt no_entry_flag='-bnoentry' 4599247738Sbapt fi 4600247738Sbapt 4601247738Sbapt # When large executables or shared objects are built, AIX ld can 4602247738Sbapt # have problems creating the table of contents. If linking a library 4603247738Sbapt # or program results in "error TOC overflow" add -mminimal-toc to 4604247738Sbapt # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not 4605247738Sbapt # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. 4606247738Sbapt 4607247738Sbapt _LT_TAGVAR(archive_cmds, $1)='' 4608247738Sbapt _LT_TAGVAR(hardcode_direct, $1)=yes 4609247738Sbapt _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 4610247738Sbapt _LT_TAGVAR(hardcode_libdir_separator, $1)=':' 4611247738Sbapt _LT_TAGVAR(link_all_deplibs, $1)=yes 4612247738Sbapt _LT_TAGVAR(file_list_spec, $1)='${wl}-f,' 4613247738Sbapt 4614247738Sbapt if test "$GCC" = yes; then 4615247738Sbapt case $host_os in aix4.[[012]]|aix4.[[012]].*) 4616247738Sbapt # We only want to do this on AIX 4.2 and lower, the check 4617247738Sbapt # below for broken collect2 doesn't work under 4.3+ 4618247738Sbapt collect2name=`${CC} -print-prog-name=collect2` 4619247738Sbapt if test -f "$collect2name" && 4620247738Sbapt strings "$collect2name" | $GREP resolve_lib_name >/dev/null 4621247738Sbapt then 4622247738Sbapt # We have reworked collect2 4623247738Sbapt : 4624247738Sbapt else 4625247738Sbapt # We have old collect2 4626247738Sbapt _LT_TAGVAR(hardcode_direct, $1)=unsupported 4627247738Sbapt # It fails to find uninstalled libraries when the uninstalled 4628247738Sbapt # path is not listed in the libpath. Setting hardcode_minus_L 4629247738Sbapt # to unsupported forces relinking 4630247738Sbapt _LT_TAGVAR(hardcode_minus_L, $1)=yes 4631247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 4632247738Sbapt _LT_TAGVAR(hardcode_libdir_separator, $1)= 4633247738Sbapt fi 4634247738Sbapt ;; 4635247738Sbapt esac 4636247738Sbapt shared_flag='-shared' 4637247738Sbapt if test "$aix_use_runtimelinking" = yes; then 4638247738Sbapt shared_flag="$shared_flag "'${wl}-G' 4639247738Sbapt fi 4640247738Sbapt _LT_TAGVAR(link_all_deplibs, $1)=no 4641247738Sbapt else 4642247738Sbapt # not using gcc 4643247738Sbapt if test "$host_cpu" = ia64; then 4644247738Sbapt # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release 4645247738Sbapt # chokes on -Wl,-G. The following line is correct: 4646247738Sbapt shared_flag='-G' 4647247738Sbapt else 4648247738Sbapt if test "$aix_use_runtimelinking" = yes; then 4649247738Sbapt shared_flag='${wl}-G' 4650247738Sbapt else 4651247738Sbapt shared_flag='${wl}-bM:SRE' 4652247738Sbapt fi 4653247738Sbapt fi 4654247738Sbapt fi 4655247738Sbapt 4656247738Sbapt _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall' 4657247738Sbapt # It seems that -bexpall does not export symbols beginning with 4658247738Sbapt # underscore (_), so it is better to generate a list of symbols to export. 4659247738Sbapt _LT_TAGVAR(always_export_symbols, $1)=yes 4660247738Sbapt if test "$aix_use_runtimelinking" = yes; then 4661247738Sbapt # Warning - without using the other runtime loading flags (-brtl), 4662247738Sbapt # -berok will link without error, but may produce a broken library. 4663247738Sbapt _LT_TAGVAR(allow_undefined_flag, $1)='-berok' 4664247738Sbapt # Determine the default libpath from the value encoded in an 4665247738Sbapt # empty executable. 4666247738Sbapt _LT_SYS_MODULE_PATH_AIX 4667247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" 4668247738Sbapt _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 $ECHO "X${wl}${allow_undefined_flag}" | $Xsed; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" 4669247738Sbapt else 4670247738Sbapt if test "$host_cpu" = ia64; then 4671247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' 4672247738Sbapt _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" 4673247738Sbapt _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" 4674247738Sbapt else 4675247738Sbapt # Determine the default libpath from the value encoded in an 4676247738Sbapt # empty executable. 4677247738Sbapt _LT_SYS_MODULE_PATH_AIX 4678247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" 4679247738Sbapt # Warning - without using the other run time loading flags, 4680247738Sbapt # -berok will link without error, but may produce a broken library. 4681247738Sbapt _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' 4682247738Sbapt _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' 4683247738Sbapt # Exported symbols can be pulled into shared objects from archives 4684247738Sbapt _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' 4685247738Sbapt _LT_TAGVAR(archive_cmds_need_lc, $1)=yes 4686247738Sbapt # This is similar to how AIX traditionally builds its shared libraries. 4687247738Sbapt _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' 4688247738Sbapt fi 4689247738Sbapt fi 4690247738Sbapt ;; 4691247738Sbapt 4692247738Sbapt amigaos*) 4693247738Sbapt case $host_cpu in 4694247738Sbapt powerpc) 4695247738Sbapt # see comment about AmigaOS4 .so support 4696247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 4697247738Sbapt _LT_TAGVAR(archive_expsym_cmds, $1)='' 4698247738Sbapt ;; 4699247738Sbapt m68k) 4700247738Sbapt _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)' 4701247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 4702247738Sbapt _LT_TAGVAR(hardcode_minus_L, $1)=yes 4703247738Sbapt ;; 4704247738Sbapt esac 4705247738Sbapt ;; 4706247738Sbapt 4707247738Sbapt bsdi[[45]]*) 4708247738Sbapt _LT_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic 4709247738Sbapt ;; 4710247738Sbapt 4711247738Sbapt cygwin* | mingw* | pw32* | cegcc*) 4712247738Sbapt # When not using gcc, we currently assume that we are using 4713247738Sbapt # Microsoft Visual C++. 4714247738Sbapt # hardcode_libdir_flag_spec is actually meaningless, as there is 4715247738Sbapt # no search path for DLLs. 4716247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' 4717247738Sbapt _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 4718247738Sbapt # Tell ltmain to make .lib files, not .a files. 4719247738Sbapt libext=lib 4720247738Sbapt # Tell ltmain to make .dll files, not .so files. 4721247738Sbapt shrext_cmds=".dll" 4722247738Sbapt # FIXME: Setting linknames here is a bad hack. 4723247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `$ECHO "X$deplibs" | $Xsed -e '\''s/ -lc$//'\''` -link -dll~linknames=' 4724247738Sbapt # The linker will automatically build a .lib file if we build a DLL. 4725247738Sbapt _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' 4726247738Sbapt # FIXME: Should let the user specify the lib program. 4727247738Sbapt _LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs' 4728247738Sbapt _LT_TAGVAR(fix_srcfile_path, $1)='`cygpath -w "$srcfile"`' 4729247738Sbapt _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 4730247738Sbapt ;; 4731247738Sbapt 4732247738Sbapt darwin* | rhapsody*) 4733247738Sbapt _LT_DARWIN_LINKER_FEATURES($1) 4734247738Sbapt ;; 4735247738Sbapt 4736247738Sbapt dgux*) 4737247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 4738247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 4739247738Sbapt _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 4740247738Sbapt ;; 4741247738Sbapt 4742247738Sbapt freebsd1*) 4743247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 4744247738Sbapt ;; 4745247738Sbapt 4746247738Sbapt # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor 4747247738Sbapt # support. Future versions do this automatically, but an explicit c++rt0.o 4748247738Sbapt # does not break anything, and helps significantly (at the cost of a little 4749247738Sbapt # extra space). 4750247738Sbapt freebsd2.2*) 4751247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' 4752247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 4753247738Sbapt _LT_TAGVAR(hardcode_direct, $1)=yes 4754247738Sbapt _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 4755247738Sbapt ;; 4756247738Sbapt 4757247738Sbapt # Unfortunately, older versions of FreeBSD 2 do not have this feature. 4758247738Sbapt freebsd2*) 4759247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' 4760247738Sbapt _LT_TAGVAR(hardcode_direct, $1)=yes 4761247738Sbapt _LT_TAGVAR(hardcode_minus_L, $1)=yes 4762247738Sbapt _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 4763247738Sbapt ;; 4764247738Sbapt 4765247738Sbapt # FreeBSD 3 and greater uses gcc -shared to do shared libraries. 4766247738Sbapt freebsd* | dragonfly*) 4767247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' 4768247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 4769247738Sbapt _LT_TAGVAR(hardcode_direct, $1)=yes 4770247738Sbapt _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 4771247738Sbapt ;; 4772247738Sbapt 4773247738Sbapt hpux9*) 4774247738Sbapt if test "$GCC" = yes; then 4775247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' 4776247738Sbapt else 4777247738Sbapt _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' 4778247738Sbapt fi 4779247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 4780247738Sbapt _LT_TAGVAR(hardcode_libdir_separator, $1)=: 4781247738Sbapt _LT_TAGVAR(hardcode_direct, $1)=yes 4782247738Sbapt 4783247738Sbapt # hardcode_minus_L: Not really in the search PATH, 4784247738Sbapt # but as the default location of the library. 4785247738Sbapt _LT_TAGVAR(hardcode_minus_L, $1)=yes 4786247738Sbapt _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 4787247738Sbapt ;; 4788247738Sbapt 4789247738Sbapt hpux10*) 4790247738Sbapt if test "$GCC" = yes -a "$with_gnu_ld" = no; then 4791247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' 4792247738Sbapt else 4793247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' 4794247738Sbapt fi 4795247738Sbapt if test "$with_gnu_ld" = no; then 4796247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 4797247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir' 4798247738Sbapt _LT_TAGVAR(hardcode_libdir_separator, $1)=: 4799247738Sbapt _LT_TAGVAR(hardcode_direct, $1)=yes 4800247738Sbapt _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 4801247738Sbapt _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 4802247738Sbapt # hardcode_minus_L: Not really in the search PATH, 4803247738Sbapt # but as the default location of the library. 4804247738Sbapt _LT_TAGVAR(hardcode_minus_L, $1)=yes 4805247738Sbapt fi 4806247738Sbapt ;; 4807247738Sbapt 4808247738Sbapt hpux11*) 4809247738Sbapt if test "$GCC" = yes -a "$with_gnu_ld" = no; then 4810247738Sbapt case $host_cpu in 4811247738Sbapt hppa*64*) 4812247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' 4813247738Sbapt ;; 4814247738Sbapt ia64*) 4815247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' 4816247738Sbapt ;; 4817247738Sbapt *) 4818247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' 4819247738Sbapt ;; 4820247738Sbapt esac 4821247738Sbapt else 4822247738Sbapt case $host_cpu in 4823247738Sbapt hppa*64*) 4824247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' 4825247738Sbapt ;; 4826247738Sbapt ia64*) 4827247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' 4828247738Sbapt ;; 4829247738Sbapt *) 4830247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' 4831247738Sbapt ;; 4832247738Sbapt esac 4833247738Sbapt fi 4834247738Sbapt if test "$with_gnu_ld" = no; then 4835247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 4836247738Sbapt _LT_TAGVAR(hardcode_libdir_separator, $1)=: 4837247738Sbapt 4838247738Sbapt case $host_cpu in 4839247738Sbapt hppa*64*|ia64*) 4840247738Sbapt _LT_TAGVAR(hardcode_direct, $1)=no 4841247738Sbapt _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 4842247738Sbapt ;; 4843247738Sbapt *) 4844247738Sbapt _LT_TAGVAR(hardcode_direct, $1)=yes 4845247738Sbapt _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 4846247738Sbapt _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 4847247738Sbapt 4848247738Sbapt # hardcode_minus_L: Not really in the search PATH, 4849247738Sbapt # but as the default location of the library. 4850247738Sbapt _LT_TAGVAR(hardcode_minus_L, $1)=yes 4851247738Sbapt ;; 4852247738Sbapt esac 4853247738Sbapt fi 4854247738Sbapt ;; 4855247738Sbapt 4856247738Sbapt irix5* | irix6* | nonstopux*) 4857247738Sbapt if test "$GCC" = yes; then 4858247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' 4859247738Sbapt # Try to use the -exported_symbol ld option, if it does not 4860247738Sbapt # work, assume that -exports_file does not work either and 4861247738Sbapt # implicitly export all symbols. 4862247738Sbapt save_LDFLAGS="$LDFLAGS" 4863247738Sbapt LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null" 4864247738Sbapt AC_LINK_IFELSE(int foo(void) {}, 4865247738Sbapt _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib' 4866247738Sbapt ) 4867247738Sbapt LDFLAGS="$save_LDFLAGS" 4868247738Sbapt else 4869247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib' 4870247738Sbapt _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib' 4871247738Sbapt fi 4872247738Sbapt _LT_TAGVAR(archive_cmds_need_lc, $1)='no' 4873247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 4874247738Sbapt _LT_TAGVAR(hardcode_libdir_separator, $1)=: 4875247738Sbapt _LT_TAGVAR(inherit_rpath, $1)=yes 4876247738Sbapt _LT_TAGVAR(link_all_deplibs, $1)=yes 4877247738Sbapt ;; 4878247738Sbapt 4879247738Sbapt netbsd* | netbsdelf*-gnu) 4880247738Sbapt if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then 4881247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out 4882247738Sbapt else 4883247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF 4884247738Sbapt fi 4885247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 4886247738Sbapt _LT_TAGVAR(hardcode_direct, $1)=yes 4887247738Sbapt _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 4888247738Sbapt ;; 4889247738Sbapt 4890247738Sbapt newsos6) 4891247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 4892247738Sbapt _LT_TAGVAR(hardcode_direct, $1)=yes 4893247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 4894247738Sbapt _LT_TAGVAR(hardcode_libdir_separator, $1)=: 4895247738Sbapt _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 4896247738Sbapt ;; 4897247738Sbapt 4898247738Sbapt *nto* | *qnx*) 4899247738Sbapt ;; 4900247738Sbapt 4901247738Sbapt openbsd*) 4902247738Sbapt if test -f /usr/libexec/ld.so; then 4903247738Sbapt _LT_TAGVAR(hardcode_direct, $1)=yes 4904247738Sbapt _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 4905247738Sbapt _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 4906247738Sbapt if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then 4907247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' 4908247738Sbapt _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' 4909247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 4910247738Sbapt _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 4911247738Sbapt else 4912247738Sbapt case $host_os in 4913247738Sbapt openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*) 4914247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' 4915247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 4916247738Sbapt ;; 4917247738Sbapt *) 4918247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' 4919247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 4920247738Sbapt ;; 4921247738Sbapt esac 4922247738Sbapt fi 4923247738Sbapt else 4924247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 4925247738Sbapt fi 4926247738Sbapt ;; 4927247738Sbapt 4928247738Sbapt os2*) 4929247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 4930247738Sbapt _LT_TAGVAR(hardcode_minus_L, $1)=yes 4931247738Sbapt _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 4932247738Sbapt _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' 4933247738Sbapt _LT_TAGVAR(old_archive_from_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' 4934247738Sbapt ;; 4935247738Sbapt 4936247738Sbapt osf3*) 4937247738Sbapt if test "$GCC" = yes; then 4938247738Sbapt _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' 4939247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' 4940247738Sbapt else 4941247738Sbapt _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' 4942247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib' 4943247738Sbapt fi 4944247738Sbapt _LT_TAGVAR(archive_cmds_need_lc, $1)='no' 4945247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 4946247738Sbapt _LT_TAGVAR(hardcode_libdir_separator, $1)=: 4947247738Sbapt ;; 4948247738Sbapt 4949247738Sbapt osf4* | osf5*) # as osf3* with the addition of -msym flag 4950247738Sbapt if test "$GCC" = yes; then 4951247738Sbapt _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' 4952247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' 4953247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 4954247738Sbapt else 4955247738Sbapt _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' 4956247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib' 4957247738Sbapt _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~ 4958247738Sbapt $CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp' 4959247738Sbapt 4960247738Sbapt # Both c and cxx compiler support -rpath directly 4961247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' 4962247738Sbapt fi 4963247738Sbapt _LT_TAGVAR(archive_cmds_need_lc, $1)='no' 4964247738Sbapt _LT_TAGVAR(hardcode_libdir_separator, $1)=: 4965247738Sbapt ;; 4966247738Sbapt 4967247738Sbapt solaris*) 4968247738Sbapt _LT_TAGVAR(no_undefined_flag, $1)=' -z defs' 4969247738Sbapt if test "$GCC" = yes; then 4970247738Sbapt wlarc='${wl}' 4971247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' 4972247738Sbapt _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 4973247738Sbapt $CC -shared ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' 4974247738Sbapt else 4975247738Sbapt case `$CC -V 2>&1` in 4976247738Sbapt *"Compilers 5.0"*) 4977247738Sbapt wlarc='' 4978247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' 4979247738Sbapt _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 4980247738Sbapt $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' 4981247738Sbapt ;; 4982247738Sbapt *) 4983247738Sbapt wlarc='${wl}' 4984247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags' 4985247738Sbapt _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 4986247738Sbapt $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' 4987247738Sbapt ;; 4988247738Sbapt esac 4989247738Sbapt fi 4990247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 4991247738Sbapt _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 4992247738Sbapt case $host_os in 4993247738Sbapt solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; 4994247738Sbapt *) 4995247738Sbapt # The compiler driver will combine and reorder linker options, 4996247738Sbapt # but understands `-z linker_flag'. GCC discards it without `$wl', 4997247738Sbapt # but is careful enough not to reorder. 4998247738Sbapt # Supported since Solaris 2.6 (maybe 2.5.1?) 4999247738Sbapt if test "$GCC" = yes; then 5000247738Sbapt _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' 5001247738Sbapt else 5002247738Sbapt _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' 5003247738Sbapt fi 5004247738Sbapt ;; 5005247738Sbapt esac 5006247738Sbapt _LT_TAGVAR(link_all_deplibs, $1)=yes 5007247738Sbapt ;; 5008247738Sbapt 5009247738Sbapt sunos4*) 5010247738Sbapt if test "x$host_vendor" = xsequent; then 5011247738Sbapt # Use $CC to link under sequent, because it throws in some extra .o 5012247738Sbapt # files that make .init and .fini sections work. 5013247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' 5014247738Sbapt else 5015247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' 5016247738Sbapt fi 5017247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 5018247738Sbapt _LT_TAGVAR(hardcode_direct, $1)=yes 5019247738Sbapt _LT_TAGVAR(hardcode_minus_L, $1)=yes 5020247738Sbapt _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5021247738Sbapt ;; 5022247738Sbapt 5023247738Sbapt sysv4) 5024247738Sbapt case $host_vendor in 5025247738Sbapt sni) 5026247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 5027247738Sbapt _LT_TAGVAR(hardcode_direct, $1)=yes # is this really true??? 5028247738Sbapt ;; 5029247738Sbapt siemens) 5030247738Sbapt ## LD is ld it makes a PLAMLIB 5031247738Sbapt ## CC just makes a GrossModule. 5032247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags' 5033247738Sbapt _LT_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs' 5034247738Sbapt _LT_TAGVAR(hardcode_direct, $1)=no 5035247738Sbapt ;; 5036247738Sbapt motorola) 5037247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 5038247738Sbapt _LT_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie 5039247738Sbapt ;; 5040247738Sbapt esac 5041247738Sbapt runpath_var='LD_RUN_PATH' 5042247738Sbapt _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5043247738Sbapt ;; 5044247738Sbapt 5045247738Sbapt sysv4.3*) 5046247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 5047247738Sbapt _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5048247738Sbapt _LT_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport' 5049247738Sbapt ;; 5050247738Sbapt 5051247738Sbapt sysv4*MP*) 5052247738Sbapt if test -d /usr/nec; then 5053247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 5054247738Sbapt _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5055247738Sbapt runpath_var=LD_RUN_PATH 5056247738Sbapt hardcode_runpath_var=yes 5057247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=yes 5058247738Sbapt fi 5059247738Sbapt ;; 5060247738Sbapt 5061247738Sbapt sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) 5062247738Sbapt _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' 5063247738Sbapt _LT_TAGVAR(archive_cmds_need_lc, $1)=no 5064247738Sbapt _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5065247738Sbapt runpath_var='LD_RUN_PATH' 5066247738Sbapt 5067247738Sbapt if test "$GCC" = yes; then 5068247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 5069247738Sbapt _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 5070247738Sbapt else 5071247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 5072247738Sbapt _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 5073247738Sbapt fi 5074247738Sbapt ;; 5075247738Sbapt 5076247738Sbapt sysv5* | sco3.2v5* | sco5v6*) 5077247738Sbapt # Note: We can NOT use -z defs as we might desire, because we do not 5078247738Sbapt # link with -lc, and that would cause any symbols used from libc to 5079247738Sbapt # always be unresolved, which means just about no library would 5080247738Sbapt # ever link correctly. If we're not using GNU ld we use -z text 5081247738Sbapt # though, which does catch some bad symbols but isn't as heavy-handed 5082247738Sbapt # as -z defs. 5083247738Sbapt _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' 5084247738Sbapt _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs' 5085247738Sbapt _LT_TAGVAR(archive_cmds_need_lc, $1)=no 5086247738Sbapt _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5087247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir' 5088247738Sbapt _LT_TAGVAR(hardcode_libdir_separator, $1)=':' 5089247738Sbapt _LT_TAGVAR(link_all_deplibs, $1)=yes 5090247738Sbapt _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' 5091247738Sbapt runpath_var='LD_RUN_PATH' 5092247738Sbapt 5093247738Sbapt if test "$GCC" = yes; then 5094247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 5095247738Sbapt _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 5096247738Sbapt else 5097247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 5098247738Sbapt _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 5099247738Sbapt fi 5100247738Sbapt ;; 5101247738Sbapt 5102247738Sbapt uts4*) 5103247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 5104247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 5105247738Sbapt _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5106247738Sbapt ;; 5107247738Sbapt 5108247738Sbapt *) 5109247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 5110247738Sbapt ;; 5111247738Sbapt esac 5112247738Sbapt 5113247738Sbapt if test x$host_vendor = xsni; then 5114247738Sbapt case $host in 5115247738Sbapt sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) 5116247738Sbapt _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Blargedynsym' 5117247738Sbapt ;; 5118247738Sbapt esac 5119247738Sbapt fi 5120247738Sbapt fi 5121247738Sbapt]) 5122247738SbaptAC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) 5123247738Sbapttest "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no 5124247738Sbapt 5125247738Sbapt_LT_TAGVAR(with_gnu_ld, $1)=$with_gnu_ld 5126247738Sbapt 5127247738Sbapt_LT_DECL([], [libext], [0], [Old archive suffix (normally "a")])dnl 5128247738Sbapt_LT_DECL([], [shrext_cmds], [1], [Shared library suffix (normally ".so")])dnl 5129247738Sbapt_LT_DECL([], [extract_expsyms_cmds], [2], 5130247738Sbapt [The commands to extract the exported symbol list from a shared archive]) 5131247738Sbapt 5132247738Sbapt# 5133247738Sbapt# Do we need to explicitly link libc? 5134247738Sbapt# 5135247738Sbaptcase "x$_LT_TAGVAR(archive_cmds_need_lc, $1)" in 5136247738Sbaptx|xyes) 5137247738Sbapt # Assume -lc should be added 5138247738Sbapt _LT_TAGVAR(archive_cmds_need_lc, $1)=yes 5139247738Sbapt 5140247738Sbapt if test "$enable_shared" = yes && test "$GCC" = yes; then 5141247738Sbapt case $_LT_TAGVAR(archive_cmds, $1) in 5142247738Sbapt *'~'*) 5143247738Sbapt # FIXME: we may have to deal with multi-command sequences. 5144247738Sbapt ;; 5145247738Sbapt '$CC '*) 5146247738Sbapt # Test whether the compiler implicitly links with -lc since on some 5147247738Sbapt # systems, -lgcc has to come before -lc. If gcc already passes -lc 5148247738Sbapt # to ld, don't add -lc before -lgcc. 5149247738Sbapt AC_MSG_CHECKING([whether -lc should be explicitly linked in]) 5150247738Sbapt $RM conftest* 5151247738Sbapt echo "$lt_simple_compile_test_code" > conftest.$ac_ext 5152247738Sbapt 5153247738Sbapt if AC_TRY_EVAL(ac_compile) 2>conftest.err; then 5154247738Sbapt soname=conftest 5155247738Sbapt lib=conftest 5156247738Sbapt libobjs=conftest.$ac_objext 5157247738Sbapt deplibs= 5158247738Sbapt wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) 5159247738Sbapt pic_flag=$_LT_TAGVAR(lt_prog_compiler_pic, $1) 5160247738Sbapt compiler_flags=-v 5161247738Sbapt linker_flags=-v 5162247738Sbapt verstring= 5163247738Sbapt output_objdir=. 5164247738Sbapt libname=conftest 5165247738Sbapt lt_save_allow_undefined_flag=$_LT_TAGVAR(allow_undefined_flag, $1) 5166247738Sbapt _LT_TAGVAR(allow_undefined_flag, $1)= 5167247738Sbapt if AC_TRY_EVAL(_LT_TAGVAR(archive_cmds, $1) 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 5168247738Sbapt then 5169247738Sbapt _LT_TAGVAR(archive_cmds_need_lc, $1)=no 5170247738Sbapt else 5171247738Sbapt _LT_TAGVAR(archive_cmds_need_lc, $1)=yes 5172247738Sbapt fi 5173247738Sbapt _LT_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag 5174247738Sbapt else 5175247738Sbapt cat conftest.err 1>&5 5176247738Sbapt fi 5177247738Sbapt $RM conftest* 5178247738Sbapt AC_MSG_RESULT([$_LT_TAGVAR(archive_cmds_need_lc, $1)]) 5179247738Sbapt ;; 5180247738Sbapt esac 5181247738Sbapt fi 5182247738Sbapt ;; 5183247738Sbaptesac 5184247738Sbapt 5185247738Sbapt_LT_TAGDECL([build_libtool_need_lc], [archive_cmds_need_lc], [0], 5186247738Sbapt [Whether or not to add -lc for building shared libraries]) 5187247738Sbapt_LT_TAGDECL([allow_libtool_libs_with_static_runtimes], 5188247738Sbapt [enable_shared_with_static_runtimes], [0], 5189247738Sbapt [Whether or not to disallow shared libs when runtime libs are static]) 5190247738Sbapt_LT_TAGDECL([], [export_dynamic_flag_spec], [1], 5191247738Sbapt [Compiler flag to allow reflexive dlopens]) 5192247738Sbapt_LT_TAGDECL([], [whole_archive_flag_spec], [1], 5193247738Sbapt [Compiler flag to generate shared objects directly from archives]) 5194247738Sbapt_LT_TAGDECL([], [compiler_needs_object], [1], 5195247738Sbapt [Whether the compiler copes with passing no objects directly]) 5196247738Sbapt_LT_TAGDECL([], [old_archive_from_new_cmds], [2], 5197247738Sbapt [Create an old-style archive from a shared archive]) 5198247738Sbapt_LT_TAGDECL([], [old_archive_from_expsyms_cmds], [2], 5199247738Sbapt [Create a temporary old-style archive to link instead of a shared archive]) 5200247738Sbapt_LT_TAGDECL([], [archive_cmds], [2], [Commands used to build a shared archive]) 5201247738Sbapt_LT_TAGDECL([], [archive_expsym_cmds], [2]) 5202247738Sbapt_LT_TAGDECL([], [module_cmds], [2], 5203247738Sbapt [Commands used to build a loadable module if different from building 5204247738Sbapt a shared archive.]) 5205247738Sbapt_LT_TAGDECL([], [module_expsym_cmds], [2]) 5206247738Sbapt_LT_TAGDECL([], [with_gnu_ld], [1], 5207247738Sbapt [Whether we are building with GNU ld or not]) 5208247738Sbapt_LT_TAGDECL([], [allow_undefined_flag], [1], 5209247738Sbapt [Flag that allows shared libraries with undefined symbols to be built]) 5210247738Sbapt_LT_TAGDECL([], [no_undefined_flag], [1], 5211247738Sbapt [Flag that enforces no undefined symbols]) 5212247738Sbapt_LT_TAGDECL([], [hardcode_libdir_flag_spec], [1], 5213247738Sbapt [Flag to hardcode $libdir into a binary during linking. 5214247738Sbapt This must work even if $libdir does not exist]) 5215247738Sbapt_LT_TAGDECL([], [hardcode_libdir_flag_spec_ld], [1], 5216247738Sbapt [[If ld is used when linking, flag to hardcode $libdir into a binary 5217247738Sbapt during linking. This must work even if $libdir does not exist]]) 5218247738Sbapt_LT_TAGDECL([], [hardcode_libdir_separator], [1], 5219247738Sbapt [Whether we need a single "-rpath" flag with a separated argument]) 5220247738Sbapt_LT_TAGDECL([], [hardcode_direct], [0], 5221247738Sbapt [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes 5222247738Sbapt DIR into the resulting binary]) 5223247738Sbapt_LT_TAGDECL([], [hardcode_direct_absolute], [0], 5224247738Sbapt [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes 5225247738Sbapt DIR into the resulting binary and the resulting library dependency is 5226247738Sbapt "absolute", i.e impossible to change by setting ${shlibpath_var} if the 5227247738Sbapt library is relocated]) 5228247738Sbapt_LT_TAGDECL([], [hardcode_minus_L], [0], 5229247738Sbapt [Set to "yes" if using the -LDIR flag during linking hardcodes DIR 5230247738Sbapt into the resulting binary]) 5231247738Sbapt_LT_TAGDECL([], [hardcode_shlibpath_var], [0], 5232247738Sbapt [Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR 5233247738Sbapt into the resulting binary]) 5234247738Sbapt_LT_TAGDECL([], [hardcode_automatic], [0], 5235247738Sbapt [Set to "yes" if building a shared library automatically hardcodes DIR 5236247738Sbapt into the library and all subsequent libraries and executables linked 5237247738Sbapt against it]) 5238247738Sbapt_LT_TAGDECL([], [inherit_rpath], [0], 5239247738Sbapt [Set to yes if linker adds runtime paths of dependent libraries 5240247738Sbapt to runtime path list]) 5241247738Sbapt_LT_TAGDECL([], [link_all_deplibs], [0], 5242247738Sbapt [Whether libtool must link a program against all its dependency libraries]) 5243247738Sbapt_LT_TAGDECL([], [fix_srcfile_path], [1], 5244247738Sbapt [Fix the shell variable $srcfile for the compiler]) 5245247738Sbapt_LT_TAGDECL([], [always_export_symbols], [0], 5246247738Sbapt [Set to "yes" if exported symbols are required]) 5247247738Sbapt_LT_TAGDECL([], [export_symbols_cmds], [2], 5248247738Sbapt [The commands to list exported symbols]) 5249247738Sbapt_LT_TAGDECL([], [exclude_expsyms], [1], 5250247738Sbapt [Symbols that should not be listed in the preloaded symbols]) 5251247738Sbapt_LT_TAGDECL([], [include_expsyms], [1], 5252247738Sbapt [Symbols that must always be exported]) 5253247738Sbapt_LT_TAGDECL([], [prelink_cmds], [2], 5254247738Sbapt [Commands necessary for linking programs (against libraries) with templates]) 5255247738Sbapt_LT_TAGDECL([], [file_list_spec], [1], 5256247738Sbapt [Specify filename containing input files]) 5257247738Sbaptdnl FIXME: Not yet implemented 5258247738Sbaptdnl _LT_TAGDECL([], [thread_safe_flag_spec], [1], 5259247738Sbaptdnl [Compiler flag to generate thread safe objects]) 5260247738Sbapt])# _LT_LINKER_SHLIBS 5261247738Sbapt 5262247738Sbapt 5263247738Sbapt# _LT_LANG_C_CONFIG([TAG]) 5264247738Sbapt# ------------------------ 5265247738Sbapt# Ensure that the configuration variables for a C compiler are suitably 5266247738Sbapt# defined. These variables are subsequently used by _LT_CONFIG to write 5267247738Sbapt# the compiler configuration to `libtool'. 5268247738Sbaptm4_defun([_LT_LANG_C_CONFIG], 5269247738Sbapt[m4_require([_LT_DECL_EGREP])dnl 5270247738Sbaptlt_save_CC="$CC" 5271247738SbaptAC_LANG_PUSH(C) 5272247738Sbapt 5273247738Sbapt# Source file extension for C test sources. 5274247738Sbaptac_ext=c 5275247738Sbapt 5276247738Sbapt# Object file extension for compiled C test sources. 5277247738Sbaptobjext=o 5278247738Sbapt_LT_TAGVAR(objext, $1)=$objext 5279247738Sbapt 5280247738Sbapt# Code to be used in simple compile tests 5281247738Sbaptlt_simple_compile_test_code="int some_variable = 0;" 5282247738Sbapt 5283247738Sbapt# Code to be used in simple link tests 5284247738Sbaptlt_simple_link_test_code='int main(){return(0);}' 5285247738Sbapt 5286247738Sbapt_LT_TAG_COMPILER 5287247738Sbapt# Save the default compiler, since it gets overwritten when the other 5288247738Sbapt# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP. 5289247738Sbaptcompiler_DEFAULT=$CC 5290247738Sbapt 5291247738Sbapt# save warnings/boilerplate of simple test code 5292247738Sbapt_LT_COMPILER_BOILERPLATE 5293247738Sbapt_LT_LINKER_BOILERPLATE 5294247738Sbapt 5295247738Sbaptif test -n "$compiler"; then 5296247738Sbapt _LT_COMPILER_NO_RTTI($1) 5297247738Sbapt _LT_COMPILER_PIC($1) 5298247738Sbapt _LT_COMPILER_C_O($1) 5299247738Sbapt _LT_COMPILER_FILE_LOCKS($1) 5300247738Sbapt _LT_LINKER_SHLIBS($1) 5301247738Sbapt _LT_SYS_DYNAMIC_LINKER($1) 5302247738Sbapt _LT_LINKER_HARDCODE_LIBPATH($1) 5303247738Sbapt LT_SYS_DLOPEN_SELF 5304247738Sbapt _LT_CMD_STRIPLIB 5305247738Sbapt 5306247738Sbapt # Report which library types will actually be built 5307247738Sbapt AC_MSG_CHECKING([if libtool supports shared libraries]) 5308247738Sbapt AC_MSG_RESULT([$can_build_shared]) 5309247738Sbapt 5310247738Sbapt AC_MSG_CHECKING([whether to build shared libraries]) 5311247738Sbapt test "$can_build_shared" = "no" && enable_shared=no 5312247738Sbapt 5313247738Sbapt # On AIX, shared libraries and static libraries use the same namespace, and 5314247738Sbapt # are all built from PIC. 5315247738Sbapt case $host_os in 5316247738Sbapt aix3*) 5317247738Sbapt test "$enable_shared" = yes && enable_static=no 5318247738Sbapt if test -n "$RANLIB"; then 5319247738Sbapt archive_cmds="$archive_cmds~\$RANLIB \$lib" 5320247738Sbapt postinstall_cmds='$RANLIB $lib' 5321247738Sbapt fi 5322247738Sbapt ;; 5323247738Sbapt 5324247738Sbapt aix[[4-9]]*) 5325247738Sbapt if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then 5326247738Sbapt test "$enable_shared" = yes && enable_static=no 5327247738Sbapt fi 5328247738Sbapt ;; 5329247738Sbapt esac 5330247738Sbapt AC_MSG_RESULT([$enable_shared]) 5331247738Sbapt 5332247738Sbapt AC_MSG_CHECKING([whether to build static libraries]) 5333247738Sbapt # Make sure either enable_shared or enable_static is yes. 5334247738Sbapt test "$enable_shared" = yes || enable_static=yes 5335247738Sbapt AC_MSG_RESULT([$enable_static]) 5336247738Sbapt 5337247738Sbapt _LT_CONFIG($1) 5338247738Sbaptfi 5339247738SbaptAC_LANG_POP 5340247738SbaptCC="$lt_save_CC" 5341247738Sbapt])# _LT_LANG_C_CONFIG 5342247738Sbapt 5343247738Sbapt 5344247738Sbapt# _LT_PROG_CXX 5345247738Sbapt# ------------ 5346247738Sbapt# Since AC_PROG_CXX is broken, in that it returns g++ if there is no c++ 5347247738Sbapt# compiler, we have our own version here. 5348247738Sbaptm4_defun([_LT_PROG_CXX], 5349247738Sbapt[ 5350247738Sbaptpushdef([AC_MSG_ERROR], [_lt_caught_CXX_error=yes]) 5351247738SbaptAC_PROG_CXX 5352247738Sbaptif test -n "$CXX" && ( test "X$CXX" != "Xno" && 5353247738Sbapt ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || 5354247738Sbapt (test "X$CXX" != "Xg++"))) ; then 5355247738Sbapt AC_PROG_CXXCPP 5356247738Sbaptelse 5357247738Sbapt _lt_caught_CXX_error=yes 5358247738Sbaptfi 5359247738Sbaptpopdef([AC_MSG_ERROR]) 5360247738Sbapt])# _LT_PROG_CXX 5361247738Sbapt 5362247738Sbaptdnl aclocal-1.4 backwards compatibility: 5363247738Sbaptdnl AC_DEFUN([_LT_PROG_CXX], []) 5364247738Sbapt 5365247738Sbapt 5366247738Sbapt# _LT_LANG_CXX_CONFIG([TAG]) 5367247738Sbapt# -------------------------- 5368247738Sbapt# Ensure that the configuration variables for a C++ compiler are suitably 5369247738Sbapt# defined. These variables are subsequently used by _LT_CONFIG to write 5370247738Sbapt# the compiler configuration to `libtool'. 5371247738Sbaptm4_defun([_LT_LANG_CXX_CONFIG], 5372247738Sbapt[AC_REQUIRE([_LT_PROG_CXX])dnl 5373247738Sbaptm4_require([_LT_FILEUTILS_DEFAULTS])dnl 5374247738Sbaptm4_require([_LT_DECL_EGREP])dnl 5375247738Sbapt 5376247738SbaptAC_LANG_PUSH(C++) 5377247738Sbapt_LT_TAGVAR(archive_cmds_need_lc, $1)=no 5378247738Sbapt_LT_TAGVAR(allow_undefined_flag, $1)= 5379247738Sbapt_LT_TAGVAR(always_export_symbols, $1)=no 5380247738Sbapt_LT_TAGVAR(archive_expsym_cmds, $1)= 5381247738Sbapt_LT_TAGVAR(compiler_needs_object, $1)=no 5382247738Sbapt_LT_TAGVAR(export_dynamic_flag_spec, $1)= 5383247738Sbapt_LT_TAGVAR(hardcode_direct, $1)=no 5384247738Sbapt_LT_TAGVAR(hardcode_direct_absolute, $1)=no 5385247738Sbapt_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 5386247738Sbapt_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= 5387247738Sbapt_LT_TAGVAR(hardcode_libdir_separator, $1)= 5388247738Sbapt_LT_TAGVAR(hardcode_minus_L, $1)=no 5389247738Sbapt_LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported 5390247738Sbapt_LT_TAGVAR(hardcode_automatic, $1)=no 5391247738Sbapt_LT_TAGVAR(inherit_rpath, $1)=no 5392247738Sbapt_LT_TAGVAR(module_cmds, $1)= 5393247738Sbapt_LT_TAGVAR(module_expsym_cmds, $1)= 5394247738Sbapt_LT_TAGVAR(link_all_deplibs, $1)=unknown 5395247738Sbapt_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 5396247738Sbapt_LT_TAGVAR(no_undefined_flag, $1)= 5397247738Sbapt_LT_TAGVAR(whole_archive_flag_spec, $1)= 5398247738Sbapt_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no 5399247738Sbapt 5400247738Sbapt# Source file extension for C++ test sources. 5401247738Sbaptac_ext=cpp 5402247738Sbapt 5403247738Sbapt# Object file extension for compiled C++ test sources. 5404247738Sbaptobjext=o 5405247738Sbapt_LT_TAGVAR(objext, $1)=$objext 5406247738Sbapt 5407247738Sbapt# No sense in running all these tests if we already determined that 5408247738Sbapt# the CXX compiler isn't working. Some variables (like enable_shared) 5409247738Sbapt# are currently assumed to apply to all compilers on this platform, 5410247738Sbapt# and will be corrupted by setting them based on a non-working compiler. 5411247738Sbaptif test "$_lt_caught_CXX_error" != yes; then 5412247738Sbapt # Code to be used in simple compile tests 5413247738Sbapt lt_simple_compile_test_code="int some_variable = 0;" 5414247738Sbapt 5415247738Sbapt # Code to be used in simple link tests 5416247738Sbapt lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }' 5417247738Sbapt 5418247738Sbapt # ltmain only uses $CC for tagged configurations so make sure $CC is set. 5419247738Sbapt _LT_TAG_COMPILER 5420247738Sbapt 5421247738Sbapt # save warnings/boilerplate of simple test code 5422247738Sbapt _LT_COMPILER_BOILERPLATE 5423247738Sbapt _LT_LINKER_BOILERPLATE 5424247738Sbapt 5425247738Sbapt # Allow CC to be a program name with arguments. 5426247738Sbapt lt_save_CC=$CC 5427247738Sbapt lt_save_LD=$LD 5428247738Sbapt lt_save_GCC=$GCC 5429247738Sbapt GCC=$GXX 5430247738Sbapt lt_save_with_gnu_ld=$with_gnu_ld 5431247738Sbapt lt_save_path_LD=$lt_cv_path_LD 5432247738Sbapt if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then 5433247738Sbapt lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx 5434247738Sbapt else 5435247738Sbapt $as_unset lt_cv_prog_gnu_ld 5436247738Sbapt fi 5437247738Sbapt if test -n "${lt_cv_path_LDCXX+set}"; then 5438247738Sbapt lt_cv_path_LD=$lt_cv_path_LDCXX 5439247738Sbapt else 5440247738Sbapt $as_unset lt_cv_path_LD 5441247738Sbapt fi 5442247738Sbapt test -z "${LDCXX+set}" || LD=$LDCXX 5443247738Sbapt CC=${CXX-"c++"} 5444247738Sbapt compiler=$CC 5445247738Sbapt _LT_TAGVAR(compiler, $1)=$CC 5446247738Sbapt _LT_CC_BASENAME([$compiler]) 5447247738Sbapt 5448247738Sbapt if test -n "$compiler"; then 5449247738Sbapt # We don't want -fno-exception when compiling C++ code, so set the 5450247738Sbapt # no_builtin_flag separately 5451247738Sbapt if test "$GXX" = yes; then 5452247738Sbapt _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' 5453247738Sbapt else 5454247738Sbapt _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= 5455247738Sbapt fi 5456247738Sbapt 5457247738Sbapt if test "$GXX" = yes; then 5458247738Sbapt # Set up default GNU C++ configuration 5459247738Sbapt 5460247738Sbapt LT_PATH_LD 5461247738Sbapt 5462247738Sbapt # Check if GNU C++ uses GNU ld as the underlying linker, since the 5463247738Sbapt # archiving commands below assume that GNU ld is being used. 5464247738Sbapt if test "$with_gnu_ld" = yes; then 5465247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' 5466247738Sbapt _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' 5467247738Sbapt 5468247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 5469247738Sbapt _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 5470247738Sbapt 5471247738Sbapt # If archive_cmds runs LD, not CC, wlarc should be empty 5472247738Sbapt # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to 5473247738Sbapt # investigate it a little bit more. (MM) 5474247738Sbapt wlarc='${wl}' 5475247738Sbapt 5476247738Sbapt # ancient GNU ld didn't support --whole-archive et. al. 5477247738Sbapt if eval "`$CC -print-prog-name=ld` --help 2>&1" | 5478247738Sbapt $GREP 'no-whole-archive' > /dev/null; then 5479247738Sbapt _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' 5480247738Sbapt else 5481247738Sbapt _LT_TAGVAR(whole_archive_flag_spec, $1)= 5482247738Sbapt fi 5483247738Sbapt else 5484247738Sbapt with_gnu_ld=no 5485247738Sbapt wlarc= 5486247738Sbapt 5487247738Sbapt # A generic and very simple default shared library creation 5488247738Sbapt # command for GNU C++ for the case where it uses the native 5489247738Sbapt # linker, instead of GNU ld. If possible, this setting should 5490247738Sbapt # overridden to take advantage of the native linker features on 5491247738Sbapt # the platform it is being used on. 5492247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' 5493247738Sbapt fi 5494247738Sbapt 5495247738Sbapt # Commands to make compiler produce verbose output that lists 5496247738Sbapt # what "hidden" libraries, object files and flags are used when 5497247738Sbapt # linking a shared library. 5498247738Sbapt output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"' 5499247738Sbapt 5500247738Sbapt else 5501247738Sbapt GXX=no 5502247738Sbapt with_gnu_ld=no 5503247738Sbapt wlarc= 5504247738Sbapt fi 5505247738Sbapt 5506247738Sbapt # PORTME: fill in a description of your system's C++ link characteristics 5507247738Sbapt AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) 5508247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=yes 5509247738Sbapt case $host_os in 5510247738Sbapt aix3*) 5511247738Sbapt # FIXME: insert proper C++ library support 5512247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 5513247738Sbapt ;; 5514247738Sbapt aix[[4-9]]*) 5515247738Sbapt if test "$host_cpu" = ia64; then 5516247738Sbapt # On IA64, the linker does run time linking by default, so we don't 5517247738Sbapt # have to do anything special. 5518247738Sbapt aix_use_runtimelinking=no 5519247738Sbapt exp_sym_flag='-Bexport' 5520247738Sbapt no_entry_flag="" 5521247738Sbapt else 5522247738Sbapt aix_use_runtimelinking=no 5523247738Sbapt 5524247738Sbapt # Test if we are trying to use run time linking or normal 5525247738Sbapt # AIX style linking. If -brtl is somewhere in LDFLAGS, we 5526247738Sbapt # need to do runtime linking. 5527247738Sbapt case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) 5528247738Sbapt for ld_flag in $LDFLAGS; do 5529247738Sbapt case $ld_flag in 5530247738Sbapt *-brtl*) 5531247738Sbapt aix_use_runtimelinking=yes 5532247738Sbapt break 5533247738Sbapt ;; 5534247738Sbapt esac 5535247738Sbapt done 5536247738Sbapt ;; 5537247738Sbapt esac 5538247738Sbapt 5539247738Sbapt exp_sym_flag='-bexport' 5540247738Sbapt no_entry_flag='-bnoentry' 5541247738Sbapt fi 5542247738Sbapt 5543247738Sbapt # When large executables or shared objects are built, AIX ld can 5544247738Sbapt # have problems creating the table of contents. If linking a library 5545247738Sbapt # or program results in "error TOC overflow" add -mminimal-toc to 5546247738Sbapt # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not 5547247738Sbapt # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. 5548247738Sbapt 5549247738Sbapt _LT_TAGVAR(archive_cmds, $1)='' 5550247738Sbapt _LT_TAGVAR(hardcode_direct, $1)=yes 5551247738Sbapt _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 5552247738Sbapt _LT_TAGVAR(hardcode_libdir_separator, $1)=':' 5553247738Sbapt _LT_TAGVAR(link_all_deplibs, $1)=yes 5554247738Sbapt _LT_TAGVAR(file_list_spec, $1)='${wl}-f,' 5555247738Sbapt 5556247738Sbapt if test "$GXX" = yes; then 5557247738Sbapt case $host_os in aix4.[[012]]|aix4.[[012]].*) 5558247738Sbapt # We only want to do this on AIX 4.2 and lower, the check 5559247738Sbapt # below for broken collect2 doesn't work under 4.3+ 5560247738Sbapt collect2name=`${CC} -print-prog-name=collect2` 5561247738Sbapt if test -f "$collect2name" && 5562247738Sbapt strings "$collect2name" | $GREP resolve_lib_name >/dev/null 5563247738Sbapt then 5564247738Sbapt # We have reworked collect2 5565247738Sbapt : 5566247738Sbapt else 5567247738Sbapt # We have old collect2 5568247738Sbapt _LT_TAGVAR(hardcode_direct, $1)=unsupported 5569247738Sbapt # It fails to find uninstalled libraries when the uninstalled 5570247738Sbapt # path is not listed in the libpath. Setting hardcode_minus_L 5571247738Sbapt # to unsupported forces relinking 5572247738Sbapt _LT_TAGVAR(hardcode_minus_L, $1)=yes 5573247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 5574247738Sbapt _LT_TAGVAR(hardcode_libdir_separator, $1)= 5575247738Sbapt fi 5576247738Sbapt esac 5577247738Sbapt shared_flag='-shared' 5578247738Sbapt if test "$aix_use_runtimelinking" = yes; then 5579247738Sbapt shared_flag="$shared_flag "'${wl}-G' 5580247738Sbapt fi 5581247738Sbapt else 5582247738Sbapt # not using gcc 5583247738Sbapt if test "$host_cpu" = ia64; then 5584247738Sbapt # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release 5585247738Sbapt # chokes on -Wl,-G. The following line is correct: 5586247738Sbapt shared_flag='-G' 5587247738Sbapt else 5588247738Sbapt if test "$aix_use_runtimelinking" = yes; then 5589247738Sbapt shared_flag='${wl}-G' 5590247738Sbapt else 5591247738Sbapt shared_flag='${wl}-bM:SRE' 5592247738Sbapt fi 5593247738Sbapt fi 5594247738Sbapt fi 5595247738Sbapt 5596247738Sbapt _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall' 5597247738Sbapt # It seems that -bexpall does not export symbols beginning with 5598247738Sbapt # underscore (_), so it is better to generate a list of symbols to 5599247738Sbapt # export. 5600247738Sbapt _LT_TAGVAR(always_export_symbols, $1)=yes 5601247738Sbapt if test "$aix_use_runtimelinking" = yes; then 5602247738Sbapt # Warning - without using the other runtime loading flags (-brtl), 5603247738Sbapt # -berok will link without error, but may produce a broken library. 5604247738Sbapt _LT_TAGVAR(allow_undefined_flag, $1)='-berok' 5605247738Sbapt # Determine the default libpath from the value encoded in an empty 5606247738Sbapt # executable. 5607247738Sbapt _LT_SYS_MODULE_PATH_AIX 5608247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" 5609247738Sbapt 5610247738Sbapt _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 $ECHO "X${wl}${allow_undefined_flag}" | $Xsed; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" 5611247738Sbapt else 5612247738Sbapt if test "$host_cpu" = ia64; then 5613247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' 5614247738Sbapt _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" 5615247738Sbapt _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" 5616247738Sbapt else 5617247738Sbapt # Determine the default libpath from the value encoded in an 5618247738Sbapt # empty executable. 5619247738Sbapt _LT_SYS_MODULE_PATH_AIX 5620247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" 5621247738Sbapt # Warning - without using the other run time loading flags, 5622247738Sbapt # -berok will link without error, but may produce a broken library. 5623247738Sbapt _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' 5624247738Sbapt _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' 5625247738Sbapt # Exported symbols can be pulled into shared objects from archives 5626247738Sbapt _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' 5627247738Sbapt _LT_TAGVAR(archive_cmds_need_lc, $1)=yes 5628247738Sbapt # This is similar to how AIX traditionally builds its shared 5629247738Sbapt # libraries. 5630247738Sbapt _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' 5631247738Sbapt fi 5632247738Sbapt fi 5633247738Sbapt ;; 5634247738Sbapt 5635247738Sbapt beos*) 5636247738Sbapt if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 5637247738Sbapt _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 5638247738Sbapt # Joseph Beckenbach <jrb3@best.com> says some releases of gcc 5639247738Sbapt # support --undefined. This deserves some investigation. FIXME 5640247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 5641247738Sbapt else 5642247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 5643247738Sbapt fi 5644247738Sbapt ;; 5645247738Sbapt 5646247738Sbapt chorus*) 5647247738Sbapt case $cc_basename in 5648247738Sbapt *) 5649247738Sbapt # FIXME: insert proper C++ library support 5650247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 5651247738Sbapt ;; 5652247738Sbapt esac 5653247738Sbapt ;; 5654247738Sbapt 5655247738Sbapt cygwin* | mingw* | pw32* | cegcc*) 5656247738Sbapt # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, 5657247738Sbapt # as there is no search path for DLLs. 5658247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 5659247738Sbapt _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 5660247738Sbapt _LT_TAGVAR(always_export_symbols, $1)=no 5661247738Sbapt _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 5662247738Sbapt 5663247738Sbapt if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then 5664247738Sbapt _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' 5665247738Sbapt # If the export-symbols file already is a .def file (1st line 5666247738Sbapt # is EXPORTS), use it as is; otherwise, prepend... 5667247738Sbapt _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then 5668247738Sbapt cp $export_symbols $output_objdir/$soname.def; 5669247738Sbapt else 5670247738Sbapt echo EXPORTS > $output_objdir/$soname.def; 5671247738Sbapt cat $export_symbols >> $output_objdir/$soname.def; 5672247738Sbapt fi~ 5673247738Sbapt $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' 5674247738Sbapt else 5675247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 5676247738Sbapt fi 5677247738Sbapt ;; 5678247738Sbapt darwin* | rhapsody*) 5679247738Sbapt _LT_DARWIN_LINKER_FEATURES($1) 5680247738Sbapt ;; 5681247738Sbapt 5682247738Sbapt dgux*) 5683247738Sbapt case $cc_basename in 5684247738Sbapt ec++*) 5685247738Sbapt # FIXME: insert proper C++ library support 5686247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 5687247738Sbapt ;; 5688247738Sbapt ghcx*) 5689247738Sbapt # Green Hills C++ Compiler 5690247738Sbapt # FIXME: insert proper C++ library support 5691247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 5692247738Sbapt ;; 5693247738Sbapt *) 5694247738Sbapt # FIXME: insert proper C++ library support 5695247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 5696247738Sbapt ;; 5697247738Sbapt esac 5698247738Sbapt ;; 5699247738Sbapt 5700247738Sbapt freebsd[[12]]*) 5701247738Sbapt # C++ shared libraries reported to be fairly broken before 5702247738Sbapt # switch to ELF 5703247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 5704247738Sbapt ;; 5705247738Sbapt 5706247738Sbapt freebsd-elf*) 5707247738Sbapt _LT_TAGVAR(archive_cmds_need_lc, $1)=no 5708247738Sbapt ;; 5709247738Sbapt 5710247738Sbapt freebsd* | dragonfly*) 5711247738Sbapt # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF 5712247738Sbapt # conventions 5713247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=yes 5714247738Sbapt ;; 5715247738Sbapt 5716247738Sbapt gnu*) 5717247738Sbapt ;; 5718247738Sbapt 5719247738Sbapt hpux9*) 5720247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 5721247738Sbapt _LT_TAGVAR(hardcode_libdir_separator, $1)=: 5722247738Sbapt _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 5723247738Sbapt _LT_TAGVAR(hardcode_direct, $1)=yes 5724247738Sbapt _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, 5725247738Sbapt # but as the default 5726247738Sbapt # location of the library. 5727247738Sbapt 5728247738Sbapt case $cc_basename in 5729247738Sbapt CC*) 5730247738Sbapt # FIXME: insert proper C++ library support 5731247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 5732247738Sbapt ;; 5733247738Sbapt aCC*) 5734247738Sbapt _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' 5735247738Sbapt # Commands to make compiler produce verbose output that lists 5736247738Sbapt # what "hidden" libraries, object files and flags are used when 5737247738Sbapt # linking a shared library. 5738247738Sbapt # 5739247738Sbapt # There doesn't appear to be a way to prevent this compiler from 5740247738Sbapt # explicitly linking system object files so we need to strip them 5741247738Sbapt # from the output so that they don't get included in the library 5742247738Sbapt # dependencies. 5743247738Sbapt 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; $ECHO "X$list" | $Xsed' 5744247738Sbapt ;; 5745247738Sbapt *) 5746247738Sbapt if test "$GXX" = yes; then 5747247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' 5748247738Sbapt else 5749247738Sbapt # FIXME: insert proper C++ library support 5750247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 5751247738Sbapt fi 5752247738Sbapt ;; 5753247738Sbapt esac 5754247738Sbapt ;; 5755247738Sbapt 5756247738Sbapt hpux10*|hpux11*) 5757247738Sbapt if test $with_gnu_ld = no; then 5758247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 5759247738Sbapt _LT_TAGVAR(hardcode_libdir_separator, $1)=: 5760247738Sbapt 5761247738Sbapt case $host_cpu in 5762247738Sbapt hppa*64*|ia64*) 5763247738Sbapt ;; 5764247738Sbapt *) 5765247738Sbapt _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 5766247738Sbapt ;; 5767247738Sbapt esac 5768247738Sbapt fi 5769247738Sbapt case $host_cpu in 5770247738Sbapt hppa*64*|ia64*) 5771247738Sbapt _LT_TAGVAR(hardcode_direct, $1)=no 5772247738Sbapt _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5773247738Sbapt ;; 5774247738Sbapt *) 5775247738Sbapt _LT_TAGVAR(hardcode_direct, $1)=yes 5776247738Sbapt _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 5777247738Sbapt _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, 5778247738Sbapt # but as the default 5779247738Sbapt # location of the library. 5780247738Sbapt ;; 5781247738Sbapt esac 5782247738Sbapt 5783247738Sbapt case $cc_basename in 5784247738Sbapt CC*) 5785247738Sbapt # FIXME: insert proper C++ library support 5786247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 5787247738Sbapt ;; 5788247738Sbapt aCC*) 5789247738Sbapt case $host_cpu in 5790247738Sbapt hppa*64*) 5791247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 5792247738Sbapt ;; 5793247738Sbapt ia64*) 5794247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 5795247738Sbapt ;; 5796247738Sbapt *) 5797247738Sbapt _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' 5798247738Sbapt ;; 5799247738Sbapt esac 5800247738Sbapt # Commands to make compiler produce verbose output that lists 5801247738Sbapt # what "hidden" libraries, object files and flags are used when 5802247738Sbapt # linking a shared library. 5803247738Sbapt # 5804247738Sbapt # There doesn't appear to be a way to prevent this compiler from 5805247738Sbapt # explicitly linking system object files so we need to strip them 5806247738Sbapt # from the output so that they don't get included in the library 5807247738Sbapt # dependencies. 5808247738Sbapt 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; $ECHO "X$list" | $Xsed' 5809247738Sbapt ;; 5810247738Sbapt *) 5811247738Sbapt if test "$GXX" = yes; then 5812247738Sbapt if test $with_gnu_ld = no; then 5813247738Sbapt case $host_cpu in 5814247738Sbapt hppa*64*) 5815247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 5816247738Sbapt ;; 5817247738Sbapt ia64*) 5818247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 5819247738Sbapt ;; 5820247738Sbapt *) 5821247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 5822247738Sbapt ;; 5823247738Sbapt esac 5824247738Sbapt fi 5825247738Sbapt else 5826247738Sbapt # FIXME: insert proper C++ library support 5827247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 5828247738Sbapt fi 5829247738Sbapt ;; 5830247738Sbapt esac 5831247738Sbapt ;; 5832247738Sbapt 5833247738Sbapt interix[[3-9]]*) 5834247738Sbapt _LT_TAGVAR(hardcode_direct, $1)=no 5835247738Sbapt _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 5836247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 5837247738Sbapt _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 5838247738Sbapt # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. 5839247738Sbapt # Instead, shared libraries are loaded at an image base (0x10000000 by 5840247738Sbapt # default) and relocated if they conflict, which is a slow very memory 5841247738Sbapt # consuming and fragmenting process. To avoid this, we pick a random, 5842247738Sbapt # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link 5843247738Sbapt # time. Moving up from 0x10000000 also allows more sbrk(2) space. 5844247738Sbapt _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' 5845247738Sbapt _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' 5846247738Sbapt ;; 5847247738Sbapt irix5* | irix6*) 5848247738Sbapt case $cc_basename in 5849247738Sbapt CC*) 5850247738Sbapt # SGI C++ 5851247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib' 5852247738Sbapt 5853247738Sbapt # Archives containing C++ object files must be created using 5854247738Sbapt # "CC -ar", where "CC" is the IRIX C++ compiler. This is 5855247738Sbapt # necessary to make sure instantiated templates are included 5856247738Sbapt # in the archive. 5857247738Sbapt _LT_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs' 5858247738Sbapt ;; 5859247738Sbapt *) 5860247738Sbapt if test "$GXX" = yes; then 5861247738Sbapt if test "$with_gnu_ld" = no; then 5862247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' 5863247738Sbapt else 5864247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` -o $lib' 5865247738Sbapt fi 5866247738Sbapt fi 5867247738Sbapt _LT_TAGVAR(link_all_deplibs, $1)=yes 5868247738Sbapt ;; 5869247738Sbapt esac 5870247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 5871247738Sbapt _LT_TAGVAR(hardcode_libdir_separator, $1)=: 5872247738Sbapt _LT_TAGVAR(inherit_rpath, $1)=yes 5873247738Sbapt ;; 5874247738Sbapt 5875247738Sbapt linux* | k*bsd*-gnu | kopensolaris*-gnu) 5876247738Sbapt case $cc_basename in 5877247738Sbapt KCC*) 5878247738Sbapt # Kuck and Associates, Inc. (KAI) C++ Compiler 5879247738Sbapt 5880247738Sbapt # KCC will only create a shared library if the output file 5881247738Sbapt # ends with ".so" (or ".sl" for HP-UX), so rename the library 5882247738Sbapt # to its proper name (with version) after linking. 5883247738Sbapt _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' 5884247738Sbapt _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' 5885247738Sbapt # Commands to make compiler produce verbose output that lists 5886247738Sbapt # what "hidden" libraries, object files and flags are used when 5887247738Sbapt # linking a shared library. 5888247738Sbapt # 5889247738Sbapt # There doesn't appear to be a way to prevent this compiler from 5890247738Sbapt # explicitly linking system object files so we need to strip them 5891247738Sbapt # from the output so that they don't get included in the library 5892247738Sbapt # dependencies. 5893247738Sbapt 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; $ECHO "X$list" | $Xsed' 5894247738Sbapt 5895247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 5896247738Sbapt _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 5897247738Sbapt 5898247738Sbapt # Archives containing C++ object files must be created using 5899247738Sbapt # "CC -Bstatic", where "CC" is the KAI C++ compiler. 5900247738Sbapt _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' 5901247738Sbapt ;; 5902247738Sbapt icpc* | ecpc* ) 5903247738Sbapt # Intel C++ 5904247738Sbapt with_gnu_ld=yes 5905247738Sbapt # version 8.0 and above of icpc choke on multiply defined symbols 5906247738Sbapt # if we add $predep_objects and $postdep_objects, however 7.1 and 5907247738Sbapt # earlier do not add the objects themselves. 5908247738Sbapt case `$CC -V 2>&1` in 5909247738Sbapt *"Version 7."*) 5910247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' 5911247738Sbapt _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' 5912247738Sbapt ;; 5913247738Sbapt *) # Version 8.0 or newer 5914247738Sbapt tmp_idyn= 5915247738Sbapt case $host_cpu in 5916247738Sbapt ia64*) tmp_idyn=' -i_dynamic';; 5917247738Sbapt esac 5918247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 5919247738Sbapt _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' 5920247738Sbapt ;; 5921247738Sbapt esac 5922247738Sbapt _LT_TAGVAR(archive_cmds_need_lc, $1)=no 5923247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 5924247738Sbapt _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 5925247738Sbapt _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' 5926247738Sbapt ;; 5927247738Sbapt pgCC* | pgcpp*) 5928247738Sbapt # Portland Group C++ compiler 5929247738Sbapt case `$CC -V` in 5930247738Sbapt *pgCC\ [[1-5]]* | *pgcpp\ [[1-5]]*) 5931247738Sbapt _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~ 5932247738Sbapt rm -rf $tpldir~ 5933247738Sbapt $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~ 5934247738Sbapt compile_command="$compile_command `find $tpldir -name \*.o | $NL2SP`"' 5935247738Sbapt _LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~ 5936247738Sbapt rm -rf $tpldir~ 5937247738Sbapt $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~ 5938247738Sbapt $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | $NL2SP`~ 5939247738Sbapt $RANLIB $oldlib' 5940247738Sbapt _LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~ 5941247738Sbapt rm -rf $tpldir~ 5942247738Sbapt $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ 5943247738Sbapt $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' 5944247738Sbapt _LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~ 5945247738Sbapt rm -rf $tpldir~ 5946247738Sbapt $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ 5947247738Sbapt $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib' 5948247738Sbapt ;; 5949247738Sbapt *) # Version 6 will use weak symbols 5950247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' 5951247738Sbapt _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' 5952247738Sbapt ;; 5953247738Sbapt esac 5954247738Sbapt 5955247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir' 5956247738Sbapt _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 5957247738Sbapt _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive' 5958247738Sbapt ;; 5959247738Sbapt cxx*) 5960247738Sbapt # Compaq C++ 5961247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' 5962247738Sbapt _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' 5963247738Sbapt 5964247738Sbapt runpath_var=LD_RUN_PATH 5965247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' 5966247738Sbapt _LT_TAGVAR(hardcode_libdir_separator, $1)=: 5967247738Sbapt 5968247738Sbapt # Commands to make compiler produce verbose output that lists 5969247738Sbapt # what "hidden" libraries, object files and flags are used when 5970247738Sbapt # linking a shared library. 5971247738Sbapt # 5972247738Sbapt # There doesn't appear to be a way to prevent this compiler from 5973247738Sbapt # explicitly linking system object files so we need to strip them 5974247738Sbapt # from the output so that they don't get included in the library 5975247738Sbapt # dependencies. 5976247738Sbapt output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`$ECHO "X$templist" | $Xsed -e "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; $ECHO "X$list" | $Xsed' 5977247738Sbapt ;; 5978247738Sbapt xl*) 5979247738Sbapt # IBM XL 8.0 on PPC, with GNU ld 5980247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 5981247738Sbapt _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 5982247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 5983247738Sbapt if test "x$supports_anon_versioning" = xyes; then 5984247738Sbapt _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ 5985247738Sbapt cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ 5986247738Sbapt echo "local: *; };" >> $output_objdir/$libname.ver~ 5987247738Sbapt $CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' 5988247738Sbapt fi 5989247738Sbapt ;; 5990247738Sbapt *) 5991247738Sbapt case `$CC -V 2>&1 | sed 5q` in 5992247738Sbapt *Sun\ C*) 5993247738Sbapt # Sun C++ 5.9 5994247738Sbapt _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' 5995247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 5996247738Sbapt _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' 5997247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 5998247738Sbapt _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; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive' 5999247738Sbapt _LT_TAGVAR(compiler_needs_object, $1)=yes 6000247738Sbapt 6001247738Sbapt # Not sure whether something based on 6002247738Sbapt # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 6003247738Sbapt # would be better. 6004247738Sbapt output_verbose_link_cmd='echo' 6005247738Sbapt 6006247738Sbapt # Archives containing C++ object files must be created using 6007247738Sbapt # "CC -xar", where "CC" is the Sun C++ compiler. This is 6008247738Sbapt # necessary to make sure instantiated templates are included 6009247738Sbapt # in the archive. 6010247738Sbapt _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' 6011247738Sbapt ;; 6012247738Sbapt esac 6013247738Sbapt ;; 6014247738Sbapt esac 6015247738Sbapt ;; 6016247738Sbapt 6017247738Sbapt lynxos*) 6018247738Sbapt # FIXME: insert proper C++ library support 6019247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 6020247738Sbapt ;; 6021247738Sbapt 6022247738Sbapt m88k*) 6023247738Sbapt # FIXME: insert proper C++ library support 6024247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 6025247738Sbapt ;; 6026247738Sbapt 6027247738Sbapt mvs*) 6028247738Sbapt case $cc_basename in 6029247738Sbapt cxx*) 6030247738Sbapt # FIXME: insert proper C++ library support 6031247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 6032247738Sbapt ;; 6033247738Sbapt *) 6034247738Sbapt # FIXME: insert proper C++ library support 6035247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 6036247738Sbapt ;; 6037247738Sbapt esac 6038247738Sbapt ;; 6039247738Sbapt 6040247738Sbapt netbsd*) 6041247738Sbapt if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then 6042247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' 6043247738Sbapt wlarc= 6044247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 6045247738Sbapt _LT_TAGVAR(hardcode_direct, $1)=yes 6046247738Sbapt _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 6047247738Sbapt fi 6048247738Sbapt # Workaround some broken pre-1.5 toolchains 6049247738Sbapt output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' 6050247738Sbapt ;; 6051247738Sbapt 6052247738Sbapt *nto* | *qnx*) 6053247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=yes 6054247738Sbapt ;; 6055247738Sbapt 6056247738Sbapt openbsd2*) 6057247738Sbapt # C++ shared libraries are fairly broken 6058247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 6059247738Sbapt ;; 6060247738Sbapt 6061247738Sbapt openbsd*) 6062247738Sbapt if test -f /usr/libexec/ld.so; then 6063247738Sbapt _LT_TAGVAR(hardcode_direct, $1)=yes 6064247738Sbapt _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 6065247738Sbapt _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 6066247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' 6067247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 6068247738Sbapt if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then 6069247738Sbapt _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' 6070247738Sbapt _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 6071247738Sbapt _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' 6072247738Sbapt fi 6073247738Sbapt output_verbose_link_cmd=echo 6074247738Sbapt else 6075247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 6076247738Sbapt fi 6077247738Sbapt ;; 6078247738Sbapt 6079247738Sbapt osf3* | osf4* | osf5*) 6080247738Sbapt case $cc_basename in 6081247738Sbapt KCC*) 6082247738Sbapt # Kuck and Associates, Inc. (KAI) C++ Compiler 6083247738Sbapt 6084247738Sbapt # KCC will only create a shared library if the output file 6085247738Sbapt # ends with ".so" (or ".sl" for HP-UX), so rename the library 6086247738Sbapt # to its proper name (with version) after linking. 6087247738Sbapt _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' 6088247738Sbapt 6089247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 6090247738Sbapt _LT_TAGVAR(hardcode_libdir_separator, $1)=: 6091247738Sbapt 6092247738Sbapt # Archives containing C++ object files must be created using 6093247738Sbapt # the KAI C++ compiler. 6094247738Sbapt case $host in 6095247738Sbapt osf3*) _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;; 6096247738Sbapt *) _LT_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' ;; 6097247738Sbapt esac 6098247738Sbapt ;; 6099247738Sbapt RCC*) 6100247738Sbapt # Rational C++ 2.4.1 6101247738Sbapt # FIXME: insert proper C++ library support 6102247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 6103247738Sbapt ;; 6104247738Sbapt cxx*) 6105247738Sbapt case $host in 6106247738Sbapt osf3*) 6107247738Sbapt _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' 6108247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && $ECHO "X${wl}-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib' 6109247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 6110247738Sbapt ;; 6111247738Sbapt *) 6112247738Sbapt _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' 6113247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib' 6114247738Sbapt _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ 6115247738Sbapt echo "-hidden">> $lib.exp~ 6116247738Sbapt $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 "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib~ 6117247738Sbapt $RM $lib.exp' 6118247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' 6119247738Sbapt ;; 6120247738Sbapt esac 6121247738Sbapt 6122247738Sbapt _LT_TAGVAR(hardcode_libdir_separator, $1)=: 6123247738Sbapt 6124247738Sbapt # Commands to make compiler produce verbose output that lists 6125247738Sbapt # what "hidden" libraries, object files and flags are used when 6126247738Sbapt # linking a shared library. 6127247738Sbapt # 6128247738Sbapt # There doesn't appear to be a way to prevent this compiler from 6129247738Sbapt # explicitly linking system object files so we need to strip them 6130247738Sbapt # from the output so that they don't get included in the library 6131247738Sbapt # dependencies. 6132247738Sbapt output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`$ECHO "X$templist" | $Xsed -e "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; $ECHO "X$list" | $Xsed' 6133247738Sbapt ;; 6134247738Sbapt *) 6135247738Sbapt if test "$GXX" = yes && test "$with_gnu_ld" = no; then 6136247738Sbapt _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' 6137247738Sbapt case $host in 6138247738Sbapt osf3*) 6139247738Sbapt _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" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' 6140247738Sbapt ;; 6141247738Sbapt *) 6142247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' 6143247738Sbapt ;; 6144247738Sbapt esac 6145247738Sbapt 6146247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 6147247738Sbapt _LT_TAGVAR(hardcode_libdir_separator, $1)=: 6148247738Sbapt 6149247738Sbapt # Commands to make compiler produce verbose output that lists 6150247738Sbapt # what "hidden" libraries, object files and flags are used when 6151247738Sbapt # linking a shared library. 6152247738Sbapt output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"' 6153247738Sbapt 6154247738Sbapt else 6155247738Sbapt # FIXME: insert proper C++ library support 6156247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 6157247738Sbapt fi 6158247738Sbapt ;; 6159247738Sbapt esac 6160247738Sbapt ;; 6161247738Sbapt 6162247738Sbapt psos*) 6163247738Sbapt # FIXME: insert proper C++ library support 6164247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 6165247738Sbapt ;; 6166247738Sbapt 6167247738Sbapt sunos4*) 6168247738Sbapt case $cc_basename in 6169247738Sbapt CC*) 6170247738Sbapt # Sun C++ 4.x 6171247738Sbapt # FIXME: insert proper C++ library support 6172247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 6173247738Sbapt ;; 6174247738Sbapt lcc*) 6175247738Sbapt # Lucid 6176247738Sbapt # FIXME: insert proper C++ library support 6177247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 6178247738Sbapt ;; 6179247738Sbapt *) 6180247738Sbapt # FIXME: insert proper C++ library support 6181247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 6182247738Sbapt ;; 6183247738Sbapt esac 6184247738Sbapt ;; 6185247738Sbapt 6186247738Sbapt solaris*) 6187247738Sbapt case $cc_basename in 6188247738Sbapt CC*) 6189247738Sbapt # Sun C++ 4.2, 5.x and Centerline C++ 6190247738Sbapt _LT_TAGVAR(archive_cmds_need_lc,$1)=yes 6191247738Sbapt _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' 6192247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 6193247738Sbapt _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 6194247738Sbapt $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' 6195247738Sbapt 6196247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 6197247738Sbapt _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 6198247738Sbapt case $host_os in 6199247738Sbapt solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; 6200247738Sbapt *) 6201247738Sbapt # The compiler driver will combine and reorder linker options, 6202247738Sbapt # but understands `-z linker_flag'. 6203247738Sbapt # Supported since Solaris 2.6 (maybe 2.5.1?) 6204247738Sbapt _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' 6205247738Sbapt ;; 6206247738Sbapt esac 6207247738Sbapt _LT_TAGVAR(link_all_deplibs, $1)=yes 6208247738Sbapt 6209247738Sbapt output_verbose_link_cmd='echo' 6210247738Sbapt 6211247738Sbapt # Archives containing C++ object files must be created using 6212247738Sbapt # "CC -xar", where "CC" is the Sun C++ compiler. This is 6213247738Sbapt # necessary to make sure instantiated templates are included 6214247738Sbapt # in the archive. 6215247738Sbapt _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' 6216247738Sbapt ;; 6217247738Sbapt gcx*) 6218247738Sbapt # Green Hills C++ Compiler 6219247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' 6220247738Sbapt 6221247738Sbapt # The C++ compiler must be used to create the archive. 6222247738Sbapt _LT_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs' 6223247738Sbapt ;; 6224247738Sbapt *) 6225247738Sbapt # GNU C++ compiler with Solaris linker 6226247738Sbapt if test "$GXX" = yes && test "$with_gnu_ld" = no; then 6227247738Sbapt _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs' 6228247738Sbapt if $CC --version | $GREP -v '^2\.7' > /dev/null; then 6229247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' 6230247738Sbapt _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 6231247738Sbapt $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' 6232247738Sbapt 6233247738Sbapt # Commands to make compiler produce verbose output that lists 6234247738Sbapt # what "hidden" libraries, object files and flags are used when 6235247738Sbapt # linking a shared library. 6236247738Sbapt output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"' 6237247738Sbapt else 6238247738Sbapt # g++ 2.7 appears to require `-G' NOT `-shared' on this 6239247738Sbapt # platform. 6240247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' 6241247738Sbapt _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 6242247738Sbapt $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' 6243247738Sbapt 6244247738Sbapt # Commands to make compiler produce verbose output that lists 6245247738Sbapt # what "hidden" libraries, object files and flags are used when 6246247738Sbapt # linking a shared library. 6247247738Sbapt output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"' 6248247738Sbapt fi 6249247738Sbapt 6250247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir' 6251247738Sbapt case $host_os in 6252247738Sbapt solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; 6253247738Sbapt *) 6254247738Sbapt _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' 6255247738Sbapt ;; 6256247738Sbapt esac 6257247738Sbapt fi 6258247738Sbapt ;; 6259247738Sbapt esac 6260247738Sbapt ;; 6261247738Sbapt 6262247738Sbapt sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) 6263247738Sbapt _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' 6264247738Sbapt _LT_TAGVAR(archive_cmds_need_lc, $1)=no 6265247738Sbapt _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 6266247738Sbapt runpath_var='LD_RUN_PATH' 6267247738Sbapt 6268247738Sbapt case $cc_basename in 6269247738Sbapt CC*) 6270247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 6271247738Sbapt _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 6272247738Sbapt ;; 6273247738Sbapt *) 6274247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 6275247738Sbapt _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 6276247738Sbapt ;; 6277247738Sbapt esac 6278247738Sbapt ;; 6279247738Sbapt 6280247738Sbapt sysv5* | sco3.2v5* | sco5v6*) 6281247738Sbapt # Note: We can NOT use -z defs as we might desire, because we do not 6282247738Sbapt # link with -lc, and that would cause any symbols used from libc to 6283247738Sbapt # always be unresolved, which means just about no library would 6284247738Sbapt # ever link correctly. If we're not using GNU ld we use -z text 6285247738Sbapt # though, which does catch some bad symbols but isn't as heavy-handed 6286247738Sbapt # as -z defs. 6287247738Sbapt _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' 6288247738Sbapt _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs' 6289247738Sbapt _LT_TAGVAR(archive_cmds_need_lc, $1)=no 6290247738Sbapt _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 6291247738Sbapt _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir' 6292247738Sbapt _LT_TAGVAR(hardcode_libdir_separator, $1)=':' 6293247738Sbapt _LT_TAGVAR(link_all_deplibs, $1)=yes 6294247738Sbapt _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' 6295247738Sbapt runpath_var='LD_RUN_PATH' 6296247738Sbapt 6297247738Sbapt case $cc_basename in 6298247738Sbapt CC*) 6299247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 6300247738Sbapt _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 6301247738Sbapt ;; 6302247738Sbapt *) 6303247738Sbapt _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 6304247738Sbapt _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 6305247738Sbapt ;; 6306247738Sbapt esac 6307247738Sbapt ;; 6308247738Sbapt 6309247738Sbapt tandem*) 6310247738Sbapt case $cc_basename in 6311247738Sbapt NCC*) 6312247738Sbapt # NonStop-UX NCC 3.20 6313247738Sbapt # FIXME: insert proper C++ library support 6314247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 6315247738Sbapt ;; 6316247738Sbapt *) 6317247738Sbapt # FIXME: insert proper C++ library support 6318247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 6319247738Sbapt ;; 6320247738Sbapt esac 6321247738Sbapt ;; 6322247738Sbapt 6323247738Sbapt vxworks*) 6324247738Sbapt # FIXME: insert proper C++ library support 6325247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 6326247738Sbapt ;; 6327247738Sbapt 6328247738Sbapt *) 6329247738Sbapt # FIXME: insert proper C++ library support 6330247738Sbapt _LT_TAGVAR(ld_shlibs, $1)=no 6331247738Sbapt ;; 6332247738Sbapt esac 6333247738Sbapt 6334247738Sbapt AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) 6335247738Sbapt test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no 6336247738Sbapt 6337247738Sbapt _LT_TAGVAR(GCC, $1)="$GXX" 6338247738Sbapt _LT_TAGVAR(LD, $1)="$LD" 6339247738Sbapt 6340247738Sbapt ## CAVEAT EMPTOR: 6341247738Sbapt ## There is no encapsulation within the following macros, do not change 6342247738Sbapt ## the running order or otherwise move them around unless you know exactly 6343247738Sbapt ## what you are doing... 6344247738Sbapt _LT_SYS_HIDDEN_LIBDEPS($1) 6345247738Sbapt _LT_COMPILER_PIC($1) 6346247738Sbapt _LT_COMPILER_C_O($1) 6347247738Sbapt _LT_COMPILER_FILE_LOCKS($1) 6348247738Sbapt _LT_LINKER_SHLIBS($1) 6349247738Sbapt _LT_SYS_DYNAMIC_LINKER($1) 6350247738Sbapt _LT_LINKER_HARDCODE_LIBPATH($1) 6351247738Sbapt 6352247738Sbapt _LT_CONFIG($1) 6353247738Sbapt fi # test -n "$compiler" 6354247738Sbapt 6355247738Sbapt CC=$lt_save_CC 6356247738Sbapt LDCXX=$LD 6357247738Sbapt LD=$lt_save_LD 6358247738Sbapt GCC=$lt_save_GCC 6359247738Sbapt with_gnu_ld=$lt_save_with_gnu_ld 6360247738Sbapt lt_cv_path_LDCXX=$lt_cv_path_LD 6361247738Sbapt lt_cv_path_LD=$lt_save_path_LD 6362247738Sbapt lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld 6363247738Sbapt lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld 6364247738Sbaptfi # test "$_lt_caught_CXX_error" != yes 6365247738Sbapt 6366247738SbaptAC_LANG_POP 6367247738Sbapt])# _LT_LANG_CXX_CONFIG 6368247738Sbapt 6369247738Sbapt 6370247738Sbapt# _LT_SYS_HIDDEN_LIBDEPS([TAGNAME]) 6371247738Sbapt# --------------------------------- 6372247738Sbapt# Figure out "hidden" library dependencies from verbose 6373247738Sbapt# compiler output when linking a shared library. 6374247738Sbapt# Parse the compiler output and extract the necessary 6375247738Sbapt# objects, libraries and library flags. 6376247738Sbaptm4_defun([_LT_SYS_HIDDEN_LIBDEPS], 6377247738Sbapt[m4_require([_LT_FILEUTILS_DEFAULTS])dnl 6378247738Sbapt# Dependencies to place before and after the object being linked: 6379247738Sbapt_LT_TAGVAR(predep_objects, $1)= 6380247738Sbapt_LT_TAGVAR(postdep_objects, $1)= 6381247738Sbapt_LT_TAGVAR(predeps, $1)= 6382247738Sbapt_LT_TAGVAR(postdeps, $1)= 6383247738Sbapt_LT_TAGVAR(compiler_lib_search_path, $1)= 6384247738Sbapt 6385247738Sbaptdnl we can't use the lt_simple_compile_test_code here, 6386247738Sbaptdnl because it contains code intended for an executable, 6387247738Sbaptdnl not a library. It's possible we should let each 6388247738Sbaptdnl tag define a new lt_????_link_test_code variable, 6389247738Sbaptdnl but it's only used here... 6390247738Sbaptm4_if([$1], [], [cat > conftest.$ac_ext <<_LT_EOF 6391247738Sbaptint a; 6392247738Sbaptvoid foo (void) { a = 0; } 6393247738Sbapt_LT_EOF 6394247738Sbapt], [$1], [CXX], [cat > conftest.$ac_ext <<_LT_EOF 6395247738Sbaptclass Foo 6396247738Sbapt{ 6397247738Sbaptpublic: 6398247738Sbapt Foo (void) { a = 0; } 6399247738Sbaptprivate: 6400247738Sbapt int a; 6401247738Sbapt}; 6402247738Sbapt_LT_EOF 6403247738Sbapt], [$1], [F77], [cat > conftest.$ac_ext <<_LT_EOF 6404247738Sbapt subroutine foo 6405247738Sbapt implicit none 6406247738Sbapt integer*4 a 6407247738Sbapt a=0 6408247738Sbapt return 6409247738Sbapt end 6410247738Sbapt_LT_EOF 6411247738Sbapt], [$1], [FC], [cat > conftest.$ac_ext <<_LT_EOF 6412247738Sbapt subroutine foo 6413247738Sbapt implicit none 6414247738Sbapt integer a 6415247738Sbapt a=0 6416247738Sbapt return 6417247738Sbapt end 6418247738Sbapt_LT_EOF 6419247738Sbapt], [$1], [GCJ], [cat > conftest.$ac_ext <<_LT_EOF 6420247738Sbaptpublic class foo { 6421247738Sbapt private int a; 6422247738Sbapt public void bar (void) { 6423247738Sbapt a = 0; 6424247738Sbapt } 6425247738Sbapt}; 6426247738Sbapt_LT_EOF 6427247738Sbapt]) 6428247738Sbaptdnl Parse the compiler output and extract the necessary 6429247738Sbaptdnl objects, libraries and library flags. 6430247738Sbaptif AC_TRY_EVAL(ac_compile); then 6431247738Sbapt # Parse the compiler output and extract the necessary 6432247738Sbapt # objects, libraries and library flags. 6433247738Sbapt 6434247738Sbapt # Sentinel used to keep track of whether or not we are before 6435247738Sbapt # the conftest object file. 6436247738Sbapt pre_test_object_deps_done=no 6437247738Sbapt 6438247738Sbapt for p in `eval "$output_verbose_link_cmd"`; do 6439247738Sbapt case $p in 6440247738Sbapt 6441247738Sbapt -L* | -R* | -l*) 6442247738Sbapt # Some compilers place space between "-{L,R}" and the path. 6443247738Sbapt # Remove the space. 6444247738Sbapt if test $p = "-L" || 6445247738Sbapt test $p = "-R"; then 6446247738Sbapt prev=$p 6447247738Sbapt continue 6448247738Sbapt else 6449247738Sbapt prev= 6450247738Sbapt fi 6451247738Sbapt 6452247738Sbapt if test "$pre_test_object_deps_done" = no; then 6453247738Sbapt case $p in 6454247738Sbapt -L* | -R*) 6455247738Sbapt # Internal compiler library paths should come after those 6456247738Sbapt # provided the user. The postdeps already come after the 6457247738Sbapt # user supplied libs so there is no need to process them. 6458247738Sbapt if test -z "$_LT_TAGVAR(compiler_lib_search_path, $1)"; then 6459247738Sbapt _LT_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}" 6460247738Sbapt else 6461247738Sbapt _LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}" 6462247738Sbapt fi 6463247738Sbapt ;; 6464247738Sbapt # The "-l" case would never come before the object being 6465247738Sbapt # linked, so don't bother handling this case. 6466247738Sbapt esac 6467247738Sbapt else 6468247738Sbapt if test -z "$_LT_TAGVAR(postdeps, $1)"; then 6469247738Sbapt _LT_TAGVAR(postdeps, $1)="${prev}${p}" 6470247738Sbapt else 6471247738Sbapt _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} ${prev}${p}" 6472247738Sbapt fi 6473247738Sbapt fi 6474247738Sbapt ;; 6475247738Sbapt 6476247738Sbapt *.$objext) 6477247738Sbapt # This assumes that the test object file only shows up 6478247738Sbapt # once in the compiler output. 6479247738Sbapt if test "$p" = "conftest.$objext"; then 6480247738Sbapt pre_test_object_deps_done=yes 6481247738Sbapt continue 6482247738Sbapt fi 6483247738Sbapt 6484247738Sbapt if test "$pre_test_object_deps_done" = no; then 6485247738Sbapt if test -z "$_LT_TAGVAR(predep_objects, $1)"; then 6486247738Sbapt _LT_TAGVAR(predep_objects, $1)="$p" 6487247738Sbapt else 6488247738Sbapt _LT_TAGVAR(predep_objects, $1)="$_LT_TAGVAR(predep_objects, $1) $p" 6489247738Sbapt fi 6490247738Sbapt else 6491247738Sbapt if test -z "$_LT_TAGVAR(postdep_objects, $1)"; then 6492247738Sbapt _LT_TAGVAR(postdep_objects, $1)="$p" 6493247738Sbapt else 6494247738Sbapt _LT_TAGVAR(postdep_objects, $1)="$_LT_TAGVAR(postdep_objects, $1) $p" 6495247738Sbapt fi 6496247738Sbapt fi 6497247738Sbapt ;; 6498247738Sbapt 6499247738Sbapt *) ;; # Ignore the rest. 6500247738Sbapt 6501247738Sbapt esac 6502247738Sbapt done 6503247738Sbapt 6504247738Sbapt # Clean up. 6505247738Sbapt rm -f a.out a.exe 6506247738Sbaptelse 6507247738Sbapt echo "libtool.m4: error: problem compiling $1 test program" 6508247738Sbaptfi 6509247738Sbapt 6510247738Sbapt$RM -f confest.$objext 6511247738Sbapt 6512247738Sbapt# PORTME: override above test on systems where it is broken 6513247738Sbaptm4_if([$1], [CXX], 6514247738Sbapt[case $host_os in 6515247738Sbaptinterix[[3-9]]*) 6516247738Sbapt # Interix 3.5 installs completely hosed .la files for C++, so rather than 6517247738Sbapt # hack all around it, let's just trust "g++" to DTRT. 6518247738Sbapt _LT_TAGVAR(predep_objects,$1)= 6519247738Sbapt _LT_TAGVAR(postdep_objects,$1)= 6520247738Sbapt _LT_TAGVAR(postdeps,$1)= 6521247738Sbapt ;; 6522247738Sbapt 6523247738Sbaptlinux*) 6524247738Sbapt case `$CC -V 2>&1 | sed 5q` in 6525247738Sbapt *Sun\ C*) 6526247738Sbapt # Sun C++ 5.9 6527247738Sbapt 6528247738Sbapt # The more standards-conforming stlport4 library is 6529247738Sbapt # incompatible with the Cstd library. Avoid specifying 6530247738Sbapt # it if it's in CXXFLAGS. Ignore libCrun as 6531247738Sbapt # -library=stlport4 depends on it. 6532247738Sbapt case " $CXX $CXXFLAGS " in 6533247738Sbapt *" -library=stlport4 "*) 6534247738Sbapt solaris_use_stlport4=yes 6535247738Sbapt ;; 6536247738Sbapt esac 6537247738Sbapt 6538247738Sbapt if test "$solaris_use_stlport4" != yes; then 6539247738Sbapt _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun' 6540247738Sbapt fi 6541247738Sbapt ;; 6542247738Sbapt esac 6543247738Sbapt ;; 6544247738Sbapt 6545247738Sbaptsolaris*) 6546247738Sbapt case $cc_basename in 6547247738Sbapt CC*) 6548247738Sbapt # The more standards-conforming stlport4 library is 6549247738Sbapt # incompatible with the Cstd library. Avoid specifying 6550247738Sbapt # it if it's in CXXFLAGS. Ignore libCrun as 6551247738Sbapt # -library=stlport4 depends on it. 6552247738Sbapt case " $CXX $CXXFLAGS " in 6553247738Sbapt *" -library=stlport4 "*) 6554247738Sbapt solaris_use_stlport4=yes 6555247738Sbapt ;; 6556247738Sbapt esac 6557247738Sbapt 6558247738Sbapt # Adding this requires a known-good setup of shared libraries for 6559247738Sbapt # Sun compiler versions before 5.6, else PIC objects from an old 6560247738Sbapt # archive will be linked into the output, leading to subtle bugs. 6561247738Sbapt if test "$solaris_use_stlport4" != yes; then 6562247738Sbapt _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun' 6563247738Sbapt fi 6564247738Sbapt ;; 6565247738Sbapt esac 6566247738Sbapt ;; 6567247738Sbaptesac 6568247738Sbapt]) 6569247738Sbapt 6570247738Sbaptcase " $_LT_TAGVAR(postdeps, $1) " in 6571247738Sbapt*" -lc "*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;; 6572247738Sbaptesac 6573247738Sbapt _LT_TAGVAR(compiler_lib_search_dirs, $1)= 6574247738Sbaptif test -n "${_LT_TAGVAR(compiler_lib_search_path, $1)}"; then 6575247738Sbapt _LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | ${SED} -e 's! -L! !g' -e 's!^ !!'` 6576247738Sbaptfi 6577247738Sbapt_LT_TAGDECL([], [compiler_lib_search_dirs], [1], 6578247738Sbapt [The directories searched by this compiler when creating a shared library]) 6579247738Sbapt_LT_TAGDECL([], [predep_objects], [1], 6580247738Sbapt [Dependencies to place before and after the objects being linked to 6581247738Sbapt create a shared library]) 6582247738Sbapt_LT_TAGDECL([], [postdep_objects], [1]) 6583247738Sbapt_LT_TAGDECL([], [predeps], [1]) 6584247738Sbapt_LT_TAGDECL([], [postdeps], [1]) 6585247738Sbapt_LT_TAGDECL([], [compiler_lib_search_path], [1], 6586247738Sbapt [The library search path used internally by the compiler when linking 6587247738Sbapt a shared library]) 6588247738Sbapt])# _LT_SYS_HIDDEN_LIBDEPS 6589247738Sbapt 6590247738Sbapt 6591247738Sbapt# _LT_PROG_F77 6592247738Sbapt# ------------ 6593247738Sbapt# Since AC_PROG_F77 is broken, in that it returns the empty string 6594247738Sbapt# if there is no fortran compiler, we have our own version here. 6595247738Sbaptm4_defun([_LT_PROG_F77], 6596247738Sbapt[ 6597247738Sbaptpushdef([AC_MSG_ERROR], [_lt_disable_F77=yes]) 6598247738SbaptAC_PROG_F77 6599247738Sbaptif test -z "$F77" || test "X$F77" = "Xno"; then 6600247738Sbapt _lt_disable_F77=yes 6601247738Sbaptfi 6602247738Sbaptpopdef([AC_MSG_ERROR]) 6603247738Sbapt])# _LT_PROG_F77 6604247738Sbapt 6605247738Sbaptdnl aclocal-1.4 backwards compatibility: 6606247738Sbaptdnl AC_DEFUN([_LT_PROG_F77], []) 6607247738Sbapt 6608247738Sbapt 6609247738Sbapt# _LT_LANG_F77_CONFIG([TAG]) 6610247738Sbapt# -------------------------- 6611247738Sbapt# Ensure that the configuration variables for a Fortran 77 compiler are 6612247738Sbapt# suitably defined. These variables are subsequently used by _LT_CONFIG 6613247738Sbapt# to write the compiler configuration to `libtool'. 6614247738Sbaptm4_defun([_LT_LANG_F77_CONFIG], 6615247738Sbapt[AC_REQUIRE([_LT_PROG_F77])dnl 6616247738SbaptAC_LANG_PUSH(Fortran 77) 6617247738Sbapt 6618247738Sbapt_LT_TAGVAR(archive_cmds_need_lc, $1)=no 6619247738Sbapt_LT_TAGVAR(allow_undefined_flag, $1)= 6620247738Sbapt_LT_TAGVAR(always_export_symbols, $1)=no 6621247738Sbapt_LT_TAGVAR(archive_expsym_cmds, $1)= 6622247738Sbapt_LT_TAGVAR(export_dynamic_flag_spec, $1)= 6623247738Sbapt_LT_TAGVAR(hardcode_direct, $1)=no 6624247738Sbapt_LT_TAGVAR(hardcode_direct_absolute, $1)=no 6625247738Sbapt_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 6626247738Sbapt_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= 6627247738Sbapt_LT_TAGVAR(hardcode_libdir_separator, $1)= 6628247738Sbapt_LT_TAGVAR(hardcode_minus_L, $1)=no 6629247738Sbapt_LT_TAGVAR(hardcode_automatic, $1)=no 6630247738Sbapt_LT_TAGVAR(inherit_rpath, $1)=no 6631247738Sbapt_LT_TAGVAR(module_cmds, $1)= 6632247738Sbapt_LT_TAGVAR(module_expsym_cmds, $1)= 6633247738Sbapt_LT_TAGVAR(link_all_deplibs, $1)=unknown 6634247738Sbapt_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 6635247738Sbapt_LT_TAGVAR(no_undefined_flag, $1)= 6636247738Sbapt_LT_TAGVAR(whole_archive_flag_spec, $1)= 6637247738Sbapt_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no 6638247738Sbapt 6639247738Sbapt# Source file extension for f77 test sources. 6640247738Sbaptac_ext=f 6641247738Sbapt 6642247738Sbapt# Object file extension for compiled f77 test sources. 6643247738Sbaptobjext=o 6644247738Sbapt_LT_TAGVAR(objext, $1)=$objext 6645247738Sbapt 6646247738Sbapt# No sense in running all these tests if we already determined that 6647247738Sbapt# the F77 compiler isn't working. Some variables (like enable_shared) 6648247738Sbapt# are currently assumed to apply to all compilers on this platform, 6649247738Sbapt# and will be corrupted by setting them based on a non-working compiler. 6650247738Sbaptif test "$_lt_disable_F77" != yes; then 6651247738Sbapt # Code to be used in simple compile tests 6652247738Sbapt lt_simple_compile_test_code="\ 6653247738Sbapt subroutine t 6654247738Sbapt return 6655247738Sbapt end 6656247738Sbapt" 6657247738Sbapt 6658247738Sbapt # Code to be used in simple link tests 6659247738Sbapt lt_simple_link_test_code="\ 6660247738Sbapt program t 6661247738Sbapt end 6662247738Sbapt" 6663247738Sbapt 6664247738Sbapt # ltmain only uses $CC for tagged configurations so make sure $CC is set. 6665247738Sbapt _LT_TAG_COMPILER 6666247738Sbapt 6667247738Sbapt # save warnings/boilerplate of simple test code 6668247738Sbapt _LT_COMPILER_BOILERPLATE 6669247738Sbapt _LT_LINKER_BOILERPLATE 6670247738Sbapt 6671247738Sbapt # Allow CC to be a program name with arguments. 6672247738Sbapt lt_save_CC="$CC" 6673247738Sbapt lt_save_GCC=$GCC 6674247738Sbapt CC=${F77-"f77"} 6675247738Sbapt compiler=$CC 6676247738Sbapt _LT_TAGVAR(compiler, $1)=$CC 6677247738Sbapt _LT_CC_BASENAME([$compiler]) 6678247738Sbapt GCC=$G77 6679247738Sbapt if test -n "$compiler"; then 6680247738Sbapt AC_MSG_CHECKING([if libtool supports shared libraries]) 6681247738Sbapt AC_MSG_RESULT([$can_build_shared]) 6682247738Sbapt 6683247738Sbapt AC_MSG_CHECKING([whether to build shared libraries]) 6684247738Sbapt test "$can_build_shared" = "no" && enable_shared=no 6685247738Sbapt 6686247738Sbapt # On AIX, shared libraries and static libraries use the same namespace, and 6687247738Sbapt # are all built from PIC. 6688247738Sbapt case $host_os in 6689247738Sbapt aix3*) 6690247738Sbapt test "$enable_shared" = yes && enable_static=no 6691247738Sbapt if test -n "$RANLIB"; then 6692247738Sbapt archive_cmds="$archive_cmds~\$RANLIB \$lib" 6693247738Sbapt postinstall_cmds='$RANLIB $lib' 6694247738Sbapt fi 6695247738Sbapt ;; 6696247738Sbapt aix[[4-9]]*) 6697247738Sbapt if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then 6698247738Sbapt test "$enable_shared" = yes && enable_static=no 6699247738Sbapt fi 6700247738Sbapt ;; 6701247738Sbapt esac 6702247738Sbapt AC_MSG_RESULT([$enable_shared]) 6703247738Sbapt 6704247738Sbapt AC_MSG_CHECKING([whether to build static libraries]) 6705247738Sbapt # Make sure either enable_shared or enable_static is yes. 6706247738Sbapt test "$enable_shared" = yes || enable_static=yes 6707247738Sbapt AC_MSG_RESULT([$enable_static]) 6708247738Sbapt 6709247738Sbapt _LT_TAGVAR(GCC, $1)="$G77" 6710247738Sbapt _LT_TAGVAR(LD, $1)="$LD" 6711247738Sbapt 6712247738Sbapt ## CAVEAT EMPTOR: 6713247738Sbapt ## There is no encapsulation within the following macros, do not change 6714247738Sbapt ## the running order or otherwise move them around unless you know exactly 6715247738Sbapt ## what you are doing... 6716247738Sbapt _LT_COMPILER_PIC($1) 6717247738Sbapt _LT_COMPILER_C_O($1) 6718247738Sbapt _LT_COMPILER_FILE_LOCKS($1) 6719247738Sbapt _LT_LINKER_SHLIBS($1) 6720247738Sbapt _LT_SYS_DYNAMIC_LINKER($1) 6721247738Sbapt _LT_LINKER_HARDCODE_LIBPATH($1) 6722247738Sbapt 6723247738Sbapt _LT_CONFIG($1) 6724247738Sbapt fi # test -n "$compiler" 6725247738Sbapt 6726247738Sbapt GCC=$lt_save_GCC 6727247738Sbapt CC="$lt_save_CC" 6728247738Sbaptfi # test "$_lt_disable_F77" != yes 6729247738Sbapt 6730247738SbaptAC_LANG_POP 6731247738Sbapt])# _LT_LANG_F77_CONFIG 6732247738Sbapt 6733247738Sbapt 6734247738Sbapt# _LT_PROG_FC 6735247738Sbapt# ----------- 6736247738Sbapt# Since AC_PROG_FC is broken, in that it returns the empty string 6737247738Sbapt# if there is no fortran compiler, we have our own version here. 6738247738Sbaptm4_defun([_LT_PROG_FC], 6739247738Sbapt[ 6740247738Sbaptpushdef([AC_MSG_ERROR], [_lt_disable_FC=yes]) 6741247738SbaptAC_PROG_FC 6742247738Sbaptif test -z "$FC" || test "X$FC" = "Xno"; then 6743247738Sbapt _lt_disable_FC=yes 6744247738Sbaptfi 6745247738Sbaptpopdef([AC_MSG_ERROR]) 6746247738Sbapt])# _LT_PROG_FC 6747247738Sbapt 6748247738Sbaptdnl aclocal-1.4 backwards compatibility: 6749247738Sbaptdnl AC_DEFUN([_LT_PROG_FC], []) 6750247738Sbapt 6751247738Sbapt 6752247738Sbapt# _LT_LANG_FC_CONFIG([TAG]) 6753247738Sbapt# ------------------------- 6754247738Sbapt# Ensure that the configuration variables for a Fortran compiler are 6755247738Sbapt# suitably defined. These variables are subsequently used by _LT_CONFIG 6756247738Sbapt# to write the compiler configuration to `libtool'. 6757247738Sbaptm4_defun([_LT_LANG_FC_CONFIG], 6758247738Sbapt[AC_REQUIRE([_LT_PROG_FC])dnl 6759247738SbaptAC_LANG_PUSH(Fortran) 6760247738Sbapt 6761247738Sbapt_LT_TAGVAR(archive_cmds_need_lc, $1)=no 6762247738Sbapt_LT_TAGVAR(allow_undefined_flag, $1)= 6763247738Sbapt_LT_TAGVAR(always_export_symbols, $1)=no 6764247738Sbapt_LT_TAGVAR(archive_expsym_cmds, $1)= 6765247738Sbapt_LT_TAGVAR(export_dynamic_flag_spec, $1)= 6766247738Sbapt_LT_TAGVAR(hardcode_direct, $1)=no 6767247738Sbapt_LT_TAGVAR(hardcode_direct_absolute, $1)=no 6768247738Sbapt_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 6769247738Sbapt_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= 6770247738Sbapt_LT_TAGVAR(hardcode_libdir_separator, $1)= 6771247738Sbapt_LT_TAGVAR(hardcode_minus_L, $1)=no 6772247738Sbapt_LT_TAGVAR(hardcode_automatic, $1)=no 6773247738Sbapt_LT_TAGVAR(inherit_rpath, $1)=no 6774247738Sbapt_LT_TAGVAR(module_cmds, $1)= 6775247738Sbapt_LT_TAGVAR(module_expsym_cmds, $1)= 6776247738Sbapt_LT_TAGVAR(link_all_deplibs, $1)=unknown 6777247738Sbapt_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 6778247738Sbapt_LT_TAGVAR(no_undefined_flag, $1)= 6779247738Sbapt_LT_TAGVAR(whole_archive_flag_spec, $1)= 6780247738Sbapt_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no 6781247738Sbapt 6782247738Sbapt# Source file extension for fc test sources. 6783247738Sbaptac_ext=${ac_fc_srcext-f} 6784247738Sbapt 6785247738Sbapt# Object file extension for compiled fc test sources. 6786247738Sbaptobjext=o 6787247738Sbapt_LT_TAGVAR(objext, $1)=$objext 6788247738Sbapt 6789247738Sbapt# No sense in running all these tests if we already determined that 6790247738Sbapt# the FC compiler isn't working. Some variables (like enable_shared) 6791247738Sbapt# are currently assumed to apply to all compilers on this platform, 6792247738Sbapt# and will be corrupted by setting them based on a non-working compiler. 6793247738Sbaptif test "$_lt_disable_FC" != yes; then 6794247738Sbapt # Code to be used in simple compile tests 6795247738Sbapt lt_simple_compile_test_code="\ 6796247738Sbapt subroutine t 6797247738Sbapt return 6798247738Sbapt end 6799247738Sbapt" 6800247738Sbapt 6801247738Sbapt # Code to be used in simple link tests 6802247738Sbapt lt_simple_link_test_code="\ 6803247738Sbapt program t 6804247738Sbapt end 6805247738Sbapt" 6806247738Sbapt 6807247738Sbapt # ltmain only uses $CC for tagged configurations so make sure $CC is set. 6808247738Sbapt _LT_TAG_COMPILER 6809247738Sbapt 6810247738Sbapt # save warnings/boilerplate of simple test code 6811247738Sbapt _LT_COMPILER_BOILERPLATE 6812247738Sbapt _LT_LINKER_BOILERPLATE 6813247738Sbapt 6814247738Sbapt # Allow CC to be a program name with arguments. 6815247738Sbapt lt_save_CC="$CC" 6816247738Sbapt lt_save_GCC=$GCC 6817247738Sbapt CC=${FC-"f95"} 6818247738Sbapt compiler=$CC 6819247738Sbapt GCC=$ac_cv_fc_compiler_gnu 6820247738Sbapt 6821247738Sbapt _LT_TAGVAR(compiler, $1)=$CC 6822247738Sbapt _LT_CC_BASENAME([$compiler]) 6823247738Sbapt 6824247738Sbapt if test -n "$compiler"; then 6825247738Sbapt AC_MSG_CHECKING([if libtool supports shared libraries]) 6826247738Sbapt AC_MSG_RESULT([$can_build_shared]) 6827247738Sbapt 6828247738Sbapt AC_MSG_CHECKING([whether to build shared libraries]) 6829247738Sbapt test "$can_build_shared" = "no" && enable_shared=no 6830247738Sbapt 6831247738Sbapt # On AIX, shared libraries and static libraries use the same namespace, and 6832247738Sbapt # are all built from PIC. 6833247738Sbapt case $host_os in 6834247738Sbapt aix3*) 6835247738Sbapt test "$enable_shared" = yes && enable_static=no 6836247738Sbapt if test -n "$RANLIB"; then 6837247738Sbapt archive_cmds="$archive_cmds~\$RANLIB \$lib" 6838247738Sbapt postinstall_cmds='$RANLIB $lib' 6839247738Sbapt fi 6840247738Sbapt ;; 6841247738Sbapt aix[[4-9]]*) 6842247738Sbapt if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then 6843247738Sbapt test "$enable_shared" = yes && enable_static=no 6844247738Sbapt fi 6845247738Sbapt ;; 6846247738Sbapt esac 6847247738Sbapt AC_MSG_RESULT([$enable_shared]) 6848247738Sbapt 6849247738Sbapt AC_MSG_CHECKING([whether to build static libraries]) 6850247738Sbapt # Make sure either enable_shared or enable_static is yes. 6851247738Sbapt test "$enable_shared" = yes || enable_static=yes 6852247738Sbapt AC_MSG_RESULT([$enable_static]) 6853247738Sbapt 6854247738Sbapt _LT_TAGVAR(GCC, $1)="$ac_cv_fc_compiler_gnu" 6855247738Sbapt _LT_TAGVAR(LD, $1)="$LD" 6856247738Sbapt 6857247738Sbapt ## CAVEAT EMPTOR: 6858247738Sbapt ## There is no encapsulation within the following macros, do not change 6859247738Sbapt ## the running order or otherwise move them around unless you know exactly 6860247738Sbapt ## what you are doing... 6861247738Sbapt _LT_SYS_HIDDEN_LIBDEPS($1) 6862247738Sbapt _LT_COMPILER_PIC($1) 6863247738Sbapt _LT_COMPILER_C_O($1) 6864247738Sbapt _LT_COMPILER_FILE_LOCKS($1) 6865247738Sbapt _LT_LINKER_SHLIBS($1) 6866247738Sbapt _LT_SYS_DYNAMIC_LINKER($1) 6867247738Sbapt _LT_LINKER_HARDCODE_LIBPATH($1) 6868247738Sbapt 6869247738Sbapt _LT_CONFIG($1) 6870247738Sbapt fi # test -n "$compiler" 6871247738Sbapt 6872247738Sbapt GCC=$lt_save_GCC 6873247738Sbapt CC="$lt_save_CC" 6874247738Sbaptfi # test "$_lt_disable_FC" != yes 6875247738Sbapt 6876247738SbaptAC_LANG_POP 6877247738Sbapt])# _LT_LANG_FC_CONFIG 6878247738Sbapt 6879247738Sbapt 6880247738Sbapt# _LT_LANG_GCJ_CONFIG([TAG]) 6881247738Sbapt# -------------------------- 6882247738Sbapt# Ensure that the configuration variables for the GNU Java Compiler compiler 6883247738Sbapt# are suitably defined. These variables are subsequently used by _LT_CONFIG 6884247738Sbapt# to write the compiler configuration to `libtool'. 6885247738Sbaptm4_defun([_LT_LANG_GCJ_CONFIG], 6886247738Sbapt[AC_REQUIRE([LT_PROG_GCJ])dnl 6887247738SbaptAC_LANG_SAVE 6888247738Sbapt 6889247738Sbapt# Source file extension for Java test sources. 6890247738Sbaptac_ext=java 6891247738Sbapt 6892247738Sbapt# Object file extension for compiled Java test sources. 6893247738Sbaptobjext=o 6894247738Sbapt_LT_TAGVAR(objext, $1)=$objext 6895247738Sbapt 6896247738Sbapt# Code to be used in simple compile tests 6897247738Sbaptlt_simple_compile_test_code="class foo {}" 6898247738Sbapt 6899247738Sbapt# Code to be used in simple link tests 6900247738Sbaptlt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }' 6901247738Sbapt 6902247738Sbapt# ltmain only uses $CC for tagged configurations so make sure $CC is set. 6903247738Sbapt_LT_TAG_COMPILER 6904247738Sbapt 6905247738Sbapt# save warnings/boilerplate of simple test code 6906247738Sbapt_LT_COMPILER_BOILERPLATE 6907247738Sbapt_LT_LINKER_BOILERPLATE 6908247738Sbapt 6909247738Sbapt# Allow CC to be a program name with arguments. 6910247738Sbaptlt_save_CC="$CC" 6911247738Sbaptlt_save_GCC=$GCC 6912247738SbaptGCC=yes 6913247738SbaptCC=${GCJ-"gcj"} 6914247738Sbaptcompiler=$CC 6915247738Sbapt_LT_TAGVAR(compiler, $1)=$CC 6916247738Sbapt_LT_TAGVAR(LD, $1)="$LD" 6917247738Sbapt_LT_CC_BASENAME([$compiler]) 6918247738Sbapt 6919247738Sbapt# GCJ did not exist at the time GCC didn't implicitly link libc in. 6920247738Sbapt_LT_TAGVAR(archive_cmds_need_lc, $1)=no 6921247738Sbapt 6922247738Sbapt_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 6923247738Sbapt 6924247738Sbaptif test -n "$compiler"; then 6925247738Sbapt _LT_COMPILER_NO_RTTI($1) 6926247738Sbapt _LT_COMPILER_PIC($1) 6927247738Sbapt _LT_COMPILER_C_O($1) 6928247738Sbapt _LT_COMPILER_FILE_LOCKS($1) 6929247738Sbapt _LT_LINKER_SHLIBS($1) 6930247738Sbapt _LT_LINKER_HARDCODE_LIBPATH($1) 6931247738Sbapt 6932247738Sbapt _LT_CONFIG($1) 6933247738Sbaptfi 6934247738Sbapt 6935247738SbaptAC_LANG_RESTORE 6936247738Sbapt 6937247738SbaptGCC=$lt_save_GCC 6938247738SbaptCC="$lt_save_CC" 6939247738Sbapt])# _LT_LANG_GCJ_CONFIG 6940247738Sbapt 6941247738Sbapt 6942247738Sbapt# _LT_LANG_RC_CONFIG([TAG]) 6943247738Sbapt# ------------------------- 6944247738Sbapt# Ensure that the configuration variables for the Windows resource compiler 6945247738Sbapt# are suitably defined. These variables are subsequently used by _LT_CONFIG 6946247738Sbapt# to write the compiler configuration to `libtool'. 6947247738Sbaptm4_defun([_LT_LANG_RC_CONFIG], 6948247738Sbapt[AC_REQUIRE([LT_PROG_RC])dnl 6949247738SbaptAC_LANG_SAVE 6950247738Sbapt 6951247738Sbapt# Source file extension for RC test sources. 6952247738Sbaptac_ext=rc 6953247738Sbapt 6954247738Sbapt# Object file extension for compiled RC test sources. 6955247738Sbaptobjext=o 6956247738Sbapt_LT_TAGVAR(objext, $1)=$objext 6957247738Sbapt 6958247738Sbapt# Code to be used in simple compile tests 6959247738Sbaptlt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }' 6960247738Sbapt 6961247738Sbapt# Code to be used in simple link tests 6962247738Sbaptlt_simple_link_test_code="$lt_simple_compile_test_code" 6963247738Sbapt 6964247738Sbapt# ltmain only uses $CC for tagged configurations so make sure $CC is set. 6965247738Sbapt_LT_TAG_COMPILER 6966247738Sbapt 6967247738Sbapt# save warnings/boilerplate of simple test code 6968247738Sbapt_LT_COMPILER_BOILERPLATE 6969247738Sbapt_LT_LINKER_BOILERPLATE 6970247738Sbapt 6971247738Sbapt# Allow CC to be a program name with arguments. 6972247738Sbaptlt_save_CC="$CC" 6973247738Sbaptlt_save_GCC=$GCC 6974247738SbaptGCC= 6975247738SbaptCC=${RC-"windres"} 6976247738Sbaptcompiler=$CC 6977247738Sbapt_LT_TAGVAR(compiler, $1)=$CC 6978247738Sbapt_LT_CC_BASENAME([$compiler]) 6979247738Sbapt_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes 6980247738Sbapt 6981247738Sbaptif test -n "$compiler"; then 6982247738Sbapt : 6983247738Sbapt _LT_CONFIG($1) 6984247738Sbaptfi 6985247738Sbapt 6986247738SbaptGCC=$lt_save_GCC 6987247738SbaptAC_LANG_RESTORE 6988247738SbaptCC="$lt_save_CC" 6989247738Sbapt])# _LT_LANG_RC_CONFIG 6990247738Sbapt 6991247738Sbapt 6992247738Sbapt# LT_PROG_GCJ 6993247738Sbapt# ----------- 6994247738SbaptAC_DEFUN([LT_PROG_GCJ], 6995247738Sbapt[m4_ifdef([AC_PROG_GCJ], [AC_PROG_GCJ], 6996247738Sbapt [m4_ifdef([A][M_PROG_GCJ], [A][M_PROG_GCJ], 6997247738Sbapt [AC_CHECK_TOOL(GCJ, gcj,) 6998247738Sbapt test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2" 6999247738Sbapt AC_SUBST(GCJFLAGS)])])[]dnl 7000247738Sbapt]) 7001247738Sbapt 7002247738Sbapt# Old name: 7003247738SbaptAU_ALIAS([LT_AC_PROG_GCJ], [LT_PROG_GCJ]) 7004247738Sbaptdnl aclocal-1.4 backwards compatibility: 7005247738Sbaptdnl AC_DEFUN([LT_AC_PROG_GCJ], []) 7006247738Sbapt 7007247738Sbapt 7008247738Sbapt# LT_PROG_RC 7009247738Sbapt# ---------- 7010247738SbaptAC_DEFUN([LT_PROG_RC], 7011247738Sbapt[AC_CHECK_TOOL(RC, windres,) 7012247738Sbapt]) 7013247738Sbapt 7014247738Sbapt# Old name: 7015247738SbaptAU_ALIAS([LT_AC_PROG_RC], [LT_PROG_RC]) 7016247738Sbaptdnl aclocal-1.4 backwards compatibility: 7017247738Sbaptdnl AC_DEFUN([LT_AC_PROG_RC], []) 7018247738Sbapt 7019247738Sbapt 7020247738Sbapt# _LT_DECL_EGREP 7021247738Sbapt# -------------- 7022247738Sbapt# If we don't have a new enough Autoconf to choose the best grep 7023247738Sbapt# available, choose the one first in the user's PATH. 7024247738Sbaptm4_defun([_LT_DECL_EGREP], 7025247738Sbapt[AC_REQUIRE([AC_PROG_EGREP])dnl 7026247738SbaptAC_REQUIRE([AC_PROG_FGREP])dnl 7027247738Sbapttest -z "$GREP" && GREP=grep 7028247738Sbapt_LT_DECL([], [GREP], [1], [A grep program that handles long lines]) 7029247738Sbapt_LT_DECL([], [EGREP], [1], [An ERE matcher]) 7030247738Sbapt_LT_DECL([], [FGREP], [1], [A literal string matcher]) 7031247738Sbaptdnl Non-bleeding-edge autoconf doesn't subst GREP, so do it here too 7032247738SbaptAC_SUBST([GREP]) 7033247738Sbapt]) 7034247738Sbapt 7035247738Sbapt 7036247738Sbapt# _LT_DECL_OBJDUMP 7037247738Sbapt# -------------- 7038247738Sbapt# If we don't have a new enough Autoconf to choose the best objdump 7039247738Sbapt# available, choose the one first in the user's PATH. 7040247738Sbaptm4_defun([_LT_DECL_OBJDUMP], 7041247738Sbapt[AC_CHECK_TOOL(OBJDUMP, objdump, false) 7042247738Sbapttest -z "$OBJDUMP" && OBJDUMP=objdump 7043247738Sbapt_LT_DECL([], [OBJDUMP], [1], [An object symbol dumper]) 7044247738SbaptAC_SUBST([OBJDUMP]) 7045247738Sbapt]) 7046247738Sbapt 7047247738Sbapt 7048247738Sbapt# _LT_DECL_SED 7049247738Sbapt# ------------ 7050247738Sbapt# Check for a fully-functional sed program, that truncates 7051247738Sbapt# as few characters as possible. Prefer GNU sed if found. 7052247738Sbaptm4_defun([_LT_DECL_SED], 7053247738Sbapt[AC_PROG_SED 7054247738Sbapttest -z "$SED" && SED=sed 7055247738SbaptXsed="$SED -e 1s/^X//" 7056247738Sbapt_LT_DECL([], [SED], [1], [A sed program that does not truncate output]) 7057247738Sbapt_LT_DECL([], [Xsed], ["\$SED -e 1s/^X//"], 7058247738Sbapt [Sed that helps us avoid accidentally triggering echo(1) options like -n]) 7059247738Sbapt])# _LT_DECL_SED 7060247738Sbapt 7061247738Sbaptm4_ifndef([AC_PROG_SED], [ 7062247738Sbapt# NOTE: This macro has been submitted for inclusion into # 7063247738Sbapt# GNU Autoconf as AC_PROG_SED. When it is available in # 7064247738Sbapt# a released version of Autoconf we should remove this # 7065247738Sbapt# macro and use it instead. # 7066247738Sbapt 7067247738Sbaptm4_defun([AC_PROG_SED], 7068247738Sbapt[AC_MSG_CHECKING([for a sed that does not truncate output]) 7069247738SbaptAC_CACHE_VAL(lt_cv_path_SED, 7070247738Sbapt[# Loop through the user's path and test for sed and gsed. 7071247738Sbapt# Then use that list of sed's as ones to test for truncation. 7072247738Sbaptas_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7073247738Sbaptfor as_dir in $PATH 7074247738Sbaptdo 7075247738Sbapt IFS=$as_save_IFS 7076247738Sbapt test -z "$as_dir" && as_dir=. 7077247738Sbapt for lt_ac_prog in sed gsed; do 7078247738Sbapt for ac_exec_ext in '' $ac_executable_extensions; do 7079247738Sbapt if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then 7080247738Sbapt lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext" 7081247738Sbapt fi 7082247738Sbapt done 7083247738Sbapt done 7084247738Sbaptdone 7085247738SbaptIFS=$as_save_IFS 7086247738Sbaptlt_ac_max=0 7087247738Sbaptlt_ac_count=0 7088247738Sbapt# Add /usr/xpg4/bin/sed as it is typically found on Solaris 7089247738Sbapt# along with /bin/sed that truncates output. 7090247738Sbaptfor lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do 7091247738Sbapt test ! -f $lt_ac_sed && continue 7092247738Sbapt cat /dev/null > conftest.in 7093247738Sbapt lt_ac_count=0 7094247738Sbapt echo $ECHO_N "0123456789$ECHO_C" >conftest.in 7095247738Sbapt # Check for GNU sed and select it if it is found. 7096247738Sbapt if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then 7097247738Sbapt lt_cv_path_SED=$lt_ac_sed 7098247738Sbapt break 7099247738Sbapt fi 7100247738Sbapt while true; do 7101247738Sbapt cat conftest.in conftest.in >conftest.tmp 7102247738Sbapt mv conftest.tmp conftest.in 7103247738Sbapt cp conftest.in conftest.nl 7104247738Sbapt echo >>conftest.nl 7105247738Sbapt $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break 7106247738Sbapt cmp -s conftest.out conftest.nl || break 7107247738Sbapt # 10000 chars as input seems more than enough 7108247738Sbapt test $lt_ac_count -gt 10 && break 7109247738Sbapt lt_ac_count=`expr $lt_ac_count + 1` 7110247738Sbapt if test $lt_ac_count -gt $lt_ac_max; then 7111247738Sbapt lt_ac_max=$lt_ac_count 7112247738Sbapt lt_cv_path_SED=$lt_ac_sed 7113247738Sbapt fi 7114247738Sbapt done 7115247738Sbaptdone 7116247738Sbapt]) 7117247738SbaptSED=$lt_cv_path_SED 7118247738SbaptAC_SUBST([SED]) 7119247738SbaptAC_MSG_RESULT([$SED]) 7120247738Sbapt])#AC_PROG_SED 7121247738Sbapt])#m4_ifndef 7122247738Sbapt 7123247738Sbapt# Old name: 7124247738SbaptAU_ALIAS([LT_AC_PROG_SED], [AC_PROG_SED]) 7125247738Sbaptdnl aclocal-1.4 backwards compatibility: 7126247738Sbaptdnl AC_DEFUN([LT_AC_PROG_SED], []) 7127247738Sbapt 7128247738Sbapt 7129247738Sbapt# _LT_CHECK_SHELL_FEATURES 7130247738Sbapt# ------------------------ 7131247738Sbapt# Find out whether the shell is Bourne or XSI compatible, 7132247738Sbapt# or has some other useful features. 7133247738Sbaptm4_defun([_LT_CHECK_SHELL_FEATURES], 7134247738Sbapt[AC_MSG_CHECKING([whether the shell understands some XSI constructs]) 7135247738Sbapt# Try some XSI features 7136247738Sbaptxsi_shell=no 7137247738Sbapt( _lt_dummy="a/b/c" 7138247738Sbapt test "${_lt_dummy##*/},${_lt_dummy%/*},"${_lt_dummy%"$_lt_dummy"}, \ 7139247738Sbapt = c,a/b,, \ 7140247738Sbapt && eval 'test $(( 1 + 1 )) -eq 2 \ 7141247738Sbapt && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \ 7142247738Sbapt && xsi_shell=yes 7143247738SbaptAC_MSG_RESULT([$xsi_shell]) 7144247738Sbapt_LT_CONFIG_LIBTOOL_INIT([xsi_shell='$xsi_shell']) 7145247738Sbapt 7146247738SbaptAC_MSG_CHECKING([whether the shell understands "+="]) 7147247738Sbaptlt_shell_append=no 7148247738Sbapt( foo=bar; set foo baz; eval "$[1]+=\$[2]" && test "$foo" = barbaz ) \ 7149247738Sbapt >/dev/null 2>&1 \ 7150247738Sbapt && lt_shell_append=yes 7151247738SbaptAC_MSG_RESULT([$lt_shell_append]) 7152247738Sbapt_LT_CONFIG_LIBTOOL_INIT([lt_shell_append='$lt_shell_append']) 7153247738Sbapt 7154247738Sbaptif ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then 7155247738Sbapt lt_unset=unset 7156247738Sbaptelse 7157247738Sbapt lt_unset=false 7158247738Sbaptfi 7159247738Sbapt_LT_DECL([], [lt_unset], [0], [whether the shell understands "unset"])dnl 7160247738Sbapt 7161247738Sbapt# test EBCDIC or ASCII 7162247738Sbaptcase `echo X|tr X '\101'` in 7163247738Sbapt A) # ASCII based system 7164247738Sbapt # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr 7165247738Sbapt lt_SP2NL='tr \040 \012' 7166247738Sbapt lt_NL2SP='tr \015\012 \040\040' 7167247738Sbapt ;; 7168247738Sbapt *) # EBCDIC based system 7169247738Sbapt lt_SP2NL='tr \100 \n' 7170247738Sbapt lt_NL2SP='tr \r\n \100\100' 7171247738Sbapt ;; 7172247738Sbaptesac 7173247738Sbapt_LT_DECL([SP2NL], [lt_SP2NL], [1], [turn spaces into newlines])dnl 7174247738Sbapt_LT_DECL([NL2SP], [lt_NL2SP], [1], [turn newlines into spaces])dnl 7175247738Sbapt])# _LT_CHECK_SHELL_FEATURES 7176247738Sbapt 7177247738Sbapt 7178247738Sbapt# _LT_PROG_XSI_SHELLFNS 7179247738Sbapt# --------------------- 7180247738Sbapt# Bourne and XSI compatible variants of some useful shell functions. 7181247738Sbaptm4_defun([_LT_PROG_XSI_SHELLFNS], 7182247738Sbapt[case $xsi_shell in 7183247738Sbapt yes) 7184247738Sbapt cat << \_LT_EOF >> "$cfgfile" 7185247738Sbapt 7186247738Sbapt# func_dirname file append nondir_replacement 7187247738Sbapt# Compute the dirname of FILE. If nonempty, add APPEND to the result, 7188247738Sbapt# otherwise set result to NONDIR_REPLACEMENT. 7189247738Sbaptfunc_dirname () 7190247738Sbapt{ 7191247738Sbapt case ${1} in 7192247738Sbapt */*) func_dirname_result="${1%/*}${2}" ;; 7193247738Sbapt * ) func_dirname_result="${3}" ;; 7194247738Sbapt esac 7195247738Sbapt} 7196247738Sbapt 7197247738Sbapt# func_basename file 7198247738Sbaptfunc_basename () 7199247738Sbapt{ 7200247738Sbapt func_basename_result="${1##*/}" 7201247738Sbapt} 7202247738Sbapt 7203247738Sbapt# func_dirname_and_basename file append nondir_replacement 7204247738Sbapt# perform func_basename and func_dirname in a single function 7205247738Sbapt# call: 7206247738Sbapt# dirname: Compute the dirname of FILE. If nonempty, 7207247738Sbapt# add APPEND to the result, otherwise set result 7208247738Sbapt# to NONDIR_REPLACEMENT. 7209247738Sbapt# value returned in "$func_dirname_result" 7210247738Sbapt# basename: Compute filename of FILE. 7211247738Sbapt# value retuned in "$func_basename_result" 7212247738Sbapt# Implementation must be kept synchronized with func_dirname 7213247738Sbapt# and func_basename. For efficiency, we do not delegate to 7214247738Sbapt# those functions but instead duplicate the functionality here. 7215247738Sbaptfunc_dirname_and_basename () 7216247738Sbapt{ 7217247738Sbapt case ${1} in 7218247738Sbapt */*) func_dirname_result="${1%/*}${2}" ;; 7219247738Sbapt * ) func_dirname_result="${3}" ;; 7220247738Sbapt esac 7221247738Sbapt func_basename_result="${1##*/}" 7222247738Sbapt} 7223247738Sbapt 7224247738Sbapt# func_stripname prefix suffix name 7225247738Sbapt# strip PREFIX and SUFFIX off of NAME. 7226247738Sbapt# PREFIX and SUFFIX must not contain globbing or regex special 7227247738Sbapt# characters, hashes, percent signs, but SUFFIX may contain a leading 7228247738Sbapt# dot (in which case that matches only a dot). 7229247738Sbaptfunc_stripname () 7230247738Sbapt{ 7231247738Sbapt # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are 7232247738Sbapt # positional parameters, so assign one to ordinary parameter first. 7233247738Sbapt func_stripname_result=${3} 7234247738Sbapt func_stripname_result=${func_stripname_result#"${1}"} 7235247738Sbapt func_stripname_result=${func_stripname_result%"${2}"} 7236247738Sbapt} 7237247738Sbapt 7238247738Sbapt# func_opt_split 7239247738Sbaptfunc_opt_split () 7240247738Sbapt{ 7241247738Sbapt func_opt_split_opt=${1%%=*} 7242247738Sbapt func_opt_split_arg=${1#*=} 7243247738Sbapt} 7244247738Sbapt 7245247738Sbapt# func_lo2o object 7246247738Sbaptfunc_lo2o () 7247247738Sbapt{ 7248247738Sbapt case ${1} in 7249247738Sbapt *.lo) func_lo2o_result=${1%.lo}.${objext} ;; 7250247738Sbapt *) func_lo2o_result=${1} ;; 7251247738Sbapt esac 7252247738Sbapt} 7253247738Sbapt 7254247738Sbapt# func_xform libobj-or-source 7255247738Sbaptfunc_xform () 7256247738Sbapt{ 7257247738Sbapt func_xform_result=${1%.*}.lo 7258247738Sbapt} 7259247738Sbapt 7260247738Sbapt# func_arith arithmetic-term... 7261247738Sbaptfunc_arith () 7262247738Sbapt{ 7263247738Sbapt func_arith_result=$(( $[*] )) 7264247738Sbapt} 7265247738Sbapt 7266247738Sbapt# func_len string 7267247738Sbapt# STRING may not start with a hyphen. 7268247738Sbaptfunc_len () 7269247738Sbapt{ 7270247738Sbapt func_len_result=${#1} 7271247738Sbapt} 7272247738Sbapt 7273247738Sbapt_LT_EOF 7274247738Sbapt ;; 7275247738Sbapt *) # Bourne compatible functions. 7276247738Sbapt cat << \_LT_EOF >> "$cfgfile" 7277247738Sbapt 7278247738Sbapt# func_dirname file append nondir_replacement 7279247738Sbapt# Compute the dirname of FILE. If nonempty, add APPEND to the result, 7280247738Sbapt# otherwise set result to NONDIR_REPLACEMENT. 7281247738Sbaptfunc_dirname () 7282247738Sbapt{ 7283247738Sbapt # Extract subdirectory from the argument. 7284247738Sbapt func_dirname_result=`$ECHO "X${1}" | $Xsed -e "$dirname"` 7285247738Sbapt if test "X$func_dirname_result" = "X${1}"; then 7286247738Sbapt func_dirname_result="${3}" 7287247738Sbapt else 7288247738Sbapt func_dirname_result="$func_dirname_result${2}" 7289247738Sbapt fi 7290247738Sbapt} 7291247738Sbapt 7292247738Sbapt# func_basename file 7293247738Sbaptfunc_basename () 7294247738Sbapt{ 7295247738Sbapt func_basename_result=`$ECHO "X${1}" | $Xsed -e "$basename"` 7296247738Sbapt} 7297247738Sbapt 7298247738Sbaptdnl func_dirname_and_basename 7299247738Sbaptdnl A portable version of this function is already defined in general.m4sh 7300247738Sbaptdnl so there is no need for it here. 7301247738Sbapt 7302247738Sbapt# func_stripname prefix suffix name 7303247738Sbapt# strip PREFIX and SUFFIX off of NAME. 7304247738Sbapt# PREFIX and SUFFIX must not contain globbing or regex special 7305247738Sbapt# characters, hashes, percent signs, but SUFFIX may contain a leading 7306247738Sbapt# dot (in which case that matches only a dot). 7307247738Sbapt# func_strip_suffix prefix name 7308247738Sbaptfunc_stripname () 7309247738Sbapt{ 7310247738Sbapt case ${2} in 7311247738Sbapt .*) func_stripname_result=`$ECHO "X${3}" \ 7312247738Sbapt | $Xsed -e "s%^${1}%%" -e "s%\\\\${2}\$%%"`;; 7313247738Sbapt *) func_stripname_result=`$ECHO "X${3}" \ 7314247738Sbapt | $Xsed -e "s%^${1}%%" -e "s%${2}\$%%"`;; 7315247738Sbapt esac 7316247738Sbapt} 7317247738Sbapt 7318247738Sbapt# sed scripts: 7319247738Sbaptmy_sed_long_opt='1s/^\(-[[^=]]*\)=.*/\1/;q' 7320247738Sbaptmy_sed_long_arg='1s/^-[[^=]]*=//' 7321247738Sbapt 7322247738Sbapt# func_opt_split 7323247738Sbaptfunc_opt_split () 7324247738Sbapt{ 7325247738Sbapt func_opt_split_opt=`$ECHO "X${1}" | $Xsed -e "$my_sed_long_opt"` 7326247738Sbapt func_opt_split_arg=`$ECHO "X${1}" | $Xsed -e "$my_sed_long_arg"` 7327247738Sbapt} 7328247738Sbapt 7329247738Sbapt# func_lo2o object 7330247738Sbaptfunc_lo2o () 7331247738Sbapt{ 7332247738Sbapt func_lo2o_result=`$ECHO "X${1}" | $Xsed -e "$lo2o"` 7333247738Sbapt} 7334247738Sbapt 7335247738Sbapt# func_xform libobj-or-source 7336247738Sbaptfunc_xform () 7337247738Sbapt{ 7338247738Sbapt func_xform_result=`$ECHO "X${1}" | $Xsed -e 's/\.[[^.]]*$/.lo/'` 7339247738Sbapt} 7340247738Sbapt 7341247738Sbapt# func_arith arithmetic-term... 7342247738Sbaptfunc_arith () 7343247738Sbapt{ 7344247738Sbapt func_arith_result=`expr "$[@]"` 7345247738Sbapt} 7346247738Sbapt 7347247738Sbapt# func_len string 7348247738Sbapt# STRING may not start with a hyphen. 7349247738Sbaptfunc_len () 7350247738Sbapt{ 7351247738Sbapt func_len_result=`expr "$[1]" : ".*" 2>/dev/null || echo $max_cmd_len` 7352247738Sbapt} 7353247738Sbapt 7354247738Sbapt_LT_EOF 7355247738Sbaptesac 7356247738Sbapt 7357247738Sbaptcase $lt_shell_append in 7358247738Sbapt yes) 7359247738Sbapt cat << \_LT_EOF >> "$cfgfile" 7360247738Sbapt 7361247738Sbapt# func_append var value 7362247738Sbapt# Append VALUE to the end of shell variable VAR. 7363247738Sbaptfunc_append () 7364247738Sbapt{ 7365247738Sbapt eval "$[1]+=\$[2]" 7366247738Sbapt} 7367247738Sbapt_LT_EOF 7368247738Sbapt ;; 7369247738Sbapt *) 7370247738Sbapt cat << \_LT_EOF >> "$cfgfile" 7371247738Sbapt 7372247738Sbapt# func_append var value 7373247738Sbapt# Append VALUE to the end of shell variable VAR. 7374247738Sbaptfunc_append () 7375247738Sbapt{ 7376247738Sbapt eval "$[1]=\$$[1]\$[2]" 7377247738Sbapt} 7378247738Sbapt 7379247738Sbapt_LT_EOF 7380247738Sbapt ;; 7381247738Sbapt esac 7382247738Sbapt]) 7383247738Sbapt 7384247738Sbapt# Helper functions for option handling. -*- Autoconf -*- 7385247738Sbapt# 7386247738Sbapt# Copyright (C) 2004, 2005, 2007, 2008 Free Software Foundation, Inc. 7387247738Sbapt# Written by Gary V. Vaughan, 2004 7388247738Sbapt# 7389247738Sbapt# This file is free software; the Free Software Foundation gives 7390247738Sbapt# unlimited permission to copy and/or distribute it, with or without 7391247738Sbapt# modifications, as long as this notice is preserved. 7392247738Sbapt 7393247738Sbapt# serial 6 ltoptions.m4 7394247738Sbapt 7395247738Sbapt# This is to help aclocal find these macros, as it can't see m4_define. 7396247738SbaptAC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])]) 7397247738Sbapt 7398247738Sbapt 7399247738Sbapt# _LT_MANGLE_OPTION(MACRO-NAME, OPTION-NAME) 7400247738Sbapt# ------------------------------------------ 7401247738Sbaptm4_define([_LT_MANGLE_OPTION], 7402247738Sbapt[[_LT_OPTION_]m4_bpatsubst($1__$2, [[^a-zA-Z0-9_]], [_])]) 7403247738Sbapt 7404247738Sbapt 7405247738Sbapt# _LT_SET_OPTION(MACRO-NAME, OPTION-NAME) 7406247738Sbapt# --------------------------------------- 7407247738Sbapt# Set option OPTION-NAME for macro MACRO-NAME, and if there is a 7408247738Sbapt# matching handler defined, dispatch to it. Other OPTION-NAMEs are 7409247738Sbapt# saved as a flag. 7410247738Sbaptm4_define([_LT_SET_OPTION], 7411247738Sbapt[m4_define(_LT_MANGLE_OPTION([$1], [$2]))dnl 7412247738Sbaptm4_ifdef(_LT_MANGLE_DEFUN([$1], [$2]), 7413247738Sbapt _LT_MANGLE_DEFUN([$1], [$2]), 7414247738Sbapt [m4_warning([Unknown $1 option `$2'])])[]dnl 7415247738Sbapt]) 7416247738Sbapt 7417247738Sbapt 7418247738Sbapt# _LT_IF_OPTION(MACRO-NAME, OPTION-NAME, IF-SET, [IF-NOT-SET]) 7419247738Sbapt# ------------------------------------------------------------ 7420247738Sbapt# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. 7421247738Sbaptm4_define([_LT_IF_OPTION], 7422247738Sbapt[m4_ifdef(_LT_MANGLE_OPTION([$1], [$2]), [$3], [$4])]) 7423247738Sbapt 7424247738Sbapt 7425247738Sbapt# _LT_UNLESS_OPTIONS(MACRO-NAME, OPTION-LIST, IF-NOT-SET) 7426247738Sbapt# ------------------------------------------------------- 7427247738Sbapt# Execute IF-NOT-SET unless all options in OPTION-LIST for MACRO-NAME 7428247738Sbapt# are set. 7429247738Sbaptm4_define([_LT_UNLESS_OPTIONS], 7430247738Sbapt[m4_foreach([_LT_Option], m4_split(m4_normalize([$2])), 7431247738Sbapt [m4_ifdef(_LT_MANGLE_OPTION([$1], _LT_Option), 7432247738Sbapt [m4_define([$0_found])])])[]dnl 7433247738Sbaptm4_ifdef([$0_found], [m4_undefine([$0_found])], [$3 7434247738Sbapt])[]dnl 7435247738Sbapt]) 7436247738Sbapt 7437247738Sbapt 7438247738Sbapt# _LT_SET_OPTIONS(MACRO-NAME, OPTION-LIST) 7439247738Sbapt# ---------------------------------------- 7440247738Sbapt# OPTION-LIST is a space-separated list of Libtool options associated 7441247738Sbapt# with MACRO-NAME. If any OPTION has a matching handler declared with 7442247738Sbapt# LT_OPTION_DEFINE, dispatch to that macro; otherwise complain about 7443247738Sbapt# the unknown option and exit. 7444247738Sbaptm4_defun([_LT_SET_OPTIONS], 7445247738Sbapt[# Set options 7446247738Sbaptm4_foreach([_LT_Option], m4_split(m4_normalize([$2])), 7447247738Sbapt [_LT_SET_OPTION([$1], _LT_Option)]) 7448247738Sbapt 7449247738Sbaptm4_if([$1],[LT_INIT],[ 7450247738Sbapt dnl 7451247738Sbapt dnl Simply set some default values (i.e off) if boolean options were not 7452247738Sbapt dnl specified: 7453247738Sbapt _LT_UNLESS_OPTIONS([LT_INIT], [dlopen], [enable_dlopen=no 7454247738Sbapt ]) 7455247738Sbapt _LT_UNLESS_OPTIONS([LT_INIT], [win32-dll], [enable_win32_dll=no 7456247738Sbapt ]) 7457247738Sbapt dnl 7458247738Sbapt dnl If no reference was made to various pairs of opposing options, then 7459247738Sbapt dnl we run the default mode handler for the pair. For example, if neither 7460247738Sbapt dnl `shared' nor `disable-shared' was passed, we enable building of shared 7461247738Sbapt dnl archives by default: 7462247738Sbapt _LT_UNLESS_OPTIONS([LT_INIT], [shared disable-shared], [_LT_ENABLE_SHARED]) 7463247738Sbapt _LT_UNLESS_OPTIONS([LT_INIT], [static disable-static], [_LT_ENABLE_STATIC]) 7464247738Sbapt _LT_UNLESS_OPTIONS([LT_INIT], [pic-only no-pic], [_LT_WITH_PIC]) 7465247738Sbapt _LT_UNLESS_OPTIONS([LT_INIT], [fast-install disable-fast-install], 7466247738Sbapt [_LT_ENABLE_FAST_INSTALL]) 7467247738Sbapt ]) 7468247738Sbapt])# _LT_SET_OPTIONS 7469247738Sbapt 7470247738Sbapt 7471247738Sbapt 7472247738Sbapt# _LT_MANGLE_DEFUN(MACRO-NAME, OPTION-NAME) 7473247738Sbapt# ----------------------------------------- 7474247738Sbaptm4_define([_LT_MANGLE_DEFUN], 7475247738Sbapt[[_LT_OPTION_DEFUN_]m4_bpatsubst(m4_toupper([$1__$2]), [[^A-Z0-9_]], [_])]) 7476247738Sbapt 7477247738Sbapt 7478247738Sbapt# LT_OPTION_DEFINE(MACRO-NAME, OPTION-NAME, CODE) 7479247738Sbapt# ----------------------------------------------- 7480247738Sbaptm4_define([LT_OPTION_DEFINE], 7481247738Sbapt[m4_define(_LT_MANGLE_DEFUN([$1], [$2]), [$3])[]dnl 7482247738Sbapt])# LT_OPTION_DEFINE 7483247738Sbapt 7484247738Sbapt 7485247738Sbapt# dlopen 7486247738Sbapt# ------ 7487247738SbaptLT_OPTION_DEFINE([LT_INIT], [dlopen], [enable_dlopen=yes 7488247738Sbapt]) 7489247738Sbapt 7490247738SbaptAU_DEFUN([AC_LIBTOOL_DLOPEN], 7491247738Sbapt[_LT_SET_OPTION([LT_INIT], [dlopen]) 7492247738SbaptAC_DIAGNOSE([obsolete], 7493247738Sbapt[$0: Remove this warning and the call to _LT_SET_OPTION when you 7494247738Sbaptput the `dlopen' option into LT_INIT's first parameter.]) 7495247738Sbapt]) 7496247738Sbapt 7497247738Sbaptdnl aclocal-1.4 backwards compatibility: 7498247738Sbaptdnl AC_DEFUN([AC_LIBTOOL_DLOPEN], []) 7499247738Sbapt 7500247738Sbapt 7501247738Sbapt# win32-dll 7502247738Sbapt# --------- 7503247738Sbapt# Declare package support for building win32 dll's. 7504247738SbaptLT_OPTION_DEFINE([LT_INIT], [win32-dll], 7505247738Sbapt[enable_win32_dll=yes 7506247738Sbapt 7507247738Sbaptcase $host in 7508247738Sbapt*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-cegcc*) 7509247738Sbapt AC_CHECK_TOOL(AS, as, false) 7510247738Sbapt AC_CHECK_TOOL(DLLTOOL, dlltool, false) 7511247738Sbapt AC_CHECK_TOOL(OBJDUMP, objdump, false) 7512247738Sbapt ;; 7513247738Sbaptesac 7514247738Sbapt 7515247738Sbapttest -z "$AS" && AS=as 7516247738Sbapt_LT_DECL([], [AS], [0], [Assembler program])dnl 7517247738Sbapt 7518247738Sbapttest -z "$DLLTOOL" && DLLTOOL=dlltool 7519247738Sbapt_LT_DECL([], [DLLTOOL], [0], [DLL creation program])dnl 7520247738Sbapt 7521247738Sbapttest -z "$OBJDUMP" && OBJDUMP=objdump 7522247738Sbapt_LT_DECL([], [OBJDUMP], [0], [Object dumper program])dnl 7523247738Sbapt])# win32-dll 7524247738Sbapt 7525247738SbaptAU_DEFUN([AC_LIBTOOL_WIN32_DLL], 7526247738Sbapt[AC_REQUIRE([AC_CANONICAL_HOST])dnl 7527247738Sbapt_LT_SET_OPTION([LT_INIT], [win32-dll]) 7528247738SbaptAC_DIAGNOSE([obsolete], 7529247738Sbapt[$0: Remove this warning and the call to _LT_SET_OPTION when you 7530247738Sbaptput the `win32-dll' option into LT_INIT's first parameter.]) 7531247738Sbapt]) 7532247738Sbapt 7533247738Sbaptdnl aclocal-1.4 backwards compatibility: 7534247738Sbaptdnl AC_DEFUN([AC_LIBTOOL_WIN32_DLL], []) 7535247738Sbapt 7536247738Sbapt 7537247738Sbapt# _LT_ENABLE_SHARED([DEFAULT]) 7538247738Sbapt# ---------------------------- 7539247738Sbapt# implement the --enable-shared flag, and supports the `shared' and 7540247738Sbapt# `disable-shared' LT_INIT options. 7541247738Sbapt# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. 7542247738Sbaptm4_define([_LT_ENABLE_SHARED], 7543247738Sbapt[m4_define([_LT_ENABLE_SHARED_DEFAULT], [m4_if($1, no, no, yes)])dnl 7544247738SbaptAC_ARG_ENABLE([shared], 7545247738Sbapt [AS_HELP_STRING([--enable-shared@<:@=PKGS@:>@], 7546247738Sbapt [build shared libraries @<:@default=]_LT_ENABLE_SHARED_DEFAULT[@:>@])], 7547247738Sbapt [p=${PACKAGE-default} 7548247738Sbapt case $enableval in 7549247738Sbapt yes) enable_shared=yes ;; 7550247738Sbapt no) enable_shared=no ;; 7551247738Sbapt *) 7552247738Sbapt enable_shared=no 7553247738Sbapt # Look at the argument we got. We use all the common list separators. 7554247738Sbapt lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," 7555247738Sbapt for pkg in $enableval; do 7556247738Sbapt IFS="$lt_save_ifs" 7557247738Sbapt if test "X$pkg" = "X$p"; then 7558247738Sbapt enable_shared=yes 7559247738Sbapt fi 7560247738Sbapt done 7561247738Sbapt IFS="$lt_save_ifs" 7562247738Sbapt ;; 7563247738Sbapt esac], 7564247738Sbapt [enable_shared=]_LT_ENABLE_SHARED_DEFAULT) 7565247738Sbapt 7566247738Sbapt _LT_DECL([build_libtool_libs], [enable_shared], [0], 7567247738Sbapt [Whether or not to build shared libraries]) 7568247738Sbapt])# _LT_ENABLE_SHARED 7569247738Sbapt 7570247738SbaptLT_OPTION_DEFINE([LT_INIT], [shared], [_LT_ENABLE_SHARED([yes])]) 7571247738SbaptLT_OPTION_DEFINE([LT_INIT], [disable-shared], [_LT_ENABLE_SHARED([no])]) 7572247738Sbapt 7573247738Sbapt# Old names: 7574247738SbaptAC_DEFUN([AC_ENABLE_SHARED], 7575247738Sbapt[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[shared]) 7576247738Sbapt]) 7577247738Sbapt 7578247738SbaptAC_DEFUN([AC_DISABLE_SHARED], 7579247738Sbapt[_LT_SET_OPTION([LT_INIT], [disable-shared]) 7580247738Sbapt]) 7581247738Sbapt 7582247738SbaptAU_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)]) 7583247738SbaptAU_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)]) 7584247738Sbapt 7585247738Sbaptdnl aclocal-1.4 backwards compatibility: 7586247738Sbaptdnl AC_DEFUN([AM_ENABLE_SHARED], []) 7587247738Sbaptdnl AC_DEFUN([AM_DISABLE_SHARED], []) 7588247738Sbapt 7589247738Sbapt 7590247738Sbapt 7591247738Sbapt# _LT_ENABLE_STATIC([DEFAULT]) 7592247738Sbapt# ---------------------------- 7593247738Sbapt# implement the --enable-static flag, and support the `static' and 7594247738Sbapt# `disable-static' LT_INIT options. 7595247738Sbapt# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. 7596247738Sbaptm4_define([_LT_ENABLE_STATIC], 7597247738Sbapt[m4_define([_LT_ENABLE_STATIC_DEFAULT], [m4_if($1, no, no, yes)])dnl 7598247738SbaptAC_ARG_ENABLE([static], 7599247738Sbapt [AS_HELP_STRING([--enable-static@<:@=PKGS@:>@], 7600247738Sbapt [build static libraries @<:@default=]_LT_ENABLE_STATIC_DEFAULT[@:>@])], 7601247738Sbapt [p=${PACKAGE-default} 7602247738Sbapt case $enableval in 7603247738Sbapt yes) enable_static=yes ;; 7604247738Sbapt no) enable_static=no ;; 7605247738Sbapt *) 7606247738Sbapt enable_static=no 7607247738Sbapt # Look at the argument we got. We use all the common list separators. 7608247738Sbapt lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," 7609247738Sbapt for pkg in $enableval; do 7610247738Sbapt IFS="$lt_save_ifs" 7611247738Sbapt if test "X$pkg" = "X$p"; then 7612247738Sbapt enable_static=yes 7613247738Sbapt fi 7614247738Sbapt done 7615247738Sbapt IFS="$lt_save_ifs" 7616247738Sbapt ;; 7617247738Sbapt esac], 7618247738Sbapt [enable_static=]_LT_ENABLE_STATIC_DEFAULT) 7619247738Sbapt 7620247738Sbapt _LT_DECL([build_old_libs], [enable_static], [0], 7621247738Sbapt [Whether or not to build static libraries]) 7622247738Sbapt])# _LT_ENABLE_STATIC 7623247738Sbapt 7624247738SbaptLT_OPTION_DEFINE([LT_INIT], [static], [_LT_ENABLE_STATIC([yes])]) 7625247738SbaptLT_OPTION_DEFINE([LT_INIT], [disable-static], [_LT_ENABLE_STATIC([no])]) 7626247738Sbapt 7627247738Sbapt# Old names: 7628247738SbaptAC_DEFUN([AC_ENABLE_STATIC], 7629247738Sbapt[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[static]) 7630247738Sbapt]) 7631247738Sbapt 7632247738SbaptAC_DEFUN([AC_DISABLE_STATIC], 7633247738Sbapt[_LT_SET_OPTION([LT_INIT], [disable-static]) 7634247738Sbapt]) 7635247738Sbapt 7636247738SbaptAU_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)]) 7637247738SbaptAU_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)]) 7638247738Sbapt 7639247738Sbaptdnl aclocal-1.4 backwards compatibility: 7640247738Sbaptdnl AC_DEFUN([AM_ENABLE_STATIC], []) 7641247738Sbaptdnl AC_DEFUN([AM_DISABLE_STATIC], []) 7642247738Sbapt 7643247738Sbapt 7644247738Sbapt 7645247738Sbapt# _LT_ENABLE_FAST_INSTALL([DEFAULT]) 7646247738Sbapt# ---------------------------------- 7647247738Sbapt# implement the --enable-fast-install flag, and support the `fast-install' 7648247738Sbapt# and `disable-fast-install' LT_INIT options. 7649247738Sbapt# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. 7650247738Sbaptm4_define([_LT_ENABLE_FAST_INSTALL], 7651247738Sbapt[m4_define([_LT_ENABLE_FAST_INSTALL_DEFAULT], [m4_if($1, no, no, yes)])dnl 7652247738SbaptAC_ARG_ENABLE([fast-install], 7653247738Sbapt [AS_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@], 7654247738Sbapt [optimize for fast installation @<:@default=]_LT_ENABLE_FAST_INSTALL_DEFAULT[@:>@])], 7655247738Sbapt [p=${PACKAGE-default} 7656247738Sbapt case $enableval in 7657247738Sbapt yes) enable_fast_install=yes ;; 7658247738Sbapt no) enable_fast_install=no ;; 7659247738Sbapt *) 7660247738Sbapt enable_fast_install=no 7661247738Sbapt # Look at the argument we got. We use all the common list separators. 7662247738Sbapt lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," 7663247738Sbapt for pkg in $enableval; do 7664247738Sbapt IFS="$lt_save_ifs" 7665247738Sbapt if test "X$pkg" = "X$p"; then 7666247738Sbapt enable_fast_install=yes 7667247738Sbapt fi 7668247738Sbapt done 7669247738Sbapt IFS="$lt_save_ifs" 7670247738Sbapt ;; 7671247738Sbapt esac], 7672247738Sbapt [enable_fast_install=]_LT_ENABLE_FAST_INSTALL_DEFAULT) 7673247738Sbapt 7674247738Sbapt_LT_DECL([fast_install], [enable_fast_install], [0], 7675247738Sbapt [Whether or not to optimize for fast installation])dnl 7676247738Sbapt])# _LT_ENABLE_FAST_INSTALL 7677247738Sbapt 7678247738SbaptLT_OPTION_DEFINE([LT_INIT], [fast-install], [_LT_ENABLE_FAST_INSTALL([yes])]) 7679247738SbaptLT_OPTION_DEFINE([LT_INIT], [disable-fast-install], [_LT_ENABLE_FAST_INSTALL([no])]) 7680247738Sbapt 7681247738Sbapt# Old names: 7682247738SbaptAU_DEFUN([AC_ENABLE_FAST_INSTALL], 7683247738Sbapt[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[fast-install]) 7684247738SbaptAC_DIAGNOSE([obsolete], 7685247738Sbapt[$0: Remove this warning and the call to _LT_SET_OPTION when you put 7686247738Sbaptthe `fast-install' option into LT_INIT's first parameter.]) 7687247738Sbapt]) 7688247738Sbapt 7689247738SbaptAU_DEFUN([AC_DISABLE_FAST_INSTALL], 7690247738Sbapt[_LT_SET_OPTION([LT_INIT], [disable-fast-install]) 7691247738SbaptAC_DIAGNOSE([obsolete], 7692247738Sbapt[$0: Remove this warning and the call to _LT_SET_OPTION when you put 7693247738Sbaptthe `disable-fast-install' option into LT_INIT's first parameter.]) 7694247738Sbapt]) 7695247738Sbapt 7696247738Sbaptdnl aclocal-1.4 backwards compatibility: 7697247738Sbaptdnl AC_DEFUN([AC_ENABLE_FAST_INSTALL], []) 7698247738Sbaptdnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], []) 7699247738Sbapt 7700247738Sbapt 7701247738Sbapt# _LT_WITH_PIC([MODE]) 7702247738Sbapt# -------------------- 7703247738Sbapt# implement the --with-pic flag, and support the `pic-only' and `no-pic' 7704247738Sbapt# LT_INIT options. 7705247738Sbapt# MODE is either `yes' or `no'. If omitted, it defaults to `both'. 7706247738Sbaptm4_define([_LT_WITH_PIC], 7707247738Sbapt[AC_ARG_WITH([pic], 7708247738Sbapt [AS_HELP_STRING([--with-pic], 7709247738Sbapt [try to use only PIC/non-PIC objects @<:@default=use both@:>@])], 7710247738Sbapt [pic_mode="$withval"], 7711247738Sbapt [pic_mode=default]) 7712247738Sbapt 7713247738Sbapttest -z "$pic_mode" && pic_mode=m4_default([$1], [default]) 7714247738Sbapt 7715247738Sbapt_LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl 7716247738Sbapt])# _LT_WITH_PIC 7717247738Sbapt 7718247738SbaptLT_OPTION_DEFINE([LT_INIT], [pic-only], [_LT_WITH_PIC([yes])]) 7719247738SbaptLT_OPTION_DEFINE([LT_INIT], [no-pic], [_LT_WITH_PIC([no])]) 7720247738Sbapt 7721247738Sbapt# Old name: 7722247738SbaptAU_DEFUN([AC_LIBTOOL_PICMODE], 7723247738Sbapt[_LT_SET_OPTION([LT_INIT], [pic-only]) 7724247738SbaptAC_DIAGNOSE([obsolete], 7725247738Sbapt[$0: Remove this warning and the call to _LT_SET_OPTION when you 7726247738Sbaptput the `pic-only' option into LT_INIT's first parameter.]) 7727247738Sbapt]) 7728247738Sbapt 7729247738Sbaptdnl aclocal-1.4 backwards compatibility: 7730247738Sbaptdnl AC_DEFUN([AC_LIBTOOL_PICMODE], []) 7731247738Sbapt 7732247738Sbapt 7733247738Sbaptm4_define([_LTDL_MODE], []) 7734247738SbaptLT_OPTION_DEFINE([LTDL_INIT], [nonrecursive], 7735247738Sbapt [m4_define([_LTDL_MODE], [nonrecursive])]) 7736247738SbaptLT_OPTION_DEFINE([LTDL_INIT], [recursive], 7737247738Sbapt [m4_define([_LTDL_MODE], [recursive])]) 7738247738SbaptLT_OPTION_DEFINE([LTDL_INIT], [subproject], 7739247738Sbapt [m4_define([_LTDL_MODE], [subproject])]) 7740247738Sbapt 7741247738Sbaptm4_define([_LTDL_TYPE], []) 7742247738SbaptLT_OPTION_DEFINE([LTDL_INIT], [installable], 7743247738Sbapt [m4_define([_LTDL_TYPE], [installable])]) 7744247738SbaptLT_OPTION_DEFINE([LTDL_INIT], [convenience], 7745247738Sbapt [m4_define([_LTDL_TYPE], [convenience])]) 7746247738Sbapt 7747247738Sbapt# ltsugar.m4 -- libtool m4 base layer. -*-Autoconf-*- 7748247738Sbapt# 7749247738Sbapt# Copyright (C) 2004, 2005, 2007, 2008 Free Software Foundation, Inc. 7750247738Sbapt# Written by Gary V. Vaughan, 2004 7751247738Sbapt# 7752247738Sbapt# This file is free software; the Free Software Foundation gives 7753247738Sbapt# unlimited permission to copy and/or distribute it, with or without 7754247738Sbapt# modifications, as long as this notice is preserved. 7755247738Sbapt 7756247738Sbapt# serial 6 ltsugar.m4 7757247738Sbapt 7758247738Sbapt# This is to help aclocal find these macros, as it can't see m4_define. 7759247738SbaptAC_DEFUN([LTSUGAR_VERSION], [m4_if([0.1])]) 7760247738Sbapt 7761247738Sbapt 7762247738Sbapt# lt_join(SEP, ARG1, [ARG2...]) 7763247738Sbapt# ----------------------------- 7764247738Sbapt# Produce ARG1SEPARG2...SEPARGn, omitting [] arguments and their 7765247738Sbapt# associated separator. 7766247738Sbapt# Needed until we can rely on m4_join from Autoconf 2.62, since all earlier 7767247738Sbapt# versions in m4sugar had bugs. 7768247738Sbaptm4_define([lt_join], 7769247738Sbapt[m4_if([$#], [1], [], 7770247738Sbapt [$#], [2], [[$2]], 7771247738Sbapt [m4_if([$2], [], [], [[$2]_])$0([$1], m4_shift(m4_shift($@)))])]) 7772247738Sbaptm4_define([_lt_join], 7773247738Sbapt[m4_if([$#$2], [2], [], 7774247738Sbapt [m4_if([$2], [], [], [[$1$2]])$0([$1], m4_shift(m4_shift($@)))])]) 7775247738Sbapt 7776247738Sbapt 7777247738Sbapt# lt_car(LIST) 7778247738Sbapt# lt_cdr(LIST) 7779247738Sbapt# ------------ 7780247738Sbapt# Manipulate m4 lists. 7781247738Sbapt# These macros are necessary as long as will still need to support 7782247738Sbapt# Autoconf-2.59 which quotes differently. 7783247738Sbaptm4_define([lt_car], [[$1]]) 7784247738Sbaptm4_define([lt_cdr], 7785247738Sbapt[m4_if([$#], 0, [m4_fatal([$0: cannot be called without arguments])], 7786247738Sbapt [$#], 1, [], 7787247738Sbapt [m4_dquote(m4_shift($@))])]) 7788247738Sbaptm4_define([lt_unquote], $1) 7789247738Sbapt 7790247738Sbapt 7791247738Sbapt# lt_append(MACRO-NAME, STRING, [SEPARATOR]) 7792247738Sbapt# ------------------------------------------ 7793247738Sbapt# Redefine MACRO-NAME to hold its former content plus `SEPARATOR'`STRING'. 7794247738Sbapt# Note that neither SEPARATOR nor STRING are expanded; they are appended 7795247738Sbapt# to MACRO-NAME as is (leaving the expansion for when MACRO-NAME is invoked). 7796247738Sbapt# No SEPARATOR is output if MACRO-NAME was previously undefined (different 7797247738Sbapt# than defined and empty). 7798247738Sbapt# 7799247738Sbapt# This macro is needed until we can rely on Autoconf 2.62, since earlier 7800247738Sbapt# versions of m4sugar mistakenly expanded SEPARATOR but not STRING. 7801247738Sbaptm4_define([lt_append], 7802247738Sbapt[m4_define([$1], 7803247738Sbapt m4_ifdef([$1], [m4_defn([$1])[$3]])[$2])]) 7804247738Sbapt 7805247738Sbapt 7806247738Sbapt 7807247738Sbapt# lt_combine(SEP, PREFIX-LIST, INFIX, SUFFIX1, [SUFFIX2...]) 7808247738Sbapt# ---------------------------------------------------------- 7809247738Sbapt# Produce a SEP delimited list of all paired combinations of elements of 7810247738Sbapt# PREFIX-LIST with SUFFIX1 through SUFFIXn. Each element of the list 7811247738Sbapt# has the form PREFIXmINFIXSUFFIXn. 7812247738Sbapt# Needed until we can rely on m4_combine added in Autoconf 2.62. 7813247738Sbaptm4_define([lt_combine], 7814247738Sbapt[m4_if(m4_eval([$# > 3]), [1], 7815247738Sbapt [m4_pushdef([_Lt_sep], [m4_define([_Lt_sep], m4_defn([lt_car]))])]]dnl 7816247738Sbapt[[m4_foreach([_Lt_prefix], [$2], 7817247738Sbapt [m4_foreach([_Lt_suffix], 7818247738Sbapt ]m4_dquote(m4_dquote(m4_shift(m4_shift(m4_shift($@)))))[, 7819247738Sbapt [_Lt_sep([$1])[]m4_defn([_Lt_prefix])[$3]m4_defn([_Lt_suffix])])])])]) 7820247738Sbapt 7821247738Sbapt 7822247738Sbapt# lt_if_append_uniq(MACRO-NAME, VARNAME, [SEPARATOR], [UNIQ], [NOT-UNIQ]) 7823247738Sbapt# ----------------------------------------------------------------------- 7824247738Sbapt# Iff MACRO-NAME does not yet contain VARNAME, then append it (delimited 7825247738Sbapt# by SEPARATOR if supplied) and expand UNIQ, else NOT-UNIQ. 7826247738Sbaptm4_define([lt_if_append_uniq], 7827247738Sbapt[m4_ifdef([$1], 7828247738Sbapt [m4_if(m4_index([$3]m4_defn([$1])[$3], [$3$2$3]), [-1], 7829247738Sbapt [lt_append([$1], [$2], [$3])$4], 7830247738Sbapt [$5])], 7831247738Sbapt [lt_append([$1], [$2], [$3])$4])]) 7832247738Sbapt 7833247738Sbapt 7834247738Sbapt# lt_dict_add(DICT, KEY, VALUE) 7835247738Sbapt# ----------------------------- 7836247738Sbaptm4_define([lt_dict_add], 7837247738Sbapt[m4_define([$1($2)], [$3])]) 7838247738Sbapt 7839247738Sbapt 7840247738Sbapt# lt_dict_add_subkey(DICT, KEY, SUBKEY, VALUE) 7841247738Sbapt# -------------------------------------------- 7842247738Sbaptm4_define([lt_dict_add_subkey], 7843247738Sbapt[m4_define([$1($2:$3)], [$4])]) 7844247738Sbapt 7845247738Sbapt 7846247738Sbapt# lt_dict_fetch(DICT, KEY, [SUBKEY]) 7847247738Sbapt# ---------------------------------- 7848247738Sbaptm4_define([lt_dict_fetch], 7849247738Sbapt[m4_ifval([$3], 7850247738Sbapt m4_ifdef([$1($2:$3)], [m4_defn([$1($2:$3)])]), 7851247738Sbapt m4_ifdef([$1($2)], [m4_defn([$1($2)])]))]) 7852247738Sbapt 7853247738Sbapt 7854247738Sbapt# lt_if_dict_fetch(DICT, KEY, [SUBKEY], VALUE, IF-TRUE, [IF-FALSE]) 7855247738Sbapt# ----------------------------------------------------------------- 7856247738Sbaptm4_define([lt_if_dict_fetch], 7857247738Sbapt[m4_if(lt_dict_fetch([$1], [$2], [$3]), [$4], 7858247738Sbapt [$5], 7859247738Sbapt [$6])]) 7860247738Sbapt 7861247738Sbapt 7862247738Sbapt# lt_dict_filter(DICT, [SUBKEY], VALUE, [SEPARATOR], KEY, [...]) 7863247738Sbapt# -------------------------------------------------------------- 7864247738Sbaptm4_define([lt_dict_filter], 7865247738Sbapt[m4_if([$5], [], [], 7866247738Sbapt [lt_join(m4_quote(m4_default([$4], [[, ]])), 7867247738Sbapt lt_unquote(m4_split(m4_normalize(m4_foreach(_Lt_key, lt_car([m4_shiftn(4, $@)]), 7868247738Sbapt [lt_if_dict_fetch([$1], _Lt_key, [$2], [$3], [_Lt_key ])])))))])[]dnl 7869247738Sbapt]) 7870247738Sbapt 7871247738Sbapt# ltversion.m4 -- version numbers -*- Autoconf -*- 7872247738Sbapt# 7873247738Sbapt# Copyright (C) 2004 Free Software Foundation, Inc. 7874247738Sbapt# Written by Scott James Remnant, 2004 7875247738Sbapt# 7876247738Sbapt# This file is free software; the Free Software Foundation gives 7877247738Sbapt# unlimited permission to copy and/or distribute it, with or without 7878247738Sbapt# modifications, as long as this notice is preserved. 7879247738Sbapt 7880247738Sbapt# Generated from ltversion.in. 7881247738Sbapt 7882247738Sbapt# serial 3017 ltversion.m4 7883247738Sbapt# This file is part of GNU Libtool 7884247738Sbapt 7885247738Sbaptm4_define([LT_PACKAGE_VERSION], [2.2.6b]) 7886247738Sbaptm4_define([LT_PACKAGE_REVISION], [1.3017]) 7887247738Sbapt 7888247738SbaptAC_DEFUN([LTVERSION_VERSION], 7889247738Sbapt[macro_version='2.2.6b' 7890247738Sbaptmacro_revision='1.3017' 7891247738Sbapt_LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?]) 7892247738Sbapt_LT_DECL(, macro_revision, 0) 7893247738Sbapt]) 7894247738Sbapt 7895247738Sbapt# lt~obsolete.m4 -- aclocal satisfying obsolete definitions. -*-Autoconf-*- 7896247738Sbapt# 7897247738Sbapt# Copyright (C) 2004, 2005, 2007 Free Software Foundation, Inc. 7898247738Sbapt# Written by Scott James Remnant, 2004. 7899247738Sbapt# 7900247738Sbapt# This file is free software; the Free Software Foundation gives 7901247738Sbapt# unlimited permission to copy and/or distribute it, with or without 7902247738Sbapt# modifications, as long as this notice is preserved. 7903247738Sbapt 7904247738Sbapt# serial 4 lt~obsolete.m4 7905247738Sbapt 7906247738Sbapt# These exist entirely to fool aclocal when bootstrapping libtool. 7907247738Sbapt# 7908247738Sbapt# In the past libtool.m4 has provided macros via AC_DEFUN (or AU_DEFUN) 7909247738Sbapt# which have later been changed to m4_define as they aren't part of the 7910247738Sbapt# exported API, or moved to Autoconf or Automake where they belong. 7911247738Sbapt# 7912247738Sbapt# The trouble is, aclocal is a bit thick. It'll see the old AC_DEFUN 7913247738Sbapt# in /usr/share/aclocal/libtool.m4 and remember it, then when it sees us 7914247738Sbapt# using a macro with the same name in our local m4/libtool.m4 it'll 7915247738Sbapt# pull the old libtool.m4 in (it doesn't see our shiny new m4_define 7916247738Sbapt# and doesn't know about Autoconf macros at all.) 7917247738Sbapt# 7918247738Sbapt# So we provide this file, which has a silly filename so it's always 7919247738Sbapt# included after everything else. This provides aclocal with the 7920247738Sbapt# AC_DEFUNs it wants, but when m4 processes it, it doesn't do anything 7921247738Sbapt# because those macros already exist, or will be overwritten later. 7922247738Sbapt# We use AC_DEFUN over AU_DEFUN for compatibility with aclocal-1.6. 7923247738Sbapt# 7924247738Sbapt# Anytime we withdraw an AC_DEFUN or AU_DEFUN, remember to add it here. 7925247738Sbapt# Yes, that means every name once taken will need to remain here until 7926247738Sbapt# we give up compatibility with versions before 1.7, at which point 7927247738Sbapt# we need to keep only those names which we still refer to. 7928247738Sbapt 7929247738Sbapt# This is to help aclocal find these macros, as it can't see m4_define. 7930247738SbaptAC_DEFUN([LTOBSOLETE_VERSION], [m4_if([1])]) 7931247738Sbapt 7932247738Sbaptm4_ifndef([AC_LIBTOOL_LINKER_OPTION], [AC_DEFUN([AC_LIBTOOL_LINKER_OPTION])]) 7933247738Sbaptm4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP])]) 7934247738Sbaptm4_ifndef([_LT_AC_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH])]) 7935247738Sbaptm4_ifndef([_LT_AC_SHELL_INIT], [AC_DEFUN([_LT_AC_SHELL_INIT])]) 7936247738Sbaptm4_ifndef([_LT_AC_SYS_LIBPATH_AIX], [AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX])]) 7937247738Sbaptm4_ifndef([_LT_PROG_LTMAIN], [AC_DEFUN([_LT_PROG_LTMAIN])]) 7938247738Sbaptm4_ifndef([_LT_AC_TAGVAR], [AC_DEFUN([_LT_AC_TAGVAR])]) 7939247738Sbaptm4_ifndef([AC_LTDL_ENABLE_INSTALL], [AC_DEFUN([AC_LTDL_ENABLE_INSTALL])]) 7940247738Sbaptm4_ifndef([AC_LTDL_PREOPEN], [AC_DEFUN([AC_LTDL_PREOPEN])]) 7941247738Sbaptm4_ifndef([_LT_AC_SYS_COMPILER], [AC_DEFUN([_LT_AC_SYS_COMPILER])]) 7942247738Sbaptm4_ifndef([_LT_AC_LOCK], [AC_DEFUN([_LT_AC_LOCK])]) 7943247738Sbaptm4_ifndef([AC_LIBTOOL_SYS_OLD_ARCHIVE], [AC_DEFUN([AC_LIBTOOL_SYS_OLD_ARCHIVE])]) 7944247738Sbaptm4_ifndef([_LT_AC_TRY_DLOPEN_SELF], [AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF])]) 7945247738Sbaptm4_ifndef([AC_LIBTOOL_PROG_CC_C_O], [AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O])]) 7946247738Sbaptm4_ifndef([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], [AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS])]) 7947247738Sbaptm4_ifndef([AC_LIBTOOL_OBJDIR], [AC_DEFUN([AC_LIBTOOL_OBJDIR])]) 7948247738Sbaptm4_ifndef([AC_LTDL_OBJDIR], [AC_DEFUN([AC_LTDL_OBJDIR])]) 7949247738Sbaptm4_ifndef([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], [AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH])]) 7950247738Sbaptm4_ifndef([AC_LIBTOOL_SYS_LIB_STRIP], [AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP])]) 7951247738Sbaptm4_ifndef([AC_PATH_MAGIC], [AC_DEFUN([AC_PATH_MAGIC])]) 7952247738Sbaptm4_ifndef([AC_PROG_LD_GNU], [AC_DEFUN([AC_PROG_LD_GNU])]) 7953247738Sbaptm4_ifndef([AC_PROG_LD_RELOAD_FLAG], [AC_DEFUN([AC_PROG_LD_RELOAD_FLAG])]) 7954247738Sbaptm4_ifndef([AC_DEPLIBS_CHECK_METHOD], [AC_DEFUN([AC_DEPLIBS_CHECK_METHOD])]) 7955247738Sbaptm4_ifndef([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI])]) 7956247738Sbaptm4_ifndef([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], [AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE])]) 7957247738Sbaptm4_ifndef([AC_LIBTOOL_PROG_COMPILER_PIC], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC])]) 7958247738Sbaptm4_ifndef([AC_LIBTOOL_PROG_LD_SHLIBS], [AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS])]) 7959247738Sbaptm4_ifndef([AC_LIBTOOL_POSTDEP_PREDEP], [AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP])]) 7960247738Sbaptm4_ifndef([LT_AC_PROG_EGREP], [AC_DEFUN([LT_AC_PROG_EGREP])]) 7961247738Sbaptm4_ifndef([LT_AC_PROG_SED], [AC_DEFUN([LT_AC_PROG_SED])]) 7962247738Sbaptm4_ifndef([_LT_CC_BASENAME], [AC_DEFUN([_LT_CC_BASENAME])]) 7963247738Sbaptm4_ifndef([_LT_COMPILER_BOILERPLATE], [AC_DEFUN([_LT_COMPILER_BOILERPLATE])]) 7964247738Sbaptm4_ifndef([_LT_LINKER_BOILERPLATE], [AC_DEFUN([_LT_LINKER_BOILERPLATE])]) 7965247738Sbaptm4_ifndef([_AC_PROG_LIBTOOL], [AC_DEFUN([_AC_PROG_LIBTOOL])]) 7966247738Sbaptm4_ifndef([AC_LIBTOOL_SETUP], [AC_DEFUN([AC_LIBTOOL_SETUP])]) 7967247738Sbaptm4_ifndef([_LT_AC_CHECK_DLFCN], [AC_DEFUN([_LT_AC_CHECK_DLFCN])]) 7968247738Sbaptm4_ifndef([AC_LIBTOOL_SYS_DYNAMIC_LINKER], [AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER])]) 7969247738Sbaptm4_ifndef([_LT_AC_TAGCONFIG], [AC_DEFUN([_LT_AC_TAGCONFIG])]) 7970247738Sbaptm4_ifndef([AC_DISABLE_FAST_INSTALL], [AC_DEFUN([AC_DISABLE_FAST_INSTALL])]) 7971247738Sbaptm4_ifndef([_LT_AC_LANG_CXX], [AC_DEFUN([_LT_AC_LANG_CXX])]) 7972247738Sbaptm4_ifndef([_LT_AC_LANG_F77], [AC_DEFUN([_LT_AC_LANG_F77])]) 7973247738Sbaptm4_ifndef([_LT_AC_LANG_GCJ], [AC_DEFUN([_LT_AC_LANG_GCJ])]) 7974247738Sbaptm4_ifndef([AC_LIBTOOL_RC], [AC_DEFUN([AC_LIBTOOL_RC])]) 7975247738Sbaptm4_ifndef([AC_LIBTOOL_LANG_C_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG])]) 7976247738Sbaptm4_ifndef([_LT_AC_LANG_C_CONFIG], [AC_DEFUN([_LT_AC_LANG_C_CONFIG])]) 7977247738Sbaptm4_ifndef([AC_LIBTOOL_LANG_CXX_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG])]) 7978247738Sbaptm4_ifndef([_LT_AC_LANG_CXX_CONFIG], [AC_DEFUN([_LT_AC_LANG_CXX_CONFIG])]) 7979247738Sbaptm4_ifndef([AC_LIBTOOL_LANG_F77_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG])]) 7980247738Sbaptm4_ifndef([_LT_AC_LANG_F77_CONFIG], [AC_DEFUN([_LT_AC_LANG_F77_CONFIG])]) 7981247738Sbaptm4_ifndef([AC_LIBTOOL_LANG_GCJ_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG])]) 7982247738Sbaptm4_ifndef([_LT_AC_LANG_GCJ_CONFIG], [AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG])]) 7983247738Sbaptm4_ifndef([AC_LIBTOOL_LANG_RC_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG])]) 7984247738Sbaptm4_ifndef([_LT_AC_LANG_RC_CONFIG], [AC_DEFUN([_LT_AC_LANG_RC_CONFIG])]) 7985247738Sbaptm4_ifndef([AC_LIBTOOL_CONFIG], [AC_DEFUN([AC_LIBTOOL_CONFIG])]) 7986247738Sbaptm4_ifndef([_LT_AC_FILE_LTDLL_C], [AC_DEFUN([_LT_AC_FILE_LTDLL_C])]) 7987247738Sbapt 7988247738Sbapt# Copyright (C) 2002, 2003, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. 7989247738Sbapt# 7990247738Sbapt# This file is free software; the Free Software Foundation 7991247738Sbapt# gives unlimited permission to copy and/or distribute it, 7992247738Sbapt# with or without modifications, as long as this notice is preserved. 7993247738Sbapt 7994247738Sbapt# AM_AUTOMAKE_VERSION(VERSION) 7995247738Sbapt# ---------------------------- 7996247738Sbapt# Automake X.Y traces this macro to ensure aclocal.m4 has been 7997247738Sbapt# generated from the m4 files accompanying Automake X.Y. 7998247738Sbapt# (This private macro should not be called outside this file.) 7999247738SbaptAC_DEFUN([AM_AUTOMAKE_VERSION], 8000247738Sbapt[am__api_version='1.11' 8001247738Sbaptdnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to 8002247738Sbaptdnl require some minimum version. Point them to the right macro. 8003247738Sbaptm4_if([$1], [1.11.1], [], 8004247738Sbapt [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl 8005247738Sbapt]) 8006247738Sbapt 8007247738Sbapt# _AM_AUTOCONF_VERSION(VERSION) 8008247738Sbapt# ----------------------------- 8009247738Sbapt# aclocal traces this macro to find the Autoconf version. 8010247738Sbapt# This is a private macro too. Using m4_define simplifies 8011247738Sbapt# the logic in aclocal, which can simply ignore this definition. 8012247738Sbaptm4_define([_AM_AUTOCONF_VERSION], []) 8013247738Sbapt 8014247738Sbapt# AM_SET_CURRENT_AUTOMAKE_VERSION 8015247738Sbapt# ------------------------------- 8016247738Sbapt# Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced. 8017247738Sbapt# This function is AC_REQUIREd by AM_INIT_AUTOMAKE. 8018247738SbaptAC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION], 8019247738Sbapt[AM_AUTOMAKE_VERSION([1.11.1])dnl 8020247738Sbaptm4_ifndef([AC_AUTOCONF_VERSION], 8021247738Sbapt [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl 8022247738Sbapt_AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))]) 8023247738Sbapt 8024247738Sbapt# AM_AUX_DIR_EXPAND -*- Autoconf -*- 8025247738Sbapt 8026247738Sbapt# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. 8027247738Sbapt# 8028247738Sbapt# This file is free software; the Free Software Foundation 8029247738Sbapt# gives unlimited permission to copy and/or distribute it, 8030247738Sbapt# with or without modifications, as long as this notice is preserved. 8031247738Sbapt 8032247738Sbapt# For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets 8033247738Sbapt# $ac_aux_dir to `$srcdir/foo'. In other projects, it is set to 8034247738Sbapt# `$srcdir', `$srcdir/..', or `$srcdir/../..'. 8035247738Sbapt# 8036247738Sbapt# Of course, Automake must honor this variable whenever it calls a 8037247738Sbapt# tool from the auxiliary directory. The problem is that $srcdir (and 8038247738Sbapt# therefore $ac_aux_dir as well) can be either absolute or relative, 8039247738Sbapt# depending on how configure is run. This is pretty annoying, since 8040247738Sbapt# it makes $ac_aux_dir quite unusable in subdirectories: in the top 8041247738Sbapt# source directory, any form will work fine, but in subdirectories a 8042247738Sbapt# relative path needs to be adjusted first. 8043247738Sbapt# 8044247738Sbapt# $ac_aux_dir/missing 8045247738Sbapt# fails when called from a subdirectory if $ac_aux_dir is relative 8046247738Sbapt# $top_srcdir/$ac_aux_dir/missing 8047247738Sbapt# fails if $ac_aux_dir is absolute, 8048247738Sbapt# fails when called from a subdirectory in a VPATH build with 8049247738Sbapt# a relative $ac_aux_dir 8050247738Sbapt# 8051247738Sbapt# The reason of the latter failure is that $top_srcdir and $ac_aux_dir 8052247738Sbapt# are both prefixed by $srcdir. In an in-source build this is usually 8053247738Sbapt# harmless because $srcdir is `.', but things will broke when you 8054247738Sbapt# start a VPATH build or use an absolute $srcdir. 8055247738Sbapt# 8056247738Sbapt# So we could use something similar to $top_srcdir/$ac_aux_dir/missing, 8057247738Sbapt# iff we strip the leading $srcdir from $ac_aux_dir. That would be: 8058247738Sbapt# am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"` 8059247738Sbapt# and then we would define $MISSING as 8060247738Sbapt# MISSING="\${SHELL} $am_aux_dir/missing" 8061247738Sbapt# This will work as long as MISSING is not called from configure, because 8062247738Sbapt# unfortunately $(top_srcdir) has no meaning in configure. 8063247738Sbapt# However there are other variables, like CC, which are often used in 8064247738Sbapt# configure, and could therefore not use this "fixed" $ac_aux_dir. 8065247738Sbapt# 8066247738Sbapt# Another solution, used here, is to always expand $ac_aux_dir to an 8067247738Sbapt# absolute PATH. The drawback is that using absolute paths prevent a 8068247738Sbapt# configured tree to be moved without reconfiguration. 8069247738Sbapt 8070247738SbaptAC_DEFUN([AM_AUX_DIR_EXPAND], 8071247738Sbapt[dnl Rely on autoconf to set up CDPATH properly. 8072247738SbaptAC_PREREQ([2.50])dnl 8073247738Sbapt# expand $ac_aux_dir to an absolute path 8074247738Sbaptam_aux_dir=`cd $ac_aux_dir && pwd` 8075247738Sbapt]) 8076247738Sbapt 8077247738Sbapt# AM_CONDITIONAL -*- Autoconf -*- 8078247738Sbapt 8079247738Sbapt# Copyright (C) 1997, 2000, 2001, 2003, 2004, 2005, 2006, 2008 8080247738Sbapt# Free Software Foundation, Inc. 8081247738Sbapt# 8082247738Sbapt# This file is free software; the Free Software Foundation 8083247738Sbapt# gives unlimited permission to copy and/or distribute it, 8084247738Sbapt# with or without modifications, as long as this notice is preserved. 8085247738Sbapt 8086247738Sbapt# serial 9 8087247738Sbapt 8088247738Sbapt# AM_CONDITIONAL(NAME, SHELL-CONDITION) 8089247738Sbapt# ------------------------------------- 8090247738Sbapt# Define a conditional. 8091247738SbaptAC_DEFUN([AM_CONDITIONAL], 8092247738Sbapt[AC_PREREQ(2.52)dnl 8093247738Sbapt ifelse([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])], 8094247738Sbapt [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl 8095247738SbaptAC_SUBST([$1_TRUE])dnl 8096247738SbaptAC_SUBST([$1_FALSE])dnl 8097247738Sbapt_AM_SUBST_NOTMAKE([$1_TRUE])dnl 8098247738Sbapt_AM_SUBST_NOTMAKE([$1_FALSE])dnl 8099247738Sbaptm4_define([_AM_COND_VALUE_$1], [$2])dnl 8100247738Sbaptif $2; then 8101247738Sbapt $1_TRUE= 8102247738Sbapt $1_FALSE='#' 8103247738Sbaptelse 8104247738Sbapt $1_TRUE='#' 8105247738Sbapt $1_FALSE= 8106247738Sbaptfi 8107247738SbaptAC_CONFIG_COMMANDS_PRE( 8108247738Sbapt[if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then 8109247738Sbapt AC_MSG_ERROR([[conditional "$1" was never defined. 8110247738SbaptUsually this means the macro was only invoked conditionally.]]) 8111247738Sbaptfi])]) 8112247738Sbapt 8113247738Sbapt# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2009 8114247738Sbapt# Free Software Foundation, Inc. 8115247738Sbapt# 8116247738Sbapt# This file is free software; the Free Software Foundation 8117247738Sbapt# gives unlimited permission to copy and/or distribute it, 8118247738Sbapt# with or without modifications, as long as this notice is preserved. 8119247738Sbapt 8120247738Sbapt# serial 10 8121247738Sbapt 8122247738Sbapt# There are a few dirty hacks below to avoid letting `AC_PROG_CC' be 8123247738Sbapt# written in clear, in which case automake, when reading aclocal.m4, 8124247738Sbapt# will think it sees a *use*, and therefore will trigger all it's 8125247738Sbapt# C support machinery. Also note that it means that autoscan, seeing 8126247738Sbapt# CC etc. in the Makefile, will ask for an AC_PROG_CC use... 8127247738Sbapt 8128247738Sbapt 8129247738Sbapt# _AM_DEPENDENCIES(NAME) 8130247738Sbapt# ---------------------- 8131247738Sbapt# See how the compiler implements dependency checking. 8132247738Sbapt# NAME is "CC", "CXX", "GCJ", or "OBJC". 8133247738Sbapt# We try a few techniques and use that to set a single cache variable. 8134247738Sbapt# 8135247738Sbapt# We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was 8136247738Sbapt# modified to invoke _AM_DEPENDENCIES(CC); we would have a circular 8137247738Sbapt# dependency, and given that the user is not expected to run this macro, 8138247738Sbapt# just rely on AC_PROG_CC. 8139247738SbaptAC_DEFUN([_AM_DEPENDENCIES], 8140247738Sbapt[AC_REQUIRE([AM_SET_DEPDIR])dnl 8141247738SbaptAC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl 8142247738SbaptAC_REQUIRE([AM_MAKE_INCLUDE])dnl 8143247738SbaptAC_REQUIRE([AM_DEP_TRACK])dnl 8144247738Sbapt 8145247738Sbaptifelse([$1], CC, [depcc="$CC" am_compiler_list=], 8146247738Sbapt [$1], CXX, [depcc="$CXX" am_compiler_list=], 8147247738Sbapt [$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc'], 8148247738Sbapt [$1], UPC, [depcc="$UPC" am_compiler_list=], 8149247738Sbapt [$1], GCJ, [depcc="$GCJ" am_compiler_list='gcc3 gcc'], 8150247738Sbapt [depcc="$$1" am_compiler_list=]) 8151247738Sbapt 8152247738SbaptAC_CACHE_CHECK([dependency style of $depcc], 8153247738Sbapt [am_cv_$1_dependencies_compiler_type], 8154247738Sbapt[if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then 8155247738Sbapt # We make a subdir and do the tests there. Otherwise we can end up 8156247738Sbapt # making bogus files that we don't know about and never remove. For 8157247738Sbapt # instance it was reported that on HP-UX the gcc test will end up 8158247738Sbapt # making a dummy file named `D' -- because `-MD' means `put the output 8159247738Sbapt # in D'. 8160247738Sbapt mkdir conftest.dir 8161247738Sbapt # Copy depcomp to subdir because otherwise we won't find it if we're 8162247738Sbapt # using a relative directory. 8163247738Sbapt cp "$am_depcomp" conftest.dir 8164247738Sbapt cd conftest.dir 8165247738Sbapt # We will build objects and dependencies in a subdirectory because 8166247738Sbapt # it helps to detect inapplicable dependency modes. For instance 8167247738Sbapt # both Tru64's cc and ICC support -MD to output dependencies as a 8168247738Sbapt # side effect of compilation, but ICC will put the dependencies in 8169247738Sbapt # the current directory while Tru64 will put them in the object 8170247738Sbapt # directory. 8171247738Sbapt mkdir sub 8172247738Sbapt 8173247738Sbapt am_cv_$1_dependencies_compiler_type=none 8174247738Sbapt if test "$am_compiler_list" = ""; then 8175247738Sbapt am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp` 8176247738Sbapt fi 8177247738Sbapt am__universal=false 8178247738Sbapt m4_case([$1], [CC], 8179247738Sbapt [case " $depcc " in #( 8180247738Sbapt *\ -arch\ *\ -arch\ *) am__universal=true ;; 8181247738Sbapt esac], 8182247738Sbapt [CXX], 8183247738Sbapt [case " $depcc " in #( 8184247738Sbapt *\ -arch\ *\ -arch\ *) am__universal=true ;; 8185247738Sbapt esac]) 8186247738Sbapt 8187247738Sbapt for depmode in $am_compiler_list; do 8188247738Sbapt # Setup a source with many dependencies, because some compilers 8189247738Sbapt # like to wrap large dependency lists on column 80 (with \), and 8190247738Sbapt # we should not choose a depcomp mode which is confused by this. 8191247738Sbapt # 8192247738Sbapt # We need to recreate these files for each test, as the compiler may 8193247738Sbapt # overwrite some of them when testing with obscure command lines. 8194247738Sbapt # This happens at least with the AIX C compiler. 8195247738Sbapt : > sub/conftest.c 8196247738Sbapt for i in 1 2 3 4 5 6; do 8197247738Sbapt echo '#include "conftst'$i'.h"' >> sub/conftest.c 8198247738Sbapt # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with 8199247738Sbapt # Solaris 8's {/usr,}/bin/sh. 8200247738Sbapt touch sub/conftst$i.h 8201247738Sbapt done 8202247738Sbapt echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf 8203247738Sbapt 8204247738Sbapt # We check with `-c' and `-o' for the sake of the "dashmstdout" 8205247738Sbapt # mode. It turns out that the SunPro C++ compiler does not properly 8206247738Sbapt # handle `-M -o', and we need to detect this. Also, some Intel 8207247738Sbapt # versions had trouble with output in subdirs 8208247738Sbapt am__obj=sub/conftest.${OBJEXT-o} 8209247738Sbapt am__minus_obj="-o $am__obj" 8210247738Sbapt case $depmode in 8211247738Sbapt gcc) 8212247738Sbapt # This depmode causes a compiler race in universal mode. 8213247738Sbapt test "$am__universal" = false || continue 8214247738Sbapt ;; 8215247738Sbapt nosideeffect) 8216247738Sbapt # after this tag, mechanisms are not by side-effect, so they'll 8217247738Sbapt # only be used when explicitly requested 8218247738Sbapt if test "x$enable_dependency_tracking" = xyes; then 8219247738Sbapt continue 8220247738Sbapt else 8221247738Sbapt break 8222247738Sbapt fi 8223247738Sbapt ;; 8224247738Sbapt msvisualcpp | msvcmsys) 8225247738Sbapt # This compiler won't grok `-c -o', but also, the minuso test has 8226247738Sbapt # not run yet. These depmodes are late enough in the game, and 8227247738Sbapt # so weak that their functioning should not be impacted. 8228247738Sbapt am__obj=conftest.${OBJEXT-o} 8229247738Sbapt am__minus_obj= 8230247738Sbapt ;; 8231247738Sbapt none) break ;; 8232247738Sbapt esac 8233247738Sbapt if depmode=$depmode \ 8234247738Sbapt source=sub/conftest.c object=$am__obj \ 8235247738Sbapt depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ 8236247738Sbapt $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ 8237247738Sbapt >/dev/null 2>conftest.err && 8238247738Sbapt grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && 8239247738Sbapt grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && 8240247738Sbapt grep $am__obj sub/conftest.Po > /dev/null 2>&1 && 8241247738Sbapt ${MAKE-make} -s -f confmf > /dev/null 2>&1; then 8242247738Sbapt # icc doesn't choke on unknown options, it will just issue warnings 8243247738Sbapt # or remarks (even with -Werror). So we grep stderr for any message 8244247738Sbapt # that says an option was ignored or not supported. 8245247738Sbapt # When given -MP, icc 7.0 and 7.1 complain thusly: 8246247738Sbapt # icc: Command line warning: ignoring option '-M'; no argument required 8247247738Sbapt # The diagnosis changed in icc 8.0: 8248247738Sbapt # icc: Command line remark: option '-MP' not supported 8249247738Sbapt if (grep 'ignoring option' conftest.err || 8250247738Sbapt grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else 8251247738Sbapt am_cv_$1_dependencies_compiler_type=$depmode 8252247738Sbapt break 8253247738Sbapt fi 8254247738Sbapt fi 8255247738Sbapt done 8256247738Sbapt 8257247738Sbapt cd .. 8258247738Sbapt rm -rf conftest.dir 8259247738Sbaptelse 8260247738Sbapt am_cv_$1_dependencies_compiler_type=none 8261247738Sbaptfi 8262247738Sbapt]) 8263247738SbaptAC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type]) 8264247738SbaptAM_CONDITIONAL([am__fastdep$1], [ 8265247738Sbapt test "x$enable_dependency_tracking" != xno \ 8266247738Sbapt && test "$am_cv_$1_dependencies_compiler_type" = gcc3]) 8267247738Sbapt]) 8268247738Sbapt 8269247738Sbapt 8270247738Sbapt# AM_SET_DEPDIR 8271247738Sbapt# ------------- 8272247738Sbapt# Choose a directory name for dependency files. 8273247738Sbapt# This macro is AC_REQUIREd in _AM_DEPENDENCIES 8274247738SbaptAC_DEFUN([AM_SET_DEPDIR], 8275247738Sbapt[AC_REQUIRE([AM_SET_LEADING_DOT])dnl 8276247738SbaptAC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl 8277247738Sbapt]) 8278247738Sbapt 8279247738Sbapt 8280247738Sbapt# AM_DEP_TRACK 8281247738Sbapt# ------------ 8282247738SbaptAC_DEFUN([AM_DEP_TRACK], 8283247738Sbapt[AC_ARG_ENABLE(dependency-tracking, 8284247738Sbapt[ --disable-dependency-tracking speeds up one-time build 8285247738Sbapt --enable-dependency-tracking do not reject slow dependency extractors]) 8286247738Sbaptif test "x$enable_dependency_tracking" != xno; then 8287247738Sbapt am_depcomp="$ac_aux_dir/depcomp" 8288247738Sbapt AMDEPBACKSLASH='\' 8289247738Sbaptfi 8290247738SbaptAM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno]) 8291247738SbaptAC_SUBST([AMDEPBACKSLASH])dnl 8292247738Sbapt_AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl 8293247738Sbapt]) 8294247738Sbapt 8295247738Sbapt# Generate code to set up dependency tracking. -*- Autoconf -*- 8296247738Sbapt 8297247738Sbapt# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2008 8298247738Sbapt# Free Software Foundation, Inc. 8299247738Sbapt# 8300247738Sbapt# This file is free software; the Free Software Foundation 8301247738Sbapt# gives unlimited permission to copy and/or distribute it, 8302247738Sbapt# with or without modifications, as long as this notice is preserved. 8303247738Sbapt 8304247738Sbapt#serial 5 8305247738Sbapt 8306247738Sbapt# _AM_OUTPUT_DEPENDENCY_COMMANDS 8307247738Sbapt# ------------------------------ 8308247738SbaptAC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], 8309247738Sbapt[{ 8310247738Sbapt # Autoconf 2.62 quotes --file arguments for eval, but not when files 8311247738Sbapt # are listed without --file. Let's play safe and only enable the eval 8312247738Sbapt # if we detect the quoting. 8313247738Sbapt case $CONFIG_FILES in 8314247738Sbapt *\'*) eval set x "$CONFIG_FILES" ;; 8315247738Sbapt *) set x $CONFIG_FILES ;; 8316247738Sbapt esac 8317247738Sbapt shift 8318247738Sbapt for mf 8319247738Sbapt do 8320247738Sbapt # Strip MF so we end up with the name of the file. 8321247738Sbapt mf=`echo "$mf" | sed -e 's/:.*$//'` 8322247738Sbapt # Check whether this is an Automake generated Makefile or not. 8323247738Sbapt # We used to match only the files named `Makefile.in', but 8324247738Sbapt # some people rename them; so instead we look at the file content. 8325247738Sbapt # Grep'ing the first line is not enough: some people post-process 8326247738Sbapt # each Makefile.in and add a new line on top of each file to say so. 8327247738Sbapt # Grep'ing the whole file is not good either: AIX grep has a line 8328247738Sbapt # limit of 2048, but all sed's we know have understand at least 4000. 8329247738Sbapt if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then 8330247738Sbapt dirpart=`AS_DIRNAME("$mf")` 8331247738Sbapt else 8332247738Sbapt continue 8333247738Sbapt fi 8334247738Sbapt # Extract the definition of DEPDIR, am__include, and am__quote 8335247738Sbapt # from the Makefile without running `make'. 8336247738Sbapt DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` 8337247738Sbapt test -z "$DEPDIR" && continue 8338247738Sbapt am__include=`sed -n 's/^am__include = //p' < "$mf"` 8339247738Sbapt test -z "am__include" && continue 8340247738Sbapt am__quote=`sed -n 's/^am__quote = //p' < "$mf"` 8341247738Sbapt # When using ansi2knr, U may be empty or an underscore; expand it 8342247738Sbapt U=`sed -n 's/^U = //p' < "$mf"` 8343247738Sbapt # Find all dependency output files, they are included files with 8344247738Sbapt # $(DEPDIR) in their names. We invoke sed twice because it is the 8345247738Sbapt # simplest approach to changing $(DEPDIR) to its actual value in the 8346247738Sbapt # expansion. 8347247738Sbapt for file in `sed -n " 8348247738Sbapt s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ 8349247738Sbapt sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do 8350247738Sbapt # Make sure the directory exists. 8351247738Sbapt test -f "$dirpart/$file" && continue 8352247738Sbapt fdir=`AS_DIRNAME(["$file"])` 8353247738Sbapt AS_MKDIR_P([$dirpart/$fdir]) 8354247738Sbapt # echo "creating $dirpart/$file" 8355247738Sbapt echo '# dummy' > "$dirpart/$file" 8356247738Sbapt done 8357247738Sbapt done 8358247738Sbapt} 8359247738Sbapt])# _AM_OUTPUT_DEPENDENCY_COMMANDS 8360247738Sbapt 8361247738Sbapt 8362247738Sbapt# AM_OUTPUT_DEPENDENCY_COMMANDS 8363247738Sbapt# ----------------------------- 8364247738Sbapt# This macro should only be invoked once -- use via AC_REQUIRE. 8365247738Sbapt# 8366247738Sbapt# This code is only required when automatic dependency tracking 8367247738Sbapt# is enabled. FIXME. This creates each `.P' file that we will 8368247738Sbapt# need in order to bootstrap the dependency handling code. 8369247738SbaptAC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS], 8370247738Sbapt[AC_CONFIG_COMMANDS([depfiles], 8371247738Sbapt [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS], 8372247738Sbapt [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"]) 8373247738Sbapt]) 8374247738Sbapt 8375247738Sbapt# Do all the work for Automake. -*- Autoconf -*- 8376247738Sbapt 8377247738Sbapt# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 8378247738Sbapt# 2005, 2006, 2008, 2009 Free Software Foundation, Inc. 8379247738Sbapt# 8380247738Sbapt# This file is free software; the Free Software Foundation 8381247738Sbapt# gives unlimited permission to copy and/or distribute it, 8382247738Sbapt# with or without modifications, as long as this notice is preserved. 8383247738Sbapt 8384247738Sbapt# serial 16 8385247738Sbapt 8386247738Sbapt# This macro actually does too much. Some checks are only needed if 8387247738Sbapt# your package does certain things. But this isn't really a big deal. 8388247738Sbapt 8389247738Sbapt# AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE]) 8390247738Sbapt# AM_INIT_AUTOMAKE([OPTIONS]) 8391247738Sbapt# ----------------------------------------------- 8392247738Sbapt# The call with PACKAGE and VERSION arguments is the old style 8393247738Sbapt# call (pre autoconf-2.50), which is being phased out. PACKAGE 8394247738Sbapt# and VERSION should now be passed to AC_INIT and removed from 8395247738Sbapt# the call to AM_INIT_AUTOMAKE. 8396247738Sbapt# We support both call styles for the transition. After 8397247738Sbapt# the next Automake release, Autoconf can make the AC_INIT 8398247738Sbapt# arguments mandatory, and then we can depend on a new Autoconf 8399247738Sbapt# release and drop the old call support. 8400247738SbaptAC_DEFUN([AM_INIT_AUTOMAKE], 8401247738Sbapt[AC_PREREQ([2.62])dnl 8402247738Sbaptdnl Autoconf wants to disallow AM_ names. We explicitly allow 8403247738Sbaptdnl the ones we care about. 8404247738Sbaptm4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl 8405247738SbaptAC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl 8406247738SbaptAC_REQUIRE([AC_PROG_INSTALL])dnl 8407247738Sbaptif test "`cd $srcdir && pwd`" != "`pwd`"; then 8408247738Sbapt # Use -I$(srcdir) only when $(srcdir) != ., so that make's output 8409247738Sbapt # is not polluted with repeated "-I." 8410247738Sbapt AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl 8411247738Sbapt # test to see if srcdir already configured 8412247738Sbapt if test -f $srcdir/config.status; then 8413247738Sbapt AC_MSG_ERROR([source directory already configured; run "make distclean" there first]) 8414247738Sbapt fi 8415247738Sbaptfi 8416247738Sbapt 8417247738Sbapt# test whether we have cygpath 8418247738Sbaptif test -z "$CYGPATH_W"; then 8419247738Sbapt if (cygpath --version) >/dev/null 2>/dev/null; then 8420247738Sbapt CYGPATH_W='cygpath -w' 8421247738Sbapt else 8422247738Sbapt CYGPATH_W=echo 8423247738Sbapt fi 8424247738Sbaptfi 8425247738SbaptAC_SUBST([CYGPATH_W]) 8426247738Sbapt 8427247738Sbapt# Define the identity of the package. 8428247738Sbaptdnl Distinguish between old-style and new-style calls. 8429247738Sbaptm4_ifval([$2], 8430247738Sbapt[m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl 8431247738Sbapt AC_SUBST([PACKAGE], [$1])dnl 8432247738Sbapt AC_SUBST([VERSION], [$2])], 8433247738Sbapt[_AM_SET_OPTIONS([$1])dnl 8434247738Sbaptdnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT. 8435247738Sbaptm4_if(m4_ifdef([AC_PACKAGE_NAME], 1)m4_ifdef([AC_PACKAGE_VERSION], 1), 11,, 8436247738Sbapt [m4_fatal([AC_INIT should be called with package and version arguments])])dnl 8437247738Sbapt AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl 8438247738Sbapt AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl 8439247738Sbapt 8440247738Sbapt_AM_IF_OPTION([no-define],, 8441247738Sbapt[AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package]) 8442247738Sbapt AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl 8443247738Sbapt 8444247738Sbapt# Some tools Automake needs. 8445247738SbaptAC_REQUIRE([AM_SANITY_CHECK])dnl 8446247738SbaptAC_REQUIRE([AC_ARG_PROGRAM])dnl 8447247738SbaptAM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version}) 8448247738SbaptAM_MISSING_PROG(AUTOCONF, autoconf) 8449247738SbaptAM_MISSING_PROG(AUTOMAKE, automake-${am__api_version}) 8450247738SbaptAM_MISSING_PROG(AUTOHEADER, autoheader) 8451247738SbaptAM_MISSING_PROG(MAKEINFO, makeinfo) 8452247738SbaptAC_REQUIRE([AM_PROG_INSTALL_SH])dnl 8453247738SbaptAC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl 8454247738SbaptAC_REQUIRE([AM_PROG_MKDIR_P])dnl 8455247738Sbapt# We need awk for the "check" target. The system "awk" is bad on 8456247738Sbapt# some platforms. 8457247738SbaptAC_REQUIRE([AC_PROG_AWK])dnl 8458247738SbaptAC_REQUIRE([AC_PROG_MAKE_SET])dnl 8459247738SbaptAC_REQUIRE([AM_SET_LEADING_DOT])dnl 8460247738Sbapt_AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])], 8461247738Sbapt [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])], 8462247738Sbapt [_AM_PROG_TAR([v7])])]) 8463247738Sbapt_AM_IF_OPTION([no-dependencies],, 8464247738Sbapt[AC_PROVIDE_IFELSE([AC_PROG_CC], 8465247738Sbapt [_AM_DEPENDENCIES(CC)], 8466247738Sbapt [define([AC_PROG_CC], 8467247738Sbapt defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl 8468247738SbaptAC_PROVIDE_IFELSE([AC_PROG_CXX], 8469247738Sbapt [_AM_DEPENDENCIES(CXX)], 8470247738Sbapt [define([AC_PROG_CXX], 8471247738Sbapt defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl 8472247738SbaptAC_PROVIDE_IFELSE([AC_PROG_OBJC], 8473247738Sbapt [_AM_DEPENDENCIES(OBJC)], 8474247738Sbapt [define([AC_PROG_OBJC], 8475247738Sbapt defn([AC_PROG_OBJC])[_AM_DEPENDENCIES(OBJC)])])dnl 8476247738Sbapt]) 8477247738Sbapt_AM_IF_OPTION([silent-rules], [AC_REQUIRE([AM_SILENT_RULES])])dnl 8478247738Sbaptdnl The `parallel-tests' driver may need to know about EXEEXT, so add the 8479247738Sbaptdnl `am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This macro 8480247738Sbaptdnl is hooked onto _AC_COMPILER_EXEEXT early, see below. 8481247738SbaptAC_CONFIG_COMMANDS_PRE(dnl 8482247738Sbapt[m4_provide_if([_AM_COMPILER_EXEEXT], 8483247738Sbapt [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl 8484247738Sbapt]) 8485247738Sbapt 8486247738Sbaptdnl Hook into `_AC_COMPILER_EXEEXT' early to learn its expansion. Do not 8487247738Sbaptdnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further 8488247738Sbaptdnl mangled by Autoconf and run in a shell conditional statement. 8489247738Sbaptm4_define([_AC_COMPILER_EXEEXT], 8490247738Sbaptm4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])]) 8491247738Sbapt 8492247738Sbapt 8493247738Sbapt# When config.status generates a header, we must update the stamp-h file. 8494247738Sbapt# This file resides in the same directory as the config header 8495247738Sbapt# that is generated. The stamp files are numbered to have different names. 8496247738Sbapt 8497247738Sbapt# Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the 8498247738Sbapt# loop where config.status creates the headers, so we can generate 8499247738Sbapt# our stamp files there. 8500247738SbaptAC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK], 8501247738Sbapt[# Compute $1's index in $config_headers. 8502247738Sbapt_am_arg=$1 8503247738Sbapt_am_stamp_count=1 8504247738Sbaptfor _am_header in $config_headers :; do 8505247738Sbapt case $_am_header in 8506247738Sbapt $_am_arg | $_am_arg:* ) 8507247738Sbapt break ;; 8508247738Sbapt * ) 8509247738Sbapt _am_stamp_count=`expr $_am_stamp_count + 1` ;; 8510247738Sbapt esac 8511247738Sbaptdone 8512247738Sbaptecho "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count]) 8513247738Sbapt 8514247738Sbapt# Copyright (C) 2001, 2003, 2005, 2008 Free Software Foundation, Inc. 8515247738Sbapt# 8516247738Sbapt# This file is free software; the Free Software Foundation 8517247738Sbapt# gives unlimited permission to copy and/or distribute it, 8518247738Sbapt# with or without modifications, as long as this notice is preserved. 8519247738Sbapt 8520247738Sbapt# AM_PROG_INSTALL_SH 8521247738Sbapt# ------------------ 8522247738Sbapt# Define $install_sh. 8523247738SbaptAC_DEFUN([AM_PROG_INSTALL_SH], 8524247738Sbapt[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl 8525247738Sbaptif test x"${install_sh}" != xset; then 8526247738Sbapt case $am_aux_dir in 8527247738Sbapt *\ * | *\ *) 8528247738Sbapt install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;; 8529247738Sbapt *) 8530247738Sbapt install_sh="\${SHELL} $am_aux_dir/install-sh" 8531247738Sbapt esac 8532247738Sbaptfi 8533247738SbaptAC_SUBST(install_sh)]) 8534247738Sbapt 8535247738Sbapt# Copyright (C) 2003, 2005 Free Software Foundation, Inc. 8536247738Sbapt# 8537247738Sbapt# This file is free software; the Free Software Foundation 8538247738Sbapt# gives unlimited permission to copy and/or distribute it, 8539247738Sbapt# with or without modifications, as long as this notice is preserved. 8540247738Sbapt 8541247738Sbapt# serial 2 8542247738Sbapt 8543247738Sbapt# Check whether the underlying file-system supports filenames 8544247738Sbapt# with a leading dot. For instance MS-DOS doesn't. 8545247738SbaptAC_DEFUN([AM_SET_LEADING_DOT], 8546247738Sbapt[rm -rf .tst 2>/dev/null 8547247738Sbaptmkdir .tst 2>/dev/null 8548247738Sbaptif test -d .tst; then 8549247738Sbapt am__leading_dot=. 8550247738Sbaptelse 8551247738Sbapt am__leading_dot=_ 8552247738Sbaptfi 8553247738Sbaptrmdir .tst 2>/dev/null 8554247738SbaptAC_SUBST([am__leading_dot])]) 8555247738Sbapt 8556247738Sbapt# Check to see how 'make' treats includes. -*- Autoconf -*- 8557247738Sbapt 8558247738Sbapt# Copyright (C) 2001, 2002, 2003, 2005, 2009 Free Software Foundation, Inc. 8559247738Sbapt# 8560247738Sbapt# This file is free software; the Free Software Foundation 8561247738Sbapt# gives unlimited permission to copy and/or distribute it, 8562247738Sbapt# with or without modifications, as long as this notice is preserved. 8563247738Sbapt 8564247738Sbapt# serial 4 8565247738Sbapt 8566247738Sbapt# AM_MAKE_INCLUDE() 8567247738Sbapt# ----------------- 8568247738Sbapt# Check to see how make treats includes. 8569247738SbaptAC_DEFUN([AM_MAKE_INCLUDE], 8570247738Sbapt[am_make=${MAKE-make} 8571247738Sbaptcat > confinc << 'END' 8572247738Sbaptam__doit: 8573247738Sbapt @echo this is the am__doit target 8574247738Sbapt.PHONY: am__doit 8575247738SbaptEND 8576247738Sbapt# If we don't find an include directive, just comment out the code. 8577247738SbaptAC_MSG_CHECKING([for style of include used by $am_make]) 8578247738Sbaptam__include="#" 8579247738Sbaptam__quote= 8580247738Sbapt_am_result=none 8581247738Sbapt# First try GNU make style include. 8582247738Sbaptecho "include confinc" > confmf 8583247738Sbapt# Ignore all kinds of additional output from `make'. 8584247738Sbaptcase `$am_make -s -f confmf 2> /dev/null` in #( 8585247738Sbapt*the\ am__doit\ target*) 8586247738Sbapt am__include=include 8587247738Sbapt am__quote= 8588247738Sbapt _am_result=GNU 8589247738Sbapt ;; 8590247738Sbaptesac 8591247738Sbapt# Now try BSD make style include. 8592247738Sbaptif test "$am__include" = "#"; then 8593247738Sbapt echo '.include "confinc"' > confmf 8594247738Sbapt case `$am_make -s -f confmf 2> /dev/null` in #( 8595247738Sbapt *the\ am__doit\ target*) 8596247738Sbapt am__include=.include 8597247738Sbapt am__quote="\"" 8598247738Sbapt _am_result=BSD 8599247738Sbapt ;; 8600247738Sbapt esac 8601247738Sbaptfi 8602247738SbaptAC_SUBST([am__include]) 8603247738SbaptAC_SUBST([am__quote]) 8604247738SbaptAC_MSG_RESULT([$_am_result]) 8605247738Sbaptrm -f confinc confmf 8606247738Sbapt]) 8607247738Sbapt 8608247738Sbapt# Fake the existence of programs that GNU maintainers use. -*- Autoconf -*- 8609247738Sbapt 8610247738Sbapt# Copyright (C) 1997, 1999, 2000, 2001, 2003, 2004, 2005, 2008 8611247738Sbapt# Free Software Foundation, Inc. 8612247738Sbapt# 8613247738Sbapt# This file is free software; the Free Software Foundation 8614247738Sbapt# gives unlimited permission to copy and/or distribute it, 8615247738Sbapt# with or without modifications, as long as this notice is preserved. 8616247738Sbapt 8617247738Sbapt# serial 6 8618247738Sbapt 8619247738Sbapt# AM_MISSING_PROG(NAME, PROGRAM) 8620247738Sbapt# ------------------------------ 8621247738SbaptAC_DEFUN([AM_MISSING_PROG], 8622247738Sbapt[AC_REQUIRE([AM_MISSING_HAS_RUN]) 8623247738Sbapt$1=${$1-"${am_missing_run}$2"} 8624247738SbaptAC_SUBST($1)]) 8625247738Sbapt 8626247738Sbapt 8627247738Sbapt# AM_MISSING_HAS_RUN 8628247738Sbapt# ------------------ 8629247738Sbapt# Define MISSING if not defined so far and test if it supports --run. 8630247738Sbapt# If it does, set am_missing_run to use it, otherwise, to nothing. 8631247738SbaptAC_DEFUN([AM_MISSING_HAS_RUN], 8632247738Sbapt[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl 8633247738SbaptAC_REQUIRE_AUX_FILE([missing])dnl 8634247738Sbaptif test x"${MISSING+set}" != xset; then 8635247738Sbapt case $am_aux_dir in 8636247738Sbapt *\ * | *\ *) 8637247738Sbapt MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;; 8638247738Sbapt *) 8639247738Sbapt MISSING="\${SHELL} $am_aux_dir/missing" ;; 8640247738Sbapt esac 8641247738Sbaptfi 8642247738Sbapt# Use eval to expand $SHELL 8643247738Sbaptif eval "$MISSING --run true"; then 8644247738Sbapt am_missing_run="$MISSING --run " 8645247738Sbaptelse 8646247738Sbapt am_missing_run= 8647247738Sbapt AC_MSG_WARN([`missing' script is too old or missing]) 8648247738Sbaptfi 8649247738Sbapt]) 8650247738Sbapt 8651247738Sbapt# Copyright (C) 2003, 2004, 2005, 2006 Free Software Foundation, Inc. 8652247738Sbapt# 8653247738Sbapt# This file is free software; the Free Software Foundation 8654247738Sbapt# gives unlimited permission to copy and/or distribute it, 8655247738Sbapt# with or without modifications, as long as this notice is preserved. 8656247738Sbapt 8657247738Sbapt# AM_PROG_MKDIR_P 8658247738Sbapt# --------------- 8659247738Sbapt# Check for `mkdir -p'. 8660247738SbaptAC_DEFUN([AM_PROG_MKDIR_P], 8661247738Sbapt[AC_PREREQ([2.60])dnl 8662247738SbaptAC_REQUIRE([AC_PROG_MKDIR_P])dnl 8663247738Sbaptdnl Automake 1.8 to 1.9.6 used to define mkdir_p. We now use MKDIR_P, 8664247738Sbaptdnl while keeping a definition of mkdir_p for backward compatibility. 8665247738Sbaptdnl @MKDIR_P@ is magic: AC_OUTPUT adjusts its value for each Makefile. 8666247738Sbaptdnl However we cannot define mkdir_p as $(MKDIR_P) for the sake of 8667247738Sbaptdnl Makefile.ins that do not define MKDIR_P, so we do our own 8668247738Sbaptdnl adjustment using top_builddir (which is defined more often than 8669247738Sbaptdnl MKDIR_P). 8670247738SbaptAC_SUBST([mkdir_p], ["$MKDIR_P"])dnl 8671247738Sbaptcase $mkdir_p in 8672247738Sbapt [[\\/$]]* | ?:[[\\/]]*) ;; 8673247738Sbapt */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;; 8674247738Sbaptesac 8675247738Sbapt]) 8676247738Sbapt 8677247738Sbapt# Helper functions for option handling. -*- Autoconf -*- 8678247738Sbapt 8679247738Sbapt# Copyright (C) 2001, 2002, 2003, 2005, 2008 Free Software Foundation, Inc. 8680247738Sbapt# 8681247738Sbapt# This file is free software; the Free Software Foundation 8682247738Sbapt# gives unlimited permission to copy and/or distribute it, 8683247738Sbapt# with or without modifications, as long as this notice is preserved. 8684247738Sbapt 8685247738Sbapt# serial 4 8686247738Sbapt 8687247738Sbapt# _AM_MANGLE_OPTION(NAME) 8688247738Sbapt# ----------------------- 8689247738SbaptAC_DEFUN([_AM_MANGLE_OPTION], 8690247738Sbapt[[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])]) 8691247738Sbapt 8692247738Sbapt# _AM_SET_OPTION(NAME) 8693247738Sbapt# ------------------------------ 8694247738Sbapt# Set option NAME. Presently that only means defining a flag for this option. 8695247738SbaptAC_DEFUN([_AM_SET_OPTION], 8696247738Sbapt[m4_define(_AM_MANGLE_OPTION([$1]), 1)]) 8697247738Sbapt 8698247738Sbapt# _AM_SET_OPTIONS(OPTIONS) 8699247738Sbapt# ---------------------------------- 8700247738Sbapt# OPTIONS is a space-separated list of Automake options. 8701247738SbaptAC_DEFUN([_AM_SET_OPTIONS], 8702247738Sbapt[m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])]) 8703247738Sbapt 8704247738Sbapt# _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET]) 8705247738Sbapt# ------------------------------------------- 8706247738Sbapt# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. 8707247738SbaptAC_DEFUN([_AM_IF_OPTION], 8708247738Sbapt[m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])]) 8709247738Sbapt 8710247738Sbapt# Check to make sure that the build environment is sane. -*- Autoconf -*- 8711247738Sbapt 8712247738Sbapt# Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005, 2008 8713247738Sbapt# Free Software Foundation, Inc. 8714247738Sbapt# 8715247738Sbapt# This file is free software; the Free Software Foundation 8716247738Sbapt# gives unlimited permission to copy and/or distribute it, 8717247738Sbapt# with or without modifications, as long as this notice is preserved. 8718247738Sbapt 8719247738Sbapt# serial 5 8720247738Sbapt 8721247738Sbapt# AM_SANITY_CHECK 8722247738Sbapt# --------------- 8723247738SbaptAC_DEFUN([AM_SANITY_CHECK], 8724247738Sbapt[AC_MSG_CHECKING([whether build environment is sane]) 8725247738Sbapt# Just in case 8726247738Sbaptsleep 1 8727247738Sbaptecho timestamp > conftest.file 8728247738Sbapt# Reject unsafe characters in $srcdir or the absolute working directory 8729247738Sbapt# name. Accept space and tab only in the latter. 8730247738Sbaptam_lf=' 8731247738Sbapt' 8732247738Sbaptcase `pwd` in 8733247738Sbapt *[[\\\"\#\$\&\'\`$am_lf]]*) 8734247738Sbapt AC_MSG_ERROR([unsafe absolute working directory name]);; 8735247738Sbaptesac 8736247738Sbaptcase $srcdir in 8737247738Sbapt *[[\\\"\#\$\&\'\`$am_lf\ \ ]]*) 8738247738Sbapt AC_MSG_ERROR([unsafe srcdir value: `$srcdir']);; 8739247738Sbaptesac 8740247738Sbapt 8741247738Sbapt# Do `set' in a subshell so we don't clobber the current shell's 8742247738Sbapt# arguments. Must try -L first in case configure is actually a 8743247738Sbapt# symlink; some systems play weird games with the mod time of symlinks 8744247738Sbapt# (eg FreeBSD returns the mod time of the symlink's containing 8745247738Sbapt# directory). 8746247738Sbaptif ( 8747247738Sbapt set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` 8748247738Sbapt if test "$[*]" = "X"; then 8749247738Sbapt # -L didn't work. 8750247738Sbapt set X `ls -t "$srcdir/configure" conftest.file` 8751247738Sbapt fi 8752247738Sbapt rm -f conftest.file 8753247738Sbapt if test "$[*]" != "X $srcdir/configure conftest.file" \ 8754247738Sbapt && test "$[*]" != "X conftest.file $srcdir/configure"; then 8755247738Sbapt 8756247738Sbapt # If neither matched, then we have a broken ls. This can happen 8757247738Sbapt # if, for instance, CONFIG_SHELL is bash and it inherits a 8758247738Sbapt # broken ls alias from the environment. This has actually 8759247738Sbapt # happened. Such a system could not be considered "sane". 8760247738Sbapt AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken 8761247738Sbaptalias in your environment]) 8762247738Sbapt fi 8763247738Sbapt 8764247738Sbapt test "$[2]" = conftest.file 8765247738Sbapt ) 8766247738Sbaptthen 8767247738Sbapt # Ok. 8768247738Sbapt : 8769247738Sbaptelse 8770247738Sbapt AC_MSG_ERROR([newly created file is older than distributed files! 8771247738SbaptCheck your system clock]) 8772247738Sbaptfi 8773247738SbaptAC_MSG_RESULT(yes)]) 8774247738Sbapt 8775247738Sbapt# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. 8776247738Sbapt# 8777247738Sbapt# This file is free software; the Free Software Foundation 8778247738Sbapt# gives unlimited permission to copy and/or distribute it, 8779247738Sbapt# with or without modifications, as long as this notice is preserved. 8780247738Sbapt 8781247738Sbapt# AM_PROG_INSTALL_STRIP 8782247738Sbapt# --------------------- 8783247738Sbapt# One issue with vendor `install' (even GNU) is that you can't 8784247738Sbapt# specify the program used to strip binaries. This is especially 8785247738Sbapt# annoying in cross-compiling environments, where the build's strip 8786247738Sbapt# is unlikely to handle the host's binaries. 8787247738Sbapt# Fortunately install-sh will honor a STRIPPROG variable, so we 8788247738Sbapt# always use install-sh in `make install-strip', and initialize 8789247738Sbapt# STRIPPROG with the value of the STRIP variable (set by the user). 8790247738SbaptAC_DEFUN([AM_PROG_INSTALL_STRIP], 8791247738Sbapt[AC_REQUIRE([AM_PROG_INSTALL_SH])dnl 8792247738Sbapt# Installed binaries are usually stripped using `strip' when the user 8793247738Sbapt# run `make install-strip'. However `strip' might not be the right 8794247738Sbapt# tool to use in cross-compilation environments, therefore Automake 8795247738Sbapt# will honor the `STRIP' environment variable to overrule this program. 8796247738Sbaptdnl Don't test for $cross_compiling = yes, because it might be `maybe'. 8797247738Sbaptif test "$cross_compiling" != no; then 8798247738Sbapt AC_CHECK_TOOL([STRIP], [strip], :) 8799247738Sbaptfi 8800247738SbaptINSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" 8801247738SbaptAC_SUBST([INSTALL_STRIP_PROGRAM])]) 8802247738Sbapt 8803247738Sbapt# Copyright (C) 2006, 2008 Free Software Foundation, Inc. 8804247738Sbapt# 8805247738Sbapt# This file is free software; the Free Software Foundation 8806247738Sbapt# gives unlimited permission to copy and/or distribute it, 8807247738Sbapt# with or without modifications, as long as this notice is preserved. 8808247738Sbapt 8809247738Sbapt# serial 2 8810247738Sbapt 8811247738Sbapt# _AM_SUBST_NOTMAKE(VARIABLE) 8812247738Sbapt# --------------------------- 8813247738Sbapt# Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in. 8814247738Sbapt# This macro is traced by Automake. 8815247738SbaptAC_DEFUN([_AM_SUBST_NOTMAKE]) 8816247738Sbapt 8817247738Sbapt# AM_SUBST_NOTMAKE(VARIABLE) 8818247738Sbapt# --------------------------- 8819247738Sbapt# Public sister of _AM_SUBST_NOTMAKE. 8820247738SbaptAC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)]) 8821247738Sbapt 8822247738Sbapt# Check how to create a tarball. -*- Autoconf -*- 8823247738Sbapt 8824247738Sbapt# Copyright (C) 2004, 2005 Free Software Foundation, Inc. 8825247738Sbapt# 8826247738Sbapt# This file is free software; the Free Software Foundation 8827247738Sbapt# gives unlimited permission to copy and/or distribute it, 8828247738Sbapt# with or without modifications, as long as this notice is preserved. 8829247738Sbapt 8830247738Sbapt# serial 2 8831247738Sbapt 8832247738Sbapt# _AM_PROG_TAR(FORMAT) 8833247738Sbapt# -------------------- 8834247738Sbapt# Check how to create a tarball in format FORMAT. 8835247738Sbapt# FORMAT should be one of `v7', `ustar', or `pax'. 8836247738Sbapt# 8837247738Sbapt# Substitute a variable $(am__tar) that is a command 8838247738Sbapt# writing to stdout a FORMAT-tarball containing the directory 8839247738Sbapt# $tardir. 8840247738Sbapt# tardir=directory && $(am__tar) > result.tar 8841247738Sbapt# 8842247738Sbapt# Substitute a variable $(am__untar) that extract such 8843247738Sbapt# a tarball read from stdin. 8844247738Sbapt# $(am__untar) < result.tar 8845247738SbaptAC_DEFUN([_AM_PROG_TAR], 8846247738Sbapt[# Always define AMTAR for backward compatibility. 8847247738SbaptAM_MISSING_PROG([AMTAR], [tar]) 8848247738Sbaptm4_if([$1], [v7], 8849247738Sbapt [am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'], 8850247738Sbapt [m4_case([$1], [ustar],, [pax],, 8851247738Sbapt [m4_fatal([Unknown tar format])]) 8852247738SbaptAC_MSG_CHECKING([how to create a $1 tar archive]) 8853247738Sbapt# Loop over all known methods to create a tar archive until one works. 8854247738Sbapt_am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none' 8855247738Sbapt_am_tools=${am_cv_prog_tar_$1-$_am_tools} 8856247738Sbapt# Do not fold the above two line into one, because Tru64 sh and 8857247738Sbapt# Solaris sh will not grok spaces in the rhs of `-'. 8858247738Sbaptfor _am_tool in $_am_tools 8859247738Sbaptdo 8860247738Sbapt case $_am_tool in 8861247738Sbapt gnutar) 8862247738Sbapt for _am_tar in tar gnutar gtar; 8863247738Sbapt do 8864247738Sbapt AM_RUN_LOG([$_am_tar --version]) && break 8865247738Sbapt done 8866247738Sbapt am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"' 8867247738Sbapt am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"' 8868247738Sbapt am__untar="$_am_tar -xf -" 8869247738Sbapt ;; 8870247738Sbapt plaintar) 8871247738Sbapt # Must skip GNU tar: if it does not support --format= it doesn't create 8872247738Sbapt # ustar tarball either. 8873247738Sbapt (tar --version) >/dev/null 2>&1 && continue 8874247738Sbapt am__tar='tar chf - "$$tardir"' 8875247738Sbapt am__tar_='tar chf - "$tardir"' 8876247738Sbapt am__untar='tar xf -' 8877247738Sbapt ;; 8878247738Sbapt pax) 8879247738Sbapt am__tar='pax -L -x $1 -w "$$tardir"' 8880247738Sbapt am__tar_='pax -L -x $1 -w "$tardir"' 8881247738Sbapt am__untar='pax -r' 8882247738Sbapt ;; 8883247738Sbapt cpio) 8884247738Sbapt am__tar='find "$$tardir" -print | cpio -o -H $1 -L' 8885247738Sbapt am__tar_='find "$tardir" -print | cpio -o -H $1 -L' 8886247738Sbapt am__untar='cpio -i -H $1 -d' 8887247738Sbapt ;; 8888247738Sbapt none) 8889247738Sbapt am__tar=false 8890247738Sbapt am__tar_=false 8891247738Sbapt am__untar=false 8892247738Sbapt ;; 8893247738Sbapt esac 8894247738Sbapt 8895247738Sbapt # If the value was cached, stop now. We just wanted to have am__tar 8896247738Sbapt # and am__untar set. 8897247738Sbapt test -n "${am_cv_prog_tar_$1}" && break 8898247738Sbapt 8899247738Sbapt # tar/untar a dummy directory, and stop if the command works 8900247738Sbapt rm -rf conftest.dir 8901247738Sbapt mkdir conftest.dir 8902247738Sbapt echo GrepMe > conftest.dir/file 8903247738Sbapt AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar]) 8904247738Sbapt rm -rf conftest.dir 8905247738Sbapt if test -s conftest.tar; then 8906247738Sbapt AM_RUN_LOG([$am__untar <conftest.tar]) 8907247738Sbapt grep GrepMe conftest.dir/file >/dev/null 2>&1 && break 8908247738Sbapt fi 8909247738Sbaptdone 8910247738Sbaptrm -rf conftest.dir 8911247738Sbapt 8912247738SbaptAC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool]) 8913247738SbaptAC_MSG_RESULT([$am_cv_prog_tar_$1])]) 8914247738SbaptAC_SUBST([am__tar]) 8915247738SbaptAC_SUBST([am__untar]) 8916247738Sbapt]) # _AM_PROG_TAR 8917247738Sbapt 8918