10ef0e59aSmrg# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*- 20ef0e59aSmrg# 3d5e6aabbSmrg# Copyright (C) 1996-2001, 2003-2019, 2021-2024 Free Software 415885c33Smrg# Foundation, Inc. 50ef0e59aSmrg# Written by Gordon Matzigkeit, 1996 60ef0e59aSmrg# 70ef0e59aSmrg# This file is free software; the Free Software Foundation gives 80ef0e59aSmrg# unlimited permission to copy and/or distribute it, with or without 90ef0e59aSmrg# modifications, as long as this notice is preserved. 100ef0e59aSmrg 110ef0e59aSmrgm4_define([_LT_COPYING], [dnl 12d5e6aabbSmrg# Copyright (C) 2024 Free Software Foundation, Inc. 130ef0e59aSmrg# This is free software; see the source for copying conditions. There is NO 140ef0e59aSmrg# warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 150ef0e59aSmrg 160ef0e59aSmrg# GNU Libtool is free software; you can redistribute it and/or modify 170ef0e59aSmrg# it under the terms of the GNU General Public License as published by 18d5e6aabbSmrg# the Free Software Foundation; either version 2 of the License, or 190ef0e59aSmrg# (at your option) any later version. 200ef0e59aSmrg# 210ef0e59aSmrg# As a special exception to the GNU General Public License, if you 220ef0e59aSmrg# distribute this file as part of a program or library that is built 230ef0e59aSmrg# using GNU Libtool, you may include this file under the same 240ef0e59aSmrg# distribution terms that you use for the rest of that program. 250ef0e59aSmrg# 260ef0e59aSmrg# GNU Libtool is distributed in the hope that it will be useful, but 270ef0e59aSmrg# WITHOUT ANY WARRANTY; without even the implied warranty of 280ef0e59aSmrg# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 290ef0e59aSmrg# GNU General Public License for more details. 300ef0e59aSmrg# 310ef0e59aSmrg# You should have received a copy of the GNU General Public License 320ef0e59aSmrg# along with this program. If not, see <http://www.gnu.org/licenses/>. 330ef0e59aSmrg]) 340ef0e59aSmrg 35d5e6aabbSmrg# serial 63 LT_INIT 360ef0e59aSmrg 370ef0e59aSmrg 380ef0e59aSmrg# LT_PREREQ(VERSION) 390ef0e59aSmrg# ------------------ 400ef0e59aSmrg# Complain and exit if this libtool version is less that VERSION. 410ef0e59aSmrgm4_defun([LT_PREREQ], 420ef0e59aSmrg[m4_if(m4_version_compare(m4_defn([LT_PACKAGE_VERSION]), [$1]), -1, 430ef0e59aSmrg [m4_default([$3], 440ef0e59aSmrg [m4_fatal([Libtool version $1 or higher is required], 450ef0e59aSmrg 63)])], 460ef0e59aSmrg [$2])]) 470ef0e59aSmrg 480ef0e59aSmrg 490ef0e59aSmrg# _LT_CHECK_BUILDDIR 500ef0e59aSmrg# ------------------ 510ef0e59aSmrg# Complain if the absolute build directory name contains unusual characters 520ef0e59aSmrgm4_defun([_LT_CHECK_BUILDDIR], 530ef0e59aSmrg[case `pwd` in 540ef0e59aSmrg *\ * | *\ *) 550ef0e59aSmrg AC_MSG_WARN([Libtool does not cope well with whitespace in `pwd`]) ;; 560ef0e59aSmrgesac 570ef0e59aSmrg]) 580ef0e59aSmrg 590ef0e59aSmrg 600ef0e59aSmrg# LT_INIT([OPTIONS]) 610ef0e59aSmrg# ------------------ 620ef0e59aSmrgAC_DEFUN([LT_INIT], 63d5e6aabbSmrg[AC_PREREQ([2.64])dnl We use AC_PATH_PROGS_FEATURE_CHECK 640ef0e59aSmrgAC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl 650ef0e59aSmrgAC_BEFORE([$0], [LT_LANG])dnl 660ef0e59aSmrgAC_BEFORE([$0], [LT_OUTPUT])dnl 670ef0e59aSmrgAC_BEFORE([$0], [LTDL_INIT])dnl 680ef0e59aSmrgm4_require([_LT_CHECK_BUILDDIR])dnl 690ef0e59aSmrg 700ef0e59aSmrgdnl Autoconf doesn't catch unexpanded LT_ macros by default: 710ef0e59aSmrgm4_pattern_forbid([^_?LT_[A-Z_]+$])dnl 720ef0e59aSmrgm4_pattern_allow([^(_LT_EOF|LT_DLGLOBAL|LT_DLLAZY_OR_NOW|LT_MULTI_MODULE)$])dnl 730ef0e59aSmrgdnl aclocal doesn't pull ltoptions.m4, ltsugar.m4, or ltversion.m4 740ef0e59aSmrgdnl unless we require an AC_DEFUNed macro: 750ef0e59aSmrgAC_REQUIRE([LTOPTIONS_VERSION])dnl 760ef0e59aSmrgAC_REQUIRE([LTSUGAR_VERSION])dnl 770ef0e59aSmrgAC_REQUIRE([LTVERSION_VERSION])dnl 780ef0e59aSmrgAC_REQUIRE([LTOBSOLETE_VERSION])dnl 790ef0e59aSmrgm4_require([_LT_PROG_LTMAIN])dnl 800ef0e59aSmrg 810ef0e59aSmrg_LT_SHELL_INIT([SHELL=${CONFIG_SHELL-/bin/sh}]) 820ef0e59aSmrg 830ef0e59aSmrgdnl Parse OPTIONS 840ef0e59aSmrg_LT_SET_OPTIONS([$0], [$1]) 850ef0e59aSmrg 860ef0e59aSmrg# This can be used to rebuild libtool when needed 870ef0e59aSmrgLIBTOOL_DEPS=$ltmain 880ef0e59aSmrg 890ef0e59aSmrg# Always use our own libtool. 900ef0e59aSmrgLIBTOOL='$(SHELL) $(top_builddir)/libtool' 910ef0e59aSmrgAC_SUBST(LIBTOOL)dnl 920ef0e59aSmrg 930ef0e59aSmrg_LT_SETUP 940ef0e59aSmrg 950ef0e59aSmrg# Only expand once: 960ef0e59aSmrgm4_define([LT_INIT]) 970ef0e59aSmrg])# LT_INIT 980ef0e59aSmrg 990ef0e59aSmrg# Old names: 1000ef0e59aSmrgAU_ALIAS([AC_PROG_LIBTOOL], [LT_INIT]) 1010ef0e59aSmrgAU_ALIAS([AM_PROG_LIBTOOL], [LT_INIT]) 1020ef0e59aSmrgdnl aclocal-1.4 backwards compatibility: 1030ef0e59aSmrgdnl AC_DEFUN([AC_PROG_LIBTOOL], []) 1040ef0e59aSmrgdnl AC_DEFUN([AM_PROG_LIBTOOL], []) 1050ef0e59aSmrg 1060ef0e59aSmrg 1070ef0e59aSmrg# _LT_PREPARE_CC_BASENAME 1080ef0e59aSmrg# ----------------------- 1090ef0e59aSmrgm4_defun([_LT_PREPARE_CC_BASENAME], [ 1100ef0e59aSmrg# Calculate cc_basename. Skip known compiler wrappers and cross-prefix. 1110ef0e59aSmrgfunc_cc_basename () 1120ef0e59aSmrg{ 1130ef0e59aSmrg for cc_temp in @S|@*""; do 1140ef0e59aSmrg case $cc_temp in 1150ef0e59aSmrg compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;; 1160ef0e59aSmrg distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;; 1170ef0e59aSmrg \-*) ;; 1180ef0e59aSmrg *) break;; 1190ef0e59aSmrg esac 1200ef0e59aSmrg done 1210ef0e59aSmrg func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` 1220ef0e59aSmrg} 1230ef0e59aSmrg])# _LT_PREPARE_CC_BASENAME 1240ef0e59aSmrg 1250ef0e59aSmrg 1260ef0e59aSmrg# _LT_CC_BASENAME(CC) 1270ef0e59aSmrg# ------------------- 1280ef0e59aSmrg# It would be clearer to call AC_REQUIREs from _LT_PREPARE_CC_BASENAME, 1290ef0e59aSmrg# but that macro is also expanded into generated libtool script, which 1300ef0e59aSmrg# arranges for $SED and $ECHO to be set by different means. 1310ef0e59aSmrgm4_defun([_LT_CC_BASENAME], 1320ef0e59aSmrg[m4_require([_LT_PREPARE_CC_BASENAME])dnl 1330ef0e59aSmrgAC_REQUIRE([_LT_DECL_SED])dnl 1340ef0e59aSmrgAC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl 1350ef0e59aSmrgfunc_cc_basename $1 1360ef0e59aSmrgcc_basename=$func_cc_basename_result 1370ef0e59aSmrg]) 1380ef0e59aSmrg 1390ef0e59aSmrg 1400ef0e59aSmrg# _LT_FILEUTILS_DEFAULTS 1410ef0e59aSmrg# ---------------------- 1420ef0e59aSmrg# It is okay to use these file commands and assume they have been set 1430ef0e59aSmrg# sensibly after 'm4_require([_LT_FILEUTILS_DEFAULTS])'. 1440ef0e59aSmrgm4_defun([_LT_FILEUTILS_DEFAULTS], 1450ef0e59aSmrg[: ${CP="cp -f"} 1460ef0e59aSmrg: ${MV="mv -f"} 1470ef0e59aSmrg: ${RM="rm -f"} 1480ef0e59aSmrg])# _LT_FILEUTILS_DEFAULTS 1490ef0e59aSmrg 1500ef0e59aSmrg 1510ef0e59aSmrg# _LT_SETUP 1520ef0e59aSmrg# --------- 1530ef0e59aSmrgm4_defun([_LT_SETUP], 1540ef0e59aSmrg[AC_REQUIRE([AC_CANONICAL_HOST])dnl 1550ef0e59aSmrgAC_REQUIRE([AC_CANONICAL_BUILD])dnl 1560ef0e59aSmrgAC_REQUIRE([_LT_PREPARE_SED_QUOTE_VARS])dnl 1570ef0e59aSmrgAC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl 1580ef0e59aSmrg 1590ef0e59aSmrg_LT_DECL([], [PATH_SEPARATOR], [1], [The PATH separator for the build system])dnl 1600ef0e59aSmrgdnl 1610ef0e59aSmrg_LT_DECL([], [host_alias], [0], [The host system])dnl 1620ef0e59aSmrg_LT_DECL([], [host], [0])dnl 1630ef0e59aSmrg_LT_DECL([], [host_os], [0])dnl 1640ef0e59aSmrgdnl 1650ef0e59aSmrg_LT_DECL([], [build_alias], [0], [The build system])dnl 1660ef0e59aSmrg_LT_DECL([], [build], [0])dnl 1670ef0e59aSmrg_LT_DECL([], [build_os], [0])dnl 1680ef0e59aSmrgdnl 1690ef0e59aSmrgAC_REQUIRE([AC_PROG_CC])dnl 1700ef0e59aSmrgAC_REQUIRE([LT_PATH_LD])dnl 1710ef0e59aSmrgAC_REQUIRE([LT_PATH_NM])dnl 1720ef0e59aSmrgdnl 1730ef0e59aSmrgAC_REQUIRE([AC_PROG_LN_S])dnl 1740ef0e59aSmrgtest -z "$LN_S" && LN_S="ln -s" 1750ef0e59aSmrg_LT_DECL([], [LN_S], [1], [Whether we need soft or hard links])dnl 1760ef0e59aSmrgdnl 1770ef0e59aSmrgAC_REQUIRE([LT_CMD_MAX_LEN])dnl 1780ef0e59aSmrg_LT_DECL([objext], [ac_objext], [0], [Object file suffix (normally "o")])dnl 1790ef0e59aSmrg_LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl 1800ef0e59aSmrgdnl 1810ef0e59aSmrgm4_require([_LT_FILEUTILS_DEFAULTS])dnl 1820ef0e59aSmrgm4_require([_LT_CHECK_SHELL_FEATURES])dnl 1830ef0e59aSmrgm4_require([_LT_PATH_CONVERSION_FUNCTIONS])dnl 1840ef0e59aSmrgm4_require([_LT_CMD_RELOAD])dnl 18515885c33Smrgm4_require([_LT_DECL_FILECMD])dnl 1860ef0e59aSmrgm4_require([_LT_CHECK_MAGIC_METHOD])dnl 1870ef0e59aSmrgm4_require([_LT_CHECK_SHAREDLIB_FROM_LINKLIB])dnl 1880ef0e59aSmrgm4_require([_LT_CMD_OLD_ARCHIVE])dnl 1890ef0e59aSmrgm4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl 1900ef0e59aSmrgm4_require([_LT_WITH_SYSROOT])dnl 1910ef0e59aSmrgm4_require([_LT_CMD_TRUNCATE])dnl 1920ef0e59aSmrg 1930ef0e59aSmrg_LT_CONFIG_LIBTOOL_INIT([ 1940ef0e59aSmrg# See if we are running on zsh, and set the options that allow our 1950ef0e59aSmrg# commands through without removal of \ escapes INIT. 1960ef0e59aSmrgif test -n "\${ZSH_VERSION+set}"; then 1970ef0e59aSmrg setopt NO_GLOB_SUBST 1980ef0e59aSmrgfi 1990ef0e59aSmrg]) 2000ef0e59aSmrgif test -n "${ZSH_VERSION+set}"; then 2010ef0e59aSmrg setopt NO_GLOB_SUBST 2020ef0e59aSmrgfi 2030ef0e59aSmrg 2040ef0e59aSmrg_LT_CHECK_OBJDIR 2050ef0e59aSmrg 2060ef0e59aSmrgm4_require([_LT_TAG_COMPILER])dnl 2070ef0e59aSmrg 2080ef0e59aSmrgcase $host_os in 2090ef0e59aSmrgaix3*) 2100ef0e59aSmrg # AIX sometimes has problems with the GCC collect2 program. For some 2110ef0e59aSmrg # reason, if we set the COLLECT_NAMES environment variable, the problems 2120ef0e59aSmrg # vanish in a puff of smoke. 2130ef0e59aSmrg if test set != "${COLLECT_NAMES+set}"; then 2140ef0e59aSmrg COLLECT_NAMES= 2150ef0e59aSmrg export COLLECT_NAMES 2160ef0e59aSmrg fi 2170ef0e59aSmrg ;; 2180ef0e59aSmrgesac 2190ef0e59aSmrg 2200ef0e59aSmrg# Global variables: 2210ef0e59aSmrgofile=libtool 2220ef0e59aSmrgcan_build_shared=yes 2230ef0e59aSmrg 22415885c33Smrg# All known linkers require a '.a' archive for static linking (except MSVC and 22515885c33Smrg# ICC, which need '.lib'). 2260ef0e59aSmrglibext=a 2270ef0e59aSmrg 2280ef0e59aSmrgwith_gnu_ld=$lt_cv_prog_gnu_ld 2290ef0e59aSmrg 2300ef0e59aSmrgold_CC=$CC 2310ef0e59aSmrgold_CFLAGS=$CFLAGS 2320ef0e59aSmrg 2330ef0e59aSmrg# Set sane defaults for various variables 2340ef0e59aSmrgtest -z "$CC" && CC=cc 2350ef0e59aSmrgtest -z "$LTCC" && LTCC=$CC 2360ef0e59aSmrgtest -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS 2370ef0e59aSmrgtest -z "$LD" && LD=ld 2380ef0e59aSmrgtest -z "$ac_objext" && ac_objext=o 2390ef0e59aSmrg 2400ef0e59aSmrg_LT_CC_BASENAME([$compiler]) 2410ef0e59aSmrg 2420ef0e59aSmrg# Only perform the check for file, if the check method requires it 2430ef0e59aSmrgtest -z "$MAGIC_CMD" && MAGIC_CMD=file 2440ef0e59aSmrgcase $deplibs_check_method in 2450ef0e59aSmrgfile_magic*) 2460ef0e59aSmrg if test "$file_magic_cmd" = '$MAGIC_CMD'; then 2470ef0e59aSmrg _LT_PATH_MAGIC 2480ef0e59aSmrg fi 2490ef0e59aSmrg ;; 2500ef0e59aSmrgesac 2510ef0e59aSmrg 2520ef0e59aSmrg# Use C for the default configuration in the libtool script 2530ef0e59aSmrgLT_SUPPORTED_TAG([CC]) 2540ef0e59aSmrg_LT_LANG_C_CONFIG 2550ef0e59aSmrg_LT_LANG_DEFAULT_CONFIG 2560ef0e59aSmrg_LT_CONFIG_COMMANDS 2570ef0e59aSmrg])# _LT_SETUP 2580ef0e59aSmrg 2590ef0e59aSmrg 2600ef0e59aSmrg# _LT_PREPARE_SED_QUOTE_VARS 2610ef0e59aSmrg# -------------------------- 2620ef0e59aSmrg# Define a few sed substitution that help us do robust quoting. 2630ef0e59aSmrgm4_defun([_LT_PREPARE_SED_QUOTE_VARS], 2640ef0e59aSmrg[# Backslashify metacharacters that are still active within 2650ef0e59aSmrg# double-quoted strings. 2660ef0e59aSmrgsed_quote_subst='s/\([["`$\\]]\)/\\\1/g' 2670ef0e59aSmrg 2680ef0e59aSmrg# Same as above, but do not quote variable references. 2690ef0e59aSmrgdouble_quote_subst='s/\([["`\\]]\)/\\\1/g' 2700ef0e59aSmrg 2710ef0e59aSmrg# Sed substitution to delay expansion of an escaped shell variable in a 2720ef0e59aSmrg# double_quote_subst'ed string. 2730ef0e59aSmrgdelay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' 2740ef0e59aSmrg 2750ef0e59aSmrg# Sed substitution to delay expansion of an escaped single quote. 2760ef0e59aSmrgdelay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g' 2770ef0e59aSmrg 2780ef0e59aSmrg# Sed substitution to avoid accidental globbing in evaled expressions 2790ef0e59aSmrgno_glob_subst='s/\*/\\\*/g' 2800ef0e59aSmrg]) 2810ef0e59aSmrg 2820ef0e59aSmrg# _LT_PROG_LTMAIN 2830ef0e59aSmrg# --------------- 2840ef0e59aSmrg# Note that this code is called both from 'configure', and 'config.status' 2850ef0e59aSmrg# now that we use AC_CONFIG_COMMANDS to generate libtool. Notably, 2860ef0e59aSmrg# 'config.status' has no value for ac_aux_dir unless we are using Automake, 2870ef0e59aSmrg# so we pass a copy along to make sure it has a sensible value anyway. 2880ef0e59aSmrgm4_defun([_LT_PROG_LTMAIN], 2890ef0e59aSmrg[m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl 2900ef0e59aSmrg_LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir']) 2910ef0e59aSmrgltmain=$ac_aux_dir/ltmain.sh 2920ef0e59aSmrg])# _LT_PROG_LTMAIN 2930ef0e59aSmrg 2940ef0e59aSmrg 2950ef0e59aSmrg## ------------------------------------- ## 2960ef0e59aSmrg## Accumulate code for creating libtool. ## 2970ef0e59aSmrg## ------------------------------------- ## 2980ef0e59aSmrg 2990ef0e59aSmrg# So that we can recreate a full libtool script including additional 3000ef0e59aSmrg# tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS 3010ef0e59aSmrg# in macros and then make a single call at the end using the 'libtool' 3020ef0e59aSmrg# label. 3030ef0e59aSmrg 3040ef0e59aSmrg 3050ef0e59aSmrg# _LT_CONFIG_LIBTOOL_INIT([INIT-COMMANDS]) 3060ef0e59aSmrg# ---------------------------------------- 3070ef0e59aSmrg# Register INIT-COMMANDS to be passed to AC_CONFIG_COMMANDS later. 3080ef0e59aSmrgm4_define([_LT_CONFIG_LIBTOOL_INIT], 3090ef0e59aSmrg[m4_ifval([$1], 3100ef0e59aSmrg [m4_append([_LT_OUTPUT_LIBTOOL_INIT], 3110ef0e59aSmrg [$1 3120ef0e59aSmrg])])]) 3130ef0e59aSmrg 3140ef0e59aSmrg# Initialize. 3150ef0e59aSmrgm4_define([_LT_OUTPUT_LIBTOOL_INIT]) 3160ef0e59aSmrg 3170ef0e59aSmrg 3180ef0e59aSmrg# _LT_CONFIG_LIBTOOL([COMMANDS]) 3190ef0e59aSmrg# ------------------------------ 3200ef0e59aSmrg# Register COMMANDS to be passed to AC_CONFIG_COMMANDS later. 3210ef0e59aSmrgm4_define([_LT_CONFIG_LIBTOOL], 3220ef0e59aSmrg[m4_ifval([$1], 3230ef0e59aSmrg [m4_append([_LT_OUTPUT_LIBTOOL_COMMANDS], 3240ef0e59aSmrg [$1 3250ef0e59aSmrg])])]) 3260ef0e59aSmrg 3270ef0e59aSmrg# Initialize. 3280ef0e59aSmrgm4_define([_LT_OUTPUT_LIBTOOL_COMMANDS]) 3290ef0e59aSmrg 3300ef0e59aSmrg 3310ef0e59aSmrg# _LT_CONFIG_SAVE_COMMANDS([COMMANDS], [INIT_COMMANDS]) 3320ef0e59aSmrg# ----------------------------------------------------- 3330ef0e59aSmrgm4_defun([_LT_CONFIG_SAVE_COMMANDS], 3340ef0e59aSmrg[_LT_CONFIG_LIBTOOL([$1]) 3350ef0e59aSmrg_LT_CONFIG_LIBTOOL_INIT([$2]) 3360ef0e59aSmrg]) 3370ef0e59aSmrg 3380ef0e59aSmrg 3390ef0e59aSmrg# _LT_FORMAT_COMMENT([COMMENT]) 3400ef0e59aSmrg# ----------------------------- 3410ef0e59aSmrg# Add leading comment marks to the start of each line, and a trailing 3420ef0e59aSmrg# full-stop to the whole comment if one is not present already. 3430ef0e59aSmrgm4_define([_LT_FORMAT_COMMENT], 3440ef0e59aSmrg[m4_ifval([$1], [ 3450ef0e59aSmrgm4_bpatsubst([m4_bpatsubst([$1], [^ *], [# ])], 3460ef0e59aSmrg [['`$\]], [\\\&])]m4_bmatch([$1], [[!?.]$], [], [.]) 3470ef0e59aSmrg)]) 3480ef0e59aSmrg 3490ef0e59aSmrg 3500ef0e59aSmrg 3510ef0e59aSmrg## ------------------------ ## 3520ef0e59aSmrg## FIXME: Eliminate VARNAME ## 3530ef0e59aSmrg## ------------------------ ## 3540ef0e59aSmrg 3550ef0e59aSmrg 3560ef0e59aSmrg# _LT_DECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION], [IS-TAGGED?]) 3570ef0e59aSmrg# ------------------------------------------------------------------- 3580ef0e59aSmrg# CONFIGNAME is the name given to the value in the libtool script. 3590ef0e59aSmrg# VARNAME is the (base) name used in the configure script. 3600ef0e59aSmrg# VALUE may be 0, 1 or 2 for a computed quote escaped value based on 3610ef0e59aSmrg# VARNAME. Any other value will be used directly. 3620ef0e59aSmrgm4_define([_LT_DECL], 3630ef0e59aSmrg[lt_if_append_uniq([lt_decl_varnames], [$2], [, ], 3640ef0e59aSmrg [lt_dict_add_subkey([lt_decl_dict], [$2], [libtool_name], 3650ef0e59aSmrg [m4_ifval([$1], [$1], [$2])]) 3660ef0e59aSmrg lt_dict_add_subkey([lt_decl_dict], [$2], [value], [$3]) 3670ef0e59aSmrg m4_ifval([$4], 3680ef0e59aSmrg [lt_dict_add_subkey([lt_decl_dict], [$2], [description], [$4])]) 3690ef0e59aSmrg lt_dict_add_subkey([lt_decl_dict], [$2], 3700ef0e59aSmrg [tagged?], [m4_ifval([$5], [yes], [no])])]) 3710ef0e59aSmrg]) 3720ef0e59aSmrg 3730ef0e59aSmrg 3740ef0e59aSmrg# _LT_TAGDECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION]) 3750ef0e59aSmrg# -------------------------------------------------------- 3760ef0e59aSmrgm4_define([_LT_TAGDECL], [_LT_DECL([$1], [$2], [$3], [$4], [yes])]) 3770ef0e59aSmrg 3780ef0e59aSmrg 3790ef0e59aSmrg# lt_decl_tag_varnames([SEPARATOR], [VARNAME1...]) 3800ef0e59aSmrg# ------------------------------------------------ 3810ef0e59aSmrgm4_define([lt_decl_tag_varnames], 3820ef0e59aSmrg[_lt_decl_filter([tagged?], [yes], $@)]) 3830ef0e59aSmrg 3840ef0e59aSmrg 3850ef0e59aSmrg# _lt_decl_filter(SUBKEY, VALUE, [SEPARATOR], [VARNAME1..]) 3860ef0e59aSmrg# --------------------------------------------------------- 3870ef0e59aSmrgm4_define([_lt_decl_filter], 3880ef0e59aSmrg[m4_case([$#], 3890ef0e59aSmrg [0], [m4_fatal([$0: too few arguments: $#])], 3900ef0e59aSmrg [1], [m4_fatal([$0: too few arguments: $#: $1])], 3910ef0e59aSmrg [2], [lt_dict_filter([lt_decl_dict], [$1], [$2], [], lt_decl_varnames)], 3920ef0e59aSmrg [3], [lt_dict_filter([lt_decl_dict], [$1], [$2], [$3], lt_decl_varnames)], 3930ef0e59aSmrg [lt_dict_filter([lt_decl_dict], $@)])[]dnl 3940ef0e59aSmrg]) 3950ef0e59aSmrg 3960ef0e59aSmrg 3970ef0e59aSmrg# lt_decl_quote_varnames([SEPARATOR], [VARNAME1...]) 3980ef0e59aSmrg# -------------------------------------------------- 3990ef0e59aSmrgm4_define([lt_decl_quote_varnames], 4000ef0e59aSmrg[_lt_decl_filter([value], [1], $@)]) 4010ef0e59aSmrg 4020ef0e59aSmrg 4030ef0e59aSmrg# lt_decl_dquote_varnames([SEPARATOR], [VARNAME1...]) 4040ef0e59aSmrg# --------------------------------------------------- 4050ef0e59aSmrgm4_define([lt_decl_dquote_varnames], 4060ef0e59aSmrg[_lt_decl_filter([value], [2], $@)]) 4070ef0e59aSmrg 4080ef0e59aSmrg 4090ef0e59aSmrg# lt_decl_varnames_tagged([SEPARATOR], [VARNAME1...]) 4100ef0e59aSmrg# --------------------------------------------------- 4110ef0e59aSmrgm4_define([lt_decl_varnames_tagged], 4120ef0e59aSmrg[m4_assert([$# <= 2])dnl 4130ef0e59aSmrg_$0(m4_quote(m4_default([$1], [[, ]])), 4140ef0e59aSmrg m4_ifval([$2], [[$2]], [m4_dquote(lt_decl_tag_varnames)]), 4150ef0e59aSmrg m4_split(m4_normalize(m4_quote(_LT_TAGS)), [ ]))]) 4160ef0e59aSmrgm4_define([_lt_decl_varnames_tagged], 4170ef0e59aSmrg[m4_ifval([$3], [lt_combine([$1], [$2], [_], $3)])]) 4180ef0e59aSmrg 4190ef0e59aSmrg 4200ef0e59aSmrg# lt_decl_all_varnames([SEPARATOR], [VARNAME1...]) 4210ef0e59aSmrg# ------------------------------------------------ 4220ef0e59aSmrgm4_define([lt_decl_all_varnames], 4230ef0e59aSmrg[_$0(m4_quote(m4_default([$1], [[, ]])), 4240ef0e59aSmrg m4_if([$2], [], 4250ef0e59aSmrg m4_quote(lt_decl_varnames), 4260ef0e59aSmrg m4_quote(m4_shift($@))))[]dnl 4270ef0e59aSmrg]) 4280ef0e59aSmrgm4_define([_lt_decl_all_varnames], 4290ef0e59aSmrg[lt_join($@, lt_decl_varnames_tagged([$1], 4300ef0e59aSmrg lt_decl_tag_varnames([[, ]], m4_shift($@))))dnl 4310ef0e59aSmrg]) 4320ef0e59aSmrg 4330ef0e59aSmrg 4340ef0e59aSmrg# _LT_CONFIG_STATUS_DECLARE([VARNAME]) 4350ef0e59aSmrg# ------------------------------------ 4360ef0e59aSmrg# Quote a variable value, and forward it to 'config.status' so that its 4370ef0e59aSmrg# declaration there will have the same value as in 'configure'. VARNAME 4380ef0e59aSmrg# must have a single quote delimited value for this to work. 4390ef0e59aSmrgm4_define([_LT_CONFIG_STATUS_DECLARE], 4400ef0e59aSmrg[$1='`$ECHO "$][$1" | $SED "$delay_single_quote_subst"`']) 4410ef0e59aSmrg 4420ef0e59aSmrg 4430ef0e59aSmrg# _LT_CONFIG_STATUS_DECLARATIONS 4440ef0e59aSmrg# ------------------------------ 4450ef0e59aSmrg# We delimit libtool config variables with single quotes, so when 4460ef0e59aSmrg# we write them to config.status, we have to be sure to quote all 4470ef0e59aSmrg# embedded single quotes properly. In configure, this macro expands 4480ef0e59aSmrg# each variable declared with _LT_DECL (and _LT_TAGDECL) into: 4490ef0e59aSmrg# 4500ef0e59aSmrg# <var>='`$ECHO "$<var>" | $SED "$delay_single_quote_subst"`' 4510ef0e59aSmrgm4_defun([_LT_CONFIG_STATUS_DECLARATIONS], 4520ef0e59aSmrg[m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames), 4530ef0e59aSmrg [m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])]) 4540ef0e59aSmrg 4550ef0e59aSmrg 4560ef0e59aSmrg# _LT_LIBTOOL_TAGS 4570ef0e59aSmrg# ---------------- 4580ef0e59aSmrg# Output comment and list of tags supported by the script 4590ef0e59aSmrgm4_defun([_LT_LIBTOOL_TAGS], 4600ef0e59aSmrg[_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl 4610ef0e59aSmrgavailable_tags='_LT_TAGS'dnl 4620ef0e59aSmrg]) 4630ef0e59aSmrg 4640ef0e59aSmrg 4650ef0e59aSmrg# _LT_LIBTOOL_DECLARE(VARNAME, [TAG]) 4660ef0e59aSmrg# ----------------------------------- 4670ef0e59aSmrg# Extract the dictionary values for VARNAME (optionally with TAG) and 4680ef0e59aSmrg# expand to a commented shell variable setting: 4690ef0e59aSmrg# 4700ef0e59aSmrg# # Some comment about what VAR is for. 4710ef0e59aSmrg# visible_name=$lt_internal_name 4720ef0e59aSmrgm4_define([_LT_LIBTOOL_DECLARE], 4730ef0e59aSmrg[_LT_FORMAT_COMMENT(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], 4740ef0e59aSmrg [description])))[]dnl 4750ef0e59aSmrgm4_pushdef([_libtool_name], 4760ef0e59aSmrg m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [libtool_name])))[]dnl 4770ef0e59aSmrgm4_case(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [value])), 4780ef0e59aSmrg [0], [_libtool_name=[$]$1], 4790ef0e59aSmrg [1], [_libtool_name=$lt_[]$1], 4800ef0e59aSmrg [2], [_libtool_name=$lt_[]$1], 4810ef0e59aSmrg [_libtool_name=lt_dict_fetch([lt_decl_dict], [$1], [value])])[]dnl 4820ef0e59aSmrgm4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl 4830ef0e59aSmrg]) 4840ef0e59aSmrg 4850ef0e59aSmrg 4860ef0e59aSmrg# _LT_LIBTOOL_CONFIG_VARS 4870ef0e59aSmrg# ----------------------- 4880ef0e59aSmrg# Produce commented declarations of non-tagged libtool config variables 4890ef0e59aSmrg# suitable for insertion in the LIBTOOL CONFIG section of the 'libtool' 4900ef0e59aSmrg# script. Tagged libtool config variables (even for the LIBTOOL CONFIG 4910ef0e59aSmrg# section) are produced by _LT_LIBTOOL_TAG_VARS. 4920ef0e59aSmrgm4_defun([_LT_LIBTOOL_CONFIG_VARS], 4930ef0e59aSmrg[m4_foreach([_lt_var], 4940ef0e59aSmrg m4_quote(_lt_decl_filter([tagged?], [no], [], lt_decl_varnames)), 4950ef0e59aSmrg [m4_n([_LT_LIBTOOL_DECLARE(_lt_var)])])]) 4960ef0e59aSmrg 4970ef0e59aSmrg 4980ef0e59aSmrg# _LT_LIBTOOL_TAG_VARS(TAG) 4990ef0e59aSmrg# ------------------------- 5000ef0e59aSmrgm4_define([_LT_LIBTOOL_TAG_VARS], 5010ef0e59aSmrg[m4_foreach([_lt_var], m4_quote(lt_decl_tag_varnames), 5020ef0e59aSmrg [m4_n([_LT_LIBTOOL_DECLARE(_lt_var, [$1])])])]) 5030ef0e59aSmrg 5040ef0e59aSmrg 5050ef0e59aSmrg# _LT_TAGVAR(VARNAME, [TAGNAME]) 5060ef0e59aSmrg# ------------------------------ 5070ef0e59aSmrgm4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])]) 5080ef0e59aSmrg 5090ef0e59aSmrg 5100ef0e59aSmrg# _LT_CONFIG_COMMANDS 5110ef0e59aSmrg# ------------------- 5120ef0e59aSmrg# Send accumulated output to $CONFIG_STATUS. Thanks to the lists of 5130ef0e59aSmrg# variables for single and double quote escaping we saved from calls 5140ef0e59aSmrg# to _LT_DECL, we can put quote escaped variables declarations 5150ef0e59aSmrg# into 'config.status', and then the shell code to quote escape them in 5160ef0e59aSmrg# for loops in 'config.status'. Finally, any additional code accumulated 5170ef0e59aSmrg# from calls to _LT_CONFIG_LIBTOOL_INIT is expanded. 5180ef0e59aSmrgm4_defun([_LT_CONFIG_COMMANDS], 5190ef0e59aSmrg[AC_PROVIDE_IFELSE([LT_OUTPUT], 5200ef0e59aSmrg dnl If the libtool generation code has been placed in $CONFIG_LT, 5210ef0e59aSmrg dnl instead of duplicating it all over again into config.status, 5220ef0e59aSmrg dnl then we will have config.status run $CONFIG_LT later, so it 5230ef0e59aSmrg dnl needs to know what name is stored there: 5240ef0e59aSmrg [AC_CONFIG_COMMANDS([libtool], 5250ef0e59aSmrg [$SHELL $CONFIG_LT || AS_EXIT(1)], [CONFIG_LT='$CONFIG_LT'])], 5260ef0e59aSmrg dnl If the libtool generation code is destined for config.status, 5270ef0e59aSmrg dnl expand the accumulated commands and init code now: 5280ef0e59aSmrg [AC_CONFIG_COMMANDS([libtool], 5290ef0e59aSmrg [_LT_OUTPUT_LIBTOOL_COMMANDS], [_LT_OUTPUT_LIBTOOL_COMMANDS_INIT])]) 5300ef0e59aSmrg])#_LT_CONFIG_COMMANDS 5310ef0e59aSmrg 5320ef0e59aSmrg 5330ef0e59aSmrg# Initialize. 5340ef0e59aSmrgm4_define([_LT_OUTPUT_LIBTOOL_COMMANDS_INIT], 5350ef0e59aSmrg[ 5360ef0e59aSmrg 5370ef0e59aSmrg# The HP-UX ksh and POSIX shell print the target directory to stdout 5380ef0e59aSmrg# if CDPATH is set. 5390ef0e59aSmrg(unset CDPATH) >/dev/null 2>&1 && unset CDPATH 5400ef0e59aSmrg 5410ef0e59aSmrgsed_quote_subst='$sed_quote_subst' 5420ef0e59aSmrgdouble_quote_subst='$double_quote_subst' 5430ef0e59aSmrgdelay_variable_subst='$delay_variable_subst' 5440ef0e59aSmrg_LT_CONFIG_STATUS_DECLARATIONS 5450ef0e59aSmrgLTCC='$LTCC' 5460ef0e59aSmrgLTCFLAGS='$LTCFLAGS' 5470ef0e59aSmrgcompiler='$compiler_DEFAULT' 5480ef0e59aSmrg 5490ef0e59aSmrg# A function that is used when there is no print builtin or printf. 5500ef0e59aSmrgfunc_fallback_echo () 5510ef0e59aSmrg{ 5520ef0e59aSmrg eval 'cat <<_LTECHO_EOF 5530ef0e59aSmrg\$[]1 5540ef0e59aSmrg_LTECHO_EOF' 5550ef0e59aSmrg} 5560ef0e59aSmrg 5570ef0e59aSmrg# Quote evaled strings. 5580ef0e59aSmrgfor var in lt_decl_all_varnames([[ \ 5590ef0e59aSmrg]], lt_decl_quote_varnames); do 5600ef0e59aSmrg case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in 5610ef0e59aSmrg *[[\\\\\\\`\\"\\\$]]*) 5620ef0e59aSmrg eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes 5630ef0e59aSmrg ;; 5640ef0e59aSmrg *) 5650ef0e59aSmrg eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" 5660ef0e59aSmrg ;; 5670ef0e59aSmrg esac 5680ef0e59aSmrgdone 5690ef0e59aSmrg 5700ef0e59aSmrg# Double-quote double-evaled strings. 5710ef0e59aSmrgfor var in lt_decl_all_varnames([[ \ 5720ef0e59aSmrg]], lt_decl_dquote_varnames); do 5730ef0e59aSmrg case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in 5740ef0e59aSmrg *[[\\\\\\\`\\"\\\$]]*) 5750ef0e59aSmrg eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes 5760ef0e59aSmrg ;; 5770ef0e59aSmrg *) 5780ef0e59aSmrg eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" 5790ef0e59aSmrg ;; 5800ef0e59aSmrg esac 5810ef0e59aSmrgdone 5820ef0e59aSmrg 5830ef0e59aSmrg_LT_OUTPUT_LIBTOOL_INIT 5840ef0e59aSmrg]) 5850ef0e59aSmrg 5860ef0e59aSmrg# _LT_GENERATED_FILE_INIT(FILE, [COMMENT]) 5870ef0e59aSmrg# ------------------------------------ 5880ef0e59aSmrg# Generate a child script FILE with all initialization necessary to 5890ef0e59aSmrg# reuse the environment learned by the parent script, and make the 5900ef0e59aSmrg# file executable. If COMMENT is supplied, it is inserted after the 5910ef0e59aSmrg# '#!' sequence but before initialization text begins. After this 5920ef0e59aSmrg# macro, additional text can be appended to FILE to form the body of 5930ef0e59aSmrg# the child script. The macro ends with non-zero status if the 5940ef0e59aSmrg# file could not be fully written (such as if the disk is full). 5950ef0e59aSmrgm4_ifdef([AS_INIT_GENERATED], 5960ef0e59aSmrg[m4_defun([_LT_GENERATED_FILE_INIT],[AS_INIT_GENERATED($@)])], 5970ef0e59aSmrg[m4_defun([_LT_GENERATED_FILE_INIT], 5980ef0e59aSmrg[m4_require([AS_PREPARE])]dnl 5990ef0e59aSmrg[m4_pushdef([AS_MESSAGE_LOG_FD])]dnl 6000ef0e59aSmrg[lt_write_fail=0 6010ef0e59aSmrgcat >$1 <<_ASEOF || lt_write_fail=1 6020ef0e59aSmrg#! $SHELL 6030ef0e59aSmrg# Generated by $as_me. 6040ef0e59aSmrg$2 6050ef0e59aSmrgSHELL=\${CONFIG_SHELL-$SHELL} 6060ef0e59aSmrgexport SHELL 6070ef0e59aSmrg_ASEOF 6080ef0e59aSmrgcat >>$1 <<\_ASEOF || lt_write_fail=1 6090ef0e59aSmrgAS_SHELL_SANITIZE 6100ef0e59aSmrg_AS_PREPARE 6110ef0e59aSmrgexec AS_MESSAGE_FD>&1 6120ef0e59aSmrg_ASEOF 6130ef0e59aSmrgtest 0 = "$lt_write_fail" && chmod +x $1[]dnl 6140ef0e59aSmrgm4_popdef([AS_MESSAGE_LOG_FD])])])# _LT_GENERATED_FILE_INIT 6150ef0e59aSmrg 6160ef0e59aSmrg# LT_OUTPUT 6170ef0e59aSmrg# --------- 6180ef0e59aSmrg# This macro allows early generation of the libtool script (before 619d5e6aabbSmrg# AC_OUTPUT is called), in case it is used in configure for compilation 6200ef0e59aSmrg# tests. 6210ef0e59aSmrgAC_DEFUN([LT_OUTPUT], 6220ef0e59aSmrg[: ${CONFIG_LT=./config.lt} 6230ef0e59aSmrgAC_MSG_NOTICE([creating $CONFIG_LT]) 6240ef0e59aSmrg_LT_GENERATED_FILE_INIT(["$CONFIG_LT"], 6250ef0e59aSmrg[# Run this file to recreate a libtool stub with the current configuration.]) 6260ef0e59aSmrg 6270ef0e59aSmrgcat >>"$CONFIG_LT" <<\_LTEOF 6280ef0e59aSmrglt_cl_silent=false 6290ef0e59aSmrgexec AS_MESSAGE_LOG_FD>>config.log 6300ef0e59aSmrg{ 6310ef0e59aSmrg echo 6320ef0e59aSmrg AS_BOX([Running $as_me.]) 6330ef0e59aSmrg} >&AS_MESSAGE_LOG_FD 6340ef0e59aSmrg 6350ef0e59aSmrglt_cl_help="\ 6360ef0e59aSmrg'$as_me' creates a local libtool stub from the current configuration, 6370ef0e59aSmrgfor use in further configure time tests before the real libtool is 6380ef0e59aSmrggenerated. 6390ef0e59aSmrg 6400ef0e59aSmrgUsage: $[0] [[OPTIONS]] 6410ef0e59aSmrg 6420ef0e59aSmrg -h, --help print this help, then exit 6430ef0e59aSmrg -V, --version print version number, then exit 6440ef0e59aSmrg -q, --quiet do not print progress messages 6450ef0e59aSmrg -d, --debug don't remove temporary files 6460ef0e59aSmrg 6470ef0e59aSmrgReport bugs to <bug-libtool@gnu.org>." 6480ef0e59aSmrg 6490ef0e59aSmrglt_cl_version="\ 6500ef0e59aSmrgm4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl 6510ef0e59aSmrgm4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION]) 6520ef0e59aSmrgconfigured by $[0], generated by m4_PACKAGE_STRING. 6530ef0e59aSmrg 654d5e6aabbSmrgCopyright (C) 2024 Free Software Foundation, Inc. 6550ef0e59aSmrgThis config.lt script is free software; the Free Software Foundation 656d5e6aabbSmrggives unlimited permission to copy, distribute and modify it." 6570ef0e59aSmrg 6580ef0e59aSmrgwhile test 0 != $[#] 6590ef0e59aSmrgdo 6600ef0e59aSmrg case $[1] in 6610ef0e59aSmrg --version | --v* | -V ) 6620ef0e59aSmrg echo "$lt_cl_version"; exit 0 ;; 6630ef0e59aSmrg --help | --h* | -h ) 6640ef0e59aSmrg echo "$lt_cl_help"; exit 0 ;; 6650ef0e59aSmrg --debug | --d* | -d ) 6660ef0e59aSmrg debug=: ;; 6670ef0e59aSmrg --quiet | --q* | --silent | --s* | -q ) 6680ef0e59aSmrg lt_cl_silent=: ;; 6690ef0e59aSmrg 6700ef0e59aSmrg -*) AC_MSG_ERROR([unrecognized option: $[1] 6710ef0e59aSmrgTry '$[0] --help' for more information.]) ;; 6720ef0e59aSmrg 6730ef0e59aSmrg *) AC_MSG_ERROR([unrecognized argument: $[1] 6740ef0e59aSmrgTry '$[0] --help' for more information.]) ;; 6750ef0e59aSmrg esac 6760ef0e59aSmrg shift 6770ef0e59aSmrgdone 6780ef0e59aSmrg 6790ef0e59aSmrgif $lt_cl_silent; then 6800ef0e59aSmrg exec AS_MESSAGE_FD>/dev/null 6810ef0e59aSmrgfi 6820ef0e59aSmrg_LTEOF 6830ef0e59aSmrg 6840ef0e59aSmrgcat >>"$CONFIG_LT" <<_LTEOF 6850ef0e59aSmrg_LT_OUTPUT_LIBTOOL_COMMANDS_INIT 6860ef0e59aSmrg_LTEOF 6870ef0e59aSmrg 6880ef0e59aSmrgcat >>"$CONFIG_LT" <<\_LTEOF 6890ef0e59aSmrgAC_MSG_NOTICE([creating $ofile]) 6900ef0e59aSmrg_LT_OUTPUT_LIBTOOL_COMMANDS 6910ef0e59aSmrgAS_EXIT(0) 6920ef0e59aSmrg_LTEOF 6930ef0e59aSmrgchmod +x "$CONFIG_LT" 6940ef0e59aSmrg 6950ef0e59aSmrg# configure is writing to config.log, but config.lt does its own redirection, 6960ef0e59aSmrg# appending to config.log, which fails on DOS, as config.log is still kept 6970ef0e59aSmrg# open by configure. Here we exec the FD to /dev/null, effectively closing 6980ef0e59aSmrg# config.log, so it can be properly (re)opened and appended to by config.lt. 6990ef0e59aSmrglt_cl_success=: 7000ef0e59aSmrgtest yes = "$silent" && 7010ef0e59aSmrg lt_config_lt_args="$lt_config_lt_args --quiet" 7020ef0e59aSmrgexec AS_MESSAGE_LOG_FD>/dev/null 7030ef0e59aSmrg$SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false 7040ef0e59aSmrgexec AS_MESSAGE_LOG_FD>>config.log 7050ef0e59aSmrg$lt_cl_success || AS_EXIT(1) 7060ef0e59aSmrg])# LT_OUTPUT 7070ef0e59aSmrg 7080ef0e59aSmrg 7090ef0e59aSmrg# _LT_CONFIG(TAG) 7100ef0e59aSmrg# --------------- 7110ef0e59aSmrg# If TAG is the built-in tag, create an initial libtool script with a 7120ef0e59aSmrg# default configuration from the untagged config vars. Otherwise add code 7130ef0e59aSmrg# to config.status for appending the configuration named by TAG from the 7140ef0e59aSmrg# matching tagged config vars. 7150ef0e59aSmrgm4_defun([_LT_CONFIG], 7160ef0e59aSmrg[m4_require([_LT_FILEUTILS_DEFAULTS])dnl 7170ef0e59aSmrg_LT_CONFIG_SAVE_COMMANDS([ 7180ef0e59aSmrg m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl 7190ef0e59aSmrg m4_if(_LT_TAG, [C], [ 7200ef0e59aSmrg # See if we are running on zsh, and set the options that allow our 7210ef0e59aSmrg # commands through without removal of \ escapes. 7220ef0e59aSmrg if test -n "${ZSH_VERSION+set}"; then 7230ef0e59aSmrg setopt NO_GLOB_SUBST 7240ef0e59aSmrg fi 7250ef0e59aSmrg 7260ef0e59aSmrg cfgfile=${ofile}T 7270ef0e59aSmrg trap "$RM \"$cfgfile\"; exit 1" 1 2 15 7280ef0e59aSmrg $RM "$cfgfile" 7290ef0e59aSmrg 7300ef0e59aSmrg cat <<_LT_EOF >> "$cfgfile" 7310ef0e59aSmrg#! $SHELL 7320ef0e59aSmrg# Generated automatically by $as_me ($PACKAGE) $VERSION 7330ef0e59aSmrg# NOTE: Changes made to this file will be lost: look at ltmain.sh. 7340ef0e59aSmrg 7350ef0e59aSmrg# Provide generalized library-building support services. 7360ef0e59aSmrg# Written by Gordon Matzigkeit, 1996 7370ef0e59aSmrg 7380ef0e59aSmrg_LT_COPYING 7390ef0e59aSmrg_LT_LIBTOOL_TAGS 7400ef0e59aSmrg 7410ef0e59aSmrg# Configured defaults for sys_lib_dlsearch_path munging. 7420ef0e59aSmrg: \${LT_SYS_LIBRARY_PATH="$configure_time_lt_sys_library_path"} 7430ef0e59aSmrg 7440ef0e59aSmrg# ### BEGIN LIBTOOL CONFIG 7450ef0e59aSmrg_LT_LIBTOOL_CONFIG_VARS 7460ef0e59aSmrg_LT_LIBTOOL_TAG_VARS 7470ef0e59aSmrg# ### END LIBTOOL CONFIG 7480ef0e59aSmrg 7490ef0e59aSmrg_LT_EOF 7500ef0e59aSmrg 7510ef0e59aSmrg cat <<'_LT_EOF' >> "$cfgfile" 7520ef0e59aSmrg 7530ef0e59aSmrg# ### BEGIN FUNCTIONS SHARED WITH CONFIGURE 7540ef0e59aSmrg 7550ef0e59aSmrg_LT_PREPARE_MUNGE_PATH_LIST 7560ef0e59aSmrg_LT_PREPARE_CC_BASENAME 7570ef0e59aSmrg 7580ef0e59aSmrg# ### END FUNCTIONS SHARED WITH CONFIGURE 7590ef0e59aSmrg 7600ef0e59aSmrg_LT_EOF 7610ef0e59aSmrg 7620ef0e59aSmrg case $host_os in 7630ef0e59aSmrg aix3*) 7640ef0e59aSmrg cat <<\_LT_EOF >> "$cfgfile" 7650ef0e59aSmrg# AIX sometimes has problems with the GCC collect2 program. For some 7660ef0e59aSmrg# reason, if we set the COLLECT_NAMES environment variable, the problems 7670ef0e59aSmrg# vanish in a puff of smoke. 7680ef0e59aSmrgif test set != "${COLLECT_NAMES+set}"; then 7690ef0e59aSmrg COLLECT_NAMES= 7700ef0e59aSmrg export COLLECT_NAMES 7710ef0e59aSmrgfi 7720ef0e59aSmrg_LT_EOF 7730ef0e59aSmrg ;; 7740ef0e59aSmrg esac 7750ef0e59aSmrg 7760ef0e59aSmrg _LT_PROG_LTMAIN 7770ef0e59aSmrg 7780ef0e59aSmrg # We use sed instead of cat because bash on DJGPP gets confused if 7790ef0e59aSmrg # if finds mixed CR/LF and LF-only lines. Since sed operates in 7800ef0e59aSmrg # text mode, it properly converts lines to CR/LF. This bash problem 7810ef0e59aSmrg # is reportedly fixed, but why not run on old versions too? 78215885c33Smrg $SED '$q' "$ltmain" >> "$cfgfile" \ 7830ef0e59aSmrg || (rm -f "$cfgfile"; exit 1) 7840ef0e59aSmrg 7850ef0e59aSmrg mv -f "$cfgfile" "$ofile" || 7860ef0e59aSmrg (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") 7870ef0e59aSmrg chmod +x "$ofile" 7880ef0e59aSmrg], 7890ef0e59aSmrg[cat <<_LT_EOF >> "$ofile" 7900ef0e59aSmrg 7910ef0e59aSmrgdnl Unfortunately we have to use $1 here, since _LT_TAG is not expanded 7920ef0e59aSmrgdnl in a comment (ie after a #). 7930ef0e59aSmrg# ### BEGIN LIBTOOL TAG CONFIG: $1 7940ef0e59aSmrg_LT_LIBTOOL_TAG_VARS(_LT_TAG) 7950ef0e59aSmrg# ### END LIBTOOL TAG CONFIG: $1 7960ef0e59aSmrg_LT_EOF 7970ef0e59aSmrg])dnl /m4_if 7980ef0e59aSmrg], 7990ef0e59aSmrg[m4_if([$1], [], [ 8000ef0e59aSmrg PACKAGE='$PACKAGE' 8010ef0e59aSmrg VERSION='$VERSION' 8020ef0e59aSmrg RM='$RM' 8030ef0e59aSmrg ofile='$ofile'], []) 8040ef0e59aSmrg])dnl /_LT_CONFIG_SAVE_COMMANDS 8050ef0e59aSmrg])# _LT_CONFIG 8060ef0e59aSmrg 8070ef0e59aSmrg 8080ef0e59aSmrg# LT_SUPPORTED_TAG(TAG) 8090ef0e59aSmrg# --------------------- 8100ef0e59aSmrg# Trace this macro to discover what tags are supported by the libtool 8110ef0e59aSmrg# --tag option, using: 8120ef0e59aSmrg# autoconf --trace 'LT_SUPPORTED_TAG:$1' 8130ef0e59aSmrgAC_DEFUN([LT_SUPPORTED_TAG], []) 8140ef0e59aSmrg 8150ef0e59aSmrg 8160ef0e59aSmrg# C support is built-in for now 8170ef0e59aSmrgm4_define([_LT_LANG_C_enabled], []) 8180ef0e59aSmrgm4_define([_LT_TAGS], []) 8190ef0e59aSmrg 8200ef0e59aSmrg 8210ef0e59aSmrg# LT_LANG(LANG) 8220ef0e59aSmrg# ------------- 8230ef0e59aSmrg# Enable libtool support for the given language if not already enabled. 8240ef0e59aSmrgAC_DEFUN([LT_LANG], 8250ef0e59aSmrg[AC_BEFORE([$0], [LT_OUTPUT])dnl 8260ef0e59aSmrgm4_case([$1], 8270ef0e59aSmrg [C], [_LT_LANG(C)], 8280ef0e59aSmrg [C++], [_LT_LANG(CXX)], 8290ef0e59aSmrg [Go], [_LT_LANG(GO)], 8300ef0e59aSmrg [Java], [_LT_LANG(GCJ)], 8310ef0e59aSmrg [Fortran 77], [_LT_LANG(F77)], 8320ef0e59aSmrg [Fortran], [_LT_LANG(FC)], 8330ef0e59aSmrg [Windows Resource], [_LT_LANG(RC)], 8340ef0e59aSmrg [m4_ifdef([_LT_LANG_]$1[_CONFIG], 8350ef0e59aSmrg [_LT_LANG($1)], 8360ef0e59aSmrg [m4_fatal([$0: unsupported language: "$1"])])])dnl 8370ef0e59aSmrg])# LT_LANG 8380ef0e59aSmrg 8390ef0e59aSmrg 8400ef0e59aSmrg# _LT_LANG(LANGNAME) 8410ef0e59aSmrg# ------------------ 8420ef0e59aSmrgm4_defun([_LT_LANG], 8430ef0e59aSmrg[m4_ifdef([_LT_LANG_]$1[_enabled], [], 8440ef0e59aSmrg [LT_SUPPORTED_TAG([$1])dnl 8450ef0e59aSmrg m4_append([_LT_TAGS], [$1 ])dnl 8460ef0e59aSmrg m4_define([_LT_LANG_]$1[_enabled], [])dnl 8470ef0e59aSmrg _LT_LANG_$1_CONFIG($1)])dnl 8480ef0e59aSmrg])# _LT_LANG 8490ef0e59aSmrg 8500ef0e59aSmrg 8510ef0e59aSmrgm4_ifndef([AC_PROG_GO], [ 8520ef0e59aSmrg############################################################ 8530ef0e59aSmrg# NOTE: This macro has been submitted for inclusion into # 8540ef0e59aSmrg# GNU Autoconf as AC_PROG_GO. When it is available in # 8550ef0e59aSmrg# a released version of Autoconf we should remove this # 8560ef0e59aSmrg# macro and use it instead. # 8570ef0e59aSmrg############################################################ 8580ef0e59aSmrgm4_defun([AC_PROG_GO], 8590ef0e59aSmrg[AC_LANG_PUSH(Go)dnl 8600ef0e59aSmrgAC_ARG_VAR([GOC], [Go compiler command])dnl 8610ef0e59aSmrgAC_ARG_VAR([GOFLAGS], [Go compiler flags])dnl 8620ef0e59aSmrg_AC_ARG_VAR_LDFLAGS()dnl 8630ef0e59aSmrgAC_CHECK_TOOL(GOC, gccgo) 8640ef0e59aSmrgif test -z "$GOC"; then 8650ef0e59aSmrg if test -n "$ac_tool_prefix"; then 8660ef0e59aSmrg AC_CHECK_PROG(GOC, [${ac_tool_prefix}gccgo], [${ac_tool_prefix}gccgo]) 8670ef0e59aSmrg fi 8680ef0e59aSmrgfi 8690ef0e59aSmrgif test -z "$GOC"; then 8700ef0e59aSmrg AC_CHECK_PROG(GOC, gccgo, gccgo, false) 8710ef0e59aSmrgfi 8720ef0e59aSmrg])#m4_defun 8730ef0e59aSmrg])#m4_ifndef 8740ef0e59aSmrg 8750ef0e59aSmrg 8760ef0e59aSmrg# _LT_LANG_DEFAULT_CONFIG 8770ef0e59aSmrg# ----------------------- 8780ef0e59aSmrgm4_defun([_LT_LANG_DEFAULT_CONFIG], 8790ef0e59aSmrg[AC_PROVIDE_IFELSE([AC_PROG_CXX], 8800ef0e59aSmrg [LT_LANG(CXX)], 8810ef0e59aSmrg [m4_define([AC_PROG_CXX], defn([AC_PROG_CXX])[LT_LANG(CXX)])]) 8820ef0e59aSmrg 8830ef0e59aSmrgAC_PROVIDE_IFELSE([AC_PROG_F77], 8840ef0e59aSmrg [LT_LANG(F77)], 8850ef0e59aSmrg [m4_define([AC_PROG_F77], defn([AC_PROG_F77])[LT_LANG(F77)])]) 8860ef0e59aSmrg 8870ef0e59aSmrgAC_PROVIDE_IFELSE([AC_PROG_FC], 8880ef0e59aSmrg [LT_LANG(FC)], 8890ef0e59aSmrg [m4_define([AC_PROG_FC], defn([AC_PROG_FC])[LT_LANG(FC)])]) 8900ef0e59aSmrg 8910ef0e59aSmrgdnl The call to [A][M_PROG_GCJ] is quoted like that to stop aclocal 8920ef0e59aSmrgdnl pulling things in needlessly. 8930ef0e59aSmrgAC_PROVIDE_IFELSE([AC_PROG_GCJ], 8940ef0e59aSmrg [LT_LANG(GCJ)], 8950ef0e59aSmrg [AC_PROVIDE_IFELSE([A][M_PROG_GCJ], 8960ef0e59aSmrg [LT_LANG(GCJ)], 8970ef0e59aSmrg [AC_PROVIDE_IFELSE([LT_PROG_GCJ], 8980ef0e59aSmrg [LT_LANG(GCJ)], 8990ef0e59aSmrg [m4_ifdef([AC_PROG_GCJ], 9000ef0e59aSmrg [m4_define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[LT_LANG(GCJ)])]) 9010ef0e59aSmrg m4_ifdef([A][M_PROG_GCJ], 9020ef0e59aSmrg [m4_define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[LT_LANG(GCJ)])]) 9030ef0e59aSmrg m4_ifdef([LT_PROG_GCJ], 9040ef0e59aSmrg [m4_define([LT_PROG_GCJ], defn([LT_PROG_GCJ])[LT_LANG(GCJ)])])])])]) 9050ef0e59aSmrg 9060ef0e59aSmrgAC_PROVIDE_IFELSE([AC_PROG_GO], 9070ef0e59aSmrg [LT_LANG(GO)], 9080ef0e59aSmrg [m4_define([AC_PROG_GO], defn([AC_PROG_GO])[LT_LANG(GO)])]) 9090ef0e59aSmrg 9100ef0e59aSmrgAC_PROVIDE_IFELSE([LT_PROG_RC], 9110ef0e59aSmrg [LT_LANG(RC)], 9120ef0e59aSmrg [m4_define([LT_PROG_RC], defn([LT_PROG_RC])[LT_LANG(RC)])]) 9130ef0e59aSmrg])# _LT_LANG_DEFAULT_CONFIG 9140ef0e59aSmrg 9150ef0e59aSmrg# Obsolete macros: 9160ef0e59aSmrgAU_DEFUN([AC_LIBTOOL_CXX], [LT_LANG(C++)]) 9170ef0e59aSmrgAU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)]) 9180ef0e59aSmrgAU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)]) 9190ef0e59aSmrgAU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)]) 9200ef0e59aSmrgAU_DEFUN([AC_LIBTOOL_RC], [LT_LANG(Windows Resource)]) 9210ef0e59aSmrgdnl aclocal-1.4 backwards compatibility: 9220ef0e59aSmrgdnl AC_DEFUN([AC_LIBTOOL_CXX], []) 9230ef0e59aSmrgdnl AC_DEFUN([AC_LIBTOOL_F77], []) 9240ef0e59aSmrgdnl AC_DEFUN([AC_LIBTOOL_FC], []) 9250ef0e59aSmrgdnl AC_DEFUN([AC_LIBTOOL_GCJ], []) 9260ef0e59aSmrgdnl AC_DEFUN([AC_LIBTOOL_RC], []) 9270ef0e59aSmrg 9280ef0e59aSmrg 9290ef0e59aSmrg# _LT_TAG_COMPILER 9300ef0e59aSmrg# ---------------- 9310ef0e59aSmrgm4_defun([_LT_TAG_COMPILER], 9320ef0e59aSmrg[AC_REQUIRE([AC_PROG_CC])dnl 9330ef0e59aSmrg 9340ef0e59aSmrg_LT_DECL([LTCC], [CC], [1], [A C compiler])dnl 9350ef0e59aSmrg_LT_DECL([LTCFLAGS], [CFLAGS], [1], [LTCC compiler flags])dnl 9360ef0e59aSmrg_LT_TAGDECL([CC], [compiler], [1], [A language specific compiler])dnl 9370ef0e59aSmrg_LT_TAGDECL([with_gcc], [GCC], [0], [Is the compiler the GNU compiler?])dnl 9380ef0e59aSmrg 9390ef0e59aSmrg# If no C compiler was specified, use CC. 9400ef0e59aSmrgLTCC=${LTCC-"$CC"} 9410ef0e59aSmrg 9420ef0e59aSmrg# If no C compiler flags were specified, use CFLAGS. 9430ef0e59aSmrgLTCFLAGS=${LTCFLAGS-"$CFLAGS"} 9440ef0e59aSmrg 9450ef0e59aSmrg# Allow CC to be a program name with arguments. 9460ef0e59aSmrgcompiler=$CC 9470ef0e59aSmrg])# _LT_TAG_COMPILER 9480ef0e59aSmrg 9490ef0e59aSmrg 9500ef0e59aSmrg# _LT_COMPILER_BOILERPLATE 9510ef0e59aSmrg# ------------------------ 9520ef0e59aSmrg# Check for compiler boilerplate output or warnings with 9530ef0e59aSmrg# the simple compiler test code. 9540ef0e59aSmrgm4_defun([_LT_COMPILER_BOILERPLATE], 9550ef0e59aSmrg[m4_require([_LT_DECL_SED])dnl 9560ef0e59aSmrgac_outfile=conftest.$ac_objext 9570ef0e59aSmrgecho "$lt_simple_compile_test_code" >conftest.$ac_ext 9580ef0e59aSmrgeval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err 9590ef0e59aSmrg_lt_compiler_boilerplate=`cat conftest.err` 9600ef0e59aSmrg$RM conftest* 9610ef0e59aSmrg])# _LT_COMPILER_BOILERPLATE 9620ef0e59aSmrg 9630ef0e59aSmrg 9640ef0e59aSmrg# _LT_LINKER_BOILERPLATE 9650ef0e59aSmrg# ---------------------- 9660ef0e59aSmrg# Check for linker boilerplate output or warnings with 9670ef0e59aSmrg# the simple link test code. 9680ef0e59aSmrgm4_defun([_LT_LINKER_BOILERPLATE], 9690ef0e59aSmrg[m4_require([_LT_DECL_SED])dnl 9700ef0e59aSmrgac_outfile=conftest.$ac_objext 9710ef0e59aSmrgecho "$lt_simple_link_test_code" >conftest.$ac_ext 9720ef0e59aSmrgeval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err 9730ef0e59aSmrg_lt_linker_boilerplate=`cat conftest.err` 9740ef0e59aSmrg$RM -r conftest* 9750ef0e59aSmrg])# _LT_LINKER_BOILERPLATE 9760ef0e59aSmrg 977d5e6aabbSmrg 9780ef0e59aSmrg# _LT_REQUIRED_DARWIN_CHECKS 9790ef0e59aSmrg# ------------------------- 9800ef0e59aSmrgm4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[ 9810ef0e59aSmrg case $host_os in 9820ef0e59aSmrg rhapsody* | darwin*) 9830ef0e59aSmrg AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:]) 9840ef0e59aSmrg AC_CHECK_TOOL([NMEDIT], [nmedit], [:]) 9850ef0e59aSmrg AC_CHECK_TOOL([LIPO], [lipo], [:]) 9860ef0e59aSmrg AC_CHECK_TOOL([OTOOL], [otool], [:]) 9870ef0e59aSmrg AC_CHECK_TOOL([OTOOL64], [otool64], [:]) 9880ef0e59aSmrg _LT_DECL([], [DSYMUTIL], [1], 9890ef0e59aSmrg [Tool to manipulate archived DWARF debug symbol files on Mac OS X]) 9900ef0e59aSmrg _LT_DECL([], [NMEDIT], [1], 9910ef0e59aSmrg [Tool to change global to local symbols on Mac OS X]) 9920ef0e59aSmrg _LT_DECL([], [LIPO], [1], 9930ef0e59aSmrg [Tool to manipulate fat objects and archives on Mac OS X]) 9940ef0e59aSmrg _LT_DECL([], [OTOOL], [1], 9950ef0e59aSmrg [ldd/readelf like tool for Mach-O binaries on Mac OS X]) 9960ef0e59aSmrg _LT_DECL([], [OTOOL64], [1], 9970ef0e59aSmrg [ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4]) 9980ef0e59aSmrg 9990ef0e59aSmrg AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod], 10000ef0e59aSmrg [lt_cv_apple_cc_single_mod=no 10010ef0e59aSmrg if test -z "$LT_MULTI_MODULE"; then 10020ef0e59aSmrg # By default we will add the -single_module flag. You can override 10030ef0e59aSmrg # by either setting the environment variable LT_MULTI_MODULE 10040ef0e59aSmrg # non-empty at configure time, or by adding -multi_module to the 10050ef0e59aSmrg # link flags. 10060ef0e59aSmrg rm -rf libconftest.dylib* 10070ef0e59aSmrg echo "int foo(void){return 1;}" > conftest.c 10080ef0e59aSmrg echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ 10090ef0e59aSmrg-dynamiclib -Wl,-single_module conftest.c" >&AS_MESSAGE_LOG_FD 10100ef0e59aSmrg $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ 10110ef0e59aSmrg -dynamiclib -Wl,-single_module conftest.c 2>conftest.err 10120ef0e59aSmrg _lt_result=$? 10130ef0e59aSmrg # If there is a non-empty error log, and "single_module" 10140ef0e59aSmrg # appears in it, assume the flag caused a linker warning 10150ef0e59aSmrg if test -s conftest.err && $GREP single_module conftest.err; then 10160ef0e59aSmrg cat conftest.err >&AS_MESSAGE_LOG_FD 10170ef0e59aSmrg # Otherwise, if the output was created with a 0 exit code from 10180ef0e59aSmrg # the compiler, it worked. 10190ef0e59aSmrg elif test -f libconftest.dylib && test 0 = "$_lt_result"; then 10200ef0e59aSmrg lt_cv_apple_cc_single_mod=yes 10210ef0e59aSmrg else 10220ef0e59aSmrg cat conftest.err >&AS_MESSAGE_LOG_FD 10230ef0e59aSmrg fi 10240ef0e59aSmrg rm -rf libconftest.dylib* 10250ef0e59aSmrg rm -f conftest.* 10260ef0e59aSmrg fi]) 10270ef0e59aSmrg 1028d5e6aabbSmrg # Feature test to disable chained fixups since it is not 1029d5e6aabbSmrg # compatible with '-undefined dynamic_lookup' 1030d5e6aabbSmrg AC_CACHE_CHECK([for -no_fixup_chains linker flag], 1031d5e6aabbSmrg [lt_cv_support_no_fixup_chains], 1032d5e6aabbSmrg [ save_LDFLAGS=$LDFLAGS 1033d5e6aabbSmrg LDFLAGS="$LDFLAGS -Wl,-no_fixup_chains" 1034d5e6aabbSmrg AC_LINK_IFELSE( 1035d5e6aabbSmrg [AC_LANG_PROGRAM([],[])], 1036d5e6aabbSmrg lt_cv_support_no_fixup_chains=yes, 1037d5e6aabbSmrg lt_cv_support_no_fixup_chains=no 1038d5e6aabbSmrg ) 1039d5e6aabbSmrg LDFLAGS=$save_LDFLAGS 1040d5e6aabbSmrg ] 1041d5e6aabbSmrg ) 1042d5e6aabbSmrg 10430ef0e59aSmrg AC_CACHE_CHECK([for -exported_symbols_list linker flag], 10440ef0e59aSmrg [lt_cv_ld_exported_symbols_list], 10450ef0e59aSmrg [lt_cv_ld_exported_symbols_list=no 10460ef0e59aSmrg save_LDFLAGS=$LDFLAGS 10470ef0e59aSmrg echo "_main" > conftest.sym 10480ef0e59aSmrg LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" 10490ef0e59aSmrg AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], 10500ef0e59aSmrg [lt_cv_ld_exported_symbols_list=yes], 10510ef0e59aSmrg [lt_cv_ld_exported_symbols_list=no]) 10520ef0e59aSmrg LDFLAGS=$save_LDFLAGS 10530ef0e59aSmrg ]) 10540ef0e59aSmrg 10550ef0e59aSmrg AC_CACHE_CHECK([for -force_load linker flag],[lt_cv_ld_force_load], 10560ef0e59aSmrg [lt_cv_ld_force_load=no 10570ef0e59aSmrg cat > conftest.c << _LT_EOF 10580ef0e59aSmrgint forced_loaded() { return 2;} 10590ef0e59aSmrg_LT_EOF 10600ef0e59aSmrg echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&AS_MESSAGE_LOG_FD 10610ef0e59aSmrg $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD 106215885c33Smrg echo "$AR $AR_FLAGS libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD 106315885c33Smrg $AR $AR_FLAGS libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD 10640ef0e59aSmrg echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD 10650ef0e59aSmrg $RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD 10660ef0e59aSmrg cat > conftest.c << _LT_EOF 1067d5e6aabbSmrgint main(void) { return 0;} 10680ef0e59aSmrg_LT_EOF 10690ef0e59aSmrg echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&AS_MESSAGE_LOG_FD 10700ef0e59aSmrg $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err 10710ef0e59aSmrg _lt_result=$? 10720ef0e59aSmrg if test -s conftest.err && $GREP force_load conftest.err; then 10730ef0e59aSmrg cat conftest.err >&AS_MESSAGE_LOG_FD 10740ef0e59aSmrg elif test -f conftest && test 0 = "$_lt_result" && $GREP forced_load conftest >/dev/null 2>&1; then 10750ef0e59aSmrg lt_cv_ld_force_load=yes 10760ef0e59aSmrg else 10770ef0e59aSmrg cat conftest.err >&AS_MESSAGE_LOG_FD 10780ef0e59aSmrg fi 10790ef0e59aSmrg rm -f conftest.err libconftest.a conftest conftest.c 10800ef0e59aSmrg rm -rf conftest.dSYM 10810ef0e59aSmrg ]) 10820ef0e59aSmrg case $host_os in 10830ef0e59aSmrg rhapsody* | darwin1.[[012]]) 10840ef0e59aSmrg _lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;; 10850ef0e59aSmrg darwin1.*) 10860ef0e59aSmrg _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; 108715885c33Smrg darwin*) 108815885c33Smrg case $MACOSX_DEPLOYMENT_TARGET,$host in 108915885c33Smrg 10.[[012]],*|,*powerpc*-darwin[[5-8]]*) 109015885c33Smrg _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; 109115885c33Smrg *) 1092d5e6aabbSmrg _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' 1093d5e6aabbSmrg if test yes = "$lt_cv_support_no_fixup_chains"; then 1094d5e6aabbSmrg AS_VAR_APPEND([_lt_dar_allow_undefined], [' $wl-no_fixup_chains']) 1095d5e6aabbSmrg fi 1096d5e6aabbSmrg ;; 10970ef0e59aSmrg esac 10980ef0e59aSmrg ;; 10990ef0e59aSmrg esac 11000ef0e59aSmrg if test yes = "$lt_cv_apple_cc_single_mod"; then 11010ef0e59aSmrg _lt_dar_single_mod='$single_module' 11020ef0e59aSmrg fi 1103d5e6aabbSmrg _lt_dar_needs_single_mod=no 1104d5e6aabbSmrg case $host_os in 1105d5e6aabbSmrg rhapsody* | darwin1.*) 1106d5e6aabbSmrg _lt_dar_needs_single_mod=yes ;; 1107d5e6aabbSmrg darwin*) 1108d5e6aabbSmrg # When targeting Mac OS X 10.4 (darwin 8) or later, 1109d5e6aabbSmrg # -single_module is the default and -multi_module is unsupported. 1110d5e6aabbSmrg # The toolchain on macOS 10.14 (darwin 18) and later cannot 1111d5e6aabbSmrg # target any OS version that needs -single_module. 1112d5e6aabbSmrg case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in 1113d5e6aabbSmrg 10.0,*-darwin[[567]].*|10.[[0-3]],*-darwin[[5-9]].*|10.[[0-3]],*-darwin1[[0-7]].*) 1114d5e6aabbSmrg _lt_dar_needs_single_mod=yes ;; 1115d5e6aabbSmrg esac 1116d5e6aabbSmrg ;; 1117d5e6aabbSmrg esac 11180ef0e59aSmrg if test yes = "$lt_cv_ld_exported_symbols_list"; then 11190ef0e59aSmrg _lt_dar_export_syms=' $wl-exported_symbols_list,$output_objdir/$libname-symbols.expsym' 11200ef0e59aSmrg else 11210ef0e59aSmrg _lt_dar_export_syms='~$NMEDIT -s $output_objdir/$libname-symbols.expsym $lib' 11220ef0e59aSmrg fi 11230ef0e59aSmrg if test : != "$DSYMUTIL" && test no = "$lt_cv_ld_force_load"; then 11240ef0e59aSmrg _lt_dsymutil='~$DSYMUTIL $lib || :' 11250ef0e59aSmrg else 11260ef0e59aSmrg _lt_dsymutil= 11270ef0e59aSmrg fi 11280ef0e59aSmrg ;; 11290ef0e59aSmrg esac 11300ef0e59aSmrg]) 11310ef0e59aSmrg 11320ef0e59aSmrg 11330ef0e59aSmrg# _LT_DARWIN_LINKER_FEATURES([TAG]) 11340ef0e59aSmrg# --------------------------------- 11350ef0e59aSmrg# Checks for linker and compiler features on darwin 11360ef0e59aSmrgm4_defun([_LT_DARWIN_LINKER_FEATURES], 11370ef0e59aSmrg[ 11380ef0e59aSmrg m4_require([_LT_REQUIRED_DARWIN_CHECKS]) 11390ef0e59aSmrg _LT_TAGVAR(archive_cmds_need_lc, $1)=no 11400ef0e59aSmrg _LT_TAGVAR(hardcode_direct, $1)=no 11410ef0e59aSmrg _LT_TAGVAR(hardcode_automatic, $1)=yes 11420ef0e59aSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported 11430ef0e59aSmrg if test yes = "$lt_cv_ld_force_load"; then 11440ef0e59aSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience $wl-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`' 11450ef0e59aSmrg m4_case([$1], [F77], [_LT_TAGVAR(compiler_needs_object, $1)=yes], 11460ef0e59aSmrg [FC], [_LT_TAGVAR(compiler_needs_object, $1)=yes]) 11470ef0e59aSmrg else 11480ef0e59aSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)='' 11490ef0e59aSmrg fi 11500ef0e59aSmrg _LT_TAGVAR(link_all_deplibs, $1)=yes 11510ef0e59aSmrg _LT_TAGVAR(allow_undefined_flag, $1)=$_lt_dar_allow_undefined 11520ef0e59aSmrg case $cc_basename in 11530ef0e59aSmrg ifort*|nagfor*) _lt_dar_can_shared=yes ;; 11540ef0e59aSmrg *) _lt_dar_can_shared=$GCC ;; 11550ef0e59aSmrg esac 11560ef0e59aSmrg if test yes = "$_lt_dar_can_shared"; then 11570ef0e59aSmrg output_verbose_link_cmd=func_echo_all 11580ef0e59aSmrg _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" 11590ef0e59aSmrg _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil" 116015885c33Smrg _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" 116115885c33Smrg _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" 11620ef0e59aSmrg m4_if([$1], [CXX], 1163d5e6aabbSmrg[ if test yes = "$_lt_dar_needs_single_mod" -a yes != "$lt_cv_apple_cc_single_mod"; then 11640ef0e59aSmrg _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" 116515885c33Smrg _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" 11660ef0e59aSmrg fi 11670ef0e59aSmrg],[]) 11680ef0e59aSmrg else 11690ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=no 11700ef0e59aSmrg fi 11710ef0e59aSmrg]) 11720ef0e59aSmrg 11730ef0e59aSmrg# _LT_SYS_MODULE_PATH_AIX([TAGNAME]) 11740ef0e59aSmrg# ---------------------------------- 11750ef0e59aSmrg# Links a minimal program and checks the executable 11760ef0e59aSmrg# for the system default hardcoded library path. In most cases, 11770ef0e59aSmrg# this is /usr/lib:/lib, but when the MPI compilers are used 11780ef0e59aSmrg# the location of the communication and MPI libs are included too. 11790ef0e59aSmrg# If we don't find anything, use the default library path according 11800ef0e59aSmrg# to the aix ld manual. 11810ef0e59aSmrg# Store the results from the different compilers for each TAGNAME. 11820ef0e59aSmrg# Allow to override them for all tags through lt_cv_aix_libpath. 11830ef0e59aSmrgm4_defun([_LT_SYS_MODULE_PATH_AIX], 11840ef0e59aSmrg[m4_require([_LT_DECL_SED])dnl 11850ef0e59aSmrgif test set = "${lt_cv_aix_libpath+set}"; then 11860ef0e59aSmrg aix_libpath=$lt_cv_aix_libpath 11870ef0e59aSmrgelse 11880ef0e59aSmrg AC_CACHE_VAL([_LT_TAGVAR([lt_cv_aix_libpath_], [$1])], 11890ef0e59aSmrg [AC_LINK_IFELSE([AC_LANG_PROGRAM],[ 11900ef0e59aSmrg lt_aix_libpath_sed='[ 11910ef0e59aSmrg /Import File Strings/,/^$/ { 11920ef0e59aSmrg /^0/ { 11930ef0e59aSmrg s/^0 *\([^ ]*\) *$/\1/ 11940ef0e59aSmrg p 11950ef0e59aSmrg } 11960ef0e59aSmrg }]' 11970ef0e59aSmrg _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` 11980ef0e59aSmrg # Check for a 64-bit object if we didn't find anything. 11990ef0e59aSmrg if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then 12000ef0e59aSmrg _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` 12010ef0e59aSmrg fi],[]) 12020ef0e59aSmrg if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then 12030ef0e59aSmrg _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=/usr/lib:/lib 12040ef0e59aSmrg fi 12050ef0e59aSmrg ]) 12060ef0e59aSmrg aix_libpath=$_LT_TAGVAR([lt_cv_aix_libpath_], [$1]) 12070ef0e59aSmrgfi 12080ef0e59aSmrg])# _LT_SYS_MODULE_PATH_AIX 12090ef0e59aSmrg 12100ef0e59aSmrg 12110ef0e59aSmrg# _LT_SHELL_INIT(ARG) 12120ef0e59aSmrg# ------------------- 12130ef0e59aSmrgm4_define([_LT_SHELL_INIT], 12140ef0e59aSmrg[m4_divert_text([M4SH-INIT], [$1 12150ef0e59aSmrg])])# _LT_SHELL_INIT 12160ef0e59aSmrg 12170ef0e59aSmrg 12180ef0e59aSmrg 12190ef0e59aSmrg# _LT_PROG_ECHO_BACKSLASH 12200ef0e59aSmrg# ----------------------- 12210ef0e59aSmrg# Find how we can fake an echo command that does not interpret backslash. 12220ef0e59aSmrg# In particular, with Autoconf 2.60 or later we add some code to the start 12230ef0e59aSmrg# of the generated configure script that will find a shell with a builtin 12240ef0e59aSmrg# printf (that we can use as an echo command). 12250ef0e59aSmrgm4_defun([_LT_PROG_ECHO_BACKSLASH], 12260ef0e59aSmrg[ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' 12270ef0e59aSmrgECHO=$ECHO$ECHO$ECHO$ECHO$ECHO 12280ef0e59aSmrgECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO 12290ef0e59aSmrg 12300ef0e59aSmrgAC_MSG_CHECKING([how to print strings]) 12310ef0e59aSmrg# Test print first, because it will be a builtin if present. 12320ef0e59aSmrgif test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \ 12330ef0e59aSmrg test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then 12340ef0e59aSmrg ECHO='print -r --' 12350ef0e59aSmrgelif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then 12360ef0e59aSmrg ECHO='printf %s\n' 12370ef0e59aSmrgelse 12380ef0e59aSmrg # Use this function as a fallback that always works. 12390ef0e59aSmrg func_fallback_echo () 12400ef0e59aSmrg { 12410ef0e59aSmrg eval 'cat <<_LTECHO_EOF 12420ef0e59aSmrg$[]1 12430ef0e59aSmrg_LTECHO_EOF' 12440ef0e59aSmrg } 12450ef0e59aSmrg ECHO='func_fallback_echo' 12460ef0e59aSmrgfi 12470ef0e59aSmrg 12480ef0e59aSmrg# func_echo_all arg... 12490ef0e59aSmrg# Invoke $ECHO with all args, space-separated. 12500ef0e59aSmrgfunc_echo_all () 12510ef0e59aSmrg{ 12520ef0e59aSmrg $ECHO "$*" 12530ef0e59aSmrg} 12540ef0e59aSmrg 12550ef0e59aSmrgcase $ECHO in 12560ef0e59aSmrg printf*) AC_MSG_RESULT([printf]) ;; 12570ef0e59aSmrg print*) AC_MSG_RESULT([print -r]) ;; 12580ef0e59aSmrg *) AC_MSG_RESULT([cat]) ;; 12590ef0e59aSmrgesac 12600ef0e59aSmrg 12610ef0e59aSmrgm4_ifdef([_AS_DETECT_SUGGESTED], 12620ef0e59aSmrg[_AS_DETECT_SUGGESTED([ 12630ef0e59aSmrg test -n "${ZSH_VERSION+set}${BASH_VERSION+set}" || ( 12640ef0e59aSmrg ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' 12650ef0e59aSmrg ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO 12660ef0e59aSmrg ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO 12670ef0e59aSmrg PATH=/empty FPATH=/empty; export PATH FPATH 12680ef0e59aSmrg test "X`printf %s $ECHO`" = "X$ECHO" \ 12690ef0e59aSmrg || test "X`print -r -- $ECHO`" = "X$ECHO" )])]) 12700ef0e59aSmrg 12710ef0e59aSmrg_LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts]) 12720ef0e59aSmrg_LT_DECL([], [ECHO], [1], [An echo program that protects backslashes]) 12730ef0e59aSmrg])# _LT_PROG_ECHO_BACKSLASH 12740ef0e59aSmrg 12750ef0e59aSmrg 12760ef0e59aSmrg# _LT_WITH_SYSROOT 12770ef0e59aSmrg# ---------------- 12780ef0e59aSmrgAC_DEFUN([_LT_WITH_SYSROOT], 127915885c33Smrg[m4_require([_LT_DECL_SED])dnl 128015885c33SmrgAC_MSG_CHECKING([for sysroot]) 12810ef0e59aSmrgAC_ARG_WITH([sysroot], 12820ef0e59aSmrg[AS_HELP_STRING([--with-sysroot@<:@=DIR@:>@], 12830ef0e59aSmrg [Search for dependent libraries within DIR (or the compiler's sysroot 12840ef0e59aSmrg if not specified).])], 12850ef0e59aSmrg[], [with_sysroot=no]) 12860ef0e59aSmrg 12870ef0e59aSmrgdnl lt_sysroot will always be passed unquoted. We quote it here 12880ef0e59aSmrgdnl in case the user passed a directory name. 12890ef0e59aSmrglt_sysroot= 12900ef0e59aSmrgcase $with_sysroot in #( 12910ef0e59aSmrg yes) 12920ef0e59aSmrg if test yes = "$GCC"; then 1293d5e6aabbSmrg # Trim trailing / since we'll always append absolute paths and we want 1294d5e6aabbSmrg # to avoid //, if only for less confusing output for the user. 1295d5e6aabbSmrg lt_sysroot=`$CC --print-sysroot 2>/dev/null | $SED 's:/\+$::'` 12960ef0e59aSmrg fi 12970ef0e59aSmrg ;; #( 12980ef0e59aSmrg /*) 129915885c33Smrg lt_sysroot=`echo "$with_sysroot" | $SED -e "$sed_quote_subst"` 13000ef0e59aSmrg ;; #( 13010ef0e59aSmrg no|'') 13020ef0e59aSmrg ;; #( 13030ef0e59aSmrg *) 13040ef0e59aSmrg AC_MSG_RESULT([$with_sysroot]) 13050ef0e59aSmrg AC_MSG_ERROR([The sysroot must be an absolute path.]) 13060ef0e59aSmrg ;; 13070ef0e59aSmrgesac 13080ef0e59aSmrg 13090ef0e59aSmrg AC_MSG_RESULT([${lt_sysroot:-no}]) 13100ef0e59aSmrg_LT_DECL([], [lt_sysroot], [0], [The root where to search for ]dnl 13110ef0e59aSmrg[dependent libraries, and where our libraries should be installed.])]) 13120ef0e59aSmrg 13130ef0e59aSmrg# _LT_ENABLE_LOCK 13140ef0e59aSmrg# --------------- 13150ef0e59aSmrgm4_defun([_LT_ENABLE_LOCK], 13160ef0e59aSmrg[AC_ARG_ENABLE([libtool-lock], 13170ef0e59aSmrg [AS_HELP_STRING([--disable-libtool-lock], 13180ef0e59aSmrg [avoid locking (might break parallel builds)])]) 13190ef0e59aSmrgtest no = "$enable_libtool_lock" || enable_libtool_lock=yes 13200ef0e59aSmrg 13210ef0e59aSmrg# Some flags need to be propagated to the compiler or linker for good 13220ef0e59aSmrg# libtool support. 13230ef0e59aSmrgcase $host in 13240ef0e59aSmrgia64-*-hpux*) 13250ef0e59aSmrg # Find out what ABI is being produced by ac_compile, and set mode 13260ef0e59aSmrg # options accordingly. 13270ef0e59aSmrg echo 'int i;' > conftest.$ac_ext 13280ef0e59aSmrg if AC_TRY_EVAL(ac_compile); then 132915885c33Smrg case `$FILECMD conftest.$ac_objext` in 13300ef0e59aSmrg *ELF-32*) 13310ef0e59aSmrg HPUX_IA64_MODE=32 13320ef0e59aSmrg ;; 13330ef0e59aSmrg *ELF-64*) 13340ef0e59aSmrg HPUX_IA64_MODE=64 13350ef0e59aSmrg ;; 13360ef0e59aSmrg esac 13370ef0e59aSmrg fi 13380ef0e59aSmrg rm -rf conftest* 13390ef0e59aSmrg ;; 13400ef0e59aSmrg*-*-irix6*) 13410ef0e59aSmrg # Find out what ABI is being produced by ac_compile, and set linker 13420ef0e59aSmrg # options accordingly. 13430ef0e59aSmrg echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext 13440ef0e59aSmrg if AC_TRY_EVAL(ac_compile); then 13450ef0e59aSmrg if test yes = "$lt_cv_prog_gnu_ld"; then 134615885c33Smrg case `$FILECMD conftest.$ac_objext` in 13470ef0e59aSmrg *32-bit*) 13480ef0e59aSmrg LD="${LD-ld} -melf32bsmip" 13490ef0e59aSmrg ;; 13500ef0e59aSmrg *N32*) 13510ef0e59aSmrg LD="${LD-ld} -melf32bmipn32" 13520ef0e59aSmrg ;; 13530ef0e59aSmrg *64-bit*) 13540ef0e59aSmrg LD="${LD-ld} -melf64bmip" 13550ef0e59aSmrg ;; 13560ef0e59aSmrg esac 13570ef0e59aSmrg else 135815885c33Smrg case `$FILECMD conftest.$ac_objext` in 13590ef0e59aSmrg *32-bit*) 13600ef0e59aSmrg LD="${LD-ld} -32" 13610ef0e59aSmrg ;; 13620ef0e59aSmrg *N32*) 13630ef0e59aSmrg LD="${LD-ld} -n32" 13640ef0e59aSmrg ;; 13650ef0e59aSmrg *64-bit*) 13660ef0e59aSmrg LD="${LD-ld} -64" 13670ef0e59aSmrg ;; 13680ef0e59aSmrg esac 13690ef0e59aSmrg fi 13700ef0e59aSmrg fi 13710ef0e59aSmrg rm -rf conftest* 13720ef0e59aSmrg ;; 13730ef0e59aSmrg 13740ef0e59aSmrgmips64*-*linux*) 13750ef0e59aSmrg # Find out what ABI is being produced by ac_compile, and set linker 13760ef0e59aSmrg # options accordingly. 13770ef0e59aSmrg echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext 13780ef0e59aSmrg if AC_TRY_EVAL(ac_compile); then 13790ef0e59aSmrg emul=elf 138015885c33Smrg case `$FILECMD conftest.$ac_objext` in 13810ef0e59aSmrg *32-bit*) 13820ef0e59aSmrg emul="${emul}32" 13830ef0e59aSmrg ;; 13840ef0e59aSmrg *64-bit*) 13850ef0e59aSmrg emul="${emul}64" 13860ef0e59aSmrg ;; 13870ef0e59aSmrg esac 138815885c33Smrg case `$FILECMD conftest.$ac_objext` in 13890ef0e59aSmrg *MSB*) 13900ef0e59aSmrg emul="${emul}btsmip" 13910ef0e59aSmrg ;; 13920ef0e59aSmrg *LSB*) 13930ef0e59aSmrg emul="${emul}ltsmip" 13940ef0e59aSmrg ;; 13950ef0e59aSmrg esac 139615885c33Smrg case `$FILECMD conftest.$ac_objext` in 13970ef0e59aSmrg *N32*) 13980ef0e59aSmrg emul="${emul}n32" 13990ef0e59aSmrg ;; 14000ef0e59aSmrg esac 14010ef0e59aSmrg LD="${LD-ld} -m $emul" 14020ef0e59aSmrg fi 14030ef0e59aSmrg rm -rf conftest* 14040ef0e59aSmrg ;; 14050ef0e59aSmrg 14060ef0e59aSmrgx86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \ 1407d5e6aabbSmrgs390*-*linux*|s390*-*tpf*|sparc*-*linux*|x86_64-gnu*) 14080ef0e59aSmrg # Find out what ABI is being produced by ac_compile, and set linker 14090ef0e59aSmrg # options accordingly. Note that the listed cases only cover the 14100ef0e59aSmrg # situations where additional linker options are needed (such as when 14110ef0e59aSmrg # doing 32-bit compilation for a host where ld defaults to 64-bit, or 14120ef0e59aSmrg # vice versa); the common cases where no linker options are needed do 14130ef0e59aSmrg # not appear in the list. 14140ef0e59aSmrg echo 'int i;' > conftest.$ac_ext 14150ef0e59aSmrg if AC_TRY_EVAL(ac_compile); then 141615885c33Smrg case `$FILECMD conftest.o` in 14170ef0e59aSmrg *32-bit*) 14180ef0e59aSmrg case $host in 14190ef0e59aSmrg x86_64-*kfreebsd*-gnu) 14200ef0e59aSmrg LD="${LD-ld} -m elf_i386_fbsd" 14210ef0e59aSmrg ;; 1422d5e6aabbSmrg x86_64-*linux*|x86_64-gnu*) 142315885c33Smrg case `$FILECMD conftest.o` in 14240ef0e59aSmrg *x86-64*) 14250ef0e59aSmrg LD="${LD-ld} -m elf32_x86_64" 14260ef0e59aSmrg ;; 14270ef0e59aSmrg *) 14280ef0e59aSmrg LD="${LD-ld} -m elf_i386" 14290ef0e59aSmrg ;; 14300ef0e59aSmrg esac 14310ef0e59aSmrg ;; 14320ef0e59aSmrg powerpc64le-*linux*) 14330ef0e59aSmrg LD="${LD-ld} -m elf32lppclinux" 14340ef0e59aSmrg ;; 14350ef0e59aSmrg powerpc64-*linux*) 14360ef0e59aSmrg LD="${LD-ld} -m elf32ppclinux" 14370ef0e59aSmrg ;; 14380ef0e59aSmrg s390x-*linux*) 14390ef0e59aSmrg LD="${LD-ld} -m elf_s390" 14400ef0e59aSmrg ;; 14410ef0e59aSmrg sparc64-*linux*) 14420ef0e59aSmrg LD="${LD-ld} -m elf32_sparc" 14430ef0e59aSmrg ;; 14440ef0e59aSmrg esac 14450ef0e59aSmrg ;; 14460ef0e59aSmrg *64-bit*) 14470ef0e59aSmrg case $host in 14480ef0e59aSmrg x86_64-*kfreebsd*-gnu) 14490ef0e59aSmrg LD="${LD-ld} -m elf_x86_64_fbsd" 14500ef0e59aSmrg ;; 1451d5e6aabbSmrg x86_64-*linux*|x86_64-gnu*) 14520ef0e59aSmrg LD="${LD-ld} -m elf_x86_64" 14530ef0e59aSmrg ;; 14540ef0e59aSmrg powerpcle-*linux*) 14550ef0e59aSmrg LD="${LD-ld} -m elf64lppc" 14560ef0e59aSmrg ;; 14570ef0e59aSmrg powerpc-*linux*) 14580ef0e59aSmrg LD="${LD-ld} -m elf64ppc" 14590ef0e59aSmrg ;; 14600ef0e59aSmrg s390*-*linux*|s390*-*tpf*) 14610ef0e59aSmrg LD="${LD-ld} -m elf64_s390" 14620ef0e59aSmrg ;; 14630ef0e59aSmrg sparc*-*linux*) 14640ef0e59aSmrg LD="${LD-ld} -m elf64_sparc" 14650ef0e59aSmrg ;; 14660ef0e59aSmrg esac 14670ef0e59aSmrg ;; 14680ef0e59aSmrg esac 14690ef0e59aSmrg fi 14700ef0e59aSmrg rm -rf conftest* 14710ef0e59aSmrg ;; 14720ef0e59aSmrg 14730ef0e59aSmrg*-*-sco3.2v5*) 14740ef0e59aSmrg # On SCO OpenServer 5, we need -belf to get full-featured binaries. 14750ef0e59aSmrg SAVE_CFLAGS=$CFLAGS 14760ef0e59aSmrg CFLAGS="$CFLAGS -belf" 14770ef0e59aSmrg AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf, 14780ef0e59aSmrg [AC_LANG_PUSH(C) 14790ef0e59aSmrg AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no]) 14800ef0e59aSmrg AC_LANG_POP]) 14810ef0e59aSmrg if test yes != "$lt_cv_cc_needs_belf"; then 14820ef0e59aSmrg # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf 14830ef0e59aSmrg CFLAGS=$SAVE_CFLAGS 14840ef0e59aSmrg fi 14850ef0e59aSmrg ;; 14860ef0e59aSmrg*-*solaris*) 14870ef0e59aSmrg # Find out what ABI is being produced by ac_compile, and set linker 14880ef0e59aSmrg # options accordingly. 14890ef0e59aSmrg echo 'int i;' > conftest.$ac_ext 14900ef0e59aSmrg if AC_TRY_EVAL(ac_compile); then 149115885c33Smrg case `$FILECMD conftest.o` in 14920ef0e59aSmrg *64-bit*) 14930ef0e59aSmrg case $lt_cv_prog_gnu_ld in 14940ef0e59aSmrg yes*) 14950ef0e59aSmrg case $host in 14960ef0e59aSmrg i?86-*-solaris*|x86_64-*-solaris*) 14970ef0e59aSmrg LD="${LD-ld} -m elf_x86_64" 14980ef0e59aSmrg ;; 14990ef0e59aSmrg sparc*-*-solaris*) 15000ef0e59aSmrg LD="${LD-ld} -m elf64_sparc" 15010ef0e59aSmrg ;; 15020ef0e59aSmrg esac 15030ef0e59aSmrg # GNU ld 2.21 introduced _sol2 emulations. Use them if available. 15040ef0e59aSmrg if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then 15050ef0e59aSmrg LD=${LD-ld}_sol2 15060ef0e59aSmrg fi 15070ef0e59aSmrg ;; 15080ef0e59aSmrg *) 15090ef0e59aSmrg if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then 15100ef0e59aSmrg LD="${LD-ld} -64" 15110ef0e59aSmrg fi 15120ef0e59aSmrg ;; 15130ef0e59aSmrg esac 15140ef0e59aSmrg ;; 15150ef0e59aSmrg esac 15160ef0e59aSmrg fi 15170ef0e59aSmrg rm -rf conftest* 15180ef0e59aSmrg ;; 15190ef0e59aSmrgesac 15200ef0e59aSmrg 15210ef0e59aSmrgneed_locks=$enable_libtool_lock 15220ef0e59aSmrg])# _LT_ENABLE_LOCK 15230ef0e59aSmrg 15240ef0e59aSmrg 15250ef0e59aSmrg# _LT_PROG_AR 15260ef0e59aSmrg# ----------- 15270ef0e59aSmrgm4_defun([_LT_PROG_AR], 15280ef0e59aSmrg[AC_CHECK_TOOLS(AR, [ar], false) 15290ef0e59aSmrg: ${AR=ar} 15300ef0e59aSmrg_LT_DECL([], [AR], [1], [The archiver]) 153115885c33Smrg 153215885c33Smrg# Use ARFLAGS variable as AR's operation code to sync the variable naming with 153315885c33Smrg# Automake. If both AR_FLAGS and ARFLAGS are specified, AR_FLAGS should have 1534d5e6aabbSmrg# higher priority because that's what people were doing historically (setting 153515885c33Smrg# ARFLAGS for automake and AR_FLAGS for libtool). FIXME: Make the AR_FLAGS 153615885c33Smrg# variable obsoleted/removed. 153715885c33Smrg 153815885c33Smrgtest ${AR_FLAGS+y} || AR_FLAGS=${ARFLAGS-cr} 153915885c33Smrglt_ar_flags=$AR_FLAGS 154015885c33Smrg_LT_DECL([], [lt_ar_flags], [0], [Flags to create an archive (by configure)]) 154115885c33Smrg 154215885c33Smrg# Make AR_FLAGS overridable by 'make ARFLAGS='. Don't try to run-time override 154315885c33Smrg# by AR_FLAGS because that was never working and AR_FLAGS is about to die. 154415885c33Smrg_LT_DECL([], [AR_FLAGS], [\@S|@{ARFLAGS-"\@S|@lt_ar_flags"}], 154515885c33Smrg [Flags to create an archive]) 15460ef0e59aSmrg 15470ef0e59aSmrgAC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file], 15480ef0e59aSmrg [lt_cv_ar_at_file=no 15490ef0e59aSmrg AC_COMPILE_IFELSE([AC_LANG_PROGRAM], 15500ef0e59aSmrg [echo conftest.$ac_objext > conftest.lst 15510ef0e59aSmrg lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&AS_MESSAGE_LOG_FD' 15520ef0e59aSmrg AC_TRY_EVAL([lt_ar_try]) 15530ef0e59aSmrg if test 0 -eq "$ac_status"; then 15540ef0e59aSmrg # Ensure the archiver fails upon bogus file names. 15550ef0e59aSmrg rm -f conftest.$ac_objext libconftest.a 15560ef0e59aSmrg AC_TRY_EVAL([lt_ar_try]) 15570ef0e59aSmrg if test 0 -ne "$ac_status"; then 15580ef0e59aSmrg lt_cv_ar_at_file=@ 15590ef0e59aSmrg fi 15600ef0e59aSmrg fi 15610ef0e59aSmrg rm -f conftest.* libconftest.a 15620ef0e59aSmrg ]) 15630ef0e59aSmrg ]) 15640ef0e59aSmrg 15650ef0e59aSmrgif test no = "$lt_cv_ar_at_file"; then 15660ef0e59aSmrg archiver_list_spec= 15670ef0e59aSmrgelse 15680ef0e59aSmrg archiver_list_spec=$lt_cv_ar_at_file 15690ef0e59aSmrgfi 15700ef0e59aSmrg_LT_DECL([], [archiver_list_spec], [1], 15710ef0e59aSmrg [How to feed a file listing to the archiver]) 15720ef0e59aSmrg])# _LT_PROG_AR 15730ef0e59aSmrg 15740ef0e59aSmrg 15750ef0e59aSmrg# _LT_CMD_OLD_ARCHIVE 15760ef0e59aSmrg# ------------------- 15770ef0e59aSmrgm4_defun([_LT_CMD_OLD_ARCHIVE], 15780ef0e59aSmrg[_LT_PROG_AR 15790ef0e59aSmrg 15800ef0e59aSmrgAC_CHECK_TOOL(STRIP, strip, :) 15810ef0e59aSmrgtest -z "$STRIP" && STRIP=: 15820ef0e59aSmrg_LT_DECL([], [STRIP], [1], [A symbol stripping program]) 15830ef0e59aSmrg 1584d5e6aabbSmrgAC_REQUIRE([AC_PROG_RANLIB]) 15850ef0e59aSmrgtest -z "$RANLIB" && RANLIB=: 15860ef0e59aSmrg_LT_DECL([], [RANLIB], [1], 15870ef0e59aSmrg [Commands used to install an old-style archive]) 15880ef0e59aSmrg 15890ef0e59aSmrg# Determine commands to create old-style static archives. 15900ef0e59aSmrgold_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' 15910ef0e59aSmrgold_postinstall_cmds='chmod 644 $oldlib' 15920ef0e59aSmrgold_postuninstall_cmds= 15930ef0e59aSmrg 15940ef0e59aSmrgif test -n "$RANLIB"; then 15950ef0e59aSmrg old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib" 1596d5e6aabbSmrg old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib" 15970ef0e59aSmrgfi 15980ef0e59aSmrg 15990ef0e59aSmrgcase $host_os in 16000ef0e59aSmrg darwin*) 16010ef0e59aSmrg lock_old_archive_extraction=yes ;; 16020ef0e59aSmrg *) 16030ef0e59aSmrg lock_old_archive_extraction=no ;; 16040ef0e59aSmrgesac 16050ef0e59aSmrg_LT_DECL([], [old_postinstall_cmds], [2]) 16060ef0e59aSmrg_LT_DECL([], [old_postuninstall_cmds], [2]) 16070ef0e59aSmrg_LT_TAGDECL([], [old_archive_cmds], [2], 16080ef0e59aSmrg [Commands used to build an old-style archive]) 16090ef0e59aSmrg_LT_DECL([], [lock_old_archive_extraction], [0], 16100ef0e59aSmrg [Whether to use a lock for old archive extraction]) 16110ef0e59aSmrg])# _LT_CMD_OLD_ARCHIVE 16120ef0e59aSmrg 16130ef0e59aSmrg 16140ef0e59aSmrg# _LT_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, 16150ef0e59aSmrg# [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE]) 16160ef0e59aSmrg# ---------------------------------------------------------------- 16170ef0e59aSmrg# Check whether the given compiler option works 16180ef0e59aSmrgAC_DEFUN([_LT_COMPILER_OPTION], 16190ef0e59aSmrg[m4_require([_LT_FILEUTILS_DEFAULTS])dnl 16200ef0e59aSmrgm4_require([_LT_DECL_SED])dnl 16210ef0e59aSmrgAC_CACHE_CHECK([$1], [$2], 16220ef0e59aSmrg [$2=no 16230ef0e59aSmrg m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4]) 16240ef0e59aSmrg echo "$lt_simple_compile_test_code" > conftest.$ac_ext 16250ef0e59aSmrg lt_compiler_flag="$3" ## exclude from sc_useless_quotes_in_assignment 16260ef0e59aSmrg # Insert the option either (1) after the last *FLAGS variable, or 16270ef0e59aSmrg # (2) before a word containing "conftest.", or (3) at the end. 16280ef0e59aSmrg # Note that $ac_compile itself does not contain backslashes and begins 16290ef0e59aSmrg # with a dollar sign (not a hyphen), so the echo should work correctly. 16300ef0e59aSmrg # The option is referenced via a variable to avoid confusing sed. 16310ef0e59aSmrg lt_compile=`echo "$ac_compile" | $SED \ 16320ef0e59aSmrg -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ 16330ef0e59aSmrg -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ 16340ef0e59aSmrg -e 's:$: $lt_compiler_flag:'` 16350ef0e59aSmrg (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD) 16360ef0e59aSmrg (eval "$lt_compile" 2>conftest.err) 16370ef0e59aSmrg ac_status=$? 16380ef0e59aSmrg cat conftest.err >&AS_MESSAGE_LOG_FD 16390ef0e59aSmrg echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD 16400ef0e59aSmrg if (exit $ac_status) && test -s "$ac_outfile"; then 16410ef0e59aSmrg # The compiler can only warn and ignore the option if not recognized 16420ef0e59aSmrg # So say no if there are warnings other than the usual output. 16430ef0e59aSmrg $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp 16440ef0e59aSmrg $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 16450ef0e59aSmrg if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then 16460ef0e59aSmrg $2=yes 16470ef0e59aSmrg fi 16480ef0e59aSmrg fi 16490ef0e59aSmrg $RM conftest* 16500ef0e59aSmrg]) 16510ef0e59aSmrg 16520ef0e59aSmrgif test yes = "[$]$2"; then 16530ef0e59aSmrg m4_if([$5], , :, [$5]) 16540ef0e59aSmrgelse 16550ef0e59aSmrg m4_if([$6], , :, [$6]) 16560ef0e59aSmrgfi 16570ef0e59aSmrg])# _LT_COMPILER_OPTION 16580ef0e59aSmrg 16590ef0e59aSmrg# Old name: 16600ef0e59aSmrgAU_ALIAS([AC_LIBTOOL_COMPILER_OPTION], [_LT_COMPILER_OPTION]) 16610ef0e59aSmrgdnl aclocal-1.4 backwards compatibility: 16620ef0e59aSmrgdnl AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], []) 16630ef0e59aSmrg 16640ef0e59aSmrg 16650ef0e59aSmrg# _LT_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, 16660ef0e59aSmrg# [ACTION-SUCCESS], [ACTION-FAILURE]) 16670ef0e59aSmrg# ---------------------------------------------------- 16680ef0e59aSmrg# Check whether the given linker option works 16690ef0e59aSmrgAC_DEFUN([_LT_LINKER_OPTION], 16700ef0e59aSmrg[m4_require([_LT_FILEUTILS_DEFAULTS])dnl 16710ef0e59aSmrgm4_require([_LT_DECL_SED])dnl 16720ef0e59aSmrgAC_CACHE_CHECK([$1], [$2], 16730ef0e59aSmrg [$2=no 16740ef0e59aSmrg save_LDFLAGS=$LDFLAGS 16750ef0e59aSmrg LDFLAGS="$LDFLAGS $3" 16760ef0e59aSmrg echo "$lt_simple_link_test_code" > conftest.$ac_ext 16770ef0e59aSmrg if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then 16780ef0e59aSmrg # The linker can only warn and ignore the option if not recognized 16790ef0e59aSmrg # So say no if there are warnings 16800ef0e59aSmrg if test -s conftest.err; then 16810ef0e59aSmrg # Append any errors to the config.log. 16820ef0e59aSmrg cat conftest.err 1>&AS_MESSAGE_LOG_FD 16830ef0e59aSmrg $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp 16840ef0e59aSmrg $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 16850ef0e59aSmrg if diff conftest.exp conftest.er2 >/dev/null; then 16860ef0e59aSmrg $2=yes 16870ef0e59aSmrg fi 16880ef0e59aSmrg else 16890ef0e59aSmrg $2=yes 16900ef0e59aSmrg fi 16910ef0e59aSmrg fi 16920ef0e59aSmrg $RM -r conftest* 16930ef0e59aSmrg LDFLAGS=$save_LDFLAGS 16940ef0e59aSmrg]) 16950ef0e59aSmrg 16960ef0e59aSmrgif test yes = "[$]$2"; then 16970ef0e59aSmrg m4_if([$4], , :, [$4]) 16980ef0e59aSmrgelse 16990ef0e59aSmrg m4_if([$5], , :, [$5]) 17000ef0e59aSmrgfi 17010ef0e59aSmrg])# _LT_LINKER_OPTION 17020ef0e59aSmrg 17030ef0e59aSmrg# Old name: 17040ef0e59aSmrgAU_ALIAS([AC_LIBTOOL_LINKER_OPTION], [_LT_LINKER_OPTION]) 17050ef0e59aSmrgdnl aclocal-1.4 backwards compatibility: 17060ef0e59aSmrgdnl AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], []) 17070ef0e59aSmrg 17080ef0e59aSmrg 17090ef0e59aSmrg# LT_CMD_MAX_LEN 17100ef0e59aSmrg#--------------- 17110ef0e59aSmrgAC_DEFUN([LT_CMD_MAX_LEN], 17120ef0e59aSmrg[AC_REQUIRE([AC_CANONICAL_HOST])dnl 17130ef0e59aSmrg# find the maximum length of command line arguments 17140ef0e59aSmrgAC_MSG_CHECKING([the maximum length of command line arguments]) 17150ef0e59aSmrgAC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl 17160ef0e59aSmrg i=0 17170ef0e59aSmrg teststring=ABCD 17180ef0e59aSmrg 17190ef0e59aSmrg case $build_os in 17200ef0e59aSmrg msdosdjgpp*) 17210ef0e59aSmrg # On DJGPP, this test can blow up pretty badly due to problems in libc 17220ef0e59aSmrg # (any single argument exceeding 2000 bytes causes a buffer overrun 17230ef0e59aSmrg # during glob expansion). Even if it were fixed, the result of this 17240ef0e59aSmrg # check would be larger than it should be. 17250ef0e59aSmrg lt_cv_sys_max_cmd_len=12288; # 12K is about right 17260ef0e59aSmrg ;; 17270ef0e59aSmrg 1728d5e6aabbSmrg gnu* | ironclad*) 1729d5e6aabbSmrg # Under GNU Hurd and Ironclad, this test is not required because there 1730d5e6aabbSmrg # is no limit to the length of command line arguments. 17310ef0e59aSmrg # Libtool will interpret -1 as no limit whatsoever 17320ef0e59aSmrg lt_cv_sys_max_cmd_len=-1; 17330ef0e59aSmrg ;; 17340ef0e59aSmrg 1735d5e6aabbSmrg cygwin* | mingw* | windows* | cegcc*) 17360ef0e59aSmrg # On Win9x/ME, this test blows up -- it succeeds, but takes 17370ef0e59aSmrg # about 5 minutes as the teststring grows exponentially. 17380ef0e59aSmrg # Worse, since 9x/ME are not pre-emptively multitasking, 17390ef0e59aSmrg # you end up with a "frozen" computer, even though with patience 17400ef0e59aSmrg # the test eventually succeeds (with a max line length of 256k). 17410ef0e59aSmrg # Instead, let's just punt: use the minimum linelength reported by 17420ef0e59aSmrg # all of the supported platforms: 8192 (on NT/2K/XP). 17430ef0e59aSmrg lt_cv_sys_max_cmd_len=8192; 17440ef0e59aSmrg ;; 17450ef0e59aSmrg 17460ef0e59aSmrg mint*) 17470ef0e59aSmrg # On MiNT this can take a long time and run out of memory. 17480ef0e59aSmrg lt_cv_sys_max_cmd_len=8192; 17490ef0e59aSmrg ;; 17500ef0e59aSmrg 17510ef0e59aSmrg amigaos*) 17520ef0e59aSmrg # On AmigaOS with pdksh, this test takes hours, literally. 17530ef0e59aSmrg # So we just punt and use a minimum line length of 8192. 17540ef0e59aSmrg lt_cv_sys_max_cmd_len=8192; 17550ef0e59aSmrg ;; 17560ef0e59aSmrg 1757d5e6aabbSmrg darwin* | dragonfly* | freebsd* | midnightbsd* | netbsd* | openbsd*) 17580ef0e59aSmrg # This has been around since 386BSD, at least. Likely further. 17590ef0e59aSmrg if test -x /sbin/sysctl; then 17600ef0e59aSmrg lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` 17610ef0e59aSmrg elif test -x /usr/sbin/sysctl; then 17620ef0e59aSmrg lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` 17630ef0e59aSmrg else 17640ef0e59aSmrg lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs 17650ef0e59aSmrg fi 17660ef0e59aSmrg # And add a safety zone 17670ef0e59aSmrg lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` 17680ef0e59aSmrg lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` 17690ef0e59aSmrg ;; 17700ef0e59aSmrg 17710ef0e59aSmrg interix*) 17720ef0e59aSmrg # We know the value 262144 and hardcode it with a safety zone (like BSD) 17730ef0e59aSmrg lt_cv_sys_max_cmd_len=196608 17740ef0e59aSmrg ;; 17750ef0e59aSmrg 17760ef0e59aSmrg os2*) 17770ef0e59aSmrg # The test takes a long time on OS/2. 17780ef0e59aSmrg lt_cv_sys_max_cmd_len=8192 17790ef0e59aSmrg ;; 17800ef0e59aSmrg 17810ef0e59aSmrg osf*) 17820ef0e59aSmrg # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure 17830ef0e59aSmrg # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not 17840ef0e59aSmrg # nice to cause kernel panics so lets avoid the loop below. 17850ef0e59aSmrg # First set a reasonable default. 17860ef0e59aSmrg lt_cv_sys_max_cmd_len=16384 17870ef0e59aSmrg # 17880ef0e59aSmrg if test -x /sbin/sysconfig; then 17890ef0e59aSmrg case `/sbin/sysconfig -q proc exec_disable_arg_limit` in 17900ef0e59aSmrg *1*) lt_cv_sys_max_cmd_len=-1 ;; 17910ef0e59aSmrg esac 17920ef0e59aSmrg fi 17930ef0e59aSmrg ;; 17940ef0e59aSmrg sco3.2v5*) 17950ef0e59aSmrg lt_cv_sys_max_cmd_len=102400 17960ef0e59aSmrg ;; 17970ef0e59aSmrg sysv5* | sco5v6* | sysv4.2uw2*) 17980ef0e59aSmrg kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` 17990ef0e59aSmrg if test -n "$kargmax"; then 180015885c33Smrg lt_cv_sys_max_cmd_len=`echo $kargmax | $SED 's/.*[[ ]]//'` 18010ef0e59aSmrg else 18020ef0e59aSmrg lt_cv_sys_max_cmd_len=32768 18030ef0e59aSmrg fi 18040ef0e59aSmrg ;; 18050ef0e59aSmrg *) 18060ef0e59aSmrg lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` 18070ef0e59aSmrg if test -n "$lt_cv_sys_max_cmd_len" && \ 18080ef0e59aSmrg test undefined != "$lt_cv_sys_max_cmd_len"; then 18090ef0e59aSmrg lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` 18100ef0e59aSmrg lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` 18110ef0e59aSmrg else 18120ef0e59aSmrg # Make teststring a little bigger before we do anything with it. 18130ef0e59aSmrg # a 1K string should be a reasonable start. 18140ef0e59aSmrg for i in 1 2 3 4 5 6 7 8; do 18150ef0e59aSmrg teststring=$teststring$teststring 18160ef0e59aSmrg done 18170ef0e59aSmrg SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} 18180ef0e59aSmrg # If test is not a shell built-in, we'll probably end up computing a 18190ef0e59aSmrg # maximum length that is only half of the actual maximum length, but 18200ef0e59aSmrg # we can't tell. 18210ef0e59aSmrg while { test X`env echo "$teststring$teststring" 2>/dev/null` \ 18220ef0e59aSmrg = "X$teststring$teststring"; } >/dev/null 2>&1 && 18230ef0e59aSmrg test 17 != "$i" # 1/2 MB should be enough 18240ef0e59aSmrg do 18250ef0e59aSmrg i=`expr $i + 1` 18260ef0e59aSmrg teststring=$teststring$teststring 18270ef0e59aSmrg done 18280ef0e59aSmrg # Only check the string length outside the loop. 18290ef0e59aSmrg lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1` 18300ef0e59aSmrg teststring= 18310ef0e59aSmrg # Add a significant safety factor because C++ compilers can tack on 18320ef0e59aSmrg # massive amounts of additional arguments before passing them to the 18330ef0e59aSmrg # linker. It appears as though 1/2 is a usable value. 18340ef0e59aSmrg lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` 18350ef0e59aSmrg fi 18360ef0e59aSmrg ;; 18370ef0e59aSmrg esac 18380ef0e59aSmrg]) 18390ef0e59aSmrgif test -n "$lt_cv_sys_max_cmd_len"; then 18400ef0e59aSmrg AC_MSG_RESULT($lt_cv_sys_max_cmd_len) 18410ef0e59aSmrgelse 18420ef0e59aSmrg AC_MSG_RESULT(none) 18430ef0e59aSmrgfi 18440ef0e59aSmrgmax_cmd_len=$lt_cv_sys_max_cmd_len 18450ef0e59aSmrg_LT_DECL([], [max_cmd_len], [0], 18460ef0e59aSmrg [What is the maximum length of a command?]) 18470ef0e59aSmrg])# LT_CMD_MAX_LEN 18480ef0e59aSmrg 18490ef0e59aSmrg# Old name: 18500ef0e59aSmrgAU_ALIAS([AC_LIBTOOL_SYS_MAX_CMD_LEN], [LT_CMD_MAX_LEN]) 18510ef0e59aSmrgdnl aclocal-1.4 backwards compatibility: 18520ef0e59aSmrgdnl AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], []) 18530ef0e59aSmrg 18540ef0e59aSmrg 18550ef0e59aSmrg# _LT_HEADER_DLFCN 18560ef0e59aSmrg# ---------------- 18570ef0e59aSmrgm4_defun([_LT_HEADER_DLFCN], 18580ef0e59aSmrg[AC_CHECK_HEADERS([dlfcn.h], [], [], [AC_INCLUDES_DEFAULT])dnl 18590ef0e59aSmrg])# _LT_HEADER_DLFCN 18600ef0e59aSmrg 18610ef0e59aSmrg 18620ef0e59aSmrg# _LT_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE, 18630ef0e59aSmrg# ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING) 18640ef0e59aSmrg# ---------------------------------------------------------------- 18650ef0e59aSmrgm4_defun([_LT_TRY_DLOPEN_SELF], 18660ef0e59aSmrg[m4_require([_LT_HEADER_DLFCN])dnl 18670ef0e59aSmrgif test yes = "$cross_compiling"; then : 18680ef0e59aSmrg [$4] 18690ef0e59aSmrgelse 18700ef0e59aSmrg lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 18710ef0e59aSmrg lt_status=$lt_dlunknown 18720ef0e59aSmrg cat > conftest.$ac_ext <<_LT_EOF 18730ef0e59aSmrg[#line $LINENO "configure" 18740ef0e59aSmrg#include "confdefs.h" 18750ef0e59aSmrg 18760ef0e59aSmrg#if HAVE_DLFCN_H 18770ef0e59aSmrg#include <dlfcn.h> 18780ef0e59aSmrg#endif 18790ef0e59aSmrg 18800ef0e59aSmrg#include <stdio.h> 18810ef0e59aSmrg 18820ef0e59aSmrg#ifdef RTLD_GLOBAL 18830ef0e59aSmrg# define LT_DLGLOBAL RTLD_GLOBAL 18840ef0e59aSmrg#else 18850ef0e59aSmrg# ifdef DL_GLOBAL 18860ef0e59aSmrg# define LT_DLGLOBAL DL_GLOBAL 18870ef0e59aSmrg# else 18880ef0e59aSmrg# define LT_DLGLOBAL 0 18890ef0e59aSmrg# endif 18900ef0e59aSmrg#endif 18910ef0e59aSmrg 18920ef0e59aSmrg/* We may have to define LT_DLLAZY_OR_NOW in the command line if we 18930ef0e59aSmrg find out it does not work in some platform. */ 18940ef0e59aSmrg#ifndef LT_DLLAZY_OR_NOW 18950ef0e59aSmrg# ifdef RTLD_LAZY 18960ef0e59aSmrg# define LT_DLLAZY_OR_NOW RTLD_LAZY 18970ef0e59aSmrg# else 18980ef0e59aSmrg# ifdef DL_LAZY 18990ef0e59aSmrg# define LT_DLLAZY_OR_NOW DL_LAZY 19000ef0e59aSmrg# else 19010ef0e59aSmrg# ifdef RTLD_NOW 19020ef0e59aSmrg# define LT_DLLAZY_OR_NOW RTLD_NOW 19030ef0e59aSmrg# else 19040ef0e59aSmrg# ifdef DL_NOW 19050ef0e59aSmrg# define LT_DLLAZY_OR_NOW DL_NOW 19060ef0e59aSmrg# else 19070ef0e59aSmrg# define LT_DLLAZY_OR_NOW 0 19080ef0e59aSmrg# endif 19090ef0e59aSmrg# endif 19100ef0e59aSmrg# endif 19110ef0e59aSmrg# endif 19120ef0e59aSmrg#endif 19130ef0e59aSmrg 19140ef0e59aSmrg/* When -fvisibility=hidden is used, assume the code has been annotated 19150ef0e59aSmrg correspondingly for the symbols needed. */ 19160ef0e59aSmrg#if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) 1917d5e6aabbSmrgint fnord (void) __attribute__((visibility("default"))); 19180ef0e59aSmrg#endif 19190ef0e59aSmrg 1920d5e6aabbSmrgint fnord (void) { return 42; } 1921d5e6aabbSmrgint main (void) 19220ef0e59aSmrg{ 19230ef0e59aSmrg void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); 19240ef0e59aSmrg int status = $lt_dlunknown; 19250ef0e59aSmrg 19260ef0e59aSmrg if (self) 19270ef0e59aSmrg { 19280ef0e59aSmrg if (dlsym (self,"fnord")) status = $lt_dlno_uscore; 19290ef0e59aSmrg else 19300ef0e59aSmrg { 19310ef0e59aSmrg if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; 19320ef0e59aSmrg else puts (dlerror ()); 19330ef0e59aSmrg } 19340ef0e59aSmrg /* dlclose (self); */ 19350ef0e59aSmrg } 19360ef0e59aSmrg else 19370ef0e59aSmrg puts (dlerror ()); 19380ef0e59aSmrg 19390ef0e59aSmrg return status; 19400ef0e59aSmrg}] 19410ef0e59aSmrg_LT_EOF 19420ef0e59aSmrg if AC_TRY_EVAL(ac_link) && test -s "conftest$ac_exeext" 2>/dev/null; then 19430ef0e59aSmrg (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null 19440ef0e59aSmrg lt_status=$? 19450ef0e59aSmrg case x$lt_status in 19460ef0e59aSmrg x$lt_dlno_uscore) $1 ;; 19470ef0e59aSmrg x$lt_dlneed_uscore) $2 ;; 19480ef0e59aSmrg x$lt_dlunknown|x*) $3 ;; 19490ef0e59aSmrg esac 19500ef0e59aSmrg else : 19510ef0e59aSmrg # compilation failed 19520ef0e59aSmrg $3 19530ef0e59aSmrg fi 19540ef0e59aSmrgfi 19550ef0e59aSmrgrm -fr conftest* 19560ef0e59aSmrg])# _LT_TRY_DLOPEN_SELF 19570ef0e59aSmrg 19580ef0e59aSmrg 19590ef0e59aSmrg# LT_SYS_DLOPEN_SELF 19600ef0e59aSmrg# ------------------ 19610ef0e59aSmrgAC_DEFUN([LT_SYS_DLOPEN_SELF], 19620ef0e59aSmrg[m4_require([_LT_HEADER_DLFCN])dnl 19630ef0e59aSmrgif test yes != "$enable_dlopen"; then 19640ef0e59aSmrg enable_dlopen=unknown 19650ef0e59aSmrg enable_dlopen_self=unknown 19660ef0e59aSmrg enable_dlopen_self_static=unknown 19670ef0e59aSmrgelse 19680ef0e59aSmrg lt_cv_dlopen=no 19690ef0e59aSmrg lt_cv_dlopen_libs= 19700ef0e59aSmrg 19710ef0e59aSmrg case $host_os in 19720ef0e59aSmrg beos*) 19730ef0e59aSmrg lt_cv_dlopen=load_add_on 19740ef0e59aSmrg lt_cv_dlopen_libs= 19750ef0e59aSmrg lt_cv_dlopen_self=yes 19760ef0e59aSmrg ;; 19770ef0e59aSmrg 1978d5e6aabbSmrg mingw* | windows* | pw32* | cegcc*) 19790ef0e59aSmrg lt_cv_dlopen=LoadLibrary 19800ef0e59aSmrg lt_cv_dlopen_libs= 19810ef0e59aSmrg ;; 19820ef0e59aSmrg 19830ef0e59aSmrg cygwin*) 19840ef0e59aSmrg lt_cv_dlopen=dlopen 19850ef0e59aSmrg lt_cv_dlopen_libs= 19860ef0e59aSmrg ;; 19870ef0e59aSmrg 19880ef0e59aSmrg darwin*) 19890ef0e59aSmrg # if libdl is installed we need to link against it 19900ef0e59aSmrg AC_CHECK_LIB([dl], [dlopen], 19910ef0e59aSmrg [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl],[ 19920ef0e59aSmrg lt_cv_dlopen=dyld 19930ef0e59aSmrg lt_cv_dlopen_libs= 19940ef0e59aSmrg lt_cv_dlopen_self=yes 19950ef0e59aSmrg ]) 19960ef0e59aSmrg ;; 19970ef0e59aSmrg 19980ef0e59aSmrg tpf*) 19990ef0e59aSmrg # Don't try to run any link tests for TPF. We know it's impossible 20000ef0e59aSmrg # because TPF is a cross-compiler, and we know how we open DSOs. 20010ef0e59aSmrg lt_cv_dlopen=dlopen 20020ef0e59aSmrg lt_cv_dlopen_libs= 20030ef0e59aSmrg lt_cv_dlopen_self=no 20040ef0e59aSmrg ;; 20050ef0e59aSmrg 20060ef0e59aSmrg *) 20070ef0e59aSmrg AC_CHECK_FUNC([shl_load], 20080ef0e59aSmrg [lt_cv_dlopen=shl_load], 20090ef0e59aSmrg [AC_CHECK_LIB([dld], [shl_load], 20100ef0e59aSmrg [lt_cv_dlopen=shl_load lt_cv_dlopen_libs=-ldld], 20110ef0e59aSmrg [AC_CHECK_FUNC([dlopen], 20120ef0e59aSmrg [lt_cv_dlopen=dlopen], 20130ef0e59aSmrg [AC_CHECK_LIB([dl], [dlopen], 20140ef0e59aSmrg [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl], 20150ef0e59aSmrg [AC_CHECK_LIB([svld], [dlopen], 20160ef0e59aSmrg [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-lsvld], 20170ef0e59aSmrg [AC_CHECK_LIB([dld], [dld_link], 20180ef0e59aSmrg [lt_cv_dlopen=dld_link lt_cv_dlopen_libs=-ldld]) 20190ef0e59aSmrg ]) 20200ef0e59aSmrg ]) 20210ef0e59aSmrg ]) 20220ef0e59aSmrg ]) 20230ef0e59aSmrg ]) 20240ef0e59aSmrg ;; 20250ef0e59aSmrg esac 20260ef0e59aSmrg 20270ef0e59aSmrg if test no = "$lt_cv_dlopen"; then 20280ef0e59aSmrg enable_dlopen=no 20290ef0e59aSmrg else 20300ef0e59aSmrg enable_dlopen=yes 20310ef0e59aSmrg fi 20320ef0e59aSmrg 20330ef0e59aSmrg case $lt_cv_dlopen in 20340ef0e59aSmrg dlopen) 20350ef0e59aSmrg save_CPPFLAGS=$CPPFLAGS 20360ef0e59aSmrg test yes = "$ac_cv_header_dlfcn_h" && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" 20370ef0e59aSmrg 20380ef0e59aSmrg save_LDFLAGS=$LDFLAGS 20390ef0e59aSmrg wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" 20400ef0e59aSmrg 20410ef0e59aSmrg save_LIBS=$LIBS 20420ef0e59aSmrg LIBS="$lt_cv_dlopen_libs $LIBS" 20430ef0e59aSmrg 20440ef0e59aSmrg AC_CACHE_CHECK([whether a program can dlopen itself], 20450ef0e59aSmrg lt_cv_dlopen_self, [dnl 20460ef0e59aSmrg _LT_TRY_DLOPEN_SELF( 20470ef0e59aSmrg lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes, 20480ef0e59aSmrg lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross) 20490ef0e59aSmrg ]) 20500ef0e59aSmrg 20510ef0e59aSmrg if test yes = "$lt_cv_dlopen_self"; then 20520ef0e59aSmrg wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" 20530ef0e59aSmrg AC_CACHE_CHECK([whether a statically linked program can dlopen itself], 20540ef0e59aSmrg lt_cv_dlopen_self_static, [dnl 20550ef0e59aSmrg _LT_TRY_DLOPEN_SELF( 20560ef0e59aSmrg lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes, 20570ef0e59aSmrg lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross) 20580ef0e59aSmrg ]) 20590ef0e59aSmrg fi 20600ef0e59aSmrg 20610ef0e59aSmrg CPPFLAGS=$save_CPPFLAGS 20620ef0e59aSmrg LDFLAGS=$save_LDFLAGS 20630ef0e59aSmrg LIBS=$save_LIBS 20640ef0e59aSmrg ;; 20650ef0e59aSmrg esac 20660ef0e59aSmrg 20670ef0e59aSmrg case $lt_cv_dlopen_self in 20680ef0e59aSmrg yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; 20690ef0e59aSmrg *) enable_dlopen_self=unknown ;; 20700ef0e59aSmrg esac 20710ef0e59aSmrg 20720ef0e59aSmrg case $lt_cv_dlopen_self_static in 20730ef0e59aSmrg yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; 20740ef0e59aSmrg *) enable_dlopen_self_static=unknown ;; 20750ef0e59aSmrg esac 20760ef0e59aSmrgfi 20770ef0e59aSmrg_LT_DECL([dlopen_support], [enable_dlopen], [0], 20780ef0e59aSmrg [Whether dlopen is supported]) 20790ef0e59aSmrg_LT_DECL([dlopen_self], [enable_dlopen_self], [0], 20800ef0e59aSmrg [Whether dlopen of programs is supported]) 20810ef0e59aSmrg_LT_DECL([dlopen_self_static], [enable_dlopen_self_static], [0], 20820ef0e59aSmrg [Whether dlopen of statically linked programs is supported]) 20830ef0e59aSmrg])# LT_SYS_DLOPEN_SELF 20840ef0e59aSmrg 20850ef0e59aSmrg# Old name: 20860ef0e59aSmrgAU_ALIAS([AC_LIBTOOL_DLOPEN_SELF], [LT_SYS_DLOPEN_SELF]) 20870ef0e59aSmrgdnl aclocal-1.4 backwards compatibility: 20880ef0e59aSmrgdnl AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], []) 20890ef0e59aSmrg 20900ef0e59aSmrg 20910ef0e59aSmrg# _LT_COMPILER_C_O([TAGNAME]) 20920ef0e59aSmrg# --------------------------- 20930ef0e59aSmrg# Check to see if options -c and -o are simultaneously supported by compiler. 20940ef0e59aSmrg# This macro does not hard code the compiler like AC_PROG_CC_C_O. 20950ef0e59aSmrgm4_defun([_LT_COMPILER_C_O], 20960ef0e59aSmrg[m4_require([_LT_DECL_SED])dnl 20970ef0e59aSmrgm4_require([_LT_FILEUTILS_DEFAULTS])dnl 20980ef0e59aSmrgm4_require([_LT_TAG_COMPILER])dnl 20990ef0e59aSmrgAC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext], 21000ef0e59aSmrg [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)], 21010ef0e59aSmrg [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no 21020ef0e59aSmrg $RM -r conftest 2>/dev/null 21030ef0e59aSmrg mkdir conftest 21040ef0e59aSmrg cd conftest 21050ef0e59aSmrg mkdir out 21060ef0e59aSmrg echo "$lt_simple_compile_test_code" > conftest.$ac_ext 21070ef0e59aSmrg 21080ef0e59aSmrg lt_compiler_flag="-o out/conftest2.$ac_objext" 21090ef0e59aSmrg # Insert the option either (1) after the last *FLAGS variable, or 21100ef0e59aSmrg # (2) before a word containing "conftest.", or (3) at the end. 21110ef0e59aSmrg # Note that $ac_compile itself does not contain backslashes and begins 21120ef0e59aSmrg # with a dollar sign (not a hyphen), so the echo should work correctly. 21130ef0e59aSmrg lt_compile=`echo "$ac_compile" | $SED \ 21140ef0e59aSmrg -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ 21150ef0e59aSmrg -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ 21160ef0e59aSmrg -e 's:$: $lt_compiler_flag:'` 21170ef0e59aSmrg (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD) 21180ef0e59aSmrg (eval "$lt_compile" 2>out/conftest.err) 21190ef0e59aSmrg ac_status=$? 21200ef0e59aSmrg cat out/conftest.err >&AS_MESSAGE_LOG_FD 21210ef0e59aSmrg echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD 21220ef0e59aSmrg if (exit $ac_status) && test -s out/conftest2.$ac_objext 21230ef0e59aSmrg then 21240ef0e59aSmrg # The compiler can only warn and ignore the option if not recognized 21250ef0e59aSmrg # So say no if there are warnings 21260ef0e59aSmrg $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp 21270ef0e59aSmrg $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 21280ef0e59aSmrg if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then 21290ef0e59aSmrg _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes 21300ef0e59aSmrg fi 21310ef0e59aSmrg fi 21320ef0e59aSmrg chmod u+w . 2>&AS_MESSAGE_LOG_FD 21330ef0e59aSmrg $RM conftest* 21340ef0e59aSmrg # SGI C++ compiler will create directory out/ii_files/ for 21350ef0e59aSmrg # template instantiation 21360ef0e59aSmrg test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files 21370ef0e59aSmrg $RM out/* && rmdir out 21380ef0e59aSmrg cd .. 21390ef0e59aSmrg $RM -r conftest 21400ef0e59aSmrg $RM conftest* 21410ef0e59aSmrg]) 21420ef0e59aSmrg_LT_TAGDECL([compiler_c_o], [lt_cv_prog_compiler_c_o], [1], 21430ef0e59aSmrg [Does compiler simultaneously support -c and -o options?]) 21440ef0e59aSmrg])# _LT_COMPILER_C_O 21450ef0e59aSmrg 21460ef0e59aSmrg 21470ef0e59aSmrg# _LT_COMPILER_FILE_LOCKS([TAGNAME]) 21480ef0e59aSmrg# ---------------------------------- 21490ef0e59aSmrg# Check to see if we can do hard links to lock some files if needed 21500ef0e59aSmrgm4_defun([_LT_COMPILER_FILE_LOCKS], 21510ef0e59aSmrg[m4_require([_LT_ENABLE_LOCK])dnl 21520ef0e59aSmrgm4_require([_LT_FILEUTILS_DEFAULTS])dnl 21530ef0e59aSmrg_LT_COMPILER_C_O([$1]) 21540ef0e59aSmrg 21550ef0e59aSmrghard_links=nottested 21560ef0e59aSmrgif test no = "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" && test no != "$need_locks"; then 21570ef0e59aSmrg # do not overwrite the value of need_locks provided by the user 21580ef0e59aSmrg AC_MSG_CHECKING([if we can lock with hard links]) 21590ef0e59aSmrg hard_links=yes 21600ef0e59aSmrg $RM conftest* 21610ef0e59aSmrg ln conftest.a conftest.b 2>/dev/null && hard_links=no 21620ef0e59aSmrg touch conftest.a 21630ef0e59aSmrg ln conftest.a conftest.b 2>&5 || hard_links=no 21640ef0e59aSmrg ln conftest.a conftest.b 2>/dev/null && hard_links=no 21650ef0e59aSmrg AC_MSG_RESULT([$hard_links]) 21660ef0e59aSmrg if test no = "$hard_links"; then 21670ef0e59aSmrg AC_MSG_WARN(['$CC' does not support '-c -o', so 'make -j' may be unsafe]) 21680ef0e59aSmrg need_locks=warn 21690ef0e59aSmrg fi 21700ef0e59aSmrgelse 21710ef0e59aSmrg need_locks=no 21720ef0e59aSmrgfi 21730ef0e59aSmrg_LT_DECL([], [need_locks], [1], [Must we lock files when doing compilation?]) 21740ef0e59aSmrg])# _LT_COMPILER_FILE_LOCKS 21750ef0e59aSmrg 21760ef0e59aSmrg 21770ef0e59aSmrg# _LT_CHECK_OBJDIR 21780ef0e59aSmrg# ---------------- 21790ef0e59aSmrgm4_defun([_LT_CHECK_OBJDIR], 21800ef0e59aSmrg[AC_CACHE_CHECK([for objdir], [lt_cv_objdir], 21810ef0e59aSmrg[rm -f .libs 2>/dev/null 21820ef0e59aSmrgmkdir .libs 2>/dev/null 21830ef0e59aSmrgif test -d .libs; then 21840ef0e59aSmrg lt_cv_objdir=.libs 21850ef0e59aSmrgelse 21860ef0e59aSmrg # MS-DOS does not allow filenames that begin with a dot. 21870ef0e59aSmrg lt_cv_objdir=_libs 21880ef0e59aSmrgfi 21890ef0e59aSmrgrmdir .libs 2>/dev/null]) 21900ef0e59aSmrgobjdir=$lt_cv_objdir 21910ef0e59aSmrg_LT_DECL([], [objdir], [0], 21920ef0e59aSmrg [The name of the directory that contains temporary libtool files])dnl 21930ef0e59aSmrgm4_pattern_allow([LT_OBJDIR])dnl 21940ef0e59aSmrgAC_DEFINE_UNQUOTED([LT_OBJDIR], "$lt_cv_objdir/", 21950ef0e59aSmrg [Define to the sub-directory where libtool stores uninstalled libraries.]) 21960ef0e59aSmrg])# _LT_CHECK_OBJDIR 21970ef0e59aSmrg 21980ef0e59aSmrg 21990ef0e59aSmrg# _LT_LINKER_HARDCODE_LIBPATH([TAGNAME]) 22000ef0e59aSmrg# -------------------------------------- 22010ef0e59aSmrg# Check hardcoding attributes. 22020ef0e59aSmrgm4_defun([_LT_LINKER_HARDCODE_LIBPATH], 22030ef0e59aSmrg[AC_MSG_CHECKING([how to hardcode library paths into programs]) 22040ef0e59aSmrg_LT_TAGVAR(hardcode_action, $1)= 22050ef0e59aSmrgif test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" || 22060ef0e59aSmrg test -n "$_LT_TAGVAR(runpath_var, $1)" || 22070ef0e59aSmrg test yes = "$_LT_TAGVAR(hardcode_automatic, $1)"; then 22080ef0e59aSmrg 22090ef0e59aSmrg # We can hardcode non-existent directories. 22100ef0e59aSmrg if test no != "$_LT_TAGVAR(hardcode_direct, $1)" && 22110ef0e59aSmrg # If the only mechanism to avoid hardcoding is shlibpath_var, we 22120ef0e59aSmrg # have to relink, otherwise we might link with an installed library 22130ef0e59aSmrg # when we should be linking with a yet-to-be-installed one 22140ef0e59aSmrg ## test no != "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" && 22150ef0e59aSmrg test no != "$_LT_TAGVAR(hardcode_minus_L, $1)"; then 22160ef0e59aSmrg # Linking always hardcodes the temporary library directory. 22170ef0e59aSmrg _LT_TAGVAR(hardcode_action, $1)=relink 22180ef0e59aSmrg else 22190ef0e59aSmrg # We can link without hardcoding, and we can hardcode nonexisting dirs. 22200ef0e59aSmrg _LT_TAGVAR(hardcode_action, $1)=immediate 22210ef0e59aSmrg fi 22220ef0e59aSmrgelse 22230ef0e59aSmrg # We cannot hardcode anything, or else we can only hardcode existing 22240ef0e59aSmrg # directories. 22250ef0e59aSmrg _LT_TAGVAR(hardcode_action, $1)=unsupported 22260ef0e59aSmrgfi 22270ef0e59aSmrgAC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)]) 22280ef0e59aSmrg 22290ef0e59aSmrgif test relink = "$_LT_TAGVAR(hardcode_action, $1)" || 22300ef0e59aSmrg test yes = "$_LT_TAGVAR(inherit_rpath, $1)"; then 22310ef0e59aSmrg # Fast installation is not supported 22320ef0e59aSmrg enable_fast_install=no 22330ef0e59aSmrgelif test yes = "$shlibpath_overrides_runpath" || 22340ef0e59aSmrg test no = "$enable_shared"; then 22350ef0e59aSmrg # Fast installation is not necessary 22360ef0e59aSmrg enable_fast_install=needless 22370ef0e59aSmrgfi 22380ef0e59aSmrg_LT_TAGDECL([], [hardcode_action], [0], 22390ef0e59aSmrg [How to hardcode a shared library path into an executable]) 22400ef0e59aSmrg])# _LT_LINKER_HARDCODE_LIBPATH 22410ef0e59aSmrg 22420ef0e59aSmrg 22430ef0e59aSmrg# _LT_CMD_STRIPLIB 22440ef0e59aSmrg# ---------------- 22450ef0e59aSmrgm4_defun([_LT_CMD_STRIPLIB], 22460ef0e59aSmrg[m4_require([_LT_DECL_EGREP]) 22470ef0e59aSmrgstriplib= 22480ef0e59aSmrgold_striplib= 22490ef0e59aSmrgAC_MSG_CHECKING([whether stripping libraries is possible]) 225015885c33Smrgif test -z "$STRIP"; then 225115885c33Smrg AC_MSG_RESULT([no]) 22520ef0e59aSmrgelse 225315885c33Smrg if $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then 225415885c33Smrg old_striplib="$STRIP --strip-debug" 225515885c33Smrg striplib="$STRIP --strip-unneeded" 225615885c33Smrg AC_MSG_RESULT([yes]) 225715885c33Smrg else 225815885c33Smrg case $host_os in 225915885c33Smrg darwin*) 226015885c33Smrg # FIXME - insert some real tests, host_os isn't really good enough 22610ef0e59aSmrg striplib="$STRIP -x" 22620ef0e59aSmrg old_striplib="$STRIP -S" 22630ef0e59aSmrg AC_MSG_RESULT([yes]) 226415885c33Smrg ;; 226515885c33Smrg freebsd*) 226615885c33Smrg if $STRIP -V 2>&1 | $GREP "elftoolchain" >/dev/null; then 226715885c33Smrg old_striplib="$STRIP --strip-debug" 226815885c33Smrg striplib="$STRIP --strip-unneeded" 226915885c33Smrg AC_MSG_RESULT([yes]) 227015885c33Smrg else 227115885c33Smrg AC_MSG_RESULT([no]) 227215885c33Smrg fi 227315885c33Smrg ;; 227415885c33Smrg *) 22750ef0e59aSmrg AC_MSG_RESULT([no]) 227615885c33Smrg ;; 227715885c33Smrg esac 227815885c33Smrg fi 22790ef0e59aSmrgfi 22800ef0e59aSmrg_LT_DECL([], [old_striplib], [1], [Commands to strip libraries]) 22810ef0e59aSmrg_LT_DECL([], [striplib], [1]) 22820ef0e59aSmrg])# _LT_CMD_STRIPLIB 22830ef0e59aSmrg 22840ef0e59aSmrg 22850ef0e59aSmrg# _LT_PREPARE_MUNGE_PATH_LIST 22860ef0e59aSmrg# --------------------------- 22870ef0e59aSmrg# Make sure func_munge_path_list() is defined correctly. 22880ef0e59aSmrgm4_defun([_LT_PREPARE_MUNGE_PATH_LIST], 22890ef0e59aSmrg[[# func_munge_path_list VARIABLE PATH 22900ef0e59aSmrg# ----------------------------------- 22910ef0e59aSmrg# VARIABLE is name of variable containing _space_ separated list of 22920ef0e59aSmrg# directories to be munged by the contents of PATH, which is string 22930ef0e59aSmrg# having a format: 22940ef0e59aSmrg# "DIR[:DIR]:" 22950ef0e59aSmrg# string "DIR[ DIR]" will be prepended to VARIABLE 22960ef0e59aSmrg# ":DIR[:DIR]" 22970ef0e59aSmrg# string "DIR[ DIR]" will be appended to VARIABLE 22980ef0e59aSmrg# "DIRP[:DIRP]::[DIRA:]DIRA" 22990ef0e59aSmrg# string "DIRP[ DIRP]" will be prepended to VARIABLE and string 23000ef0e59aSmrg# "DIRA[ DIRA]" will be appended to VARIABLE 23010ef0e59aSmrg# "DIR[:DIR]" 23020ef0e59aSmrg# VARIABLE will be replaced by "DIR[ DIR]" 23030ef0e59aSmrgfunc_munge_path_list () 23040ef0e59aSmrg{ 23050ef0e59aSmrg case x@S|@2 in 23060ef0e59aSmrg x) 23070ef0e59aSmrg ;; 23080ef0e59aSmrg *:) 23090ef0e59aSmrg eval @S|@1=\"`$ECHO @S|@2 | $SED 's/:/ /g'` \@S|@@S|@1\" 23100ef0e59aSmrg ;; 23110ef0e59aSmrg x:*) 23120ef0e59aSmrg eval @S|@1=\"\@S|@@S|@1 `$ECHO @S|@2 | $SED 's/:/ /g'`\" 23130ef0e59aSmrg ;; 23140ef0e59aSmrg *::*) 23150ef0e59aSmrg eval @S|@1=\"\@S|@@S|@1\ `$ECHO @S|@2 | $SED -e 's/.*:://' -e 's/:/ /g'`\" 23160ef0e59aSmrg eval @S|@1=\"`$ECHO @S|@2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \@S|@@S|@1\" 23170ef0e59aSmrg ;; 23180ef0e59aSmrg *) 23190ef0e59aSmrg eval @S|@1=\"`$ECHO @S|@2 | $SED 's/:/ /g'`\" 23200ef0e59aSmrg ;; 23210ef0e59aSmrg esac 23220ef0e59aSmrg} 23230ef0e59aSmrg]])# _LT_PREPARE_PATH_LIST 23240ef0e59aSmrg 23250ef0e59aSmrg 23260ef0e59aSmrg# _LT_SYS_DYNAMIC_LINKER([TAG]) 23270ef0e59aSmrg# ----------------------------- 23280ef0e59aSmrg# PORTME Fill in your ld.so characteristics 23290ef0e59aSmrgm4_defun([_LT_SYS_DYNAMIC_LINKER], 23300ef0e59aSmrg[AC_REQUIRE([AC_CANONICAL_HOST])dnl 23310ef0e59aSmrgm4_require([_LT_DECL_EGREP])dnl 23320ef0e59aSmrgm4_require([_LT_FILEUTILS_DEFAULTS])dnl 23330ef0e59aSmrgm4_require([_LT_DECL_OBJDUMP])dnl 23340ef0e59aSmrgm4_require([_LT_DECL_SED])dnl 23350ef0e59aSmrgm4_require([_LT_CHECK_SHELL_FEATURES])dnl 23360ef0e59aSmrgm4_require([_LT_PREPARE_MUNGE_PATH_LIST])dnl 23370ef0e59aSmrgAC_MSG_CHECKING([dynamic linker characteristics]) 23380ef0e59aSmrgm4_if([$1], 23390ef0e59aSmrg [], [ 23400ef0e59aSmrgif test yes = "$GCC"; then 23410ef0e59aSmrg case $host_os in 23420ef0e59aSmrg darwin*) lt_awk_arg='/^libraries:/,/LR/' ;; 23430ef0e59aSmrg *) lt_awk_arg='/^libraries:/' ;; 23440ef0e59aSmrg esac 23450ef0e59aSmrg case $host_os in 2346d5e6aabbSmrg mingw* | windows* | cegcc*) lt_sed_strip_eq='s|=\([[A-Za-z]]:\)|\1|g' ;; 23470ef0e59aSmrg *) lt_sed_strip_eq='s|=/|/|g' ;; 23480ef0e59aSmrg esac 23490ef0e59aSmrg lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq` 23500ef0e59aSmrg case $lt_search_path_spec in 23510ef0e59aSmrg *\;*) 23520ef0e59aSmrg # if the path contains ";" then we assume it to be the separator 23530ef0e59aSmrg # otherwise default to the standard path separator (i.e. ":") - it is 23540ef0e59aSmrg # assumed that no part of a normal pathname contains ";" but that should 23550ef0e59aSmrg # okay in the real world where ";" in dirpaths is itself problematic. 23560ef0e59aSmrg lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'` 23570ef0e59aSmrg ;; 23580ef0e59aSmrg *) 23590ef0e59aSmrg lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"` 23600ef0e59aSmrg ;; 23610ef0e59aSmrg esac 23620ef0e59aSmrg # Ok, now we have the path, separated by spaces, we can step through it 23630ef0e59aSmrg # and add multilib dir if necessary... 23640ef0e59aSmrg lt_tmp_lt_search_path_spec= 23650ef0e59aSmrg lt_multi_os_dir=/`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` 23660ef0e59aSmrg # ...but if some path component already ends with the multilib dir we assume 23670ef0e59aSmrg # that all is fine and trust -print-search-dirs as is (GCC 4.2? or newer). 23680ef0e59aSmrg case "$lt_multi_os_dir; $lt_search_path_spec " in 23690ef0e59aSmrg "/; "* | "/.; "* | "/./; "* | *"$lt_multi_os_dir "* | *"$lt_multi_os_dir/ "*) 23700ef0e59aSmrg lt_multi_os_dir= 23710ef0e59aSmrg ;; 23720ef0e59aSmrg esac 23730ef0e59aSmrg for lt_sys_path in $lt_search_path_spec; do 23740ef0e59aSmrg if test -d "$lt_sys_path$lt_multi_os_dir"; then 23750ef0e59aSmrg lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path$lt_multi_os_dir" 23760ef0e59aSmrg elif test -n "$lt_multi_os_dir"; then 23770ef0e59aSmrg test -d "$lt_sys_path" && \ 23780ef0e59aSmrg lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" 23790ef0e59aSmrg fi 23800ef0e59aSmrg done 23810ef0e59aSmrg lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk ' 23820ef0e59aSmrgBEGIN {RS = " "; FS = "/|\n";} { 23830ef0e59aSmrg lt_foo = ""; 23840ef0e59aSmrg lt_count = 0; 23850ef0e59aSmrg for (lt_i = NF; lt_i > 0; lt_i--) { 23860ef0e59aSmrg if ($lt_i != "" && $lt_i != ".") { 23870ef0e59aSmrg if ($lt_i == "..") { 23880ef0e59aSmrg lt_count++; 23890ef0e59aSmrg } else { 23900ef0e59aSmrg if (lt_count == 0) { 23910ef0e59aSmrg lt_foo = "/" $lt_i lt_foo; 23920ef0e59aSmrg } else { 23930ef0e59aSmrg lt_count--; 23940ef0e59aSmrg } 23950ef0e59aSmrg } 23960ef0e59aSmrg } 23970ef0e59aSmrg } 23980ef0e59aSmrg if (lt_foo != "") { lt_freq[[lt_foo]]++; } 23990ef0e59aSmrg if (lt_freq[[lt_foo]] == 1) { print lt_foo; } 24000ef0e59aSmrg}'` 24010ef0e59aSmrg # AWK program above erroneously prepends '/' to C:/dos/paths 24020ef0e59aSmrg # for these hosts. 24030ef0e59aSmrg case $host_os in 2404d5e6aabbSmrg mingw* | windows* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ 24050ef0e59aSmrg $SED 's|/\([[A-Za-z]]:\)|\1|g'` ;; 24060ef0e59aSmrg esac 24070ef0e59aSmrg sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP` 24080ef0e59aSmrgelse 24090ef0e59aSmrg sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" 24100ef0e59aSmrgfi]) 24110ef0e59aSmrglibrary_names_spec= 24120ef0e59aSmrglibname_spec='lib$name' 24130ef0e59aSmrgsoname_spec= 24140ef0e59aSmrgshrext_cmds=.so 24150ef0e59aSmrgpostinstall_cmds= 24160ef0e59aSmrgpostuninstall_cmds= 24170ef0e59aSmrgfinish_cmds= 24180ef0e59aSmrgfinish_eval= 24190ef0e59aSmrgshlibpath_var= 24200ef0e59aSmrgshlibpath_overrides_runpath=unknown 24210ef0e59aSmrgversion_type=none 24220ef0e59aSmrgdynamic_linker="$host_os ld.so" 24230ef0e59aSmrgsys_lib_dlsearch_path_spec="/lib /usr/lib" 24240ef0e59aSmrgneed_lib_prefix=unknown 24250ef0e59aSmrghardcode_into_libs=no 24260ef0e59aSmrg 24270ef0e59aSmrg# when you set need_version to no, make sure it does not cause -set_version 24280ef0e59aSmrg# flags to be left without arguments 24290ef0e59aSmrgneed_version=unknown 24300ef0e59aSmrg 24310ef0e59aSmrgAC_ARG_VAR([LT_SYS_LIBRARY_PATH], 24320ef0e59aSmrg[User-defined run-time library search path.]) 24330ef0e59aSmrg 24340ef0e59aSmrgcase $host_os in 24350ef0e59aSmrgaix3*) 24360ef0e59aSmrg version_type=linux # correct to gnu/linux during the next big refactor 24370ef0e59aSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname.a' 24380ef0e59aSmrg shlibpath_var=LIBPATH 24390ef0e59aSmrg 24400ef0e59aSmrg # AIX 3 has no versioning support, so we append a major version to the name. 24410ef0e59aSmrg soname_spec='$libname$release$shared_ext$major' 24420ef0e59aSmrg ;; 24430ef0e59aSmrg 24440ef0e59aSmrgaix[[4-9]]*) 24450ef0e59aSmrg version_type=linux # correct to gnu/linux during the next big refactor 24460ef0e59aSmrg need_lib_prefix=no 24470ef0e59aSmrg need_version=no 24480ef0e59aSmrg hardcode_into_libs=yes 24490ef0e59aSmrg if test ia64 = "$host_cpu"; then 24500ef0e59aSmrg # AIX 5 supports IA64 24510ef0e59aSmrg library_names_spec='$libname$release$shared_ext$major $libname$release$shared_ext$versuffix $libname$shared_ext' 24520ef0e59aSmrg shlibpath_var=LD_LIBRARY_PATH 24530ef0e59aSmrg else 24540ef0e59aSmrg # With GCC up to 2.95.x, collect2 would create an import file 24550ef0e59aSmrg # for dependence libraries. The import file would start with 24560ef0e59aSmrg # the line '#! .'. This would cause the generated library to 24570ef0e59aSmrg # depend on '.', always an invalid library. This was fixed in 24580ef0e59aSmrg # development snapshots of GCC prior to 3.0. 24590ef0e59aSmrg case $host_os in 24600ef0e59aSmrg aix4 | aix4.[[01]] | aix4.[[01]].*) 24610ef0e59aSmrg if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' 24620ef0e59aSmrg echo ' yes ' 24630ef0e59aSmrg echo '#endif'; } | $CC -E - | $GREP yes > /dev/null; then 24640ef0e59aSmrg : 24650ef0e59aSmrg else 24660ef0e59aSmrg can_build_shared=no 24670ef0e59aSmrg fi 24680ef0e59aSmrg ;; 24690ef0e59aSmrg esac 24700ef0e59aSmrg # Using Import Files as archive members, it is possible to support 24710ef0e59aSmrg # filename-based versioning of shared library archives on AIX. While 24720ef0e59aSmrg # this would work for both with and without runtime linking, it will 24730ef0e59aSmrg # prevent static linking of such archives. So we do filename-based 24740ef0e59aSmrg # shared library versioning with .so extension only, which is used 24750ef0e59aSmrg # when both runtime linking and shared linking is enabled. 24760ef0e59aSmrg # Unfortunately, runtime linking may impact performance, so we do 24770ef0e59aSmrg # not want this to be the default eventually. Also, we use the 24780ef0e59aSmrg # versioned .so libs for executables only if there is the -brtl 2479d5e6aabbSmrg # linker flag in LDFLAGS as well, or --enable-aix-soname=svr4 only. 24800ef0e59aSmrg # To allow for filename-based versioning support, we need to create 24810ef0e59aSmrg # libNAME.so.V as an archive file, containing: 24820ef0e59aSmrg # *) an Import File, referring to the versioned filename of the 24830ef0e59aSmrg # archive as well as the shared archive member, telling the 24840ef0e59aSmrg # bitwidth (32 or 64) of that shared object, and providing the 24850ef0e59aSmrg # list of exported symbols of that shared object, eventually 24860ef0e59aSmrg # decorated with the 'weak' keyword 24870ef0e59aSmrg # *) the shared object with the F_LOADONLY flag set, to really avoid 24880ef0e59aSmrg # it being seen by the linker. 24890ef0e59aSmrg # At run time we better use the real file rather than another symlink, 24900ef0e59aSmrg # but for link time we create the symlink libNAME.so -> libNAME.so.V 24910ef0e59aSmrg 24920ef0e59aSmrg case $with_aix_soname,$aix_use_runtimelinking in 24930ef0e59aSmrg # AIX (on Power*) has no versioning support, so currently we cannot hardcode correct 24940ef0e59aSmrg # soname into executable. Probably we can add versioning support to 24950ef0e59aSmrg # collect2, so additional links can be useful in future. 24960ef0e59aSmrg aix,yes) # traditional libtool 24970ef0e59aSmrg dynamic_linker='AIX unversionable lib.so' 24980ef0e59aSmrg # If using run time linking (on AIX 4.2 or later) use lib<name>.so 24990ef0e59aSmrg # instead of lib<name>.a to let people know that these are not 25000ef0e59aSmrg # typical AIX shared libraries. 25010ef0e59aSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 25020ef0e59aSmrg ;; 25030ef0e59aSmrg aix,no) # traditional AIX only 25040ef0e59aSmrg dynamic_linker='AIX lib.a[(]lib.so.V[)]' 25050ef0e59aSmrg # We preserve .a as extension for shared libraries through AIX4.2 25060ef0e59aSmrg # and later when we are not doing run time linking. 25070ef0e59aSmrg library_names_spec='$libname$release.a $libname.a' 25080ef0e59aSmrg soname_spec='$libname$release$shared_ext$major' 25090ef0e59aSmrg ;; 25100ef0e59aSmrg svr4,*) # full svr4 only 25110ef0e59aSmrg dynamic_linker="AIX lib.so.V[(]$shared_archive_member_spec.o[)]" 25120ef0e59aSmrg library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' 25130ef0e59aSmrg # We do not specify a path in Import Files, so LIBPATH fires. 25140ef0e59aSmrg shlibpath_overrides_runpath=yes 25150ef0e59aSmrg ;; 25160ef0e59aSmrg *,yes) # both, prefer svr4 25170ef0e59aSmrg dynamic_linker="AIX lib.so.V[(]$shared_archive_member_spec.o[)], lib.a[(]lib.so.V[)]" 25180ef0e59aSmrg library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' 25190ef0e59aSmrg # unpreferred sharedlib libNAME.a needs extra handling 25200ef0e59aSmrg postinstall_cmds='test -n "$linkname" || linkname="$realname"~func_stripname "" ".so" "$linkname"~$install_shared_prog "$dir/$func_stripname_result.$libext" "$destdir/$func_stripname_result.$libext"~test -z "$tstripme" || test -z "$striplib" || $striplib "$destdir/$func_stripname_result.$libext"' 25210ef0e59aSmrg postuninstall_cmds='for n in $library_names $old_library; do :; done~func_stripname "" ".so" "$n"~test "$func_stripname_result" = "$n" || func_append rmfiles " $odir/$func_stripname_result.$libext"' 25220ef0e59aSmrg # We do not specify a path in Import Files, so LIBPATH fires. 25230ef0e59aSmrg shlibpath_overrides_runpath=yes 25240ef0e59aSmrg ;; 25250ef0e59aSmrg *,no) # both, prefer aix 25260ef0e59aSmrg dynamic_linker="AIX lib.a[(]lib.so.V[)], lib.so.V[(]$shared_archive_member_spec.o[)]" 25270ef0e59aSmrg library_names_spec='$libname$release.a $libname.a' 25280ef0e59aSmrg soname_spec='$libname$release$shared_ext$major' 25290ef0e59aSmrg # unpreferred sharedlib libNAME.so.V and symlink libNAME.so need extra handling 25300ef0e59aSmrg postinstall_cmds='test -z "$dlname" || $install_shared_prog $dir/$dlname $destdir/$dlname~test -z "$tstripme" || test -z "$striplib" || $striplib $destdir/$dlname~test -n "$linkname" || linkname=$realname~func_stripname "" ".a" "$linkname"~(cd "$destdir" && $LN_S -f $dlname $func_stripname_result.so)' 25310ef0e59aSmrg postuninstall_cmds='test -z "$dlname" || func_append rmfiles " $odir/$dlname"~for n in $old_library $library_names; do :; done~func_stripname "" ".a" "$n"~func_append rmfiles " $odir/$func_stripname_result.so"' 25320ef0e59aSmrg ;; 25330ef0e59aSmrg esac 25340ef0e59aSmrg shlibpath_var=LIBPATH 25350ef0e59aSmrg fi 25360ef0e59aSmrg ;; 25370ef0e59aSmrg 25380ef0e59aSmrgamigaos*) 25390ef0e59aSmrg case $host_cpu in 25400ef0e59aSmrg powerpc) 25410ef0e59aSmrg # Since July 2007 AmigaOS4 officially supports .so libraries. 25420ef0e59aSmrg # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. 25430ef0e59aSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 25440ef0e59aSmrg ;; 25450ef0e59aSmrg m68k) 25460ef0e59aSmrg library_names_spec='$libname.ixlibrary $libname.a' 25470ef0e59aSmrg # Create ${libname}_ixlibrary.a entries in /sys/libs. 25480ef0e59aSmrg finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' 25490ef0e59aSmrg ;; 25500ef0e59aSmrg esac 25510ef0e59aSmrg ;; 25520ef0e59aSmrg 25530ef0e59aSmrgbeos*) 25540ef0e59aSmrg library_names_spec='$libname$shared_ext' 25550ef0e59aSmrg dynamic_linker="$host_os ld.so" 25560ef0e59aSmrg shlibpath_var=LIBRARY_PATH 25570ef0e59aSmrg ;; 25580ef0e59aSmrg 25590ef0e59aSmrgbsdi[[45]]*) 25600ef0e59aSmrg version_type=linux # correct to gnu/linux during the next big refactor 25610ef0e59aSmrg need_version=no 25620ef0e59aSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 25630ef0e59aSmrg soname_spec='$libname$release$shared_ext$major' 25640ef0e59aSmrg finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' 25650ef0e59aSmrg shlibpath_var=LD_LIBRARY_PATH 25660ef0e59aSmrg sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" 25670ef0e59aSmrg sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" 25680ef0e59aSmrg # the default ld.so.conf also contains /usr/contrib/lib and 25690ef0e59aSmrg # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow 25700ef0e59aSmrg # libtool to hard-code these into programs 25710ef0e59aSmrg ;; 25720ef0e59aSmrg 2573d5e6aabbSmrgcygwin* | mingw* | windows* | pw32* | cegcc*) 25740ef0e59aSmrg version_type=windows 25750ef0e59aSmrg shrext_cmds=.dll 25760ef0e59aSmrg need_version=no 25770ef0e59aSmrg need_lib_prefix=no 25780ef0e59aSmrg 25790ef0e59aSmrg case $GCC,$cc_basename in 25800ef0e59aSmrg yes,*) 25810ef0e59aSmrg # gcc 25820ef0e59aSmrg library_names_spec='$libname.dll.a' 25830ef0e59aSmrg # DLL is installed to $(libdir)/../bin by postinstall_cmds 2584d5e6aabbSmrg # If user builds GCC with multilib enabled, 2585d5e6aabbSmrg # it should just install on $(libdir) 2586d5e6aabbSmrg # not on $(libdir)/../bin or 32 bits dlls would override 64 bit ones. 2587d5e6aabbSmrg if test xyes = x"$multilib"; then 2588d5e6aabbSmrg postinstall_cmds='base_file=`basename \$file`~ 2589d5e6aabbSmrg dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ 2590d5e6aabbSmrg dldir=$destdir/`dirname \$dlpath`~ 2591d5e6aabbSmrg $install_prog $dir/$dlname $destdir/$dlname~ 2592d5e6aabbSmrg chmod a+x $destdir/$dlname~ 2593d5e6aabbSmrg if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then 2594d5e6aabbSmrg eval '\''$striplib $destdir/$dlname'\'' || exit \$?; 2595d5e6aabbSmrg fi' 2596d5e6aabbSmrg else 2597d5e6aabbSmrg postinstall_cmds='base_file=`basename \$file`~ 2598d5e6aabbSmrg dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ 2599d5e6aabbSmrg dldir=$destdir/`dirname \$dlpath`~ 2600d5e6aabbSmrg test -d \$dldir || mkdir -p \$dldir~ 2601d5e6aabbSmrg $install_prog $dir/$dlname \$dldir/$dlname~ 2602d5e6aabbSmrg chmod a+x \$dldir/$dlname~ 2603d5e6aabbSmrg if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then 2604d5e6aabbSmrg eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; 2605d5e6aabbSmrg fi' 2606d5e6aabbSmrg fi 26070ef0e59aSmrg postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ 26080ef0e59aSmrg dlpath=$dir/\$dldll~ 26090ef0e59aSmrg $RM \$dlpath' 26100ef0e59aSmrg shlibpath_overrides_runpath=yes 26110ef0e59aSmrg 26120ef0e59aSmrg case $host_os in 26130ef0e59aSmrg cygwin*) 26140ef0e59aSmrg # Cygwin DLLs use 'cyg' prefix rather than 'lib' 261515885c33Smrg soname_spec='`echo $libname | $SED -e 's/^lib/cyg/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' 26160ef0e59aSmrgm4_if([$1], [],[ 26170ef0e59aSmrg sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"]) 26180ef0e59aSmrg ;; 2619d5e6aabbSmrg mingw* | windows* | cegcc*) 26200ef0e59aSmrg # MinGW DLLs use traditional 'lib' prefix 26210ef0e59aSmrg soname_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' 26220ef0e59aSmrg ;; 26230ef0e59aSmrg pw32*) 26240ef0e59aSmrg # pw32 DLLs use 'pw' prefix rather than 'lib' 262515885c33Smrg library_names_spec='`echo $libname | $SED -e 's/^lib/pw/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' 26260ef0e59aSmrg ;; 26270ef0e59aSmrg esac 26280ef0e59aSmrg dynamic_linker='Win32 ld.exe' 26290ef0e59aSmrg ;; 26300ef0e59aSmrg 263115885c33Smrg *,cl* | *,icl*) 263215885c33Smrg # Native MSVC or ICC 26330ef0e59aSmrg libname_spec='$name' 26340ef0e59aSmrg soname_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' 26350ef0e59aSmrg library_names_spec='$libname.dll.lib' 26360ef0e59aSmrg 26370ef0e59aSmrg case $build_os in 2638d5e6aabbSmrg mingw* | windows*) 26390ef0e59aSmrg sys_lib_search_path_spec= 26400ef0e59aSmrg lt_save_ifs=$IFS 26410ef0e59aSmrg IFS=';' 26420ef0e59aSmrg for lt_path in $LIB 26430ef0e59aSmrg do 26440ef0e59aSmrg IFS=$lt_save_ifs 26450ef0e59aSmrg # Let DOS variable expansion print the short 8.3 style file name. 26460ef0e59aSmrg lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` 26470ef0e59aSmrg sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" 26480ef0e59aSmrg done 26490ef0e59aSmrg IFS=$lt_save_ifs 26500ef0e59aSmrg # Convert to MSYS style. 265115885c33Smrg sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's|\\\\|/|g' -e 's| \\([[a-zA-Z]]\\):| /\\1|g' -e 's|^ ||'` 26520ef0e59aSmrg ;; 26530ef0e59aSmrg cygwin*) 26540ef0e59aSmrg # Convert to unix form, then to dos form, then back to unix form 26550ef0e59aSmrg # but this time dos style (no spaces!) so that the unix form looks 26560ef0e59aSmrg # like /cygdrive/c/PROGRA~1:/cygdr... 26570ef0e59aSmrg sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` 26580ef0e59aSmrg sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` 26590ef0e59aSmrg sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` 26600ef0e59aSmrg ;; 26610ef0e59aSmrg *) 26620ef0e59aSmrg sys_lib_search_path_spec=$LIB 26630ef0e59aSmrg if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then 26640ef0e59aSmrg # It is most probably a Windows format PATH. 26650ef0e59aSmrg sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` 26660ef0e59aSmrg else 26670ef0e59aSmrg sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` 26680ef0e59aSmrg fi 26690ef0e59aSmrg # FIXME: find the short name or the path components, as spaces are 26700ef0e59aSmrg # common. (e.g. "Program Files" -> "PROGRA~1") 26710ef0e59aSmrg ;; 26720ef0e59aSmrg esac 26730ef0e59aSmrg 26740ef0e59aSmrg # DLL is installed to $(libdir)/../bin by postinstall_cmds 26750ef0e59aSmrg postinstall_cmds='base_file=`basename \$file`~ 26760ef0e59aSmrg dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ 26770ef0e59aSmrg dldir=$destdir/`dirname \$dlpath`~ 26780ef0e59aSmrg test -d \$dldir || mkdir -p \$dldir~ 26790ef0e59aSmrg $install_prog $dir/$dlname \$dldir/$dlname' 26800ef0e59aSmrg postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ 26810ef0e59aSmrg dlpath=$dir/\$dldll~ 26820ef0e59aSmrg $RM \$dlpath' 26830ef0e59aSmrg shlibpath_overrides_runpath=yes 26840ef0e59aSmrg dynamic_linker='Win32 link.exe' 26850ef0e59aSmrg ;; 26860ef0e59aSmrg 26870ef0e59aSmrg *) 268815885c33Smrg # Assume MSVC and ICC wrapper 26890ef0e59aSmrg library_names_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext $libname.lib' 26900ef0e59aSmrg dynamic_linker='Win32 ld.exe' 26910ef0e59aSmrg ;; 26920ef0e59aSmrg esac 26930ef0e59aSmrg # FIXME: first we should search . and the directory the executable is in 26940ef0e59aSmrg shlibpath_var=PATH 26950ef0e59aSmrg ;; 26960ef0e59aSmrg 26970ef0e59aSmrgdarwin* | rhapsody*) 26980ef0e59aSmrg dynamic_linker="$host_os dyld" 26990ef0e59aSmrg version_type=darwin 27000ef0e59aSmrg need_lib_prefix=no 27010ef0e59aSmrg need_version=no 27020ef0e59aSmrg library_names_spec='$libname$release$major$shared_ext $libname$shared_ext' 27030ef0e59aSmrg soname_spec='$libname$release$major$shared_ext' 27040ef0e59aSmrg shlibpath_overrides_runpath=yes 27050ef0e59aSmrg shlibpath_var=DYLD_LIBRARY_PATH 27060ef0e59aSmrg shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' 27070ef0e59aSmrgm4_if([$1], [],[ 27080ef0e59aSmrg sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"]) 27090ef0e59aSmrg sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' 27100ef0e59aSmrg ;; 27110ef0e59aSmrg 27120ef0e59aSmrgdgux*) 27130ef0e59aSmrg version_type=linux # correct to gnu/linux during the next big refactor 27140ef0e59aSmrg need_lib_prefix=no 27150ef0e59aSmrg need_version=no 27160ef0e59aSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 27170ef0e59aSmrg soname_spec='$libname$release$shared_ext$major' 27180ef0e59aSmrg shlibpath_var=LD_LIBRARY_PATH 27190ef0e59aSmrg ;; 27200ef0e59aSmrg 272115885c33Smrgfreebsd* | dragonfly* | midnightbsd*) 27220ef0e59aSmrg # DragonFly does not have aout. When/if they implement a new 27230ef0e59aSmrg # versioning mechanism, adjust this. 27240ef0e59aSmrg if test -x /usr/bin/objformat; then 27250ef0e59aSmrg objformat=`/usr/bin/objformat` 27260ef0e59aSmrg else 27270ef0e59aSmrg case $host_os in 27280ef0e59aSmrg freebsd[[23]].*) objformat=aout ;; 27290ef0e59aSmrg *) objformat=elf ;; 27300ef0e59aSmrg esac 27310ef0e59aSmrg fi 27320ef0e59aSmrg version_type=freebsd-$objformat 27330ef0e59aSmrg case $version_type in 27340ef0e59aSmrg freebsd-elf*) 27350ef0e59aSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 27360ef0e59aSmrg soname_spec='$libname$release$shared_ext$major' 27370ef0e59aSmrg need_version=no 27380ef0e59aSmrg need_lib_prefix=no 27390ef0e59aSmrg ;; 27400ef0e59aSmrg freebsd-*) 27410ef0e59aSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' 27420ef0e59aSmrg need_version=yes 27430ef0e59aSmrg ;; 27440ef0e59aSmrg esac 2745d5e6aabbSmrg case $host_cpu in 2746d5e6aabbSmrg powerpc64) 2747d5e6aabbSmrg # On FreeBSD bi-arch platforms, a different variable is used for 32-bit 2748d5e6aabbSmrg # binaries. See <https://man.freebsd.org/cgi/man.cgi?query=ld.so>. 2749d5e6aabbSmrg AC_COMPILE_IFELSE( 2750d5e6aabbSmrg [AC_LANG_SOURCE( 2751d5e6aabbSmrg [[int test_pointer_size[sizeof (void *) - 5]; 2752d5e6aabbSmrg ]])], 2753d5e6aabbSmrg [shlibpath_var=LD_LIBRARY_PATH], 2754d5e6aabbSmrg [shlibpath_var=LD_32_LIBRARY_PATH]) 2755d5e6aabbSmrg ;; 2756d5e6aabbSmrg *) 2757d5e6aabbSmrg shlibpath_var=LD_LIBRARY_PATH 2758d5e6aabbSmrg ;; 2759d5e6aabbSmrg esac 27600ef0e59aSmrg case $host_os in 27610ef0e59aSmrg freebsd2.*) 27620ef0e59aSmrg shlibpath_overrides_runpath=yes 27630ef0e59aSmrg ;; 27640ef0e59aSmrg freebsd3.[[01]]* | freebsdelf3.[[01]]*) 27650ef0e59aSmrg shlibpath_overrides_runpath=yes 27660ef0e59aSmrg hardcode_into_libs=yes 27670ef0e59aSmrg ;; 27680ef0e59aSmrg freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \ 27690ef0e59aSmrg freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1) 27700ef0e59aSmrg shlibpath_overrides_runpath=no 27710ef0e59aSmrg hardcode_into_libs=yes 27720ef0e59aSmrg ;; 27730ef0e59aSmrg *) # from 4.6 on, and DragonFly 27740ef0e59aSmrg shlibpath_overrides_runpath=yes 27750ef0e59aSmrg hardcode_into_libs=yes 27760ef0e59aSmrg ;; 27770ef0e59aSmrg esac 27780ef0e59aSmrg ;; 27790ef0e59aSmrg 27800ef0e59aSmrghaiku*) 27810ef0e59aSmrg version_type=linux # correct to gnu/linux during the next big refactor 27820ef0e59aSmrg need_lib_prefix=no 27830ef0e59aSmrg need_version=no 27840ef0e59aSmrg dynamic_linker="$host_os runtime_loader" 27850ef0e59aSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 27860ef0e59aSmrg soname_spec='$libname$release$shared_ext$major' 27870ef0e59aSmrg shlibpath_var=LIBRARY_PATH 27880ef0e59aSmrg shlibpath_overrides_runpath=no 2789d5e6aabbSmrg sys_lib_search_path_spec='/boot/system/non-packaged/develop/lib /boot/system/develop/lib' 2790d5e6aabbSmrg sys_lib_dlsearch_path_spec='/boot/home/config/non-packaged/lib /boot/home/config/lib /boot/system/non-packaged/lib /boot/system/lib' 2791d5e6aabbSmrg hardcode_into_libs=no 27920ef0e59aSmrg ;; 27930ef0e59aSmrg 27940ef0e59aSmrghpux9* | hpux10* | hpux11*) 27950ef0e59aSmrg # Give a soname corresponding to the major version so that dld.sl refuses to 27960ef0e59aSmrg # link against other versions. 27970ef0e59aSmrg version_type=sunos 27980ef0e59aSmrg need_lib_prefix=no 27990ef0e59aSmrg need_version=no 28000ef0e59aSmrg case $host_cpu in 28010ef0e59aSmrg ia64*) 28020ef0e59aSmrg shrext_cmds='.so' 28030ef0e59aSmrg hardcode_into_libs=yes 28040ef0e59aSmrg dynamic_linker="$host_os dld.so" 28050ef0e59aSmrg shlibpath_var=LD_LIBRARY_PATH 28060ef0e59aSmrg shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. 28070ef0e59aSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 28080ef0e59aSmrg soname_spec='$libname$release$shared_ext$major' 28090ef0e59aSmrg if test 32 = "$HPUX_IA64_MODE"; then 28100ef0e59aSmrg sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" 28110ef0e59aSmrg sys_lib_dlsearch_path_spec=/usr/lib/hpux32 28120ef0e59aSmrg else 28130ef0e59aSmrg sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" 28140ef0e59aSmrg sys_lib_dlsearch_path_spec=/usr/lib/hpux64 28150ef0e59aSmrg fi 28160ef0e59aSmrg ;; 28170ef0e59aSmrg hppa*64*) 28180ef0e59aSmrg shrext_cmds='.sl' 28190ef0e59aSmrg hardcode_into_libs=yes 28200ef0e59aSmrg dynamic_linker="$host_os dld.sl" 28210ef0e59aSmrg shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH 28220ef0e59aSmrg shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. 28230ef0e59aSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 28240ef0e59aSmrg soname_spec='$libname$release$shared_ext$major' 28250ef0e59aSmrg sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" 28260ef0e59aSmrg sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec 28270ef0e59aSmrg ;; 28280ef0e59aSmrg *) 28290ef0e59aSmrg shrext_cmds='.sl' 28300ef0e59aSmrg dynamic_linker="$host_os dld.sl" 28310ef0e59aSmrg shlibpath_var=SHLIB_PATH 28320ef0e59aSmrg shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH 28330ef0e59aSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 28340ef0e59aSmrg soname_spec='$libname$release$shared_ext$major' 28350ef0e59aSmrg ;; 28360ef0e59aSmrg esac 28370ef0e59aSmrg # HP-UX runs *really* slowly unless shared libraries are mode 555, ... 28380ef0e59aSmrg postinstall_cmds='chmod 555 $lib' 28390ef0e59aSmrg # or fails outright, so override atomically: 28400ef0e59aSmrg install_override_mode=555 28410ef0e59aSmrg ;; 28420ef0e59aSmrg 28430ef0e59aSmrginterix[[3-9]]*) 28440ef0e59aSmrg version_type=linux # correct to gnu/linux during the next big refactor 28450ef0e59aSmrg need_lib_prefix=no 28460ef0e59aSmrg need_version=no 28470ef0e59aSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 28480ef0e59aSmrg soname_spec='$libname$release$shared_ext$major' 28490ef0e59aSmrg dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' 28500ef0e59aSmrg shlibpath_var=LD_LIBRARY_PATH 28510ef0e59aSmrg shlibpath_overrides_runpath=no 28520ef0e59aSmrg hardcode_into_libs=yes 28530ef0e59aSmrg ;; 28540ef0e59aSmrg 28550ef0e59aSmrgirix5* | irix6* | nonstopux*) 28560ef0e59aSmrg case $host_os in 28570ef0e59aSmrg nonstopux*) version_type=nonstopux ;; 28580ef0e59aSmrg *) 28590ef0e59aSmrg if test yes = "$lt_cv_prog_gnu_ld"; then 28600ef0e59aSmrg version_type=linux # correct to gnu/linux during the next big refactor 28610ef0e59aSmrg else 28620ef0e59aSmrg version_type=irix 28630ef0e59aSmrg fi ;; 28640ef0e59aSmrg esac 28650ef0e59aSmrg need_lib_prefix=no 28660ef0e59aSmrg need_version=no 28670ef0e59aSmrg soname_spec='$libname$release$shared_ext$major' 28680ef0e59aSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$release$shared_ext $libname$shared_ext' 28690ef0e59aSmrg case $host_os in 28700ef0e59aSmrg irix5* | nonstopux*) 28710ef0e59aSmrg libsuff= shlibsuff= 28720ef0e59aSmrg ;; 28730ef0e59aSmrg *) 28740ef0e59aSmrg case $LD in # libtool.m4 will add one of these switches to LD 28750ef0e59aSmrg *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") 28760ef0e59aSmrg libsuff= shlibsuff= libmagic=32-bit;; 28770ef0e59aSmrg *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") 28780ef0e59aSmrg libsuff=32 shlibsuff=N32 libmagic=N32;; 28790ef0e59aSmrg *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") 28800ef0e59aSmrg libsuff=64 shlibsuff=64 libmagic=64-bit;; 28810ef0e59aSmrg *) libsuff= shlibsuff= libmagic=never-match;; 28820ef0e59aSmrg esac 28830ef0e59aSmrg ;; 28840ef0e59aSmrg esac 28850ef0e59aSmrg shlibpath_var=LD_LIBRARY${shlibsuff}_PATH 28860ef0e59aSmrg shlibpath_overrides_runpath=no 28870ef0e59aSmrg sys_lib_search_path_spec="/usr/lib$libsuff /lib$libsuff /usr/local/lib$libsuff" 28880ef0e59aSmrg sys_lib_dlsearch_path_spec="/usr/lib$libsuff /lib$libsuff" 28890ef0e59aSmrg hardcode_into_libs=yes 28900ef0e59aSmrg ;; 28910ef0e59aSmrg 28920ef0e59aSmrg# No shared lib support for Linux oldld, aout, or coff. 28930ef0e59aSmrglinux*oldld* | linux*aout* | linux*coff*) 28940ef0e59aSmrg dynamic_linker=no 28950ef0e59aSmrg ;; 28960ef0e59aSmrg 28970ef0e59aSmrglinux*android*) 28980ef0e59aSmrg version_type=none # Android doesn't support versioned libraries. 28990ef0e59aSmrg need_lib_prefix=no 29000ef0e59aSmrg need_version=no 2901d5e6aabbSmrg library_names_spec='$libname$release$shared_ext $libname$shared_ext' 29020ef0e59aSmrg soname_spec='$libname$release$shared_ext' 29030ef0e59aSmrg finish_cmds= 29040ef0e59aSmrg shlibpath_var=LD_LIBRARY_PATH 29050ef0e59aSmrg shlibpath_overrides_runpath=yes 29060ef0e59aSmrg 29070ef0e59aSmrg # This implies no fast_install, which is unacceptable. 29080ef0e59aSmrg # Some rework will be needed to allow for fast_install 29090ef0e59aSmrg # before this can be enabled. 29100ef0e59aSmrg hardcode_into_libs=yes 29110ef0e59aSmrg 29120ef0e59aSmrg dynamic_linker='Android linker' 2913d5e6aabbSmrg # -rpath works at least for libraries that are not overridden by 2914d5e6aabbSmrg # libraries installed in system locations. 2915d5e6aabbSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' 29160ef0e59aSmrg ;; 29170ef0e59aSmrg 29180ef0e59aSmrg# This must be glibc/ELF. 29190ef0e59aSmrglinux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) 29200ef0e59aSmrg version_type=linux # correct to gnu/linux during the next big refactor 29210ef0e59aSmrg need_lib_prefix=no 29220ef0e59aSmrg need_version=no 29230ef0e59aSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 29240ef0e59aSmrg soname_spec='$libname$release$shared_ext$major' 29250ef0e59aSmrg finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' 29260ef0e59aSmrg shlibpath_var=LD_LIBRARY_PATH 29270ef0e59aSmrg shlibpath_overrides_runpath=no 29280ef0e59aSmrg 29290ef0e59aSmrg # Some binutils ld are patched to set DT_RUNPATH 29300ef0e59aSmrg AC_CACHE_VAL([lt_cv_shlibpath_overrides_runpath], 29310ef0e59aSmrg [lt_cv_shlibpath_overrides_runpath=no 29320ef0e59aSmrg save_LDFLAGS=$LDFLAGS 29330ef0e59aSmrg save_libdir=$libdir 29340ef0e59aSmrg eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \ 29350ef0e59aSmrg LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\"" 29360ef0e59aSmrg AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], 29370ef0e59aSmrg [AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null], 29380ef0e59aSmrg [lt_cv_shlibpath_overrides_runpath=yes])]) 29390ef0e59aSmrg LDFLAGS=$save_LDFLAGS 29400ef0e59aSmrg libdir=$save_libdir 29410ef0e59aSmrg ]) 29420ef0e59aSmrg shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath 29430ef0e59aSmrg 29440ef0e59aSmrg # This implies no fast_install, which is unacceptable. 29450ef0e59aSmrg # Some rework will be needed to allow for fast_install 29460ef0e59aSmrg # before this can be enabled. 29470ef0e59aSmrg hardcode_into_libs=yes 29480ef0e59aSmrg 2949d5e6aabbSmrg # Ideally, we could use ldconfig to report *all* directories which are 29500ef0e59aSmrg # searched for libraries, however this is still not possible. Aside from not 29510ef0e59aSmrg # being certain /sbin/ldconfig is available, command 29520ef0e59aSmrg # 'ldconfig -N -X -v | grep ^/' on 64bit Fedora does not report /usr/lib64, 29530ef0e59aSmrg # even though it is searched at run-time. Try to do the best guess by 29540ef0e59aSmrg # appending ld.so.conf contents (and includes) to the search path. 29550ef0e59aSmrg if test -f /etc/ld.so.conf; then 29560ef0e59aSmrg lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '` 29570ef0e59aSmrg sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" 29580ef0e59aSmrg fi 29590ef0e59aSmrg 29600ef0e59aSmrg # We used to test for /lib/ld.so.1 and disable shared libraries on 29610ef0e59aSmrg # powerpc, because MkLinux only supported shared libraries with the 29620ef0e59aSmrg # GNU dynamic linker. Since this was broken with cross compilers, 29630ef0e59aSmrg # most powerpc-linux boxes support dynamic linking these days and 29640ef0e59aSmrg # people can always --disable-shared, the test was removed, and we 29650ef0e59aSmrg # assume the GNU/Linux dynamic linker is in use. 29660ef0e59aSmrg dynamic_linker='GNU/Linux ld.so' 29670ef0e59aSmrg ;; 29680ef0e59aSmrg 2969d5e6aabbSmrgnetbsdelf*-gnu) 2970d5e6aabbSmrg version_type=linux 2971d5e6aabbSmrg need_lib_prefix=no 2972d5e6aabbSmrg need_version=no 2973d5e6aabbSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 2974d5e6aabbSmrg soname_spec='$libname$release$shared_ext$major' 2975d5e6aabbSmrg shlibpath_var=LD_LIBRARY_PATH 2976d5e6aabbSmrg shlibpath_overrides_runpath=no 2977d5e6aabbSmrg hardcode_into_libs=yes 2978d5e6aabbSmrg dynamic_linker='NetBSD ld.elf_so' 2979d5e6aabbSmrg ;; 2980d5e6aabbSmrg 29810ef0e59aSmrgnetbsd*) 29820ef0e59aSmrg version_type=sunos 29830ef0e59aSmrg need_lib_prefix=no 29840ef0e59aSmrg need_version=no 29850ef0e59aSmrg if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then 29860ef0e59aSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' 29870ef0e59aSmrg finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' 29880ef0e59aSmrg dynamic_linker='NetBSD (a.out) ld.so' 29890ef0e59aSmrg else 29900ef0e59aSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 29910ef0e59aSmrg soname_spec='$libname$release$shared_ext$major' 29920ef0e59aSmrg dynamic_linker='NetBSD ld.elf_so' 29930ef0e59aSmrg fi 29940ef0e59aSmrg shlibpath_var=LD_LIBRARY_PATH 29950ef0e59aSmrg shlibpath_overrides_runpath=yes 29960ef0e59aSmrg hardcode_into_libs=yes 29970ef0e59aSmrg ;; 29980ef0e59aSmrg 2999d5e6aabbSmrg*-mlibc) 3000d5e6aabbSmrg version_type=linux # correct to gnu/linux during the next big refactor 3001d5e6aabbSmrg need_lib_prefix=no 3002d5e6aabbSmrg need_version=no 3003d5e6aabbSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 3004d5e6aabbSmrg soname_spec='$libname$release$shared_ext$major' 3005d5e6aabbSmrg dynamic_linker='mlibc ld.so' 3006d5e6aabbSmrg shlibpath_var=LD_LIBRARY_PATH 3007d5e6aabbSmrg shlibpath_overrides_runpath=no 3008d5e6aabbSmrg hardcode_into_libs=yes 3009d5e6aabbSmrg ;; 3010d5e6aabbSmrg 30110ef0e59aSmrgnewsos6) 30120ef0e59aSmrg version_type=linux # correct to gnu/linux during the next big refactor 30130ef0e59aSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 30140ef0e59aSmrg shlibpath_var=LD_LIBRARY_PATH 30150ef0e59aSmrg shlibpath_overrides_runpath=yes 30160ef0e59aSmrg ;; 30170ef0e59aSmrg 30180ef0e59aSmrg*nto* | *qnx*) 30190ef0e59aSmrg version_type=qnx 30200ef0e59aSmrg need_lib_prefix=no 30210ef0e59aSmrg need_version=no 30220ef0e59aSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 30230ef0e59aSmrg soname_spec='$libname$release$shared_ext$major' 30240ef0e59aSmrg shlibpath_var=LD_LIBRARY_PATH 30250ef0e59aSmrg shlibpath_overrides_runpath=no 30260ef0e59aSmrg hardcode_into_libs=yes 30270ef0e59aSmrg dynamic_linker='ldqnx.so' 30280ef0e59aSmrg ;; 30290ef0e59aSmrg 3030d5e6aabbSmrgopenbsd*) 30310ef0e59aSmrg version_type=sunos 30320ef0e59aSmrg sys_lib_dlsearch_path_spec=/usr/lib 30330ef0e59aSmrg need_lib_prefix=no 30340ef0e59aSmrg if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then 30350ef0e59aSmrg need_version=no 30360ef0e59aSmrg else 30370ef0e59aSmrg need_version=yes 30380ef0e59aSmrg fi 30390ef0e59aSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' 30400ef0e59aSmrg finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' 30410ef0e59aSmrg shlibpath_var=LD_LIBRARY_PATH 30420ef0e59aSmrg shlibpath_overrides_runpath=yes 30430ef0e59aSmrg ;; 30440ef0e59aSmrg 30450ef0e59aSmrgos2*) 30460ef0e59aSmrg libname_spec='$name' 30470ef0e59aSmrg version_type=windows 30480ef0e59aSmrg shrext_cmds=.dll 30490ef0e59aSmrg need_version=no 30500ef0e59aSmrg need_lib_prefix=no 30510ef0e59aSmrg # OS/2 can only load a DLL with a base name of 8 characters or less. 30520ef0e59aSmrg soname_spec='`test -n "$os2dllname" && libname="$os2dllname"; 30530ef0e59aSmrg v=$($ECHO $release$versuffix | tr -d .-); 30540ef0e59aSmrg n=$($ECHO $libname | cut -b -$((8 - ${#v})) | tr . _); 30550ef0e59aSmrg $ECHO $n$v`$shared_ext' 30560ef0e59aSmrg library_names_spec='${libname}_dll.$libext' 30570ef0e59aSmrg dynamic_linker='OS/2 ld.exe' 30580ef0e59aSmrg shlibpath_var=BEGINLIBPATH 30590ef0e59aSmrg sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" 30600ef0e59aSmrg sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec 30610ef0e59aSmrg postinstall_cmds='base_file=`basename \$file`~ 30620ef0e59aSmrg dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; $ECHO \$dlname'\''`~ 30630ef0e59aSmrg dldir=$destdir/`dirname \$dlpath`~ 30640ef0e59aSmrg test -d \$dldir || mkdir -p \$dldir~ 30650ef0e59aSmrg $install_prog $dir/$dlname \$dldir/$dlname~ 30660ef0e59aSmrg chmod a+x \$dldir/$dlname~ 30670ef0e59aSmrg if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then 30680ef0e59aSmrg eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; 30690ef0e59aSmrg fi' 30700ef0e59aSmrg postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; $ECHO \$dlname'\''`~ 30710ef0e59aSmrg dlpath=$dir/\$dldll~ 30720ef0e59aSmrg $RM \$dlpath' 30730ef0e59aSmrg ;; 30740ef0e59aSmrg 30750ef0e59aSmrgosf3* | osf4* | osf5*) 30760ef0e59aSmrg version_type=osf 30770ef0e59aSmrg need_lib_prefix=no 30780ef0e59aSmrg need_version=no 30790ef0e59aSmrg soname_spec='$libname$release$shared_ext$major' 30800ef0e59aSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 30810ef0e59aSmrg shlibpath_var=LD_LIBRARY_PATH 30820ef0e59aSmrg sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" 30830ef0e59aSmrg sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec 30840ef0e59aSmrg ;; 30850ef0e59aSmrg 30860ef0e59aSmrgrdos*) 30870ef0e59aSmrg dynamic_linker=no 30880ef0e59aSmrg ;; 30890ef0e59aSmrg 3090d5e6aabbSmrgserenity*) 3091d5e6aabbSmrg version_type=linux # correct to gnu/linux during the next big refactor 3092d5e6aabbSmrg need_lib_prefix=no 3093d5e6aabbSmrg need_version=no 3094d5e6aabbSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 3095d5e6aabbSmrg soname_spec='$libname$release$shared_ext$major' 3096d5e6aabbSmrg shlibpath_var=LD_LIBRARY_PATH 3097d5e6aabbSmrg shlibpath_overrides_runpath=no 3098d5e6aabbSmrg dynamic_linker='SerenityOS LibELF' 3099d5e6aabbSmrg ;; 3100d5e6aabbSmrg 31010ef0e59aSmrgsolaris*) 31020ef0e59aSmrg version_type=linux # correct to gnu/linux during the next big refactor 31030ef0e59aSmrg need_lib_prefix=no 31040ef0e59aSmrg need_version=no 31050ef0e59aSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 31060ef0e59aSmrg soname_spec='$libname$release$shared_ext$major' 31070ef0e59aSmrg shlibpath_var=LD_LIBRARY_PATH 31080ef0e59aSmrg shlibpath_overrides_runpath=yes 31090ef0e59aSmrg hardcode_into_libs=yes 31100ef0e59aSmrg # ldd complains unless libraries are executable 31110ef0e59aSmrg postinstall_cmds='chmod +x $lib' 31120ef0e59aSmrg ;; 31130ef0e59aSmrg 31140ef0e59aSmrgsunos4*) 31150ef0e59aSmrg version_type=sunos 31160ef0e59aSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' 31170ef0e59aSmrg finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' 31180ef0e59aSmrg shlibpath_var=LD_LIBRARY_PATH 31190ef0e59aSmrg shlibpath_overrides_runpath=yes 31200ef0e59aSmrg if test yes = "$with_gnu_ld"; then 31210ef0e59aSmrg need_lib_prefix=no 31220ef0e59aSmrg fi 31230ef0e59aSmrg need_version=yes 31240ef0e59aSmrg ;; 31250ef0e59aSmrg 31260ef0e59aSmrgsysv4 | sysv4.3*) 31270ef0e59aSmrg version_type=linux # correct to gnu/linux during the next big refactor 31280ef0e59aSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 31290ef0e59aSmrg soname_spec='$libname$release$shared_ext$major' 31300ef0e59aSmrg shlibpath_var=LD_LIBRARY_PATH 31310ef0e59aSmrg case $host_vendor in 31320ef0e59aSmrg sni) 31330ef0e59aSmrg shlibpath_overrides_runpath=no 31340ef0e59aSmrg need_lib_prefix=no 31350ef0e59aSmrg runpath_var=LD_RUN_PATH 31360ef0e59aSmrg ;; 31370ef0e59aSmrg siemens) 31380ef0e59aSmrg need_lib_prefix=no 31390ef0e59aSmrg ;; 31400ef0e59aSmrg motorola) 31410ef0e59aSmrg need_lib_prefix=no 31420ef0e59aSmrg need_version=no 31430ef0e59aSmrg shlibpath_overrides_runpath=no 31440ef0e59aSmrg sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' 31450ef0e59aSmrg ;; 31460ef0e59aSmrg esac 31470ef0e59aSmrg ;; 31480ef0e59aSmrg 31490ef0e59aSmrgsysv4*MP*) 31500ef0e59aSmrg if test -d /usr/nec; then 31510ef0e59aSmrg version_type=linux # correct to gnu/linux during the next big refactor 31520ef0e59aSmrg library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext' 31530ef0e59aSmrg soname_spec='$libname$shared_ext.$major' 31540ef0e59aSmrg shlibpath_var=LD_LIBRARY_PATH 31550ef0e59aSmrg fi 31560ef0e59aSmrg ;; 31570ef0e59aSmrg 31580ef0e59aSmrgsysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) 31590ef0e59aSmrg version_type=sco 31600ef0e59aSmrg need_lib_prefix=no 31610ef0e59aSmrg need_version=no 31620ef0e59aSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext' 31630ef0e59aSmrg soname_spec='$libname$release$shared_ext$major' 31640ef0e59aSmrg shlibpath_var=LD_LIBRARY_PATH 31650ef0e59aSmrg shlibpath_overrides_runpath=yes 31660ef0e59aSmrg hardcode_into_libs=yes 31670ef0e59aSmrg if test yes = "$with_gnu_ld"; then 31680ef0e59aSmrg sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' 31690ef0e59aSmrg else 31700ef0e59aSmrg sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' 31710ef0e59aSmrg case $host_os in 31720ef0e59aSmrg sco3.2v5*) 31730ef0e59aSmrg sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" 31740ef0e59aSmrg ;; 31750ef0e59aSmrg esac 31760ef0e59aSmrg fi 31770ef0e59aSmrg sys_lib_dlsearch_path_spec='/usr/lib' 31780ef0e59aSmrg ;; 31790ef0e59aSmrg 31800ef0e59aSmrgtpf*) 31810ef0e59aSmrg # TPF is a cross-target only. Preferred cross-host = GNU/Linux. 31820ef0e59aSmrg version_type=linux # correct to gnu/linux during the next big refactor 31830ef0e59aSmrg need_lib_prefix=no 31840ef0e59aSmrg need_version=no 31850ef0e59aSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 31860ef0e59aSmrg shlibpath_var=LD_LIBRARY_PATH 31870ef0e59aSmrg shlibpath_overrides_runpath=no 31880ef0e59aSmrg hardcode_into_libs=yes 31890ef0e59aSmrg ;; 31900ef0e59aSmrg 31910ef0e59aSmrguts4*) 31920ef0e59aSmrg version_type=linux # correct to gnu/linux during the next big refactor 31930ef0e59aSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 31940ef0e59aSmrg soname_spec='$libname$release$shared_ext$major' 31950ef0e59aSmrg shlibpath_var=LD_LIBRARY_PATH 31960ef0e59aSmrg ;; 31970ef0e59aSmrg 3198d5e6aabbSmrgemscripten*) 3199d5e6aabbSmrg version_type=none 3200d5e6aabbSmrg need_lib_prefix=no 3201d5e6aabbSmrg need_version=no 3202d5e6aabbSmrg library_names_spec='$libname$release$shared_ext' 3203d5e6aabbSmrg soname_spec='$libname$release$shared_ext' 3204d5e6aabbSmrg finish_cmds= 3205d5e6aabbSmrg dynamic_linker="Emscripten linker" 3206d5e6aabbSmrg _LT_COMPILER_PIC($1)='-fPIC' 3207d5e6aabbSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -sSIDE_MODULE=2 -shared $libobjs $deplibs $compiler_flags -o $lib' 3208d5e6aabbSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='$SED "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -sSIDE_MODULE=2 -shared $libobjs $deplibs $compiler_flags -o $lib -s EXPORTED_FUNCTIONS=@$output_objdir/$soname.expsym' 3209d5e6aabbSmrg _LT_TAGVAR(archive_cmds_need_lc, $1)=no 3210d5e6aabbSmrg _LT_TAGVAR(no_undefined_flag, $1)= 3211d5e6aabbSmrg ;; 3212d5e6aabbSmrg 32130ef0e59aSmrg*) 32140ef0e59aSmrg dynamic_linker=no 32150ef0e59aSmrg ;; 32160ef0e59aSmrgesac 32170ef0e59aSmrgAC_MSG_RESULT([$dynamic_linker]) 32180ef0e59aSmrgtest no = "$dynamic_linker" && can_build_shared=no 32190ef0e59aSmrg 32200ef0e59aSmrgvariables_saved_for_relink="PATH $shlibpath_var $runpath_var" 32210ef0e59aSmrgif test yes = "$GCC"; then 32220ef0e59aSmrg variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" 32230ef0e59aSmrgfi 32240ef0e59aSmrg 32250ef0e59aSmrgif test set = "${lt_cv_sys_lib_search_path_spec+set}"; then 32260ef0e59aSmrg sys_lib_search_path_spec=$lt_cv_sys_lib_search_path_spec 32270ef0e59aSmrgfi 32280ef0e59aSmrg 32290ef0e59aSmrgif test set = "${lt_cv_sys_lib_dlsearch_path_spec+set}"; then 32300ef0e59aSmrg sys_lib_dlsearch_path_spec=$lt_cv_sys_lib_dlsearch_path_spec 32310ef0e59aSmrgfi 32320ef0e59aSmrg 32330ef0e59aSmrg# remember unaugmented sys_lib_dlsearch_path content for libtool script decls... 32340ef0e59aSmrgconfigure_time_dlsearch_path=$sys_lib_dlsearch_path_spec 32350ef0e59aSmrg 32360ef0e59aSmrg# ... but it needs LT_SYS_LIBRARY_PATH munging for other configure-time code 32370ef0e59aSmrgfunc_munge_path_list sys_lib_dlsearch_path_spec "$LT_SYS_LIBRARY_PATH" 32380ef0e59aSmrg 32390ef0e59aSmrg# to be used as default LT_SYS_LIBRARY_PATH value in generated libtool 32400ef0e59aSmrgconfigure_time_lt_sys_library_path=$LT_SYS_LIBRARY_PATH 32410ef0e59aSmrg 32420ef0e59aSmrg_LT_DECL([], [variables_saved_for_relink], [1], 32430ef0e59aSmrg [Variables whose values should be saved in libtool wrapper scripts and 32440ef0e59aSmrg restored at link time]) 32450ef0e59aSmrg_LT_DECL([], [need_lib_prefix], [0], 32460ef0e59aSmrg [Do we need the "lib" prefix for modules?]) 32470ef0e59aSmrg_LT_DECL([], [need_version], [0], [Do we need a version for libraries?]) 32480ef0e59aSmrg_LT_DECL([], [version_type], [0], [Library versioning type]) 32490ef0e59aSmrg_LT_DECL([], [runpath_var], [0], [Shared library runtime path variable]) 32500ef0e59aSmrg_LT_DECL([], [shlibpath_var], [0],[Shared library path variable]) 32510ef0e59aSmrg_LT_DECL([], [shlibpath_overrides_runpath], [0], 32520ef0e59aSmrg [Is shlibpath searched before the hard-coded library search path?]) 32530ef0e59aSmrg_LT_DECL([], [libname_spec], [1], [Format of library name prefix]) 32540ef0e59aSmrg_LT_DECL([], [library_names_spec], [1], 32550ef0e59aSmrg [[List of archive names. First name is the real one, the rest are links. 32560ef0e59aSmrg The last name is the one that the linker finds with -lNAME]]) 32570ef0e59aSmrg_LT_DECL([], [soname_spec], [1], 32580ef0e59aSmrg [[The coded name of the library, if different from the real name]]) 32590ef0e59aSmrg_LT_DECL([], [install_override_mode], [1], 32600ef0e59aSmrg [Permission mode override for installation of shared libraries]) 32610ef0e59aSmrg_LT_DECL([], [postinstall_cmds], [2], 32620ef0e59aSmrg [Command to use after installation of a shared archive]) 32630ef0e59aSmrg_LT_DECL([], [postuninstall_cmds], [2], 32640ef0e59aSmrg [Command to use after uninstallation of a shared archive]) 32650ef0e59aSmrg_LT_DECL([], [finish_cmds], [2], 32660ef0e59aSmrg [Commands used to finish a libtool library installation in a directory]) 32670ef0e59aSmrg_LT_DECL([], [finish_eval], [1], 32680ef0e59aSmrg [[As "finish_cmds", except a single script fragment to be evaled but 32690ef0e59aSmrg not shown]]) 32700ef0e59aSmrg_LT_DECL([], [hardcode_into_libs], [0], 32710ef0e59aSmrg [Whether we should hardcode library paths into libraries]) 32720ef0e59aSmrg_LT_DECL([], [sys_lib_search_path_spec], [2], 32730ef0e59aSmrg [Compile-time system search path for libraries]) 32740ef0e59aSmrg_LT_DECL([sys_lib_dlsearch_path_spec], [configure_time_dlsearch_path], [2], 32750ef0e59aSmrg [Detected run-time system search path for libraries]) 32760ef0e59aSmrg_LT_DECL([], [configure_time_lt_sys_library_path], [2], 32770ef0e59aSmrg [Explicit LT_SYS_LIBRARY_PATH set during ./configure time]) 32780ef0e59aSmrg])# _LT_SYS_DYNAMIC_LINKER 32790ef0e59aSmrg 32800ef0e59aSmrg 32810ef0e59aSmrg# _LT_PATH_TOOL_PREFIX(TOOL) 32820ef0e59aSmrg# -------------------------- 32830ef0e59aSmrg# find a file program that can recognize shared library 32840ef0e59aSmrgAC_DEFUN([_LT_PATH_TOOL_PREFIX], 32850ef0e59aSmrg[m4_require([_LT_DECL_EGREP])dnl 32860ef0e59aSmrgAC_MSG_CHECKING([for $1]) 32870ef0e59aSmrgAC_CACHE_VAL(lt_cv_path_MAGIC_CMD, 32880ef0e59aSmrg[case $MAGIC_CMD in 32890ef0e59aSmrg[[\\/*] | ?:[\\/]*]) 32900ef0e59aSmrg lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path. 32910ef0e59aSmrg ;; 32920ef0e59aSmrg*) 32930ef0e59aSmrg lt_save_MAGIC_CMD=$MAGIC_CMD 32940ef0e59aSmrg lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR 32950ef0e59aSmrgdnl $ac_dummy forces splitting on constant user-supplied paths. 32960ef0e59aSmrgdnl POSIX.2 word splitting is done only on the output of word expansions, 32970ef0e59aSmrgdnl not every word. This closes a longstanding sh security hole. 32980ef0e59aSmrg ac_dummy="m4_if([$2], , $PATH, [$2])" 32990ef0e59aSmrg for ac_dir in $ac_dummy; do 33000ef0e59aSmrg IFS=$lt_save_ifs 33010ef0e59aSmrg test -z "$ac_dir" && ac_dir=. 33020ef0e59aSmrg if test -f "$ac_dir/$1"; then 33030ef0e59aSmrg lt_cv_path_MAGIC_CMD=$ac_dir/"$1" 33040ef0e59aSmrg if test -n "$file_magic_test_file"; then 33050ef0e59aSmrg case $deplibs_check_method in 33060ef0e59aSmrg "file_magic "*) 33070ef0e59aSmrg file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` 33080ef0e59aSmrg MAGIC_CMD=$lt_cv_path_MAGIC_CMD 33090ef0e59aSmrg if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | 33100ef0e59aSmrg $EGREP "$file_magic_regex" > /dev/null; then 33110ef0e59aSmrg : 33120ef0e59aSmrg else 33130ef0e59aSmrg cat <<_LT_EOF 1>&2 33140ef0e59aSmrg 33150ef0e59aSmrg*** Warning: the command libtool uses to detect shared libraries, 33160ef0e59aSmrg*** $file_magic_cmd, produces output that libtool cannot recognize. 33170ef0e59aSmrg*** The result is that libtool may fail to recognize shared libraries 33180ef0e59aSmrg*** as such. This will affect the creation of libtool libraries that 33190ef0e59aSmrg*** depend on shared libraries, but programs linked with such libtool 33200ef0e59aSmrg*** libraries will work regardless of this problem. Nevertheless, you 33210ef0e59aSmrg*** may want to report the problem to your system manager and/or to 33220ef0e59aSmrg*** bug-libtool@gnu.org 33230ef0e59aSmrg 33240ef0e59aSmrg_LT_EOF 33250ef0e59aSmrg fi ;; 33260ef0e59aSmrg esac 33270ef0e59aSmrg fi 33280ef0e59aSmrg break 33290ef0e59aSmrg fi 33300ef0e59aSmrg done 33310ef0e59aSmrg IFS=$lt_save_ifs 33320ef0e59aSmrg MAGIC_CMD=$lt_save_MAGIC_CMD 33330ef0e59aSmrg ;; 33340ef0e59aSmrgesac]) 33350ef0e59aSmrgMAGIC_CMD=$lt_cv_path_MAGIC_CMD 33360ef0e59aSmrgif test -n "$MAGIC_CMD"; then 33370ef0e59aSmrg AC_MSG_RESULT($MAGIC_CMD) 33380ef0e59aSmrgelse 33390ef0e59aSmrg AC_MSG_RESULT(no) 33400ef0e59aSmrgfi 33410ef0e59aSmrg_LT_DECL([], [MAGIC_CMD], [0], 33420ef0e59aSmrg [Used to examine libraries when file_magic_cmd begins with "file"])dnl 33430ef0e59aSmrg])# _LT_PATH_TOOL_PREFIX 33440ef0e59aSmrg 33450ef0e59aSmrg# Old name: 33460ef0e59aSmrgAU_ALIAS([AC_PATH_TOOL_PREFIX], [_LT_PATH_TOOL_PREFIX]) 33470ef0e59aSmrgdnl aclocal-1.4 backwards compatibility: 33480ef0e59aSmrgdnl AC_DEFUN([AC_PATH_TOOL_PREFIX], []) 33490ef0e59aSmrg 33500ef0e59aSmrg 33510ef0e59aSmrg# _LT_PATH_MAGIC 33520ef0e59aSmrg# -------------- 33530ef0e59aSmrg# find a file program that can recognize a shared library 33540ef0e59aSmrgm4_defun([_LT_PATH_MAGIC], 33550ef0e59aSmrg[_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH) 33560ef0e59aSmrgif test -z "$lt_cv_path_MAGIC_CMD"; then 33570ef0e59aSmrg if test -n "$ac_tool_prefix"; then 33580ef0e59aSmrg _LT_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH) 33590ef0e59aSmrg else 33600ef0e59aSmrg MAGIC_CMD=: 33610ef0e59aSmrg fi 33620ef0e59aSmrgfi 33630ef0e59aSmrg])# _LT_PATH_MAGIC 33640ef0e59aSmrg 33650ef0e59aSmrg 33660ef0e59aSmrg# LT_PATH_LD 33670ef0e59aSmrg# ---------- 33680ef0e59aSmrg# find the pathname to the GNU or non-GNU linker 33690ef0e59aSmrgAC_DEFUN([LT_PATH_LD], 33700ef0e59aSmrg[AC_REQUIRE([AC_PROG_CC])dnl 33710ef0e59aSmrgAC_REQUIRE([AC_CANONICAL_HOST])dnl 33720ef0e59aSmrgAC_REQUIRE([AC_CANONICAL_BUILD])dnl 33730ef0e59aSmrgm4_require([_LT_DECL_SED])dnl 33740ef0e59aSmrgm4_require([_LT_DECL_EGREP])dnl 33750ef0e59aSmrgm4_require([_LT_PROG_ECHO_BACKSLASH])dnl 33760ef0e59aSmrg 33770ef0e59aSmrgAC_ARG_WITH([gnu-ld], 33780ef0e59aSmrg [AS_HELP_STRING([--with-gnu-ld], 33790ef0e59aSmrg [assume the C compiler uses GNU ld @<:@default=no@:>@])], 33800ef0e59aSmrg [test no = "$withval" || with_gnu_ld=yes], 33810ef0e59aSmrg [with_gnu_ld=no])dnl 33820ef0e59aSmrg 33830ef0e59aSmrgac_prog=ld 33840ef0e59aSmrgif test yes = "$GCC"; then 33850ef0e59aSmrg # Check if gcc -print-prog-name=ld gives a path. 33860ef0e59aSmrg AC_MSG_CHECKING([for ld used by $CC]) 33870ef0e59aSmrg case $host in 3388d5e6aabbSmrg *-*-mingw* | *-*-windows*) 33890ef0e59aSmrg # gcc leaves a trailing carriage return, which upsets mingw 33900ef0e59aSmrg ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; 33910ef0e59aSmrg *) 33920ef0e59aSmrg ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; 33930ef0e59aSmrg esac 33940ef0e59aSmrg case $ac_prog in 33950ef0e59aSmrg # Accept absolute paths. 33960ef0e59aSmrg [[\\/]]* | ?:[[\\/]]*) 33970ef0e59aSmrg re_direlt='/[[^/]][[^/]]*/\.\./' 33980ef0e59aSmrg # Canonicalize the pathname of ld 33990ef0e59aSmrg ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` 34000ef0e59aSmrg while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do 34010ef0e59aSmrg ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` 34020ef0e59aSmrg done 34030ef0e59aSmrg test -z "$LD" && LD=$ac_prog 34040ef0e59aSmrg ;; 34050ef0e59aSmrg "") 34060ef0e59aSmrg # If it fails, then pretend we aren't using GCC. 34070ef0e59aSmrg ac_prog=ld 34080ef0e59aSmrg ;; 34090ef0e59aSmrg *) 34100ef0e59aSmrg # If it is relative, then search for the first ld in PATH. 34110ef0e59aSmrg with_gnu_ld=unknown 34120ef0e59aSmrg ;; 34130ef0e59aSmrg esac 34140ef0e59aSmrgelif test yes = "$with_gnu_ld"; then 34150ef0e59aSmrg AC_MSG_CHECKING([for GNU ld]) 34160ef0e59aSmrgelse 34170ef0e59aSmrg AC_MSG_CHECKING([for non-GNU ld]) 34180ef0e59aSmrgfi 34190ef0e59aSmrgAC_CACHE_VAL(lt_cv_path_LD, 34200ef0e59aSmrg[if test -z "$LD"; then 34210ef0e59aSmrg lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR 34220ef0e59aSmrg for ac_dir in $PATH; do 34230ef0e59aSmrg IFS=$lt_save_ifs 34240ef0e59aSmrg test -z "$ac_dir" && ac_dir=. 34250ef0e59aSmrg if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then 34260ef0e59aSmrg lt_cv_path_LD=$ac_dir/$ac_prog 34270ef0e59aSmrg # Check to see if the program is GNU ld. I'd rather use --version, 34280ef0e59aSmrg # but apparently some variants of GNU ld only accept -v. 34290ef0e59aSmrg # Break only if it was the GNU/non-GNU ld that we prefer. 34300ef0e59aSmrg case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in 34310ef0e59aSmrg *GNU* | *'with BFD'*) 34320ef0e59aSmrg test no != "$with_gnu_ld" && break 34330ef0e59aSmrg ;; 34340ef0e59aSmrg *) 34350ef0e59aSmrg test yes != "$with_gnu_ld" && break 34360ef0e59aSmrg ;; 34370ef0e59aSmrg esac 34380ef0e59aSmrg fi 34390ef0e59aSmrg done 34400ef0e59aSmrg IFS=$lt_save_ifs 34410ef0e59aSmrgelse 34420ef0e59aSmrg lt_cv_path_LD=$LD # Let the user override the test with a path. 34430ef0e59aSmrgfi]) 34440ef0e59aSmrgLD=$lt_cv_path_LD 34450ef0e59aSmrgif test -n "$LD"; then 34460ef0e59aSmrg AC_MSG_RESULT($LD) 34470ef0e59aSmrgelse 34480ef0e59aSmrg AC_MSG_RESULT(no) 34490ef0e59aSmrgfi 34500ef0e59aSmrgtest -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH]) 34510ef0e59aSmrg_LT_PATH_LD_GNU 34520ef0e59aSmrgAC_SUBST([LD]) 34530ef0e59aSmrg 34540ef0e59aSmrg_LT_TAGDECL([], [LD], [1], [The linker used to build libraries]) 34550ef0e59aSmrg])# LT_PATH_LD 34560ef0e59aSmrg 34570ef0e59aSmrg# Old names: 34580ef0e59aSmrgAU_ALIAS([AM_PROG_LD], [LT_PATH_LD]) 34590ef0e59aSmrgAU_ALIAS([AC_PROG_LD], [LT_PATH_LD]) 34600ef0e59aSmrgdnl aclocal-1.4 backwards compatibility: 34610ef0e59aSmrgdnl AC_DEFUN([AM_PROG_LD], []) 34620ef0e59aSmrgdnl AC_DEFUN([AC_PROG_LD], []) 34630ef0e59aSmrg 34640ef0e59aSmrg 34650ef0e59aSmrg# _LT_PATH_LD_GNU 34660ef0e59aSmrg#- -------------- 34670ef0e59aSmrgm4_defun([_LT_PATH_LD_GNU], 34680ef0e59aSmrg[AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld, 34690ef0e59aSmrg[# I'd rather use --version here, but apparently some GNU lds only accept -v. 34700ef0e59aSmrgcase `$LD -v 2>&1 </dev/null` in 34710ef0e59aSmrg*GNU* | *'with BFD'*) 34720ef0e59aSmrg lt_cv_prog_gnu_ld=yes 34730ef0e59aSmrg ;; 34740ef0e59aSmrg*) 34750ef0e59aSmrg lt_cv_prog_gnu_ld=no 34760ef0e59aSmrg ;; 34770ef0e59aSmrgesac]) 34780ef0e59aSmrgwith_gnu_ld=$lt_cv_prog_gnu_ld 34790ef0e59aSmrg])# _LT_PATH_LD_GNU 34800ef0e59aSmrg 34810ef0e59aSmrg 34820ef0e59aSmrg# _LT_CMD_RELOAD 34830ef0e59aSmrg# -------------- 34840ef0e59aSmrg# find reload flag for linker 34850ef0e59aSmrg# -- PORTME Some linkers may need a different reload flag. 34860ef0e59aSmrgm4_defun([_LT_CMD_RELOAD], 34870ef0e59aSmrg[AC_CACHE_CHECK([for $LD option to reload object files], 34880ef0e59aSmrg lt_cv_ld_reload_flag, 34890ef0e59aSmrg [lt_cv_ld_reload_flag='-r']) 34900ef0e59aSmrgreload_flag=$lt_cv_ld_reload_flag 34910ef0e59aSmrgcase $reload_flag in 34920ef0e59aSmrg"" | " "*) ;; 34930ef0e59aSmrg*) reload_flag=" $reload_flag" ;; 34940ef0e59aSmrgesac 34950ef0e59aSmrgreload_cmds='$LD$reload_flag -o $output$reload_objs' 34960ef0e59aSmrgcase $host_os in 3497d5e6aabbSmrg cygwin* | mingw* | windows* | pw32* | cegcc*) 34980ef0e59aSmrg if test yes != "$GCC"; then 34990ef0e59aSmrg reload_cmds=false 35000ef0e59aSmrg fi 35010ef0e59aSmrg ;; 35020ef0e59aSmrg darwin*) 35030ef0e59aSmrg if test yes = "$GCC"; then 35040ef0e59aSmrg reload_cmds='$LTCC $LTCFLAGS -nostdlib $wl-r -o $output$reload_objs' 35050ef0e59aSmrg else 35060ef0e59aSmrg reload_cmds='$LD$reload_flag -o $output$reload_objs' 35070ef0e59aSmrg fi 35080ef0e59aSmrg ;; 35090ef0e59aSmrgesac 35100ef0e59aSmrg_LT_TAGDECL([], [reload_flag], [1], [How to create reloadable object files])dnl 35110ef0e59aSmrg_LT_TAGDECL([], [reload_cmds], [2])dnl 35120ef0e59aSmrg])# _LT_CMD_RELOAD 35130ef0e59aSmrg 35140ef0e59aSmrg 35150ef0e59aSmrg# _LT_PATH_DD 35160ef0e59aSmrg# ----------- 35170ef0e59aSmrg# find a working dd 35180ef0e59aSmrgm4_defun([_LT_PATH_DD], 35190ef0e59aSmrg[AC_CACHE_CHECK([for a working dd], [ac_cv_path_lt_DD], 35200ef0e59aSmrg[printf 0123456789abcdef0123456789abcdef >conftest.i 35210ef0e59aSmrgcat conftest.i conftest.i >conftest2.i 35220ef0e59aSmrg: ${lt_DD:=$DD} 35230ef0e59aSmrgAC_PATH_PROGS_FEATURE_CHECK([lt_DD], [dd], 35240ef0e59aSmrg[if "$ac_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then 35250ef0e59aSmrg cmp -s conftest.i conftest.out \ 35260ef0e59aSmrg && ac_cv_path_lt_DD="$ac_path_lt_DD" ac_path_lt_DD_found=: 35270ef0e59aSmrgfi]) 35280ef0e59aSmrgrm -f conftest.i conftest2.i conftest.out]) 35290ef0e59aSmrg])# _LT_PATH_DD 35300ef0e59aSmrg 35310ef0e59aSmrg 35320ef0e59aSmrg# _LT_CMD_TRUNCATE 35330ef0e59aSmrg# ---------------- 35340ef0e59aSmrg# find command to truncate a binary pipe 35350ef0e59aSmrgm4_defun([_LT_CMD_TRUNCATE], 35360ef0e59aSmrg[m4_require([_LT_PATH_DD]) 35370ef0e59aSmrgAC_CACHE_CHECK([how to truncate binary pipes], [lt_cv_truncate_bin], 35380ef0e59aSmrg[printf 0123456789abcdef0123456789abcdef >conftest.i 35390ef0e59aSmrgcat conftest.i conftest.i >conftest2.i 35400ef0e59aSmrglt_cv_truncate_bin= 35410ef0e59aSmrgif "$ac_cv_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then 35420ef0e59aSmrg cmp -s conftest.i conftest.out \ 35430ef0e59aSmrg && lt_cv_truncate_bin="$ac_cv_path_lt_DD bs=4096 count=1" 35440ef0e59aSmrgfi 35450ef0e59aSmrgrm -f conftest.i conftest2.i conftest.out 35460ef0e59aSmrgtest -z "$lt_cv_truncate_bin" && lt_cv_truncate_bin="$SED -e 4q"]) 35470ef0e59aSmrg_LT_DECL([lt_truncate_bin], [lt_cv_truncate_bin], [1], 35480ef0e59aSmrg [Command to truncate a binary pipe]) 35490ef0e59aSmrg])# _LT_CMD_TRUNCATE 35500ef0e59aSmrg 35510ef0e59aSmrg 35520ef0e59aSmrg# _LT_CHECK_MAGIC_METHOD 35530ef0e59aSmrg# ---------------------- 35540ef0e59aSmrg# how to check for library dependencies 35550ef0e59aSmrg# -- PORTME fill in with the dynamic library characteristics 35560ef0e59aSmrgm4_defun([_LT_CHECK_MAGIC_METHOD], 35570ef0e59aSmrg[m4_require([_LT_DECL_EGREP]) 35580ef0e59aSmrgm4_require([_LT_DECL_OBJDUMP]) 35590ef0e59aSmrgAC_CACHE_CHECK([how to recognize dependent libraries], 35600ef0e59aSmrglt_cv_deplibs_check_method, 35610ef0e59aSmrg[lt_cv_file_magic_cmd='$MAGIC_CMD' 35620ef0e59aSmrglt_cv_file_magic_test_file= 35630ef0e59aSmrglt_cv_deplibs_check_method='unknown' 35640ef0e59aSmrg# Need to set the preceding variable on all platforms that support 35650ef0e59aSmrg# interlibrary dependencies. 35660ef0e59aSmrg# 'none' -- dependencies not supported. 35670ef0e59aSmrg# 'unknown' -- same as none, but documents that we really don't know. 35680ef0e59aSmrg# 'pass_all' -- all dependencies passed with no checks. 35690ef0e59aSmrg# 'file_magic [[regex]]' -- check by looking for files in library path 35700ef0e59aSmrg# that responds to the $file_magic_cmd with a given extended regex. 35710ef0e59aSmrg# If you have 'file' or equivalent on your system and you're not sure 35720ef0e59aSmrg# whether 'pass_all' will *always* work, you probably want this one. 35730ef0e59aSmrg 35740ef0e59aSmrgcase $host_os in 35750ef0e59aSmrgaix[[4-9]]*) 35760ef0e59aSmrg lt_cv_deplibs_check_method=pass_all 35770ef0e59aSmrg ;; 35780ef0e59aSmrg 35790ef0e59aSmrgbeos*) 35800ef0e59aSmrg lt_cv_deplibs_check_method=pass_all 35810ef0e59aSmrg ;; 35820ef0e59aSmrg 35830ef0e59aSmrgbsdi[[45]]*) 35840ef0e59aSmrg lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)' 358515885c33Smrg lt_cv_file_magic_cmd='$FILECMD -L' 35860ef0e59aSmrg lt_cv_file_magic_test_file=/shlib/libc.so 35870ef0e59aSmrg ;; 35880ef0e59aSmrg 35890ef0e59aSmrgcygwin*) 35900ef0e59aSmrg # func_win32_libid is a shell function defined in ltmain.sh 35910ef0e59aSmrg lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' 35920ef0e59aSmrg lt_cv_file_magic_cmd='func_win32_libid' 35930ef0e59aSmrg ;; 35940ef0e59aSmrg 3595d5e6aabbSmrgmingw* | windows* | pw32*) 35960ef0e59aSmrg # Base MSYS/MinGW do not provide the 'file' command needed by 35970ef0e59aSmrg # func_win32_libid shell function, so use a weaker test based on 'objdump', 35980ef0e59aSmrg # unless we find 'file', for example because we are cross-compiling. 35990ef0e59aSmrg if ( file / ) >/dev/null 2>&1; then 36000ef0e59aSmrg lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' 36010ef0e59aSmrg lt_cv_file_magic_cmd='func_win32_libid' 36020ef0e59aSmrg else 36030ef0e59aSmrg # Keep this pattern in sync with the one in func_win32_libid. 3604d5e6aabbSmrg lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64|pe-aarch64)' 36050ef0e59aSmrg lt_cv_file_magic_cmd='$OBJDUMP -f' 36060ef0e59aSmrg fi 36070ef0e59aSmrg ;; 36080ef0e59aSmrg 36090ef0e59aSmrgcegcc*) 36100ef0e59aSmrg # use the weaker test based on 'objdump'. See mingw*. 36110ef0e59aSmrg lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?' 36120ef0e59aSmrg lt_cv_file_magic_cmd='$OBJDUMP -f' 36130ef0e59aSmrg ;; 36140ef0e59aSmrg 36150ef0e59aSmrgdarwin* | rhapsody*) 36160ef0e59aSmrg lt_cv_deplibs_check_method=pass_all 36170ef0e59aSmrg ;; 36180ef0e59aSmrg 361915885c33Smrgfreebsd* | dragonfly* | midnightbsd*) 36200ef0e59aSmrg if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then 36210ef0e59aSmrg case $host_cpu in 36220ef0e59aSmrg i*86 ) 36230ef0e59aSmrg # Not sure whether the presence of OpenBSD here was a mistake. 36240ef0e59aSmrg # Let's accept both of them until this is cleared up. 36250ef0e59aSmrg lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library' 362615885c33Smrg lt_cv_file_magic_cmd=$FILECMD 36270ef0e59aSmrg lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` 36280ef0e59aSmrg ;; 36290ef0e59aSmrg esac 36300ef0e59aSmrg else 36310ef0e59aSmrg lt_cv_deplibs_check_method=pass_all 36320ef0e59aSmrg fi 36330ef0e59aSmrg ;; 36340ef0e59aSmrg 36350ef0e59aSmrghaiku*) 36360ef0e59aSmrg lt_cv_deplibs_check_method=pass_all 36370ef0e59aSmrg ;; 36380ef0e59aSmrg 36390ef0e59aSmrghpux10.20* | hpux11*) 364015885c33Smrg lt_cv_file_magic_cmd=$FILECMD 36410ef0e59aSmrg case $host_cpu in 36420ef0e59aSmrg ia64*) 36430ef0e59aSmrg lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64' 36440ef0e59aSmrg lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so 36450ef0e59aSmrg ;; 36460ef0e59aSmrg hppa*64*) 36470ef0e59aSmrg [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]'] 36480ef0e59aSmrg lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl 36490ef0e59aSmrg ;; 36500ef0e59aSmrg *) 36510ef0e59aSmrg lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]]\.[[0-9]]) shared library' 36520ef0e59aSmrg lt_cv_file_magic_test_file=/usr/lib/libc.sl 36530ef0e59aSmrg ;; 36540ef0e59aSmrg esac 36550ef0e59aSmrg ;; 36560ef0e59aSmrg 36570ef0e59aSmrginterix[[3-9]]*) 36580ef0e59aSmrg # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here 36590ef0e59aSmrg lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$' 36600ef0e59aSmrg ;; 36610ef0e59aSmrg 36620ef0e59aSmrgirix5* | irix6* | nonstopux*) 36630ef0e59aSmrg case $LD in 36640ef0e59aSmrg *-32|*"-32 ") libmagic=32-bit;; 36650ef0e59aSmrg *-n32|*"-n32 ") libmagic=N32;; 36660ef0e59aSmrg *-64|*"-64 ") libmagic=64-bit;; 36670ef0e59aSmrg *) libmagic=never-match;; 36680ef0e59aSmrg esac 36690ef0e59aSmrg lt_cv_deplibs_check_method=pass_all 36700ef0e59aSmrg ;; 36710ef0e59aSmrg 36720ef0e59aSmrg# This must be glibc/ELF. 36730ef0e59aSmrglinux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) 36740ef0e59aSmrg lt_cv_deplibs_check_method=pass_all 36750ef0e59aSmrg ;; 36760ef0e59aSmrg 3677d5e6aabbSmrg*-mlibc) 3678d5e6aabbSmrg lt_cv_deplibs_check_method=pass_all 3679d5e6aabbSmrg ;; 3680d5e6aabbSmrg 3681d5e6aabbSmrgnetbsd* | netbsdelf*-gnu) 36820ef0e59aSmrg if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then 36830ef0e59aSmrg lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' 36840ef0e59aSmrg else 36850ef0e59aSmrg lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$' 36860ef0e59aSmrg fi 36870ef0e59aSmrg ;; 36880ef0e59aSmrg 36890ef0e59aSmrgnewos6*) 36900ef0e59aSmrg lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)' 369115885c33Smrg lt_cv_file_magic_cmd=$FILECMD 36920ef0e59aSmrg lt_cv_file_magic_test_file=/usr/lib/libnls.so 36930ef0e59aSmrg ;; 36940ef0e59aSmrg 36950ef0e59aSmrg*nto* | *qnx*) 36960ef0e59aSmrg lt_cv_deplibs_check_method=pass_all 36970ef0e59aSmrg ;; 36980ef0e59aSmrg 3699d5e6aabbSmrgopenbsd*) 37000ef0e59aSmrg if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then 37010ef0e59aSmrg lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$' 37020ef0e59aSmrg else 37030ef0e59aSmrg lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' 37040ef0e59aSmrg fi 37050ef0e59aSmrg ;; 37060ef0e59aSmrg 37070ef0e59aSmrgosf3* | osf4* | osf5*) 37080ef0e59aSmrg lt_cv_deplibs_check_method=pass_all 37090ef0e59aSmrg ;; 37100ef0e59aSmrg 37110ef0e59aSmrgrdos*) 37120ef0e59aSmrg lt_cv_deplibs_check_method=pass_all 37130ef0e59aSmrg ;; 37140ef0e59aSmrg 3715d5e6aabbSmrgserenity*) 3716d5e6aabbSmrg lt_cv_deplibs_check_method=pass_all 3717d5e6aabbSmrg ;; 3718d5e6aabbSmrg 37190ef0e59aSmrgsolaris*) 37200ef0e59aSmrg lt_cv_deplibs_check_method=pass_all 37210ef0e59aSmrg ;; 37220ef0e59aSmrg 37230ef0e59aSmrgsysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) 37240ef0e59aSmrg lt_cv_deplibs_check_method=pass_all 37250ef0e59aSmrg ;; 37260ef0e59aSmrg 37270ef0e59aSmrgsysv4 | sysv4.3*) 37280ef0e59aSmrg case $host_vendor in 37290ef0e59aSmrg motorola) 37300ef0e59aSmrg 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]]' 37310ef0e59aSmrg lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` 37320ef0e59aSmrg ;; 37330ef0e59aSmrg ncr) 37340ef0e59aSmrg lt_cv_deplibs_check_method=pass_all 37350ef0e59aSmrg ;; 37360ef0e59aSmrg sequent) 37370ef0e59aSmrg lt_cv_file_magic_cmd='/bin/file' 37380ef0e59aSmrg lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )' 37390ef0e59aSmrg ;; 37400ef0e59aSmrg sni) 37410ef0e59aSmrg lt_cv_file_magic_cmd='/bin/file' 37420ef0e59aSmrg lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib" 37430ef0e59aSmrg lt_cv_file_magic_test_file=/lib/libc.so 37440ef0e59aSmrg ;; 37450ef0e59aSmrg siemens) 37460ef0e59aSmrg lt_cv_deplibs_check_method=pass_all 37470ef0e59aSmrg ;; 37480ef0e59aSmrg pc) 37490ef0e59aSmrg lt_cv_deplibs_check_method=pass_all 37500ef0e59aSmrg ;; 37510ef0e59aSmrg esac 37520ef0e59aSmrg ;; 37530ef0e59aSmrg 37540ef0e59aSmrgtpf*) 37550ef0e59aSmrg lt_cv_deplibs_check_method=pass_all 37560ef0e59aSmrg ;; 37570ef0e59aSmrgos2*) 37580ef0e59aSmrg lt_cv_deplibs_check_method=pass_all 37590ef0e59aSmrg ;; 37600ef0e59aSmrgesac 37610ef0e59aSmrg]) 37620ef0e59aSmrg 37630ef0e59aSmrgfile_magic_glob= 37640ef0e59aSmrgwant_nocaseglob=no 37650ef0e59aSmrgif test "$build" = "$host"; then 37660ef0e59aSmrg case $host_os in 3767d5e6aabbSmrg mingw* | windows* | pw32*) 37680ef0e59aSmrg if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then 37690ef0e59aSmrg want_nocaseglob=yes 37700ef0e59aSmrg else 37710ef0e59aSmrg file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[[\1]]\/[[\1]]\/g;/g"` 37720ef0e59aSmrg fi 37730ef0e59aSmrg ;; 37740ef0e59aSmrg esac 37750ef0e59aSmrgfi 37760ef0e59aSmrg 37770ef0e59aSmrgfile_magic_cmd=$lt_cv_file_magic_cmd 37780ef0e59aSmrgdeplibs_check_method=$lt_cv_deplibs_check_method 37790ef0e59aSmrgtest -z "$deplibs_check_method" && deplibs_check_method=unknown 37800ef0e59aSmrg 37810ef0e59aSmrg_LT_DECL([], [deplibs_check_method], [1], 37820ef0e59aSmrg [Method to check whether dependent libraries are shared objects]) 37830ef0e59aSmrg_LT_DECL([], [file_magic_cmd], [1], 37840ef0e59aSmrg [Command to use when deplibs_check_method = "file_magic"]) 37850ef0e59aSmrg_LT_DECL([], [file_magic_glob], [1], 37860ef0e59aSmrg [How to find potential files when deplibs_check_method = "file_magic"]) 37870ef0e59aSmrg_LT_DECL([], [want_nocaseglob], [1], 37880ef0e59aSmrg [Find potential files using nocaseglob when deplibs_check_method = "file_magic"]) 37890ef0e59aSmrg])# _LT_CHECK_MAGIC_METHOD 37900ef0e59aSmrg 37910ef0e59aSmrg 37920ef0e59aSmrg# LT_PATH_NM 37930ef0e59aSmrg# ---------- 37940ef0e59aSmrg# find the pathname to a BSD- or MS-compatible name lister 37950ef0e59aSmrgAC_DEFUN([LT_PATH_NM], 37960ef0e59aSmrg[AC_REQUIRE([AC_PROG_CC])dnl 37970ef0e59aSmrgAC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM, 37980ef0e59aSmrg[if test -n "$NM"; then 37990ef0e59aSmrg # Let the user override the test. 38000ef0e59aSmrg lt_cv_path_NM=$NM 38010ef0e59aSmrgelse 38020ef0e59aSmrg lt_nm_to_check=${ac_tool_prefix}nm 38030ef0e59aSmrg if test -n "$ac_tool_prefix" && test "$build" = "$host"; then 38040ef0e59aSmrg lt_nm_to_check="$lt_nm_to_check nm" 38050ef0e59aSmrg fi 38060ef0e59aSmrg for lt_tmp_nm in $lt_nm_to_check; do 38070ef0e59aSmrg lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR 38080ef0e59aSmrg for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do 38090ef0e59aSmrg IFS=$lt_save_ifs 38100ef0e59aSmrg test -z "$ac_dir" && ac_dir=. 38110ef0e59aSmrg tmp_nm=$ac_dir/$lt_tmp_nm 38120ef0e59aSmrg if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext"; then 38130ef0e59aSmrg # Check to see if the nm accepts a BSD-compat flag. 38140ef0e59aSmrg # Adding the 'sed 1q' prevents false positives on HP-UX, which says: 38150ef0e59aSmrg # nm: unknown option "B" ignored 38160ef0e59aSmrg # Tru64's nm complains that /dev/null is an invalid object file 38170ef0e59aSmrg # MSYS converts /dev/null to NUL, MinGW nm treats NUL as empty 38180ef0e59aSmrg case $build_os in 3819d5e6aabbSmrg mingw* | windows*) lt_bad_file=conftest.nm/nofile ;; 38200ef0e59aSmrg *) lt_bad_file=/dev/null ;; 38210ef0e59aSmrg esac 382215885c33Smrg case `"$tmp_nm" -B $lt_bad_file 2>&1 | $SED '1q'` in 38230ef0e59aSmrg *$lt_bad_file* | *'Invalid file or object type'*) 38240ef0e59aSmrg lt_cv_path_NM="$tmp_nm -B" 38250ef0e59aSmrg break 2 38260ef0e59aSmrg ;; 38270ef0e59aSmrg *) 382815885c33Smrg case `"$tmp_nm" -p /dev/null 2>&1 | $SED '1q'` in 38290ef0e59aSmrg */dev/null*) 38300ef0e59aSmrg lt_cv_path_NM="$tmp_nm -p" 38310ef0e59aSmrg break 2 38320ef0e59aSmrg ;; 38330ef0e59aSmrg *) 38340ef0e59aSmrg lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but 38350ef0e59aSmrg continue # so that we can try to find one that supports BSD flags 38360ef0e59aSmrg ;; 38370ef0e59aSmrg esac 38380ef0e59aSmrg ;; 38390ef0e59aSmrg esac 38400ef0e59aSmrg fi 38410ef0e59aSmrg done 38420ef0e59aSmrg IFS=$lt_save_ifs 38430ef0e59aSmrg done 38440ef0e59aSmrg : ${lt_cv_path_NM=no} 38450ef0e59aSmrgfi]) 38460ef0e59aSmrgif test no != "$lt_cv_path_NM"; then 38470ef0e59aSmrg NM=$lt_cv_path_NM 38480ef0e59aSmrgelse 38490ef0e59aSmrg # Didn't find any BSD compatible name lister, look for dumpbin. 38500ef0e59aSmrg if test -n "$DUMPBIN"; then : 38510ef0e59aSmrg # Let the user override the test. 38520ef0e59aSmrg else 38530ef0e59aSmrg AC_CHECK_TOOLS(DUMPBIN, [dumpbin "link -dump"], :) 385415885c33Smrg case `$DUMPBIN -symbols -headers /dev/null 2>&1 | $SED '1q'` in 38550ef0e59aSmrg *COFF*) 38560ef0e59aSmrg DUMPBIN="$DUMPBIN -symbols -headers" 38570ef0e59aSmrg ;; 38580ef0e59aSmrg *) 38590ef0e59aSmrg DUMPBIN=: 38600ef0e59aSmrg ;; 38610ef0e59aSmrg esac 38620ef0e59aSmrg fi 38630ef0e59aSmrg AC_SUBST([DUMPBIN]) 38640ef0e59aSmrg if test : != "$DUMPBIN"; then 38650ef0e59aSmrg NM=$DUMPBIN 38660ef0e59aSmrg fi 38670ef0e59aSmrgfi 38680ef0e59aSmrgtest -z "$NM" && NM=nm 38690ef0e59aSmrgAC_SUBST([NM]) 38700ef0e59aSmrg_LT_DECL([], [NM], [1], [A BSD- or MS-compatible name lister])dnl 38710ef0e59aSmrg 38720ef0e59aSmrgAC_CACHE_CHECK([the name lister ($NM) interface], [lt_cv_nm_interface], 38730ef0e59aSmrg [lt_cv_nm_interface="BSD nm" 38740ef0e59aSmrg echo "int some_variable = 0;" > conftest.$ac_ext 38750ef0e59aSmrg (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&AS_MESSAGE_LOG_FD) 38760ef0e59aSmrg (eval "$ac_compile" 2>conftest.err) 38770ef0e59aSmrg cat conftest.err >&AS_MESSAGE_LOG_FD 38780ef0e59aSmrg (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD) 38790ef0e59aSmrg (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) 38800ef0e59aSmrg cat conftest.err >&AS_MESSAGE_LOG_FD 38810ef0e59aSmrg (eval echo "\"\$as_me:$LINENO: output\"" >&AS_MESSAGE_LOG_FD) 38820ef0e59aSmrg cat conftest.out >&AS_MESSAGE_LOG_FD 38830ef0e59aSmrg if $GREP 'External.*some_variable' conftest.out > /dev/null; then 38840ef0e59aSmrg lt_cv_nm_interface="MS dumpbin" 38850ef0e59aSmrg fi 38860ef0e59aSmrg rm -f conftest*]) 38870ef0e59aSmrg])# LT_PATH_NM 38880ef0e59aSmrg 38890ef0e59aSmrg# Old names: 38900ef0e59aSmrgAU_ALIAS([AM_PROG_NM], [LT_PATH_NM]) 38910ef0e59aSmrgAU_ALIAS([AC_PROG_NM], [LT_PATH_NM]) 38920ef0e59aSmrgdnl aclocal-1.4 backwards compatibility: 38930ef0e59aSmrgdnl AC_DEFUN([AM_PROG_NM], []) 38940ef0e59aSmrgdnl AC_DEFUN([AC_PROG_NM], []) 38950ef0e59aSmrg 38960ef0e59aSmrg# _LT_CHECK_SHAREDLIB_FROM_LINKLIB 38970ef0e59aSmrg# -------------------------------- 38980ef0e59aSmrg# how to determine the name of the shared library 38990ef0e59aSmrg# associated with a specific link library. 39000ef0e59aSmrg# -- PORTME fill in with the dynamic library characteristics 39010ef0e59aSmrgm4_defun([_LT_CHECK_SHAREDLIB_FROM_LINKLIB], 39020ef0e59aSmrg[m4_require([_LT_DECL_EGREP]) 39030ef0e59aSmrgm4_require([_LT_DECL_OBJDUMP]) 39040ef0e59aSmrgm4_require([_LT_DECL_DLLTOOL]) 39050ef0e59aSmrgAC_CACHE_CHECK([how to associate runtime and link libraries], 39060ef0e59aSmrglt_cv_sharedlib_from_linklib_cmd, 39070ef0e59aSmrg[lt_cv_sharedlib_from_linklib_cmd='unknown' 39080ef0e59aSmrg 39090ef0e59aSmrgcase $host_os in 3910d5e6aabbSmrgcygwin* | mingw* | windows* | pw32* | cegcc*) 39110ef0e59aSmrg # two different shell functions defined in ltmain.sh; 39120ef0e59aSmrg # decide which one to use based on capabilities of $DLLTOOL 39130ef0e59aSmrg case `$DLLTOOL --help 2>&1` in 39140ef0e59aSmrg *--identify-strict*) 39150ef0e59aSmrg lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib 39160ef0e59aSmrg ;; 39170ef0e59aSmrg *) 39180ef0e59aSmrg lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback 39190ef0e59aSmrg ;; 39200ef0e59aSmrg esac 39210ef0e59aSmrg ;; 39220ef0e59aSmrg*) 39230ef0e59aSmrg # fallback: assume linklib IS sharedlib 39240ef0e59aSmrg lt_cv_sharedlib_from_linklib_cmd=$ECHO 39250ef0e59aSmrg ;; 39260ef0e59aSmrgesac 39270ef0e59aSmrg]) 39280ef0e59aSmrgsharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd 39290ef0e59aSmrgtest -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO 39300ef0e59aSmrg 39310ef0e59aSmrg_LT_DECL([], [sharedlib_from_linklib_cmd], [1], 39320ef0e59aSmrg [Command to associate shared and link libraries]) 39330ef0e59aSmrg])# _LT_CHECK_SHAREDLIB_FROM_LINKLIB 39340ef0e59aSmrg 39350ef0e59aSmrg 39360ef0e59aSmrg# _LT_PATH_MANIFEST_TOOL 39370ef0e59aSmrg# ---------------------- 39380ef0e59aSmrg# locate the manifest tool 39390ef0e59aSmrgm4_defun([_LT_PATH_MANIFEST_TOOL], 39400ef0e59aSmrg[AC_CHECK_TOOL(MANIFEST_TOOL, mt, :) 39410ef0e59aSmrgtest -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt 3942d5e6aabbSmrgAC_CACHE_CHECK([if $MANIFEST_TOOL is a manifest tool], [lt_cv_path_manifest_tool], 3943d5e6aabbSmrg [lt_cv_path_manifest_tool=no 39440ef0e59aSmrg echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&AS_MESSAGE_LOG_FD 39450ef0e59aSmrg $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out 39460ef0e59aSmrg cat conftest.err >&AS_MESSAGE_LOG_FD 39470ef0e59aSmrg if $GREP 'Manifest Tool' conftest.out > /dev/null; then 3948d5e6aabbSmrg lt_cv_path_manifest_tool=yes 39490ef0e59aSmrg fi 39500ef0e59aSmrg rm -f conftest*]) 3951d5e6aabbSmrgif test yes != "$lt_cv_path_manifest_tool"; then 39520ef0e59aSmrg MANIFEST_TOOL=: 39530ef0e59aSmrgfi 39540ef0e59aSmrg_LT_DECL([], [MANIFEST_TOOL], [1], [Manifest tool])dnl 39550ef0e59aSmrg])# _LT_PATH_MANIFEST_TOOL 39560ef0e59aSmrg 39570ef0e59aSmrg 39580ef0e59aSmrg# _LT_DLL_DEF_P([FILE]) 39590ef0e59aSmrg# --------------------- 39600ef0e59aSmrg# True iff FILE is a Windows DLL '.def' file. 39610ef0e59aSmrg# Keep in sync with func_dll_def_p in the libtool script 39620ef0e59aSmrgAC_DEFUN([_LT_DLL_DEF_P], 39630ef0e59aSmrg[dnl 39640ef0e59aSmrg test DEF = "`$SED -n dnl 39650ef0e59aSmrg -e '\''s/^[[ ]]*//'\'' dnl Strip leading whitespace 39660ef0e59aSmrg -e '\''/^\(;.*\)*$/d'\'' dnl Delete empty lines and comments 39670ef0e59aSmrg -e '\''s/^\(EXPORTS\|LIBRARY\)\([[ ]].*\)*$/DEF/p'\'' dnl 39680ef0e59aSmrg -e q dnl Only consider the first "real" line 39690ef0e59aSmrg $1`" dnl 39700ef0e59aSmrg])# _LT_DLL_DEF_P 39710ef0e59aSmrg 39720ef0e59aSmrg 39730ef0e59aSmrg# LT_LIB_M 39740ef0e59aSmrg# -------- 39750ef0e59aSmrg# check for math library 39760ef0e59aSmrgAC_DEFUN([LT_LIB_M], 39770ef0e59aSmrg[AC_REQUIRE([AC_CANONICAL_HOST])dnl 39780ef0e59aSmrgLIBM= 39790ef0e59aSmrgcase $host in 3980d5e6aabbSmrg*-*-beos* | *-*-cegcc* | *-*-cygwin* | *-*-haiku* | *-*-mingw* | *-*-pw32* | *-*-darwin*) 39810ef0e59aSmrg # These system don't have libm, or don't need it 39820ef0e59aSmrg ;; 39830ef0e59aSmrg*-ncr-sysv4.3*) 39840ef0e59aSmrg AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM=-lmw) 39850ef0e59aSmrg AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm") 39860ef0e59aSmrg ;; 39870ef0e59aSmrg*) 39880ef0e59aSmrg AC_CHECK_LIB(m, cos, LIBM=-lm) 39890ef0e59aSmrg ;; 39900ef0e59aSmrgesac 39910ef0e59aSmrgAC_SUBST([LIBM]) 39920ef0e59aSmrg])# LT_LIB_M 39930ef0e59aSmrg 39940ef0e59aSmrg# Old name: 39950ef0e59aSmrgAU_ALIAS([AC_CHECK_LIBM], [LT_LIB_M]) 39960ef0e59aSmrgdnl aclocal-1.4 backwards compatibility: 39970ef0e59aSmrgdnl AC_DEFUN([AC_CHECK_LIBM], []) 39980ef0e59aSmrg 39990ef0e59aSmrg 40000ef0e59aSmrg# _LT_COMPILER_NO_RTTI([TAGNAME]) 40010ef0e59aSmrg# ------------------------------- 40020ef0e59aSmrgm4_defun([_LT_COMPILER_NO_RTTI], 40030ef0e59aSmrg[m4_require([_LT_TAG_COMPILER])dnl 40040ef0e59aSmrg 40050ef0e59aSmrg_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= 40060ef0e59aSmrg 40070ef0e59aSmrgif test yes = "$GCC"; then 40080ef0e59aSmrg case $cc_basename in 40090ef0e59aSmrg nvcc*) 40100ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -Xcompiler -fno-builtin' ;; 40110ef0e59aSmrg *) 40120ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' ;; 40130ef0e59aSmrg esac 40140ef0e59aSmrg 40150ef0e59aSmrg _LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions], 40160ef0e59aSmrg lt_cv_prog_compiler_rtti_exceptions, 40170ef0e59aSmrg [-fno-rtti -fno-exceptions], [], 40180ef0e59aSmrg [_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"]) 40190ef0e59aSmrgfi 40200ef0e59aSmrg_LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1], 40210ef0e59aSmrg [Compiler flag to turn off builtin functions]) 40220ef0e59aSmrg])# _LT_COMPILER_NO_RTTI 40230ef0e59aSmrg 40240ef0e59aSmrg 40250ef0e59aSmrg# _LT_CMD_GLOBAL_SYMBOLS 40260ef0e59aSmrg# ---------------------- 40270ef0e59aSmrgm4_defun([_LT_CMD_GLOBAL_SYMBOLS], 40280ef0e59aSmrg[AC_REQUIRE([AC_CANONICAL_HOST])dnl 40290ef0e59aSmrgAC_REQUIRE([AC_PROG_CC])dnl 40300ef0e59aSmrgAC_REQUIRE([AC_PROG_AWK])dnl 40310ef0e59aSmrgAC_REQUIRE([LT_PATH_NM])dnl 40320ef0e59aSmrgAC_REQUIRE([LT_PATH_LD])dnl 40330ef0e59aSmrgm4_require([_LT_DECL_SED])dnl 40340ef0e59aSmrgm4_require([_LT_DECL_EGREP])dnl 40350ef0e59aSmrgm4_require([_LT_TAG_COMPILER])dnl 40360ef0e59aSmrg 40370ef0e59aSmrg# Check for command to grab the raw symbol name followed by C symbol from nm. 40380ef0e59aSmrgAC_MSG_CHECKING([command to parse $NM output from $compiler object]) 40390ef0e59aSmrgAC_CACHE_VAL([lt_cv_sys_global_symbol_pipe], 40400ef0e59aSmrg[ 40410ef0e59aSmrg# These are sane defaults that work on at least a few old systems. 40420ef0e59aSmrg# [They come from Ultrix. What could be older than Ultrix?!! ;)] 40430ef0e59aSmrg 40440ef0e59aSmrg# Character class describing NM global symbol codes. 40450ef0e59aSmrgsymcode='[[BCDEGRST]]' 40460ef0e59aSmrg 40470ef0e59aSmrg# Regexp to match symbols that can be accessed directly from C. 40480ef0e59aSmrgsympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)' 40490ef0e59aSmrg 40500ef0e59aSmrg# Define system-specific variables. 40510ef0e59aSmrgcase $host_os in 40520ef0e59aSmrgaix*) 40530ef0e59aSmrg symcode='[[BCDT]]' 40540ef0e59aSmrg ;; 4055d5e6aabbSmrgcygwin* | mingw* | windows* | pw32* | cegcc*) 40560ef0e59aSmrg symcode='[[ABCDGISTW]]' 40570ef0e59aSmrg ;; 40580ef0e59aSmrghpux*) 40590ef0e59aSmrg if test ia64 = "$host_cpu"; then 40600ef0e59aSmrg symcode='[[ABCDEGRST]]' 40610ef0e59aSmrg fi 40620ef0e59aSmrg ;; 40630ef0e59aSmrgirix* | nonstopux*) 40640ef0e59aSmrg symcode='[[BCDEGRST]]' 40650ef0e59aSmrg ;; 40660ef0e59aSmrgosf*) 40670ef0e59aSmrg symcode='[[BCDEGQRST]]' 40680ef0e59aSmrg ;; 40690ef0e59aSmrgsolaris*) 4070d5e6aabbSmrg symcode='[[BCDRT]]' 40710ef0e59aSmrg ;; 40720ef0e59aSmrgsco3.2v5*) 40730ef0e59aSmrg symcode='[[DT]]' 40740ef0e59aSmrg ;; 40750ef0e59aSmrgsysv4.2uw2*) 40760ef0e59aSmrg symcode='[[DT]]' 40770ef0e59aSmrg ;; 40780ef0e59aSmrgsysv5* | sco5v6* | unixware* | OpenUNIX*) 40790ef0e59aSmrg symcode='[[ABDT]]' 40800ef0e59aSmrg ;; 40810ef0e59aSmrgsysv4) 40820ef0e59aSmrg symcode='[[DFNSTU]]' 40830ef0e59aSmrg ;; 40840ef0e59aSmrgesac 40850ef0e59aSmrg 40860ef0e59aSmrg# If we're using GNU nm, then use its standard symbol codes. 40870ef0e59aSmrgcase `$NM -V 2>&1` in 40880ef0e59aSmrg*GNU* | *'with BFD'*) 40890ef0e59aSmrg symcode='[[ABCDGIRSTW]]' ;; 40900ef0e59aSmrgesac 40910ef0e59aSmrg 40920ef0e59aSmrgif test "$lt_cv_nm_interface" = "MS dumpbin"; then 40930ef0e59aSmrg # Gets list of data symbols to import. 409415885c33Smrg lt_cv_sys_global_symbol_to_import="$SED -n -e 's/^I .* \(.*\)$/\1/p'" 40950ef0e59aSmrg # Adjust the below global symbol transforms to fixup imported variables. 40960ef0e59aSmrg lt_cdecl_hook=" -e 's/^I .* \(.*\)$/extern __declspec(dllimport) char \1;/p'" 40970ef0e59aSmrg lt_c_name_hook=" -e 's/^I .* \(.*\)$/ {\"\1\", (void *) 0},/p'" 40980ef0e59aSmrg lt_c_name_lib_hook="\ 40990ef0e59aSmrg -e 's/^I .* \(lib.*\)$/ {\"\1\", (void *) 0},/p'\ 41000ef0e59aSmrg -e 's/^I .* \(.*\)$/ {\"lib\1\", (void *) 0},/p'" 41010ef0e59aSmrgelse 41020ef0e59aSmrg # Disable hooks by default. 41030ef0e59aSmrg lt_cv_sys_global_symbol_to_import= 41040ef0e59aSmrg lt_cdecl_hook= 41050ef0e59aSmrg lt_c_name_hook= 41060ef0e59aSmrg lt_c_name_lib_hook= 41070ef0e59aSmrgfi 41080ef0e59aSmrg 41090ef0e59aSmrg# Transform an extracted symbol line into a proper C declaration. 41100ef0e59aSmrg# Some systems (esp. on ia64) link data and code symbols differently, 41110ef0e59aSmrg# so use this general approach. 411215885c33Smrglt_cv_sys_global_symbol_to_cdecl="$SED -n"\ 41130ef0e59aSmrg$lt_cdecl_hook\ 41140ef0e59aSmrg" -e 's/^T .* \(.*\)$/extern int \1();/p'"\ 41150ef0e59aSmrg" -e 's/^$symcode$symcode* .* \(.*\)$/extern char \1;/p'" 41160ef0e59aSmrg 41170ef0e59aSmrg# Transform an extracted symbol line into symbol name and symbol address 411815885c33Smrglt_cv_sys_global_symbol_to_c_name_address="$SED -n"\ 41190ef0e59aSmrg$lt_c_name_hook\ 41200ef0e59aSmrg" -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ 41210ef0e59aSmrg" -e 's/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/p'" 41220ef0e59aSmrg 41230ef0e59aSmrg# Transform an extracted symbol line into symbol name with lib prefix and 41240ef0e59aSmrg# symbol address. 412515885c33Smrglt_cv_sys_global_symbol_to_c_name_address_lib_prefix="$SED -n"\ 41260ef0e59aSmrg$lt_c_name_lib_hook\ 41270ef0e59aSmrg" -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ 41280ef0e59aSmrg" -e 's/^$symcode$symcode* .* \(lib.*\)$/ {\"\1\", (void *) \&\1},/p'"\ 41290ef0e59aSmrg" -e 's/^$symcode$symcode* .* \(.*\)$/ {\"lib\1\", (void *) \&\1},/p'" 41300ef0e59aSmrg 41310ef0e59aSmrg# Handle CRLF in mingw tool chain 41320ef0e59aSmrgopt_cr= 41330ef0e59aSmrgcase $build_os in 4134d5e6aabbSmrgmingw* | windows*) 41350ef0e59aSmrg opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp 41360ef0e59aSmrg ;; 41370ef0e59aSmrgesac 41380ef0e59aSmrg 41390ef0e59aSmrg# Try without a prefix underscore, then with it. 41400ef0e59aSmrgfor ac_symprfx in "" "_"; do 41410ef0e59aSmrg 41420ef0e59aSmrg # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. 41430ef0e59aSmrg symxfrm="\\1 $ac_symprfx\\2 \\2" 41440ef0e59aSmrg 41450ef0e59aSmrg # Write the raw and C identifiers. 41460ef0e59aSmrg if test "$lt_cv_nm_interface" = "MS dumpbin"; then 41470ef0e59aSmrg # Fake it for dumpbin and say T for any non-static function, 41480ef0e59aSmrg # D for any global variable and I for any imported variable. 414915885c33Smrg # Also find C++ and __fastcall symbols from MSVC++ or ICC, 41500ef0e59aSmrg # which start with @ or ?. 41510ef0e59aSmrg lt_cv_sys_global_symbol_pipe="$AWK ['"\ 41520ef0e59aSmrg" {last_section=section; section=\$ 3};"\ 41530ef0e59aSmrg" /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\ 41540ef0e59aSmrg" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\ 41550ef0e59aSmrg" /^ *Symbol name *: /{split(\$ 0,sn,\":\"); si=substr(sn[2],2)};"\ 41560ef0e59aSmrg" /^ *Type *: code/{print \"T\",si,substr(si,length(prfx))};"\ 41570ef0e59aSmrg" /^ *Type *: data/{print \"I\",si,substr(si,length(prfx))};"\ 41580ef0e59aSmrg" \$ 0!~/External *\|/{next};"\ 41590ef0e59aSmrg" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\ 41600ef0e59aSmrg" {if(hide[section]) next};"\ 41610ef0e59aSmrg" {f=\"D\"}; \$ 0~/\(\).*\|/{f=\"T\"};"\ 41620ef0e59aSmrg" {split(\$ 0,a,/\||\r/); split(a[2],s)};"\ 41630ef0e59aSmrg" s[1]~/^[@?]/{print f,s[1],s[1]; next};"\ 41640ef0e59aSmrg" s[1]~prfx {split(s[1],t,\"@\"); print f,t[1],substr(t[1],length(prfx))}"\ 41650ef0e59aSmrg" ' prfx=^$ac_symprfx]" 41660ef0e59aSmrg else 416715885c33Smrg lt_cv_sys_global_symbol_pipe="$SED -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" 41680ef0e59aSmrg fi 416915885c33Smrg lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | $SED '/ __gnu_lto/d'" 41700ef0e59aSmrg 41710ef0e59aSmrg # Check to see that the pipe works correctly. 41720ef0e59aSmrg pipe_works=no 41730ef0e59aSmrg 41740ef0e59aSmrg rm -f conftest* 41750ef0e59aSmrg cat > conftest.$ac_ext <<_LT_EOF 41760ef0e59aSmrg#ifdef __cplusplus 41770ef0e59aSmrgextern "C" { 41780ef0e59aSmrg#endif 41790ef0e59aSmrgchar nm_test_var; 41800ef0e59aSmrgvoid nm_test_func(void); 41810ef0e59aSmrgvoid nm_test_func(void){} 41820ef0e59aSmrg#ifdef __cplusplus 41830ef0e59aSmrg} 41840ef0e59aSmrg#endif 4185d5e6aabbSmrgint main(void){nm_test_var='a';nm_test_func();return(0);} 41860ef0e59aSmrg_LT_EOF 41870ef0e59aSmrg 41880ef0e59aSmrg if AC_TRY_EVAL(ac_compile); then 41890ef0e59aSmrg # Now try to grab the symbols. 41900ef0e59aSmrg nlist=conftest.nm 4191d5e6aabbSmrg $ECHO "$as_me:$LINENO: $NM conftest.$ac_objext | $lt_cv_sys_global_symbol_pipe > $nlist" >&AS_MESSAGE_LOG_FD 4192d5e6aabbSmrg if eval "$NM" conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist 2>&AS_MESSAGE_LOG_FD && test -s "$nlist"; then 41930ef0e59aSmrg # Try sorting and uniquifying the output. 41940ef0e59aSmrg if sort "$nlist" | uniq > "$nlist"T; then 41950ef0e59aSmrg mv -f "$nlist"T "$nlist" 41960ef0e59aSmrg else 41970ef0e59aSmrg rm -f "$nlist"T 41980ef0e59aSmrg fi 41990ef0e59aSmrg 42000ef0e59aSmrg # Make sure that we snagged all the symbols we need. 42010ef0e59aSmrg if $GREP ' nm_test_var$' "$nlist" >/dev/null; then 42020ef0e59aSmrg if $GREP ' nm_test_func$' "$nlist" >/dev/null; then 42030ef0e59aSmrg cat <<_LT_EOF > conftest.$ac_ext 42040ef0e59aSmrg/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ 42050ef0e59aSmrg#if defined _WIN32 || defined __CYGWIN__ || defined _WIN32_WCE 42060ef0e59aSmrg/* DATA imports from DLLs on WIN32 can't be const, because runtime 42070ef0e59aSmrg relocations are performed -- see ld's documentation on pseudo-relocs. */ 42080ef0e59aSmrg# define LT@&t@_DLSYM_CONST 42090ef0e59aSmrg#elif defined __osf__ 42100ef0e59aSmrg/* This system does not cope well with relocations in const data. */ 42110ef0e59aSmrg# define LT@&t@_DLSYM_CONST 42120ef0e59aSmrg#else 42130ef0e59aSmrg# define LT@&t@_DLSYM_CONST const 42140ef0e59aSmrg#endif 42150ef0e59aSmrg 42160ef0e59aSmrg#ifdef __cplusplus 42170ef0e59aSmrgextern "C" { 42180ef0e59aSmrg#endif 42190ef0e59aSmrg 42200ef0e59aSmrg_LT_EOF 42210ef0e59aSmrg # Now generate the symbol file. 42220ef0e59aSmrg eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext' 42230ef0e59aSmrg 42240ef0e59aSmrg cat <<_LT_EOF >> conftest.$ac_ext 42250ef0e59aSmrg 42260ef0e59aSmrg/* The mapping between symbol names and symbols. */ 42270ef0e59aSmrgLT@&t@_DLSYM_CONST struct { 42280ef0e59aSmrg const char *name; 42290ef0e59aSmrg void *address; 42300ef0e59aSmrg} 42310ef0e59aSmrglt__PROGRAM__LTX_preloaded_symbols[[]] = 42320ef0e59aSmrg{ 42330ef0e59aSmrg { "@PROGRAM@", (void *) 0 }, 42340ef0e59aSmrg_LT_EOF 42350ef0e59aSmrg $SED "s/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext 42360ef0e59aSmrg cat <<\_LT_EOF >> conftest.$ac_ext 42370ef0e59aSmrg {0, (void *) 0} 42380ef0e59aSmrg}; 42390ef0e59aSmrg 42400ef0e59aSmrg/* This works around a problem in FreeBSD linker */ 42410ef0e59aSmrg#ifdef FREEBSD_WORKAROUND 42420ef0e59aSmrgstatic const void *lt_preloaded_setup() { 42430ef0e59aSmrg return lt__PROGRAM__LTX_preloaded_symbols; 42440ef0e59aSmrg} 42450ef0e59aSmrg#endif 42460ef0e59aSmrg 42470ef0e59aSmrg#ifdef __cplusplus 42480ef0e59aSmrg} 42490ef0e59aSmrg#endif 42500ef0e59aSmrg_LT_EOF 42510ef0e59aSmrg # Now try linking the two files. 42520ef0e59aSmrg mv conftest.$ac_objext conftstm.$ac_objext 42530ef0e59aSmrg lt_globsym_save_LIBS=$LIBS 42540ef0e59aSmrg lt_globsym_save_CFLAGS=$CFLAGS 42550ef0e59aSmrg LIBS=conftstm.$ac_objext 42560ef0e59aSmrg CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)" 42570ef0e59aSmrg if AC_TRY_EVAL(ac_link) && test -s conftest$ac_exeext; then 42580ef0e59aSmrg pipe_works=yes 42590ef0e59aSmrg fi 42600ef0e59aSmrg LIBS=$lt_globsym_save_LIBS 42610ef0e59aSmrg CFLAGS=$lt_globsym_save_CFLAGS 42620ef0e59aSmrg else 42630ef0e59aSmrg echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD 42640ef0e59aSmrg fi 42650ef0e59aSmrg else 42660ef0e59aSmrg echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD 42670ef0e59aSmrg fi 42680ef0e59aSmrg else 42690ef0e59aSmrg echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD 42700ef0e59aSmrg fi 42710ef0e59aSmrg else 42720ef0e59aSmrg echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD 42730ef0e59aSmrg cat conftest.$ac_ext >&5 42740ef0e59aSmrg fi 42750ef0e59aSmrg rm -rf conftest* conftst* 42760ef0e59aSmrg 42770ef0e59aSmrg # Do not use the global_symbol_pipe unless it works. 42780ef0e59aSmrg if test yes = "$pipe_works"; then 42790ef0e59aSmrg break 42800ef0e59aSmrg else 42810ef0e59aSmrg lt_cv_sys_global_symbol_pipe= 42820ef0e59aSmrg fi 42830ef0e59aSmrgdone 42840ef0e59aSmrg]) 42850ef0e59aSmrgif test -z "$lt_cv_sys_global_symbol_pipe"; then 42860ef0e59aSmrg lt_cv_sys_global_symbol_to_cdecl= 42870ef0e59aSmrgfi 42880ef0e59aSmrgif test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then 42890ef0e59aSmrg AC_MSG_RESULT(failed) 42900ef0e59aSmrgelse 42910ef0e59aSmrg AC_MSG_RESULT(ok) 42920ef0e59aSmrgfi 42930ef0e59aSmrg 42940ef0e59aSmrg# Response file support. 42950ef0e59aSmrgif test "$lt_cv_nm_interface" = "MS dumpbin"; then 42960ef0e59aSmrg nm_file_list_spec='@' 42970ef0e59aSmrgelif $NM --help 2>/dev/null | grep '[[@]]FILE' >/dev/null; then 42980ef0e59aSmrg nm_file_list_spec='@' 42990ef0e59aSmrgfi 43000ef0e59aSmrg 43010ef0e59aSmrg_LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1], 43020ef0e59aSmrg [Take the output of nm and produce a listing of raw symbols and C names]) 43030ef0e59aSmrg_LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1], 43040ef0e59aSmrg [Transform the output of nm in a proper C declaration]) 43050ef0e59aSmrg_LT_DECL([global_symbol_to_import], [lt_cv_sys_global_symbol_to_import], [1], 43060ef0e59aSmrg [Transform the output of nm into a list of symbols to manually relocate]) 43070ef0e59aSmrg_LT_DECL([global_symbol_to_c_name_address], 43080ef0e59aSmrg [lt_cv_sys_global_symbol_to_c_name_address], [1], 43090ef0e59aSmrg [Transform the output of nm in a C name address pair]) 43100ef0e59aSmrg_LT_DECL([global_symbol_to_c_name_address_lib_prefix], 43110ef0e59aSmrg [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1], 43120ef0e59aSmrg [Transform the output of nm in a C name address pair when lib prefix is needed]) 43130ef0e59aSmrg_LT_DECL([nm_interface], [lt_cv_nm_interface], [1], 43140ef0e59aSmrg [The name lister interface]) 43150ef0e59aSmrg_LT_DECL([], [nm_file_list_spec], [1], 43160ef0e59aSmrg [Specify filename containing input files for $NM]) 43170ef0e59aSmrg]) # _LT_CMD_GLOBAL_SYMBOLS 43180ef0e59aSmrg 43190ef0e59aSmrg 43200ef0e59aSmrg# _LT_COMPILER_PIC([TAGNAME]) 43210ef0e59aSmrg# --------------------------- 43220ef0e59aSmrgm4_defun([_LT_COMPILER_PIC], 43230ef0e59aSmrg[m4_require([_LT_TAG_COMPILER])dnl 43240ef0e59aSmrg_LT_TAGVAR(lt_prog_compiler_wl, $1)= 43250ef0e59aSmrg_LT_TAGVAR(lt_prog_compiler_pic, $1)= 43260ef0e59aSmrg_LT_TAGVAR(lt_prog_compiler_static, $1)= 43270ef0e59aSmrg 43280ef0e59aSmrgm4_if([$1], [CXX], [ 43290ef0e59aSmrg # C++ specific cases for pic, static, wl, etc. 43300ef0e59aSmrg if test yes = "$GXX"; then 43310ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 43320ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 43330ef0e59aSmrg 43340ef0e59aSmrg case $host_os in 43350ef0e59aSmrg aix*) 43360ef0e59aSmrg # All AIX code is PIC. 43370ef0e59aSmrg if test ia64 = "$host_cpu"; then 43380ef0e59aSmrg # AIX 5 now supports IA64 processor 43390ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 43400ef0e59aSmrg fi 43410ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 43420ef0e59aSmrg ;; 43430ef0e59aSmrg 43440ef0e59aSmrg amigaos*) 43450ef0e59aSmrg case $host_cpu in 43460ef0e59aSmrg powerpc) 43470ef0e59aSmrg # see comment about AmigaOS4 .so support 43480ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 43490ef0e59aSmrg ;; 43500ef0e59aSmrg m68k) 43510ef0e59aSmrg # FIXME: we need at least 68020 code to build shared libraries, but 43520ef0e59aSmrg # adding the '-m68020' flag to GCC prevents building anything better, 43530ef0e59aSmrg # like '-m68040'. 43540ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' 43550ef0e59aSmrg ;; 43560ef0e59aSmrg esac 43570ef0e59aSmrg ;; 43580ef0e59aSmrg 43590ef0e59aSmrg beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) 43600ef0e59aSmrg # PIC is the default for these OSes. 43610ef0e59aSmrg ;; 4362d5e6aabbSmrg mingw* | windows* | cygwin* | os2* | pw32* | cegcc*) 43630ef0e59aSmrg # This hack is so that the source file can tell whether it is being 43640ef0e59aSmrg # built for inclusion in a dll (and should export symbols for example). 43650ef0e59aSmrg # Although the cygwin gcc ignores -fPIC, still need this for old-style 43660ef0e59aSmrg # (--disable-auto-import) libraries 43670ef0e59aSmrg m4_if([$1], [GCJ], [], 43680ef0e59aSmrg [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) 43690ef0e59aSmrg case $host_os in 43700ef0e59aSmrg os2*) 43710ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static' 43720ef0e59aSmrg ;; 43730ef0e59aSmrg esac 43740ef0e59aSmrg ;; 43750ef0e59aSmrg darwin* | rhapsody*) 43760ef0e59aSmrg # PIC is the default on this platform 43770ef0e59aSmrg # Common symbols not allowed in MH_DYLIB files 43780ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' 43790ef0e59aSmrg ;; 43800ef0e59aSmrg *djgpp*) 43810ef0e59aSmrg # DJGPP does not support shared libraries at all 43820ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)= 43830ef0e59aSmrg ;; 43840ef0e59aSmrg haiku*) 43850ef0e59aSmrg # PIC is the default for Haiku. 43860ef0e59aSmrg # The "-static" flag exists, but is broken. 43870ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)= 43880ef0e59aSmrg ;; 43890ef0e59aSmrg interix[[3-9]]*) 43900ef0e59aSmrg # Interix 3.x gcc -fpic/-fPIC options generate broken code. 43910ef0e59aSmrg # Instead, we relocate shared libraries at runtime. 43920ef0e59aSmrg ;; 43930ef0e59aSmrg sysv4*MP*) 43940ef0e59aSmrg if test -d /usr/nec; then 43950ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic 43960ef0e59aSmrg fi 43970ef0e59aSmrg ;; 43980ef0e59aSmrg hpux*) 43990ef0e59aSmrg # PIC is the default for 64-bit PA HP-UX, but not for 32-bit 44000ef0e59aSmrg # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag 44010ef0e59aSmrg # sets the default TLS model and affects inlining. 44020ef0e59aSmrg case $host_cpu in 44030ef0e59aSmrg hppa*64*) 44040ef0e59aSmrg ;; 44050ef0e59aSmrg *) 44060ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 44070ef0e59aSmrg ;; 44080ef0e59aSmrg esac 44090ef0e59aSmrg ;; 44100ef0e59aSmrg *qnx* | *nto*) 44110ef0e59aSmrg # QNX uses GNU C++, but need to define -shared option too, otherwise 44120ef0e59aSmrg # it will coredump. 44130ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' 44140ef0e59aSmrg ;; 44150ef0e59aSmrg *) 44160ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 44170ef0e59aSmrg ;; 44180ef0e59aSmrg esac 44190ef0e59aSmrg else 44200ef0e59aSmrg case $host_os in 44210ef0e59aSmrg aix[[4-9]]*) 44220ef0e59aSmrg # All AIX code is PIC. 44230ef0e59aSmrg if test ia64 = "$host_cpu"; then 44240ef0e59aSmrg # AIX 5 now supports IA64 processor 44250ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 44260ef0e59aSmrg else 44270ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' 44280ef0e59aSmrg fi 44290ef0e59aSmrg ;; 44300ef0e59aSmrg chorus*) 44310ef0e59aSmrg case $cc_basename in 44320ef0e59aSmrg cxch68*) 44330ef0e59aSmrg # Green Hills C++ Compiler 44340ef0e59aSmrg # _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" 44350ef0e59aSmrg ;; 44360ef0e59aSmrg esac 44370ef0e59aSmrg ;; 4438d5e6aabbSmrg mingw* | windows* | cygwin* | os2* | pw32* | cegcc*) 44390ef0e59aSmrg # This hack is so that the source file can tell whether it is being 44400ef0e59aSmrg # built for inclusion in a dll (and should export symbols for example). 44410ef0e59aSmrg m4_if([$1], [GCJ], [], 44420ef0e59aSmrg [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) 44430ef0e59aSmrg ;; 44440ef0e59aSmrg dgux*) 44450ef0e59aSmrg case $cc_basename in 44460ef0e59aSmrg ec++*) 44470ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 44480ef0e59aSmrg ;; 44490ef0e59aSmrg ghcx*) 44500ef0e59aSmrg # Green Hills C++ Compiler 44510ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 44520ef0e59aSmrg ;; 44530ef0e59aSmrg *) 44540ef0e59aSmrg ;; 44550ef0e59aSmrg esac 44560ef0e59aSmrg ;; 445715885c33Smrg freebsd* | dragonfly* | midnightbsd*) 44580ef0e59aSmrg # FreeBSD uses GNU C++ 44590ef0e59aSmrg ;; 44600ef0e59aSmrg hpux9* | hpux10* | hpux11*) 44610ef0e59aSmrg case $cc_basename in 44620ef0e59aSmrg CC*) 44630ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 44640ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive' 44650ef0e59aSmrg if test ia64 != "$host_cpu"; then 44660ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' 44670ef0e59aSmrg fi 44680ef0e59aSmrg ;; 44690ef0e59aSmrg aCC*) 44700ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 44710ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive' 44720ef0e59aSmrg case $host_cpu in 44730ef0e59aSmrg hppa*64*|ia64*) 44740ef0e59aSmrg # +Z the default 44750ef0e59aSmrg ;; 44760ef0e59aSmrg *) 44770ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' 44780ef0e59aSmrg ;; 44790ef0e59aSmrg esac 44800ef0e59aSmrg ;; 44810ef0e59aSmrg *) 44820ef0e59aSmrg ;; 44830ef0e59aSmrg esac 44840ef0e59aSmrg ;; 44850ef0e59aSmrg interix*) 44860ef0e59aSmrg # This is c89, which is MS Visual C++ (no shared libs) 44870ef0e59aSmrg # Anyone wants to do a port? 44880ef0e59aSmrg ;; 44890ef0e59aSmrg irix5* | irix6* | nonstopux*) 44900ef0e59aSmrg case $cc_basename in 44910ef0e59aSmrg CC*) 44920ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 44930ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 44940ef0e59aSmrg # CC pic flag -KPIC is the default. 44950ef0e59aSmrg ;; 44960ef0e59aSmrg *) 44970ef0e59aSmrg ;; 44980ef0e59aSmrg esac 44990ef0e59aSmrg ;; 45000ef0e59aSmrg linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) 45010ef0e59aSmrg case $cc_basename in 45020ef0e59aSmrg KCC*) 45030ef0e59aSmrg # KAI C++ Compiler 45040ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' 45050ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 45060ef0e59aSmrg ;; 45070ef0e59aSmrg ecpc* ) 45080ef0e59aSmrg # old Intel C++ for x86_64, which still supported -KPIC. 45090ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 45100ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 45110ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 45120ef0e59aSmrg ;; 45130ef0e59aSmrg icpc* ) 45140ef0e59aSmrg # Intel C++, used to be incompatible with GCC. 45150ef0e59aSmrg # ICC 10 doesn't accept -KPIC any more. 45160ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 45170ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 45180ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 45190ef0e59aSmrg ;; 45200ef0e59aSmrg pgCC* | pgcpp*) 45210ef0e59aSmrg # Portland Group C++ compiler 45220ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 45230ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' 45240ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 45250ef0e59aSmrg ;; 45260ef0e59aSmrg cxx*) 45270ef0e59aSmrg # Compaq C++ 45280ef0e59aSmrg # Make sure the PIC flag is empty. It appears that all Alpha 45290ef0e59aSmrg # Linux and Compaq Tru64 Unix objects are PIC. 45300ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)= 45310ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 45320ef0e59aSmrg ;; 45330ef0e59aSmrg xlc* | xlC* | bgxl[[cC]]* | mpixl[[cC]]*) 45340ef0e59aSmrg # IBM XL 8.0, 9.0 on PPC and BlueGene 45350ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 45360ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' 45370ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' 45380ef0e59aSmrg ;; 45390ef0e59aSmrg *) 454015885c33Smrg case `$CC -V 2>&1 | $SED 5q` in 45410ef0e59aSmrg *Sun\ C*) 45420ef0e59aSmrg # Sun C++ 5.9 45430ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 45440ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 45450ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' 45460ef0e59aSmrg ;; 45470ef0e59aSmrg esac 45480ef0e59aSmrg ;; 45490ef0e59aSmrg esac 45500ef0e59aSmrg ;; 45510ef0e59aSmrg lynxos*) 45520ef0e59aSmrg ;; 45530ef0e59aSmrg m88k*) 45540ef0e59aSmrg ;; 45550ef0e59aSmrg mvs*) 45560ef0e59aSmrg case $cc_basename in 45570ef0e59aSmrg cxx*) 45580ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall' 45590ef0e59aSmrg ;; 45600ef0e59aSmrg *) 45610ef0e59aSmrg ;; 45620ef0e59aSmrg esac 45630ef0e59aSmrg ;; 4564d5e6aabbSmrg netbsd* | netbsdelf*-gnu) 4565d5e6aabbSmrg ;; 4566d5e6aabbSmrg *-mlibc) 45670ef0e59aSmrg ;; 45680ef0e59aSmrg *qnx* | *nto*) 45690ef0e59aSmrg # QNX uses GNU C++, but need to define -shared option too, otherwise 45700ef0e59aSmrg # it will coredump. 45710ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' 45720ef0e59aSmrg ;; 45730ef0e59aSmrg osf3* | osf4* | osf5*) 45740ef0e59aSmrg case $cc_basename in 45750ef0e59aSmrg KCC*) 45760ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' 45770ef0e59aSmrg ;; 45780ef0e59aSmrg RCC*) 45790ef0e59aSmrg # Rational C++ 2.4.1 45800ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 45810ef0e59aSmrg ;; 45820ef0e59aSmrg cxx*) 45830ef0e59aSmrg # Digital/Compaq C++ 45840ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 45850ef0e59aSmrg # Make sure the PIC flag is empty. It appears that all Alpha 45860ef0e59aSmrg # Linux and Compaq Tru64 Unix objects are PIC. 45870ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)= 45880ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 45890ef0e59aSmrg ;; 45900ef0e59aSmrg *) 45910ef0e59aSmrg ;; 45920ef0e59aSmrg esac 45930ef0e59aSmrg ;; 45940ef0e59aSmrg psos*) 45950ef0e59aSmrg ;; 4596d5e6aabbSmrg serenity*) 4597d5e6aabbSmrg ;; 45980ef0e59aSmrg solaris*) 45990ef0e59aSmrg case $cc_basename in 46000ef0e59aSmrg CC* | sunCC*) 46010ef0e59aSmrg # Sun C++ 4.2, 5.x and Centerline C++ 46020ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 46030ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 46040ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' 46050ef0e59aSmrg ;; 46060ef0e59aSmrg gcx*) 46070ef0e59aSmrg # Green Hills C++ Compiler 46080ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' 46090ef0e59aSmrg ;; 46100ef0e59aSmrg *) 46110ef0e59aSmrg ;; 46120ef0e59aSmrg esac 46130ef0e59aSmrg ;; 46140ef0e59aSmrg sunos4*) 46150ef0e59aSmrg case $cc_basename in 46160ef0e59aSmrg CC*) 46170ef0e59aSmrg # Sun C++ 4.x 46180ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 46190ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 46200ef0e59aSmrg ;; 46210ef0e59aSmrg lcc*) 46220ef0e59aSmrg # Lucid 46230ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 46240ef0e59aSmrg ;; 46250ef0e59aSmrg *) 46260ef0e59aSmrg ;; 46270ef0e59aSmrg esac 46280ef0e59aSmrg ;; 46290ef0e59aSmrg sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) 46300ef0e59aSmrg case $cc_basename in 46310ef0e59aSmrg CC*) 46320ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 46330ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 46340ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 46350ef0e59aSmrg ;; 46360ef0e59aSmrg esac 46370ef0e59aSmrg ;; 46380ef0e59aSmrg tandem*) 46390ef0e59aSmrg case $cc_basename in 46400ef0e59aSmrg NCC*) 46410ef0e59aSmrg # NonStop-UX NCC 3.20 46420ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 46430ef0e59aSmrg ;; 46440ef0e59aSmrg *) 46450ef0e59aSmrg ;; 46460ef0e59aSmrg esac 46470ef0e59aSmrg ;; 46480ef0e59aSmrg vxworks*) 46490ef0e59aSmrg ;; 46500ef0e59aSmrg *) 46510ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 46520ef0e59aSmrg ;; 46530ef0e59aSmrg esac 46540ef0e59aSmrg fi 46550ef0e59aSmrg], 46560ef0e59aSmrg[ 46570ef0e59aSmrg if test yes = "$GCC"; then 46580ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 46590ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 46600ef0e59aSmrg 46610ef0e59aSmrg case $host_os in 46620ef0e59aSmrg aix*) 46630ef0e59aSmrg # All AIX code is PIC. 46640ef0e59aSmrg if test ia64 = "$host_cpu"; then 46650ef0e59aSmrg # AIX 5 now supports IA64 processor 46660ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 46670ef0e59aSmrg fi 46680ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 46690ef0e59aSmrg ;; 46700ef0e59aSmrg 46710ef0e59aSmrg amigaos*) 46720ef0e59aSmrg case $host_cpu in 46730ef0e59aSmrg powerpc) 46740ef0e59aSmrg # see comment about AmigaOS4 .so support 46750ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 46760ef0e59aSmrg ;; 46770ef0e59aSmrg m68k) 46780ef0e59aSmrg # FIXME: we need at least 68020 code to build shared libraries, but 46790ef0e59aSmrg # adding the '-m68020' flag to GCC prevents building anything better, 46800ef0e59aSmrg # like '-m68040'. 46810ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' 46820ef0e59aSmrg ;; 46830ef0e59aSmrg esac 46840ef0e59aSmrg ;; 46850ef0e59aSmrg 46860ef0e59aSmrg beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) 46870ef0e59aSmrg # PIC is the default for these OSes. 46880ef0e59aSmrg ;; 46890ef0e59aSmrg 4690d5e6aabbSmrg mingw* | windows* | cygwin* | pw32* | os2* | cegcc*) 46910ef0e59aSmrg # This hack is so that the source file can tell whether it is being 46920ef0e59aSmrg # built for inclusion in a dll (and should export symbols for example). 46930ef0e59aSmrg # Although the cygwin gcc ignores -fPIC, still need this for old-style 46940ef0e59aSmrg # (--disable-auto-import) libraries 46950ef0e59aSmrg m4_if([$1], [GCJ], [], 46960ef0e59aSmrg [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) 46970ef0e59aSmrg case $host_os in 46980ef0e59aSmrg os2*) 46990ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static' 47000ef0e59aSmrg ;; 47010ef0e59aSmrg esac 47020ef0e59aSmrg ;; 47030ef0e59aSmrg 47040ef0e59aSmrg darwin* | rhapsody*) 47050ef0e59aSmrg # PIC is the default on this platform 47060ef0e59aSmrg # Common symbols not allowed in MH_DYLIB files 47070ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' 47080ef0e59aSmrg ;; 47090ef0e59aSmrg 47100ef0e59aSmrg haiku*) 47110ef0e59aSmrg # PIC is the default for Haiku. 47120ef0e59aSmrg # The "-static" flag exists, but is broken. 47130ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)= 47140ef0e59aSmrg ;; 47150ef0e59aSmrg 47160ef0e59aSmrg hpux*) 47170ef0e59aSmrg # PIC is the default for 64-bit PA HP-UX, but not for 32-bit 47180ef0e59aSmrg # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag 47190ef0e59aSmrg # sets the default TLS model and affects inlining. 47200ef0e59aSmrg case $host_cpu in 47210ef0e59aSmrg hppa*64*) 47220ef0e59aSmrg # +Z the default 47230ef0e59aSmrg ;; 47240ef0e59aSmrg *) 47250ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 47260ef0e59aSmrg ;; 47270ef0e59aSmrg esac 47280ef0e59aSmrg ;; 47290ef0e59aSmrg 47300ef0e59aSmrg interix[[3-9]]*) 47310ef0e59aSmrg # Interix 3.x gcc -fpic/-fPIC options generate broken code. 47320ef0e59aSmrg # Instead, we relocate shared libraries at runtime. 47330ef0e59aSmrg ;; 47340ef0e59aSmrg 47350ef0e59aSmrg msdosdjgpp*) 47360ef0e59aSmrg # Just because we use GCC doesn't mean we suddenly get shared libraries 47370ef0e59aSmrg # on systems that don't support them. 47380ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 47390ef0e59aSmrg enable_shared=no 47400ef0e59aSmrg ;; 47410ef0e59aSmrg 47420ef0e59aSmrg *nto* | *qnx*) 47430ef0e59aSmrg # QNX uses GNU C++, but need to define -shared option too, otherwise 47440ef0e59aSmrg # it will coredump. 47450ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' 47460ef0e59aSmrg ;; 47470ef0e59aSmrg 47480ef0e59aSmrg sysv4*MP*) 47490ef0e59aSmrg if test -d /usr/nec; then 47500ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic 47510ef0e59aSmrg fi 47520ef0e59aSmrg ;; 47530ef0e59aSmrg 47540ef0e59aSmrg *) 47550ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 47560ef0e59aSmrg ;; 47570ef0e59aSmrg esac 47580ef0e59aSmrg 47590ef0e59aSmrg case $cc_basename in 47600ef0e59aSmrg nvcc*) # Cuda Compiler Driver 2.2 47610ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Xlinker ' 47620ef0e59aSmrg if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then 47630ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)="-Xcompiler $_LT_TAGVAR(lt_prog_compiler_pic, $1)" 47640ef0e59aSmrg fi 47650ef0e59aSmrg ;; 47660ef0e59aSmrg esac 47670ef0e59aSmrg else 47680ef0e59aSmrg # PORTME Check for flag to pass linker flags through the system compiler. 47690ef0e59aSmrg case $host_os in 47700ef0e59aSmrg aix*) 47710ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 47720ef0e59aSmrg if test ia64 = "$host_cpu"; then 47730ef0e59aSmrg # AIX 5 now supports IA64 processor 47740ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 47750ef0e59aSmrg else 47760ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' 47770ef0e59aSmrg fi 47780ef0e59aSmrg ;; 47790ef0e59aSmrg 47800ef0e59aSmrg darwin* | rhapsody*) 47810ef0e59aSmrg # PIC is the default on this platform 47820ef0e59aSmrg # Common symbols not allowed in MH_DYLIB files 47830ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' 47840ef0e59aSmrg case $cc_basename in 47850ef0e59aSmrg nagfor*) 47860ef0e59aSmrg # NAG Fortran compiler 47870ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,' 47880ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' 47890ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 47900ef0e59aSmrg ;; 47910ef0e59aSmrg esac 47920ef0e59aSmrg ;; 47930ef0e59aSmrg 4794d5e6aabbSmrg mingw* | windows* | cygwin* | pw32* | os2* | cegcc*) 47950ef0e59aSmrg # This hack is so that the source file can tell whether it is being 47960ef0e59aSmrg # built for inclusion in a dll (and should export symbols for example). 47970ef0e59aSmrg m4_if([$1], [GCJ], [], 47980ef0e59aSmrg [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) 47990ef0e59aSmrg case $host_os in 48000ef0e59aSmrg os2*) 48010ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static' 48020ef0e59aSmrg ;; 48030ef0e59aSmrg esac 48040ef0e59aSmrg ;; 48050ef0e59aSmrg 48060ef0e59aSmrg hpux9* | hpux10* | hpux11*) 48070ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 48080ef0e59aSmrg # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but 48090ef0e59aSmrg # not for PA HP-UX. 48100ef0e59aSmrg case $host_cpu in 48110ef0e59aSmrg hppa*64*|ia64*) 48120ef0e59aSmrg # +Z the default 48130ef0e59aSmrg ;; 48140ef0e59aSmrg *) 48150ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' 48160ef0e59aSmrg ;; 48170ef0e59aSmrg esac 48180ef0e59aSmrg # Is there a better lt_prog_compiler_static that works with the bundled CC? 48190ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive' 48200ef0e59aSmrg ;; 48210ef0e59aSmrg 48220ef0e59aSmrg irix5* | irix6* | nonstopux*) 48230ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 48240ef0e59aSmrg # PIC (with -KPIC) is the default. 48250ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 48260ef0e59aSmrg ;; 48270ef0e59aSmrg 48280ef0e59aSmrg linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) 48290ef0e59aSmrg case $cc_basename in 48300ef0e59aSmrg # old Intel for x86_64, which still supported -KPIC. 48310ef0e59aSmrg ecc*) 48320ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 48330ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 48340ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 48350ef0e59aSmrg ;; 4836d5e6aabbSmrg *flang* | ftn | f18* | f95*) 4837d5e6aabbSmrg # Flang compiler. 4838d5e6aabbSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4839d5e6aabbSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 4840d5e6aabbSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 4841d5e6aabbSmrg ;; 48420ef0e59aSmrg # icc used to be incompatible with GCC. 48430ef0e59aSmrg # ICC 10 doesn't accept -KPIC any more. 48440ef0e59aSmrg icc* | ifort*) 48450ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 48460ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 48470ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 48480ef0e59aSmrg ;; 48490ef0e59aSmrg # Lahey Fortran 8.1. 48500ef0e59aSmrg lf95*) 48510ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 48520ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='--shared' 48530ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='--static' 48540ef0e59aSmrg ;; 48550ef0e59aSmrg nagfor*) 48560ef0e59aSmrg # NAG Fortran compiler 48570ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,' 48580ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' 48590ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 48600ef0e59aSmrg ;; 48610ef0e59aSmrg tcc*) 48620ef0e59aSmrg # Fabrice Bellard et al's Tiny C Compiler 48630ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 48640ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 48650ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 48660ef0e59aSmrg ;; 48670ef0e59aSmrg pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) 48680ef0e59aSmrg # Portland Group compilers (*not* the Pentium gcc compiler, 48690ef0e59aSmrg # which looks to be a dead project) 48700ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 48710ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' 48720ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 48730ef0e59aSmrg ;; 48740ef0e59aSmrg ccc*) 48750ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 48760ef0e59aSmrg # All Alpha code is PIC. 48770ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 48780ef0e59aSmrg ;; 48790ef0e59aSmrg xl* | bgxl* | bgf* | mpixl*) 48800ef0e59aSmrg # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene 48810ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 48820ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' 48830ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' 48840ef0e59aSmrg ;; 48850ef0e59aSmrg *) 488615885c33Smrg case `$CC -V 2>&1 | $SED 5q` in 48870ef0e59aSmrg *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [[1-7]].* | *Sun*Fortran*\ 8.[[0-3]]*) 48880ef0e59aSmrg # Sun Fortran 8.3 passes all unrecognized flags to the linker 48890ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 48900ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 48910ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='' 48920ef0e59aSmrg ;; 48930ef0e59aSmrg *Sun\ F* | *Sun*Fortran*) 48940ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 48950ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 48960ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' 48970ef0e59aSmrg ;; 48980ef0e59aSmrg *Sun\ C*) 48990ef0e59aSmrg # Sun C 5.9 49000ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 49010ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 49020ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 49030ef0e59aSmrg ;; 49040ef0e59aSmrg *Intel*\ [[CF]]*Compiler*) 49050ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 49060ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 49070ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 49080ef0e59aSmrg ;; 49090ef0e59aSmrg *Portland\ Group*) 49100ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 49110ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' 49120ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 49130ef0e59aSmrg ;; 49140ef0e59aSmrg esac 49150ef0e59aSmrg ;; 49160ef0e59aSmrg esac 49170ef0e59aSmrg ;; 49180ef0e59aSmrg 49190ef0e59aSmrg newsos6) 49200ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 49210ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 49220ef0e59aSmrg ;; 49230ef0e59aSmrg 4924d5e6aabbSmrg *-mlibc) 4925d5e6aabbSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 4926d5e6aabbSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 4927d5e6aabbSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 4928d5e6aabbSmrg ;; 4929d5e6aabbSmrg 49300ef0e59aSmrg *nto* | *qnx*) 49310ef0e59aSmrg # QNX uses GNU C++, but need to define -shared option too, otherwise 49320ef0e59aSmrg # it will coredump. 49330ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' 49340ef0e59aSmrg ;; 49350ef0e59aSmrg 49360ef0e59aSmrg osf3* | osf4* | osf5*) 49370ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 49380ef0e59aSmrg # All OSF/1 code is PIC. 49390ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 49400ef0e59aSmrg ;; 49410ef0e59aSmrg 49420ef0e59aSmrg rdos*) 49430ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 49440ef0e59aSmrg ;; 49450ef0e59aSmrg 4946d5e6aabbSmrg serenity*) 4947d5e6aabbSmrg ;; 4948d5e6aabbSmrg 49490ef0e59aSmrg solaris*) 49500ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 49510ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 49520ef0e59aSmrg case $cc_basename in 49530ef0e59aSmrg f77* | f90* | f95* | sunf77* | sunf90* | sunf95*) 49540ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';; 49550ef0e59aSmrg *) 49560ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';; 49570ef0e59aSmrg esac 49580ef0e59aSmrg ;; 49590ef0e59aSmrg 49600ef0e59aSmrg sunos4*) 49610ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' 49620ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' 49630ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 49640ef0e59aSmrg ;; 49650ef0e59aSmrg 49660ef0e59aSmrg sysv4 | sysv4.2uw2* | sysv4.3*) 49670ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 49680ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 49690ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 49700ef0e59aSmrg ;; 49710ef0e59aSmrg 49720ef0e59aSmrg sysv4*MP*) 49730ef0e59aSmrg if test -d /usr/nec; then 49740ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic' 49750ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 49760ef0e59aSmrg fi 49770ef0e59aSmrg ;; 49780ef0e59aSmrg 49790ef0e59aSmrg sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) 49800ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 49810ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 49820ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 49830ef0e59aSmrg ;; 49840ef0e59aSmrg 49850ef0e59aSmrg unicos*) 49860ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 49870ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 49880ef0e59aSmrg ;; 49890ef0e59aSmrg 49900ef0e59aSmrg uts4*) 49910ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 49920ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 49930ef0e59aSmrg ;; 49940ef0e59aSmrg 49950ef0e59aSmrg *) 49960ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 49970ef0e59aSmrg ;; 49980ef0e59aSmrg esac 49990ef0e59aSmrg fi 50000ef0e59aSmrg]) 50010ef0e59aSmrgcase $host_os in 50020ef0e59aSmrg # For platforms that do not support PIC, -DPIC is meaningless: 50030ef0e59aSmrg *djgpp*) 50040ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)= 50050ef0e59aSmrg ;; 50060ef0e59aSmrg *) 50070ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])" 50080ef0e59aSmrg ;; 50090ef0e59aSmrgesac 50100ef0e59aSmrg 50110ef0e59aSmrgAC_CACHE_CHECK([for $compiler option to produce PIC], 50120ef0e59aSmrg [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)], 50130ef0e59aSmrg [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_prog_compiler_pic, $1)]) 50140ef0e59aSmrg_LT_TAGVAR(lt_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_cv_prog_compiler_pic, $1) 50150ef0e59aSmrg 50160ef0e59aSmrg# 50170ef0e59aSmrg# Check to make sure the PIC flag actually works. 50180ef0e59aSmrg# 50190ef0e59aSmrgif test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then 50200ef0e59aSmrg _LT_COMPILER_OPTION([if $compiler PIC flag $_LT_TAGVAR(lt_prog_compiler_pic, $1) works], 50210ef0e59aSmrg [_LT_TAGVAR(lt_cv_prog_compiler_pic_works, $1)], 50220ef0e59aSmrg [$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])], [], 50230ef0e59aSmrg [case $_LT_TAGVAR(lt_prog_compiler_pic, $1) in 50240ef0e59aSmrg "" | " "*) ;; 50250ef0e59aSmrg *) _LT_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_TAGVAR(lt_prog_compiler_pic, $1)" ;; 50260ef0e59aSmrg esac], 50270ef0e59aSmrg [_LT_TAGVAR(lt_prog_compiler_pic, $1)= 50280ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no]) 50290ef0e59aSmrgfi 50300ef0e59aSmrg_LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1], 50310ef0e59aSmrg [Additional compiler flags for building library objects]) 50320ef0e59aSmrg 50330ef0e59aSmrg_LT_TAGDECL([wl], [lt_prog_compiler_wl], [1], 50340ef0e59aSmrg [How to pass a linker flag through the compiler]) 50350ef0e59aSmrg# 50360ef0e59aSmrg# Check to make sure the static flag actually works. 50370ef0e59aSmrg# 50380ef0e59aSmrgwl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_TAGVAR(lt_prog_compiler_static, $1)\" 50390ef0e59aSmrg_LT_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works], 50400ef0e59aSmrg _LT_TAGVAR(lt_cv_prog_compiler_static_works, $1), 50410ef0e59aSmrg $lt_tmp_static_flag, 50420ef0e59aSmrg [], 50430ef0e59aSmrg [_LT_TAGVAR(lt_prog_compiler_static, $1)=]) 50440ef0e59aSmrg_LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1], 50450ef0e59aSmrg [Compiler flag to prevent dynamic linking]) 50460ef0e59aSmrg])# _LT_COMPILER_PIC 50470ef0e59aSmrg 50480ef0e59aSmrg 50490ef0e59aSmrg# _LT_LINKER_SHLIBS([TAGNAME]) 50500ef0e59aSmrg# ---------------------------- 50510ef0e59aSmrg# See if the linker supports building shared libraries. 50520ef0e59aSmrgm4_defun([_LT_LINKER_SHLIBS], 50530ef0e59aSmrg[AC_REQUIRE([LT_PATH_LD])dnl 50540ef0e59aSmrgAC_REQUIRE([LT_PATH_NM])dnl 50550ef0e59aSmrgm4_require([_LT_PATH_MANIFEST_TOOL])dnl 50560ef0e59aSmrgm4_require([_LT_FILEUTILS_DEFAULTS])dnl 50570ef0e59aSmrgm4_require([_LT_DECL_EGREP])dnl 50580ef0e59aSmrgm4_require([_LT_DECL_SED])dnl 50590ef0e59aSmrgm4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl 50600ef0e59aSmrgm4_require([_LT_TAG_COMPILER])dnl 50610ef0e59aSmrgAC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) 50620ef0e59aSmrgm4_if([$1], [CXX], [ 50630ef0e59aSmrg _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' 50640ef0e59aSmrg _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] 50650ef0e59aSmrg case $host_os in 50660ef0e59aSmrg aix[[4-9]]*) 50670ef0e59aSmrg # If we're using GNU nm, then we don't want the "-C" option. 50680ef0e59aSmrg # -C means demangle to GNU nm, but means don't demangle to AIX nm. 50690ef0e59aSmrg # Without the "-l" option, or with the "-B" option, AIX nm treats 50700ef0e59aSmrg # weak defined symbols like other global defined symbols, whereas 50710ef0e59aSmrg # GNU nm marks them as "W". 50720ef0e59aSmrg # While the 'weak' keyword is ignored in the Export File, we need 50730ef0e59aSmrg # it in the Import File for the 'aix-soname' feature, so we have 50740ef0e59aSmrg # to replace the "-B" option with "-P" for AIX nm. 50750ef0e59aSmrg if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then 50760ef0e59aSmrg _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols' 50770ef0e59aSmrg else 507815885c33Smrg _LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "L") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' 50790ef0e59aSmrg fi 50800ef0e59aSmrg ;; 50810ef0e59aSmrg pw32*) 50820ef0e59aSmrg _LT_TAGVAR(export_symbols_cmds, $1)=$ltdll_cmds 50830ef0e59aSmrg ;; 5084d5e6aabbSmrg cygwin* | mingw* | windows* | cegcc*) 50850ef0e59aSmrg case $cc_basename in 508615885c33Smrg cl* | icl*) 50870ef0e59aSmrg _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' 50880ef0e59aSmrg ;; 50890ef0e59aSmrg *) 50900ef0e59aSmrg _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols' 50910ef0e59aSmrg _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'] 50920ef0e59aSmrg ;; 50930ef0e59aSmrg esac 50940ef0e59aSmrg ;; 50950ef0e59aSmrg *) 50960ef0e59aSmrg _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' 50970ef0e59aSmrg ;; 50980ef0e59aSmrg esac 50990ef0e59aSmrg], [ 51000ef0e59aSmrg runpath_var= 51010ef0e59aSmrg _LT_TAGVAR(allow_undefined_flag, $1)= 51020ef0e59aSmrg _LT_TAGVAR(always_export_symbols, $1)=no 51030ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)= 51040ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)= 51050ef0e59aSmrg _LT_TAGVAR(compiler_needs_object, $1)=no 51060ef0e59aSmrg _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no 51070ef0e59aSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)= 51080ef0e59aSmrg _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' 51090ef0e59aSmrg _LT_TAGVAR(hardcode_automatic, $1)=no 51100ef0e59aSmrg _LT_TAGVAR(hardcode_direct, $1)=no 51110ef0e59aSmrg _LT_TAGVAR(hardcode_direct_absolute, $1)=no 51120ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 51130ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)= 51140ef0e59aSmrg _LT_TAGVAR(hardcode_minus_L, $1)=no 51150ef0e59aSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported 51160ef0e59aSmrg _LT_TAGVAR(inherit_rpath, $1)=no 51170ef0e59aSmrg _LT_TAGVAR(link_all_deplibs, $1)=unknown 51180ef0e59aSmrg _LT_TAGVAR(module_cmds, $1)= 51190ef0e59aSmrg _LT_TAGVAR(module_expsym_cmds, $1)= 51200ef0e59aSmrg _LT_TAGVAR(old_archive_from_new_cmds, $1)= 51210ef0e59aSmrg _LT_TAGVAR(old_archive_from_expsyms_cmds, $1)= 51220ef0e59aSmrg _LT_TAGVAR(thread_safe_flag_spec, $1)= 51230ef0e59aSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)= 51240ef0e59aSmrg # include_expsyms should be a list of space-separated symbols to be *always* 51250ef0e59aSmrg # included in the symbol list 51260ef0e59aSmrg _LT_TAGVAR(include_expsyms, $1)= 51270ef0e59aSmrg # exclude_expsyms can be an extended regexp of symbols to exclude 51280ef0e59aSmrg # it will be wrapped by ' (' and ')$', so one must not match beginning or 51290ef0e59aSmrg # end of line. Example: 'a|bc|.*d.*' will exclude the symbols 'a' and 'bc', 51300ef0e59aSmrg # as well as any symbol that contains 'd'. 51310ef0e59aSmrg _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] 51320ef0e59aSmrg # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out 51330ef0e59aSmrg # platforms (ab)use it in PIC code, but their linkers get confused if 51340ef0e59aSmrg # the symbol is explicitly referenced. Since portable code cannot 51350ef0e59aSmrg # rely on this symbol name, it's probably fine to never include it in 51360ef0e59aSmrg # preloaded symbol tables. 51370ef0e59aSmrg # Exclude shared library initialization/finalization symbols. 51380ef0e59aSmrgdnl Note also adjust exclude_expsyms for C++ above. 51390ef0e59aSmrg extract_expsyms_cmds= 51400ef0e59aSmrg 51410ef0e59aSmrg case $host_os in 5142d5e6aabbSmrg cygwin* | mingw* | windows* | pw32* | cegcc*) 514315885c33Smrg # FIXME: the MSVC++ and ICC port hasn't been tested in a loooong time 51440ef0e59aSmrg # When not using gcc, we currently assume that we are using 514515885c33Smrg # Microsoft Visual C++ or Intel C++ Compiler. 51460ef0e59aSmrg if test yes != "$GCC"; then 51470ef0e59aSmrg with_gnu_ld=no 51480ef0e59aSmrg fi 51490ef0e59aSmrg ;; 51500ef0e59aSmrg interix*) 515115885c33Smrg # we just hope/assume this is gcc and not c89 (= MSVC++ or ICC) 51520ef0e59aSmrg with_gnu_ld=yes 51530ef0e59aSmrg ;; 51540ef0e59aSmrg esac 51550ef0e59aSmrg 51560ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=yes 51570ef0e59aSmrg 51580ef0e59aSmrg # On some targets, GNU ld is compatible enough with the native linker 51590ef0e59aSmrg # that we're better off using the native interface for both. 51600ef0e59aSmrg lt_use_gnu_ld_interface=no 51610ef0e59aSmrg if test yes = "$with_gnu_ld"; then 51620ef0e59aSmrg case $host_os in 51630ef0e59aSmrg aix*) 51640ef0e59aSmrg # The AIX port of GNU ld has always aspired to compatibility 51650ef0e59aSmrg # with the native linker. However, as the warning in the GNU ld 51660ef0e59aSmrg # block says, versions before 2.19.5* couldn't really create working 51670ef0e59aSmrg # shared libraries, regardless of the interface used. 51680ef0e59aSmrg case `$LD -v 2>&1` in 51690ef0e59aSmrg *\ \(GNU\ Binutils\)\ 2.19.5*) ;; 51700ef0e59aSmrg *\ \(GNU\ Binutils\)\ 2.[[2-9]]*) ;; 51710ef0e59aSmrg *\ \(GNU\ Binutils\)\ [[3-9]]*) ;; 51720ef0e59aSmrg *) 51730ef0e59aSmrg lt_use_gnu_ld_interface=yes 51740ef0e59aSmrg ;; 51750ef0e59aSmrg esac 51760ef0e59aSmrg ;; 51770ef0e59aSmrg *) 51780ef0e59aSmrg lt_use_gnu_ld_interface=yes 51790ef0e59aSmrg ;; 51800ef0e59aSmrg esac 51810ef0e59aSmrg fi 51820ef0e59aSmrg 51830ef0e59aSmrg if test yes = "$lt_use_gnu_ld_interface"; then 51840ef0e59aSmrg # If archive_cmds runs LD, not CC, wlarc should be empty 51850ef0e59aSmrg wlarc='$wl' 51860ef0e59aSmrg 51870ef0e59aSmrg # Set some defaults for GNU ld with shared library support. These 51880ef0e59aSmrg # are reset later if shared libraries are not supported. Putting them 51890ef0e59aSmrg # here allows them to be overridden if necessary. 51900ef0e59aSmrg runpath_var=LD_RUN_PATH 51910ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' 51920ef0e59aSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' 51930ef0e59aSmrg # ancient GNU ld didn't support --whole-archive et. al. 51940ef0e59aSmrg if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then 51950ef0e59aSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' 51960ef0e59aSmrg else 51970ef0e59aSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)= 51980ef0e59aSmrg fi 51990ef0e59aSmrg supports_anon_versioning=no 520015885c33Smrg case `$LD -v | $SED -e 's/([[^)]]\+)\s\+//' 2>&1` in 52010ef0e59aSmrg *GNU\ gold*) supports_anon_versioning=yes ;; 52020ef0e59aSmrg *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11 52030ef0e59aSmrg *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... 52040ef0e59aSmrg *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... 52050ef0e59aSmrg *\ 2.11.*) ;; # other 2.11 versions 52060ef0e59aSmrg *) supports_anon_versioning=yes ;; 52070ef0e59aSmrg esac 52080ef0e59aSmrg 52090ef0e59aSmrg # See if GNU ld supports shared libraries. 52100ef0e59aSmrg case $host_os in 52110ef0e59aSmrg aix[[3-9]]*) 52120ef0e59aSmrg # On AIX/PPC, the GNU linker is very broken 52130ef0e59aSmrg if test ia64 != "$host_cpu"; then 52140ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=no 52150ef0e59aSmrg cat <<_LT_EOF 1>&2 52160ef0e59aSmrg 52170ef0e59aSmrg*** Warning: the GNU linker, at least up to release 2.19, is reported 52180ef0e59aSmrg*** to be unable to reliably create shared libraries on AIX. 52190ef0e59aSmrg*** Therefore, libtool is disabling shared libraries support. If you 52200ef0e59aSmrg*** really care for shared libraries, you may want to install binutils 52210ef0e59aSmrg*** 2.20 or above, or modify your PATH so that a non-GNU linker is found. 52220ef0e59aSmrg*** You will then need to restart the configuration process. 52230ef0e59aSmrg 52240ef0e59aSmrg_LT_EOF 52250ef0e59aSmrg fi 52260ef0e59aSmrg ;; 52270ef0e59aSmrg 52280ef0e59aSmrg amigaos*) 52290ef0e59aSmrg case $host_cpu in 52300ef0e59aSmrg powerpc) 52310ef0e59aSmrg # see comment about AmigaOS4 .so support 52320ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' 52330ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='' 52340ef0e59aSmrg ;; 52350ef0e59aSmrg m68k) 52360ef0e59aSmrg _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)' 52370ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 52380ef0e59aSmrg _LT_TAGVAR(hardcode_minus_L, $1)=yes 52390ef0e59aSmrg ;; 52400ef0e59aSmrg esac 52410ef0e59aSmrg ;; 52420ef0e59aSmrg 52430ef0e59aSmrg beos*) 52440ef0e59aSmrg if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 52450ef0e59aSmrg _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 52460ef0e59aSmrg # Joseph Beckenbach <jrb3@best.com> says some releases of gcc 52470ef0e59aSmrg # support --undefined. This deserves some investigation. FIXME 52480ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' 52490ef0e59aSmrg else 52500ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=no 52510ef0e59aSmrg fi 52520ef0e59aSmrg ;; 52530ef0e59aSmrg 5254d5e6aabbSmrg cygwin* | mingw* | windows* | pw32* | cegcc*) 52550ef0e59aSmrg # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, 52560ef0e59aSmrg # as there is no search path for DLLs. 52570ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 52580ef0e59aSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-all-symbols' 52590ef0e59aSmrg _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 52600ef0e59aSmrg _LT_TAGVAR(always_export_symbols, $1)=no 52610ef0e59aSmrg _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 52620ef0e59aSmrg _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols' 52630ef0e59aSmrg _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'] 5264d5e6aabbSmrg _LT_TAGVAR(file_list_spec, $1)='@' 52650ef0e59aSmrg 52660ef0e59aSmrg if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then 52670ef0e59aSmrg _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' 52680ef0e59aSmrg # If the export-symbols file already is a .def file, use it as 52690ef0e59aSmrg # is; otherwise, prepend EXPORTS... 52700ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then 52710ef0e59aSmrg cp $export_symbols $output_objdir/$soname.def; 52720ef0e59aSmrg else 52730ef0e59aSmrg echo EXPORTS > $output_objdir/$soname.def; 52740ef0e59aSmrg cat $export_symbols >> $output_objdir/$soname.def; 52750ef0e59aSmrg fi~ 52760ef0e59aSmrg $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' 52770ef0e59aSmrg else 52780ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=no 52790ef0e59aSmrg fi 52800ef0e59aSmrg ;; 52810ef0e59aSmrg 52820ef0e59aSmrg haiku*) 52830ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' 5284d5e6aabbSmrg _LT_TAGVAR(link_all_deplibs, $1)=no 52850ef0e59aSmrg ;; 52860ef0e59aSmrg 52870ef0e59aSmrg os2*) 52880ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 52890ef0e59aSmrg _LT_TAGVAR(hardcode_minus_L, $1)=yes 52900ef0e59aSmrg _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 52910ef0e59aSmrg shrext_cmds=.dll 52920ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ 52930ef0e59aSmrg $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ 52940ef0e59aSmrg $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ 52950ef0e59aSmrg $ECHO EXPORTS >> $output_objdir/$libname.def~ 52960ef0e59aSmrg emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ 52970ef0e59aSmrg $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ 52980ef0e59aSmrg emximp -o $lib $output_objdir/$libname.def' 52990ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ 53000ef0e59aSmrg $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ 53010ef0e59aSmrg $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ 53020ef0e59aSmrg $ECHO EXPORTS >> $output_objdir/$libname.def~ 53030ef0e59aSmrg prefix_cmds="$SED"~ 53040ef0e59aSmrg if test EXPORTS = "`$SED 1q $export_symbols`"; then 53050ef0e59aSmrg prefix_cmds="$prefix_cmds -e 1d"; 53060ef0e59aSmrg fi~ 53070ef0e59aSmrg prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ 53080ef0e59aSmrg cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ 53090ef0e59aSmrg $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ 53100ef0e59aSmrg emximp -o $lib $output_objdir/$libname.def' 5311d5e6aabbSmrg _LT_TAGVAR(old_archive_from_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' 53120ef0e59aSmrg _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 531315885c33Smrg _LT_TAGVAR(file_list_spec, $1)='@' 53140ef0e59aSmrg ;; 53150ef0e59aSmrg 53160ef0e59aSmrg interix[[3-9]]*) 53170ef0e59aSmrg _LT_TAGVAR(hardcode_direct, $1)=no 53180ef0e59aSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 53190ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' 53200ef0e59aSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' 53210ef0e59aSmrg # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. 53220ef0e59aSmrg # Instead, shared libraries are loaded at an image base (0x10000000 by 53230ef0e59aSmrg # default) and relocated if they conflict, which is a slow very memory 53240ef0e59aSmrg # consuming and fragmenting process. To avoid this, we pick a random, 53250ef0e59aSmrg # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link 53260ef0e59aSmrg # time. Moving up from 0x10000000 also allows more sbrk(2) space. 53270ef0e59aSmrg _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' 532815885c33Smrg _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' 53290ef0e59aSmrg ;; 53300ef0e59aSmrg 53310ef0e59aSmrg gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) 53320ef0e59aSmrg tmp_diet=no 53330ef0e59aSmrg if test linux-dietlibc = "$host_os"; then 53340ef0e59aSmrg case $cc_basename in 53350ef0e59aSmrg diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn) 53360ef0e59aSmrg esac 53370ef0e59aSmrg fi 53380ef0e59aSmrg if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ 53390ef0e59aSmrg && test no = "$tmp_diet" 53400ef0e59aSmrg then 53410ef0e59aSmrg tmp_addflag=' $pic_flag' 53420ef0e59aSmrg tmp_sharedflag='-shared' 53430ef0e59aSmrg case $cc_basename,$host_cpu in 53440ef0e59aSmrg pgcc*) # Portland Group C compiler 53450ef0e59aSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' 53460ef0e59aSmrg tmp_addflag=' $pic_flag' 53470ef0e59aSmrg ;; 53480ef0e59aSmrg pgf77* | pgf90* | pgf95* | pgfortran*) 53490ef0e59aSmrg # Portland Group f77 and f90 compilers 53500ef0e59aSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' 53510ef0e59aSmrg tmp_addflag=' $pic_flag -Mnomain' ;; 53520ef0e59aSmrg ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 53530ef0e59aSmrg tmp_addflag=' -i_dynamic' ;; 53540ef0e59aSmrg efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 53550ef0e59aSmrg tmp_addflag=' -i_dynamic -nofor_main' ;; 53560ef0e59aSmrg ifc* | ifort*) # Intel Fortran compiler 53570ef0e59aSmrg tmp_addflag=' -nofor_main' ;; 53580ef0e59aSmrg lf95*) # Lahey Fortran 8.1 53590ef0e59aSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)= 53600ef0e59aSmrg tmp_sharedflag='--shared' ;; 53610ef0e59aSmrg nagfor*) # NAGFOR 5.3 53620ef0e59aSmrg tmp_sharedflag='-Wl,-shared' ;; 53630ef0e59aSmrg xl[[cC]]* | bgxl[[cC]]* | mpixl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below) 53640ef0e59aSmrg tmp_sharedflag='-qmkshrobj' 53650ef0e59aSmrg tmp_addflag= ;; 53660ef0e59aSmrg nvcc*) # Cuda Compiler Driver 2.2 53670ef0e59aSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' 53680ef0e59aSmrg _LT_TAGVAR(compiler_needs_object, $1)=yes 53690ef0e59aSmrg ;; 53700ef0e59aSmrg esac 537115885c33Smrg case `$CC -V 2>&1 | $SED 5q` in 53720ef0e59aSmrg *Sun\ C*) # Sun C 5.9 53730ef0e59aSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' 53740ef0e59aSmrg _LT_TAGVAR(compiler_needs_object, $1)=yes 53750ef0e59aSmrg tmp_sharedflag='-G' ;; 53760ef0e59aSmrg *Sun\ F*) # Sun Fortran 8.3 53770ef0e59aSmrg tmp_sharedflag='-G' ;; 53780ef0e59aSmrg esac 53790ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' 53800ef0e59aSmrg 53810ef0e59aSmrg if test yes = "$supports_anon_versioning"; then 53820ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ 538315885c33Smrg cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ 53840ef0e59aSmrg echo "local: *; };" >> $output_objdir/$libname.ver~ 53850ef0e59aSmrg $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib' 53860ef0e59aSmrg fi 53870ef0e59aSmrg 53880ef0e59aSmrg case $cc_basename in 53890ef0e59aSmrg tcc*) 5390d5e6aabbSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' 53910ef0e59aSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='-rdynamic' 53920ef0e59aSmrg ;; 53930ef0e59aSmrg xlf* | bgf* | bgxlf* | mpixlf*) 53940ef0e59aSmrg # IBM XL Fortran 10.1 on PPC cannot create shared libs itself 53950ef0e59aSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive' 53960ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' 53970ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib' 53980ef0e59aSmrg if test yes = "$supports_anon_versioning"; then 53990ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ 540015885c33Smrg cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ 54010ef0e59aSmrg echo "local: *; };" >> $output_objdir/$libname.ver~ 54020ef0e59aSmrg $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' 54030ef0e59aSmrg fi 54040ef0e59aSmrg ;; 54050ef0e59aSmrg esac 54060ef0e59aSmrg else 54070ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=no 54080ef0e59aSmrg fi 54090ef0e59aSmrg ;; 54100ef0e59aSmrg 5411d5e6aabbSmrg *-mlibc) 5412d5e6aabbSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' 5413d5e6aabbSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' 5414d5e6aabbSmrg ;; 5415d5e6aabbSmrg 5416d5e6aabbSmrg netbsd* | netbsdelf*-gnu) 54170ef0e59aSmrg if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then 54180ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' 54190ef0e59aSmrg wlarc= 54200ef0e59aSmrg else 54210ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' 54220ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' 54230ef0e59aSmrg fi 54240ef0e59aSmrg ;; 54250ef0e59aSmrg 54260ef0e59aSmrg solaris*) 54270ef0e59aSmrg if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then 54280ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=no 54290ef0e59aSmrg cat <<_LT_EOF 1>&2 54300ef0e59aSmrg 54310ef0e59aSmrg*** Warning: The releases 2.8.* of the GNU linker cannot reliably 54320ef0e59aSmrg*** create shared libraries on Solaris systems. Therefore, libtool 54330ef0e59aSmrg*** is disabling shared libraries support. We urge you to upgrade GNU 54340ef0e59aSmrg*** binutils to release 2.9.1 or newer. Another option is to modify 54350ef0e59aSmrg*** your PATH or compiler configuration so that the native linker is 54360ef0e59aSmrg*** used, and then restart. 54370ef0e59aSmrg 54380ef0e59aSmrg_LT_EOF 54390ef0e59aSmrg elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 54400ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' 54410ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' 54420ef0e59aSmrg else 54430ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=no 54440ef0e59aSmrg fi 54450ef0e59aSmrg ;; 54460ef0e59aSmrg 54470ef0e59aSmrg sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) 54480ef0e59aSmrg case `$LD -v 2>&1` in 54490ef0e59aSmrg *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*) 54500ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=no 54510ef0e59aSmrg cat <<_LT_EOF 1>&2 54520ef0e59aSmrg 54530ef0e59aSmrg*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 cannot 54540ef0e59aSmrg*** reliably create shared libraries on SCO systems. Therefore, libtool 54550ef0e59aSmrg*** is disabling shared libraries support. We urge you to upgrade GNU 54560ef0e59aSmrg*** binutils to release 2.16.91.0.3 or newer. Another option is to modify 54570ef0e59aSmrg*** your PATH or compiler configuration so that the native linker is 54580ef0e59aSmrg*** used, and then restart. 54590ef0e59aSmrg 54600ef0e59aSmrg_LT_EOF 54610ef0e59aSmrg ;; 54620ef0e59aSmrg *) 54630ef0e59aSmrg # For security reasons, it is highly recommended that you always 54640ef0e59aSmrg # use absolute paths for naming shared libraries, and exclude the 54650ef0e59aSmrg # DT_RUNPATH tag from executables and libraries. But doing so 54660ef0e59aSmrg # requires that you compile everything twice, which is a pain. 54670ef0e59aSmrg if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 54680ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' 54690ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' 54700ef0e59aSmrg _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' 54710ef0e59aSmrg else 54720ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=no 54730ef0e59aSmrg fi 54740ef0e59aSmrg ;; 54750ef0e59aSmrg esac 54760ef0e59aSmrg ;; 54770ef0e59aSmrg 54780ef0e59aSmrg sunos4*) 54790ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' 54800ef0e59aSmrg wlarc= 54810ef0e59aSmrg _LT_TAGVAR(hardcode_direct, $1)=yes 54820ef0e59aSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 54830ef0e59aSmrg ;; 54840ef0e59aSmrg 54850ef0e59aSmrg *) 54860ef0e59aSmrg if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 54870ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' 54880ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' 54890ef0e59aSmrg else 54900ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=no 54910ef0e59aSmrg fi 54920ef0e59aSmrg ;; 54930ef0e59aSmrg esac 54940ef0e59aSmrg 54950ef0e59aSmrg if test no = "$_LT_TAGVAR(ld_shlibs, $1)"; then 54960ef0e59aSmrg runpath_var= 54970ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 54980ef0e59aSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)= 54990ef0e59aSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)= 55000ef0e59aSmrg fi 55010ef0e59aSmrg else 55020ef0e59aSmrg # PORTME fill in a description of your system's linker (not GNU ld) 55030ef0e59aSmrg case $host_os in 55040ef0e59aSmrg aix3*) 55050ef0e59aSmrg _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 55060ef0e59aSmrg _LT_TAGVAR(always_export_symbols, $1)=yes 55070ef0e59aSmrg _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' 55080ef0e59aSmrg # Note: this linker hardcodes the directories in LIBPATH if there 55090ef0e59aSmrg # are no directories specified by -L. 55100ef0e59aSmrg _LT_TAGVAR(hardcode_minus_L, $1)=yes 55110ef0e59aSmrg if test yes = "$GCC" && test -z "$lt_prog_compiler_static"; then 55120ef0e59aSmrg # Neither direct hardcoding nor static linking is supported with a 55130ef0e59aSmrg # broken collect2. 55140ef0e59aSmrg _LT_TAGVAR(hardcode_direct, $1)=unsupported 55150ef0e59aSmrg fi 55160ef0e59aSmrg ;; 55170ef0e59aSmrg 55180ef0e59aSmrg aix[[4-9]]*) 55190ef0e59aSmrg if test ia64 = "$host_cpu"; then 55200ef0e59aSmrg # On IA64, the linker does run time linking by default, so we don't 55210ef0e59aSmrg # have to do anything special. 55220ef0e59aSmrg aix_use_runtimelinking=no 55230ef0e59aSmrg exp_sym_flag='-Bexport' 55240ef0e59aSmrg no_entry_flag= 55250ef0e59aSmrg else 55260ef0e59aSmrg # If we're using GNU nm, then we don't want the "-C" option. 55270ef0e59aSmrg # -C means demangle to GNU nm, but means don't demangle to AIX nm. 55280ef0e59aSmrg # Without the "-l" option, or with the "-B" option, AIX nm treats 55290ef0e59aSmrg # weak defined symbols like other global defined symbols, whereas 55300ef0e59aSmrg # GNU nm marks them as "W". 55310ef0e59aSmrg # While the 'weak' keyword is ignored in the Export File, we need 55320ef0e59aSmrg # it in the Import File for the 'aix-soname' feature, so we have 55330ef0e59aSmrg # to replace the "-B" option with "-P" for AIX nm. 55340ef0e59aSmrg if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then 55350ef0e59aSmrg _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols' 55360ef0e59aSmrg else 553715885c33Smrg _LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "L") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' 55380ef0e59aSmrg fi 55390ef0e59aSmrg aix_use_runtimelinking=no 55400ef0e59aSmrg 55410ef0e59aSmrg # Test if we are trying to use run time linking or normal 55420ef0e59aSmrg # AIX style linking. If -brtl is somewhere in LDFLAGS, we 55430ef0e59aSmrg # have runtime linking enabled, and use it for executables. 55440ef0e59aSmrg # For shared libraries, we enable/disable runtime linking 55450ef0e59aSmrg # depending on the kind of the shared library created - 55460ef0e59aSmrg # when "with_aix_soname,aix_use_runtimelinking" is: 55470ef0e59aSmrg # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables 55480ef0e59aSmrg # "aix,yes" lib.so shared, rtl:yes, for executables 55490ef0e59aSmrg # lib.a static archive 55500ef0e59aSmrg # "both,no" lib.so.V(shr.o) shared, rtl:yes 55510ef0e59aSmrg # lib.a(lib.so.V) shared, rtl:no, for executables 55520ef0e59aSmrg # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables 55530ef0e59aSmrg # lib.a(lib.so.V) shared, rtl:no 55540ef0e59aSmrg # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables 55550ef0e59aSmrg # lib.a static archive 55560ef0e59aSmrg case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) 55570ef0e59aSmrg for ld_flag in $LDFLAGS; do 55580ef0e59aSmrg if (test x-brtl = "x$ld_flag" || test x-Wl,-brtl = "x$ld_flag"); then 55590ef0e59aSmrg aix_use_runtimelinking=yes 55600ef0e59aSmrg break 55610ef0e59aSmrg fi 55620ef0e59aSmrg done 55630ef0e59aSmrg if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then 55640ef0e59aSmrg # With aix-soname=svr4, we create the lib.so.V shared archives only, 55650ef0e59aSmrg # so we don't have lib.a shared libs to link our executables. 55660ef0e59aSmrg # We have to force runtime linking in this case. 55670ef0e59aSmrg aix_use_runtimelinking=yes 55680ef0e59aSmrg LDFLAGS="$LDFLAGS -Wl,-brtl" 55690ef0e59aSmrg fi 55700ef0e59aSmrg ;; 55710ef0e59aSmrg esac 55720ef0e59aSmrg 55730ef0e59aSmrg exp_sym_flag='-bexport' 55740ef0e59aSmrg no_entry_flag='-bnoentry' 55750ef0e59aSmrg fi 55760ef0e59aSmrg 55770ef0e59aSmrg # When large executables or shared objects are built, AIX ld can 55780ef0e59aSmrg # have problems creating the table of contents. If linking a library 55790ef0e59aSmrg # or program results in "error TOC overflow" add -mminimal-toc to 55800ef0e59aSmrg # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not 55810ef0e59aSmrg # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. 55820ef0e59aSmrg 55830ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='' 55840ef0e59aSmrg _LT_TAGVAR(hardcode_direct, $1)=yes 55850ef0e59aSmrg _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 55860ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)=':' 55870ef0e59aSmrg _LT_TAGVAR(link_all_deplibs, $1)=yes 55880ef0e59aSmrg _LT_TAGVAR(file_list_spec, $1)='$wl-f,' 55890ef0e59aSmrg case $with_aix_soname,$aix_use_runtimelinking in 55900ef0e59aSmrg aix,*) ;; # traditional, no import file 55910ef0e59aSmrg svr4,* | *,yes) # use import file 55920ef0e59aSmrg # The Import File defines what to hardcode. 55930ef0e59aSmrg _LT_TAGVAR(hardcode_direct, $1)=no 55940ef0e59aSmrg _LT_TAGVAR(hardcode_direct_absolute, $1)=no 55950ef0e59aSmrg ;; 55960ef0e59aSmrg esac 55970ef0e59aSmrg 55980ef0e59aSmrg if test yes = "$GCC"; then 55990ef0e59aSmrg case $host_os in aix4.[[012]]|aix4.[[012]].*) 56000ef0e59aSmrg # We only want to do this on AIX 4.2 and lower, the check 56010ef0e59aSmrg # below for broken collect2 doesn't work under 4.3+ 56020ef0e59aSmrg collect2name=`$CC -print-prog-name=collect2` 56030ef0e59aSmrg if test -f "$collect2name" && 56040ef0e59aSmrg strings "$collect2name" | $GREP resolve_lib_name >/dev/null 56050ef0e59aSmrg then 56060ef0e59aSmrg # We have reworked collect2 56070ef0e59aSmrg : 56080ef0e59aSmrg else 56090ef0e59aSmrg # We have old collect2 56100ef0e59aSmrg _LT_TAGVAR(hardcode_direct, $1)=unsupported 56110ef0e59aSmrg # It fails to find uninstalled libraries when the uninstalled 56120ef0e59aSmrg # path is not listed in the libpath. Setting hardcode_minus_L 56130ef0e59aSmrg # to unsupported forces relinking 56140ef0e59aSmrg _LT_TAGVAR(hardcode_minus_L, $1)=yes 56150ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 56160ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)= 56170ef0e59aSmrg fi 56180ef0e59aSmrg ;; 56190ef0e59aSmrg esac 56200ef0e59aSmrg shared_flag='-shared' 56210ef0e59aSmrg if test yes = "$aix_use_runtimelinking"; then 56220ef0e59aSmrg shared_flag="$shared_flag "'$wl-G' 56230ef0e59aSmrg fi 56240ef0e59aSmrg # Need to ensure runtime linking is disabled for the traditional 56250ef0e59aSmrg # shared library, or the linker may eventually find shared libraries 56260ef0e59aSmrg # /with/ Import File - we do not want to mix them. 56270ef0e59aSmrg shared_flag_aix='-shared' 56280ef0e59aSmrg shared_flag_svr4='-shared $wl-G' 56290ef0e59aSmrg else 56300ef0e59aSmrg # not using gcc 56310ef0e59aSmrg if test ia64 = "$host_cpu"; then 56320ef0e59aSmrg # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release 56330ef0e59aSmrg # chokes on -Wl,-G. The following line is correct: 56340ef0e59aSmrg shared_flag='-G' 56350ef0e59aSmrg else 56360ef0e59aSmrg if test yes = "$aix_use_runtimelinking"; then 56370ef0e59aSmrg shared_flag='$wl-G' 56380ef0e59aSmrg else 56390ef0e59aSmrg shared_flag='$wl-bM:SRE' 56400ef0e59aSmrg fi 56410ef0e59aSmrg shared_flag_aix='$wl-bM:SRE' 56420ef0e59aSmrg shared_flag_svr4='$wl-G' 56430ef0e59aSmrg fi 56440ef0e59aSmrg fi 56450ef0e59aSmrg 56460ef0e59aSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-bexpall' 56470ef0e59aSmrg # It seems that -bexpall does not export symbols beginning with 56480ef0e59aSmrg # underscore (_), so it is better to generate a list of symbols to export. 56490ef0e59aSmrg _LT_TAGVAR(always_export_symbols, $1)=yes 56500ef0e59aSmrg if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then 56510ef0e59aSmrg # Warning - without using the other runtime loading flags (-brtl), 56520ef0e59aSmrg # -berok will link without error, but may produce a broken library. 56530ef0e59aSmrg _LT_TAGVAR(allow_undefined_flag, $1)='-berok' 56540ef0e59aSmrg # Determine the default libpath from the value encoded in an 56550ef0e59aSmrg # empty executable. 56560ef0e59aSmrg _LT_SYS_MODULE_PATH_AIX([$1]) 56570ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" 56580ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag 56590ef0e59aSmrg else 56600ef0e59aSmrg if test ia64 = "$host_cpu"; then 56610ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $libdir:/usr/lib:/lib' 56620ef0e59aSmrg _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" 56630ef0e59aSmrg _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" 56640ef0e59aSmrg else 56650ef0e59aSmrg # Determine the default libpath from the value encoded in an 56660ef0e59aSmrg # empty executable. 56670ef0e59aSmrg _LT_SYS_MODULE_PATH_AIX([$1]) 56680ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" 56690ef0e59aSmrg # Warning - without using the other run time loading flags, 56700ef0e59aSmrg # -berok will link without error, but may produce a broken library. 56710ef0e59aSmrg _LT_TAGVAR(no_undefined_flag, $1)=' $wl-bernotok' 56720ef0e59aSmrg _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-berok' 56730ef0e59aSmrg if test yes = "$with_gnu_ld"; then 56740ef0e59aSmrg # We only use this code for GNU lds that support --whole-archive. 56750ef0e59aSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive' 56760ef0e59aSmrg else 56770ef0e59aSmrg # Exported symbols can be pulled into shared objects from archives 56780ef0e59aSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' 56790ef0e59aSmrg fi 56800ef0e59aSmrg _LT_TAGVAR(archive_cmds_need_lc, $1)=yes 56810ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d' 56820ef0e59aSmrg # -brtl affects multiple linker settings, -berok does not and is overridden later 56830ef0e59aSmrg compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([[, ]]\\)%-berok\\1%g"`' 56840ef0e59aSmrg if test svr4 != "$with_aix_soname"; then 56850ef0e59aSmrg # This is similar to how AIX traditionally builds its shared libraries. 56860ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname' 56870ef0e59aSmrg fi 56880ef0e59aSmrg if test aix != "$with_aix_soname"; then 56890ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp' 56900ef0e59aSmrg else 56910ef0e59aSmrg # used by -dlpreopen to get the symbols 56920ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$MV $output_objdir/$realname.d/$soname $output_objdir' 56930ef0e59aSmrg fi 56940ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$RM -r $output_objdir/$realname.d' 56950ef0e59aSmrg fi 56960ef0e59aSmrg fi 56970ef0e59aSmrg ;; 56980ef0e59aSmrg 56990ef0e59aSmrg amigaos*) 57000ef0e59aSmrg case $host_cpu in 57010ef0e59aSmrg powerpc) 57020ef0e59aSmrg # see comment about AmigaOS4 .so support 57030ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' 57040ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='' 57050ef0e59aSmrg ;; 57060ef0e59aSmrg m68k) 57070ef0e59aSmrg _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)' 57080ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 57090ef0e59aSmrg _LT_TAGVAR(hardcode_minus_L, $1)=yes 57100ef0e59aSmrg ;; 57110ef0e59aSmrg esac 57120ef0e59aSmrg ;; 57130ef0e59aSmrg 57140ef0e59aSmrg bsdi[[45]]*) 57150ef0e59aSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic 57160ef0e59aSmrg ;; 57170ef0e59aSmrg 5718d5e6aabbSmrg cygwin* | mingw* | windows* | pw32* | cegcc*) 57190ef0e59aSmrg # When not using gcc, we currently assume that we are using 572015885c33Smrg # Microsoft Visual C++ or Intel C++ Compiler. 57210ef0e59aSmrg # hardcode_libdir_flag_spec is actually meaningless, as there is 57220ef0e59aSmrg # no search path for DLLs. 57230ef0e59aSmrg case $cc_basename in 572415885c33Smrg cl* | icl*) 572515885c33Smrg # Native MSVC or ICC 57260ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' 57270ef0e59aSmrg _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 57280ef0e59aSmrg _LT_TAGVAR(always_export_symbols, $1)=yes 57290ef0e59aSmrg _LT_TAGVAR(file_list_spec, $1)='@' 57300ef0e59aSmrg # Tell ltmain to make .lib files, not .a files. 57310ef0e59aSmrg libext=lib 57320ef0e59aSmrg # Tell ltmain to make .dll files, not .so files. 57330ef0e59aSmrg shrext_cmds=.dll 57340ef0e59aSmrg # FIXME: Setting linknames here is a bad hack. 5735d5e6aabbSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -Fe$output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames=' 57360ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then 57370ef0e59aSmrg cp "$export_symbols" "$output_objdir/$soname.def"; 57380ef0e59aSmrg echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp"; 57390ef0e59aSmrg else 57400ef0e59aSmrg $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp; 57410ef0e59aSmrg fi~ 5742d5e6aabbSmrg $CC -Fe$tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ 57430ef0e59aSmrg linknames=' 57440ef0e59aSmrg # The linker will not automatically build a static lib if we build a DLL. 57450ef0e59aSmrg # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' 57460ef0e59aSmrg _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 57470ef0e59aSmrg _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' 57480ef0e59aSmrg _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' 57490ef0e59aSmrg # Don't use ranlib 57500ef0e59aSmrg _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib' 57510ef0e59aSmrg _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~ 57520ef0e59aSmrg lt_tool_outputfile="@TOOL_OUTPUT@"~ 57530ef0e59aSmrg case $lt_outputfile in 57540ef0e59aSmrg *.exe|*.EXE) ;; 57550ef0e59aSmrg *) 57560ef0e59aSmrg lt_outputfile=$lt_outputfile.exe 57570ef0e59aSmrg lt_tool_outputfile=$lt_tool_outputfile.exe 57580ef0e59aSmrg ;; 57590ef0e59aSmrg esac~ 57600ef0e59aSmrg if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then 57610ef0e59aSmrg $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; 57620ef0e59aSmrg $RM "$lt_outputfile.manifest"; 57630ef0e59aSmrg fi' 57640ef0e59aSmrg ;; 57650ef0e59aSmrg *) 576615885c33Smrg # Assume MSVC and ICC wrapper 57670ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' 57680ef0e59aSmrg _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 57690ef0e59aSmrg # Tell ltmain to make .lib files, not .a files. 57700ef0e59aSmrg libext=lib 57710ef0e59aSmrg # Tell ltmain to make .dll files, not .so files. 57720ef0e59aSmrg shrext_cmds=.dll 57730ef0e59aSmrg # FIXME: Setting linknames here is a bad hack. 57740ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames=' 57750ef0e59aSmrg # The linker will automatically build a .lib file if we build a DLL. 57760ef0e59aSmrg _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' 57770ef0e59aSmrg # FIXME: Should let the user specify the lib program. 57780ef0e59aSmrg _LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs' 57790ef0e59aSmrg _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 57800ef0e59aSmrg ;; 57810ef0e59aSmrg esac 57820ef0e59aSmrg ;; 57830ef0e59aSmrg 57840ef0e59aSmrg darwin* | rhapsody*) 57850ef0e59aSmrg _LT_DARWIN_LINKER_FEATURES($1) 57860ef0e59aSmrg ;; 57870ef0e59aSmrg 57880ef0e59aSmrg dgux*) 57890ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 57900ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 57910ef0e59aSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 57920ef0e59aSmrg ;; 57930ef0e59aSmrg 57940ef0e59aSmrg # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor 57950ef0e59aSmrg # support. Future versions do this automatically, but an explicit c++rt0.o 57960ef0e59aSmrg # does not break anything, and helps significantly (at the cost of a little 57970ef0e59aSmrg # extra space). 57980ef0e59aSmrg freebsd2.2*) 57990ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' 58000ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 58010ef0e59aSmrg _LT_TAGVAR(hardcode_direct, $1)=yes 58020ef0e59aSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 58030ef0e59aSmrg ;; 58040ef0e59aSmrg 58050ef0e59aSmrg # Unfortunately, older versions of FreeBSD 2 do not have this feature. 58060ef0e59aSmrg freebsd2.*) 58070ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' 58080ef0e59aSmrg _LT_TAGVAR(hardcode_direct, $1)=yes 58090ef0e59aSmrg _LT_TAGVAR(hardcode_minus_L, $1)=yes 58100ef0e59aSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 58110ef0e59aSmrg ;; 58120ef0e59aSmrg 58130ef0e59aSmrg # FreeBSD 3 and greater uses gcc -shared to do shared libraries. 581415885c33Smrg freebsd* | dragonfly* | midnightbsd*) 58150ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' 58160ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 58170ef0e59aSmrg _LT_TAGVAR(hardcode_direct, $1)=yes 58180ef0e59aSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 58190ef0e59aSmrg ;; 58200ef0e59aSmrg 58210ef0e59aSmrg hpux9*) 58220ef0e59aSmrg if test yes = "$GCC"; then 58230ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' 58240ef0e59aSmrg else 58250ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' 58260ef0e59aSmrg fi 58270ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' 58280ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)=: 58290ef0e59aSmrg _LT_TAGVAR(hardcode_direct, $1)=yes 58300ef0e59aSmrg 58310ef0e59aSmrg # hardcode_minus_L: Not really in the search PATH, 58320ef0e59aSmrg # but as the default location of the library. 58330ef0e59aSmrg _LT_TAGVAR(hardcode_minus_L, $1)=yes 58340ef0e59aSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' 58350ef0e59aSmrg ;; 58360ef0e59aSmrg 58370ef0e59aSmrg hpux10*) 58380ef0e59aSmrg if test yes,no = "$GCC,$with_gnu_ld"; then 58390ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' 58400ef0e59aSmrg else 58410ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' 58420ef0e59aSmrg fi 58430ef0e59aSmrg if test no = "$with_gnu_ld"; then 58440ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' 58450ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)=: 58460ef0e59aSmrg _LT_TAGVAR(hardcode_direct, $1)=yes 58470ef0e59aSmrg _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 58480ef0e59aSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' 58490ef0e59aSmrg # hardcode_minus_L: Not really in the search PATH, 58500ef0e59aSmrg # but as the default location of the library. 58510ef0e59aSmrg _LT_TAGVAR(hardcode_minus_L, $1)=yes 58520ef0e59aSmrg fi 58530ef0e59aSmrg ;; 58540ef0e59aSmrg 58550ef0e59aSmrg hpux11*) 58560ef0e59aSmrg if test yes,no = "$GCC,$with_gnu_ld"; then 58570ef0e59aSmrg case $host_cpu in 58580ef0e59aSmrg hppa*64*) 58590ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' 58600ef0e59aSmrg ;; 58610ef0e59aSmrg ia64*) 58620ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' 58630ef0e59aSmrg ;; 58640ef0e59aSmrg *) 58650ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' 58660ef0e59aSmrg ;; 58670ef0e59aSmrg esac 58680ef0e59aSmrg else 58690ef0e59aSmrg case $host_cpu in 58700ef0e59aSmrg hppa*64*) 58710ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' 58720ef0e59aSmrg ;; 58730ef0e59aSmrg ia64*) 58740ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' 58750ef0e59aSmrg ;; 58760ef0e59aSmrg *) 58770ef0e59aSmrg m4_if($1, [], [ 58780ef0e59aSmrg # Older versions of the 11.00 compiler do not understand -b yet 58790ef0e59aSmrg # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does) 58800ef0e59aSmrg _LT_LINKER_OPTION([if $CC understands -b], 58810ef0e59aSmrg _LT_TAGVAR(lt_cv_prog_compiler__b, $1), [-b], 58820ef0e59aSmrg [_LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'], 58830ef0e59aSmrg [_LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'])], 58840ef0e59aSmrg [_LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags']) 58850ef0e59aSmrg ;; 58860ef0e59aSmrg esac 58870ef0e59aSmrg fi 58880ef0e59aSmrg if test no = "$with_gnu_ld"; then 58890ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' 58900ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)=: 58910ef0e59aSmrg 58920ef0e59aSmrg case $host_cpu in 58930ef0e59aSmrg hppa*64*|ia64*) 58940ef0e59aSmrg _LT_TAGVAR(hardcode_direct, $1)=no 58950ef0e59aSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 58960ef0e59aSmrg ;; 58970ef0e59aSmrg *) 58980ef0e59aSmrg _LT_TAGVAR(hardcode_direct, $1)=yes 58990ef0e59aSmrg _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 59000ef0e59aSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' 59010ef0e59aSmrg 59020ef0e59aSmrg # hardcode_minus_L: Not really in the search PATH, 59030ef0e59aSmrg # but as the default location of the library. 59040ef0e59aSmrg _LT_TAGVAR(hardcode_minus_L, $1)=yes 59050ef0e59aSmrg ;; 59060ef0e59aSmrg esac 59070ef0e59aSmrg fi 59080ef0e59aSmrg ;; 59090ef0e59aSmrg 59100ef0e59aSmrg irix5* | irix6* | nonstopux*) 59110ef0e59aSmrg if test yes = "$GCC"; then 59120ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' 59130ef0e59aSmrg # Try to use the -exported_symbol ld option, if it does not 59140ef0e59aSmrg # work, assume that -exports_file does not work either and 59150ef0e59aSmrg # implicitly export all symbols. 59160ef0e59aSmrg # This should be the same for all languages, so no per-tag cache variable. 59170ef0e59aSmrg AC_CACHE_CHECK([whether the $host_os linker accepts -exported_symbol], 59180ef0e59aSmrg [lt_cv_irix_exported_symbol], 59190ef0e59aSmrg [save_LDFLAGS=$LDFLAGS 59200ef0e59aSmrg LDFLAGS="$LDFLAGS -shared $wl-exported_symbol ${wl}foo $wl-update_registry $wl/dev/null" 59210ef0e59aSmrg AC_LINK_IFELSE( 59220ef0e59aSmrg [AC_LANG_SOURCE( 59230ef0e59aSmrg [AC_LANG_CASE([C], [[int foo (void) { return 0; }]], 59240ef0e59aSmrg [C++], [[int foo (void) { return 0; }]], 59250ef0e59aSmrg [Fortran 77], [[ 59260ef0e59aSmrg subroutine foo 59270ef0e59aSmrg end]], 59280ef0e59aSmrg [Fortran], [[ 59290ef0e59aSmrg subroutine foo 59300ef0e59aSmrg end]])])], 59310ef0e59aSmrg [lt_cv_irix_exported_symbol=yes], 59320ef0e59aSmrg [lt_cv_irix_exported_symbol=no]) 59330ef0e59aSmrg LDFLAGS=$save_LDFLAGS]) 59340ef0e59aSmrg if test yes = "$lt_cv_irix_exported_symbol"; then 59350ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations $wl-exports_file $wl$export_symbols -o $lib' 59360ef0e59aSmrg fi 59370ef0e59aSmrg else 59380ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' 59390ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -exports_file $export_symbols -o $lib' 59400ef0e59aSmrg fi 59410ef0e59aSmrg _LT_TAGVAR(archive_cmds_need_lc, $1)='no' 59420ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' 59430ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)=: 59440ef0e59aSmrg _LT_TAGVAR(inherit_rpath, $1)=yes 59450ef0e59aSmrg _LT_TAGVAR(link_all_deplibs, $1)=yes 59460ef0e59aSmrg ;; 59470ef0e59aSmrg 59480ef0e59aSmrg linux*) 59490ef0e59aSmrg case $cc_basename in 59500ef0e59aSmrg tcc*) 59510ef0e59aSmrg # Fabrice Bellard et al's Tiny C Compiler 59520ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=yes 59530ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' 5954d5e6aabbSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' 59550ef0e59aSmrg ;; 59560ef0e59aSmrg esac 59570ef0e59aSmrg ;; 59580ef0e59aSmrg 5959d5e6aabbSmrg *-mlibc) 5960d5e6aabbSmrg ;; 5961d5e6aabbSmrg 5962d5e6aabbSmrg netbsd* | netbsdelf*-gnu) 59630ef0e59aSmrg if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then 59640ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out 59650ef0e59aSmrg else 59660ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF 59670ef0e59aSmrg fi 59680ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 59690ef0e59aSmrg _LT_TAGVAR(hardcode_direct, $1)=yes 59700ef0e59aSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 59710ef0e59aSmrg ;; 59720ef0e59aSmrg 59730ef0e59aSmrg newsos6) 59740ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 59750ef0e59aSmrg _LT_TAGVAR(hardcode_direct, $1)=yes 59760ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' 59770ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)=: 59780ef0e59aSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 59790ef0e59aSmrg ;; 59800ef0e59aSmrg 59810ef0e59aSmrg *nto* | *qnx*) 59820ef0e59aSmrg ;; 59830ef0e59aSmrg 5984d5e6aabbSmrg openbsd*) 59850ef0e59aSmrg if test -f /usr/libexec/ld.so; then 59860ef0e59aSmrg _LT_TAGVAR(hardcode_direct, $1)=yes 59870ef0e59aSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 59880ef0e59aSmrg _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 59890ef0e59aSmrg if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then 59900ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' 59910ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags $wl-retain-symbols-file,$export_symbols' 59920ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' 59930ef0e59aSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' 59940ef0e59aSmrg else 59950ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' 59960ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' 59970ef0e59aSmrg fi 59980ef0e59aSmrg else 59990ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=no 60000ef0e59aSmrg fi 60010ef0e59aSmrg ;; 60020ef0e59aSmrg 60030ef0e59aSmrg os2*) 60040ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 60050ef0e59aSmrg _LT_TAGVAR(hardcode_minus_L, $1)=yes 60060ef0e59aSmrg _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 60070ef0e59aSmrg shrext_cmds=.dll 60080ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ 60090ef0e59aSmrg $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ 60100ef0e59aSmrg $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ 60110ef0e59aSmrg $ECHO EXPORTS >> $output_objdir/$libname.def~ 60120ef0e59aSmrg emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ 60130ef0e59aSmrg $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ 60140ef0e59aSmrg emximp -o $lib $output_objdir/$libname.def' 60150ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ 60160ef0e59aSmrg $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ 60170ef0e59aSmrg $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ 60180ef0e59aSmrg $ECHO EXPORTS >> $output_objdir/$libname.def~ 60190ef0e59aSmrg prefix_cmds="$SED"~ 60200ef0e59aSmrg if test EXPORTS = "`$SED 1q $export_symbols`"; then 60210ef0e59aSmrg prefix_cmds="$prefix_cmds -e 1d"; 60220ef0e59aSmrg fi~ 60230ef0e59aSmrg prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ 60240ef0e59aSmrg cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ 60250ef0e59aSmrg $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ 60260ef0e59aSmrg emximp -o $lib $output_objdir/$libname.def' 6027d5e6aabbSmrg _LT_TAGVAR(old_archive_from_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' 60280ef0e59aSmrg _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 602915885c33Smrg _LT_TAGVAR(file_list_spec, $1)='@' 60300ef0e59aSmrg ;; 60310ef0e59aSmrg 60320ef0e59aSmrg osf3*) 60330ef0e59aSmrg if test yes = "$GCC"; then 60340ef0e59aSmrg _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' 60350ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' 60360ef0e59aSmrg else 60370ef0e59aSmrg _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' 60380ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' 60390ef0e59aSmrg fi 60400ef0e59aSmrg _LT_TAGVAR(archive_cmds_need_lc, $1)='no' 60410ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' 60420ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)=: 60430ef0e59aSmrg ;; 60440ef0e59aSmrg 60450ef0e59aSmrg osf4* | osf5*) # as osf3* with the addition of -msym flag 60460ef0e59aSmrg if test yes = "$GCC"; then 60470ef0e59aSmrg _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' 60480ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $pic_flag $libobjs $deplibs $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' 60490ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' 60500ef0e59aSmrg else 60510ef0e59aSmrg _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' 60520ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' 60530ef0e59aSmrg _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~ 60540ef0e59aSmrg $CC -shared$allow_undefined_flag $wl-input $wl$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~$RM $lib.exp' 60550ef0e59aSmrg 60560ef0e59aSmrg # Both c and cxx compiler support -rpath directly 60570ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' 60580ef0e59aSmrg fi 60590ef0e59aSmrg _LT_TAGVAR(archive_cmds_need_lc, $1)='no' 60600ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)=: 60610ef0e59aSmrg ;; 60620ef0e59aSmrg 6063d5e6aabbSmrg serenity*) 6064d5e6aabbSmrg ;; 6065d5e6aabbSmrg 60660ef0e59aSmrg solaris*) 60670ef0e59aSmrg _LT_TAGVAR(no_undefined_flag, $1)=' -z defs' 60680ef0e59aSmrg if test yes = "$GCC"; then 60690ef0e59aSmrg wlarc='$wl' 60700ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl-z ${wl}text $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' 60710ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 60720ef0e59aSmrg $CC -shared $pic_flag $wl-z ${wl}text $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' 60730ef0e59aSmrg else 60740ef0e59aSmrg case `$CC -V 2>&1` in 60750ef0e59aSmrg *"Compilers 5.0"*) 60760ef0e59aSmrg wlarc='' 60770ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$LD -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $linker_flags' 60780ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 60790ef0e59aSmrg $LD -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' 60800ef0e59aSmrg ;; 60810ef0e59aSmrg *) 60820ef0e59aSmrg wlarc='$wl' 60830ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $compiler_flags' 60840ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 60850ef0e59aSmrg $CC -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' 60860ef0e59aSmrg ;; 60870ef0e59aSmrg esac 60880ef0e59aSmrg fi 60890ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 60900ef0e59aSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 60910ef0e59aSmrg case $host_os in 60920ef0e59aSmrg solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; 60930ef0e59aSmrg *) 60940ef0e59aSmrg # The compiler driver will combine and reorder linker options, 60950ef0e59aSmrg # but understands '-z linker_flag'. GCC discards it without '$wl', 60960ef0e59aSmrg # but is careful enough not to reorder. 60970ef0e59aSmrg # Supported since Solaris 2.6 (maybe 2.5.1?) 60980ef0e59aSmrg if test yes = "$GCC"; then 60990ef0e59aSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract' 61000ef0e59aSmrg else 61010ef0e59aSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' 61020ef0e59aSmrg fi 61030ef0e59aSmrg ;; 61040ef0e59aSmrg esac 61050ef0e59aSmrg _LT_TAGVAR(link_all_deplibs, $1)=yes 61060ef0e59aSmrg ;; 61070ef0e59aSmrg 61080ef0e59aSmrg sunos4*) 61090ef0e59aSmrg if test sequent = "$host_vendor"; then 61100ef0e59aSmrg # Use $CC to link under sequent, because it throws in some extra .o 61110ef0e59aSmrg # files that make .init and .fini sections work. 61120ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h $soname -o $lib $libobjs $deplibs $compiler_flags' 61130ef0e59aSmrg else 61140ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' 61150ef0e59aSmrg fi 61160ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 61170ef0e59aSmrg _LT_TAGVAR(hardcode_direct, $1)=yes 61180ef0e59aSmrg _LT_TAGVAR(hardcode_minus_L, $1)=yes 61190ef0e59aSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 61200ef0e59aSmrg ;; 61210ef0e59aSmrg 61220ef0e59aSmrg sysv4) 61230ef0e59aSmrg case $host_vendor in 61240ef0e59aSmrg sni) 61250ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 61260ef0e59aSmrg _LT_TAGVAR(hardcode_direct, $1)=yes # is this really true??? 61270ef0e59aSmrg ;; 61280ef0e59aSmrg siemens) 61290ef0e59aSmrg ## LD is ld it makes a PLAMLIB 61300ef0e59aSmrg ## CC just makes a GrossModule. 61310ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags' 61320ef0e59aSmrg _LT_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs' 61330ef0e59aSmrg _LT_TAGVAR(hardcode_direct, $1)=no 61340ef0e59aSmrg ;; 61350ef0e59aSmrg motorola) 61360ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 61370ef0e59aSmrg _LT_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie 61380ef0e59aSmrg ;; 61390ef0e59aSmrg esac 61400ef0e59aSmrg runpath_var='LD_RUN_PATH' 61410ef0e59aSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 61420ef0e59aSmrg ;; 61430ef0e59aSmrg 61440ef0e59aSmrg sysv4.3*) 61450ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 61460ef0e59aSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 61470ef0e59aSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport' 61480ef0e59aSmrg ;; 61490ef0e59aSmrg 61500ef0e59aSmrg sysv4*MP*) 61510ef0e59aSmrg if test -d /usr/nec; then 61520ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 61530ef0e59aSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 61540ef0e59aSmrg runpath_var=LD_RUN_PATH 61550ef0e59aSmrg hardcode_runpath_var=yes 61560ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=yes 61570ef0e59aSmrg fi 61580ef0e59aSmrg ;; 61590ef0e59aSmrg 61600ef0e59aSmrg sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) 61610ef0e59aSmrg _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' 61620ef0e59aSmrg _LT_TAGVAR(archive_cmds_need_lc, $1)=no 61630ef0e59aSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 61640ef0e59aSmrg runpath_var='LD_RUN_PATH' 61650ef0e59aSmrg 61660ef0e59aSmrg if test yes = "$GCC"; then 61670ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 61680ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 61690ef0e59aSmrg else 61700ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 61710ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 61720ef0e59aSmrg fi 61730ef0e59aSmrg ;; 61740ef0e59aSmrg 61750ef0e59aSmrg sysv5* | sco3.2v5* | sco5v6*) 61760ef0e59aSmrg # Note: We CANNOT use -z defs as we might desire, because we do not 61770ef0e59aSmrg # link with -lc, and that would cause any symbols used from libc to 61780ef0e59aSmrg # always be unresolved, which means just about no library would 61790ef0e59aSmrg # ever link correctly. If we're not using GNU ld we use -z text 61800ef0e59aSmrg # though, which does catch some bad symbols but isn't as heavy-handed 61810ef0e59aSmrg # as -z defs. 61820ef0e59aSmrg _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' 61830ef0e59aSmrg _LT_TAGVAR(allow_undefined_flag, $1)='$wl-z,nodefs' 61840ef0e59aSmrg _LT_TAGVAR(archive_cmds_need_lc, $1)=no 61850ef0e59aSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 61860ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R,$libdir' 61870ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)=':' 61880ef0e59aSmrg _LT_TAGVAR(link_all_deplibs, $1)=yes 61890ef0e59aSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Bexport' 61900ef0e59aSmrg runpath_var='LD_RUN_PATH' 61910ef0e59aSmrg 61920ef0e59aSmrg if test yes = "$GCC"; then 61930ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 61940ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 61950ef0e59aSmrg else 61960ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 61970ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 61980ef0e59aSmrg fi 61990ef0e59aSmrg ;; 62000ef0e59aSmrg 62010ef0e59aSmrg uts4*) 62020ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 62030ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 62040ef0e59aSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 62050ef0e59aSmrg ;; 62060ef0e59aSmrg 62070ef0e59aSmrg *) 62080ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=no 62090ef0e59aSmrg ;; 62100ef0e59aSmrg esac 62110ef0e59aSmrg 62120ef0e59aSmrg if test sni = "$host_vendor"; then 62130ef0e59aSmrg case $host in 62140ef0e59aSmrg sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) 62150ef0e59aSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Blargedynsym' 62160ef0e59aSmrg ;; 62170ef0e59aSmrg esac 62180ef0e59aSmrg fi 62190ef0e59aSmrg fi 62200ef0e59aSmrg]) 62210ef0e59aSmrgAC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) 62220ef0e59aSmrgtest no = "$_LT_TAGVAR(ld_shlibs, $1)" && can_build_shared=no 62230ef0e59aSmrg 62240ef0e59aSmrg_LT_TAGVAR(with_gnu_ld, $1)=$with_gnu_ld 62250ef0e59aSmrg 62260ef0e59aSmrg_LT_DECL([], [libext], [0], [Old archive suffix (normally "a")])dnl 62270ef0e59aSmrg_LT_DECL([], [shrext_cmds], [1], [Shared library suffix (normally ".so")])dnl 62280ef0e59aSmrg_LT_DECL([], [extract_expsyms_cmds], [2], 62290ef0e59aSmrg [The commands to extract the exported symbol list from a shared archive]) 62300ef0e59aSmrg 62310ef0e59aSmrg# 62320ef0e59aSmrg# Do we need to explicitly link libc? 62330ef0e59aSmrg# 62340ef0e59aSmrgcase "x$_LT_TAGVAR(archive_cmds_need_lc, $1)" in 62350ef0e59aSmrgx|xyes) 62360ef0e59aSmrg # Assume -lc should be added 62370ef0e59aSmrg _LT_TAGVAR(archive_cmds_need_lc, $1)=yes 62380ef0e59aSmrg 62390ef0e59aSmrg if test yes,yes = "$GCC,$enable_shared"; then 62400ef0e59aSmrg case $_LT_TAGVAR(archive_cmds, $1) in 62410ef0e59aSmrg *'~'*) 62420ef0e59aSmrg # FIXME: we may have to deal with multi-command sequences. 62430ef0e59aSmrg ;; 62440ef0e59aSmrg '$CC '*) 62450ef0e59aSmrg # Test whether the compiler implicitly links with -lc since on some 62460ef0e59aSmrg # systems, -lgcc has to come before -lc. If gcc already passes -lc 62470ef0e59aSmrg # to ld, don't add -lc before -lgcc. 62480ef0e59aSmrg AC_CACHE_CHECK([whether -lc should be explicitly linked in], 62490ef0e59aSmrg [lt_cv_]_LT_TAGVAR(archive_cmds_need_lc, $1), 62500ef0e59aSmrg [$RM conftest* 62510ef0e59aSmrg echo "$lt_simple_compile_test_code" > conftest.$ac_ext 62520ef0e59aSmrg 62530ef0e59aSmrg if AC_TRY_EVAL(ac_compile) 2>conftest.err; then 62540ef0e59aSmrg soname=conftest 62550ef0e59aSmrg lib=conftest 62560ef0e59aSmrg libobjs=conftest.$ac_objext 62570ef0e59aSmrg deplibs= 62580ef0e59aSmrg wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) 62590ef0e59aSmrg pic_flag=$_LT_TAGVAR(lt_prog_compiler_pic, $1) 62600ef0e59aSmrg compiler_flags=-v 62610ef0e59aSmrg linker_flags=-v 62620ef0e59aSmrg verstring= 62630ef0e59aSmrg output_objdir=. 62640ef0e59aSmrg libname=conftest 62650ef0e59aSmrg lt_save_allow_undefined_flag=$_LT_TAGVAR(allow_undefined_flag, $1) 62660ef0e59aSmrg _LT_TAGVAR(allow_undefined_flag, $1)= 62670ef0e59aSmrg if AC_TRY_EVAL(_LT_TAGVAR(archive_cmds, $1) 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 62680ef0e59aSmrg then 62690ef0e59aSmrg lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=no 62700ef0e59aSmrg else 62710ef0e59aSmrg lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=yes 62720ef0e59aSmrg fi 62730ef0e59aSmrg _LT_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag 62740ef0e59aSmrg else 62750ef0e59aSmrg cat conftest.err 1>&5 62760ef0e59aSmrg fi 62770ef0e59aSmrg $RM conftest* 62780ef0e59aSmrg ]) 62790ef0e59aSmrg _LT_TAGVAR(archive_cmds_need_lc, $1)=$lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1) 62800ef0e59aSmrg ;; 62810ef0e59aSmrg esac 62820ef0e59aSmrg fi 62830ef0e59aSmrg ;; 62840ef0e59aSmrgesac 62850ef0e59aSmrg 62860ef0e59aSmrg_LT_TAGDECL([build_libtool_need_lc], [archive_cmds_need_lc], [0], 62870ef0e59aSmrg [Whether or not to add -lc for building shared libraries]) 62880ef0e59aSmrg_LT_TAGDECL([allow_libtool_libs_with_static_runtimes], 62890ef0e59aSmrg [enable_shared_with_static_runtimes], [0], 62900ef0e59aSmrg [Whether or not to disallow shared libs when runtime libs are static]) 62910ef0e59aSmrg_LT_TAGDECL([], [export_dynamic_flag_spec], [1], 62920ef0e59aSmrg [Compiler flag to allow reflexive dlopens]) 62930ef0e59aSmrg_LT_TAGDECL([], [whole_archive_flag_spec], [1], 62940ef0e59aSmrg [Compiler flag to generate shared objects directly from archives]) 62950ef0e59aSmrg_LT_TAGDECL([], [compiler_needs_object], [1], 62960ef0e59aSmrg [Whether the compiler copes with passing no objects directly]) 62970ef0e59aSmrg_LT_TAGDECL([], [old_archive_from_new_cmds], [2], 62980ef0e59aSmrg [Create an old-style archive from a shared archive]) 62990ef0e59aSmrg_LT_TAGDECL([], [old_archive_from_expsyms_cmds], [2], 63000ef0e59aSmrg [Create a temporary old-style archive to link instead of a shared archive]) 63010ef0e59aSmrg_LT_TAGDECL([], [archive_cmds], [2], [Commands used to build a shared archive]) 63020ef0e59aSmrg_LT_TAGDECL([], [archive_expsym_cmds], [2]) 63030ef0e59aSmrg_LT_TAGDECL([], [module_cmds], [2], 63040ef0e59aSmrg [Commands used to build a loadable module if different from building 63050ef0e59aSmrg a shared archive.]) 63060ef0e59aSmrg_LT_TAGDECL([], [module_expsym_cmds], [2]) 63070ef0e59aSmrg_LT_TAGDECL([], [with_gnu_ld], [1], 63080ef0e59aSmrg [Whether we are building with GNU ld or not]) 63090ef0e59aSmrg_LT_TAGDECL([], [allow_undefined_flag], [1], 63100ef0e59aSmrg [Flag that allows shared libraries with undefined symbols to be built]) 63110ef0e59aSmrg_LT_TAGDECL([], [no_undefined_flag], [1], 63120ef0e59aSmrg [Flag that enforces no undefined symbols]) 63130ef0e59aSmrg_LT_TAGDECL([], [hardcode_libdir_flag_spec], [1], 63140ef0e59aSmrg [Flag to hardcode $libdir into a binary during linking. 63150ef0e59aSmrg This must work even if $libdir does not exist]) 63160ef0e59aSmrg_LT_TAGDECL([], [hardcode_libdir_separator], [1], 63170ef0e59aSmrg [Whether we need a single "-rpath" flag with a separated argument]) 63180ef0e59aSmrg_LT_TAGDECL([], [hardcode_direct], [0], 63190ef0e59aSmrg [Set to "yes" if using DIR/libNAME$shared_ext during linking hardcodes 63200ef0e59aSmrg DIR into the resulting binary]) 63210ef0e59aSmrg_LT_TAGDECL([], [hardcode_direct_absolute], [0], 63220ef0e59aSmrg [Set to "yes" if using DIR/libNAME$shared_ext during linking hardcodes 63230ef0e59aSmrg DIR into the resulting binary and the resulting library dependency is 6324d5e6aabbSmrg "absolute", i.e. impossible to change by setting $shlibpath_var if the 63250ef0e59aSmrg library is relocated]) 63260ef0e59aSmrg_LT_TAGDECL([], [hardcode_minus_L], [0], 63270ef0e59aSmrg [Set to "yes" if using the -LDIR flag during linking hardcodes DIR 63280ef0e59aSmrg into the resulting binary]) 63290ef0e59aSmrg_LT_TAGDECL([], [hardcode_shlibpath_var], [0], 63300ef0e59aSmrg [Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR 63310ef0e59aSmrg into the resulting binary]) 63320ef0e59aSmrg_LT_TAGDECL([], [hardcode_automatic], [0], 63330ef0e59aSmrg [Set to "yes" if building a shared library automatically hardcodes DIR 63340ef0e59aSmrg into the library and all subsequent libraries and executables linked 63350ef0e59aSmrg against it]) 63360ef0e59aSmrg_LT_TAGDECL([], [inherit_rpath], [0], 63370ef0e59aSmrg [Set to yes if linker adds runtime paths of dependent libraries 63380ef0e59aSmrg to runtime path list]) 63390ef0e59aSmrg_LT_TAGDECL([], [link_all_deplibs], [0], 63400ef0e59aSmrg [Whether libtool must link a program against all its dependency libraries]) 63410ef0e59aSmrg_LT_TAGDECL([], [always_export_symbols], [0], 63420ef0e59aSmrg [Set to "yes" if exported symbols are required]) 63430ef0e59aSmrg_LT_TAGDECL([], [export_symbols_cmds], [2], 63440ef0e59aSmrg [The commands to list exported symbols]) 63450ef0e59aSmrg_LT_TAGDECL([], [exclude_expsyms], [1], 63460ef0e59aSmrg [Symbols that should not be listed in the preloaded symbols]) 63470ef0e59aSmrg_LT_TAGDECL([], [include_expsyms], [1], 63480ef0e59aSmrg [Symbols that must always be exported]) 63490ef0e59aSmrg_LT_TAGDECL([], [prelink_cmds], [2], 63500ef0e59aSmrg [Commands necessary for linking programs (against libraries) with templates]) 63510ef0e59aSmrg_LT_TAGDECL([], [postlink_cmds], [2], 63520ef0e59aSmrg [Commands necessary for finishing linking programs]) 63530ef0e59aSmrg_LT_TAGDECL([], [file_list_spec], [1], 63540ef0e59aSmrg [Specify filename containing input files]) 63550ef0e59aSmrgdnl FIXME: Not yet implemented 63560ef0e59aSmrgdnl _LT_TAGDECL([], [thread_safe_flag_spec], [1], 63570ef0e59aSmrgdnl [Compiler flag to generate thread safe objects]) 63580ef0e59aSmrg])# _LT_LINKER_SHLIBS 63590ef0e59aSmrg 63600ef0e59aSmrg 63610ef0e59aSmrg# _LT_LANG_C_CONFIG([TAG]) 63620ef0e59aSmrg# ------------------------ 63630ef0e59aSmrg# Ensure that the configuration variables for a C compiler are suitably 63640ef0e59aSmrg# defined. These variables are subsequently used by _LT_CONFIG to write 63650ef0e59aSmrg# the compiler configuration to 'libtool'. 63660ef0e59aSmrgm4_defun([_LT_LANG_C_CONFIG], 63670ef0e59aSmrg[m4_require([_LT_DECL_EGREP])dnl 63680ef0e59aSmrglt_save_CC=$CC 63690ef0e59aSmrgAC_LANG_PUSH(C) 63700ef0e59aSmrg 63710ef0e59aSmrg# Source file extension for C test sources. 63720ef0e59aSmrgac_ext=c 63730ef0e59aSmrg 63740ef0e59aSmrg# Object file extension for compiled C test sources. 63750ef0e59aSmrgobjext=o 63760ef0e59aSmrg_LT_TAGVAR(objext, $1)=$objext 63770ef0e59aSmrg 63780ef0e59aSmrg# Code to be used in simple compile tests 63790ef0e59aSmrglt_simple_compile_test_code="int some_variable = 0;" 63800ef0e59aSmrg 63810ef0e59aSmrg# Code to be used in simple link tests 6382d5e6aabbSmrglt_simple_link_test_code='int main(void){return(0);}' 63830ef0e59aSmrg 63840ef0e59aSmrg_LT_TAG_COMPILER 63850ef0e59aSmrg# Save the default compiler, since it gets overwritten when the other 63860ef0e59aSmrg# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP. 63870ef0e59aSmrgcompiler_DEFAULT=$CC 63880ef0e59aSmrg 63890ef0e59aSmrg# save warnings/boilerplate of simple test code 63900ef0e59aSmrg_LT_COMPILER_BOILERPLATE 63910ef0e59aSmrg_LT_LINKER_BOILERPLATE 63920ef0e59aSmrg 63930ef0e59aSmrg## CAVEAT EMPTOR: 63940ef0e59aSmrg## There is no encapsulation within the following macros, do not change 63950ef0e59aSmrg## the running order or otherwise move them around unless you know exactly 63960ef0e59aSmrg## what you are doing... 63970ef0e59aSmrgif test -n "$compiler"; then 63980ef0e59aSmrg _LT_COMPILER_NO_RTTI($1) 63990ef0e59aSmrg _LT_COMPILER_PIC($1) 64000ef0e59aSmrg _LT_COMPILER_C_O($1) 64010ef0e59aSmrg _LT_COMPILER_FILE_LOCKS($1) 64020ef0e59aSmrg _LT_LINKER_SHLIBS($1) 64030ef0e59aSmrg _LT_SYS_DYNAMIC_LINKER($1) 64040ef0e59aSmrg _LT_LINKER_HARDCODE_LIBPATH($1) 64050ef0e59aSmrg LT_SYS_DLOPEN_SELF 64060ef0e59aSmrg _LT_CMD_STRIPLIB 64070ef0e59aSmrg 64080ef0e59aSmrg # Report what library types will actually be built 64090ef0e59aSmrg AC_MSG_CHECKING([if libtool supports shared libraries]) 64100ef0e59aSmrg AC_MSG_RESULT([$can_build_shared]) 64110ef0e59aSmrg 64120ef0e59aSmrg AC_MSG_CHECKING([whether to build shared libraries]) 64130ef0e59aSmrg test no = "$can_build_shared" && enable_shared=no 64140ef0e59aSmrg 64150ef0e59aSmrg # On AIX, shared libraries and static libraries use the same namespace, and 64160ef0e59aSmrg # are all built from PIC. 64170ef0e59aSmrg case $host_os in 64180ef0e59aSmrg aix3*) 64190ef0e59aSmrg test yes = "$enable_shared" && enable_static=no 64200ef0e59aSmrg if test -n "$RANLIB"; then 64210ef0e59aSmrg archive_cmds="$archive_cmds~\$RANLIB \$lib" 64220ef0e59aSmrg postinstall_cmds='$RANLIB $lib' 64230ef0e59aSmrg fi 64240ef0e59aSmrg ;; 64250ef0e59aSmrg 64260ef0e59aSmrg aix[[4-9]]*) 64270ef0e59aSmrg if test ia64 != "$host_cpu"; then 64280ef0e59aSmrg case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in 64290ef0e59aSmrg yes,aix,yes) ;; # shared object as lib.so file only 64300ef0e59aSmrg yes,svr4,*) ;; # shared object as lib.so archive member only 64310ef0e59aSmrg yes,*) enable_static=no ;; # shared object in lib.a archive as well 64320ef0e59aSmrg esac 64330ef0e59aSmrg fi 64340ef0e59aSmrg ;; 64350ef0e59aSmrg esac 64360ef0e59aSmrg AC_MSG_RESULT([$enable_shared]) 64370ef0e59aSmrg 64380ef0e59aSmrg AC_MSG_CHECKING([whether to build static libraries]) 64390ef0e59aSmrg # Make sure either enable_shared or enable_static is yes. 64400ef0e59aSmrg test yes = "$enable_shared" || enable_static=yes 64410ef0e59aSmrg AC_MSG_RESULT([$enable_static]) 64420ef0e59aSmrg 64430ef0e59aSmrg _LT_CONFIG($1) 64440ef0e59aSmrgfi 64450ef0e59aSmrgAC_LANG_POP 64460ef0e59aSmrgCC=$lt_save_CC 64470ef0e59aSmrg])# _LT_LANG_C_CONFIG 64480ef0e59aSmrg 64490ef0e59aSmrg 64500ef0e59aSmrg# _LT_LANG_CXX_CONFIG([TAG]) 64510ef0e59aSmrg# -------------------------- 64520ef0e59aSmrg# Ensure that the configuration variables for a C++ compiler are suitably 64530ef0e59aSmrg# defined. These variables are subsequently used by _LT_CONFIG to write 64540ef0e59aSmrg# the compiler configuration to 'libtool'. 64550ef0e59aSmrgm4_defun([_LT_LANG_CXX_CONFIG], 64560ef0e59aSmrg[m4_require([_LT_FILEUTILS_DEFAULTS])dnl 64570ef0e59aSmrgm4_require([_LT_DECL_EGREP])dnl 64580ef0e59aSmrgm4_require([_LT_PATH_MANIFEST_TOOL])dnl 64590ef0e59aSmrgif test -n "$CXX" && ( test no != "$CXX" && 64600ef0e59aSmrg ( (test g++ = "$CXX" && `g++ -v >/dev/null 2>&1` ) || 64610ef0e59aSmrg (test g++ != "$CXX"))); then 64620ef0e59aSmrg AC_PROG_CXXCPP 64630ef0e59aSmrgelse 64640ef0e59aSmrg _lt_caught_CXX_error=yes 64650ef0e59aSmrgfi 64660ef0e59aSmrg 64670ef0e59aSmrgAC_LANG_PUSH(C++) 64680ef0e59aSmrg_LT_TAGVAR(archive_cmds_need_lc, $1)=no 64690ef0e59aSmrg_LT_TAGVAR(allow_undefined_flag, $1)= 64700ef0e59aSmrg_LT_TAGVAR(always_export_symbols, $1)=no 64710ef0e59aSmrg_LT_TAGVAR(archive_expsym_cmds, $1)= 64720ef0e59aSmrg_LT_TAGVAR(compiler_needs_object, $1)=no 64730ef0e59aSmrg_LT_TAGVAR(export_dynamic_flag_spec, $1)= 64740ef0e59aSmrg_LT_TAGVAR(hardcode_direct, $1)=no 64750ef0e59aSmrg_LT_TAGVAR(hardcode_direct_absolute, $1)=no 64760ef0e59aSmrg_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 64770ef0e59aSmrg_LT_TAGVAR(hardcode_libdir_separator, $1)= 64780ef0e59aSmrg_LT_TAGVAR(hardcode_minus_L, $1)=no 64790ef0e59aSmrg_LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported 64800ef0e59aSmrg_LT_TAGVAR(hardcode_automatic, $1)=no 64810ef0e59aSmrg_LT_TAGVAR(inherit_rpath, $1)=no 64820ef0e59aSmrg_LT_TAGVAR(module_cmds, $1)= 64830ef0e59aSmrg_LT_TAGVAR(module_expsym_cmds, $1)= 64840ef0e59aSmrg_LT_TAGVAR(link_all_deplibs, $1)=unknown 64850ef0e59aSmrg_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 64860ef0e59aSmrg_LT_TAGVAR(reload_flag, $1)=$reload_flag 64870ef0e59aSmrg_LT_TAGVAR(reload_cmds, $1)=$reload_cmds 64880ef0e59aSmrg_LT_TAGVAR(no_undefined_flag, $1)= 64890ef0e59aSmrg_LT_TAGVAR(whole_archive_flag_spec, $1)= 64900ef0e59aSmrg_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no 64910ef0e59aSmrg 64920ef0e59aSmrg# Source file extension for C++ test sources. 64930ef0e59aSmrgac_ext=cpp 64940ef0e59aSmrg 64950ef0e59aSmrg# Object file extension for compiled C++ test sources. 64960ef0e59aSmrgobjext=o 64970ef0e59aSmrg_LT_TAGVAR(objext, $1)=$objext 64980ef0e59aSmrg 64990ef0e59aSmrg# No sense in running all these tests if we already determined that 65000ef0e59aSmrg# the CXX compiler isn't working. Some variables (like enable_shared) 65010ef0e59aSmrg# are currently assumed to apply to all compilers on this platform, 65020ef0e59aSmrg# and will be corrupted by setting them based on a non-working compiler. 65030ef0e59aSmrgif test yes != "$_lt_caught_CXX_error"; then 65040ef0e59aSmrg # Code to be used in simple compile tests 65050ef0e59aSmrg lt_simple_compile_test_code="int some_variable = 0;" 65060ef0e59aSmrg 65070ef0e59aSmrg # Code to be used in simple link tests 65080ef0e59aSmrg lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }' 65090ef0e59aSmrg 65100ef0e59aSmrg # ltmain only uses $CC for tagged configurations so make sure $CC is set. 65110ef0e59aSmrg _LT_TAG_COMPILER 65120ef0e59aSmrg 65130ef0e59aSmrg # save warnings/boilerplate of simple test code 65140ef0e59aSmrg _LT_COMPILER_BOILERPLATE 65150ef0e59aSmrg _LT_LINKER_BOILERPLATE 65160ef0e59aSmrg 65170ef0e59aSmrg # Allow CC to be a program name with arguments. 65180ef0e59aSmrg lt_save_CC=$CC 65190ef0e59aSmrg lt_save_CFLAGS=$CFLAGS 65200ef0e59aSmrg lt_save_LD=$LD 65210ef0e59aSmrg lt_save_GCC=$GCC 65220ef0e59aSmrg GCC=$GXX 65230ef0e59aSmrg lt_save_with_gnu_ld=$with_gnu_ld 65240ef0e59aSmrg lt_save_path_LD=$lt_cv_path_LD 65250ef0e59aSmrg if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then 65260ef0e59aSmrg lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx 65270ef0e59aSmrg else 65280ef0e59aSmrg $as_unset lt_cv_prog_gnu_ld 65290ef0e59aSmrg fi 65300ef0e59aSmrg if test -n "${lt_cv_path_LDCXX+set}"; then 65310ef0e59aSmrg lt_cv_path_LD=$lt_cv_path_LDCXX 65320ef0e59aSmrg else 65330ef0e59aSmrg $as_unset lt_cv_path_LD 65340ef0e59aSmrg fi 65350ef0e59aSmrg test -z "${LDCXX+set}" || LD=$LDCXX 65360ef0e59aSmrg CC=${CXX-"c++"} 65370ef0e59aSmrg CFLAGS=$CXXFLAGS 65380ef0e59aSmrg compiler=$CC 65390ef0e59aSmrg _LT_TAGVAR(compiler, $1)=$CC 65400ef0e59aSmrg _LT_CC_BASENAME([$compiler]) 65410ef0e59aSmrg 65420ef0e59aSmrg if test -n "$compiler"; then 65430ef0e59aSmrg # We don't want -fno-exception when compiling C++ code, so set the 65440ef0e59aSmrg # no_builtin_flag separately 65450ef0e59aSmrg if test yes = "$GXX"; then 65460ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' 65470ef0e59aSmrg else 65480ef0e59aSmrg _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= 65490ef0e59aSmrg fi 65500ef0e59aSmrg 65510ef0e59aSmrg if test yes = "$GXX"; then 65520ef0e59aSmrg # Set up default GNU C++ configuration 65530ef0e59aSmrg 65540ef0e59aSmrg LT_PATH_LD 65550ef0e59aSmrg 65560ef0e59aSmrg # Check if GNU C++ uses GNU ld as the underlying linker, since the 65570ef0e59aSmrg # archiving commands below assume that GNU ld is being used. 65580ef0e59aSmrg if test yes = "$with_gnu_ld"; then 65590ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' 65600ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' 65610ef0e59aSmrg 65620ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' 65630ef0e59aSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' 65640ef0e59aSmrg 65650ef0e59aSmrg # If archive_cmds runs LD, not CC, wlarc should be empty 65660ef0e59aSmrg # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to 65670ef0e59aSmrg # investigate it a little bit more. (MM) 65680ef0e59aSmrg wlarc='$wl' 65690ef0e59aSmrg 65700ef0e59aSmrg # ancient GNU ld didn't support --whole-archive et. al. 6571d5e6aabbSmrg if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then 65720ef0e59aSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' 65730ef0e59aSmrg else 65740ef0e59aSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)= 65750ef0e59aSmrg fi 65760ef0e59aSmrg else 65770ef0e59aSmrg with_gnu_ld=no 65780ef0e59aSmrg wlarc= 65790ef0e59aSmrg 65800ef0e59aSmrg # A generic and very simple default shared library creation 65810ef0e59aSmrg # command for GNU C++ for the case where it uses the native 65820ef0e59aSmrg # linker, instead of GNU ld. If possible, this setting should 65830ef0e59aSmrg # overridden to take advantage of the native linker features on 65840ef0e59aSmrg # the platform it is being used on. 65850ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' 65860ef0e59aSmrg fi 65870ef0e59aSmrg 65880ef0e59aSmrg # Commands to make compiler produce verbose output that lists 65890ef0e59aSmrg # what "hidden" libraries, object files and flags are used when 65900ef0e59aSmrg # linking a shared library. 6591d5e6aabbSmrg output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP " [[-]]L"' 65920ef0e59aSmrg 65930ef0e59aSmrg else 65940ef0e59aSmrg GXX=no 65950ef0e59aSmrg with_gnu_ld=no 65960ef0e59aSmrg wlarc= 65970ef0e59aSmrg fi 65980ef0e59aSmrg 65990ef0e59aSmrg # PORTME: fill in a description of your system's C++ link characteristics 66000ef0e59aSmrg AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) 66010ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=yes 66020ef0e59aSmrg case $host_os in 66030ef0e59aSmrg aix3*) 66040ef0e59aSmrg # FIXME: insert proper C++ library support 66050ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=no 66060ef0e59aSmrg ;; 66070ef0e59aSmrg aix[[4-9]]*) 66080ef0e59aSmrg if test ia64 = "$host_cpu"; then 66090ef0e59aSmrg # On IA64, the linker does run time linking by default, so we don't 66100ef0e59aSmrg # have to do anything special. 66110ef0e59aSmrg aix_use_runtimelinking=no 66120ef0e59aSmrg exp_sym_flag='-Bexport' 66130ef0e59aSmrg no_entry_flag= 66140ef0e59aSmrg else 66150ef0e59aSmrg aix_use_runtimelinking=no 66160ef0e59aSmrg 66170ef0e59aSmrg # Test if we are trying to use run time linking or normal 66180ef0e59aSmrg # AIX style linking. If -brtl is somewhere in LDFLAGS, we 66190ef0e59aSmrg # have runtime linking enabled, and use it for executables. 66200ef0e59aSmrg # For shared libraries, we enable/disable runtime linking 66210ef0e59aSmrg # depending on the kind of the shared library created - 66220ef0e59aSmrg # when "with_aix_soname,aix_use_runtimelinking" is: 66230ef0e59aSmrg # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables 66240ef0e59aSmrg # "aix,yes" lib.so shared, rtl:yes, for executables 66250ef0e59aSmrg # lib.a static archive 66260ef0e59aSmrg # "both,no" lib.so.V(shr.o) shared, rtl:yes 66270ef0e59aSmrg # lib.a(lib.so.V) shared, rtl:no, for executables 66280ef0e59aSmrg # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables 66290ef0e59aSmrg # lib.a(lib.so.V) shared, rtl:no 66300ef0e59aSmrg # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables 66310ef0e59aSmrg # lib.a static archive 66320ef0e59aSmrg case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) 66330ef0e59aSmrg for ld_flag in $LDFLAGS; do 66340ef0e59aSmrg case $ld_flag in 66350ef0e59aSmrg *-brtl*) 66360ef0e59aSmrg aix_use_runtimelinking=yes 66370ef0e59aSmrg break 66380ef0e59aSmrg ;; 66390ef0e59aSmrg esac 66400ef0e59aSmrg done 66410ef0e59aSmrg if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then 66420ef0e59aSmrg # With aix-soname=svr4, we create the lib.so.V shared archives only, 66430ef0e59aSmrg # so we don't have lib.a shared libs to link our executables. 66440ef0e59aSmrg # We have to force runtime linking in this case. 66450ef0e59aSmrg aix_use_runtimelinking=yes 66460ef0e59aSmrg LDFLAGS="$LDFLAGS -Wl,-brtl" 66470ef0e59aSmrg fi 66480ef0e59aSmrg ;; 66490ef0e59aSmrg esac 66500ef0e59aSmrg 66510ef0e59aSmrg exp_sym_flag='-bexport' 66520ef0e59aSmrg no_entry_flag='-bnoentry' 66530ef0e59aSmrg fi 66540ef0e59aSmrg 66550ef0e59aSmrg # When large executables or shared objects are built, AIX ld can 66560ef0e59aSmrg # have problems creating the table of contents. If linking a library 66570ef0e59aSmrg # or program results in "error TOC overflow" add -mminimal-toc to 66580ef0e59aSmrg # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not 66590ef0e59aSmrg # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. 66600ef0e59aSmrg 66610ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='' 66620ef0e59aSmrg _LT_TAGVAR(hardcode_direct, $1)=yes 66630ef0e59aSmrg _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 66640ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)=':' 66650ef0e59aSmrg _LT_TAGVAR(link_all_deplibs, $1)=yes 66660ef0e59aSmrg _LT_TAGVAR(file_list_spec, $1)='$wl-f,' 66670ef0e59aSmrg case $with_aix_soname,$aix_use_runtimelinking in 66680ef0e59aSmrg aix,*) ;; # no import file 66690ef0e59aSmrg svr4,* | *,yes) # use import file 66700ef0e59aSmrg # The Import File defines what to hardcode. 66710ef0e59aSmrg _LT_TAGVAR(hardcode_direct, $1)=no 66720ef0e59aSmrg _LT_TAGVAR(hardcode_direct_absolute, $1)=no 66730ef0e59aSmrg ;; 66740ef0e59aSmrg esac 66750ef0e59aSmrg 66760ef0e59aSmrg if test yes = "$GXX"; then 66770ef0e59aSmrg case $host_os in aix4.[[012]]|aix4.[[012]].*) 66780ef0e59aSmrg # We only want to do this on AIX 4.2 and lower, the check 66790ef0e59aSmrg # below for broken collect2 doesn't work under 4.3+ 66800ef0e59aSmrg collect2name=`$CC -print-prog-name=collect2` 66810ef0e59aSmrg if test -f "$collect2name" && 66820ef0e59aSmrg strings "$collect2name" | $GREP resolve_lib_name >/dev/null 66830ef0e59aSmrg then 66840ef0e59aSmrg # We have reworked collect2 66850ef0e59aSmrg : 66860ef0e59aSmrg else 66870ef0e59aSmrg # We have old collect2 66880ef0e59aSmrg _LT_TAGVAR(hardcode_direct, $1)=unsupported 66890ef0e59aSmrg # It fails to find uninstalled libraries when the uninstalled 66900ef0e59aSmrg # path is not listed in the libpath. Setting hardcode_minus_L 66910ef0e59aSmrg # to unsupported forces relinking 66920ef0e59aSmrg _LT_TAGVAR(hardcode_minus_L, $1)=yes 66930ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 66940ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)= 66950ef0e59aSmrg fi 66960ef0e59aSmrg esac 66970ef0e59aSmrg shared_flag='-shared' 66980ef0e59aSmrg if test yes = "$aix_use_runtimelinking"; then 66990ef0e59aSmrg shared_flag=$shared_flag' $wl-G' 67000ef0e59aSmrg fi 67010ef0e59aSmrg # Need to ensure runtime linking is disabled for the traditional 67020ef0e59aSmrg # shared library, or the linker may eventually find shared libraries 67030ef0e59aSmrg # /with/ Import File - we do not want to mix them. 67040ef0e59aSmrg shared_flag_aix='-shared' 67050ef0e59aSmrg shared_flag_svr4='-shared $wl-G' 67060ef0e59aSmrg else 67070ef0e59aSmrg # not using gcc 67080ef0e59aSmrg if test ia64 = "$host_cpu"; then 67090ef0e59aSmrg # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release 67100ef0e59aSmrg # chokes on -Wl,-G. The following line is correct: 67110ef0e59aSmrg shared_flag='-G' 67120ef0e59aSmrg else 67130ef0e59aSmrg if test yes = "$aix_use_runtimelinking"; then 67140ef0e59aSmrg shared_flag='$wl-G' 67150ef0e59aSmrg else 67160ef0e59aSmrg shared_flag='$wl-bM:SRE' 67170ef0e59aSmrg fi 67180ef0e59aSmrg shared_flag_aix='$wl-bM:SRE' 67190ef0e59aSmrg shared_flag_svr4='$wl-G' 67200ef0e59aSmrg fi 67210ef0e59aSmrg fi 67220ef0e59aSmrg 67230ef0e59aSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-bexpall' 67240ef0e59aSmrg # It seems that -bexpall does not export symbols beginning with 67250ef0e59aSmrg # underscore (_), so it is better to generate a list of symbols to 67260ef0e59aSmrg # export. 67270ef0e59aSmrg _LT_TAGVAR(always_export_symbols, $1)=yes 67280ef0e59aSmrg if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then 67290ef0e59aSmrg # Warning - without using the other runtime loading flags (-brtl), 67300ef0e59aSmrg # -berok will link without error, but may produce a broken library. 67310ef0e59aSmrg # The "-G" linker flag allows undefined symbols. 67320ef0e59aSmrg _LT_TAGVAR(no_undefined_flag, $1)='-bernotok' 67330ef0e59aSmrg # Determine the default libpath from the value encoded in an empty 67340ef0e59aSmrg # executable. 67350ef0e59aSmrg _LT_SYS_MODULE_PATH_AIX([$1]) 67360ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" 67370ef0e59aSmrg 67380ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag 67390ef0e59aSmrg else 67400ef0e59aSmrg if test ia64 = "$host_cpu"; then 67410ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $libdir:/usr/lib:/lib' 67420ef0e59aSmrg _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" 67430ef0e59aSmrg _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" 67440ef0e59aSmrg else 67450ef0e59aSmrg # Determine the default libpath from the value encoded in an 67460ef0e59aSmrg # empty executable. 67470ef0e59aSmrg _LT_SYS_MODULE_PATH_AIX([$1]) 67480ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" 67490ef0e59aSmrg # Warning - without using the other run time loading flags, 67500ef0e59aSmrg # -berok will link without error, but may produce a broken library. 67510ef0e59aSmrg _LT_TAGVAR(no_undefined_flag, $1)=' $wl-bernotok' 67520ef0e59aSmrg _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-berok' 67530ef0e59aSmrg if test yes = "$with_gnu_ld"; then 67540ef0e59aSmrg # We only use this code for GNU lds that support --whole-archive. 67550ef0e59aSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive' 67560ef0e59aSmrg else 67570ef0e59aSmrg # Exported symbols can be pulled into shared objects from archives 67580ef0e59aSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' 67590ef0e59aSmrg fi 67600ef0e59aSmrg _LT_TAGVAR(archive_cmds_need_lc, $1)=yes 67610ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d' 67620ef0e59aSmrg # -brtl affects multiple linker settings, -berok does not and is overridden later 67630ef0e59aSmrg compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([[, ]]\\)%-berok\\1%g"`' 67640ef0e59aSmrg if test svr4 != "$with_aix_soname"; then 67650ef0e59aSmrg # This is similar to how AIX traditionally builds its shared 67660ef0e59aSmrg # libraries. Need -bnortl late, we may have -brtl in LDFLAGS. 67670ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname' 67680ef0e59aSmrg fi 67690ef0e59aSmrg if test aix != "$with_aix_soname"; then 67700ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp' 67710ef0e59aSmrg else 67720ef0e59aSmrg # used by -dlpreopen to get the symbols 67730ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$MV $output_objdir/$realname.d/$soname $output_objdir' 67740ef0e59aSmrg fi 67750ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$RM -r $output_objdir/$realname.d' 67760ef0e59aSmrg fi 67770ef0e59aSmrg fi 67780ef0e59aSmrg ;; 67790ef0e59aSmrg 67800ef0e59aSmrg beos*) 67810ef0e59aSmrg if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 67820ef0e59aSmrg _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 67830ef0e59aSmrg # Joseph Beckenbach <jrb3@best.com> says some releases of gcc 67840ef0e59aSmrg # support --undefined. This deserves some investigation. FIXME 67850ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' 67860ef0e59aSmrg else 67870ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=no 67880ef0e59aSmrg fi 67890ef0e59aSmrg ;; 67900ef0e59aSmrg 67910ef0e59aSmrg chorus*) 67920ef0e59aSmrg case $cc_basename in 67930ef0e59aSmrg *) 67940ef0e59aSmrg # FIXME: insert proper C++ library support 67950ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=no 67960ef0e59aSmrg ;; 67970ef0e59aSmrg esac 67980ef0e59aSmrg ;; 67990ef0e59aSmrg 6800d5e6aabbSmrg cygwin* | mingw* | windows* | pw32* | cegcc*) 68010ef0e59aSmrg case $GXX,$cc_basename in 680215885c33Smrg ,cl* | no,cl* | ,icl* | no,icl*) 680315885c33Smrg # Native MSVC or ICC 68040ef0e59aSmrg # hardcode_libdir_flag_spec is actually meaningless, as there is 68050ef0e59aSmrg # no search path for DLLs. 68060ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' 68070ef0e59aSmrg _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 68080ef0e59aSmrg _LT_TAGVAR(always_export_symbols, $1)=yes 68090ef0e59aSmrg _LT_TAGVAR(file_list_spec, $1)='@' 68100ef0e59aSmrg # Tell ltmain to make .lib files, not .a files. 68110ef0e59aSmrg libext=lib 68120ef0e59aSmrg # Tell ltmain to make .dll files, not .so files. 68130ef0e59aSmrg shrext_cmds=.dll 68140ef0e59aSmrg # FIXME: Setting linknames here is a bad hack. 68150ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames=' 68160ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then 68170ef0e59aSmrg cp "$export_symbols" "$output_objdir/$soname.def"; 68180ef0e59aSmrg echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp"; 68190ef0e59aSmrg else 68200ef0e59aSmrg $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp; 68210ef0e59aSmrg fi~ 68220ef0e59aSmrg $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ 68230ef0e59aSmrg linknames=' 68240ef0e59aSmrg # The linker will not automatically build a static lib if we build a DLL. 68250ef0e59aSmrg # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' 68260ef0e59aSmrg _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 68270ef0e59aSmrg # Don't use ranlib 68280ef0e59aSmrg _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib' 68290ef0e59aSmrg _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~ 68300ef0e59aSmrg lt_tool_outputfile="@TOOL_OUTPUT@"~ 68310ef0e59aSmrg case $lt_outputfile in 68320ef0e59aSmrg *.exe|*.EXE) ;; 68330ef0e59aSmrg *) 68340ef0e59aSmrg lt_outputfile=$lt_outputfile.exe 68350ef0e59aSmrg lt_tool_outputfile=$lt_tool_outputfile.exe 68360ef0e59aSmrg ;; 68370ef0e59aSmrg esac~ 68380ef0e59aSmrg func_to_tool_file "$lt_outputfile"~ 68390ef0e59aSmrg if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then 68400ef0e59aSmrg $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; 68410ef0e59aSmrg $RM "$lt_outputfile.manifest"; 68420ef0e59aSmrg fi' 68430ef0e59aSmrg ;; 68440ef0e59aSmrg *) 68450ef0e59aSmrg # g++ 68460ef0e59aSmrg # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, 68470ef0e59aSmrg # as there is no search path for DLLs. 68480ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 68490ef0e59aSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-all-symbols' 68500ef0e59aSmrg _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 68510ef0e59aSmrg _LT_TAGVAR(always_export_symbols, $1)=no 68520ef0e59aSmrg _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 6853d5e6aabbSmrg _LT_TAGVAR(file_list_spec, $1)='@' 68540ef0e59aSmrg 68550ef0e59aSmrg if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then 68560ef0e59aSmrg _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' 68570ef0e59aSmrg # If the export-symbols file already is a .def file, use it as 68580ef0e59aSmrg # is; otherwise, prepend EXPORTS... 68590ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then 68600ef0e59aSmrg cp $export_symbols $output_objdir/$soname.def; 68610ef0e59aSmrg else 68620ef0e59aSmrg echo EXPORTS > $output_objdir/$soname.def; 68630ef0e59aSmrg cat $export_symbols >> $output_objdir/$soname.def; 68640ef0e59aSmrg fi~ 68650ef0e59aSmrg $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' 68660ef0e59aSmrg else 68670ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=no 68680ef0e59aSmrg fi 68690ef0e59aSmrg ;; 68700ef0e59aSmrg esac 68710ef0e59aSmrg ;; 68720ef0e59aSmrg darwin* | rhapsody*) 68730ef0e59aSmrg _LT_DARWIN_LINKER_FEATURES($1) 68740ef0e59aSmrg ;; 68750ef0e59aSmrg 68760ef0e59aSmrg os2*) 68770ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 68780ef0e59aSmrg _LT_TAGVAR(hardcode_minus_L, $1)=yes 68790ef0e59aSmrg _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 68800ef0e59aSmrg shrext_cmds=.dll 68810ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ 68820ef0e59aSmrg $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ 68830ef0e59aSmrg $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ 68840ef0e59aSmrg $ECHO EXPORTS >> $output_objdir/$libname.def~ 68850ef0e59aSmrg emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ 68860ef0e59aSmrg $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ 68870ef0e59aSmrg emximp -o $lib $output_objdir/$libname.def' 68880ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ 68890ef0e59aSmrg $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ 68900ef0e59aSmrg $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ 68910ef0e59aSmrg $ECHO EXPORTS >> $output_objdir/$libname.def~ 68920ef0e59aSmrg prefix_cmds="$SED"~ 68930ef0e59aSmrg if test EXPORTS = "`$SED 1q $export_symbols`"; then 68940ef0e59aSmrg prefix_cmds="$prefix_cmds -e 1d"; 68950ef0e59aSmrg fi~ 68960ef0e59aSmrg prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ 68970ef0e59aSmrg cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ 68980ef0e59aSmrg $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ 68990ef0e59aSmrg emximp -o $lib $output_objdir/$libname.def' 6900d5e6aabbSmrg _LT_TAGVAR(old_archive_from_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' 69010ef0e59aSmrg _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 690215885c33Smrg _LT_TAGVAR(file_list_spec, $1)='@' 69030ef0e59aSmrg ;; 69040ef0e59aSmrg 69050ef0e59aSmrg dgux*) 69060ef0e59aSmrg case $cc_basename in 69070ef0e59aSmrg ec++*) 69080ef0e59aSmrg # FIXME: insert proper C++ library support 69090ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=no 69100ef0e59aSmrg ;; 69110ef0e59aSmrg ghcx*) 69120ef0e59aSmrg # Green Hills C++ Compiler 69130ef0e59aSmrg # FIXME: insert proper C++ library support 69140ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=no 69150ef0e59aSmrg ;; 69160ef0e59aSmrg *) 69170ef0e59aSmrg # FIXME: insert proper C++ library support 69180ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=no 69190ef0e59aSmrg ;; 69200ef0e59aSmrg esac 69210ef0e59aSmrg ;; 69220ef0e59aSmrg 69230ef0e59aSmrg freebsd2.*) 69240ef0e59aSmrg # C++ shared libraries reported to be fairly broken before 69250ef0e59aSmrg # switch to ELF 69260ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=no 69270ef0e59aSmrg ;; 69280ef0e59aSmrg 69290ef0e59aSmrg freebsd-elf*) 69300ef0e59aSmrg _LT_TAGVAR(archive_cmds_need_lc, $1)=no 69310ef0e59aSmrg ;; 69320ef0e59aSmrg 693315885c33Smrg freebsd* | dragonfly* | midnightbsd*) 69340ef0e59aSmrg # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF 69350ef0e59aSmrg # conventions 69360ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=yes 69370ef0e59aSmrg ;; 69380ef0e59aSmrg 69390ef0e59aSmrg haiku*) 69400ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' 6941d5e6aabbSmrg _LT_TAGVAR(link_all_deplibs, $1)=no 69420ef0e59aSmrg ;; 69430ef0e59aSmrg 69440ef0e59aSmrg hpux9*) 69450ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' 69460ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)=: 69470ef0e59aSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' 69480ef0e59aSmrg _LT_TAGVAR(hardcode_direct, $1)=yes 69490ef0e59aSmrg _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, 69500ef0e59aSmrg # but as the default 69510ef0e59aSmrg # location of the library. 69520ef0e59aSmrg 69530ef0e59aSmrg case $cc_basename in 69540ef0e59aSmrg CC*) 69550ef0e59aSmrg # FIXME: insert proper C++ library support 69560ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=no 69570ef0e59aSmrg ;; 69580ef0e59aSmrg aCC*) 69590ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -b $wl+b $wl$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' 69600ef0e59aSmrg # Commands to make compiler produce verbose output that lists 69610ef0e59aSmrg # what "hidden" libraries, object files and flags are used when 69620ef0e59aSmrg # linking a shared library. 69630ef0e59aSmrg # 69640ef0e59aSmrg # There doesn't appear to be a way to prevent this compiler from 69650ef0e59aSmrg # explicitly linking system object files so we need to strip them 69660ef0e59aSmrg # from the output so that they don't get included in the library 69670ef0e59aSmrg # dependencies. 6968d5e6aabbSmrg output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "[[-]]L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' 69690ef0e59aSmrg ;; 69700ef0e59aSmrg *) 69710ef0e59aSmrg if test yes = "$GXX"; then 69720ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' 69730ef0e59aSmrg else 69740ef0e59aSmrg # FIXME: insert proper C++ library support 69750ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=no 69760ef0e59aSmrg fi 69770ef0e59aSmrg ;; 69780ef0e59aSmrg esac 69790ef0e59aSmrg ;; 69800ef0e59aSmrg 69810ef0e59aSmrg hpux10*|hpux11*) 69820ef0e59aSmrg if test no = "$with_gnu_ld"; then 69830ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' 69840ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)=: 69850ef0e59aSmrg 69860ef0e59aSmrg case $host_cpu in 69870ef0e59aSmrg hppa*64*|ia64*) 69880ef0e59aSmrg ;; 69890ef0e59aSmrg *) 69900ef0e59aSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' 69910ef0e59aSmrg ;; 69920ef0e59aSmrg esac 69930ef0e59aSmrg fi 69940ef0e59aSmrg case $host_cpu in 69950ef0e59aSmrg hppa*64*|ia64*) 69960ef0e59aSmrg _LT_TAGVAR(hardcode_direct, $1)=no 69970ef0e59aSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 69980ef0e59aSmrg ;; 69990ef0e59aSmrg *) 70000ef0e59aSmrg _LT_TAGVAR(hardcode_direct, $1)=yes 70010ef0e59aSmrg _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 70020ef0e59aSmrg _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, 70030ef0e59aSmrg # but as the default 70040ef0e59aSmrg # location of the library. 70050ef0e59aSmrg ;; 70060ef0e59aSmrg esac 70070ef0e59aSmrg 70080ef0e59aSmrg case $cc_basename in 70090ef0e59aSmrg CC*) 70100ef0e59aSmrg # FIXME: insert proper C++ library support 70110ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=no 70120ef0e59aSmrg ;; 70130ef0e59aSmrg aCC*) 70140ef0e59aSmrg case $host_cpu in 70150ef0e59aSmrg hppa*64*) 70160ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 70170ef0e59aSmrg ;; 70180ef0e59aSmrg ia64*) 70190ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 70200ef0e59aSmrg ;; 70210ef0e59aSmrg *) 70220ef0e59aSmrg _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' 70230ef0e59aSmrg ;; 70240ef0e59aSmrg esac 70250ef0e59aSmrg # Commands to make compiler produce verbose output that lists 70260ef0e59aSmrg # what "hidden" libraries, object files and flags are used when 70270ef0e59aSmrg # linking a shared library. 70280ef0e59aSmrg # 70290ef0e59aSmrg # There doesn't appear to be a way to prevent this compiler from 70300ef0e59aSmrg # explicitly linking system object files so we need to strip them 70310ef0e59aSmrg # from the output so that they don't get included in the library 70320ef0e59aSmrg # dependencies. 7033d5e6aabbSmrg output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP " [[-]]L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' 70340ef0e59aSmrg ;; 70350ef0e59aSmrg *) 70360ef0e59aSmrg if test yes = "$GXX"; then 70370ef0e59aSmrg if test no = "$with_gnu_ld"; then 70380ef0e59aSmrg case $host_cpu in 70390ef0e59aSmrg hppa*64*) 70400ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 70410ef0e59aSmrg ;; 70420ef0e59aSmrg ia64*) 70430ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 70440ef0e59aSmrg ;; 70450ef0e59aSmrg *) 70460ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 70470ef0e59aSmrg ;; 70480ef0e59aSmrg esac 70490ef0e59aSmrg fi 70500ef0e59aSmrg else 70510ef0e59aSmrg # FIXME: insert proper C++ library support 70520ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=no 70530ef0e59aSmrg fi 70540ef0e59aSmrg ;; 70550ef0e59aSmrg esac 70560ef0e59aSmrg ;; 70570ef0e59aSmrg 70580ef0e59aSmrg interix[[3-9]]*) 70590ef0e59aSmrg _LT_TAGVAR(hardcode_direct, $1)=no 70600ef0e59aSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 70610ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' 70620ef0e59aSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' 70630ef0e59aSmrg # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. 70640ef0e59aSmrg # Instead, shared libraries are loaded at an image base (0x10000000 by 70650ef0e59aSmrg # default) and relocated if they conflict, which is a slow very memory 70660ef0e59aSmrg # consuming and fragmenting process. To avoid this, we pick a random, 70670ef0e59aSmrg # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link 70680ef0e59aSmrg # time. Moving up from 0x10000000 also allows more sbrk(2) space. 70690ef0e59aSmrg _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' 707015885c33Smrg _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' 70710ef0e59aSmrg ;; 70720ef0e59aSmrg irix5* | irix6*) 70730ef0e59aSmrg case $cc_basename in 70740ef0e59aSmrg CC*) 70750ef0e59aSmrg # SGI C++ 70760ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' 70770ef0e59aSmrg 70780ef0e59aSmrg # Archives containing C++ object files must be created using 70790ef0e59aSmrg # "CC -ar", where "CC" is the IRIX C++ compiler. This is 70800ef0e59aSmrg # necessary to make sure instantiated templates are included 70810ef0e59aSmrg # in the archive. 70820ef0e59aSmrg _LT_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs' 70830ef0e59aSmrg ;; 70840ef0e59aSmrg *) 70850ef0e59aSmrg if test yes = "$GXX"; then 70860ef0e59aSmrg if test no = "$with_gnu_ld"; then 70870ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' 70880ef0e59aSmrg else 70890ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` -o $lib' 70900ef0e59aSmrg fi 70910ef0e59aSmrg fi 70920ef0e59aSmrg _LT_TAGVAR(link_all_deplibs, $1)=yes 70930ef0e59aSmrg ;; 70940ef0e59aSmrg esac 70950ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' 70960ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)=: 70970ef0e59aSmrg _LT_TAGVAR(inherit_rpath, $1)=yes 70980ef0e59aSmrg ;; 70990ef0e59aSmrg 71000ef0e59aSmrg linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) 71010ef0e59aSmrg case $cc_basename in 71020ef0e59aSmrg KCC*) 71030ef0e59aSmrg # Kuck and Associates, Inc. (KAI) C++ Compiler 71040ef0e59aSmrg 71050ef0e59aSmrg # KCC will only create a shared library if the output file 71060ef0e59aSmrg # ends with ".so" (or ".sl" for HP-UX), so rename the library 71070ef0e59aSmrg # to its proper name (with version) after linking. 71080ef0e59aSmrg _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' 71090ef0e59aSmrg _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' 71100ef0e59aSmrg # Commands to make compiler produce verbose output that lists 71110ef0e59aSmrg # what "hidden" libraries, object files and flags are used when 71120ef0e59aSmrg # linking a shared library. 71130ef0e59aSmrg # 71140ef0e59aSmrg # There doesn't appear to be a way to prevent this compiler from 71150ef0e59aSmrg # explicitly linking system object files so we need to strip them 71160ef0e59aSmrg # from the output so that they don't get included in the library 71170ef0e59aSmrg # dependencies. 71180ef0e59aSmrg output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' 71190ef0e59aSmrg 71200ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' 71210ef0e59aSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' 71220ef0e59aSmrg 71230ef0e59aSmrg # Archives containing C++ object files must be created using 71240ef0e59aSmrg # "CC -Bstatic", where "CC" is the KAI C++ compiler. 71250ef0e59aSmrg _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' 71260ef0e59aSmrg ;; 71270ef0e59aSmrg icpc* | ecpc* ) 71280ef0e59aSmrg # Intel C++ 71290ef0e59aSmrg with_gnu_ld=yes 71300ef0e59aSmrg # version 8.0 and above of icpc choke on multiply defined symbols 71310ef0e59aSmrg # if we add $predep_objects and $postdep_objects, however 7.1 and 71320ef0e59aSmrg # earlier do not add the objects themselves. 71330ef0e59aSmrg case `$CC -V 2>&1` in 71340ef0e59aSmrg *"Version 7."*) 71350ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' 71360ef0e59aSmrg _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' 71370ef0e59aSmrg ;; 71380ef0e59aSmrg *) # Version 8.0 or newer 71390ef0e59aSmrg tmp_idyn= 71400ef0e59aSmrg case $host_cpu in 71410ef0e59aSmrg ia64*) tmp_idyn=' -i_dynamic';; 71420ef0e59aSmrg esac 71430ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' 71440ef0e59aSmrg _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' 71450ef0e59aSmrg ;; 71460ef0e59aSmrg esac 71470ef0e59aSmrg _LT_TAGVAR(archive_cmds_need_lc, $1)=no 71480ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' 71490ef0e59aSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' 71500ef0e59aSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive' 71510ef0e59aSmrg ;; 71520ef0e59aSmrg pgCC* | pgcpp*) 71530ef0e59aSmrg # Portland Group C++ compiler 71540ef0e59aSmrg case `$CC -V` in 71550ef0e59aSmrg *pgCC\ [[1-5]].* | *pgcpp\ [[1-5]].*) 71560ef0e59aSmrg _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~ 71570ef0e59aSmrg rm -rf $tpldir~ 71580ef0e59aSmrg $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~ 71590ef0e59aSmrg compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"' 71600ef0e59aSmrg _LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~ 71610ef0e59aSmrg rm -rf $tpldir~ 71620ef0e59aSmrg $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~ 71630ef0e59aSmrg $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~ 71640ef0e59aSmrg $RANLIB $oldlib' 71650ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~ 71660ef0e59aSmrg rm -rf $tpldir~ 71670ef0e59aSmrg $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ 71680ef0e59aSmrg $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' 71690ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~ 71700ef0e59aSmrg rm -rf $tpldir~ 71710ef0e59aSmrg $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ 71720ef0e59aSmrg $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' 71730ef0e59aSmrg ;; 71740ef0e59aSmrg *) # Version 6 and above use weak symbols 71750ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' 71760ef0e59aSmrg _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' 71770ef0e59aSmrg ;; 71780ef0e59aSmrg esac 71790ef0e59aSmrg 71800ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl--rpath $wl$libdir' 71810ef0e59aSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' 71820ef0e59aSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' 71830ef0e59aSmrg ;; 71840ef0e59aSmrg cxx*) 71850ef0e59aSmrg # Compaq C++ 71860ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' 71870ef0e59aSmrg _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' 71880ef0e59aSmrg 71890ef0e59aSmrg runpath_var=LD_RUN_PATH 71900ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' 71910ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)=: 71920ef0e59aSmrg 71930ef0e59aSmrg # Commands to make compiler produce verbose output that lists 71940ef0e59aSmrg # what "hidden" libraries, object files and flags are used when 71950ef0e59aSmrg # linking a shared library. 71960ef0e59aSmrg # 71970ef0e59aSmrg # There doesn't appear to be a way to prevent this compiler from 71980ef0e59aSmrg # explicitly linking system object files so we need to strip them 71990ef0e59aSmrg # from the output so that they don't get included in the library 72000ef0e59aSmrg # dependencies. 72010ef0e59aSmrg output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed' 72020ef0e59aSmrg ;; 72030ef0e59aSmrg xl* | mpixl* | bgxl*) 72040ef0e59aSmrg # IBM XL 8.0 on PPC, with GNU ld 72050ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' 72060ef0e59aSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' 72070ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' 72080ef0e59aSmrg if test yes = "$supports_anon_versioning"; then 72090ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ 721015885c33Smrg cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ 72110ef0e59aSmrg echo "local: *; };" >> $output_objdir/$libname.ver~ 72120ef0e59aSmrg $CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib' 72130ef0e59aSmrg fi 72140ef0e59aSmrg ;; 72150ef0e59aSmrg *) 721615885c33Smrg case `$CC -V 2>&1 | $SED 5q` in 72170ef0e59aSmrg *Sun\ C*) 72180ef0e59aSmrg # Sun C++ 5.9 72190ef0e59aSmrg _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' 72200ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 72210ef0e59aSmrg _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' 72220ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 72230ef0e59aSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' 72240ef0e59aSmrg _LT_TAGVAR(compiler_needs_object, $1)=yes 72250ef0e59aSmrg 72260ef0e59aSmrg # Not sure whether something based on 72270ef0e59aSmrg # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 72280ef0e59aSmrg # would be better. 72290ef0e59aSmrg output_verbose_link_cmd='func_echo_all' 72300ef0e59aSmrg 72310ef0e59aSmrg # Archives containing C++ object files must be created using 72320ef0e59aSmrg # "CC -xar", where "CC" is the Sun C++ compiler. This is 72330ef0e59aSmrg # necessary to make sure instantiated templates are included 72340ef0e59aSmrg # in the archive. 72350ef0e59aSmrg _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' 72360ef0e59aSmrg ;; 72370ef0e59aSmrg esac 72380ef0e59aSmrg ;; 72390ef0e59aSmrg esac 72400ef0e59aSmrg ;; 72410ef0e59aSmrg 72420ef0e59aSmrg lynxos*) 72430ef0e59aSmrg # FIXME: insert proper C++ library support 72440ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=no 72450ef0e59aSmrg ;; 72460ef0e59aSmrg 72470ef0e59aSmrg m88k*) 72480ef0e59aSmrg # FIXME: insert proper C++ library support 72490ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=no 72500ef0e59aSmrg ;; 72510ef0e59aSmrg 72520ef0e59aSmrg mvs*) 72530ef0e59aSmrg case $cc_basename in 72540ef0e59aSmrg cxx*) 72550ef0e59aSmrg # FIXME: insert proper C++ library support 72560ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=no 72570ef0e59aSmrg ;; 72580ef0e59aSmrg *) 72590ef0e59aSmrg # FIXME: insert proper C++ library support 72600ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=no 72610ef0e59aSmrg ;; 72620ef0e59aSmrg esac 72630ef0e59aSmrg ;; 72640ef0e59aSmrg 7265d5e6aabbSmrg *-mlibc) 7266d5e6aabbSmrg _LT_TAGVAR(ld_shlibs, $1)=yes 7267d5e6aabbSmrg ;; 7268d5e6aabbSmrg 72690ef0e59aSmrg netbsd*) 72700ef0e59aSmrg if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then 72710ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' 72720ef0e59aSmrg wlarc= 72730ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 72740ef0e59aSmrg _LT_TAGVAR(hardcode_direct, $1)=yes 72750ef0e59aSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 72760ef0e59aSmrg fi 72770ef0e59aSmrg # Workaround some broken pre-1.5 toolchains 72780ef0e59aSmrg output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' 72790ef0e59aSmrg ;; 72800ef0e59aSmrg 72810ef0e59aSmrg *nto* | *qnx*) 72820ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=yes 72830ef0e59aSmrg ;; 72840ef0e59aSmrg 7285d5e6aabbSmrg openbsd*) 72860ef0e59aSmrg if test -f /usr/libexec/ld.so; then 72870ef0e59aSmrg _LT_TAGVAR(hardcode_direct, $1)=yes 72880ef0e59aSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 72890ef0e59aSmrg _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 72900ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' 72910ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' 72920ef0e59aSmrg if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`"; then 72930ef0e59aSmrg _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' 72940ef0e59aSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' 72950ef0e59aSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' 72960ef0e59aSmrg fi 72970ef0e59aSmrg output_verbose_link_cmd=func_echo_all 72980ef0e59aSmrg else 72990ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=no 73000ef0e59aSmrg fi 73010ef0e59aSmrg ;; 73020ef0e59aSmrg 73030ef0e59aSmrg osf3* | osf4* | osf5*) 73040ef0e59aSmrg case $cc_basename in 73050ef0e59aSmrg KCC*) 73060ef0e59aSmrg # Kuck and Associates, Inc. (KAI) C++ Compiler 73070ef0e59aSmrg 73080ef0e59aSmrg # KCC will only create a shared library if the output file 73090ef0e59aSmrg # ends with ".so" (or ".sl" for HP-UX), so rename the library 73100ef0e59aSmrg # to its proper name (with version) after linking. 73110ef0e59aSmrg _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' 73120ef0e59aSmrg 73130ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' 73140ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)=: 73150ef0e59aSmrg 73160ef0e59aSmrg # Archives containing C++ object files must be created using 73170ef0e59aSmrg # the KAI C++ compiler. 73180ef0e59aSmrg case $host in 73190ef0e59aSmrg osf3*) _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;; 73200ef0e59aSmrg *) _LT_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' ;; 73210ef0e59aSmrg esac 73220ef0e59aSmrg ;; 73230ef0e59aSmrg RCC*) 73240ef0e59aSmrg # Rational C++ 2.4.1 73250ef0e59aSmrg # FIXME: insert proper C++ library support 73260ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=no 73270ef0e59aSmrg ;; 73280ef0e59aSmrg cxx*) 73290ef0e59aSmrg case $host in 73300ef0e59aSmrg osf3*) 73310ef0e59aSmrg _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' 73320ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $soname `test -n "$verstring" && func_echo_all "$wl-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' 73330ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' 73340ef0e59aSmrg ;; 73350ef0e59aSmrg *) 73360ef0e59aSmrg _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' 73370ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' 73380ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ 73390ef0e59aSmrg echo "-hidden">> $lib.exp~ 73400ef0e59aSmrg $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname $wl-input $wl$lib.exp `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~ 73410ef0e59aSmrg $RM $lib.exp' 73420ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' 73430ef0e59aSmrg ;; 73440ef0e59aSmrg esac 73450ef0e59aSmrg 73460ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)=: 73470ef0e59aSmrg 73480ef0e59aSmrg # Commands to make compiler produce verbose output that lists 73490ef0e59aSmrg # what "hidden" libraries, object files and flags are used when 73500ef0e59aSmrg # linking a shared library. 73510ef0e59aSmrg # 73520ef0e59aSmrg # There doesn't appear to be a way to prevent this compiler from 73530ef0e59aSmrg # explicitly linking system object files so we need to strip them 73540ef0e59aSmrg # from the output so that they don't get included in the library 73550ef0e59aSmrg # dependencies. 73560ef0e59aSmrg output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' 73570ef0e59aSmrg ;; 73580ef0e59aSmrg *) 73590ef0e59aSmrg if test yes,no = "$GXX,$with_gnu_ld"; then 73600ef0e59aSmrg _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' 73610ef0e59aSmrg case $host in 73620ef0e59aSmrg osf3*) 73630ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' 73640ef0e59aSmrg ;; 73650ef0e59aSmrg *) 73660ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' 73670ef0e59aSmrg ;; 73680ef0e59aSmrg esac 73690ef0e59aSmrg 73700ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' 73710ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)=: 73720ef0e59aSmrg 73730ef0e59aSmrg # Commands to make compiler produce verbose output that lists 73740ef0e59aSmrg # what "hidden" libraries, object files and flags are used when 73750ef0e59aSmrg # linking a shared library. 7376d5e6aabbSmrg output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP " [[-]]L"' 73770ef0e59aSmrg 73780ef0e59aSmrg else 73790ef0e59aSmrg # FIXME: insert proper C++ library support 73800ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=no 73810ef0e59aSmrg fi 73820ef0e59aSmrg ;; 73830ef0e59aSmrg esac 73840ef0e59aSmrg ;; 73850ef0e59aSmrg 73860ef0e59aSmrg psos*) 73870ef0e59aSmrg # FIXME: insert proper C++ library support 73880ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=no 73890ef0e59aSmrg ;; 73900ef0e59aSmrg 7391d5e6aabbSmrg serenity*) 7392d5e6aabbSmrg ;; 7393d5e6aabbSmrg 73940ef0e59aSmrg sunos4*) 73950ef0e59aSmrg case $cc_basename in 73960ef0e59aSmrg CC*) 73970ef0e59aSmrg # Sun C++ 4.x 73980ef0e59aSmrg # FIXME: insert proper C++ library support 73990ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=no 74000ef0e59aSmrg ;; 74010ef0e59aSmrg lcc*) 74020ef0e59aSmrg # Lucid 74030ef0e59aSmrg # FIXME: insert proper C++ library support 74040ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=no 74050ef0e59aSmrg ;; 74060ef0e59aSmrg *) 74070ef0e59aSmrg # FIXME: insert proper C++ library support 74080ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=no 74090ef0e59aSmrg ;; 74100ef0e59aSmrg esac 74110ef0e59aSmrg ;; 74120ef0e59aSmrg 74130ef0e59aSmrg solaris*) 74140ef0e59aSmrg case $cc_basename in 74150ef0e59aSmrg CC* | sunCC*) 74160ef0e59aSmrg # Sun C++ 4.2, 5.x and Centerline C++ 74170ef0e59aSmrg _LT_TAGVAR(archive_cmds_need_lc,$1)=yes 74180ef0e59aSmrg _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' 74190ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 74200ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 74210ef0e59aSmrg $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' 74220ef0e59aSmrg 74230ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 74240ef0e59aSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 74250ef0e59aSmrg case $host_os in 74260ef0e59aSmrg solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; 74270ef0e59aSmrg *) 74280ef0e59aSmrg # The compiler driver will combine and reorder linker options, 74290ef0e59aSmrg # but understands '-z linker_flag'. 74300ef0e59aSmrg # Supported since Solaris 2.6 (maybe 2.5.1?) 74310ef0e59aSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' 74320ef0e59aSmrg ;; 74330ef0e59aSmrg esac 74340ef0e59aSmrg _LT_TAGVAR(link_all_deplibs, $1)=yes 74350ef0e59aSmrg 74360ef0e59aSmrg output_verbose_link_cmd='func_echo_all' 74370ef0e59aSmrg 74380ef0e59aSmrg # Archives containing C++ object files must be created using 74390ef0e59aSmrg # "CC -xar", where "CC" is the Sun C++ compiler. This is 74400ef0e59aSmrg # necessary to make sure instantiated templates are included 74410ef0e59aSmrg # in the archive. 74420ef0e59aSmrg _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' 74430ef0e59aSmrg ;; 74440ef0e59aSmrg gcx*) 74450ef0e59aSmrg # Green Hills C++ Compiler 74460ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' 74470ef0e59aSmrg 74480ef0e59aSmrg # The C++ compiler must be used to create the archive. 74490ef0e59aSmrg _LT_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs' 74500ef0e59aSmrg ;; 74510ef0e59aSmrg *) 74520ef0e59aSmrg # GNU C++ compiler with Solaris linker 74530ef0e59aSmrg if test yes,no = "$GXX,$with_gnu_ld"; then 74540ef0e59aSmrg _LT_TAGVAR(no_undefined_flag, $1)=' $wl-z ${wl}defs' 74550ef0e59aSmrg if $CC --version | $GREP -v '^2\.7' > /dev/null; then 74560ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' 74570ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 74580ef0e59aSmrg $CC -shared $pic_flag -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' 74590ef0e59aSmrg 74600ef0e59aSmrg # Commands to make compiler produce verbose output that lists 74610ef0e59aSmrg # what "hidden" libraries, object files and flags are used when 74620ef0e59aSmrg # linking a shared library. 7463d5e6aabbSmrg output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP " [[-]]L"' 74640ef0e59aSmrg else 74650ef0e59aSmrg # g++ 2.7 appears to require '-G' NOT '-shared' on this 74660ef0e59aSmrg # platform. 74670ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' 74680ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 74690ef0e59aSmrg $CC -G -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' 74700ef0e59aSmrg 74710ef0e59aSmrg # Commands to make compiler produce verbose output that lists 74720ef0e59aSmrg # what "hidden" libraries, object files and flags are used when 74730ef0e59aSmrg # linking a shared library. 7474d5e6aabbSmrg output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP " [[-]]L"' 74750ef0e59aSmrg fi 74760ef0e59aSmrg 74770ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $wl$libdir' 74780ef0e59aSmrg case $host_os in 74790ef0e59aSmrg solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; 74800ef0e59aSmrg *) 74810ef0e59aSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract' 74820ef0e59aSmrg ;; 74830ef0e59aSmrg esac 74840ef0e59aSmrg fi 74850ef0e59aSmrg ;; 74860ef0e59aSmrg esac 74870ef0e59aSmrg ;; 74880ef0e59aSmrg 74890ef0e59aSmrg sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) 74900ef0e59aSmrg _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' 74910ef0e59aSmrg _LT_TAGVAR(archive_cmds_need_lc, $1)=no 74920ef0e59aSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 74930ef0e59aSmrg runpath_var='LD_RUN_PATH' 74940ef0e59aSmrg 74950ef0e59aSmrg case $cc_basename in 74960ef0e59aSmrg CC*) 74970ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 74980ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 74990ef0e59aSmrg ;; 75000ef0e59aSmrg *) 75010ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 75020ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 75030ef0e59aSmrg ;; 75040ef0e59aSmrg esac 75050ef0e59aSmrg ;; 75060ef0e59aSmrg 75070ef0e59aSmrg sysv5* | sco3.2v5* | sco5v6*) 75080ef0e59aSmrg # Note: We CANNOT use -z defs as we might desire, because we do not 75090ef0e59aSmrg # link with -lc, and that would cause any symbols used from libc to 75100ef0e59aSmrg # always be unresolved, which means just about no library would 75110ef0e59aSmrg # ever link correctly. If we're not using GNU ld we use -z text 75120ef0e59aSmrg # though, which does catch some bad symbols but isn't as heavy-handed 75130ef0e59aSmrg # as -z defs. 75140ef0e59aSmrg _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' 75150ef0e59aSmrg _LT_TAGVAR(allow_undefined_flag, $1)='$wl-z,nodefs' 75160ef0e59aSmrg _LT_TAGVAR(archive_cmds_need_lc, $1)=no 75170ef0e59aSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 75180ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R,$libdir' 75190ef0e59aSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)=':' 75200ef0e59aSmrg _LT_TAGVAR(link_all_deplibs, $1)=yes 75210ef0e59aSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Bexport' 75220ef0e59aSmrg runpath_var='LD_RUN_PATH' 75230ef0e59aSmrg 75240ef0e59aSmrg case $cc_basename in 75250ef0e59aSmrg CC*) 75260ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 75270ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 75280ef0e59aSmrg _LT_TAGVAR(old_archive_cmds, $1)='$CC -Tprelink_objects $oldobjs~ 75290ef0e59aSmrg '"$_LT_TAGVAR(old_archive_cmds, $1)" 75300ef0e59aSmrg _LT_TAGVAR(reload_cmds, $1)='$CC -Tprelink_objects $reload_objs~ 75310ef0e59aSmrg '"$_LT_TAGVAR(reload_cmds, $1)" 75320ef0e59aSmrg ;; 75330ef0e59aSmrg *) 75340ef0e59aSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 75350ef0e59aSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 75360ef0e59aSmrg ;; 75370ef0e59aSmrg esac 75380ef0e59aSmrg ;; 75390ef0e59aSmrg 75400ef0e59aSmrg tandem*) 75410ef0e59aSmrg case $cc_basename in 75420ef0e59aSmrg NCC*) 75430ef0e59aSmrg # NonStop-UX NCC 3.20 75440ef0e59aSmrg # FIXME: insert proper C++ library support 75450ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=no 75460ef0e59aSmrg ;; 75470ef0e59aSmrg *) 75480ef0e59aSmrg # FIXME: insert proper C++ library support 75490ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=no 75500ef0e59aSmrg ;; 75510ef0e59aSmrg esac 75520ef0e59aSmrg ;; 75530ef0e59aSmrg 75540ef0e59aSmrg vxworks*) 75550ef0e59aSmrg # FIXME: insert proper C++ library support 75560ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=no 75570ef0e59aSmrg ;; 75580ef0e59aSmrg 75590ef0e59aSmrg *) 75600ef0e59aSmrg # FIXME: insert proper C++ library support 75610ef0e59aSmrg _LT_TAGVAR(ld_shlibs, $1)=no 75620ef0e59aSmrg ;; 75630ef0e59aSmrg esac 75640ef0e59aSmrg 75650ef0e59aSmrg AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) 75660ef0e59aSmrg test no = "$_LT_TAGVAR(ld_shlibs, $1)" && can_build_shared=no 75670ef0e59aSmrg 75680ef0e59aSmrg _LT_TAGVAR(GCC, $1)=$GXX 75690ef0e59aSmrg _LT_TAGVAR(LD, $1)=$LD 75700ef0e59aSmrg 75710ef0e59aSmrg ## CAVEAT EMPTOR: 75720ef0e59aSmrg ## There is no encapsulation within the following macros, do not change 75730ef0e59aSmrg ## the running order or otherwise move them around unless you know exactly 75740ef0e59aSmrg ## what you are doing... 75750ef0e59aSmrg _LT_SYS_HIDDEN_LIBDEPS($1) 75760ef0e59aSmrg _LT_COMPILER_PIC($1) 75770ef0e59aSmrg _LT_COMPILER_C_O($1) 75780ef0e59aSmrg _LT_COMPILER_FILE_LOCKS($1) 75790ef0e59aSmrg _LT_LINKER_SHLIBS($1) 75800ef0e59aSmrg _LT_SYS_DYNAMIC_LINKER($1) 75810ef0e59aSmrg _LT_LINKER_HARDCODE_LIBPATH($1) 75820ef0e59aSmrg 75830ef0e59aSmrg _LT_CONFIG($1) 75840ef0e59aSmrg fi # test -n "$compiler" 75850ef0e59aSmrg 75860ef0e59aSmrg CC=$lt_save_CC 75870ef0e59aSmrg CFLAGS=$lt_save_CFLAGS 75880ef0e59aSmrg LDCXX=$LD 75890ef0e59aSmrg LD=$lt_save_LD 75900ef0e59aSmrg GCC=$lt_save_GCC 75910ef0e59aSmrg with_gnu_ld=$lt_save_with_gnu_ld 75920ef0e59aSmrg lt_cv_path_LDCXX=$lt_cv_path_LD 75930ef0e59aSmrg lt_cv_path_LD=$lt_save_path_LD 75940ef0e59aSmrg lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld 75950ef0e59aSmrg lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld 75960ef0e59aSmrgfi # test yes != "$_lt_caught_CXX_error" 75970ef0e59aSmrg 75980ef0e59aSmrgAC_LANG_POP 75990ef0e59aSmrg])# _LT_LANG_CXX_CONFIG 76000ef0e59aSmrg 76010ef0e59aSmrg 76020ef0e59aSmrg# _LT_FUNC_STRIPNAME_CNF 76030ef0e59aSmrg# ---------------------- 76040ef0e59aSmrg# func_stripname_cnf prefix suffix name 76050ef0e59aSmrg# strip PREFIX and SUFFIX off of NAME. 76060ef0e59aSmrg# PREFIX and SUFFIX must not contain globbing or regex special 76070ef0e59aSmrg# characters, hashes, percent signs, but SUFFIX may contain a leading 76080ef0e59aSmrg# dot (in which case that matches only a dot). 76090ef0e59aSmrg# 76100ef0e59aSmrg# This function is identical to the (non-XSI) version of func_stripname, 76110ef0e59aSmrg# except this one can be used by m4 code that may be executed by configure, 76120ef0e59aSmrg# rather than the libtool script. 76130ef0e59aSmrgm4_defun([_LT_FUNC_STRIPNAME_CNF],[dnl 76140ef0e59aSmrgAC_REQUIRE([_LT_DECL_SED]) 76150ef0e59aSmrgAC_REQUIRE([_LT_PROG_ECHO_BACKSLASH]) 76160ef0e59aSmrgfunc_stripname_cnf () 76170ef0e59aSmrg{ 76180ef0e59aSmrg case @S|@2 in 76190ef0e59aSmrg .*) func_stripname_result=`$ECHO "@S|@3" | $SED "s%^@S|@1%%; s%\\\\@S|@2\$%%"`;; 76200ef0e59aSmrg *) func_stripname_result=`$ECHO "@S|@3" | $SED "s%^@S|@1%%; s%@S|@2\$%%"`;; 76210ef0e59aSmrg esac 76220ef0e59aSmrg} # func_stripname_cnf 76230ef0e59aSmrg])# _LT_FUNC_STRIPNAME_CNF 76240ef0e59aSmrg 76250ef0e59aSmrg 76260ef0e59aSmrg# _LT_SYS_HIDDEN_LIBDEPS([TAGNAME]) 76270ef0e59aSmrg# --------------------------------- 76280ef0e59aSmrg# Figure out "hidden" library dependencies from verbose 76290ef0e59aSmrg# compiler output when linking a shared library. 76300ef0e59aSmrg# Parse the compiler output and extract the necessary 76310ef0e59aSmrg# objects, libraries and library flags. 76320ef0e59aSmrgm4_defun([_LT_SYS_HIDDEN_LIBDEPS], 76330ef0e59aSmrg[m4_require([_LT_FILEUTILS_DEFAULTS])dnl 76340ef0e59aSmrgAC_REQUIRE([_LT_FUNC_STRIPNAME_CNF])dnl 76350ef0e59aSmrg# Dependencies to place before and after the object being linked: 76360ef0e59aSmrg_LT_TAGVAR(predep_objects, $1)= 76370ef0e59aSmrg_LT_TAGVAR(postdep_objects, $1)= 76380ef0e59aSmrg_LT_TAGVAR(predeps, $1)= 76390ef0e59aSmrg_LT_TAGVAR(postdeps, $1)= 76400ef0e59aSmrg_LT_TAGVAR(compiler_lib_search_path, $1)= 76410ef0e59aSmrg 76420ef0e59aSmrgdnl we can't use the lt_simple_compile_test_code here, 76430ef0e59aSmrgdnl because it contains code intended for an executable, 76440ef0e59aSmrgdnl not a library. It's possible we should let each 76450ef0e59aSmrgdnl tag define a new lt_????_link_test_code variable, 76460ef0e59aSmrgdnl but it's only used here... 76470ef0e59aSmrgm4_if([$1], [], [cat > conftest.$ac_ext <<_LT_EOF 76480ef0e59aSmrgint a; 76490ef0e59aSmrgvoid foo (void) { a = 0; } 76500ef0e59aSmrg_LT_EOF 76510ef0e59aSmrg], [$1], [CXX], [cat > conftest.$ac_ext <<_LT_EOF 76520ef0e59aSmrgclass Foo 76530ef0e59aSmrg{ 76540ef0e59aSmrgpublic: 76550ef0e59aSmrg Foo (void) { a = 0; } 76560ef0e59aSmrgprivate: 76570ef0e59aSmrg int a; 76580ef0e59aSmrg}; 76590ef0e59aSmrg_LT_EOF 76600ef0e59aSmrg], [$1], [F77], [cat > conftest.$ac_ext <<_LT_EOF 76610ef0e59aSmrg subroutine foo 76620ef0e59aSmrg implicit none 76630ef0e59aSmrg integer*4 a 76640ef0e59aSmrg a=0 76650ef0e59aSmrg return 76660ef0e59aSmrg end 76670ef0e59aSmrg_LT_EOF 76680ef0e59aSmrg], [$1], [FC], [cat > conftest.$ac_ext <<_LT_EOF 76690ef0e59aSmrg subroutine foo 76700ef0e59aSmrg implicit none 76710ef0e59aSmrg integer a 76720ef0e59aSmrg a=0 76730ef0e59aSmrg return 76740ef0e59aSmrg end 76750ef0e59aSmrg_LT_EOF 76760ef0e59aSmrg], [$1], [GCJ], [cat > conftest.$ac_ext <<_LT_EOF 76770ef0e59aSmrgpublic class foo { 76780ef0e59aSmrg private int a; 76790ef0e59aSmrg public void bar (void) { 76800ef0e59aSmrg a = 0; 76810ef0e59aSmrg } 76820ef0e59aSmrg}; 76830ef0e59aSmrg_LT_EOF 76840ef0e59aSmrg], [$1], [GO], [cat > conftest.$ac_ext <<_LT_EOF 76850ef0e59aSmrgpackage foo 76860ef0e59aSmrgfunc foo() { 76870ef0e59aSmrg} 76880ef0e59aSmrg_LT_EOF 76890ef0e59aSmrg]) 76900ef0e59aSmrg 76910ef0e59aSmrg_lt_libdeps_save_CFLAGS=$CFLAGS 76920ef0e59aSmrgcase "$CC $CFLAGS " in #( 76930ef0e59aSmrg*\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;; 76940ef0e59aSmrg*\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;; 76950ef0e59aSmrg*\ -fuse-linker-plugin*\ *) CFLAGS="$CFLAGS -fno-use-linker-plugin" ;; 76960ef0e59aSmrgesac 76970ef0e59aSmrg 76980ef0e59aSmrgdnl Parse the compiler output and extract the necessary 76990ef0e59aSmrgdnl objects, libraries and library flags. 77000ef0e59aSmrgif AC_TRY_EVAL(ac_compile); then 77010ef0e59aSmrg # Parse the compiler output and extract the necessary 77020ef0e59aSmrg # objects, libraries and library flags. 77030ef0e59aSmrg 77040ef0e59aSmrg # Sentinel used to keep track of whether or not we are before 77050ef0e59aSmrg # the conftest object file. 77060ef0e59aSmrg pre_test_object_deps_done=no 77070ef0e59aSmrg 77080ef0e59aSmrg for p in `eval "$output_verbose_link_cmd"`; do 77090ef0e59aSmrg case $prev$p in 77100ef0e59aSmrg 77110ef0e59aSmrg -L* | -R* | -l*) 7712d5e6aabbSmrg # Some compilers place space between "-{L,R,l}" and the path. 77130ef0e59aSmrg # Remove the space. 7714d5e6aabbSmrg if test x-L = x"$p" || 7715d5e6aabbSmrg test x-R = x"$p" || 7716d5e6aabbSmrg test x-l = x"$p"; then 77170ef0e59aSmrg prev=$p 77180ef0e59aSmrg continue 77190ef0e59aSmrg fi 77200ef0e59aSmrg 77210ef0e59aSmrg # Expand the sysroot to ease extracting the directories later. 77220ef0e59aSmrg if test -z "$prev"; then 77230ef0e59aSmrg case $p in 77240ef0e59aSmrg -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;; 77250ef0e59aSmrg -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;; 77260ef0e59aSmrg -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;; 77270ef0e59aSmrg esac 77280ef0e59aSmrg fi 77290ef0e59aSmrg case $p in 77300ef0e59aSmrg =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;; 77310ef0e59aSmrg esac 77320ef0e59aSmrg if test no = "$pre_test_object_deps_done"; then 77330ef0e59aSmrg case $prev in 77340ef0e59aSmrg -L | -R) 77350ef0e59aSmrg # Internal compiler library paths should come after those 77360ef0e59aSmrg # provided the user. The postdeps already come after the 77370ef0e59aSmrg # user supplied libs so there is no need to process them. 77380ef0e59aSmrg if test -z "$_LT_TAGVAR(compiler_lib_search_path, $1)"; then 77390ef0e59aSmrg _LT_TAGVAR(compiler_lib_search_path, $1)=$prev$p 77400ef0e59aSmrg else 77410ef0e59aSmrg _LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} $prev$p" 77420ef0e59aSmrg fi 77430ef0e59aSmrg ;; 77440ef0e59aSmrg # The "-l" case would never come before the object being 77450ef0e59aSmrg # linked, so don't bother handling this case. 77460ef0e59aSmrg esac 77470ef0e59aSmrg else 77480ef0e59aSmrg if test -z "$_LT_TAGVAR(postdeps, $1)"; then 77490ef0e59aSmrg _LT_TAGVAR(postdeps, $1)=$prev$p 77500ef0e59aSmrg else 77510ef0e59aSmrg _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} $prev$p" 77520ef0e59aSmrg fi 77530ef0e59aSmrg fi 77540ef0e59aSmrg prev= 77550ef0e59aSmrg ;; 77560ef0e59aSmrg 77570ef0e59aSmrg *.lto.$objext) ;; # Ignore GCC LTO objects 77580ef0e59aSmrg *.$objext) 77590ef0e59aSmrg # This assumes that the test object file only shows up 77600ef0e59aSmrg # once in the compiler output. 77610ef0e59aSmrg if test "$p" = "conftest.$objext"; then 77620ef0e59aSmrg pre_test_object_deps_done=yes 77630ef0e59aSmrg continue 77640ef0e59aSmrg fi 77650ef0e59aSmrg 77660ef0e59aSmrg if test no = "$pre_test_object_deps_done"; then 77670ef0e59aSmrg if test -z "$_LT_TAGVAR(predep_objects, $1)"; then 77680ef0e59aSmrg _LT_TAGVAR(predep_objects, $1)=$p 77690ef0e59aSmrg else 77700ef0e59aSmrg _LT_TAGVAR(predep_objects, $1)="$_LT_TAGVAR(predep_objects, $1) $p" 77710ef0e59aSmrg fi 77720ef0e59aSmrg else 77730ef0e59aSmrg if test -z "$_LT_TAGVAR(postdep_objects, $1)"; then 77740ef0e59aSmrg _LT_TAGVAR(postdep_objects, $1)=$p 77750ef0e59aSmrg else 77760ef0e59aSmrg _LT_TAGVAR(postdep_objects, $1)="$_LT_TAGVAR(postdep_objects, $1) $p" 77770ef0e59aSmrg fi 77780ef0e59aSmrg fi 77790ef0e59aSmrg ;; 77800ef0e59aSmrg 77810ef0e59aSmrg *) ;; # Ignore the rest. 77820ef0e59aSmrg 77830ef0e59aSmrg esac 77840ef0e59aSmrg done 77850ef0e59aSmrg 77860ef0e59aSmrg # Clean up. 77870ef0e59aSmrg rm -f a.out a.exe 77880ef0e59aSmrgelse 77890ef0e59aSmrg echo "libtool.m4: error: problem compiling $1 test program" 77900ef0e59aSmrgfi 77910ef0e59aSmrg 77920ef0e59aSmrg$RM -f confest.$objext 77930ef0e59aSmrgCFLAGS=$_lt_libdeps_save_CFLAGS 77940ef0e59aSmrg 77950ef0e59aSmrg# PORTME: override above test on systems where it is broken 77960ef0e59aSmrgm4_if([$1], [CXX], 77970ef0e59aSmrg[case $host_os in 77980ef0e59aSmrginterix[[3-9]]*) 77990ef0e59aSmrg # Interix 3.5 installs completely hosed .la files for C++, so rather than 78000ef0e59aSmrg # hack all around it, let's just trust "g++" to DTRT. 78010ef0e59aSmrg _LT_TAGVAR(predep_objects,$1)= 78020ef0e59aSmrg _LT_TAGVAR(postdep_objects,$1)= 78030ef0e59aSmrg _LT_TAGVAR(postdeps,$1)= 78040ef0e59aSmrg ;; 78050ef0e59aSmrgesac 78060ef0e59aSmrg]) 78070ef0e59aSmrg 78080ef0e59aSmrgcase " $_LT_TAGVAR(postdeps, $1) " in 78090ef0e59aSmrg*" -lc "*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;; 78100ef0e59aSmrgesac 78110ef0e59aSmrg _LT_TAGVAR(compiler_lib_search_dirs, $1)= 78120ef0e59aSmrgif test -n "${_LT_TAGVAR(compiler_lib_search_path, $1)}"; then 78130ef0e59aSmrg _LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | $SED -e 's! -L! !g' -e 's!^ !!'` 78140ef0e59aSmrgfi 78150ef0e59aSmrg_LT_TAGDECL([], [compiler_lib_search_dirs], [1], 78160ef0e59aSmrg [The directories searched by this compiler when creating a shared library]) 78170ef0e59aSmrg_LT_TAGDECL([], [predep_objects], [1], 78180ef0e59aSmrg [Dependencies to place before and after the objects being linked to 78190ef0e59aSmrg create a shared library]) 78200ef0e59aSmrg_LT_TAGDECL([], [postdep_objects], [1]) 78210ef0e59aSmrg_LT_TAGDECL([], [predeps], [1]) 78220ef0e59aSmrg_LT_TAGDECL([], [postdeps], [1]) 78230ef0e59aSmrg_LT_TAGDECL([], [compiler_lib_search_path], [1], 78240ef0e59aSmrg [The library search path used internally by the compiler when linking 78250ef0e59aSmrg a shared library]) 78260ef0e59aSmrg])# _LT_SYS_HIDDEN_LIBDEPS 78270ef0e59aSmrg 78280ef0e59aSmrg 78290ef0e59aSmrg# _LT_LANG_F77_CONFIG([TAG]) 78300ef0e59aSmrg# -------------------------- 78310ef0e59aSmrg# Ensure that the configuration variables for a Fortran 77 compiler are 78320ef0e59aSmrg# suitably defined. These variables are subsequently used by _LT_CONFIG 78330ef0e59aSmrg# to write the compiler configuration to 'libtool'. 78340ef0e59aSmrgm4_defun([_LT_LANG_F77_CONFIG], 78350ef0e59aSmrg[AC_LANG_PUSH(Fortran 77) 78360ef0e59aSmrgif test -z "$F77" || test no = "$F77"; then 78370ef0e59aSmrg _lt_disable_F77=yes 78380ef0e59aSmrgfi 78390ef0e59aSmrg 78400ef0e59aSmrg_LT_TAGVAR(archive_cmds_need_lc, $1)=no 78410ef0e59aSmrg_LT_TAGVAR(allow_undefined_flag, $1)= 78420ef0e59aSmrg_LT_TAGVAR(always_export_symbols, $1)=no 78430ef0e59aSmrg_LT_TAGVAR(archive_expsym_cmds, $1)= 78440ef0e59aSmrg_LT_TAGVAR(export_dynamic_flag_spec, $1)= 78450ef0e59aSmrg_LT_TAGVAR(hardcode_direct, $1)=no 78460ef0e59aSmrg_LT_TAGVAR(hardcode_direct_absolute, $1)=no 78470ef0e59aSmrg_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 78480ef0e59aSmrg_LT_TAGVAR(hardcode_libdir_separator, $1)= 78490ef0e59aSmrg_LT_TAGVAR(hardcode_minus_L, $1)=no 78500ef0e59aSmrg_LT_TAGVAR(hardcode_automatic, $1)=no 78510ef0e59aSmrg_LT_TAGVAR(inherit_rpath, $1)=no 78520ef0e59aSmrg_LT_TAGVAR(module_cmds, $1)= 78530ef0e59aSmrg_LT_TAGVAR(module_expsym_cmds, $1)= 78540ef0e59aSmrg_LT_TAGVAR(link_all_deplibs, $1)=unknown 78550ef0e59aSmrg_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 78560ef0e59aSmrg_LT_TAGVAR(reload_flag, $1)=$reload_flag 78570ef0e59aSmrg_LT_TAGVAR(reload_cmds, $1)=$reload_cmds 78580ef0e59aSmrg_LT_TAGVAR(no_undefined_flag, $1)= 78590ef0e59aSmrg_LT_TAGVAR(whole_archive_flag_spec, $1)= 78600ef0e59aSmrg_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no 78610ef0e59aSmrg 78620ef0e59aSmrg# Source file extension for f77 test sources. 78630ef0e59aSmrgac_ext=f 78640ef0e59aSmrg 78650ef0e59aSmrg# Object file extension for compiled f77 test sources. 78660ef0e59aSmrgobjext=o 78670ef0e59aSmrg_LT_TAGVAR(objext, $1)=$objext 78680ef0e59aSmrg 78690ef0e59aSmrg# No sense in running all these tests if we already determined that 78700ef0e59aSmrg# the F77 compiler isn't working. Some variables (like enable_shared) 78710ef0e59aSmrg# are currently assumed to apply to all compilers on this platform, 78720ef0e59aSmrg# and will be corrupted by setting them based on a non-working compiler. 78730ef0e59aSmrgif test yes != "$_lt_disable_F77"; then 78740ef0e59aSmrg # Code to be used in simple compile tests 78750ef0e59aSmrg lt_simple_compile_test_code="\ 78760ef0e59aSmrg subroutine t 78770ef0e59aSmrg return 78780ef0e59aSmrg end 78790ef0e59aSmrg" 78800ef0e59aSmrg 78810ef0e59aSmrg # Code to be used in simple link tests 78820ef0e59aSmrg lt_simple_link_test_code="\ 78830ef0e59aSmrg program t 78840ef0e59aSmrg end 78850ef0e59aSmrg" 78860ef0e59aSmrg 78870ef0e59aSmrg # ltmain only uses $CC for tagged configurations so make sure $CC is set. 78880ef0e59aSmrg _LT_TAG_COMPILER 78890ef0e59aSmrg 78900ef0e59aSmrg # save warnings/boilerplate of simple test code 78910ef0e59aSmrg _LT_COMPILER_BOILERPLATE 78920ef0e59aSmrg _LT_LINKER_BOILERPLATE 78930ef0e59aSmrg 78940ef0e59aSmrg # Allow CC to be a program name with arguments. 78950ef0e59aSmrg lt_save_CC=$CC 78960ef0e59aSmrg lt_save_GCC=$GCC 78970ef0e59aSmrg lt_save_CFLAGS=$CFLAGS 78980ef0e59aSmrg CC=${F77-"f77"} 78990ef0e59aSmrg CFLAGS=$FFLAGS 79000ef0e59aSmrg compiler=$CC 79010ef0e59aSmrg _LT_TAGVAR(compiler, $1)=$CC 79020ef0e59aSmrg _LT_CC_BASENAME([$compiler]) 79030ef0e59aSmrg GCC=$G77 79040ef0e59aSmrg if test -n "$compiler"; then 79050ef0e59aSmrg AC_MSG_CHECKING([if libtool supports shared libraries]) 79060ef0e59aSmrg AC_MSG_RESULT([$can_build_shared]) 79070ef0e59aSmrg 79080ef0e59aSmrg AC_MSG_CHECKING([whether to build shared libraries]) 79090ef0e59aSmrg test no = "$can_build_shared" && enable_shared=no 79100ef0e59aSmrg 79110ef0e59aSmrg # On AIX, shared libraries and static libraries use the same namespace, and 79120ef0e59aSmrg # are all built from PIC. 79130ef0e59aSmrg case $host_os in 79140ef0e59aSmrg aix3*) 79150ef0e59aSmrg test yes = "$enable_shared" && enable_static=no 79160ef0e59aSmrg if test -n "$RANLIB"; then 79170ef0e59aSmrg archive_cmds="$archive_cmds~\$RANLIB \$lib" 79180ef0e59aSmrg postinstall_cmds='$RANLIB $lib' 79190ef0e59aSmrg fi 79200ef0e59aSmrg ;; 79210ef0e59aSmrg aix[[4-9]]*) 79220ef0e59aSmrg if test ia64 != "$host_cpu"; then 79230ef0e59aSmrg case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in 79240ef0e59aSmrg yes,aix,yes) ;; # shared object as lib.so file only 79250ef0e59aSmrg yes,svr4,*) ;; # shared object as lib.so archive member only 79260ef0e59aSmrg yes,*) enable_static=no ;; # shared object in lib.a archive as well 79270ef0e59aSmrg esac 79280ef0e59aSmrg fi 79290ef0e59aSmrg ;; 79300ef0e59aSmrg esac 79310ef0e59aSmrg AC_MSG_RESULT([$enable_shared]) 79320ef0e59aSmrg 79330ef0e59aSmrg AC_MSG_CHECKING([whether to build static libraries]) 79340ef0e59aSmrg # Make sure either enable_shared or enable_static is yes. 79350ef0e59aSmrg test yes = "$enable_shared" || enable_static=yes 79360ef0e59aSmrg AC_MSG_RESULT([$enable_static]) 79370ef0e59aSmrg 79380ef0e59aSmrg _LT_TAGVAR(GCC, $1)=$G77 79390ef0e59aSmrg _LT_TAGVAR(LD, $1)=$LD 79400ef0e59aSmrg 79410ef0e59aSmrg ## CAVEAT EMPTOR: 79420ef0e59aSmrg ## There is no encapsulation within the following macros, do not change 79430ef0e59aSmrg ## the running order or otherwise move them around unless you know exactly 79440ef0e59aSmrg ## what you are doing... 79450ef0e59aSmrg _LT_COMPILER_PIC($1) 79460ef0e59aSmrg _LT_COMPILER_C_O($1) 79470ef0e59aSmrg _LT_COMPILER_FILE_LOCKS($1) 79480ef0e59aSmrg _LT_LINKER_SHLIBS($1) 79490ef0e59aSmrg _LT_SYS_DYNAMIC_LINKER($1) 79500ef0e59aSmrg _LT_LINKER_HARDCODE_LIBPATH($1) 79510ef0e59aSmrg 79520ef0e59aSmrg _LT_CONFIG($1) 79530ef0e59aSmrg fi # test -n "$compiler" 79540ef0e59aSmrg 79550ef0e59aSmrg GCC=$lt_save_GCC 79560ef0e59aSmrg CC=$lt_save_CC 79570ef0e59aSmrg CFLAGS=$lt_save_CFLAGS 79580ef0e59aSmrgfi # test yes != "$_lt_disable_F77" 79590ef0e59aSmrg 79600ef0e59aSmrgAC_LANG_POP 79610ef0e59aSmrg])# _LT_LANG_F77_CONFIG 79620ef0e59aSmrg 79630ef0e59aSmrg 79640ef0e59aSmrg# _LT_LANG_FC_CONFIG([TAG]) 79650ef0e59aSmrg# ------------------------- 79660ef0e59aSmrg# Ensure that the configuration variables for a Fortran compiler are 79670ef0e59aSmrg# suitably defined. These variables are subsequently used by _LT_CONFIG 79680ef0e59aSmrg# to write the compiler configuration to 'libtool'. 79690ef0e59aSmrgm4_defun([_LT_LANG_FC_CONFIG], 79700ef0e59aSmrg[AC_LANG_PUSH(Fortran) 79710ef0e59aSmrg 79720ef0e59aSmrgif test -z "$FC" || test no = "$FC"; then 79730ef0e59aSmrg _lt_disable_FC=yes 79740ef0e59aSmrgfi 79750ef0e59aSmrg 79760ef0e59aSmrg_LT_TAGVAR(archive_cmds_need_lc, $1)=no 79770ef0e59aSmrg_LT_TAGVAR(allow_undefined_flag, $1)= 79780ef0e59aSmrg_LT_TAGVAR(always_export_symbols, $1)=no 79790ef0e59aSmrg_LT_TAGVAR(archive_expsym_cmds, $1)= 79800ef0e59aSmrg_LT_TAGVAR(export_dynamic_flag_spec, $1)= 79810ef0e59aSmrg_LT_TAGVAR(hardcode_direct, $1)=no 79820ef0e59aSmrg_LT_TAGVAR(hardcode_direct_absolute, $1)=no 79830ef0e59aSmrg_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 79840ef0e59aSmrg_LT_TAGVAR(hardcode_libdir_separator, $1)= 79850ef0e59aSmrg_LT_TAGVAR(hardcode_minus_L, $1)=no 79860ef0e59aSmrg_LT_TAGVAR(hardcode_automatic, $1)=no 79870ef0e59aSmrg_LT_TAGVAR(inherit_rpath, $1)=no 79880ef0e59aSmrg_LT_TAGVAR(module_cmds, $1)= 79890ef0e59aSmrg_LT_TAGVAR(module_expsym_cmds, $1)= 79900ef0e59aSmrg_LT_TAGVAR(link_all_deplibs, $1)=unknown 79910ef0e59aSmrg_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 79920ef0e59aSmrg_LT_TAGVAR(reload_flag, $1)=$reload_flag 79930ef0e59aSmrg_LT_TAGVAR(reload_cmds, $1)=$reload_cmds 79940ef0e59aSmrg_LT_TAGVAR(no_undefined_flag, $1)= 79950ef0e59aSmrg_LT_TAGVAR(whole_archive_flag_spec, $1)= 79960ef0e59aSmrg_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no 79970ef0e59aSmrg 79980ef0e59aSmrg# Source file extension for fc test sources. 79990ef0e59aSmrgac_ext=${ac_fc_srcext-f} 80000ef0e59aSmrg 80010ef0e59aSmrg# Object file extension for compiled fc test sources. 80020ef0e59aSmrgobjext=o 80030ef0e59aSmrg_LT_TAGVAR(objext, $1)=$objext 80040ef0e59aSmrg 80050ef0e59aSmrg# No sense in running all these tests if we already determined that 80060ef0e59aSmrg# the FC compiler isn't working. Some variables (like enable_shared) 80070ef0e59aSmrg# are currently assumed to apply to all compilers on this platform, 80080ef0e59aSmrg# and will be corrupted by setting them based on a non-working compiler. 80090ef0e59aSmrgif test yes != "$_lt_disable_FC"; then 80100ef0e59aSmrg # Code to be used in simple compile tests 80110ef0e59aSmrg lt_simple_compile_test_code="\ 80120ef0e59aSmrg subroutine t 80130ef0e59aSmrg return 80140ef0e59aSmrg end 80150ef0e59aSmrg" 80160ef0e59aSmrg 80170ef0e59aSmrg # Code to be used in simple link tests 80180ef0e59aSmrg lt_simple_link_test_code="\ 80190ef0e59aSmrg program t 80200ef0e59aSmrg end 80210ef0e59aSmrg" 80220ef0e59aSmrg 80230ef0e59aSmrg # ltmain only uses $CC for tagged configurations so make sure $CC is set. 80240ef0e59aSmrg _LT_TAG_COMPILER 80250ef0e59aSmrg 80260ef0e59aSmrg # save warnings/boilerplate of simple test code 80270ef0e59aSmrg _LT_COMPILER_BOILERPLATE 80280ef0e59aSmrg _LT_LINKER_BOILERPLATE 80290ef0e59aSmrg 80300ef0e59aSmrg # Allow CC to be a program name with arguments. 80310ef0e59aSmrg lt_save_CC=$CC 80320ef0e59aSmrg lt_save_GCC=$GCC 80330ef0e59aSmrg lt_save_CFLAGS=$CFLAGS 80340ef0e59aSmrg CC=${FC-"f95"} 80350ef0e59aSmrg CFLAGS=$FCFLAGS 80360ef0e59aSmrg compiler=$CC 80370ef0e59aSmrg GCC=$ac_cv_fc_compiler_gnu 80380ef0e59aSmrg 80390ef0e59aSmrg _LT_TAGVAR(compiler, $1)=$CC 80400ef0e59aSmrg _LT_CC_BASENAME([$compiler]) 80410ef0e59aSmrg 80420ef0e59aSmrg if test -n "$compiler"; then 80430ef0e59aSmrg AC_MSG_CHECKING([if libtool supports shared libraries]) 80440ef0e59aSmrg AC_MSG_RESULT([$can_build_shared]) 80450ef0e59aSmrg 80460ef0e59aSmrg AC_MSG_CHECKING([whether to build shared libraries]) 80470ef0e59aSmrg test no = "$can_build_shared" && enable_shared=no 80480ef0e59aSmrg 80490ef0e59aSmrg # On AIX, shared libraries and static libraries use the same namespace, and 80500ef0e59aSmrg # are all built from PIC. 80510ef0e59aSmrg case $host_os in 80520ef0e59aSmrg aix3*) 80530ef0e59aSmrg test yes = "$enable_shared" && enable_static=no 80540ef0e59aSmrg if test -n "$RANLIB"; then 80550ef0e59aSmrg archive_cmds="$archive_cmds~\$RANLIB \$lib" 80560ef0e59aSmrg postinstall_cmds='$RANLIB $lib' 80570ef0e59aSmrg fi 80580ef0e59aSmrg ;; 80590ef0e59aSmrg aix[[4-9]]*) 80600ef0e59aSmrg if test ia64 != "$host_cpu"; then 80610ef0e59aSmrg case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in 80620ef0e59aSmrg yes,aix,yes) ;; # shared object as lib.so file only 80630ef0e59aSmrg yes,svr4,*) ;; # shared object as lib.so archive member only 80640ef0e59aSmrg yes,*) enable_static=no ;; # shared object in lib.a archive as well 80650ef0e59aSmrg esac 80660ef0e59aSmrg fi 80670ef0e59aSmrg ;; 80680ef0e59aSmrg esac 80690ef0e59aSmrg AC_MSG_RESULT([$enable_shared]) 80700ef0e59aSmrg 80710ef0e59aSmrg AC_MSG_CHECKING([whether to build static libraries]) 80720ef0e59aSmrg # Make sure either enable_shared or enable_static is yes. 80730ef0e59aSmrg test yes = "$enable_shared" || enable_static=yes 80740ef0e59aSmrg AC_MSG_RESULT([$enable_static]) 80750ef0e59aSmrg 80760ef0e59aSmrg _LT_TAGVAR(GCC, $1)=$ac_cv_fc_compiler_gnu 80770ef0e59aSmrg _LT_TAGVAR(LD, $1)=$LD 80780ef0e59aSmrg 80790ef0e59aSmrg ## CAVEAT EMPTOR: 80800ef0e59aSmrg ## There is no encapsulation within the following macros, do not change 80810ef0e59aSmrg ## the running order or otherwise move them around unless you know exactly 80820ef0e59aSmrg ## what you are doing... 80830ef0e59aSmrg _LT_SYS_HIDDEN_LIBDEPS($1) 80840ef0e59aSmrg _LT_COMPILER_PIC($1) 80850ef0e59aSmrg _LT_COMPILER_C_O($1) 80860ef0e59aSmrg _LT_COMPILER_FILE_LOCKS($1) 80870ef0e59aSmrg _LT_LINKER_SHLIBS($1) 80880ef0e59aSmrg _LT_SYS_DYNAMIC_LINKER($1) 80890ef0e59aSmrg _LT_LINKER_HARDCODE_LIBPATH($1) 80900ef0e59aSmrg 80910ef0e59aSmrg _LT_CONFIG($1) 80920ef0e59aSmrg fi # test -n "$compiler" 80930ef0e59aSmrg 80940ef0e59aSmrg GCC=$lt_save_GCC 80950ef0e59aSmrg CC=$lt_save_CC 80960ef0e59aSmrg CFLAGS=$lt_save_CFLAGS 80970ef0e59aSmrgfi # test yes != "$_lt_disable_FC" 80980ef0e59aSmrg 80990ef0e59aSmrgAC_LANG_POP 81000ef0e59aSmrg])# _LT_LANG_FC_CONFIG 81010ef0e59aSmrg 81020ef0e59aSmrg 81030ef0e59aSmrg# _LT_LANG_GCJ_CONFIG([TAG]) 81040ef0e59aSmrg# -------------------------- 81050ef0e59aSmrg# Ensure that the configuration variables for the GNU Java Compiler compiler 81060ef0e59aSmrg# are suitably defined. These variables are subsequently used by _LT_CONFIG 81070ef0e59aSmrg# to write the compiler configuration to 'libtool'. 81080ef0e59aSmrgm4_defun([_LT_LANG_GCJ_CONFIG], 81090ef0e59aSmrg[AC_REQUIRE([LT_PROG_GCJ])dnl 81100ef0e59aSmrgAC_LANG_SAVE 81110ef0e59aSmrg 81120ef0e59aSmrg# Source file extension for Java test sources. 81130ef0e59aSmrgac_ext=java 81140ef0e59aSmrg 81150ef0e59aSmrg# Object file extension for compiled Java test sources. 81160ef0e59aSmrgobjext=o 81170ef0e59aSmrg_LT_TAGVAR(objext, $1)=$objext 81180ef0e59aSmrg 81190ef0e59aSmrg# Code to be used in simple compile tests 81200ef0e59aSmrglt_simple_compile_test_code="class foo {}" 81210ef0e59aSmrg 81220ef0e59aSmrg# Code to be used in simple link tests 81230ef0e59aSmrglt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }' 81240ef0e59aSmrg 81250ef0e59aSmrg# ltmain only uses $CC for tagged configurations so make sure $CC is set. 81260ef0e59aSmrg_LT_TAG_COMPILER 81270ef0e59aSmrg 81280ef0e59aSmrg# save warnings/boilerplate of simple test code 81290ef0e59aSmrg_LT_COMPILER_BOILERPLATE 81300ef0e59aSmrg_LT_LINKER_BOILERPLATE 81310ef0e59aSmrg 81320ef0e59aSmrg# Allow CC to be a program name with arguments. 81330ef0e59aSmrglt_save_CC=$CC 81340ef0e59aSmrglt_save_CFLAGS=$CFLAGS 81350ef0e59aSmrglt_save_GCC=$GCC 81360ef0e59aSmrgGCC=yes 81370ef0e59aSmrgCC=${GCJ-"gcj"} 81380ef0e59aSmrgCFLAGS=$GCJFLAGS 81390ef0e59aSmrgcompiler=$CC 81400ef0e59aSmrg_LT_TAGVAR(compiler, $1)=$CC 81410ef0e59aSmrg_LT_TAGVAR(LD, $1)=$LD 81420ef0e59aSmrg_LT_CC_BASENAME([$compiler]) 81430ef0e59aSmrg 81440ef0e59aSmrg# GCJ did not exist at the time GCC didn't implicitly link libc in. 81450ef0e59aSmrg_LT_TAGVAR(archive_cmds_need_lc, $1)=no 81460ef0e59aSmrg 81470ef0e59aSmrg_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 81480ef0e59aSmrg_LT_TAGVAR(reload_flag, $1)=$reload_flag 81490ef0e59aSmrg_LT_TAGVAR(reload_cmds, $1)=$reload_cmds 81500ef0e59aSmrg 81510ef0e59aSmrg## CAVEAT EMPTOR: 81520ef0e59aSmrg## There is no encapsulation within the following macros, do not change 81530ef0e59aSmrg## the running order or otherwise move them around unless you know exactly 81540ef0e59aSmrg## what you are doing... 81550ef0e59aSmrgif test -n "$compiler"; then 81560ef0e59aSmrg _LT_COMPILER_NO_RTTI($1) 81570ef0e59aSmrg _LT_COMPILER_PIC($1) 81580ef0e59aSmrg _LT_COMPILER_C_O($1) 81590ef0e59aSmrg _LT_COMPILER_FILE_LOCKS($1) 81600ef0e59aSmrg _LT_LINKER_SHLIBS($1) 81610ef0e59aSmrg _LT_LINKER_HARDCODE_LIBPATH($1) 81620ef0e59aSmrg 81630ef0e59aSmrg _LT_CONFIG($1) 81640ef0e59aSmrgfi 81650ef0e59aSmrg 81660ef0e59aSmrgAC_LANG_RESTORE 81670ef0e59aSmrg 81680ef0e59aSmrgGCC=$lt_save_GCC 81690ef0e59aSmrgCC=$lt_save_CC 81700ef0e59aSmrgCFLAGS=$lt_save_CFLAGS 81710ef0e59aSmrg])# _LT_LANG_GCJ_CONFIG 81720ef0e59aSmrg 81730ef0e59aSmrg 81740ef0e59aSmrg# _LT_LANG_GO_CONFIG([TAG]) 81750ef0e59aSmrg# -------------------------- 81760ef0e59aSmrg# Ensure that the configuration variables for the GNU Go compiler 81770ef0e59aSmrg# are suitably defined. These variables are subsequently used by _LT_CONFIG 81780ef0e59aSmrg# to write the compiler configuration to 'libtool'. 81790ef0e59aSmrgm4_defun([_LT_LANG_GO_CONFIG], 81800ef0e59aSmrg[AC_REQUIRE([LT_PROG_GO])dnl 81810ef0e59aSmrgAC_LANG_SAVE 81820ef0e59aSmrg 81830ef0e59aSmrg# Source file extension for Go test sources. 81840ef0e59aSmrgac_ext=go 81850ef0e59aSmrg 81860ef0e59aSmrg# Object file extension for compiled Go test sources. 81870ef0e59aSmrgobjext=o 81880ef0e59aSmrg_LT_TAGVAR(objext, $1)=$objext 81890ef0e59aSmrg 81900ef0e59aSmrg# Code to be used in simple compile tests 81910ef0e59aSmrglt_simple_compile_test_code="package main; func main() { }" 81920ef0e59aSmrg 81930ef0e59aSmrg# Code to be used in simple link tests 81940ef0e59aSmrglt_simple_link_test_code='package main; func main() { }' 81950ef0e59aSmrg 81960ef0e59aSmrg# ltmain only uses $CC for tagged configurations so make sure $CC is set. 81970ef0e59aSmrg_LT_TAG_COMPILER 81980ef0e59aSmrg 81990ef0e59aSmrg# save warnings/boilerplate of simple test code 82000ef0e59aSmrg_LT_COMPILER_BOILERPLATE 82010ef0e59aSmrg_LT_LINKER_BOILERPLATE 82020ef0e59aSmrg 82030ef0e59aSmrg# Allow CC to be a program name with arguments. 82040ef0e59aSmrglt_save_CC=$CC 82050ef0e59aSmrglt_save_CFLAGS=$CFLAGS 82060ef0e59aSmrglt_save_GCC=$GCC 82070ef0e59aSmrgGCC=yes 82080ef0e59aSmrgCC=${GOC-"gccgo"} 82090ef0e59aSmrgCFLAGS=$GOFLAGS 82100ef0e59aSmrgcompiler=$CC 82110ef0e59aSmrg_LT_TAGVAR(compiler, $1)=$CC 82120ef0e59aSmrg_LT_TAGVAR(LD, $1)=$LD 82130ef0e59aSmrg_LT_CC_BASENAME([$compiler]) 82140ef0e59aSmrg 82150ef0e59aSmrg# Go did not exist at the time GCC didn't implicitly link libc in. 82160ef0e59aSmrg_LT_TAGVAR(archive_cmds_need_lc, $1)=no 82170ef0e59aSmrg 82180ef0e59aSmrg_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 82190ef0e59aSmrg_LT_TAGVAR(reload_flag, $1)=$reload_flag 82200ef0e59aSmrg_LT_TAGVAR(reload_cmds, $1)=$reload_cmds 82210ef0e59aSmrg 82220ef0e59aSmrg## CAVEAT EMPTOR: 82230ef0e59aSmrg## There is no encapsulation within the following macros, do not change 82240ef0e59aSmrg## the running order or otherwise move them around unless you know exactly 82250ef0e59aSmrg## what you are doing... 82260ef0e59aSmrgif test -n "$compiler"; then 82270ef0e59aSmrg _LT_COMPILER_NO_RTTI($1) 82280ef0e59aSmrg _LT_COMPILER_PIC($1) 82290ef0e59aSmrg _LT_COMPILER_C_O($1) 82300ef0e59aSmrg _LT_COMPILER_FILE_LOCKS($1) 82310ef0e59aSmrg _LT_LINKER_SHLIBS($1) 82320ef0e59aSmrg _LT_LINKER_HARDCODE_LIBPATH($1) 82330ef0e59aSmrg 82340ef0e59aSmrg _LT_CONFIG($1) 82350ef0e59aSmrgfi 82360ef0e59aSmrg 82370ef0e59aSmrgAC_LANG_RESTORE 82380ef0e59aSmrg 82390ef0e59aSmrgGCC=$lt_save_GCC 82400ef0e59aSmrgCC=$lt_save_CC 82410ef0e59aSmrgCFLAGS=$lt_save_CFLAGS 82420ef0e59aSmrg])# _LT_LANG_GO_CONFIG 82430ef0e59aSmrg 82440ef0e59aSmrg 82450ef0e59aSmrg# _LT_LANG_RC_CONFIG([TAG]) 82460ef0e59aSmrg# ------------------------- 82470ef0e59aSmrg# Ensure that the configuration variables for the Windows resource compiler 82480ef0e59aSmrg# are suitably defined. These variables are subsequently used by _LT_CONFIG 82490ef0e59aSmrg# to write the compiler configuration to 'libtool'. 82500ef0e59aSmrgm4_defun([_LT_LANG_RC_CONFIG], 82510ef0e59aSmrg[AC_REQUIRE([LT_PROG_RC])dnl 82520ef0e59aSmrgAC_LANG_SAVE 82530ef0e59aSmrg 82540ef0e59aSmrg# Source file extension for RC test sources. 82550ef0e59aSmrgac_ext=rc 82560ef0e59aSmrg 82570ef0e59aSmrg# Object file extension for compiled RC test sources. 82580ef0e59aSmrgobjext=o 82590ef0e59aSmrg_LT_TAGVAR(objext, $1)=$objext 82600ef0e59aSmrg 82610ef0e59aSmrg# Code to be used in simple compile tests 82620ef0e59aSmrglt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }' 82630ef0e59aSmrg 82640ef0e59aSmrg# Code to be used in simple link tests 82650ef0e59aSmrglt_simple_link_test_code=$lt_simple_compile_test_code 82660ef0e59aSmrg 82670ef0e59aSmrg# ltmain only uses $CC for tagged configurations so make sure $CC is set. 82680ef0e59aSmrg_LT_TAG_COMPILER 82690ef0e59aSmrg 82700ef0e59aSmrg# save warnings/boilerplate of simple test code 82710ef0e59aSmrg_LT_COMPILER_BOILERPLATE 82720ef0e59aSmrg_LT_LINKER_BOILERPLATE 82730ef0e59aSmrg 82740ef0e59aSmrg# Allow CC to be a program name with arguments. 82750ef0e59aSmrglt_save_CC=$CC 82760ef0e59aSmrglt_save_CFLAGS=$CFLAGS 82770ef0e59aSmrglt_save_GCC=$GCC 82780ef0e59aSmrgGCC= 82790ef0e59aSmrgCC=${RC-"windres"} 82800ef0e59aSmrgCFLAGS= 82810ef0e59aSmrgcompiler=$CC 82820ef0e59aSmrg_LT_TAGVAR(compiler, $1)=$CC 82830ef0e59aSmrg_LT_CC_BASENAME([$compiler]) 82840ef0e59aSmrg_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes 82850ef0e59aSmrg 82860ef0e59aSmrgif test -n "$compiler"; then 82870ef0e59aSmrg : 82880ef0e59aSmrg _LT_CONFIG($1) 82890ef0e59aSmrgfi 82900ef0e59aSmrg 82910ef0e59aSmrgGCC=$lt_save_GCC 82920ef0e59aSmrgAC_LANG_RESTORE 82930ef0e59aSmrgCC=$lt_save_CC 82940ef0e59aSmrgCFLAGS=$lt_save_CFLAGS 82950ef0e59aSmrg])# _LT_LANG_RC_CONFIG 82960ef0e59aSmrg 82970ef0e59aSmrg 82980ef0e59aSmrg# LT_PROG_GCJ 82990ef0e59aSmrg# ----------- 83000ef0e59aSmrgAC_DEFUN([LT_PROG_GCJ], 83010ef0e59aSmrg[m4_ifdef([AC_PROG_GCJ], [AC_PROG_GCJ], 83020ef0e59aSmrg [m4_ifdef([A][M_PROG_GCJ], [A][M_PROG_GCJ], 83030ef0e59aSmrg [AC_CHECK_TOOL(GCJ, gcj,) 83040ef0e59aSmrg test set = "${GCJFLAGS+set}" || GCJFLAGS="-g -O2" 83050ef0e59aSmrg AC_SUBST(GCJFLAGS)])])[]dnl 83060ef0e59aSmrg]) 83070ef0e59aSmrg 83080ef0e59aSmrg# Old name: 83090ef0e59aSmrgAU_ALIAS([LT_AC_PROG_GCJ], [LT_PROG_GCJ]) 83100ef0e59aSmrgdnl aclocal-1.4 backwards compatibility: 83110ef0e59aSmrgdnl AC_DEFUN([LT_AC_PROG_GCJ], []) 83120ef0e59aSmrg 83130ef0e59aSmrg 83140ef0e59aSmrg# LT_PROG_GO 83150ef0e59aSmrg# ---------- 83160ef0e59aSmrgAC_DEFUN([LT_PROG_GO], 83170ef0e59aSmrg[AC_CHECK_TOOL(GOC, gccgo,) 83180ef0e59aSmrg]) 83190ef0e59aSmrg 83200ef0e59aSmrg 83210ef0e59aSmrg# LT_PROG_RC 83220ef0e59aSmrg# ---------- 83230ef0e59aSmrgAC_DEFUN([LT_PROG_RC], 83240ef0e59aSmrg[AC_CHECK_TOOL(RC, windres,) 83250ef0e59aSmrg]) 83260ef0e59aSmrg 83270ef0e59aSmrg# Old name: 83280ef0e59aSmrgAU_ALIAS([LT_AC_PROG_RC], [LT_PROG_RC]) 83290ef0e59aSmrgdnl aclocal-1.4 backwards compatibility: 83300ef0e59aSmrgdnl AC_DEFUN([LT_AC_PROG_RC], []) 83310ef0e59aSmrg 83320ef0e59aSmrg 83330ef0e59aSmrg# _LT_DECL_EGREP 83340ef0e59aSmrg# -------------- 83350ef0e59aSmrg# If we don't have a new enough Autoconf to choose the best grep 83360ef0e59aSmrg# available, choose the one first in the user's PATH. 83370ef0e59aSmrgm4_defun([_LT_DECL_EGREP], 83380ef0e59aSmrg[AC_REQUIRE([AC_PROG_EGREP])dnl 83390ef0e59aSmrgAC_REQUIRE([AC_PROG_FGREP])dnl 83400ef0e59aSmrgtest -z "$GREP" && GREP=grep 83410ef0e59aSmrg_LT_DECL([], [GREP], [1], [A grep program that handles long lines]) 83420ef0e59aSmrg_LT_DECL([], [EGREP], [1], [An ERE matcher]) 83430ef0e59aSmrg_LT_DECL([], [FGREP], [1], [A literal string matcher]) 83440ef0e59aSmrgdnl Non-bleeding-edge autoconf doesn't subst GREP, so do it here too 83450ef0e59aSmrgAC_SUBST([GREP]) 83460ef0e59aSmrg]) 83470ef0e59aSmrg 83480ef0e59aSmrg 83490ef0e59aSmrg# _LT_DECL_OBJDUMP 83500ef0e59aSmrg# -------------- 83510ef0e59aSmrg# If we don't have a new enough Autoconf to choose the best objdump 83520ef0e59aSmrg# available, choose the one first in the user's PATH. 83530ef0e59aSmrgm4_defun([_LT_DECL_OBJDUMP], 83540ef0e59aSmrg[AC_CHECK_TOOL(OBJDUMP, objdump, false) 83550ef0e59aSmrgtest -z "$OBJDUMP" && OBJDUMP=objdump 83560ef0e59aSmrg_LT_DECL([], [OBJDUMP], [1], [An object symbol dumper]) 83570ef0e59aSmrgAC_SUBST([OBJDUMP]) 83580ef0e59aSmrg]) 83590ef0e59aSmrg 83600ef0e59aSmrg# _LT_DECL_DLLTOOL 83610ef0e59aSmrg# ---------------- 83620ef0e59aSmrg# Ensure DLLTOOL variable is set. 83630ef0e59aSmrgm4_defun([_LT_DECL_DLLTOOL], 83640ef0e59aSmrg[AC_CHECK_TOOL(DLLTOOL, dlltool, false) 83650ef0e59aSmrgtest -z "$DLLTOOL" && DLLTOOL=dlltool 83660ef0e59aSmrg_LT_DECL([], [DLLTOOL], [1], [DLL creation program]) 83670ef0e59aSmrgAC_SUBST([DLLTOOL]) 83680ef0e59aSmrg]) 83690ef0e59aSmrg 837015885c33Smrg# _LT_DECL_FILECMD 837115885c33Smrg# ---------------- 837215885c33Smrg# Check for a file(cmd) program that can be used to detect file type and magic 837315885c33Smrgm4_defun([_LT_DECL_FILECMD], 8374d5e6aabbSmrg[AC_CHECK_PROG([FILECMD], [file], [file], [:]) 837515885c33Smrg_LT_DECL([], [FILECMD], [1], [A file(cmd) program that detects file types]) 837615885c33Smrg])# _LD_DECL_FILECMD 837715885c33Smrg 83780ef0e59aSmrg# _LT_DECL_SED 83790ef0e59aSmrg# ------------ 83800ef0e59aSmrg# Check for a fully-functional sed program, that truncates 83810ef0e59aSmrg# as few characters as possible. Prefer GNU sed if found. 83820ef0e59aSmrgm4_defun([_LT_DECL_SED], 83830ef0e59aSmrg[AC_PROG_SED 83840ef0e59aSmrgtest -z "$SED" && SED=sed 83850ef0e59aSmrgXsed="$SED -e 1s/^X//" 83860ef0e59aSmrg_LT_DECL([], [SED], [1], [A sed program that does not truncate output]) 83870ef0e59aSmrg_LT_DECL([], [Xsed], ["\$SED -e 1s/^X//"], 83880ef0e59aSmrg [Sed that helps us avoid accidentally triggering echo(1) options like -n]) 83890ef0e59aSmrg])# _LT_DECL_SED 83900ef0e59aSmrgdnl aclocal-1.4 backwards compatibility: 83910ef0e59aSmrgdnl AC_DEFUN([LT_AC_PROG_SED], []) 83920ef0e59aSmrg 83930ef0e59aSmrg 83940ef0e59aSmrg# _LT_CHECK_SHELL_FEATURES 83950ef0e59aSmrg# ------------------------ 83960ef0e59aSmrg# Find out whether the shell is Bourne or XSI compatible, 83970ef0e59aSmrg# or has some other useful features. 83980ef0e59aSmrgm4_defun([_LT_CHECK_SHELL_FEATURES], 83990ef0e59aSmrg[if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then 84000ef0e59aSmrg lt_unset=unset 84010ef0e59aSmrgelse 84020ef0e59aSmrg lt_unset=false 84030ef0e59aSmrgfi 84040ef0e59aSmrg_LT_DECL([], [lt_unset], [0], [whether the shell understands "unset"])dnl 84050ef0e59aSmrg 84060ef0e59aSmrg# test EBCDIC or ASCII 84070ef0e59aSmrgcase `echo X|tr X '\101'` in 84080ef0e59aSmrg A) # ASCII based system 84090ef0e59aSmrg # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr 84100ef0e59aSmrg lt_SP2NL='tr \040 \012' 84110ef0e59aSmrg lt_NL2SP='tr \015\012 \040\040' 84120ef0e59aSmrg ;; 84130ef0e59aSmrg *) # EBCDIC based system 84140ef0e59aSmrg lt_SP2NL='tr \100 \n' 84150ef0e59aSmrg lt_NL2SP='tr \r\n \100\100' 84160ef0e59aSmrg ;; 84170ef0e59aSmrgesac 84180ef0e59aSmrg_LT_DECL([SP2NL], [lt_SP2NL], [1], [turn spaces into newlines])dnl 84190ef0e59aSmrg_LT_DECL([NL2SP], [lt_NL2SP], [1], [turn newlines into spaces])dnl 84200ef0e59aSmrg])# _LT_CHECK_SHELL_FEATURES 84210ef0e59aSmrg 84220ef0e59aSmrg 84230ef0e59aSmrg# _LT_PATH_CONVERSION_FUNCTIONS 84240ef0e59aSmrg# ----------------------------- 84250ef0e59aSmrg# Determine what file name conversion functions should be used by 84260ef0e59aSmrg# func_to_host_file (and, implicitly, by func_to_host_path). These are needed 84270ef0e59aSmrg# for certain cross-compile configurations and native mingw. 84280ef0e59aSmrgm4_defun([_LT_PATH_CONVERSION_FUNCTIONS], 84290ef0e59aSmrg[AC_REQUIRE([AC_CANONICAL_HOST])dnl 84300ef0e59aSmrgAC_REQUIRE([AC_CANONICAL_BUILD])dnl 84310ef0e59aSmrgAC_MSG_CHECKING([how to convert $build file names to $host format]) 84320ef0e59aSmrgAC_CACHE_VAL(lt_cv_to_host_file_cmd, 84330ef0e59aSmrg[case $host in 84340ef0e59aSmrg *-*-mingw* ) 84350ef0e59aSmrg case $build in 8436d5e6aabbSmrg *-*-mingw* | *-*-windows* ) # actually msys 84370ef0e59aSmrg lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32 84380ef0e59aSmrg ;; 84390ef0e59aSmrg *-*-cygwin* ) 84400ef0e59aSmrg lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32 84410ef0e59aSmrg ;; 84420ef0e59aSmrg * ) # otherwise, assume *nix 84430ef0e59aSmrg lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32 84440ef0e59aSmrg ;; 84450ef0e59aSmrg esac 84460ef0e59aSmrg ;; 84470ef0e59aSmrg *-*-cygwin* ) 84480ef0e59aSmrg case $build in 8449d5e6aabbSmrg *-*-mingw* | *-*-windows* ) # actually msys 84500ef0e59aSmrg lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin 84510ef0e59aSmrg ;; 84520ef0e59aSmrg *-*-cygwin* ) 84530ef0e59aSmrg lt_cv_to_host_file_cmd=func_convert_file_noop 84540ef0e59aSmrg ;; 84550ef0e59aSmrg * ) # otherwise, assume *nix 84560ef0e59aSmrg lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin 84570ef0e59aSmrg ;; 84580ef0e59aSmrg esac 84590ef0e59aSmrg ;; 84600ef0e59aSmrg * ) # unhandled hosts (and "normal" native builds) 84610ef0e59aSmrg lt_cv_to_host_file_cmd=func_convert_file_noop 84620ef0e59aSmrg ;; 84630ef0e59aSmrgesac 84640ef0e59aSmrg]) 84650ef0e59aSmrgto_host_file_cmd=$lt_cv_to_host_file_cmd 84660ef0e59aSmrgAC_MSG_RESULT([$lt_cv_to_host_file_cmd]) 84670ef0e59aSmrg_LT_DECL([to_host_file_cmd], [lt_cv_to_host_file_cmd], 84680ef0e59aSmrg [0], [convert $build file names to $host format])dnl 84690ef0e59aSmrg 84700ef0e59aSmrgAC_MSG_CHECKING([how to convert $build file names to toolchain format]) 84710ef0e59aSmrgAC_CACHE_VAL(lt_cv_to_tool_file_cmd, 84720ef0e59aSmrg[#assume ordinary cross tools, or native build. 84730ef0e59aSmrglt_cv_to_tool_file_cmd=func_convert_file_noop 84740ef0e59aSmrgcase $host in 8475d5e6aabbSmrg *-*-mingw* | *-*-windows* ) 84760ef0e59aSmrg case $build in 8477d5e6aabbSmrg *-*-mingw* | *-*-windows* ) # actually msys 84780ef0e59aSmrg lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32 84790ef0e59aSmrg ;; 84800ef0e59aSmrg esac 84810ef0e59aSmrg ;; 84820ef0e59aSmrgesac 84830ef0e59aSmrg]) 84840ef0e59aSmrgto_tool_file_cmd=$lt_cv_to_tool_file_cmd 84850ef0e59aSmrgAC_MSG_RESULT([$lt_cv_to_tool_file_cmd]) 84860ef0e59aSmrg_LT_DECL([to_tool_file_cmd], [lt_cv_to_tool_file_cmd], 84870ef0e59aSmrg [0], [convert $build files to toolchain format])dnl 84880ef0e59aSmrg])# _LT_PATH_CONVERSION_FUNCTIONS 8489