10b0ce0bfSmrg# generated automatically by aclocal 1.16.5 -*- Autoconf -*- 25a81ca49Smrg 30b0ce0bfSmrg# Copyright (C) 1996-2021 Free Software Foundation, Inc. 432b578d3Smrg 532b578d3Smrg# This file is free software; the Free Software Foundation 632b578d3Smrg# gives unlimited permission to copy and/or distribute it, 732b578d3Smrg# with or without modifications, as long as this notice is preserved. 832b578d3Smrg 932b578d3Smrg# This program is distributed in the hope that it will be useful, 1032b578d3Smrg# but WITHOUT ANY WARRANTY, to the extent permitted by law; without 1132b578d3Smrg# even the implied warranty of MERCHANTABILITY or FITNESS FOR A 1232b578d3Smrg# PARTICULAR PURPOSE. 1332b578d3Smrg 145a81ca49Smrgm4_ifndef([AC_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])]) 152a51b5beSmrgm4_ifndef([AC_AUTOCONF_VERSION], 162a51b5beSmrg [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl 170b0ce0bfSmrgm4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.71],, 180b0ce0bfSmrg[m4_warning([this file was generated for autoconf 2.71. 192a51b5beSmrgYou have another version of autoconf. It may work, but is not guaranteed to. 202a51b5beSmrgIf you have problems, you may need to regenerate the build system entirely. 215a81ca49SmrgTo do so, use the procedure documented by the package, typically 'autoreconf'.])]) 2232b578d3Smrg 230b0ce0bfSmrg# Copyright (C) 2002-2021 Free Software Foundation, Inc. 241b12faf6Smrg# 250b0ce0bfSmrg# This file is free software; the Free Software Foundation 260b0ce0bfSmrg# gives unlimited permission to copy and/or distribute it, 270b0ce0bfSmrg# with or without modifications, as long as this notice is preserved. 280b0ce0bfSmrg 290b0ce0bfSmrg# AM_AUTOMAKE_VERSION(VERSION) 300b0ce0bfSmrg# ---------------------------- 310b0ce0bfSmrg# Automake X.Y traces this macro to ensure aclocal.m4 has been 320b0ce0bfSmrg# generated from the m4 files accompanying Automake X.Y. 330b0ce0bfSmrg# (This private macro should not be called outside this file.) 340b0ce0bfSmrgAC_DEFUN([AM_AUTOMAKE_VERSION], 350b0ce0bfSmrg[am__api_version='1.16' 360b0ce0bfSmrgdnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to 370b0ce0bfSmrgdnl require some minimum version. Point them to the right macro. 380b0ce0bfSmrgm4_if([$1], [1.16.5], [], 390b0ce0bfSmrg [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl 400b0ce0bfSmrg]) 410b0ce0bfSmrg 420b0ce0bfSmrg# _AM_AUTOCONF_VERSION(VERSION) 430b0ce0bfSmrg# ----------------------------- 440b0ce0bfSmrg# aclocal traces this macro to find the Autoconf version. 450b0ce0bfSmrg# This is a private macro too. Using m4_define simplifies 460b0ce0bfSmrg# the logic in aclocal, which can simply ignore this definition. 470b0ce0bfSmrgm4_define([_AM_AUTOCONF_VERSION], []) 480b0ce0bfSmrg 490b0ce0bfSmrg# AM_SET_CURRENT_AUTOMAKE_VERSION 500b0ce0bfSmrg# ------------------------------- 510b0ce0bfSmrg# Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced. 520b0ce0bfSmrg# This function is AC_REQUIREd by AM_INIT_AUTOMAKE. 530b0ce0bfSmrgAC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION], 540b0ce0bfSmrg[AM_AUTOMAKE_VERSION([1.16.5])dnl 550b0ce0bfSmrgm4_ifndef([AC_AUTOCONF_VERSION], 560b0ce0bfSmrg [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl 570b0ce0bfSmrg_AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))]) 580b0ce0bfSmrg 590b0ce0bfSmrg# AM_AUX_DIR_EXPAND -*- Autoconf -*- 600b0ce0bfSmrg 610b0ce0bfSmrg# Copyright (C) 2001-2021 Free Software Foundation, Inc. 62e35d4d8eSmrg# 630b0ce0bfSmrg# This file is free software; the Free Software Foundation 640b0ce0bfSmrg# gives unlimited permission to copy and/or distribute it, 650b0ce0bfSmrg# with or without modifications, as long as this notice is preserved. 661b12faf6Smrg 670b0ce0bfSmrg# For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets 680b0ce0bfSmrg# $ac_aux_dir to '$srcdir/foo'. In other projects, it is set to 690b0ce0bfSmrg# '$srcdir', '$srcdir/..', or '$srcdir/../..'. 70e35d4d8eSmrg# 710b0ce0bfSmrg# Of course, Automake must honor this variable whenever it calls a 720b0ce0bfSmrg# tool from the auxiliary directory. The problem is that $srcdir (and 730b0ce0bfSmrg# therefore $ac_aux_dir as well) can be either absolute or relative, 740b0ce0bfSmrg# depending on how configure is run. This is pretty annoying, since 750b0ce0bfSmrg# it makes $ac_aux_dir quite unusable in subdirectories: in the top 760b0ce0bfSmrg# source directory, any form will work fine, but in subdirectories a 770b0ce0bfSmrg# relative path needs to be adjusted first. 78e35d4d8eSmrg# 790b0ce0bfSmrg# $ac_aux_dir/missing 800b0ce0bfSmrg# fails when called from a subdirectory if $ac_aux_dir is relative 810b0ce0bfSmrg# $top_srcdir/$ac_aux_dir/missing 820b0ce0bfSmrg# fails if $ac_aux_dir is absolute, 830b0ce0bfSmrg# fails when called from a subdirectory in a VPATH build with 840b0ce0bfSmrg# a relative $ac_aux_dir 85e35d4d8eSmrg# 860b0ce0bfSmrg# The reason of the latter failure is that $top_srcdir and $ac_aux_dir 870b0ce0bfSmrg# are both prefixed by $srcdir. In an in-source build this is usually 880b0ce0bfSmrg# harmless because $srcdir is '.', but things will broke when you 890b0ce0bfSmrg# start a VPATH build or use an absolute $srcdir. 90e35d4d8eSmrg# 910b0ce0bfSmrg# So we could use something similar to $top_srcdir/$ac_aux_dir/missing, 920b0ce0bfSmrg# iff we strip the leading $srcdir from $ac_aux_dir. That would be: 930b0ce0bfSmrg# am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"` 940b0ce0bfSmrg# and then we would define $MISSING as 950b0ce0bfSmrg# MISSING="\${SHELL} $am_aux_dir/missing" 960b0ce0bfSmrg# This will work as long as MISSING is not called from configure, because 970b0ce0bfSmrg# unfortunately $(top_srcdir) has no meaning in configure. 980b0ce0bfSmrg# However there are other variables, like CC, which are often used in 990b0ce0bfSmrg# configure, and could therefore not use this "fixed" $ac_aux_dir. 100e35d4d8eSmrg# 1010b0ce0bfSmrg# Another solution, used here, is to always expand $ac_aux_dir to an 1020b0ce0bfSmrg# absolute PATH. The drawback is that using absolute paths prevent a 1030b0ce0bfSmrg# configured tree to be moved without reconfiguration. 10432b578d3Smrg 1050b0ce0bfSmrgAC_DEFUN([AM_AUX_DIR_EXPAND], 1060b0ce0bfSmrg[AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl 1070b0ce0bfSmrg# Expand $ac_aux_dir to an absolute path. 1080b0ce0bfSmrgam_aux_dir=`cd "$ac_aux_dir" && pwd` 1095a81ca49Smrg]) 1101b12faf6Smrg 1110b0ce0bfSmrg# AM_CONDITIONAL -*- Autoconf -*- 1121b12faf6Smrg 1130b0ce0bfSmrg# Copyright (C) 1997-2021 Free Software Foundation, Inc. 1140b0ce0bfSmrg# 1150b0ce0bfSmrg# This file is free software; the Free Software Foundation 1160b0ce0bfSmrg# gives unlimited permission to copy and/or distribute it, 1170b0ce0bfSmrg# with or without modifications, as long as this notice is preserved. 1181b12faf6Smrg 1190b0ce0bfSmrg# AM_CONDITIONAL(NAME, SHELL-CONDITION) 1200b0ce0bfSmrg# ------------------------------------- 1210b0ce0bfSmrg# Define a conditional. 1220b0ce0bfSmrgAC_DEFUN([AM_CONDITIONAL], 1230b0ce0bfSmrg[AC_PREREQ([2.52])dnl 1240b0ce0bfSmrg m4_if([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])], 1250b0ce0bfSmrg [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl 1260b0ce0bfSmrgAC_SUBST([$1_TRUE])dnl 1270b0ce0bfSmrgAC_SUBST([$1_FALSE])dnl 1280b0ce0bfSmrg_AM_SUBST_NOTMAKE([$1_TRUE])dnl 1290b0ce0bfSmrg_AM_SUBST_NOTMAKE([$1_FALSE])dnl 1300b0ce0bfSmrgm4_define([_AM_COND_VALUE_$1], [$2])dnl 1310b0ce0bfSmrgif $2; then 1320b0ce0bfSmrg $1_TRUE= 1330b0ce0bfSmrg $1_FALSE='#' 1340b0ce0bfSmrgelse 1350b0ce0bfSmrg $1_TRUE='#' 1360b0ce0bfSmrg $1_FALSE= 1370b0ce0bfSmrgfi 1380b0ce0bfSmrgAC_CONFIG_COMMANDS_PRE( 1390b0ce0bfSmrg[if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then 1400b0ce0bfSmrg AC_MSG_ERROR([[conditional "$1" was never defined. 1410b0ce0bfSmrgUsually this means the macro was only invoked conditionally.]]) 1420b0ce0bfSmrgfi])]) 1431b12faf6Smrg 1440b0ce0bfSmrg# Copyright (C) 1999-2021 Free Software Foundation, Inc. 1450b0ce0bfSmrg# 1460b0ce0bfSmrg# This file is free software; the Free Software Foundation 1470b0ce0bfSmrg# gives unlimited permission to copy and/or distribute it, 1480b0ce0bfSmrg# with or without modifications, as long as this notice is preserved. 1491b12faf6Smrg 1501b12faf6Smrg 1510b0ce0bfSmrg# There are a few dirty hacks below to avoid letting 'AC_PROG_CC' be 1520b0ce0bfSmrg# written in clear, in which case automake, when reading aclocal.m4, 1530b0ce0bfSmrg# will think it sees a *use*, and therefore will trigger all it's 1540b0ce0bfSmrg# C support machinery. Also note that it means that autoscan, seeing 1550b0ce0bfSmrg# CC etc. in the Makefile, will ask for an AC_PROG_CC use... 15632b578d3Smrg 15732b578d3Smrg 1580b0ce0bfSmrg# _AM_DEPENDENCIES(NAME) 1590b0ce0bfSmrg# ---------------------- 1600b0ce0bfSmrg# See how the compiler implements dependency checking. 1610b0ce0bfSmrg# NAME is "CC", "CXX", "OBJC", "OBJCXX", "UPC", or "GJC". 1620b0ce0bfSmrg# We try a few techniques and use that to set a single cache variable. 1630b0ce0bfSmrg# 1640b0ce0bfSmrg# We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was 1650b0ce0bfSmrg# modified to invoke _AM_DEPENDENCIES(CC); we would have a circular 1660b0ce0bfSmrg# dependency, and given that the user is not expected to run this macro, 1670b0ce0bfSmrg# just rely on AC_PROG_CC. 1680b0ce0bfSmrgAC_DEFUN([_AM_DEPENDENCIES], 1690b0ce0bfSmrg[AC_REQUIRE([AM_SET_DEPDIR])dnl 1700b0ce0bfSmrgAC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl 1710b0ce0bfSmrgAC_REQUIRE([AM_MAKE_INCLUDE])dnl 1720b0ce0bfSmrgAC_REQUIRE([AM_DEP_TRACK])dnl 17332b578d3Smrg 1740b0ce0bfSmrgm4_if([$1], [CC], [depcc="$CC" am_compiler_list=], 1750b0ce0bfSmrg [$1], [CXX], [depcc="$CXX" am_compiler_list=], 1760b0ce0bfSmrg [$1], [OBJC], [depcc="$OBJC" am_compiler_list='gcc3 gcc'], 1770b0ce0bfSmrg [$1], [OBJCXX], [depcc="$OBJCXX" am_compiler_list='gcc3 gcc'], 1780b0ce0bfSmrg [$1], [UPC], [depcc="$UPC" am_compiler_list=], 1790b0ce0bfSmrg [$1], [GCJ], [depcc="$GCJ" am_compiler_list='gcc3 gcc'], 1800b0ce0bfSmrg [depcc="$$1" am_compiler_list=]) 18132b578d3Smrg 1820b0ce0bfSmrgAC_CACHE_CHECK([dependency style of $depcc], 1830b0ce0bfSmrg [am_cv_$1_dependencies_compiler_type], 1840b0ce0bfSmrg[if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then 1850b0ce0bfSmrg # We make a subdir and do the tests there. Otherwise we can end up 1860b0ce0bfSmrg # making bogus files that we don't know about and never remove. For 1870b0ce0bfSmrg # instance it was reported that on HP-UX the gcc test will end up 1880b0ce0bfSmrg # making a dummy file named 'D' -- because '-MD' means "put the output 1890b0ce0bfSmrg # in D". 1900b0ce0bfSmrg rm -rf conftest.dir 1910b0ce0bfSmrg mkdir conftest.dir 1920b0ce0bfSmrg # Copy depcomp to subdir because otherwise we won't find it if we're 1930b0ce0bfSmrg # using a relative directory. 1940b0ce0bfSmrg cp "$am_depcomp" conftest.dir 1950b0ce0bfSmrg cd conftest.dir 1960b0ce0bfSmrg # We will build objects and dependencies in a subdirectory because 1970b0ce0bfSmrg # it helps to detect inapplicable dependency modes. For instance 1980b0ce0bfSmrg # both Tru64's cc and ICC support -MD to output dependencies as a 1990b0ce0bfSmrg # side effect of compilation, but ICC will put the dependencies in 2000b0ce0bfSmrg # the current directory while Tru64 will put them in the object 2010b0ce0bfSmrg # directory. 2020b0ce0bfSmrg mkdir sub 20332b578d3Smrg 2040b0ce0bfSmrg am_cv_$1_dependencies_compiler_type=none 2050b0ce0bfSmrg if test "$am_compiler_list" = ""; then 2060b0ce0bfSmrg am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp` 2070b0ce0bfSmrg fi 2080b0ce0bfSmrg am__universal=false 2090b0ce0bfSmrg m4_case([$1], [CC], 2100b0ce0bfSmrg [case " $depcc " in #( 2110b0ce0bfSmrg *\ -arch\ *\ -arch\ *) am__universal=true ;; 2120b0ce0bfSmrg esac], 2130b0ce0bfSmrg [CXX], 2140b0ce0bfSmrg [case " $depcc " in #( 2150b0ce0bfSmrg *\ -arch\ *\ -arch\ *) am__universal=true ;; 2160b0ce0bfSmrg esac]) 21732b578d3Smrg 2180b0ce0bfSmrg for depmode in $am_compiler_list; do 2190b0ce0bfSmrg # Setup a source with many dependencies, because some compilers 2200b0ce0bfSmrg # like to wrap large dependency lists on column 80 (with \), and 2210b0ce0bfSmrg # we should not choose a depcomp mode which is confused by this. 2220b0ce0bfSmrg # 2230b0ce0bfSmrg # We need to recreate these files for each test, as the compiler may 2240b0ce0bfSmrg # overwrite some of them when testing with obscure command lines. 2250b0ce0bfSmrg # This happens at least with the AIX C compiler. 2260b0ce0bfSmrg : > sub/conftest.c 2270b0ce0bfSmrg for i in 1 2 3 4 5 6; do 2280b0ce0bfSmrg echo '#include "conftst'$i'.h"' >> sub/conftest.c 2290b0ce0bfSmrg # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with 2300b0ce0bfSmrg # Solaris 10 /bin/sh. 2310b0ce0bfSmrg echo '/* dummy */' > sub/conftst$i.h 2320b0ce0bfSmrg done 2330b0ce0bfSmrg echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf 23432b578d3Smrg 2350b0ce0bfSmrg # We check with '-c' and '-o' for the sake of the "dashmstdout" 2360b0ce0bfSmrg # mode. It turns out that the SunPro C++ compiler does not properly 2370b0ce0bfSmrg # handle '-M -o', and we need to detect this. Also, some Intel 2380b0ce0bfSmrg # versions had trouble with output in subdirs. 2390b0ce0bfSmrg am__obj=sub/conftest.${OBJEXT-o} 2400b0ce0bfSmrg am__minus_obj="-o $am__obj" 2410b0ce0bfSmrg case $depmode in 2420b0ce0bfSmrg gcc) 2430b0ce0bfSmrg # This depmode causes a compiler race in universal mode. 2440b0ce0bfSmrg test "$am__universal" = false || continue 2450b0ce0bfSmrg ;; 2460b0ce0bfSmrg nosideeffect) 2470b0ce0bfSmrg # After this tag, mechanisms are not by side-effect, so they'll 2480b0ce0bfSmrg # only be used when explicitly requested. 2490b0ce0bfSmrg if test "x$enable_dependency_tracking" = xyes; then 2500b0ce0bfSmrg continue 2510b0ce0bfSmrg else 2520b0ce0bfSmrg break 2530b0ce0bfSmrg fi 2540b0ce0bfSmrg ;; 2550b0ce0bfSmrg msvc7 | msvc7msys | msvisualcpp | msvcmsys) 2560b0ce0bfSmrg # This compiler won't grok '-c -o', but also, the minuso test has 2570b0ce0bfSmrg # not run yet. These depmodes are late enough in the game, and 2580b0ce0bfSmrg # so weak that their functioning should not be impacted. 2590b0ce0bfSmrg am__obj=conftest.${OBJEXT-o} 2600b0ce0bfSmrg am__minus_obj= 2610b0ce0bfSmrg ;; 2620b0ce0bfSmrg none) break ;; 2630b0ce0bfSmrg esac 2640b0ce0bfSmrg if depmode=$depmode \ 2650b0ce0bfSmrg source=sub/conftest.c object=$am__obj \ 2660b0ce0bfSmrg depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ 2670b0ce0bfSmrg $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ 2680b0ce0bfSmrg >/dev/null 2>conftest.err && 2690b0ce0bfSmrg grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && 2700b0ce0bfSmrg grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && 2710b0ce0bfSmrg grep $am__obj sub/conftest.Po > /dev/null 2>&1 && 2720b0ce0bfSmrg ${MAKE-make} -s -f confmf > /dev/null 2>&1; then 2730b0ce0bfSmrg # icc doesn't choke on unknown options, it will just issue warnings 2740b0ce0bfSmrg # or remarks (even with -Werror). So we grep stderr for any message 2750b0ce0bfSmrg # that says an option was ignored or not supported. 2760b0ce0bfSmrg # When given -MP, icc 7.0 and 7.1 complain thusly: 2770b0ce0bfSmrg # icc: Command line warning: ignoring option '-M'; no argument required 2780b0ce0bfSmrg # The diagnosis changed in icc 8.0: 2790b0ce0bfSmrg # icc: Command line remark: option '-MP' not supported 2800b0ce0bfSmrg if (grep 'ignoring option' conftest.err || 2810b0ce0bfSmrg grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else 2820b0ce0bfSmrg am_cv_$1_dependencies_compiler_type=$depmode 2830b0ce0bfSmrg break 2840b0ce0bfSmrg fi 2850b0ce0bfSmrg fi 2860b0ce0bfSmrg done 28732b578d3Smrg 2880b0ce0bfSmrg cd .. 2890b0ce0bfSmrg rm -rf conftest.dir 2900b0ce0bfSmrgelse 2910b0ce0bfSmrg am_cv_$1_dependencies_compiler_type=none 2920b0ce0bfSmrgfi 2930b0ce0bfSmrg]) 2940b0ce0bfSmrgAC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type]) 2950b0ce0bfSmrgAM_CONDITIONAL([am__fastdep$1], [ 2960b0ce0bfSmrg test "x$enable_dependency_tracking" != xno \ 2970b0ce0bfSmrg && test "$am_cv_$1_dependencies_compiler_type" = gcc3]) 2980b0ce0bfSmrg]) 2995a81ca49Smrg 3005a81ca49Smrg 3010b0ce0bfSmrg# AM_SET_DEPDIR 3020b0ce0bfSmrg# ------------- 3030b0ce0bfSmrg# Choose a directory name for dependency files. 3040b0ce0bfSmrg# This macro is AC_REQUIREd in _AM_DEPENDENCIES. 3050b0ce0bfSmrgAC_DEFUN([AM_SET_DEPDIR], 3060b0ce0bfSmrg[AC_REQUIRE([AM_SET_LEADING_DOT])dnl 3070b0ce0bfSmrgAC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl 3080b0ce0bfSmrg]) 3095a81ca49Smrg 3105a81ca49Smrg 3110b0ce0bfSmrg# AM_DEP_TRACK 3120b0ce0bfSmrg# ------------ 3130b0ce0bfSmrgAC_DEFUN([AM_DEP_TRACK], 3140b0ce0bfSmrg[AC_ARG_ENABLE([dependency-tracking], [dnl 3150b0ce0bfSmrgAS_HELP_STRING( 3160b0ce0bfSmrg [--enable-dependency-tracking], 3170b0ce0bfSmrg [do not reject slow dependency extractors]) 3180b0ce0bfSmrgAS_HELP_STRING( 3190b0ce0bfSmrg [--disable-dependency-tracking], 3200b0ce0bfSmrg [speeds up one-time build])]) 3210b0ce0bfSmrgif test "x$enable_dependency_tracking" != xno; then 3220b0ce0bfSmrg am_depcomp="$ac_aux_dir/depcomp" 3230b0ce0bfSmrg AMDEPBACKSLASH='\' 3240b0ce0bfSmrg am__nodep='_no' 325e35d4d8eSmrgfi 3260b0ce0bfSmrgAM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno]) 3270b0ce0bfSmrgAC_SUBST([AMDEPBACKSLASH])dnl 3280b0ce0bfSmrg_AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl 3290b0ce0bfSmrgAC_SUBST([am__nodep])dnl 3300b0ce0bfSmrg_AM_SUBST_NOTMAKE([am__nodep])dnl 331e35d4d8eSmrg]) 33232b578d3Smrg 3330b0ce0bfSmrg# Generate code to set up dependency tracking. -*- Autoconf -*- 3341b12faf6Smrg 3350b0ce0bfSmrg# Copyright (C) 1999-2021 Free Software Foundation, Inc. 3360b0ce0bfSmrg# 3370b0ce0bfSmrg# This file is free software; the Free Software Foundation 3380b0ce0bfSmrg# gives unlimited permission to copy and/or distribute it, 3390b0ce0bfSmrg# with or without modifications, as long as this notice is preserved. 3401b12faf6Smrg 3410b0ce0bfSmrg# _AM_OUTPUT_DEPENDENCY_COMMANDS 3420b0ce0bfSmrg# ------------------------------ 3430b0ce0bfSmrgAC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], 3440b0ce0bfSmrg[{ 3450b0ce0bfSmrg # Older Autoconf quotes --file arguments for eval, but not when files 3460b0ce0bfSmrg # are listed without --file. Let's play safe and only enable the eval 3470b0ce0bfSmrg # if we detect the quoting. 3480b0ce0bfSmrg # TODO: see whether this extra hack can be removed once we start 3490b0ce0bfSmrg # requiring Autoconf 2.70 or later. 3500b0ce0bfSmrg AS_CASE([$CONFIG_FILES], 3510b0ce0bfSmrg [*\'*], [eval set x "$CONFIG_FILES"], 3520b0ce0bfSmrg [*], [set x $CONFIG_FILES]) 3530b0ce0bfSmrg shift 3540b0ce0bfSmrg # Used to flag and report bootstrapping failures. 3550b0ce0bfSmrg am_rc=0 3560b0ce0bfSmrg for am_mf 3570b0ce0bfSmrg do 3580b0ce0bfSmrg # Strip MF so we end up with the name of the file. 3590b0ce0bfSmrg am_mf=`AS_ECHO(["$am_mf"]) | sed -e 's/:.*$//'` 3600b0ce0bfSmrg # Check whether this is an Automake generated Makefile which includes 3610b0ce0bfSmrg # dependency-tracking related rules and includes. 3620b0ce0bfSmrg # Grep'ing the whole file directly is not great: AIX grep has a line 3630b0ce0bfSmrg # limit of 2048, but all sed's we know have understand at least 4000. 3640b0ce0bfSmrg sed -n 's,^am--depfiles:.*,X,p' "$am_mf" | grep X >/dev/null 2>&1 \ 3650b0ce0bfSmrg || continue 3660b0ce0bfSmrg am_dirpart=`AS_DIRNAME(["$am_mf"])` 3670b0ce0bfSmrg am_filepart=`AS_BASENAME(["$am_mf"])` 3680b0ce0bfSmrg AM_RUN_LOG([cd "$am_dirpart" \ 3690b0ce0bfSmrg && sed -e '/# am--include-marker/d' "$am_filepart" \ 3700b0ce0bfSmrg | $MAKE -f - am--depfiles]) || am_rc=$? 3710b0ce0bfSmrg done 3720b0ce0bfSmrg if test $am_rc -ne 0; then 3730b0ce0bfSmrg AC_MSG_FAILURE([Something went wrong bootstrapping makefile fragments 3740b0ce0bfSmrg for automatic dependency tracking. If GNU make was not used, consider 3750b0ce0bfSmrg re-running the configure script with MAKE="gmake" (or whatever is 3760b0ce0bfSmrg necessary). You can also try re-running configure with the 3770b0ce0bfSmrg '--disable-dependency-tracking' option to at least be able to build 3780b0ce0bfSmrg the package (albeit without support for automatic dependency tracking).]) 3795a81ca49Smrg fi 3800b0ce0bfSmrg AS_UNSET([am_dirpart]) 3810b0ce0bfSmrg AS_UNSET([am_filepart]) 3820b0ce0bfSmrg AS_UNSET([am_mf]) 3830b0ce0bfSmrg AS_UNSET([am_rc]) 3840b0ce0bfSmrg rm -f conftest-deps.mk 3850b0ce0bfSmrg} 3860b0ce0bfSmrg])# _AM_OUTPUT_DEPENDENCY_COMMANDS 3871b12faf6Smrg 3881b12faf6Smrg 3890b0ce0bfSmrg# AM_OUTPUT_DEPENDENCY_COMMANDS 3900b0ce0bfSmrg# ----------------------------- 3910b0ce0bfSmrg# This macro should only be invoked once -- use via AC_REQUIRE. 3920b0ce0bfSmrg# 3930b0ce0bfSmrg# This code is only required when automatic dependency tracking is enabled. 3940b0ce0bfSmrg# This creates each '.Po' and '.Plo' makefile fragment that we'll need in 3950b0ce0bfSmrg# order to bootstrap the dependency handling code. 3960b0ce0bfSmrgAC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS], 3970b0ce0bfSmrg[AC_CONFIG_COMMANDS([depfiles], 3980b0ce0bfSmrg [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS], 3990b0ce0bfSmrg [AMDEP_TRUE="$AMDEP_TRUE" MAKE="${MAKE-make}"])]) 4001b12faf6Smrg 4010b0ce0bfSmrg# Do all the work for Automake. -*- Autoconf -*- 4021b12faf6Smrg 4030b0ce0bfSmrg# Copyright (C) 1996-2021 Free Software Foundation, Inc. 4040b0ce0bfSmrg# 4050b0ce0bfSmrg# This file is free software; the Free Software Foundation 4060b0ce0bfSmrg# gives unlimited permission to copy and/or distribute it, 4070b0ce0bfSmrg# with or without modifications, as long as this notice is preserved. 4081b12faf6Smrg 4090b0ce0bfSmrg# This macro actually does too much. Some checks are only needed if 4100b0ce0bfSmrg# your package does certain things. But this isn't really a big deal. 4111b12faf6Smrg 4120b0ce0bfSmrgdnl Redefine AC_PROG_CC to automatically invoke _AM_PROG_CC_C_O. 4130b0ce0bfSmrgm4_define([AC_PROG_CC], 4140b0ce0bfSmrgm4_defn([AC_PROG_CC]) 4150b0ce0bfSmrg[_AM_PROG_CC_C_O 4160b0ce0bfSmrg]) 4171b12faf6Smrg 4180b0ce0bfSmrg# AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE]) 4190b0ce0bfSmrg# AM_INIT_AUTOMAKE([OPTIONS]) 4200b0ce0bfSmrg# ----------------------------------------------- 4210b0ce0bfSmrg# The call with PACKAGE and VERSION arguments is the old style 4220b0ce0bfSmrg# call (pre autoconf-2.50), which is being phased out. PACKAGE 4230b0ce0bfSmrg# and VERSION should now be passed to AC_INIT and removed from 4240b0ce0bfSmrg# the call to AM_INIT_AUTOMAKE. 4250b0ce0bfSmrg# We support both call styles for the transition. After 4260b0ce0bfSmrg# the next Automake release, Autoconf can make the AC_INIT 4270b0ce0bfSmrg# arguments mandatory, and then we can depend on a new Autoconf 4280b0ce0bfSmrg# release and drop the old call support. 4290b0ce0bfSmrgAC_DEFUN([AM_INIT_AUTOMAKE], 4300b0ce0bfSmrg[AC_PREREQ([2.65])dnl 4310b0ce0bfSmrgm4_ifdef([_$0_ALREADY_INIT], 4320b0ce0bfSmrg [m4_fatal([$0 expanded multiple times 4330b0ce0bfSmrg]m4_defn([_$0_ALREADY_INIT]))], 4340b0ce0bfSmrg [m4_define([_$0_ALREADY_INIT], m4_expansion_stack)])dnl 4350b0ce0bfSmrgdnl Autoconf wants to disallow AM_ names. We explicitly allow 4360b0ce0bfSmrgdnl the ones we care about. 4370b0ce0bfSmrgm4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl 4380b0ce0bfSmrgAC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl 4390b0ce0bfSmrgAC_REQUIRE([AC_PROG_INSTALL])dnl 4400b0ce0bfSmrgif test "`cd $srcdir && pwd`" != "`pwd`"; then 4410b0ce0bfSmrg # Use -I$(srcdir) only when $(srcdir) != ., so that make's output 4420b0ce0bfSmrg # is not polluted with repeated "-I." 4430b0ce0bfSmrg AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl 4440b0ce0bfSmrg # test to see if srcdir already configured 4450b0ce0bfSmrg if test -f $srcdir/config.status; then 4460b0ce0bfSmrg AC_MSG_ERROR([source directory already configured; run "make distclean" there first]) 4475a81ca49Smrg fi 4480b0ce0bfSmrgfi 4491b12faf6Smrg 4500b0ce0bfSmrg# test whether we have cygpath 4510b0ce0bfSmrgif test -z "$CYGPATH_W"; then 4520b0ce0bfSmrg if (cygpath --version) >/dev/null 2>/dev/null; then 4530b0ce0bfSmrg CYGPATH_W='cygpath -w' 4540b0ce0bfSmrg else 4550b0ce0bfSmrg CYGPATH_W=echo 4560b0ce0bfSmrg fi 4570b0ce0bfSmrgfi 4580b0ce0bfSmrgAC_SUBST([CYGPATH_W]) 4591b12faf6Smrg 4600b0ce0bfSmrg# Define the identity of the package. 4610b0ce0bfSmrgdnl Distinguish between old-style and new-style calls. 4620b0ce0bfSmrgm4_ifval([$2], 4630b0ce0bfSmrg[AC_DIAGNOSE([obsolete], 4640b0ce0bfSmrg [$0: two- and three-arguments forms are deprecated.]) 4650b0ce0bfSmrgm4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl 4660b0ce0bfSmrg AC_SUBST([PACKAGE], [$1])dnl 4670b0ce0bfSmrg AC_SUBST([VERSION], [$2])], 4680b0ce0bfSmrg[_AM_SET_OPTIONS([$1])dnl 4690b0ce0bfSmrgdnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT. 4700b0ce0bfSmrgm4_if( 4710b0ce0bfSmrg m4_ifset([AC_PACKAGE_NAME], [ok]):m4_ifset([AC_PACKAGE_VERSION], [ok]), 4720b0ce0bfSmrg [ok:ok],, 4730b0ce0bfSmrg [m4_fatal([AC_INIT should be called with package and version arguments])])dnl 4740b0ce0bfSmrg AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl 4750b0ce0bfSmrg AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl 4765a81ca49Smrg 4770b0ce0bfSmrg_AM_IF_OPTION([no-define],, 4780b0ce0bfSmrg[AC_DEFINE_UNQUOTED([PACKAGE], ["$PACKAGE"], [Name of package]) 4790b0ce0bfSmrg AC_DEFINE_UNQUOTED([VERSION], ["$VERSION"], [Version number of package])])dnl 4805a81ca49Smrg 4810b0ce0bfSmrg# Some tools Automake needs. 4820b0ce0bfSmrgAC_REQUIRE([AM_SANITY_CHECK])dnl 4830b0ce0bfSmrgAC_REQUIRE([AC_ARG_PROGRAM])dnl 4840b0ce0bfSmrgAM_MISSING_PROG([ACLOCAL], [aclocal-${am__api_version}]) 4850b0ce0bfSmrgAM_MISSING_PROG([AUTOCONF], [autoconf]) 4860b0ce0bfSmrgAM_MISSING_PROG([AUTOMAKE], [automake-${am__api_version}]) 4870b0ce0bfSmrgAM_MISSING_PROG([AUTOHEADER], [autoheader]) 4880b0ce0bfSmrgAM_MISSING_PROG([MAKEINFO], [makeinfo]) 4890b0ce0bfSmrgAC_REQUIRE([AM_PROG_INSTALL_SH])dnl 4900b0ce0bfSmrgAC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl 4910b0ce0bfSmrgAC_REQUIRE([AC_PROG_MKDIR_P])dnl 4920b0ce0bfSmrg# For better backward compatibility. To be removed once Automake 1.9.x 4930b0ce0bfSmrg# dies out for good. For more background, see: 4940b0ce0bfSmrg# <https://lists.gnu.org/archive/html/automake/2012-07/msg00001.html> 4950b0ce0bfSmrg# <https://lists.gnu.org/archive/html/automake/2012-07/msg00014.html> 4960b0ce0bfSmrgAC_SUBST([mkdir_p], ['$(MKDIR_P)']) 4970b0ce0bfSmrg# We need awk for the "check" target (and possibly the TAP driver). The 4980b0ce0bfSmrg# system "awk" is bad on some platforms. 4990b0ce0bfSmrgAC_REQUIRE([AC_PROG_AWK])dnl 5000b0ce0bfSmrgAC_REQUIRE([AC_PROG_MAKE_SET])dnl 5010b0ce0bfSmrgAC_REQUIRE([AM_SET_LEADING_DOT])dnl 5020b0ce0bfSmrg_AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])], 5030b0ce0bfSmrg [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])], 5040b0ce0bfSmrg [_AM_PROG_TAR([v7])])]) 5050b0ce0bfSmrg_AM_IF_OPTION([no-dependencies],, 5060b0ce0bfSmrg[AC_PROVIDE_IFELSE([AC_PROG_CC], 5070b0ce0bfSmrg [_AM_DEPENDENCIES([CC])], 5080b0ce0bfSmrg [m4_define([AC_PROG_CC], 5090b0ce0bfSmrg m4_defn([AC_PROG_CC])[_AM_DEPENDENCIES([CC])])])dnl 5100b0ce0bfSmrgAC_PROVIDE_IFELSE([AC_PROG_CXX], 5110b0ce0bfSmrg [_AM_DEPENDENCIES([CXX])], 5120b0ce0bfSmrg [m4_define([AC_PROG_CXX], 5130b0ce0bfSmrg m4_defn([AC_PROG_CXX])[_AM_DEPENDENCIES([CXX])])])dnl 5140b0ce0bfSmrgAC_PROVIDE_IFELSE([AC_PROG_OBJC], 5150b0ce0bfSmrg [_AM_DEPENDENCIES([OBJC])], 5160b0ce0bfSmrg [m4_define([AC_PROG_OBJC], 5170b0ce0bfSmrg m4_defn([AC_PROG_OBJC])[_AM_DEPENDENCIES([OBJC])])])dnl 5180b0ce0bfSmrgAC_PROVIDE_IFELSE([AC_PROG_OBJCXX], 5190b0ce0bfSmrg [_AM_DEPENDENCIES([OBJCXX])], 5200b0ce0bfSmrg [m4_define([AC_PROG_OBJCXX], 5210b0ce0bfSmrg m4_defn([AC_PROG_OBJCXX])[_AM_DEPENDENCIES([OBJCXX])])])dnl 5221b12faf6Smrg]) 5230b0ce0bfSmrg# Variables for tags utilities; see am/tags.am 5240b0ce0bfSmrgif test -z "$CTAGS"; then 5250b0ce0bfSmrg CTAGS=ctags 5260b0ce0bfSmrgfi 5270b0ce0bfSmrgAC_SUBST([CTAGS]) 5280b0ce0bfSmrgif test -z "$ETAGS"; then 5290b0ce0bfSmrg ETAGS=etags 5300b0ce0bfSmrgfi 5310b0ce0bfSmrgAC_SUBST([ETAGS]) 5320b0ce0bfSmrgif test -z "$CSCOPE"; then 5330b0ce0bfSmrg CSCOPE=cscope 5340b0ce0bfSmrgfi 5350b0ce0bfSmrgAC_SUBST([CSCOPE]) 5361b12faf6Smrg 5370b0ce0bfSmrgAC_REQUIRE([AM_SILENT_RULES])dnl 5380b0ce0bfSmrgdnl The testsuite driver may need to know about EXEEXT, so add the 5390b0ce0bfSmrgdnl 'am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This 5400b0ce0bfSmrgdnl macro is hooked onto _AC_COMPILER_EXEEXT early, see below. 5410b0ce0bfSmrgAC_CONFIG_COMMANDS_PRE(dnl 5420b0ce0bfSmrg[m4_provide_if([_AM_COMPILER_EXEEXT], 5430b0ce0bfSmrg [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl 5441b12faf6Smrg 5450b0ce0bfSmrg# POSIX will say in a future version that running "rm -f" with no argument 5460b0ce0bfSmrg# is OK; and we want to be able to make that assumption in our Makefile 5470b0ce0bfSmrg# recipes. So use an aggressive probe to check that the usage we want is 5480b0ce0bfSmrg# actually supported "in the wild" to an acceptable degree. 5490b0ce0bfSmrg# See automake bug#10828. 5500b0ce0bfSmrg# To make any issue more visible, cause the running configure to be aborted 5510b0ce0bfSmrg# by default if the 'rm' program in use doesn't match our expectations; the 5520b0ce0bfSmrg# user can still override this though. 5530b0ce0bfSmrgif rm -f && rm -fr && rm -rf; then : OK; else 5540b0ce0bfSmrg cat >&2 <<'END' 5550b0ce0bfSmrgOops! 5561b12faf6Smrg 5570b0ce0bfSmrgYour 'rm' program seems unable to run without file operands specified 5580b0ce0bfSmrgon the command line, even when the '-f' option is present. This is contrary 5590b0ce0bfSmrgto the behaviour of most rm programs out there, and not conforming with 5600b0ce0bfSmrgthe upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542> 5611b12faf6Smrg 5620b0ce0bfSmrgPlease tell bug-automake@gnu.org about your system, including the value 5630b0ce0bfSmrgof your $PATH and any error possibly output before this message. This 5640b0ce0bfSmrgcan help us improve future automake versions. 5651b12faf6Smrg 5660b0ce0bfSmrgEND 5670b0ce0bfSmrg if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then 5680b0ce0bfSmrg echo 'Configuration will proceed anyway, since you have set the' >&2 5690b0ce0bfSmrg echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2 5700b0ce0bfSmrg echo >&2 5710b0ce0bfSmrg else 5720b0ce0bfSmrg cat >&2 <<'END' 5730b0ce0bfSmrgAborting the configuration process, to ensure you take notice of the issue. 5741b12faf6Smrg 5750b0ce0bfSmrgYou can download and install GNU coreutils to get an 'rm' implementation 5760b0ce0bfSmrgthat behaves properly: <https://www.gnu.org/software/coreutils/>. 5771b12faf6Smrg 5780b0ce0bfSmrgIf you want to complete the configuration process using your problematic 5790b0ce0bfSmrg'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM 5800b0ce0bfSmrgto "yes", and re-run configure. 5811b12faf6Smrg 5820b0ce0bfSmrgEND 5830b0ce0bfSmrg AC_MSG_ERROR([Your 'rm' program is bad, sorry.]) 5840b0ce0bfSmrg fi 5850b0ce0bfSmrgfi 5860b0ce0bfSmrgdnl The trailing newline in this macro's definition is deliberate, for 5870b0ce0bfSmrgdnl backward compatibility and to allow trailing 'dnl'-style comments 5880b0ce0bfSmrgdnl after the AM_INIT_AUTOMAKE invocation. See automake bug#16841. 5890b0ce0bfSmrg]) 5901b12faf6Smrg 5910b0ce0bfSmrgdnl Hook into '_AC_COMPILER_EXEEXT' early to learn its expansion. Do not 5920b0ce0bfSmrgdnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further 5930b0ce0bfSmrgdnl mangled by Autoconf and run in a shell conditional statement. 5940b0ce0bfSmrgm4_define([_AC_COMPILER_EXEEXT], 5950b0ce0bfSmrgm4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])]) 5961b12faf6Smrg 5970b0ce0bfSmrg# When config.status generates a header, we must update the stamp-h file. 5980b0ce0bfSmrg# This file resides in the same directory as the config header 5990b0ce0bfSmrg# that is generated. The stamp files are numbered to have different names. 6001b12faf6Smrg 6010b0ce0bfSmrg# Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the 6020b0ce0bfSmrg# loop where config.status creates the headers, so we can generate 6030b0ce0bfSmrg# our stamp files there. 6040b0ce0bfSmrgAC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK], 6050b0ce0bfSmrg[# Compute $1's index in $config_headers. 6060b0ce0bfSmrg_am_arg=$1 6070b0ce0bfSmrg_am_stamp_count=1 6080b0ce0bfSmrgfor _am_header in $config_headers :; do 6090b0ce0bfSmrg case $_am_header in 6100b0ce0bfSmrg $_am_arg | $_am_arg:* ) 6110b0ce0bfSmrg break ;; 6120b0ce0bfSmrg * ) 6130b0ce0bfSmrg _am_stamp_count=`expr $_am_stamp_count + 1` ;; 6140b0ce0bfSmrg esac 6150b0ce0bfSmrgdone 6160b0ce0bfSmrgecho "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count]) 6171b12faf6Smrg 6180b0ce0bfSmrg# Copyright (C) 2001-2021 Free Software Foundation, Inc. 6190b0ce0bfSmrg# 6200b0ce0bfSmrg# This file is free software; the Free Software Foundation 6210b0ce0bfSmrg# gives unlimited permission to copy and/or distribute it, 6220b0ce0bfSmrg# with or without modifications, as long as this notice is preserved. 6231b12faf6Smrg 6240b0ce0bfSmrg# AM_PROG_INSTALL_SH 6250b0ce0bfSmrg# ------------------ 6260b0ce0bfSmrg# Define $install_sh. 6270b0ce0bfSmrgAC_DEFUN([AM_PROG_INSTALL_SH], 6280b0ce0bfSmrg[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl 6290b0ce0bfSmrgif test x"${install_sh+set}" != xset; then 6300b0ce0bfSmrg case $am_aux_dir in 6310b0ce0bfSmrg *\ * | *\ *) 6320b0ce0bfSmrg install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;; 6330b0ce0bfSmrg *) 6340b0ce0bfSmrg install_sh="\${SHELL} $am_aux_dir/install-sh" 6350b0ce0bfSmrg esac 6360b0ce0bfSmrgfi 6370b0ce0bfSmrgAC_SUBST([install_sh])]) 6381b12faf6Smrg 6390b0ce0bfSmrg# Copyright (C) 2003-2021 Free Software Foundation, Inc. 6400b0ce0bfSmrg# 6410b0ce0bfSmrg# This file is free software; the Free Software Foundation 6420b0ce0bfSmrg# gives unlimited permission to copy and/or distribute it, 6430b0ce0bfSmrg# with or without modifications, as long as this notice is preserved. 6441b12faf6Smrg 6450b0ce0bfSmrg# Check whether the underlying file-system supports filenames 6460b0ce0bfSmrg# with a leading dot. For instance MS-DOS doesn't. 6470b0ce0bfSmrgAC_DEFUN([AM_SET_LEADING_DOT], 6480b0ce0bfSmrg[rm -rf .tst 2>/dev/null 6490b0ce0bfSmrgmkdir .tst 2>/dev/null 6500b0ce0bfSmrgif test -d .tst; then 6510b0ce0bfSmrg am__leading_dot=. 6520b0ce0bfSmrgelse 6530b0ce0bfSmrg am__leading_dot=_ 6540b0ce0bfSmrgfi 6550b0ce0bfSmrgrmdir .tst 2>/dev/null 6560b0ce0bfSmrgAC_SUBST([am__leading_dot])]) 65732b578d3Smrg 6580b0ce0bfSmrg# Check to see how 'make' treats includes. -*- Autoconf -*- 65932b578d3Smrg 6600b0ce0bfSmrg# Copyright (C) 2001-2021 Free Software Foundation, Inc. 6610b0ce0bfSmrg# 6620b0ce0bfSmrg# This file is free software; the Free Software Foundation 6630b0ce0bfSmrg# gives unlimited permission to copy and/or distribute it, 6640b0ce0bfSmrg# with or without modifications, as long as this notice is preserved. 6651b12faf6Smrg 6660b0ce0bfSmrg# AM_MAKE_INCLUDE() 6670b0ce0bfSmrg# ----------------- 6680b0ce0bfSmrg# Check whether make has an 'include' directive that can support all 6690b0ce0bfSmrg# the idioms we need for our automatic dependency tracking code. 6700b0ce0bfSmrgAC_DEFUN([AM_MAKE_INCLUDE], 6710b0ce0bfSmrg[AC_MSG_CHECKING([whether ${MAKE-make} supports the include directive]) 6720b0ce0bfSmrgcat > confinc.mk << 'END' 6730b0ce0bfSmrgam__doit: 6740b0ce0bfSmrg @echo this is the am__doit target >confinc.out 6750b0ce0bfSmrg.PHONY: am__doit 6760b0ce0bfSmrgEND 6770b0ce0bfSmrgam__include="#" 6780b0ce0bfSmrgam__quote= 6790b0ce0bfSmrg# BSD make does it like this. 6800b0ce0bfSmrgecho '.include "confinc.mk" # ignored' > confmf.BSD 6810b0ce0bfSmrg# Other make implementations (GNU, Solaris 10, AIX) do it like this. 6820b0ce0bfSmrgecho 'include confinc.mk # ignored' > confmf.GNU 6830b0ce0bfSmrg_am_result=no 6840b0ce0bfSmrgfor s in GNU BSD; do 6850b0ce0bfSmrg AM_RUN_LOG([${MAKE-make} -f confmf.$s && cat confinc.out]) 6860b0ce0bfSmrg AS_CASE([$?:`cat confinc.out 2>/dev/null`], 6870b0ce0bfSmrg ['0:this is the am__doit target'], 6880b0ce0bfSmrg [AS_CASE([$s], 6890b0ce0bfSmrg [BSD], [am__include='.include' am__quote='"'], 6900b0ce0bfSmrg [am__include='include' am__quote=''])]) 6910b0ce0bfSmrg if test "$am__include" != "#"; then 6920b0ce0bfSmrg _am_result="yes ($s style)" 6930b0ce0bfSmrg break 6940b0ce0bfSmrg fi 6950b0ce0bfSmrgdone 6960b0ce0bfSmrgrm -f confinc.* confmf.* 6970b0ce0bfSmrgAC_MSG_RESULT([${_am_result}]) 6980b0ce0bfSmrgAC_SUBST([am__include])]) 6990b0ce0bfSmrgAC_SUBST([am__quote])]) 7001b12faf6Smrg 7010b0ce0bfSmrg# Fake the existence of programs that GNU maintainers use. -*- Autoconf -*- 7021b12faf6Smrg 7030b0ce0bfSmrg# Copyright (C) 1997-2021 Free Software Foundation, Inc. 7040b0ce0bfSmrg# 7050b0ce0bfSmrg# This file is free software; the Free Software Foundation 7060b0ce0bfSmrg# gives unlimited permission to copy and/or distribute it, 7070b0ce0bfSmrg# with or without modifications, as long as this notice is preserved. 7081b12faf6Smrg 7090b0ce0bfSmrg# AM_MISSING_PROG(NAME, PROGRAM) 7100b0ce0bfSmrg# ------------------------------ 7110b0ce0bfSmrgAC_DEFUN([AM_MISSING_PROG], 7120b0ce0bfSmrg[AC_REQUIRE([AM_MISSING_HAS_RUN]) 7130b0ce0bfSmrg$1=${$1-"${am_missing_run}$2"} 7140b0ce0bfSmrgAC_SUBST($1)]) 7151b12faf6Smrg 7160b0ce0bfSmrg# AM_MISSING_HAS_RUN 7170b0ce0bfSmrg# ------------------ 7180b0ce0bfSmrg# Define MISSING if not defined so far and test if it is modern enough. 7190b0ce0bfSmrg# If it is, set am_missing_run to use it, otherwise, to nothing. 7200b0ce0bfSmrgAC_DEFUN([AM_MISSING_HAS_RUN], 7210b0ce0bfSmrg[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl 7220b0ce0bfSmrgAC_REQUIRE_AUX_FILE([missing])dnl 7230b0ce0bfSmrgif test x"${MISSING+set}" != xset; then 7240b0ce0bfSmrg MISSING="\${SHELL} '$am_aux_dir/missing'" 7250b0ce0bfSmrgfi 7260b0ce0bfSmrg# Use eval to expand $SHELL 7270b0ce0bfSmrgif eval "$MISSING --is-lightweight"; then 7280b0ce0bfSmrg am_missing_run="$MISSING " 7290b0ce0bfSmrgelse 7300b0ce0bfSmrg am_missing_run= 7310b0ce0bfSmrg AC_MSG_WARN(['missing' script is too old or missing]) 7320b0ce0bfSmrgfi 733e35d4d8eSmrg]) 7341b12faf6Smrg 7350b0ce0bfSmrg# Helper functions for option handling. -*- Autoconf -*- 7361b12faf6Smrg 7370b0ce0bfSmrg# Copyright (C) 2001-2021 Free Software Foundation, Inc. 7380b0ce0bfSmrg# 7390b0ce0bfSmrg# This file is free software; the Free Software Foundation 7400b0ce0bfSmrg# gives unlimited permission to copy and/or distribute it, 7410b0ce0bfSmrg# with or without modifications, as long as this notice is preserved. 7421b12faf6Smrg 7430b0ce0bfSmrg# _AM_MANGLE_OPTION(NAME) 7440b0ce0bfSmrg# ----------------------- 7450b0ce0bfSmrgAC_DEFUN([_AM_MANGLE_OPTION], 7460b0ce0bfSmrg[[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])]) 7471b12faf6Smrg 7480b0ce0bfSmrg# _AM_SET_OPTION(NAME) 7490b0ce0bfSmrg# -------------------- 7500b0ce0bfSmrg# Set option NAME. Presently that only means defining a flag for this option. 7510b0ce0bfSmrgAC_DEFUN([_AM_SET_OPTION], 7520b0ce0bfSmrg[m4_define(_AM_MANGLE_OPTION([$1]), [1])]) 7531b12faf6Smrg 7540b0ce0bfSmrg# _AM_SET_OPTIONS(OPTIONS) 7550b0ce0bfSmrg# ------------------------ 7560b0ce0bfSmrg# OPTIONS is a space-separated list of Automake options. 7570b0ce0bfSmrgAC_DEFUN([_AM_SET_OPTIONS], 7580b0ce0bfSmrg[m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])]) 7591b12faf6Smrg 7600b0ce0bfSmrg# _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET]) 7610b0ce0bfSmrg# ------------------------------------------- 7620b0ce0bfSmrg# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. 7630b0ce0bfSmrgAC_DEFUN([_AM_IF_OPTION], 7640b0ce0bfSmrg[m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])]) 7651b12faf6Smrg 7660b0ce0bfSmrg# Copyright (C) 1999-2021 Free Software Foundation, Inc. 767e35d4d8eSmrg# 7680b0ce0bfSmrg# This file is free software; the Free Software Foundation 7690b0ce0bfSmrg# gives unlimited permission to copy and/or distribute it, 7700b0ce0bfSmrg# with or without modifications, as long as this notice is preserved. 7711b12faf6Smrg 7720b0ce0bfSmrg# _AM_PROG_CC_C_O 7730b0ce0bfSmrg# --------------- 7740b0ce0bfSmrg# Like AC_PROG_CC_C_O, but changed for automake. We rewrite AC_PROG_CC 7750b0ce0bfSmrg# to automatically call this. 7760b0ce0bfSmrgAC_DEFUN([_AM_PROG_CC_C_O], 7770b0ce0bfSmrg[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl 7780b0ce0bfSmrgAC_REQUIRE_AUX_FILE([compile])dnl 7790b0ce0bfSmrgAC_LANG_PUSH([C])dnl 7800b0ce0bfSmrgAC_CACHE_CHECK( 7810b0ce0bfSmrg [whether $CC understands -c and -o together], 7820b0ce0bfSmrg [am_cv_prog_cc_c_o], 7830b0ce0bfSmrg [AC_LANG_CONFTEST([AC_LANG_PROGRAM([])]) 7840b0ce0bfSmrg # Make sure it works both with $CC and with simple cc. 7850b0ce0bfSmrg # Following AC_PROG_CC_C_O, we do the test twice because some 7860b0ce0bfSmrg # compilers refuse to overwrite an existing .o file with -o, 7870b0ce0bfSmrg # though they will create one. 7880b0ce0bfSmrg am_cv_prog_cc_c_o=yes 7890b0ce0bfSmrg for am_i in 1 2; do 7900b0ce0bfSmrg if AM_RUN_LOG([$CC -c conftest.$ac_ext -o conftest2.$ac_objext]) \ 7910b0ce0bfSmrg && test -f conftest2.$ac_objext; then 7920b0ce0bfSmrg : OK 7930b0ce0bfSmrg else 7940b0ce0bfSmrg am_cv_prog_cc_c_o=no 7950b0ce0bfSmrg break 7960b0ce0bfSmrg fi 7970b0ce0bfSmrg done 7980b0ce0bfSmrg rm -f core conftest* 7990b0ce0bfSmrg unset am_i]) 8000b0ce0bfSmrgif test "$am_cv_prog_cc_c_o" != yes; then 8010b0ce0bfSmrg # Losing compiler, so override with the script. 8020b0ce0bfSmrg # FIXME: It is wrong to rewrite CC. 8030b0ce0bfSmrg # But if we don't then we get into trouble of one sort or another. 8040b0ce0bfSmrg # A longer-term fix would be to have automake use am__CC in this case, 8050b0ce0bfSmrg # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)" 8060b0ce0bfSmrg CC="$am_aux_dir/compile $CC" 8070b0ce0bfSmrgfi 8080b0ce0bfSmrgAC_LANG_POP([C])]) 8091b12faf6Smrg 8100b0ce0bfSmrg# For backward compatibility. 8110b0ce0bfSmrgAC_DEFUN_ONCE([AM_PROG_CC_C_O], [AC_REQUIRE([AC_PROG_CC])]) 8121b12faf6Smrg 8130b0ce0bfSmrg# Copyright (C) 2001-2021 Free Software Foundation, Inc. 814e35d4d8eSmrg# 8150b0ce0bfSmrg# This file is free software; the Free Software Foundation 8160b0ce0bfSmrg# gives unlimited permission to copy and/or distribute it, 8170b0ce0bfSmrg# with or without modifications, as long as this notice is preserved. 8181b12faf6Smrg 8190b0ce0bfSmrg# AM_RUN_LOG(COMMAND) 8200b0ce0bfSmrg# ------------------- 8210b0ce0bfSmrg# Run COMMAND, save the exit status in ac_status, and log it. 8220b0ce0bfSmrg# (This has been adapted from Autoconf's _AC_RUN_LOG macro.) 8230b0ce0bfSmrgAC_DEFUN([AM_RUN_LOG], 8240b0ce0bfSmrg[{ echo "$as_me:$LINENO: $1" >&AS_MESSAGE_LOG_FD 8250b0ce0bfSmrg ($1) >&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD 8260b0ce0bfSmrg ac_status=$? 8270b0ce0bfSmrg echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD 8280b0ce0bfSmrg (exit $ac_status); }]) 8291b12faf6Smrg 8300b0ce0bfSmrg# Check to make sure that the build environment is sane. -*- Autoconf -*- 8311b12faf6Smrg 8320b0ce0bfSmrg# Copyright (C) 1996-2021 Free Software Foundation, Inc. 8330b0ce0bfSmrg# 8340b0ce0bfSmrg# This file is free software; the Free Software Foundation 8350b0ce0bfSmrg# gives unlimited permission to copy and/or distribute it, 8360b0ce0bfSmrg# with or without modifications, as long as this notice is preserved. 8371b12faf6Smrg 8380b0ce0bfSmrg# AM_SANITY_CHECK 8390b0ce0bfSmrg# --------------- 8400b0ce0bfSmrgAC_DEFUN([AM_SANITY_CHECK], 8410b0ce0bfSmrg[AC_MSG_CHECKING([whether build environment is sane]) 8420b0ce0bfSmrg# Reject unsafe characters in $srcdir or the absolute working directory 8430b0ce0bfSmrg# name. Accept space and tab only in the latter. 8440b0ce0bfSmrgam_lf=' 8450b0ce0bfSmrg' 8460b0ce0bfSmrgcase `pwd` in 8470b0ce0bfSmrg *[[\\\"\#\$\&\'\`$am_lf]]*) 8480b0ce0bfSmrg AC_MSG_ERROR([unsafe absolute working directory name]);; 8490b0ce0bfSmrgesac 8500b0ce0bfSmrgcase $srcdir in 8510b0ce0bfSmrg *[[\\\"\#\$\&\'\`$am_lf\ \ ]]*) 8520b0ce0bfSmrg AC_MSG_ERROR([unsafe srcdir value: '$srcdir']);; 8530b0ce0bfSmrgesac 8541b12faf6Smrg 8550b0ce0bfSmrg# Do 'set' in a subshell so we don't clobber the current shell's 8560b0ce0bfSmrg# arguments. Must try -L first in case configure is actually a 8570b0ce0bfSmrg# symlink; some systems play weird games with the mod time of symlinks 8580b0ce0bfSmrg# (eg FreeBSD returns the mod time of the symlink's containing 8590b0ce0bfSmrg# directory). 8600b0ce0bfSmrgif ( 8610b0ce0bfSmrg am_has_slept=no 8620b0ce0bfSmrg for am_try in 1 2; do 8630b0ce0bfSmrg echo "timestamp, slept: $am_has_slept" > conftest.file 8640b0ce0bfSmrg set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` 8650b0ce0bfSmrg if test "$[*]" = "X"; then 8660b0ce0bfSmrg # -L didn't work. 8670b0ce0bfSmrg set X `ls -t "$srcdir/configure" conftest.file` 8680b0ce0bfSmrg fi 8690b0ce0bfSmrg if test "$[*]" != "X $srcdir/configure conftest.file" \ 8700b0ce0bfSmrg && test "$[*]" != "X conftest.file $srcdir/configure"; then 871e35d4d8eSmrg 8720b0ce0bfSmrg # If neither matched, then we have a broken ls. This can happen 8730b0ce0bfSmrg # if, for instance, CONFIG_SHELL is bash and it inherits a 8740b0ce0bfSmrg # broken ls alias from the environment. This has actually 8750b0ce0bfSmrg # happened. Such a system could not be considered "sane". 8760b0ce0bfSmrg AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken 8770b0ce0bfSmrg alias in your environment]) 8780b0ce0bfSmrg fi 8790b0ce0bfSmrg if test "$[2]" = conftest.file || test $am_try -eq 2; then 8800b0ce0bfSmrg break 8810b0ce0bfSmrg fi 8820b0ce0bfSmrg # Just in case. 8830b0ce0bfSmrg sleep 1 8840b0ce0bfSmrg am_has_slept=yes 8850b0ce0bfSmrg done 8860b0ce0bfSmrg test "$[2]" = conftest.file 8870b0ce0bfSmrg ) 8880b0ce0bfSmrgthen 8890b0ce0bfSmrg # Ok. 8900b0ce0bfSmrg : 8910b0ce0bfSmrgelse 8920b0ce0bfSmrg AC_MSG_ERROR([newly created file is older than distributed files! 8930b0ce0bfSmrgCheck your system clock]) 8940b0ce0bfSmrgfi 8950b0ce0bfSmrgAC_MSG_RESULT([yes]) 8960b0ce0bfSmrg# If we didn't sleep, we still need to ensure time stamps of config.status and 8970b0ce0bfSmrg# generated files are strictly newer. 8980b0ce0bfSmrgam_sleep_pid= 8990b0ce0bfSmrgif grep 'slept: no' conftest.file >/dev/null 2>&1; then 9000b0ce0bfSmrg ( sleep 1 ) & 9010b0ce0bfSmrg am_sleep_pid=$! 9020b0ce0bfSmrgfi 9030b0ce0bfSmrgAC_CONFIG_COMMANDS_PRE( 9040b0ce0bfSmrg [AC_MSG_CHECKING([that generated files are newer than configure]) 9050b0ce0bfSmrg if test -n "$am_sleep_pid"; then 9060b0ce0bfSmrg # Hide warnings about reused PIDs. 9070b0ce0bfSmrg wait $am_sleep_pid 2>/dev/null 9080b0ce0bfSmrg fi 9090b0ce0bfSmrg AC_MSG_RESULT([done])]) 9100b0ce0bfSmrgrm -f conftest.file 9110b0ce0bfSmrg]) 912e35d4d8eSmrg 9130b0ce0bfSmrg# Copyright (C) 2009-2021 Free Software Foundation, Inc. 9140b0ce0bfSmrg# 9150b0ce0bfSmrg# This file is free software; the Free Software Foundation 9160b0ce0bfSmrg# gives unlimited permission to copy and/or distribute it, 9170b0ce0bfSmrg# with or without modifications, as long as this notice is preserved. 918e35d4d8eSmrg 9190b0ce0bfSmrg# AM_SILENT_RULES([DEFAULT]) 9200b0ce0bfSmrg# -------------------------- 9210b0ce0bfSmrg# Enable less verbose build rules; with the default set to DEFAULT 9220b0ce0bfSmrg# ("yes" being less verbose, "no" or empty being verbose). 9230b0ce0bfSmrgAC_DEFUN([AM_SILENT_RULES], 9240b0ce0bfSmrg[AC_ARG_ENABLE([silent-rules], [dnl 9250b0ce0bfSmrgAS_HELP_STRING( 9260b0ce0bfSmrg [--enable-silent-rules], 9270b0ce0bfSmrg [less verbose build output (undo: "make V=1")]) 9280b0ce0bfSmrgAS_HELP_STRING( 9290b0ce0bfSmrg [--disable-silent-rules], 9300b0ce0bfSmrg [verbose build output (undo: "make V=0")])dnl 9310b0ce0bfSmrg]) 9320b0ce0bfSmrgcase $enable_silent_rules in @%:@ ((( 9330b0ce0bfSmrg yes) AM_DEFAULT_VERBOSITY=0;; 9340b0ce0bfSmrg no) AM_DEFAULT_VERBOSITY=1;; 9350b0ce0bfSmrg *) AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);; 9360b0ce0bfSmrgesac 9370b0ce0bfSmrgdnl 9380b0ce0bfSmrgdnl A few 'make' implementations (e.g., NonStop OS and NextStep) 9390b0ce0bfSmrgdnl do not support nested variable expansions. 9400b0ce0bfSmrgdnl See automake bug#9928 and bug#10237. 9410b0ce0bfSmrgam_make=${MAKE-make} 9420b0ce0bfSmrgAC_CACHE_CHECK([whether $am_make supports nested variables], 9430b0ce0bfSmrg [am_cv_make_support_nested_variables], 9440b0ce0bfSmrg [if AS_ECHO([['TRUE=$(BAR$(V)) 9450b0ce0bfSmrgBAR0=false 9460b0ce0bfSmrgBAR1=true 9470b0ce0bfSmrgV=1 9480b0ce0bfSmrgam__doit: 9490b0ce0bfSmrg @$(TRUE) 9500b0ce0bfSmrg.PHONY: am__doit']]) | $am_make -f - >/dev/null 2>&1; then 9510b0ce0bfSmrg am_cv_make_support_nested_variables=yes 9520b0ce0bfSmrgelse 9530b0ce0bfSmrg am_cv_make_support_nested_variables=no 9540b0ce0bfSmrgfi]) 9550b0ce0bfSmrgif test $am_cv_make_support_nested_variables = yes; then 9560b0ce0bfSmrg dnl Using '$V' instead of '$(V)' breaks IRIX make. 9570b0ce0bfSmrg AM_V='$(V)' 9580b0ce0bfSmrg AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)' 9590b0ce0bfSmrgelse 9600b0ce0bfSmrg AM_V=$AM_DEFAULT_VERBOSITY 9610b0ce0bfSmrg AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY 9620b0ce0bfSmrgfi 9630b0ce0bfSmrgAC_SUBST([AM_V])dnl 9640b0ce0bfSmrgAM_SUBST_NOTMAKE([AM_V])dnl 9650b0ce0bfSmrgAC_SUBST([AM_DEFAULT_V])dnl 9660b0ce0bfSmrgAM_SUBST_NOTMAKE([AM_DEFAULT_V])dnl 9670b0ce0bfSmrgAC_SUBST([AM_DEFAULT_VERBOSITY])dnl 9680b0ce0bfSmrgAM_BACKSLASH='\' 9690b0ce0bfSmrgAC_SUBST([AM_BACKSLASH])dnl 9700b0ce0bfSmrg_AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl 9710b0ce0bfSmrg]) 9725a81ca49Smrg 9730b0ce0bfSmrg# Copyright (C) 2001-2021 Free Software Foundation, Inc. 9740b0ce0bfSmrg# 9750b0ce0bfSmrg# This file is free software; the Free Software Foundation 9760b0ce0bfSmrg# gives unlimited permission to copy and/or distribute it, 9770b0ce0bfSmrg# with or without modifications, as long as this notice is preserved. 978e35d4d8eSmrg 9790b0ce0bfSmrg# AM_PROG_INSTALL_STRIP 9800b0ce0bfSmrg# --------------------- 9810b0ce0bfSmrg# One issue with vendor 'install' (even GNU) is that you can't 9820b0ce0bfSmrg# specify the program used to strip binaries. This is especially 9830b0ce0bfSmrg# annoying in cross-compiling environments, where the build's strip 9840b0ce0bfSmrg# is unlikely to handle the host's binaries. 9850b0ce0bfSmrg# Fortunately install-sh will honor a STRIPPROG variable, so we 9860b0ce0bfSmrg# always use install-sh in "make install-strip", and initialize 9870b0ce0bfSmrg# STRIPPROG with the value of the STRIP variable (set by the user). 9880b0ce0bfSmrgAC_DEFUN([AM_PROG_INSTALL_STRIP], 9890b0ce0bfSmrg[AC_REQUIRE([AM_PROG_INSTALL_SH])dnl 9900b0ce0bfSmrg# Installed binaries are usually stripped using 'strip' when the user 9910b0ce0bfSmrg# run "make install-strip". However 'strip' might not be the right 9920b0ce0bfSmrg# tool to use in cross-compilation environments, therefore Automake 9930b0ce0bfSmrg# will honor the 'STRIP' environment variable to overrule this program. 9940b0ce0bfSmrgdnl Don't test for $cross_compiling = yes, because it might be 'maybe'. 9950b0ce0bfSmrgif test "$cross_compiling" != no; then 9960b0ce0bfSmrg AC_CHECK_TOOL([STRIP], [strip], :) 9970b0ce0bfSmrgfi 9980b0ce0bfSmrgINSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" 9990b0ce0bfSmrgAC_SUBST([INSTALL_STRIP_PROGRAM])]) 10001b12faf6Smrg 10010b0ce0bfSmrg# Copyright (C) 2006-2021 Free Software Foundation, Inc. 10020b0ce0bfSmrg# 10030b0ce0bfSmrg# This file is free software; the Free Software Foundation 10040b0ce0bfSmrg# gives unlimited permission to copy and/or distribute it, 10050b0ce0bfSmrg# with or without modifications, as long as this notice is preserved. 10061b12faf6Smrg 10070b0ce0bfSmrg# _AM_SUBST_NOTMAKE(VARIABLE) 10080b0ce0bfSmrg# --------------------------- 10090b0ce0bfSmrg# Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in. 10100b0ce0bfSmrg# This macro is traced by Automake. 10110b0ce0bfSmrgAC_DEFUN([_AM_SUBST_NOTMAKE]) 10121b12faf6Smrg 10130b0ce0bfSmrg# AM_SUBST_NOTMAKE(VARIABLE) 10140b0ce0bfSmrg# -------------------------- 10150b0ce0bfSmrg# Public sister of _AM_SUBST_NOTMAKE. 10160b0ce0bfSmrgAC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)]) 10171b12faf6Smrg 10180b0ce0bfSmrg# Check how to create a tarball. -*- Autoconf -*- 10191b12faf6Smrg 10200b0ce0bfSmrg# Copyright (C) 2004-2021 Free Software Foundation, Inc. 10210b0ce0bfSmrg# 10220b0ce0bfSmrg# This file is free software; the Free Software Foundation 10230b0ce0bfSmrg# gives unlimited permission to copy and/or distribute it, 10240b0ce0bfSmrg# with or without modifications, as long as this notice is preserved. 10251b12faf6Smrg 10260b0ce0bfSmrg# _AM_PROG_TAR(FORMAT) 10270b0ce0bfSmrg# -------------------- 10280b0ce0bfSmrg# Check how to create a tarball in format FORMAT. 10290b0ce0bfSmrg# FORMAT should be one of 'v7', 'ustar', or 'pax'. 10300b0ce0bfSmrg# 10310b0ce0bfSmrg# Substitute a variable $(am__tar) that is a command 10320b0ce0bfSmrg# writing to stdout a FORMAT-tarball containing the directory 10330b0ce0bfSmrg# $tardir. 10340b0ce0bfSmrg# tardir=directory && $(am__tar) > result.tar 10350b0ce0bfSmrg# 10360b0ce0bfSmrg# Substitute a variable $(am__untar) that extract such 10370b0ce0bfSmrg# a tarball read from stdin. 10380b0ce0bfSmrg# $(am__untar) < result.tar 10390b0ce0bfSmrg# 10400b0ce0bfSmrgAC_DEFUN([_AM_PROG_TAR], 10410b0ce0bfSmrg[# Always define AMTAR for backward compatibility. Yes, it's still used 10420b0ce0bfSmrg# in the wild :-( We should find a proper way to deprecate it ... 10430b0ce0bfSmrgAC_SUBST([AMTAR], ['$${TAR-tar}']) 10441b12faf6Smrg 10450b0ce0bfSmrg# We'll loop over all known methods to create a tar archive until one works. 10460b0ce0bfSmrg_am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none' 10471b12faf6Smrg 10480b0ce0bfSmrgm4_if([$1], [v7], 10490b0ce0bfSmrg [am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'], 10501b12faf6Smrg 10510b0ce0bfSmrg [m4_case([$1], 10520b0ce0bfSmrg [ustar], 10530b0ce0bfSmrg [# The POSIX 1988 'ustar' format is defined with fixed-size fields. 10540b0ce0bfSmrg # There is notably a 21 bits limit for the UID and the GID. In fact, 10550b0ce0bfSmrg # the 'pax' utility can hang on bigger UID/GID (see automake bug#8343 10560b0ce0bfSmrg # and bug#13588). 10570b0ce0bfSmrg am_max_uid=2097151 # 2^21 - 1 10580b0ce0bfSmrg am_max_gid=$am_max_uid 10590b0ce0bfSmrg # The $UID and $GID variables are not portable, so we need to resort 10600b0ce0bfSmrg # to the POSIX-mandated id(1) utility. Errors in the 'id' calls 10610b0ce0bfSmrg # below are definitely unexpected, so allow the users to see them 10620b0ce0bfSmrg # (that is, avoid stderr redirection). 10630b0ce0bfSmrg am_uid=`id -u || echo unknown` 10640b0ce0bfSmrg am_gid=`id -g || echo unknown` 10650b0ce0bfSmrg AC_MSG_CHECKING([whether UID '$am_uid' is supported by ustar format]) 10660b0ce0bfSmrg if test $am_uid -le $am_max_uid; then 10670b0ce0bfSmrg AC_MSG_RESULT([yes]) 10680b0ce0bfSmrg else 10690b0ce0bfSmrg AC_MSG_RESULT([no]) 10700b0ce0bfSmrg _am_tools=none 10710b0ce0bfSmrg fi 10720b0ce0bfSmrg AC_MSG_CHECKING([whether GID '$am_gid' is supported by ustar format]) 10730b0ce0bfSmrg if test $am_gid -le $am_max_gid; then 10740b0ce0bfSmrg AC_MSG_RESULT([yes]) 10750b0ce0bfSmrg else 10760b0ce0bfSmrg AC_MSG_RESULT([no]) 10770b0ce0bfSmrg _am_tools=none 10780b0ce0bfSmrg fi], 10791b12faf6Smrg 10800b0ce0bfSmrg [pax], 10810b0ce0bfSmrg [], 10821b12faf6Smrg 10830b0ce0bfSmrg [m4_fatal([Unknown tar format])]) 10841b12faf6Smrg 10850b0ce0bfSmrg AC_MSG_CHECKING([how to create a $1 tar archive]) 10861b12faf6Smrg 10870b0ce0bfSmrg # Go ahead even if we have the value already cached. We do so because we 10880b0ce0bfSmrg # need to set the values for the 'am__tar' and 'am__untar' variables. 10890b0ce0bfSmrg _am_tools=${am_cv_prog_tar_$1-$_am_tools} 10901b12faf6Smrg 10910b0ce0bfSmrg for _am_tool in $_am_tools; do 10920b0ce0bfSmrg case $_am_tool in 10930b0ce0bfSmrg gnutar) 10940b0ce0bfSmrg for _am_tar in tar gnutar gtar; do 10950b0ce0bfSmrg AM_RUN_LOG([$_am_tar --version]) && break 10960b0ce0bfSmrg done 10970b0ce0bfSmrg am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"' 10980b0ce0bfSmrg am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"' 10990b0ce0bfSmrg am__untar="$_am_tar -xf -" 11000b0ce0bfSmrg ;; 11010b0ce0bfSmrg plaintar) 11020b0ce0bfSmrg # Must skip GNU tar: if it does not support --format= it doesn't create 11030b0ce0bfSmrg # ustar tarball either. 11040b0ce0bfSmrg (tar --version) >/dev/null 2>&1 && continue 11050b0ce0bfSmrg am__tar='tar chf - "$$tardir"' 11060b0ce0bfSmrg am__tar_='tar chf - "$tardir"' 11070b0ce0bfSmrg am__untar='tar xf -' 11080b0ce0bfSmrg ;; 11090b0ce0bfSmrg pax) 11100b0ce0bfSmrg am__tar='pax -L -x $1 -w "$$tardir"' 11110b0ce0bfSmrg am__tar_='pax -L -x $1 -w "$tardir"' 11120b0ce0bfSmrg am__untar='pax -r' 11130b0ce0bfSmrg ;; 11140b0ce0bfSmrg cpio) 11150b0ce0bfSmrg am__tar='find "$$tardir" -print | cpio -o -H $1 -L' 11160b0ce0bfSmrg am__tar_='find "$tardir" -print | cpio -o -H $1 -L' 11170b0ce0bfSmrg am__untar='cpio -i -H $1 -d' 11180b0ce0bfSmrg ;; 11190b0ce0bfSmrg none) 11200b0ce0bfSmrg am__tar=false 11210b0ce0bfSmrg am__tar_=false 11220b0ce0bfSmrg am__untar=false 11230b0ce0bfSmrg ;; 11240b0ce0bfSmrg esac 112532b578d3Smrg 11260b0ce0bfSmrg # If the value was cached, stop now. We just wanted to have am__tar 11270b0ce0bfSmrg # and am__untar set. 11280b0ce0bfSmrg test -n "${am_cv_prog_tar_$1}" && break 11291b12faf6Smrg 11300b0ce0bfSmrg # tar/untar a dummy directory, and stop if the command works. 11310b0ce0bfSmrg rm -rf conftest.dir 11320b0ce0bfSmrg mkdir conftest.dir 11330b0ce0bfSmrg echo GrepMe > conftest.dir/file 11340b0ce0bfSmrg AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar]) 11350b0ce0bfSmrg rm -rf conftest.dir 11360b0ce0bfSmrg if test -s conftest.tar; then 11370b0ce0bfSmrg AM_RUN_LOG([$am__untar <conftest.tar]) 11380b0ce0bfSmrg AM_RUN_LOG([cat conftest.dir/file]) 11390b0ce0bfSmrg grep GrepMe conftest.dir/file >/dev/null 2>&1 && break 11400b0ce0bfSmrg fi 11410b0ce0bfSmrg done 11420b0ce0bfSmrg rm -rf conftest.dir 114332b578d3Smrg 11440b0ce0bfSmrg AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool]) 11450b0ce0bfSmrg AC_MSG_RESULT([$am_cv_prog_tar_$1])]) 114632b578d3Smrg 11470b0ce0bfSmrgAC_SUBST([am__tar]) 11480b0ce0bfSmrgAC_SUBST([am__untar]) 11490b0ce0bfSmrg]) # _AM_PROG_TAR 115032b578d3Smrg 11510b0ce0bfSmrgdnl Copyright 2005 Red Hat, Inc 11520b0ce0bfSmrgdnl 11530b0ce0bfSmrgdnl Permission to use, copy, modify, distribute, and sell this software and its 11540b0ce0bfSmrgdnl documentation for any purpose is hereby granted without fee, provided that 11550b0ce0bfSmrgdnl the above copyright notice appear in all copies and that both that 11560b0ce0bfSmrgdnl copyright notice and this permission notice appear in supporting 11570b0ce0bfSmrgdnl documentation. 11580b0ce0bfSmrgdnl 11590b0ce0bfSmrgdnl The above copyright notice and this permission notice shall be included 11600b0ce0bfSmrgdnl in all copies or substantial portions of the Software. 11610b0ce0bfSmrgdnl 11620b0ce0bfSmrgdnl THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS 11630b0ce0bfSmrgdnl OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 11640b0ce0bfSmrgdnl MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 11650b0ce0bfSmrgdnl IN NO EVENT SHALL THE OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR 11660b0ce0bfSmrgdnl OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, 11670b0ce0bfSmrgdnl ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 11680b0ce0bfSmrgdnl OTHER DEALINGS IN THE SOFTWARE. 11690b0ce0bfSmrgdnl 11700b0ce0bfSmrgdnl Except as contained in this notice, the name of the copyright holders shall 11710b0ce0bfSmrgdnl not be used in advertising or otherwise to promote the sale, use or 11720b0ce0bfSmrgdnl other dealings in this Software without prior written authorization 11730b0ce0bfSmrgdnl from the copyright holders. 11740b0ce0bfSmrgdnl 117532b578d3Smrg 11760b0ce0bfSmrg# XORG_DRIVER_CHECK_EXT(MACRO, PROTO) 11770b0ce0bfSmrg# -------------------------- 11780b0ce0bfSmrg# Checks for the MACRO define in xorg-server.h (from the sdk). If it 11790b0ce0bfSmrg# is defined, then add the given PROTO to $REQUIRED_MODULES. 118032b578d3Smrg 11810b0ce0bfSmrgAC_DEFUN([XORG_DRIVER_CHECK_EXT],[ 11820b0ce0bfSmrg AC_REQUIRE([PKG_PROG_PKG_CONFIG]) 11830b0ce0bfSmrg SAVE_CFLAGS="$CFLAGS" 11840b0ce0bfSmrg CFLAGS="$CFLAGS -I`$PKG_CONFIG --variable=sdkdir xorg-server`" 11850b0ce0bfSmrg AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ 11860b0ce0bfSmrg#include "xorg-server.h" 11870b0ce0bfSmrg#if !defined $1 11880b0ce0bfSmrg#error $1 not defined 11890b0ce0bfSmrg#endif 11900b0ce0bfSmrg ]])], 11910b0ce0bfSmrg [_EXT_CHECK=yes], 11920b0ce0bfSmrg [_EXT_CHECK=no]) 11930b0ce0bfSmrg CFLAGS="$SAVE_CFLAGS" 11940b0ce0bfSmrg AC_MSG_CHECKING([if $1 is defined]) 11950b0ce0bfSmrg AC_MSG_RESULT([$_EXT_CHECK]) 11960b0ce0bfSmrg if test "$_EXT_CHECK" != no; then 11970b0ce0bfSmrg REQUIRED_MODULES="$REQUIRED_MODULES $2" 11980b0ce0bfSmrg fi 11990b0ce0bfSmrg]) 120032b578d3Smrg 12010b0ce0bfSmrgdnl pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*- 12020b0ce0bfSmrgdnl serial 11 (pkg-config-0.29) 12030b0ce0bfSmrgdnl 12040b0ce0bfSmrgdnl Copyright © 2004 Scott James Remnant <scott@netsplit.com>. 12050b0ce0bfSmrgdnl Copyright © 2012-2015 Dan Nicholson <dbn.lists@gmail.com> 12060b0ce0bfSmrgdnl 12070b0ce0bfSmrgdnl This program is free software; you can redistribute it and/or modify 12080b0ce0bfSmrgdnl it under the terms of the GNU General Public License as published by 12090b0ce0bfSmrgdnl the Free Software Foundation; either version 2 of the License, or 12100b0ce0bfSmrgdnl (at your option) any later version. 12110b0ce0bfSmrgdnl 12120b0ce0bfSmrgdnl This program is distributed in the hope that it will be useful, but 12130b0ce0bfSmrgdnl WITHOUT ANY WARRANTY; without even the implied warranty of 12140b0ce0bfSmrgdnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 12150b0ce0bfSmrgdnl General Public License for more details. 12160b0ce0bfSmrgdnl 12170b0ce0bfSmrgdnl You should have received a copy of the GNU General Public License 12180b0ce0bfSmrgdnl along with this program; if not, write to the Free Software 12190b0ce0bfSmrgdnl Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 12200b0ce0bfSmrgdnl 02111-1307, USA. 12210b0ce0bfSmrgdnl 12220b0ce0bfSmrgdnl As a special exception to the GNU General Public License, if you 12230b0ce0bfSmrgdnl distribute this file as part of a program that contains a 12240b0ce0bfSmrgdnl configuration script generated by Autoconf, you may include it under 12250b0ce0bfSmrgdnl the same distribution terms that you use for the rest of that 12260b0ce0bfSmrgdnl program. 12270b0ce0bfSmrg 12280b0ce0bfSmrgdnl PKG_PREREQ(MIN-VERSION) 12290b0ce0bfSmrgdnl ----------------------- 12300b0ce0bfSmrgdnl Since: 0.29 12310b0ce0bfSmrgdnl 12320b0ce0bfSmrgdnl Verify that the version of the pkg-config macros are at least 12330b0ce0bfSmrgdnl MIN-VERSION. Unlike PKG_PROG_PKG_CONFIG, which checks the user's 12340b0ce0bfSmrgdnl installed version of pkg-config, this checks the developer's version 12350b0ce0bfSmrgdnl of pkg.m4 when generating configure. 12360b0ce0bfSmrgdnl 12370b0ce0bfSmrgdnl To ensure that this macro is defined, also add: 12380b0ce0bfSmrgdnl m4_ifndef([PKG_PREREQ], 12390b0ce0bfSmrgdnl [m4_fatal([must install pkg-config 0.29 or later before running autoconf/autogen])]) 12400b0ce0bfSmrgdnl 12410b0ce0bfSmrgdnl See the "Since" comment for each macro you use to see what version 12420b0ce0bfSmrgdnl of the macros you require. 12430b0ce0bfSmrgm4_defun([PKG_PREREQ], 12440b0ce0bfSmrg[m4_define([PKG_MACROS_VERSION], [0.29]) 12450b0ce0bfSmrgm4_if(m4_version_compare(PKG_MACROS_VERSION, [$1]), -1, 12460b0ce0bfSmrg [m4_fatal([pkg.m4 version $1 or higher is required but ]PKG_MACROS_VERSION[ found])]) 12470b0ce0bfSmrg])dnl PKG_PREREQ 12480b0ce0bfSmrg 12490b0ce0bfSmrgdnl PKG_PROG_PKG_CONFIG([MIN-VERSION]) 12500b0ce0bfSmrgdnl ---------------------------------- 12510b0ce0bfSmrgdnl Since: 0.16 12520b0ce0bfSmrgdnl 12530b0ce0bfSmrgdnl Search for the pkg-config tool and set the PKG_CONFIG variable to 12540b0ce0bfSmrgdnl first found in the path. Checks that the version of pkg-config found 12550b0ce0bfSmrgdnl is at least MIN-VERSION. If MIN-VERSION is not specified, 0.9.0 is 12560b0ce0bfSmrgdnl used since that's the first version where most current features of 12570b0ce0bfSmrgdnl pkg-config existed. 12580b0ce0bfSmrgAC_DEFUN([PKG_PROG_PKG_CONFIG], 12590b0ce0bfSmrg[m4_pattern_forbid([^_?PKG_[A-Z_]+$]) 12600b0ce0bfSmrgm4_pattern_allow([^PKG_CONFIG(_(PATH|LIBDIR|SYSROOT_DIR|ALLOW_SYSTEM_(CFLAGS|LIBS)))?$]) 12610b0ce0bfSmrgm4_pattern_allow([^PKG_CONFIG_(DISABLE_UNINSTALLED|TOP_BUILD_DIR|DEBUG_SPEW)$]) 12620b0ce0bfSmrgAC_ARG_VAR([PKG_CONFIG], [path to pkg-config utility]) 12630b0ce0bfSmrgAC_ARG_VAR([PKG_CONFIG_PATH], [directories to add to pkg-config's search path]) 12640b0ce0bfSmrgAC_ARG_VAR([PKG_CONFIG_LIBDIR], [path overriding pkg-config's built-in search path]) 126532b578d3Smrg 12660b0ce0bfSmrgif test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then 12670b0ce0bfSmrg AC_PATH_TOOL([PKG_CONFIG], [pkg-config]) 12680b0ce0bfSmrgfi 12690b0ce0bfSmrgif test -n "$PKG_CONFIG"; then 12700b0ce0bfSmrg _pkg_min_version=m4_default([$1], [0.9.0]) 12710b0ce0bfSmrg AC_MSG_CHECKING([pkg-config is at least version $_pkg_min_version]) 12720b0ce0bfSmrg if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then 12730b0ce0bfSmrg AC_MSG_RESULT([yes]) 12740b0ce0bfSmrg else 12750b0ce0bfSmrg AC_MSG_RESULT([no]) 12760b0ce0bfSmrg PKG_CONFIG="" 12770b0ce0bfSmrg fi 12780b0ce0bfSmrgfi[]dnl 12790b0ce0bfSmrg])dnl PKG_PROG_PKG_CONFIG 128032b578d3Smrg 12810b0ce0bfSmrgdnl PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) 12820b0ce0bfSmrgdnl ------------------------------------------------------------------- 12830b0ce0bfSmrgdnl Since: 0.18 12840b0ce0bfSmrgdnl 12850b0ce0bfSmrgdnl Check to see whether a particular set of modules exists. Similar to 12860b0ce0bfSmrgdnl PKG_CHECK_MODULES(), but does not set variables or print errors. 12870b0ce0bfSmrgdnl 12880b0ce0bfSmrgdnl Please remember that m4 expands AC_REQUIRE([PKG_PROG_PKG_CONFIG]) 12890b0ce0bfSmrgdnl only at the first occurence in configure.ac, so if the first place 12900b0ce0bfSmrgdnl it's called might be skipped (such as if it is within an "if", you 12910b0ce0bfSmrgdnl have to call PKG_CHECK_EXISTS manually 12920b0ce0bfSmrgAC_DEFUN([PKG_CHECK_EXISTS], 12930b0ce0bfSmrg[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl 12940b0ce0bfSmrgif test -n "$PKG_CONFIG" && \ 12950b0ce0bfSmrg AC_RUN_LOG([$PKG_CONFIG --exists --print-errors "$1"]); then 12960b0ce0bfSmrg m4_default([$2], [:]) 12970b0ce0bfSmrgm4_ifvaln([$3], [else 12980b0ce0bfSmrg $3])dnl 12990b0ce0bfSmrgfi]) 130032b578d3Smrg 13010b0ce0bfSmrgdnl _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES]) 13020b0ce0bfSmrgdnl --------------------------------------------- 13030b0ce0bfSmrgdnl Internal wrapper calling pkg-config via PKG_CONFIG and setting 13040b0ce0bfSmrgdnl pkg_failed based on the result. 13050b0ce0bfSmrgm4_define([_PKG_CONFIG], 13060b0ce0bfSmrg[if test -n "$$1"; then 13070b0ce0bfSmrg pkg_cv_[]$1="$$1" 13080b0ce0bfSmrg elif test -n "$PKG_CONFIG"; then 13090b0ce0bfSmrg PKG_CHECK_EXISTS([$3], 13100b0ce0bfSmrg [pkg_cv_[]$1=`$PKG_CONFIG --[]$2 "$3" 2>/dev/null` 13110b0ce0bfSmrg test "x$?" != "x0" && pkg_failed=yes ], 13120b0ce0bfSmrg [pkg_failed=yes]) 13130b0ce0bfSmrg else 13140b0ce0bfSmrg pkg_failed=untried 13150b0ce0bfSmrgfi[]dnl 13160b0ce0bfSmrg])dnl _PKG_CONFIG 131732b578d3Smrg 13180b0ce0bfSmrgdnl _PKG_SHORT_ERRORS_SUPPORTED 13190b0ce0bfSmrgdnl --------------------------- 13200b0ce0bfSmrgdnl Internal check to see if pkg-config supports short errors. 13210b0ce0bfSmrgAC_DEFUN([_PKG_SHORT_ERRORS_SUPPORTED], 13220b0ce0bfSmrg[AC_REQUIRE([PKG_PROG_PKG_CONFIG]) 13230b0ce0bfSmrgif $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 13240b0ce0bfSmrg _pkg_short_errors_supported=yes 13250b0ce0bfSmrgelse 13260b0ce0bfSmrg _pkg_short_errors_supported=no 13270b0ce0bfSmrgfi[]dnl 13280b0ce0bfSmrg])dnl _PKG_SHORT_ERRORS_SUPPORTED 132932b578d3Smrg 1330d31dbc53Smrg 13310b0ce0bfSmrgdnl PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND], 13320b0ce0bfSmrgdnl [ACTION-IF-NOT-FOUND]) 13330b0ce0bfSmrgdnl -------------------------------------------------------------- 13340b0ce0bfSmrgdnl Since: 0.4.0 13350b0ce0bfSmrgdnl 13360b0ce0bfSmrgdnl Note that if there is a possibility the first call to 13370b0ce0bfSmrgdnl PKG_CHECK_MODULES might not happen, you should be sure to include an 13380b0ce0bfSmrgdnl explicit call to PKG_PROG_PKG_CONFIG in your configure.ac 13390b0ce0bfSmrgAC_DEFUN([PKG_CHECK_MODULES], 13400b0ce0bfSmrg[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl 13410b0ce0bfSmrgAC_ARG_VAR([$1][_CFLAGS], [C compiler flags for $1, overriding pkg-config])dnl 13420b0ce0bfSmrgAC_ARG_VAR([$1][_LIBS], [linker flags for $1, overriding pkg-config])dnl 134332b578d3Smrg 13440b0ce0bfSmrgpkg_failed=no 13450b0ce0bfSmrgAC_MSG_CHECKING([for $1]) 134632b578d3Smrg 13470b0ce0bfSmrg_PKG_CONFIG([$1][_CFLAGS], [cflags], [$2]) 13480b0ce0bfSmrg_PKG_CONFIG([$1][_LIBS], [libs], [$2]) 134932b578d3Smrg 13500b0ce0bfSmrgm4_define([_PKG_TEXT], [Alternatively, you may set the environment variables $1[]_CFLAGS 13510b0ce0bfSmrgand $1[]_LIBS to avoid the need to call pkg-config. 13520b0ce0bfSmrgSee the pkg-config man page for more details.]) 135332b578d3Smrg 13540b0ce0bfSmrgif test $pkg_failed = yes; then 13550b0ce0bfSmrg AC_MSG_RESULT([no]) 13560b0ce0bfSmrg _PKG_SHORT_ERRORS_SUPPORTED 13570b0ce0bfSmrg if test $_pkg_short_errors_supported = yes; then 13580b0ce0bfSmrg $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "$2" 2>&1` 13590b0ce0bfSmrg else 13600b0ce0bfSmrg $1[]_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "$2" 2>&1` 13610b0ce0bfSmrg fi 13620b0ce0bfSmrg # Put the nasty error message in config.log where it belongs 13630b0ce0bfSmrg echo "$$1[]_PKG_ERRORS" >&AS_MESSAGE_LOG_FD 136432b578d3Smrg 13650b0ce0bfSmrg m4_default([$4], [AC_MSG_ERROR( 13660b0ce0bfSmrg[Package requirements ($2) were not met: 136732b578d3Smrg 13680b0ce0bfSmrg$$1_PKG_ERRORS 136932b578d3Smrg 13700b0ce0bfSmrgConsider adjusting the PKG_CONFIG_PATH environment variable if you 13710b0ce0bfSmrginstalled software in a non-standard prefix. 1372d31dbc53Smrg 13730b0ce0bfSmrg_PKG_TEXT])[]dnl 13740b0ce0bfSmrg ]) 13750b0ce0bfSmrgelif test $pkg_failed = untried; then 13760b0ce0bfSmrg AC_MSG_RESULT([no]) 13770b0ce0bfSmrg m4_default([$4], [AC_MSG_FAILURE( 13780b0ce0bfSmrg[The pkg-config script could not be found or is too old. Make sure it 13790b0ce0bfSmrgis in your PATH or set the PKG_CONFIG environment variable to the full 13800b0ce0bfSmrgpath to pkg-config. 138132b578d3Smrg 13820b0ce0bfSmrg_PKG_TEXT 138332b578d3Smrg 13840b0ce0bfSmrgTo get pkg-config, see <http://pkg-config.freedesktop.org/>.])[]dnl 13850b0ce0bfSmrg ]) 13860b0ce0bfSmrgelse 13870b0ce0bfSmrg $1[]_CFLAGS=$pkg_cv_[]$1[]_CFLAGS 13880b0ce0bfSmrg $1[]_LIBS=$pkg_cv_[]$1[]_LIBS 13890b0ce0bfSmrg AC_MSG_RESULT([yes]) 13900b0ce0bfSmrg $3 13910b0ce0bfSmrgfi[]dnl 13920b0ce0bfSmrg])dnl PKG_CHECK_MODULES 139332b578d3Smrg 13941b12faf6Smrg 13950b0ce0bfSmrgdnl PKG_CHECK_MODULES_STATIC(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND], 13960b0ce0bfSmrgdnl [ACTION-IF-NOT-FOUND]) 13970b0ce0bfSmrgdnl --------------------------------------------------------------------- 13980b0ce0bfSmrgdnl Since: 0.29 13990b0ce0bfSmrgdnl 14000b0ce0bfSmrgdnl Checks for existence of MODULES and gathers its build flags with 14010b0ce0bfSmrgdnl static libraries enabled. Sets VARIABLE-PREFIX_CFLAGS from --cflags 14020b0ce0bfSmrgdnl and VARIABLE-PREFIX_LIBS from --libs. 14030b0ce0bfSmrgdnl 14040b0ce0bfSmrgdnl Note that if there is a possibility the first call to 14050b0ce0bfSmrgdnl PKG_CHECK_MODULES_STATIC might not happen, you should be sure to 14060b0ce0bfSmrgdnl include an explicit call to PKG_PROG_PKG_CONFIG in your 14070b0ce0bfSmrgdnl configure.ac. 14080b0ce0bfSmrgAC_DEFUN([PKG_CHECK_MODULES_STATIC], 14090b0ce0bfSmrg[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl 14100b0ce0bfSmrg_save_PKG_CONFIG=$PKG_CONFIG 14110b0ce0bfSmrgPKG_CONFIG="$PKG_CONFIG --static" 14120b0ce0bfSmrgPKG_CHECK_MODULES($@) 14130b0ce0bfSmrgPKG_CONFIG=$_save_PKG_CONFIG[]dnl 14140b0ce0bfSmrg])dnl PKG_CHECK_MODULES_STATIC 14151b12faf6Smrg 14161b12faf6Smrg 14170b0ce0bfSmrgdnl PKG_INSTALLDIR([DIRECTORY]) 14180b0ce0bfSmrgdnl ------------------------- 14190b0ce0bfSmrgdnl Since: 0.27 14200b0ce0bfSmrgdnl 14210b0ce0bfSmrgdnl Substitutes the variable pkgconfigdir as the location where a module 14220b0ce0bfSmrgdnl should install pkg-config .pc files. By default the directory is 14230b0ce0bfSmrgdnl $libdir/pkgconfig, but the default can be changed by passing 14240b0ce0bfSmrgdnl DIRECTORY. The user can override through the --with-pkgconfigdir 14250b0ce0bfSmrgdnl parameter. 14260b0ce0bfSmrgAC_DEFUN([PKG_INSTALLDIR], 14270b0ce0bfSmrg[m4_pushdef([pkg_default], [m4_default([$1], ['${libdir}/pkgconfig'])]) 14280b0ce0bfSmrgm4_pushdef([pkg_description], 14290b0ce0bfSmrg [pkg-config installation directory @<:@]pkg_default[@:>@]) 14300b0ce0bfSmrgAC_ARG_WITH([pkgconfigdir], 14310b0ce0bfSmrg [AS_HELP_STRING([--with-pkgconfigdir], pkg_description)],, 14320b0ce0bfSmrg [with_pkgconfigdir=]pkg_default) 14330b0ce0bfSmrgAC_SUBST([pkgconfigdir], [$with_pkgconfigdir]) 14340b0ce0bfSmrgm4_popdef([pkg_default]) 14350b0ce0bfSmrgm4_popdef([pkg_description]) 14360b0ce0bfSmrg])dnl PKG_INSTALLDIR 14371b12faf6Smrg 14381b12faf6Smrg 14390b0ce0bfSmrgdnl PKG_NOARCH_INSTALLDIR([DIRECTORY]) 14400b0ce0bfSmrgdnl -------------------------------- 14410b0ce0bfSmrgdnl Since: 0.27 14420b0ce0bfSmrgdnl 14430b0ce0bfSmrgdnl Substitutes the variable noarch_pkgconfigdir as the location where a 14440b0ce0bfSmrgdnl module should install arch-independent pkg-config .pc files. By 14450b0ce0bfSmrgdnl default the directory is $datadir/pkgconfig, but the default can be 14460b0ce0bfSmrgdnl changed by passing DIRECTORY. The user can override through the 14470b0ce0bfSmrgdnl --with-noarch-pkgconfigdir parameter. 14480b0ce0bfSmrgAC_DEFUN([PKG_NOARCH_INSTALLDIR], 14490b0ce0bfSmrg[m4_pushdef([pkg_default], [m4_default([$1], ['${datadir}/pkgconfig'])]) 14500b0ce0bfSmrgm4_pushdef([pkg_description], 14510b0ce0bfSmrg [pkg-config arch-independent installation directory @<:@]pkg_default[@:>@]) 14520b0ce0bfSmrgAC_ARG_WITH([noarch-pkgconfigdir], 14530b0ce0bfSmrg [AS_HELP_STRING([--with-noarch-pkgconfigdir], pkg_description)],, 14540b0ce0bfSmrg [with_noarch_pkgconfigdir=]pkg_default) 14550b0ce0bfSmrgAC_SUBST([noarch_pkgconfigdir], [$with_noarch_pkgconfigdir]) 14560b0ce0bfSmrgm4_popdef([pkg_default]) 14570b0ce0bfSmrgm4_popdef([pkg_description]) 14580b0ce0bfSmrg])dnl PKG_NOARCH_INSTALLDIR 145932b578d3Smrg 146032b578d3Smrg 14610b0ce0bfSmrgdnl PKG_CHECK_VAR(VARIABLE, MODULE, CONFIG-VARIABLE, 14620b0ce0bfSmrgdnl [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) 14630b0ce0bfSmrgdnl ------------------------------------------- 14640b0ce0bfSmrgdnl Since: 0.28 14650b0ce0bfSmrgdnl 14660b0ce0bfSmrgdnl Retrieves the value of the pkg-config variable for the given module. 14670b0ce0bfSmrgAC_DEFUN([PKG_CHECK_VAR], 14680b0ce0bfSmrg[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl 14690b0ce0bfSmrgAC_ARG_VAR([$1], [value of $3 for $2, overriding pkg-config])dnl 147032b578d3Smrg 14710b0ce0bfSmrg_PKG_CONFIG([$1], [variable="][$3]["], [$2]) 14720b0ce0bfSmrgAS_VAR_COPY([$1], [pkg_cv_][$1]) 1473e35d4d8eSmrg 14740b0ce0bfSmrgAS_VAR_IF([$1], [""], [$5], [$4])dnl 14750b0ce0bfSmrg])dnl PKG_CHECK_VAR 147632b578d3Smrg 14770b0ce0bfSmrgdnl xorg-macros.m4. Generated from xorg-macros.m4.in xorgversion.m4 by configure. 14780b0ce0bfSmrgdnl 14790b0ce0bfSmrgdnl Copyright (c) 2005, 2015, Oracle and/or its affiliates. All rights reserved. 14800b0ce0bfSmrgdnl 14810b0ce0bfSmrgdnl Permission is hereby granted, free of charge, to any person obtaining a 14820b0ce0bfSmrgdnl copy of this software and associated documentation files (the "Software"), 14830b0ce0bfSmrgdnl to deal in the Software without restriction, including without limitation 14840b0ce0bfSmrgdnl the rights to use, copy, modify, merge, publish, distribute, sublicense, 14850b0ce0bfSmrgdnl and/or sell copies of the Software, and to permit persons to whom the 14860b0ce0bfSmrgdnl Software is furnished to do so, subject to the following conditions: 14870b0ce0bfSmrgdnl 14880b0ce0bfSmrgdnl The above copyright notice and this permission notice (including the next 14890b0ce0bfSmrgdnl paragraph) shall be included in all copies or substantial portions of the 14900b0ce0bfSmrgdnl Software. 14910b0ce0bfSmrgdnl 14920b0ce0bfSmrgdnl THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 14930b0ce0bfSmrgdnl IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 14940b0ce0bfSmrgdnl FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL 14950b0ce0bfSmrgdnl THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 14960b0ce0bfSmrgdnl LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 14970b0ce0bfSmrgdnl FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER 14980b0ce0bfSmrgdnl DEALINGS IN THE SOFTWARE. 149932b578d3Smrg 15000b0ce0bfSmrg# XORG_MACROS_VERSION(required-version) 15010b0ce0bfSmrg# ------------------------------------- 15020b0ce0bfSmrg# Minimum version: 1.1.0 15030b0ce0bfSmrg# 15040b0ce0bfSmrg# If you're using a macro added in Version 1.1 or newer, include this in 15050b0ce0bfSmrg# your configure.ac with the minimum required version, such as: 15060b0ce0bfSmrg# XORG_MACROS_VERSION(1.1) 15070b0ce0bfSmrg# 15080b0ce0bfSmrg# To ensure that this macro is defined, also add: 15090b0ce0bfSmrg# m4_ifndef([XORG_MACROS_VERSION], 15100b0ce0bfSmrg# [m4_fatal([must install xorg-macros 1.1 or later before running autoconf/autogen])]) 15110b0ce0bfSmrg# 15120b0ce0bfSmrg# 15130b0ce0bfSmrg# See the "minimum version" comment for each macro you use to see what 15140b0ce0bfSmrg# version you require. 15150b0ce0bfSmrgm4_defun([XORG_MACROS_VERSION],[ 15160b0ce0bfSmrgm4_define([vers_have], [1.19.3]) 15170b0ce0bfSmrgm4_define([maj_have], m4_substr(vers_have, 0, m4_index(vers_have, [.]))) 15180b0ce0bfSmrgm4_define([maj_needed], m4_substr([$1], 0, m4_index([$1], [.]))) 15190b0ce0bfSmrgm4_if(m4_cmp(maj_have, maj_needed), 0,, 15200b0ce0bfSmrg [m4_fatal([xorg-macros major version ]maj_needed[ is required but ]vers_have[ found])]) 15210b0ce0bfSmrgm4_if(m4_version_compare(vers_have, [$1]), -1, 15220b0ce0bfSmrg [m4_fatal([xorg-macros version $1 or higher is required but ]vers_have[ found])]) 15230b0ce0bfSmrgm4_undefine([vers_have]) 15240b0ce0bfSmrgm4_undefine([maj_have]) 15250b0ce0bfSmrgm4_undefine([maj_needed]) 15260b0ce0bfSmrg]) # XORG_MACROS_VERSION 152732b578d3Smrg 15280b0ce0bfSmrg# XORG_PROG_RAWCPP() 15290b0ce0bfSmrg# ------------------ 15300b0ce0bfSmrg# Minimum version: 1.0.0 15310b0ce0bfSmrg# 15320b0ce0bfSmrg# Find cpp program and necessary flags for use in pre-processing text files 15330b0ce0bfSmrg# such as man pages and config files 15340b0ce0bfSmrgAC_DEFUN([XORG_PROG_RAWCPP],[ 15350b0ce0bfSmrgAC_REQUIRE([AC_PROG_CPP]) 15360b0ce0bfSmrgAC_PATH_TOOL(RAWCPP, [cpp], [${CPP}], 15370b0ce0bfSmrg [$PATH:/bin:/usr/bin:/usr/lib:/usr/libexec:/usr/ccs/lib:/usr/ccs/lbin:/lib]) 15381b12faf6Smrg 15390b0ce0bfSmrg# Check for flag to avoid builtin definitions - assumes unix is predefined, 15400b0ce0bfSmrg# which is not the best choice for supporting other OS'es, but covers most 15410b0ce0bfSmrg# of the ones we need for now. 15420b0ce0bfSmrgAC_MSG_CHECKING([if $RAWCPP requires -undef]) 15430b0ce0bfSmrgAC_LANG_CONFTEST([AC_LANG_SOURCE([[Does cpp redefine unix ?]])]) 15440b0ce0bfSmrgif test `${RAWCPP} < conftest.$ac_ext | grep -c 'unix'` -eq 1 ; then 15450b0ce0bfSmrg AC_MSG_RESULT([no]) 15460b0ce0bfSmrgelse 15470b0ce0bfSmrg if test `${RAWCPP} -undef < conftest.$ac_ext | grep -c 'unix'` -eq 1 ; then 15480b0ce0bfSmrg RAWCPPFLAGS=-undef 15490b0ce0bfSmrg AC_MSG_RESULT([yes]) 15500b0ce0bfSmrg # under Cygwin unix is still defined even with -undef 15510b0ce0bfSmrg elif test `${RAWCPP} -undef -ansi < conftest.$ac_ext | grep -c 'unix'` -eq 1 ; then 15520b0ce0bfSmrg RAWCPPFLAGS="-undef -ansi" 15530b0ce0bfSmrg AC_MSG_RESULT([yes, with -ansi]) 15540b0ce0bfSmrg else 15550b0ce0bfSmrg AC_MSG_ERROR([${RAWCPP} defines unix with or without -undef. I don't know what to do.]) 15560b0ce0bfSmrg fi 15570b0ce0bfSmrgfi 15580b0ce0bfSmrgrm -f conftest.$ac_ext 1559e35d4d8eSmrg 15600b0ce0bfSmrgAC_MSG_CHECKING([if $RAWCPP requires -traditional]) 15610b0ce0bfSmrgAC_LANG_CONFTEST([AC_LANG_SOURCE([[Does cpp preserve "whitespace"?]])]) 15620b0ce0bfSmrgif test `${RAWCPP} < conftest.$ac_ext | grep -c 'preserve \"'` -eq 1 ; then 15630b0ce0bfSmrg AC_MSG_RESULT([no]) 15640b0ce0bfSmrgelse 15650b0ce0bfSmrg if test `${RAWCPP} -traditional < conftest.$ac_ext | grep -c 'preserve \"'` -eq 1 ; then 15660b0ce0bfSmrg TRADITIONALCPPFLAGS="-traditional" 15670b0ce0bfSmrg RAWCPPFLAGS="${RAWCPPFLAGS} -traditional" 15680b0ce0bfSmrg AC_MSG_RESULT([yes]) 15690b0ce0bfSmrg else 15700b0ce0bfSmrg AC_MSG_ERROR([${RAWCPP} does not preserve whitespace with or without -traditional. I don't know what to do.]) 15710b0ce0bfSmrg fi 15720b0ce0bfSmrgfi 15730b0ce0bfSmrgrm -f conftest.$ac_ext 15740b0ce0bfSmrgAC_SUBST(RAWCPPFLAGS) 15750b0ce0bfSmrgAC_SUBST(TRADITIONALCPPFLAGS) 15760b0ce0bfSmrg]) # XORG_PROG_RAWCPP 1577e35d4d8eSmrg 15780b0ce0bfSmrg# XORG_MANPAGE_SECTIONS() 15790b0ce0bfSmrg# ----------------------- 15800b0ce0bfSmrg# Minimum version: 1.0.0 15810b0ce0bfSmrg# 15820b0ce0bfSmrg# Determine which sections man pages go in for the different man page types 15830b0ce0bfSmrg# on this OS - replaces *ManSuffix settings in old Imake *.cf per-os files. 15840b0ce0bfSmrg# Not sure if there's any better way than just hardcoding by OS name. 15850b0ce0bfSmrg# Override default settings by setting environment variables 15860b0ce0bfSmrg# Added MAN_SUBSTS in version 1.8 15870b0ce0bfSmrg# Added AC_PROG_SED in version 1.8 158832b578d3Smrg 15890b0ce0bfSmrgAC_DEFUN([XORG_MANPAGE_SECTIONS],[ 15900b0ce0bfSmrgAC_REQUIRE([AC_CANONICAL_HOST]) 15910b0ce0bfSmrgAC_REQUIRE([AC_PROG_SED]) 159232b578d3Smrg 15930b0ce0bfSmrgcase $host_os in 15940b0ce0bfSmrg solaris*) 15950b0ce0bfSmrg # Solaris 2.0 - 11.3 use SysV man page section numbers, so we 15960b0ce0bfSmrg # check for a man page file found in later versions that use 15970b0ce0bfSmrg # traditional section numbers instead 15980b0ce0bfSmrg AC_CHECK_FILE([/usr/share/man/man7/attributes.7], 15990b0ce0bfSmrg [SYSV_MAN_SECTIONS=false], [SYSV_MAN_SECTIONS=true]) 16000b0ce0bfSmrg ;; 16010b0ce0bfSmrg *) SYSV_MAN_SECTIONS=false ;; 16020b0ce0bfSmrgesac 160332b578d3Smrg 16040b0ce0bfSmrgif test x$APP_MAN_SUFFIX = x ; then 16050b0ce0bfSmrg APP_MAN_SUFFIX=1 16060b0ce0bfSmrgfi 16070b0ce0bfSmrgif test x$APP_MAN_DIR = x ; then 16080b0ce0bfSmrg APP_MAN_DIR='$(mandir)/man$(APP_MAN_SUFFIX)' 16090b0ce0bfSmrgfi 16101b12faf6Smrg 16110b0ce0bfSmrgif test x$LIB_MAN_SUFFIX = x ; then 16120b0ce0bfSmrg LIB_MAN_SUFFIX=3 16130b0ce0bfSmrgfi 16140b0ce0bfSmrgif test x$LIB_MAN_DIR = x ; then 16150b0ce0bfSmrg LIB_MAN_DIR='$(mandir)/man$(LIB_MAN_SUFFIX)' 16160b0ce0bfSmrgfi 161732b578d3Smrg 16180b0ce0bfSmrgif test x$FILE_MAN_SUFFIX = x ; then 16190b0ce0bfSmrg case $SYSV_MAN_SECTIONS in 16200b0ce0bfSmrg true) FILE_MAN_SUFFIX=4 ;; 16210b0ce0bfSmrg *) FILE_MAN_SUFFIX=5 ;; 16220b0ce0bfSmrg esac 16230b0ce0bfSmrgfi 16240b0ce0bfSmrgif test x$FILE_MAN_DIR = x ; then 16250b0ce0bfSmrg FILE_MAN_DIR='$(mandir)/man$(FILE_MAN_SUFFIX)' 16260b0ce0bfSmrgfi 162732b578d3Smrg 16280b0ce0bfSmrgif test x$MISC_MAN_SUFFIX = x ; then 16290b0ce0bfSmrg case $SYSV_MAN_SECTIONS in 16300b0ce0bfSmrg true) MISC_MAN_SUFFIX=5 ;; 16310b0ce0bfSmrg *) MISC_MAN_SUFFIX=7 ;; 16320b0ce0bfSmrg esac 16330b0ce0bfSmrgfi 16340b0ce0bfSmrgif test x$MISC_MAN_DIR = x ; then 16350b0ce0bfSmrg MISC_MAN_DIR='$(mandir)/man$(MISC_MAN_SUFFIX)' 16360b0ce0bfSmrgfi 163732b578d3Smrg 16380b0ce0bfSmrgif test x$DRIVER_MAN_SUFFIX = x ; then 16390b0ce0bfSmrg case $SYSV_MAN_SECTIONS in 16400b0ce0bfSmrg true) DRIVER_MAN_SUFFIX=7 ;; 16410b0ce0bfSmrg *) DRIVER_MAN_SUFFIX=4 ;; 16420b0ce0bfSmrg esac 16430b0ce0bfSmrgfi 16440b0ce0bfSmrgif test x$DRIVER_MAN_DIR = x ; then 16450b0ce0bfSmrg DRIVER_MAN_DIR='$(mandir)/man$(DRIVER_MAN_SUFFIX)' 16460b0ce0bfSmrgfi 164732b578d3Smrg 16480b0ce0bfSmrgif test x$ADMIN_MAN_SUFFIX = x ; then 16490b0ce0bfSmrg case $SYSV_MAN_SECTIONS in 16500b0ce0bfSmrg true) ADMIN_MAN_SUFFIX=1m ;; 16510b0ce0bfSmrg *) ADMIN_MAN_SUFFIX=8 ;; 16520b0ce0bfSmrg esac 16530b0ce0bfSmrgfi 16540b0ce0bfSmrgif test x$ADMIN_MAN_DIR = x ; then 16550b0ce0bfSmrg ADMIN_MAN_DIR='$(mandir)/man$(ADMIN_MAN_SUFFIX)' 16560b0ce0bfSmrgfi 165732b578d3Smrg 16580b0ce0bfSmrg 16590b0ce0bfSmrgAC_SUBST([APP_MAN_SUFFIX]) 16600b0ce0bfSmrgAC_SUBST([LIB_MAN_SUFFIX]) 16610b0ce0bfSmrgAC_SUBST([FILE_MAN_SUFFIX]) 16620b0ce0bfSmrgAC_SUBST([MISC_MAN_SUFFIX]) 16630b0ce0bfSmrgAC_SUBST([DRIVER_MAN_SUFFIX]) 16640b0ce0bfSmrgAC_SUBST([ADMIN_MAN_SUFFIX]) 16650b0ce0bfSmrgAC_SUBST([APP_MAN_DIR]) 16660b0ce0bfSmrgAC_SUBST([LIB_MAN_DIR]) 16670b0ce0bfSmrgAC_SUBST([FILE_MAN_DIR]) 16680b0ce0bfSmrgAC_SUBST([MISC_MAN_DIR]) 16690b0ce0bfSmrgAC_SUBST([DRIVER_MAN_DIR]) 16700b0ce0bfSmrgAC_SUBST([ADMIN_MAN_DIR]) 16710b0ce0bfSmrg 16720b0ce0bfSmrgXORG_MAN_PAGE="X Version 11" 16730b0ce0bfSmrgAC_SUBST([XORG_MAN_PAGE]) 16740b0ce0bfSmrgMAN_SUBSTS="\ 16750b0ce0bfSmrg -e 's|__vendorversion__|\"\$(PACKAGE_STRING)\" \"\$(XORG_MAN_PAGE)\"|' \ 16760b0ce0bfSmrg -e 's|__xorgversion__|\"\$(PACKAGE_STRING)\" \"\$(XORG_MAN_PAGE)\"|' \ 16770b0ce0bfSmrg -e 's|__xservername__|Xorg|g' \ 16780b0ce0bfSmrg -e 's|__xconfigfile__|xorg.conf|g' \ 16790b0ce0bfSmrg -e 's|__projectroot__|\$(prefix)|g' \ 16800b0ce0bfSmrg -e 's|__apploaddir__|\$(appdefaultdir)|g' \ 16810b0ce0bfSmrg -e 's|__appmansuffix__|\$(APP_MAN_SUFFIX)|g' \ 16820b0ce0bfSmrg -e 's|__drivermansuffix__|\$(DRIVER_MAN_SUFFIX)|g' \ 16830b0ce0bfSmrg -e 's|__adminmansuffix__|\$(ADMIN_MAN_SUFFIX)|g' \ 16840b0ce0bfSmrg -e 's|__libmansuffix__|\$(LIB_MAN_SUFFIX)|g' \ 16850b0ce0bfSmrg -e 's|__miscmansuffix__|\$(MISC_MAN_SUFFIX)|g' \ 16860b0ce0bfSmrg -e 's|__filemansuffix__|\$(FILE_MAN_SUFFIX)|g'" 16870b0ce0bfSmrgAC_SUBST([MAN_SUBSTS]) 16880b0ce0bfSmrg 16890b0ce0bfSmrg]) # XORG_MANPAGE_SECTIONS 16900b0ce0bfSmrg 16910b0ce0bfSmrg# XORG_CHECK_SGML_DOCTOOLS([MIN-VERSION]) 16920b0ce0bfSmrg# ------------------------ 16930b0ce0bfSmrg# Minimum version: 1.7.0 16940b0ce0bfSmrg# 16950b0ce0bfSmrg# Defines the variable XORG_SGML_PATH containing the location of X11/defs.ent 16960b0ce0bfSmrg# provided by xorg-sgml-doctools, if installed. 16970b0ce0bfSmrgAC_DEFUN([XORG_CHECK_SGML_DOCTOOLS],[ 16980b0ce0bfSmrgAC_MSG_CHECKING([for X.Org SGML entities m4_ifval([$1],[>= $1])]) 16990b0ce0bfSmrgXORG_SGML_PATH= 17000b0ce0bfSmrgPKG_CHECK_EXISTS([xorg-sgml-doctools m4_ifval([$1],[>= $1])], 17010b0ce0bfSmrg [XORG_SGML_PATH=`$PKG_CONFIG --variable=sgmlrootdir xorg-sgml-doctools`], 17020b0ce0bfSmrg [m4_ifval([$1],[:], 17030b0ce0bfSmrg [if test x"$cross_compiling" != x"yes" ; then 17040b0ce0bfSmrg AC_CHECK_FILE([$prefix/share/sgml/X11/defs.ent], 17050b0ce0bfSmrg [XORG_SGML_PATH=$prefix/share/sgml]) 17060b0ce0bfSmrg fi]) 17070b0ce0bfSmrg ]) 17080b0ce0bfSmrg 17090b0ce0bfSmrg# Define variables STYLESHEET_SRCDIR and XSL_STYLESHEET containing 17100b0ce0bfSmrg# the path and the name of the doc stylesheet 17110b0ce0bfSmrgif test "x$XORG_SGML_PATH" != "x" ; then 17120b0ce0bfSmrg AC_MSG_RESULT([$XORG_SGML_PATH]) 17130b0ce0bfSmrg STYLESHEET_SRCDIR=$XORG_SGML_PATH/X11 17140b0ce0bfSmrg XSL_STYLESHEET=$STYLESHEET_SRCDIR/xorg.xsl 17155a81ca49Smrgelse 17160b0ce0bfSmrg AC_MSG_RESULT([no]) 17175a81ca49Smrgfi 171832b578d3Smrg 17190b0ce0bfSmrgAC_SUBST(XORG_SGML_PATH) 17200b0ce0bfSmrgAC_SUBST(STYLESHEET_SRCDIR) 17210b0ce0bfSmrgAC_SUBST(XSL_STYLESHEET) 17220b0ce0bfSmrgAM_CONDITIONAL([HAVE_STYLESHEETS], [test "x$XSL_STYLESHEET" != "x"]) 17230b0ce0bfSmrg]) # XORG_CHECK_SGML_DOCTOOLS 1724d31dbc53Smrg 17250b0ce0bfSmrg# XORG_CHECK_LINUXDOC 17265a81ca49Smrg# ------------------- 17270b0ce0bfSmrg# Minimum version: 1.0.0 17280b0ce0bfSmrg# 17290b0ce0bfSmrg# Defines the variable MAKE_TEXT if the necessary tools and 17300b0ce0bfSmrg# files are found. $(MAKE_TEXT) blah.sgml will then produce blah.txt. 17310b0ce0bfSmrg# Whether or not the necessary tools and files are found can be checked 17320b0ce0bfSmrg# with the AM_CONDITIONAL "BUILD_LINUXDOC" 17330b0ce0bfSmrgAC_DEFUN([XORG_CHECK_LINUXDOC],[ 17340b0ce0bfSmrgAC_REQUIRE([XORG_CHECK_SGML_DOCTOOLS]) 17350b0ce0bfSmrgAC_REQUIRE([XORG_WITH_PS2PDF]) 173632b578d3Smrg 17370b0ce0bfSmrgAC_PATH_PROG(LINUXDOC, linuxdoc) 17381b12faf6Smrg 17390b0ce0bfSmrgAC_MSG_CHECKING([whether to build documentation]) 174032b578d3Smrg 17410b0ce0bfSmrgif test x$XORG_SGML_PATH != x && test x$LINUXDOC != x ; then 17420b0ce0bfSmrg BUILDDOC=yes 17435a81ca49Smrgelse 17440b0ce0bfSmrg BUILDDOC=no 17455a81ca49Smrgfi 174632b578d3Smrg 17470b0ce0bfSmrgAM_CONDITIONAL(BUILD_LINUXDOC, [test x$BUILDDOC = xyes]) 17481b12faf6Smrg 17490b0ce0bfSmrgAC_MSG_RESULT([$BUILDDOC]) 17502a51b5beSmrg 17510b0ce0bfSmrgAC_MSG_CHECKING([whether to build pdf documentation]) 17522a51b5beSmrg 17530b0ce0bfSmrgif test x$have_ps2pdf != xno && test x$BUILD_PDFDOC != xno; then 17540b0ce0bfSmrg BUILDPDFDOC=yes 17550b0ce0bfSmrgelse 17560b0ce0bfSmrg BUILDPDFDOC=no 17570b0ce0bfSmrgfi 17581b12faf6Smrg 17590b0ce0bfSmrgAM_CONDITIONAL(BUILD_PDFDOC, [test x$BUILDPDFDOC = xyes]) 1760e35d4d8eSmrg 17610b0ce0bfSmrgAC_MSG_RESULT([$BUILDPDFDOC]) 17621b12faf6Smrg 17630b0ce0bfSmrgMAKE_TEXT="SGML_SEARCH_PATH=$XORG_SGML_PATH GROFF_NO_SGR=y $LINUXDOC -B txt -f" 17640b0ce0bfSmrgMAKE_PS="SGML_SEARCH_PATH=$XORG_SGML_PATH $LINUXDOC -B latex --papersize=letter --output=ps" 17650b0ce0bfSmrgMAKE_PDF="$PS2PDF" 17660b0ce0bfSmrgMAKE_HTML="SGML_SEARCH_PATH=$XORG_SGML_PATH $LINUXDOC -B html --split=0" 17671b12faf6Smrg 17680b0ce0bfSmrgAC_SUBST(MAKE_TEXT) 17690b0ce0bfSmrgAC_SUBST(MAKE_PS) 17700b0ce0bfSmrgAC_SUBST(MAKE_PDF) 17710b0ce0bfSmrgAC_SUBST(MAKE_HTML) 17720b0ce0bfSmrg]) # XORG_CHECK_LINUXDOC 177332b578d3Smrg 17740b0ce0bfSmrg# XORG_CHECK_DOCBOOK 17750b0ce0bfSmrg# ------------------- 17760b0ce0bfSmrg# Minimum version: 1.0.0 17770b0ce0bfSmrg# 17780b0ce0bfSmrg# Checks for the ability to build output formats from SGML DocBook source. 17790b0ce0bfSmrg# For XXX in {TXT, PDF, PS, HTML}, the AM_CONDITIONAL "BUILD_XXXDOC" 17800b0ce0bfSmrg# indicates whether the necessary tools and files are found and, if set, 17810b0ce0bfSmrg# $(MAKE_XXX) blah.sgml will produce blah.xxx. 17820b0ce0bfSmrgAC_DEFUN([XORG_CHECK_DOCBOOK],[ 17830b0ce0bfSmrgAC_REQUIRE([XORG_CHECK_SGML_DOCTOOLS]) 178432b578d3Smrg 17850b0ce0bfSmrgBUILDTXTDOC=no 17860b0ce0bfSmrgBUILDPDFDOC=no 17870b0ce0bfSmrgBUILDPSDOC=no 17880b0ce0bfSmrgBUILDHTMLDOC=no 1789e35d4d8eSmrg 17900b0ce0bfSmrgAC_PATH_PROG(DOCBOOKPS, docbook2ps) 17910b0ce0bfSmrgAC_PATH_PROG(DOCBOOKPDF, docbook2pdf) 17920b0ce0bfSmrgAC_PATH_PROG(DOCBOOKHTML, docbook2html) 17930b0ce0bfSmrgAC_PATH_PROG(DOCBOOKTXT, docbook2txt) 179432b578d3Smrg 17950b0ce0bfSmrgAC_MSG_CHECKING([whether to build text documentation]) 17960b0ce0bfSmrgif test x$XORG_SGML_PATH != x && test x$DOCBOOKTXT != x && 17970b0ce0bfSmrg test x$BUILD_TXTDOC != xno; then 17980b0ce0bfSmrg BUILDTXTDOC=yes 1799e35d4d8eSmrgfi 18000b0ce0bfSmrgAM_CONDITIONAL(BUILD_TXTDOC, [test x$BUILDTXTDOC = xyes]) 18010b0ce0bfSmrgAC_MSG_RESULT([$BUILDTXTDOC]) 1802d31dbc53Smrg 18030b0ce0bfSmrgAC_MSG_CHECKING([whether to build PDF documentation]) 18040b0ce0bfSmrgif test x$XORG_SGML_PATH != x && test x$DOCBOOKPDF != x && 18050b0ce0bfSmrg test x$BUILD_PDFDOC != xno; then 18060b0ce0bfSmrg BUILDPDFDOC=yes 18070b0ce0bfSmrgfi 18080b0ce0bfSmrgAM_CONDITIONAL(BUILD_PDFDOC, [test x$BUILDPDFDOC = xyes]) 18090b0ce0bfSmrgAC_MSG_RESULT([$BUILDPDFDOC]) 1810d31dbc53Smrg 18110b0ce0bfSmrgAC_MSG_CHECKING([whether to build PostScript documentation]) 18120b0ce0bfSmrgif test x$XORG_SGML_PATH != x && test x$DOCBOOKPS != x && 18130b0ce0bfSmrg test x$BUILD_PSDOC != xno; then 18140b0ce0bfSmrg BUILDPSDOC=yes 18150b0ce0bfSmrgfi 18160b0ce0bfSmrgAM_CONDITIONAL(BUILD_PSDOC, [test x$BUILDPSDOC = xyes]) 18170b0ce0bfSmrgAC_MSG_RESULT([$BUILDPSDOC]) 18181b12faf6Smrg 18190b0ce0bfSmrgAC_MSG_CHECKING([whether to build HTML documentation]) 18200b0ce0bfSmrgif test x$XORG_SGML_PATH != x && test x$DOCBOOKHTML != x && 18210b0ce0bfSmrg test x$BUILD_HTMLDOC != xno; then 18220b0ce0bfSmrg BUILDHTMLDOC=yes 1823e35d4d8eSmrgfi 18240b0ce0bfSmrgAM_CONDITIONAL(BUILD_HTMLDOC, [test x$BUILDHTMLDOC = xyes]) 18250b0ce0bfSmrgAC_MSG_RESULT([$BUILDHTMLDOC]) 18262a51b5beSmrg 18270b0ce0bfSmrgMAKE_TEXT="SGML_SEARCH_PATH=$XORG_SGML_PATH $DOCBOOKTXT" 18280b0ce0bfSmrgMAKE_PS="SGML_SEARCH_PATH=$XORG_SGML_PATH $DOCBOOKPS" 18290b0ce0bfSmrgMAKE_PDF="SGML_SEARCH_PATH=$XORG_SGML_PATH $DOCBOOKPDF" 18300b0ce0bfSmrgMAKE_HTML="SGML_SEARCH_PATH=$XORG_SGML_PATH $DOCBOOKHTML" 18311b12faf6Smrg 18320b0ce0bfSmrgAC_SUBST(MAKE_TEXT) 18330b0ce0bfSmrgAC_SUBST(MAKE_PS) 18340b0ce0bfSmrgAC_SUBST(MAKE_PDF) 18350b0ce0bfSmrgAC_SUBST(MAKE_HTML) 18360b0ce0bfSmrg]) # XORG_CHECK_DOCBOOK 183732b578d3Smrg 18380b0ce0bfSmrg# XORG_WITH_XMLTO([MIN-VERSION], [DEFAULT]) 18390b0ce0bfSmrg# ---------------- 18400b0ce0bfSmrg# Minimum version: 1.5.0 18410b0ce0bfSmrg# Minimum version for optional DEFAULT argument: 1.11.0 18420b0ce0bfSmrg# 18430b0ce0bfSmrg# Documentation tools are not always available on all platforms and sometimes 18440b0ce0bfSmrg# not at the appropriate level. This macro enables a module to test for the 18450b0ce0bfSmrg# presence of the tool and obtain it's path in separate variables. Coupled with 18460b0ce0bfSmrg# the --with-xmlto option, it allows maximum flexibilty in making decisions 18470b0ce0bfSmrg# as whether or not to use the xmlto package. When DEFAULT is not specified, 18480b0ce0bfSmrg# --with-xmlto assumes 'auto'. 18490b0ce0bfSmrg# 18500b0ce0bfSmrg# Interface to module: 18510b0ce0bfSmrg# HAVE_XMLTO: used in makefiles to conditionally generate documentation 18520b0ce0bfSmrg# XMLTO: returns the path of the xmlto program found 18530b0ce0bfSmrg# returns the path set by the user in the environment 18540b0ce0bfSmrg# --with-xmlto: 'yes' user instructs the module to use xmlto 18550b0ce0bfSmrg# 'no' user instructs the module not to use xmlto 18560b0ce0bfSmrg# 18570b0ce0bfSmrg# Added in version 1.10.0 18580b0ce0bfSmrg# HAVE_XMLTO_TEXT: used in makefiles to conditionally generate text documentation 18590b0ce0bfSmrg# xmlto for text output requires either lynx, links, or w3m browsers 18600b0ce0bfSmrg# 18610b0ce0bfSmrg# If the user sets the value of XMLTO, AC_PATH_PROG skips testing the path. 18620b0ce0bfSmrg# 18630b0ce0bfSmrgAC_DEFUN([XORG_WITH_XMLTO],[ 18640b0ce0bfSmrgAC_ARG_VAR([XMLTO], [Path to xmlto command]) 18650b0ce0bfSmrgm4_define([_defopt], m4_default([$2], [auto])) 18660b0ce0bfSmrgAC_ARG_WITH(xmlto, 18670b0ce0bfSmrg AS_HELP_STRING([--with-xmlto], 18680b0ce0bfSmrg [Use xmlto to regenerate documentation (default: ]_defopt[)]), 18690b0ce0bfSmrg [use_xmlto=$withval], [use_xmlto=]_defopt) 18700b0ce0bfSmrgm4_undefine([_defopt]) 187132b578d3Smrg 18720b0ce0bfSmrgif test "x$use_xmlto" = x"auto"; then 18730b0ce0bfSmrg AC_PATH_PROG([XMLTO], [xmlto]) 18740b0ce0bfSmrg if test "x$XMLTO" = "x"; then 18750b0ce0bfSmrg AC_MSG_WARN([xmlto not found - documentation targets will be skipped]) 18760b0ce0bfSmrg have_xmlto=no 18770b0ce0bfSmrg else 18780b0ce0bfSmrg have_xmlto=yes 18790b0ce0bfSmrg fi 18800b0ce0bfSmrgelif test "x$use_xmlto" = x"yes" ; then 18810b0ce0bfSmrg AC_PATH_PROG([XMLTO], [xmlto]) 18820b0ce0bfSmrg if test "x$XMLTO" = "x"; then 18830b0ce0bfSmrg AC_MSG_ERROR([--with-xmlto=yes specified but xmlto not found in PATH]) 18840b0ce0bfSmrg fi 18850b0ce0bfSmrg have_xmlto=yes 18860b0ce0bfSmrgelif test "x$use_xmlto" = x"no" ; then 18870b0ce0bfSmrg if test "x$XMLTO" != "x"; then 18880b0ce0bfSmrg AC_MSG_WARN([ignoring XMLTO environment variable since --with-xmlto=no was specified]) 18890b0ce0bfSmrg fi 18900b0ce0bfSmrg have_xmlto=no 18911b12faf6Smrgelse 18920b0ce0bfSmrg AC_MSG_ERROR([--with-xmlto expects 'yes' or 'no']) 18931b12faf6Smrgfi 189432b578d3Smrg 18950b0ce0bfSmrg# Test for a minimum version of xmlto, if provided. 18960b0ce0bfSmrgm4_ifval([$1], 18970b0ce0bfSmrg[if test "$have_xmlto" = yes; then 18980b0ce0bfSmrg # scrape the xmlto version 18990b0ce0bfSmrg AC_MSG_CHECKING([the xmlto version]) 19000b0ce0bfSmrg xmlto_version=`$XMLTO --version 2>/dev/null | cut -d' ' -f3` 19010b0ce0bfSmrg AC_MSG_RESULT([$xmlto_version]) 19020b0ce0bfSmrg AS_VERSION_COMPARE([$xmlto_version], [$1], 19030b0ce0bfSmrg [if test "x$use_xmlto" = xauto; then 19040b0ce0bfSmrg AC_MSG_WARN([xmlto version $xmlto_version found, but $1 needed]) 19050b0ce0bfSmrg have_xmlto=no 19060b0ce0bfSmrg else 19070b0ce0bfSmrg AC_MSG_ERROR([xmlto version $xmlto_version found, but $1 needed]) 19080b0ce0bfSmrg fi]) 19090b0ce0bfSmrgfi]) 191032b578d3Smrg 19110b0ce0bfSmrg# Test for the ability of xmlto to generate a text target 19120b0ce0bfSmrg# 19130b0ce0bfSmrg# NOTE: xmlto 0.0.27 or higher return a non-zero return code in the 19140b0ce0bfSmrg# following test for empty XML docbook files. 19150b0ce0bfSmrg# For compatibility reasons use the following empty XML docbook file and if 19160b0ce0bfSmrg# it fails try it again with a non-empty XML file. 19170b0ce0bfSmrghave_xmlto_text=no 19180b0ce0bfSmrgcat > conftest.xml << "EOF" 19190b0ce0bfSmrgEOF 19200b0ce0bfSmrgAS_IF([test "$have_xmlto" = yes], 19210b0ce0bfSmrg [AS_IF([$XMLTO --skip-validation txt conftest.xml >/dev/null 2>&1], 19220b0ce0bfSmrg [have_xmlto_text=yes], 19230b0ce0bfSmrg [# Try it again with a non-empty XML file. 19240b0ce0bfSmrg cat > conftest.xml << "EOF" 19250b0ce0bfSmrg<x></x> 19260b0ce0bfSmrgEOF 19270b0ce0bfSmrg AS_IF([$XMLTO --skip-validation txt conftest.xml >/dev/null 2>&1], 19280b0ce0bfSmrg [have_xmlto_text=yes], 19290b0ce0bfSmrg [AC_MSG_WARN([xmlto cannot generate text format, this format skipped])])])]) 19300b0ce0bfSmrgrm -f conftest.xml 19310b0ce0bfSmrgAM_CONDITIONAL([HAVE_XMLTO_TEXT], [test $have_xmlto_text = yes]) 19320b0ce0bfSmrgAM_CONDITIONAL([HAVE_XMLTO], [test "$have_xmlto" = yes]) 19330b0ce0bfSmrg]) # XORG_WITH_XMLTO 19341b12faf6Smrg 19350b0ce0bfSmrg# XORG_WITH_XSLTPROC([MIN-VERSION], [DEFAULT]) 19360b0ce0bfSmrg# -------------------------------------------- 19370b0ce0bfSmrg# Minimum version: 1.12.0 19380b0ce0bfSmrg# Minimum version for optional DEFAULT argument: 1.12.0 19390b0ce0bfSmrg# 19400b0ce0bfSmrg# XSLT (Extensible Stylesheet Language Transformations) is a declarative, 19410b0ce0bfSmrg# XML-based language used for the transformation of XML documents. 19420b0ce0bfSmrg# The xsltproc command line tool is for applying XSLT stylesheets to XML documents. 19430b0ce0bfSmrg# It is used under the cover by xmlto to generate html files from DocBook/XML. 19440b0ce0bfSmrg# The XSLT processor is often used as a standalone tool for transformations. 19450b0ce0bfSmrg# It should not be assumed that this tool is used only to work with documnetation. 19460b0ce0bfSmrg# When DEFAULT is not specified, --with-xsltproc assumes 'auto'. 19470b0ce0bfSmrg# 19480b0ce0bfSmrg# Interface to module: 19490b0ce0bfSmrg# HAVE_XSLTPROC: used in makefiles to conditionally generate documentation 19500b0ce0bfSmrg# XSLTPROC: returns the path of the xsltproc program found 19510b0ce0bfSmrg# returns the path set by the user in the environment 19520b0ce0bfSmrg# --with-xsltproc: 'yes' user instructs the module to use xsltproc 19530b0ce0bfSmrg# 'no' user instructs the module not to use xsltproc 19540b0ce0bfSmrg# have_xsltproc: returns yes if xsltproc found in PATH or no 19550b0ce0bfSmrg# 19560b0ce0bfSmrg# If the user sets the value of XSLTPROC, AC_PATH_PROG skips testing the path. 19570b0ce0bfSmrg# 19580b0ce0bfSmrgAC_DEFUN([XORG_WITH_XSLTPROC],[ 19590b0ce0bfSmrgAC_ARG_VAR([XSLTPROC], [Path to xsltproc command]) 19600b0ce0bfSmrg# Preserves the interface, should it be implemented later 19610b0ce0bfSmrgm4_ifval([$1], [m4_warn([syntax], [Checking for xsltproc MIN-VERSION is not implemented])]) 19620b0ce0bfSmrgm4_define([_defopt], m4_default([$2], [auto])) 19630b0ce0bfSmrgAC_ARG_WITH(xsltproc, 19640b0ce0bfSmrg AS_HELP_STRING([--with-xsltproc], 19650b0ce0bfSmrg [Use xsltproc for the transformation of XML documents (default: ]_defopt[)]), 19660b0ce0bfSmrg [use_xsltproc=$withval], [use_xsltproc=]_defopt) 19670b0ce0bfSmrgm4_undefine([_defopt]) 1968e35d4d8eSmrg 19690b0ce0bfSmrgif test "x$use_xsltproc" = x"auto"; then 19700b0ce0bfSmrg AC_PATH_PROG([XSLTPROC], [xsltproc]) 19710b0ce0bfSmrg if test "x$XSLTPROC" = "x"; then 19720b0ce0bfSmrg AC_MSG_WARN([xsltproc not found - cannot transform XML documents]) 19730b0ce0bfSmrg have_xsltproc=no 19740b0ce0bfSmrg else 19750b0ce0bfSmrg have_xsltproc=yes 19760b0ce0bfSmrg fi 19770b0ce0bfSmrgelif test "x$use_xsltproc" = x"yes" ; then 19780b0ce0bfSmrg AC_PATH_PROG([XSLTPROC], [xsltproc]) 19790b0ce0bfSmrg if test "x$XSLTPROC" = "x"; then 19800b0ce0bfSmrg AC_MSG_ERROR([--with-xsltproc=yes specified but xsltproc not found in PATH]) 19810b0ce0bfSmrg fi 19820b0ce0bfSmrg have_xsltproc=yes 19830b0ce0bfSmrgelif test "x$use_xsltproc" = x"no" ; then 19840b0ce0bfSmrg if test "x$XSLTPROC" != "x"; then 19850b0ce0bfSmrg AC_MSG_WARN([ignoring XSLTPROC environment variable since --with-xsltproc=no was specified]) 19860b0ce0bfSmrg fi 19870b0ce0bfSmrg have_xsltproc=no 1988e35d4d8eSmrgelse 19890b0ce0bfSmrg AC_MSG_ERROR([--with-xsltproc expects 'yes' or 'no']) 1990e35d4d8eSmrgfi 199132b578d3Smrg 19920b0ce0bfSmrgAM_CONDITIONAL([HAVE_XSLTPROC], [test "$have_xsltproc" = yes]) 19930b0ce0bfSmrg]) # XORG_WITH_XSLTPROC 199432b578d3Smrg 19950b0ce0bfSmrg# XORG_WITH_PERL([MIN-VERSION], [DEFAULT]) 19960b0ce0bfSmrg# ---------------------------------------- 19970b0ce0bfSmrg# Minimum version: 1.15.0 19980b0ce0bfSmrg# 19990b0ce0bfSmrg# PERL (Practical Extraction and Report Language) is a language optimized for 20000b0ce0bfSmrg# scanning arbitrary text files, extracting information from those text files, 20010b0ce0bfSmrg# and printing reports based on that information. 20020b0ce0bfSmrg# 20030b0ce0bfSmrg# When DEFAULT is not specified, --with-perl assumes 'auto'. 20040b0ce0bfSmrg# 20050b0ce0bfSmrg# Interface to module: 20060b0ce0bfSmrg# HAVE_PERL: used in makefiles to conditionally scan text files 20070b0ce0bfSmrg# PERL: returns the path of the perl program found 20080b0ce0bfSmrg# returns the path set by the user in the environment 20090b0ce0bfSmrg# --with-perl: 'yes' user instructs the module to use perl 20100b0ce0bfSmrg# 'no' user instructs the module not to use perl 20110b0ce0bfSmrg# have_perl: returns yes if perl found in PATH or no 20120b0ce0bfSmrg# 20130b0ce0bfSmrg# If the user sets the value of PERL, AC_PATH_PROG skips testing the path. 20140b0ce0bfSmrg# 20150b0ce0bfSmrgAC_DEFUN([XORG_WITH_PERL],[ 20160b0ce0bfSmrgAC_ARG_VAR([PERL], [Path to perl command]) 20170b0ce0bfSmrg# Preserves the interface, should it be implemented later 20180b0ce0bfSmrgm4_ifval([$1], [m4_warn([syntax], [Checking for perl MIN-VERSION is not implemented])]) 20190b0ce0bfSmrgm4_define([_defopt], m4_default([$2], [auto])) 20200b0ce0bfSmrgAC_ARG_WITH(perl, 20210b0ce0bfSmrg AS_HELP_STRING([--with-perl], 20220b0ce0bfSmrg [Use perl for extracting information from files (default: ]_defopt[)]), 20230b0ce0bfSmrg [use_perl=$withval], [use_perl=]_defopt) 20240b0ce0bfSmrgm4_undefine([_defopt]) 202532b578d3Smrg 20260b0ce0bfSmrgif test "x$use_perl" = x"auto"; then 20270b0ce0bfSmrg AC_PATH_PROG([PERL], [perl]) 20280b0ce0bfSmrg if test "x$PERL" = "x"; then 20290b0ce0bfSmrg AC_MSG_WARN([perl not found - cannot extract information and report]) 20300b0ce0bfSmrg have_perl=no 20310b0ce0bfSmrg else 20320b0ce0bfSmrg have_perl=yes 20330b0ce0bfSmrg fi 20340b0ce0bfSmrgelif test "x$use_perl" = x"yes" ; then 20350b0ce0bfSmrg AC_PATH_PROG([PERL], [perl]) 20360b0ce0bfSmrg if test "x$PERL" = "x"; then 20370b0ce0bfSmrg AC_MSG_ERROR([--with-perl=yes specified but perl not found in PATH]) 20380b0ce0bfSmrg fi 20390b0ce0bfSmrg have_perl=yes 20400b0ce0bfSmrgelif test "x$use_perl" = x"no" ; then 20410b0ce0bfSmrg if test "x$PERL" != "x"; then 20420b0ce0bfSmrg AC_MSG_WARN([ignoring PERL environment variable since --with-perl=no was specified]) 20430b0ce0bfSmrg fi 20440b0ce0bfSmrg have_perl=no 2045e35d4d8eSmrgelse 20460b0ce0bfSmrg AC_MSG_ERROR([--with-perl expects 'yes' or 'no']) 2047e35d4d8eSmrgfi 204832b578d3Smrg 20490b0ce0bfSmrgAM_CONDITIONAL([HAVE_PERL], [test "$have_perl" = yes]) 20500b0ce0bfSmrg]) # XORG_WITH_PERL 2051d31dbc53Smrg 20520b0ce0bfSmrg# XORG_WITH_ASCIIDOC([MIN-VERSION], [DEFAULT]) 2053e35d4d8eSmrg# ---------------- 20540b0ce0bfSmrg# Minimum version: 1.5.0 20550b0ce0bfSmrg# Minimum version for optional DEFAULT argument: 1.11.0 20560b0ce0bfSmrg# 20570b0ce0bfSmrg# Documentation tools are not always available on all platforms and sometimes 20580b0ce0bfSmrg# not at the appropriate level. This macro enables a module to test for the 20590b0ce0bfSmrg# presence of the tool and obtain it's path in separate variables. Coupled with 20600b0ce0bfSmrg# the --with-asciidoc option, it allows maximum flexibilty in making decisions 20610b0ce0bfSmrg# as whether or not to use the asciidoc package. When DEFAULT is not specified, 20620b0ce0bfSmrg# --with-asciidoc assumes 'auto'. 20630b0ce0bfSmrg# 20640b0ce0bfSmrg# Interface to module: 20650b0ce0bfSmrg# HAVE_ASCIIDOC: used in makefiles to conditionally generate documentation 20660b0ce0bfSmrg# ASCIIDOC: returns the path of the asciidoc program found 20670b0ce0bfSmrg# returns the path set by the user in the environment 20680b0ce0bfSmrg# --with-asciidoc: 'yes' user instructs the module to use asciidoc 20690b0ce0bfSmrg# 'no' user instructs the module not to use asciidoc 20700b0ce0bfSmrg# 20710b0ce0bfSmrg# If the user sets the value of ASCIIDOC, AC_PATH_PROG skips testing the path. 20720b0ce0bfSmrg# 20730b0ce0bfSmrgAC_DEFUN([XORG_WITH_ASCIIDOC],[ 20740b0ce0bfSmrgAC_ARG_VAR([ASCIIDOC], [Path to asciidoc command]) 20750b0ce0bfSmrgm4_define([_defopt], m4_default([$2], [auto])) 20760b0ce0bfSmrgAC_ARG_WITH(asciidoc, 20770b0ce0bfSmrg AS_HELP_STRING([--with-asciidoc], 20780b0ce0bfSmrg [Use asciidoc to regenerate documentation (default: ]_defopt[)]), 20790b0ce0bfSmrg [use_asciidoc=$withval], [use_asciidoc=]_defopt) 20800b0ce0bfSmrgm4_undefine([_defopt]) 20812a51b5beSmrg 20820b0ce0bfSmrgif test "x$use_asciidoc" = x"auto"; then 20830b0ce0bfSmrg AC_PATH_PROG([ASCIIDOC], [asciidoc]) 20840b0ce0bfSmrg if test "x$ASCIIDOC" = "x"; then 20850b0ce0bfSmrg AC_MSG_WARN([asciidoc not found - documentation targets will be skipped]) 20860b0ce0bfSmrg have_asciidoc=no 20870b0ce0bfSmrg else 20880b0ce0bfSmrg have_asciidoc=yes 20890b0ce0bfSmrg fi 20900b0ce0bfSmrgelif test "x$use_asciidoc" = x"yes" ; then 20910b0ce0bfSmrg AC_PATH_PROG([ASCIIDOC], [asciidoc]) 20920b0ce0bfSmrg if test "x$ASCIIDOC" = "x"; then 20930b0ce0bfSmrg AC_MSG_ERROR([--with-asciidoc=yes specified but asciidoc not found in PATH]) 20940b0ce0bfSmrg fi 20950b0ce0bfSmrg have_asciidoc=yes 20960b0ce0bfSmrgelif test "x$use_asciidoc" = x"no" ; then 20970b0ce0bfSmrg if test "x$ASCIIDOC" != "x"; then 20980b0ce0bfSmrg AC_MSG_WARN([ignoring ASCIIDOC environment variable since --with-asciidoc=no was specified]) 20990b0ce0bfSmrg fi 21000b0ce0bfSmrg have_asciidoc=no 2101e35d4d8eSmrgelse 21020b0ce0bfSmrg AC_MSG_ERROR([--with-asciidoc expects 'yes' or 'no']) 21030b0ce0bfSmrgfi 21040b0ce0bfSmrgm4_ifval([$1], 21050b0ce0bfSmrg[if test "$have_asciidoc" = yes; then 21060b0ce0bfSmrg # scrape the asciidoc version 21070b0ce0bfSmrg AC_MSG_CHECKING([the asciidoc version]) 21080b0ce0bfSmrg asciidoc_version=`$ASCIIDOC --version 2>/dev/null | cut -d' ' -f2` 21090b0ce0bfSmrg AC_MSG_RESULT([$asciidoc_version]) 21100b0ce0bfSmrg AS_VERSION_COMPARE([$asciidoc_version], [$1], 21110b0ce0bfSmrg [if test "x$use_asciidoc" = xauto; then 21120b0ce0bfSmrg AC_MSG_WARN([asciidoc version $asciidoc_version found, but $1 needed]) 21130b0ce0bfSmrg have_asciidoc=no 21140b0ce0bfSmrg else 21150b0ce0bfSmrg AC_MSG_ERROR([asciidoc version $asciidoc_version found, but $1 needed]) 21160b0ce0bfSmrg fi]) 21170b0ce0bfSmrgfi]) 21180b0ce0bfSmrgAM_CONDITIONAL([HAVE_ASCIIDOC], [test "$have_asciidoc" = yes]) 21190b0ce0bfSmrg]) # XORG_WITH_ASCIIDOC 2120e35d4d8eSmrg 21210b0ce0bfSmrg# XORG_WITH_DOXYGEN([MIN-VERSION], [DEFAULT]) 21220b0ce0bfSmrg# ------------------------------------------- 21230b0ce0bfSmrg# Minimum version: 1.5.0 21240b0ce0bfSmrg# Minimum version for optional DEFAULT argument: 1.11.0 21250b0ce0bfSmrg# Minimum version for optional DOT checking: 1.18.0 21260b0ce0bfSmrg# 21270b0ce0bfSmrg# Documentation tools are not always available on all platforms and sometimes 21280b0ce0bfSmrg# not at the appropriate level. This macro enables a module to test for the 21290b0ce0bfSmrg# presence of the tool and obtain it's path in separate variables. Coupled with 21300b0ce0bfSmrg# the --with-doxygen option, it allows maximum flexibilty in making decisions 21310b0ce0bfSmrg# as whether or not to use the doxygen package. When DEFAULT is not specified, 21320b0ce0bfSmrg# --with-doxygen assumes 'auto'. 21330b0ce0bfSmrg# 21340b0ce0bfSmrg# Interface to module: 21350b0ce0bfSmrg# HAVE_DOXYGEN: used in makefiles to conditionally generate documentation 21360b0ce0bfSmrg# DOXYGEN: returns the path of the doxygen program found 21370b0ce0bfSmrg# returns the path set by the user in the environment 21380b0ce0bfSmrg# --with-doxygen: 'yes' user instructs the module to use doxygen 21390b0ce0bfSmrg# 'no' user instructs the module not to use doxygen 21400b0ce0bfSmrg# 21410b0ce0bfSmrg# If the user sets the value of DOXYGEN, AC_PATH_PROG skips testing the path. 21420b0ce0bfSmrg# 21430b0ce0bfSmrgAC_DEFUN([XORG_WITH_DOXYGEN],[ 21440b0ce0bfSmrgAC_ARG_VAR([DOXYGEN], [Path to doxygen command]) 21450b0ce0bfSmrgAC_ARG_VAR([DOT], [Path to the dot graphics utility]) 21460b0ce0bfSmrgm4_define([_defopt], m4_default([$2], [auto])) 21470b0ce0bfSmrgAC_ARG_WITH(doxygen, 21480b0ce0bfSmrg AS_HELP_STRING([--with-doxygen], 21490b0ce0bfSmrg [Use doxygen to regenerate documentation (default: ]_defopt[)]), 21500b0ce0bfSmrg [use_doxygen=$withval], [use_doxygen=]_defopt) 21510b0ce0bfSmrgm4_undefine([_defopt]) 2152e35d4d8eSmrg 21530b0ce0bfSmrgif test "x$use_doxygen" = x"auto"; then 21540b0ce0bfSmrg AC_PATH_PROG([DOXYGEN], [doxygen]) 21550b0ce0bfSmrg if test "x$DOXYGEN" = "x"; then 21560b0ce0bfSmrg AC_MSG_WARN([doxygen not found - documentation targets will be skipped]) 21570b0ce0bfSmrg have_doxygen=no 21580b0ce0bfSmrg else 21590b0ce0bfSmrg have_doxygen=yes 21600b0ce0bfSmrg fi 21610b0ce0bfSmrgelif test "x$use_doxygen" = x"yes" ; then 21620b0ce0bfSmrg AC_PATH_PROG([DOXYGEN], [doxygen]) 21630b0ce0bfSmrg if test "x$DOXYGEN" = "x"; then 21640b0ce0bfSmrg AC_MSG_ERROR([--with-doxygen=yes specified but doxygen not found in PATH]) 21650b0ce0bfSmrg fi 21660b0ce0bfSmrg have_doxygen=yes 21670b0ce0bfSmrgelif test "x$use_doxygen" = x"no" ; then 21680b0ce0bfSmrg if test "x$DOXYGEN" != "x"; then 21690b0ce0bfSmrg AC_MSG_WARN([ignoring DOXYGEN environment variable since --with-doxygen=no was specified]) 21700b0ce0bfSmrg fi 21710b0ce0bfSmrg have_doxygen=no 21720b0ce0bfSmrgelse 21730b0ce0bfSmrg AC_MSG_ERROR([--with-doxygen expects 'yes' or 'no']) 21740b0ce0bfSmrgfi 21750b0ce0bfSmrgm4_ifval([$1], 21760b0ce0bfSmrg[if test "$have_doxygen" = yes; then 21770b0ce0bfSmrg # scrape the doxygen version 21780b0ce0bfSmrg AC_MSG_CHECKING([the doxygen version]) 21790b0ce0bfSmrg doxygen_version=`$DOXYGEN --version 2>/dev/null` 21800b0ce0bfSmrg AC_MSG_RESULT([$doxygen_version]) 21810b0ce0bfSmrg AS_VERSION_COMPARE([$doxygen_version], [$1], 21820b0ce0bfSmrg [if test "x$use_doxygen" = xauto; then 21830b0ce0bfSmrg AC_MSG_WARN([doxygen version $doxygen_version found, but $1 needed]) 21840b0ce0bfSmrg have_doxygen=no 21850b0ce0bfSmrg else 21860b0ce0bfSmrg AC_MSG_ERROR([doxygen version $doxygen_version found, but $1 needed]) 21870b0ce0bfSmrg fi]) 21880b0ce0bfSmrgfi]) 218932b578d3Smrg 21900b0ce0bfSmrgdnl Check for DOT if we have doxygen. The caller decides if it is mandatory 21910b0ce0bfSmrgdnl HAVE_DOT is a variable that can be used in your doxygen.in config file: 21920b0ce0bfSmrgdnl HAVE_DOT = @HAVE_DOT@ 21930b0ce0bfSmrgHAVE_DOT=no 21940b0ce0bfSmrgif test "x$have_doxygen" = "xyes"; then 21950b0ce0bfSmrg AC_PATH_PROG([DOT], [dot]) 21960b0ce0bfSmrg if test "x$DOT" != "x"; then 21970b0ce0bfSmrg HAVE_DOT=yes 21980b0ce0bfSmrg fi 21992a51b5beSmrgfi 220032b578d3Smrg 22010b0ce0bfSmrgAC_SUBST([HAVE_DOT]) 22020b0ce0bfSmrgAM_CONDITIONAL([HAVE_DOT], [test "$HAVE_DOT" = "yes"]) 22030b0ce0bfSmrgAM_CONDITIONAL([HAVE_DOXYGEN], [test "$have_doxygen" = yes]) 22040b0ce0bfSmrg]) # XORG_WITH_DOXYGEN 220532b578d3Smrg 22060b0ce0bfSmrg# XORG_WITH_GROFF([DEFAULT]) 22070b0ce0bfSmrg# ---------------- 22080b0ce0bfSmrg# Minimum version: 1.6.0 22090b0ce0bfSmrg# Minimum version for optional DEFAULT argument: 1.11.0 22100b0ce0bfSmrg# 22110b0ce0bfSmrg# Documentation tools are not always available on all platforms and sometimes 22120b0ce0bfSmrg# not at the appropriate level. This macro enables a module to test for the 22130b0ce0bfSmrg# presence of the tool and obtain it's path in separate variables. Coupled with 22140b0ce0bfSmrg# the --with-groff option, it allows maximum flexibilty in making decisions 22150b0ce0bfSmrg# as whether or not to use the groff package. When DEFAULT is not specified, 22160b0ce0bfSmrg# --with-groff assumes 'auto'. 22170b0ce0bfSmrg# 22180b0ce0bfSmrg# Interface to module: 22190b0ce0bfSmrg# HAVE_GROFF: used in makefiles to conditionally generate documentation 22200b0ce0bfSmrg# HAVE_GROFF_MM: the memorandum macros (-mm) package 22210b0ce0bfSmrg# HAVE_GROFF_MS: the -ms macros package 22220b0ce0bfSmrg# GROFF: returns the path of the groff program found 22230b0ce0bfSmrg# returns the path set by the user in the environment 22240b0ce0bfSmrg# --with-groff: 'yes' user instructs the module to use groff 22250b0ce0bfSmrg# 'no' user instructs the module not to use groff 22260b0ce0bfSmrg# 22270b0ce0bfSmrg# Added in version 1.9.0: 22280b0ce0bfSmrg# HAVE_GROFF_HTML: groff has dependencies to output HTML format: 22290b0ce0bfSmrg# pnmcut pnmcrop pnmtopng pnmtops from the netpbm package. 22300b0ce0bfSmrg# psselect from the psutils package. 22310b0ce0bfSmrg# the ghostcript package. Refer to the grohtml man pages 22320b0ce0bfSmrg# 22330b0ce0bfSmrg# If the user sets the value of GROFF, AC_PATH_PROG skips testing the path. 22340b0ce0bfSmrg# 22350b0ce0bfSmrg# OS and distros often splits groff in a basic and full package, the former 22360b0ce0bfSmrg# having the groff program and the later having devices, fonts and macros 22370b0ce0bfSmrg# Checking for the groff executable is not enough. 22380b0ce0bfSmrg# 22390b0ce0bfSmrg# If macros are missing, we cannot assume that groff is useless, so we don't 22400b0ce0bfSmrg# unset HAVE_GROFF or GROFF env variables. 22410b0ce0bfSmrg# HAVE_GROFF_?? can never be true while HAVE_GROFF is false. 22420b0ce0bfSmrg# 22430b0ce0bfSmrgAC_DEFUN([XORG_WITH_GROFF],[ 22440b0ce0bfSmrgAC_ARG_VAR([GROFF], [Path to groff command]) 22450b0ce0bfSmrgm4_define([_defopt], m4_default([$1], [auto])) 22460b0ce0bfSmrgAC_ARG_WITH(groff, 22470b0ce0bfSmrg AS_HELP_STRING([--with-groff], 22480b0ce0bfSmrg [Use groff to regenerate documentation (default: ]_defopt[)]), 22490b0ce0bfSmrg [use_groff=$withval], [use_groff=]_defopt) 22500b0ce0bfSmrgm4_undefine([_defopt]) 225132b578d3Smrg 22520b0ce0bfSmrgif test "x$use_groff" = x"auto"; then 22530b0ce0bfSmrg AC_PATH_PROG([GROFF], [groff]) 22540b0ce0bfSmrg if test "x$GROFF" = "x"; then 22550b0ce0bfSmrg AC_MSG_WARN([groff not found - documentation targets will be skipped]) 22560b0ce0bfSmrg have_groff=no 22570b0ce0bfSmrg else 22580b0ce0bfSmrg have_groff=yes 22590b0ce0bfSmrg fi 22600b0ce0bfSmrgelif test "x$use_groff" = x"yes" ; then 22610b0ce0bfSmrg AC_PATH_PROG([GROFF], [groff]) 22620b0ce0bfSmrg if test "x$GROFF" = "x"; then 22630b0ce0bfSmrg AC_MSG_ERROR([--with-groff=yes specified but groff not found in PATH]) 22640b0ce0bfSmrg fi 22650b0ce0bfSmrg have_groff=yes 22660b0ce0bfSmrgelif test "x$use_groff" = x"no" ; then 22670b0ce0bfSmrg if test "x$GROFF" != "x"; then 22680b0ce0bfSmrg AC_MSG_WARN([ignoring GROFF environment variable since --with-groff=no was specified]) 22690b0ce0bfSmrg fi 22700b0ce0bfSmrg have_groff=no 22710b0ce0bfSmrgelse 22720b0ce0bfSmrg AC_MSG_ERROR([--with-groff expects 'yes' or 'no']) 22730b0ce0bfSmrgfi 227432b578d3Smrg 22750b0ce0bfSmrg# We have groff, test for the presence of the macro packages 22760b0ce0bfSmrgif test "x$have_groff" = x"yes"; then 22770b0ce0bfSmrg AC_MSG_CHECKING([for ${GROFF} -ms macros]) 22780b0ce0bfSmrg if ${GROFF} -ms -I. /dev/null >/dev/null 2>&1 ; then 22790b0ce0bfSmrg groff_ms_works=yes 22800b0ce0bfSmrg else 22810b0ce0bfSmrg groff_ms_works=no 22820b0ce0bfSmrg fi 22830b0ce0bfSmrg AC_MSG_RESULT([$groff_ms_works]) 22840b0ce0bfSmrg AC_MSG_CHECKING([for ${GROFF} -mm macros]) 22850b0ce0bfSmrg if ${GROFF} -mm -I. /dev/null >/dev/null 2>&1 ; then 22860b0ce0bfSmrg groff_mm_works=yes 22870b0ce0bfSmrg else 22880b0ce0bfSmrg groff_mm_works=no 22890b0ce0bfSmrg fi 22900b0ce0bfSmrg AC_MSG_RESULT([$groff_mm_works]) 22910b0ce0bfSmrgfi 2292e35d4d8eSmrg 22930b0ce0bfSmrg# We have groff, test for HTML dependencies, one command per package 22940b0ce0bfSmrgif test "x$have_groff" = x"yes"; then 22950b0ce0bfSmrg AC_PATH_PROGS(GS_PATH, [gs gswin32c]) 22960b0ce0bfSmrg AC_PATH_PROG(PNMTOPNG_PATH, [pnmtopng]) 22970b0ce0bfSmrg AC_PATH_PROG(PSSELECT_PATH, [psselect]) 22980b0ce0bfSmrg if test "x$GS_PATH" != "x" -a "x$PNMTOPNG_PATH" != "x" -a "x$PSSELECT_PATH" != "x"; then 22990b0ce0bfSmrg have_groff_html=yes 23000b0ce0bfSmrg else 23010b0ce0bfSmrg have_groff_html=no 23020b0ce0bfSmrg AC_MSG_WARN([grohtml dependencies not found - HTML Documentation skipped. Refer to grohtml man pages]) 23030b0ce0bfSmrg fi 23040b0ce0bfSmrgfi 2305e35d4d8eSmrg 23060b0ce0bfSmrg# Set Automake conditionals for Makefiles 23070b0ce0bfSmrgAM_CONDITIONAL([HAVE_GROFF], [test "$have_groff" = yes]) 23080b0ce0bfSmrgAM_CONDITIONAL([HAVE_GROFF_MS], [test "$groff_ms_works" = yes]) 23090b0ce0bfSmrgAM_CONDITIONAL([HAVE_GROFF_MM], [test "$groff_mm_works" = yes]) 23100b0ce0bfSmrgAM_CONDITIONAL([HAVE_GROFF_HTML], [test "$have_groff_html" = yes]) 23110b0ce0bfSmrg]) # XORG_WITH_GROFF 2312e35d4d8eSmrg 23130b0ce0bfSmrg# XORG_WITH_FOP([MIN-VERSION], [DEFAULT]) 23140b0ce0bfSmrg# --------------------------------------- 23150b0ce0bfSmrg# Minimum version: 1.6.0 23160b0ce0bfSmrg# Minimum version for optional DEFAULT argument: 1.11.0 23170b0ce0bfSmrg# Minimum version for optional MIN-VERSION argument: 1.15.0 23180b0ce0bfSmrg# 23190b0ce0bfSmrg# Documentation tools are not always available on all platforms and sometimes 23200b0ce0bfSmrg# not at the appropriate level. This macro enables a module to test for the 23210b0ce0bfSmrg# presence of the tool and obtain it's path in separate variables. Coupled with 23220b0ce0bfSmrg# the --with-fop option, it allows maximum flexibilty in making decisions 23230b0ce0bfSmrg# as whether or not to use the fop package. When DEFAULT is not specified, 23240b0ce0bfSmrg# --with-fop assumes 'auto'. 23250b0ce0bfSmrg# 23260b0ce0bfSmrg# Interface to module: 23270b0ce0bfSmrg# HAVE_FOP: used in makefiles to conditionally generate documentation 23280b0ce0bfSmrg# FOP: returns the path of the fop program found 23290b0ce0bfSmrg# returns the path set by the user in the environment 23300b0ce0bfSmrg# --with-fop: 'yes' user instructs the module to use fop 23310b0ce0bfSmrg# 'no' user instructs the module not to use fop 23320b0ce0bfSmrg# 23330b0ce0bfSmrg# If the user sets the value of FOP, AC_PATH_PROG skips testing the path. 23340b0ce0bfSmrg# 23350b0ce0bfSmrgAC_DEFUN([XORG_WITH_FOP],[ 23360b0ce0bfSmrgAC_ARG_VAR([FOP], [Path to fop command]) 23370b0ce0bfSmrgm4_define([_defopt], m4_default([$2], [auto])) 23380b0ce0bfSmrgAC_ARG_WITH(fop, 23390b0ce0bfSmrg AS_HELP_STRING([--with-fop], 23400b0ce0bfSmrg [Use fop to regenerate documentation (default: ]_defopt[)]), 23410b0ce0bfSmrg [use_fop=$withval], [use_fop=]_defopt) 23420b0ce0bfSmrgm4_undefine([_defopt]) 2343e35d4d8eSmrg 23440b0ce0bfSmrgif test "x$use_fop" = x"auto"; then 23450b0ce0bfSmrg AC_PATH_PROG([FOP], [fop]) 23460b0ce0bfSmrg if test "x$FOP" = "x"; then 23470b0ce0bfSmrg AC_MSG_WARN([fop not found - documentation targets will be skipped]) 23480b0ce0bfSmrg have_fop=no 23490b0ce0bfSmrg else 23500b0ce0bfSmrg have_fop=yes 23510b0ce0bfSmrg fi 23520b0ce0bfSmrgelif test "x$use_fop" = x"yes" ; then 23530b0ce0bfSmrg AC_PATH_PROG([FOP], [fop]) 23540b0ce0bfSmrg if test "x$FOP" = "x"; then 23550b0ce0bfSmrg AC_MSG_ERROR([--with-fop=yes specified but fop not found in PATH]) 23560b0ce0bfSmrg fi 23570b0ce0bfSmrg have_fop=yes 23580b0ce0bfSmrgelif test "x$use_fop" = x"no" ; then 23590b0ce0bfSmrg if test "x$FOP" != "x"; then 23600b0ce0bfSmrg AC_MSG_WARN([ignoring FOP environment variable since --with-fop=no was specified]) 23610b0ce0bfSmrg fi 23620b0ce0bfSmrg have_fop=no 23630b0ce0bfSmrgelse 23640b0ce0bfSmrg AC_MSG_ERROR([--with-fop expects 'yes' or 'no']) 23650b0ce0bfSmrgfi 2366e35d4d8eSmrg 23670b0ce0bfSmrg# Test for a minimum version of fop, if provided. 23680b0ce0bfSmrgm4_ifval([$1], 23690b0ce0bfSmrg[if test "$have_fop" = yes; then 23700b0ce0bfSmrg # scrape the fop version 23710b0ce0bfSmrg AC_MSG_CHECKING([for fop minimum version]) 23720b0ce0bfSmrg fop_version=`$FOP -version 2>/dev/null | cut -d' ' -f3` 23730b0ce0bfSmrg AC_MSG_RESULT([$fop_version]) 23740b0ce0bfSmrg AS_VERSION_COMPARE([$fop_version], [$1], 23750b0ce0bfSmrg [if test "x$use_fop" = xauto; then 23760b0ce0bfSmrg AC_MSG_WARN([fop version $fop_version found, but $1 needed]) 23770b0ce0bfSmrg have_fop=no 23780b0ce0bfSmrg else 23790b0ce0bfSmrg AC_MSG_ERROR([fop version $fop_version found, but $1 needed]) 23800b0ce0bfSmrg fi]) 23810b0ce0bfSmrgfi]) 23820b0ce0bfSmrgAM_CONDITIONAL([HAVE_FOP], [test "$have_fop" = yes]) 23830b0ce0bfSmrg]) # XORG_WITH_FOP 2384e35d4d8eSmrg 23850b0ce0bfSmrg# XORG_WITH_M4([MIN-VERSION]) 23860b0ce0bfSmrg# --------------------------- 23870b0ce0bfSmrg# Minimum version: 1.19.0 23880b0ce0bfSmrg# 23890b0ce0bfSmrg# This macro attempts to locate an m4 macro processor which supports 23900b0ce0bfSmrg# -I option and is only useful for modules relying on M4 in order to 23910b0ce0bfSmrg# expand macros in source code files. 23920b0ce0bfSmrg# 23930b0ce0bfSmrg# Interface to module: 23940b0ce0bfSmrg# M4: returns the path of the m4 program found 23950b0ce0bfSmrg# returns the path set by the user in the environment 23960b0ce0bfSmrg# 23970b0ce0bfSmrgAC_DEFUN([XORG_WITH_M4], [ 23980b0ce0bfSmrgAC_CACHE_CHECK([for m4 that supports -I option], [ac_cv_path_M4], 23990b0ce0bfSmrg [AC_PATH_PROGS_FEATURE_CHECK([M4], [m4 gm4], 24000b0ce0bfSmrg [[$ac_path_M4 -I. /dev/null > /dev/null 2>&1 && \ 24010b0ce0bfSmrg ac_cv_path_M4=$ac_path_M4 ac_path_M4_found=:]], 24020b0ce0bfSmrg [AC_MSG_ERROR([could not find m4 that supports -I option])], 24030b0ce0bfSmrg [$PATH:/usr/gnu/bin])]) 2404e35d4d8eSmrg 24050b0ce0bfSmrgAC_SUBST([M4], [$ac_cv_path_M4]) 24060b0ce0bfSmrg]) # XORG_WITH_M4 2407e35d4d8eSmrg 24080b0ce0bfSmrg# XORG_WITH_PS2PDF([DEFAULT]) 24090b0ce0bfSmrg# ---------------- 24100b0ce0bfSmrg# Minimum version: 1.6.0 24110b0ce0bfSmrg# Minimum version for optional DEFAULT argument: 1.11.0 24120b0ce0bfSmrg# 24130b0ce0bfSmrg# Documentation tools are not always available on all platforms and sometimes 24140b0ce0bfSmrg# not at the appropriate level. This macro enables a module to test for the 24150b0ce0bfSmrg# presence of the tool and obtain it's path in separate variables. Coupled with 24160b0ce0bfSmrg# the --with-ps2pdf option, it allows maximum flexibilty in making decisions 24170b0ce0bfSmrg# as whether or not to use the ps2pdf package. When DEFAULT is not specified, 24180b0ce0bfSmrg# --with-ps2pdf assumes 'auto'. 24190b0ce0bfSmrg# 24200b0ce0bfSmrg# Interface to module: 24210b0ce0bfSmrg# HAVE_PS2PDF: used in makefiles to conditionally generate documentation 24220b0ce0bfSmrg# PS2PDF: returns the path of the ps2pdf program found 24230b0ce0bfSmrg# returns the path set by the user in the environment 24240b0ce0bfSmrg# --with-ps2pdf: 'yes' user instructs the module to use ps2pdf 24250b0ce0bfSmrg# 'no' user instructs the module not to use ps2pdf 24260b0ce0bfSmrg# 24270b0ce0bfSmrg# If the user sets the value of PS2PDF, AC_PATH_PROG skips testing the path. 24280b0ce0bfSmrg# 24290b0ce0bfSmrgAC_DEFUN([XORG_WITH_PS2PDF],[ 24300b0ce0bfSmrgAC_ARG_VAR([PS2PDF], [Path to ps2pdf command]) 24310b0ce0bfSmrgm4_define([_defopt], m4_default([$1], [auto])) 24320b0ce0bfSmrgAC_ARG_WITH(ps2pdf, 24330b0ce0bfSmrg AS_HELP_STRING([--with-ps2pdf], 24340b0ce0bfSmrg [Use ps2pdf to regenerate documentation (default: ]_defopt[)]), 24350b0ce0bfSmrg [use_ps2pdf=$withval], [use_ps2pdf=]_defopt) 24360b0ce0bfSmrgm4_undefine([_defopt]) 2437e35d4d8eSmrg 24380b0ce0bfSmrgif test "x$use_ps2pdf" = x"auto"; then 24390b0ce0bfSmrg AC_PATH_PROG([PS2PDF], [ps2pdf]) 24400b0ce0bfSmrg if test "x$PS2PDF" = "x"; then 24410b0ce0bfSmrg AC_MSG_WARN([ps2pdf not found - documentation targets will be skipped]) 24420b0ce0bfSmrg have_ps2pdf=no 24430b0ce0bfSmrg else 24440b0ce0bfSmrg have_ps2pdf=yes 24450b0ce0bfSmrg fi 24460b0ce0bfSmrgelif test "x$use_ps2pdf" = x"yes" ; then 24470b0ce0bfSmrg AC_PATH_PROG([PS2PDF], [ps2pdf]) 24480b0ce0bfSmrg if test "x$PS2PDF" = "x"; then 24490b0ce0bfSmrg AC_MSG_ERROR([--with-ps2pdf=yes specified but ps2pdf not found in PATH]) 24500b0ce0bfSmrg fi 24510b0ce0bfSmrg have_ps2pdf=yes 24520b0ce0bfSmrgelif test "x$use_ps2pdf" = x"no" ; then 24530b0ce0bfSmrg if test "x$PS2PDF" != "x"; then 24540b0ce0bfSmrg AC_MSG_WARN([ignoring PS2PDF environment variable since --with-ps2pdf=no was specified]) 24550b0ce0bfSmrg fi 24560b0ce0bfSmrg have_ps2pdf=no 24570b0ce0bfSmrgelse 24580b0ce0bfSmrg AC_MSG_ERROR([--with-ps2pdf expects 'yes' or 'no']) 2459e35d4d8eSmrgfi 24600b0ce0bfSmrgAM_CONDITIONAL([HAVE_PS2PDF], [test "$have_ps2pdf" = yes]) 24610b0ce0bfSmrg]) # XORG_WITH_PS2PDF 2462e35d4d8eSmrg 24630b0ce0bfSmrg# XORG_ENABLE_DOCS (enable_docs=yes) 24640b0ce0bfSmrg# ---------------- 24650b0ce0bfSmrg# Minimum version: 1.6.0 24660b0ce0bfSmrg# 24670b0ce0bfSmrg# Documentation tools are not always available on all platforms and sometimes 24680b0ce0bfSmrg# not at the appropriate level. This macro enables a builder to skip all 24690b0ce0bfSmrg# documentation targets except traditional man pages. 24700b0ce0bfSmrg# Combined with the specific tool checking macros XORG_WITH_*, it provides 24710b0ce0bfSmrg# maximum flexibilty in controlling documentation building. 24720b0ce0bfSmrg# Refer to: 24730b0ce0bfSmrg# XORG_WITH_XMLTO --with-xmlto 24740b0ce0bfSmrg# XORG_WITH_ASCIIDOC --with-asciidoc 24750b0ce0bfSmrg# XORG_WITH_DOXYGEN --with-doxygen 24760b0ce0bfSmrg# XORG_WITH_FOP --with-fop 24770b0ce0bfSmrg# XORG_WITH_GROFF --with-groff 24780b0ce0bfSmrg# XORG_WITH_PS2PDF --with-ps2pdf 24790b0ce0bfSmrg# 24800b0ce0bfSmrg# Interface to module: 24810b0ce0bfSmrg# ENABLE_DOCS: used in makefiles to conditionally generate documentation 24820b0ce0bfSmrg# --enable-docs: 'yes' user instructs the module to generate docs 24830b0ce0bfSmrg# 'no' user instructs the module not to generate docs 24840b0ce0bfSmrg# parm1: specify the default value, yes or no. 24850b0ce0bfSmrg# 24860b0ce0bfSmrgAC_DEFUN([XORG_ENABLE_DOCS],[ 24870b0ce0bfSmrgm4_define([docs_default], m4_default([$1], [yes])) 24880b0ce0bfSmrgAC_ARG_ENABLE(docs, 24890b0ce0bfSmrg AS_HELP_STRING([--enable-docs], 24900b0ce0bfSmrg [Enable building the documentation (default: ]docs_default[)]), 24910b0ce0bfSmrg [build_docs=$enableval], [build_docs=]docs_default) 24920b0ce0bfSmrgm4_undefine([docs_default]) 24930b0ce0bfSmrgAM_CONDITIONAL(ENABLE_DOCS, [test x$build_docs = xyes]) 24940b0ce0bfSmrgAC_MSG_CHECKING([whether to build documentation]) 24950b0ce0bfSmrgAC_MSG_RESULT([$build_docs]) 24960b0ce0bfSmrg]) # XORG_ENABLE_DOCS 2497e35d4d8eSmrg 24980b0ce0bfSmrg# XORG_ENABLE_DEVEL_DOCS (enable_devel_docs=yes) 24990b0ce0bfSmrg# ---------------- 25000b0ce0bfSmrg# Minimum version: 1.6.0 25010b0ce0bfSmrg# 25020b0ce0bfSmrg# This macro enables a builder to skip all developer documentation. 25030b0ce0bfSmrg# Combined with the specific tool checking macros XORG_WITH_*, it provides 25040b0ce0bfSmrg# maximum flexibilty in controlling documentation building. 25050b0ce0bfSmrg# Refer to: 25060b0ce0bfSmrg# XORG_WITH_XMLTO --with-xmlto 25070b0ce0bfSmrg# XORG_WITH_ASCIIDOC --with-asciidoc 25080b0ce0bfSmrg# XORG_WITH_DOXYGEN --with-doxygen 25090b0ce0bfSmrg# XORG_WITH_FOP --with-fop 25100b0ce0bfSmrg# XORG_WITH_GROFF --with-groff 25110b0ce0bfSmrg# XORG_WITH_PS2PDF --with-ps2pdf 25120b0ce0bfSmrg# 25130b0ce0bfSmrg# Interface to module: 25140b0ce0bfSmrg# ENABLE_DEVEL_DOCS: used in makefiles to conditionally generate developer docs 25150b0ce0bfSmrg# --enable-devel-docs: 'yes' user instructs the module to generate developer docs 25160b0ce0bfSmrg# 'no' user instructs the module not to generate developer docs 25170b0ce0bfSmrg# parm1: specify the default value, yes or no. 25180b0ce0bfSmrg# 25190b0ce0bfSmrgAC_DEFUN([XORG_ENABLE_DEVEL_DOCS],[ 25200b0ce0bfSmrgm4_define([devel_default], m4_default([$1], [yes])) 25210b0ce0bfSmrgAC_ARG_ENABLE(devel-docs, 25220b0ce0bfSmrg AS_HELP_STRING([--enable-devel-docs], 25230b0ce0bfSmrg [Enable building the developer documentation (default: ]devel_default[)]), 25240b0ce0bfSmrg [build_devel_docs=$enableval], [build_devel_docs=]devel_default) 25250b0ce0bfSmrgm4_undefine([devel_default]) 25260b0ce0bfSmrgAM_CONDITIONAL(ENABLE_DEVEL_DOCS, [test x$build_devel_docs = xyes]) 25270b0ce0bfSmrgAC_MSG_CHECKING([whether to build developer documentation]) 25280b0ce0bfSmrgAC_MSG_RESULT([$build_devel_docs]) 25290b0ce0bfSmrg]) # XORG_ENABLE_DEVEL_DOCS 2530e35d4d8eSmrg 25310b0ce0bfSmrg# XORG_ENABLE_SPECS (enable_specs=yes) 25320b0ce0bfSmrg# ---------------- 25330b0ce0bfSmrg# Minimum version: 1.6.0 25340b0ce0bfSmrg# 25350b0ce0bfSmrg# This macro enables a builder to skip all functional specification targets. 25360b0ce0bfSmrg# Combined with the specific tool checking macros XORG_WITH_*, it provides 25370b0ce0bfSmrg# maximum flexibilty in controlling documentation building. 25380b0ce0bfSmrg# Refer to: 25390b0ce0bfSmrg# XORG_WITH_XMLTO --with-xmlto 25400b0ce0bfSmrg# XORG_WITH_ASCIIDOC --with-asciidoc 25410b0ce0bfSmrg# XORG_WITH_DOXYGEN --with-doxygen 25420b0ce0bfSmrg# XORG_WITH_FOP --with-fop 25430b0ce0bfSmrg# XORG_WITH_GROFF --with-groff 25440b0ce0bfSmrg# XORG_WITH_PS2PDF --with-ps2pdf 25450b0ce0bfSmrg# 25460b0ce0bfSmrg# Interface to module: 25470b0ce0bfSmrg# ENABLE_SPECS: used in makefiles to conditionally generate specs 25480b0ce0bfSmrg# --enable-specs: 'yes' user instructs the module to generate specs 25490b0ce0bfSmrg# 'no' user instructs the module not to generate specs 25500b0ce0bfSmrg# parm1: specify the default value, yes or no. 25510b0ce0bfSmrg# 25520b0ce0bfSmrgAC_DEFUN([XORG_ENABLE_SPECS],[ 25530b0ce0bfSmrgm4_define([spec_default], m4_default([$1], [yes])) 25540b0ce0bfSmrgAC_ARG_ENABLE(specs, 25550b0ce0bfSmrg AS_HELP_STRING([--enable-specs], 25560b0ce0bfSmrg [Enable building the specs (default: ]spec_default[)]), 25570b0ce0bfSmrg [build_specs=$enableval], [build_specs=]spec_default) 25580b0ce0bfSmrgm4_undefine([spec_default]) 25590b0ce0bfSmrgAM_CONDITIONAL(ENABLE_SPECS, [test x$build_specs = xyes]) 25600b0ce0bfSmrgAC_MSG_CHECKING([whether to build functional specifications]) 25610b0ce0bfSmrgAC_MSG_RESULT([$build_specs]) 25620b0ce0bfSmrg]) # XORG_ENABLE_SPECS 2563e35d4d8eSmrg 25640b0ce0bfSmrg# XORG_ENABLE_UNIT_TESTS (enable_unit_tests=auto) 25650b0ce0bfSmrg# ---------------------------------------------- 25660b0ce0bfSmrg# Minimum version: 1.13.0 25670b0ce0bfSmrg# 25680b0ce0bfSmrg# This macro enables a builder to enable/disable unit testing 25690b0ce0bfSmrg# It makes no assumption about the test cases implementation 25700b0ce0bfSmrg# Test cases may or may not use Automake "Support for test suites" 25710b0ce0bfSmrg# They may or may not use the software utility library GLib 25720b0ce0bfSmrg# 25730b0ce0bfSmrg# When used in conjunction with XORG_WITH_GLIB, use both AM_CONDITIONAL 25740b0ce0bfSmrg# ENABLE_UNIT_TESTS and HAVE_GLIB. Not all unit tests may use glib. 25750b0ce0bfSmrg# The variable enable_unit_tests is used by other macros in this file. 25760b0ce0bfSmrg# 25770b0ce0bfSmrg# Interface to module: 25780b0ce0bfSmrg# ENABLE_UNIT_TESTS: used in makefiles to conditionally build tests 25790b0ce0bfSmrg# enable_unit_tests: used in configure.ac for additional configuration 25800b0ce0bfSmrg# --enable-unit-tests: 'yes' user instructs the module to build tests 25810b0ce0bfSmrg# 'no' user instructs the module not to build tests 25820b0ce0bfSmrg# parm1: specify the default value, yes or no. 25830b0ce0bfSmrg# 25840b0ce0bfSmrgAC_DEFUN([XORG_ENABLE_UNIT_TESTS],[ 25850b0ce0bfSmrgAC_BEFORE([$0], [XORG_WITH_GLIB]) 25860b0ce0bfSmrgAC_BEFORE([$0], [XORG_LD_WRAP]) 25870b0ce0bfSmrgAC_REQUIRE([XORG_MEMORY_CHECK_FLAGS]) 25880b0ce0bfSmrgm4_define([_defopt], m4_default([$1], [auto])) 25890b0ce0bfSmrgAC_ARG_ENABLE(unit-tests, AS_HELP_STRING([--enable-unit-tests], 25900b0ce0bfSmrg [Enable building unit test cases (default: ]_defopt[)]), 25910b0ce0bfSmrg [enable_unit_tests=$enableval], [enable_unit_tests=]_defopt) 25920b0ce0bfSmrgm4_undefine([_defopt]) 25930b0ce0bfSmrgAM_CONDITIONAL(ENABLE_UNIT_TESTS, [test "x$enable_unit_tests" != xno]) 25940b0ce0bfSmrgAC_MSG_CHECKING([whether to build unit test cases]) 25950b0ce0bfSmrgAC_MSG_RESULT([$enable_unit_tests]) 25960b0ce0bfSmrg]) # XORG_ENABLE_UNIT_TESTS 2597e35d4d8eSmrg 25980b0ce0bfSmrg# XORG_ENABLE_INTEGRATION_TESTS (enable_unit_tests=auto) 25990b0ce0bfSmrg# ------------------------------------------------------ 26000b0ce0bfSmrg# Minimum version: 1.17.0 26010b0ce0bfSmrg# 26020b0ce0bfSmrg# This macro enables a builder to enable/disable integration testing 26030b0ce0bfSmrg# It makes no assumption about the test cases' implementation 26040b0ce0bfSmrg# Test cases may or may not use Automake "Support for test suites" 26050b0ce0bfSmrg# 26060b0ce0bfSmrg# Please see XORG_ENABLE_UNIT_TESTS for unit test support. Unit test support 26070b0ce0bfSmrg# usually requires less dependencies and may be built and run under less 26080b0ce0bfSmrg# stringent environments than integration tests. 26090b0ce0bfSmrg# 26100b0ce0bfSmrg# Interface to module: 26110b0ce0bfSmrg# ENABLE_INTEGRATION_TESTS: used in makefiles to conditionally build tests 26120b0ce0bfSmrg# enable_integration_tests: used in configure.ac for additional configuration 26130b0ce0bfSmrg# --enable-integration-tests: 'yes' user instructs the module to build tests 26140b0ce0bfSmrg# 'no' user instructs the module not to build tests 26150b0ce0bfSmrg# parm1: specify the default value, yes or no. 26160b0ce0bfSmrg# 26170b0ce0bfSmrgAC_DEFUN([XORG_ENABLE_INTEGRATION_TESTS],[ 26180b0ce0bfSmrgAC_REQUIRE([XORG_MEMORY_CHECK_FLAGS]) 26190b0ce0bfSmrgm4_define([_defopt], m4_default([$1], [auto])) 26200b0ce0bfSmrgAC_ARG_ENABLE(integration-tests, AS_HELP_STRING([--enable-integration-tests], 26210b0ce0bfSmrg [Enable building integration test cases (default: ]_defopt[)]), 26220b0ce0bfSmrg [enable_integration_tests=$enableval], 26230b0ce0bfSmrg [enable_integration_tests=]_defopt) 26240b0ce0bfSmrgm4_undefine([_defopt]) 26250b0ce0bfSmrgAM_CONDITIONAL([ENABLE_INTEGRATION_TESTS], 26260b0ce0bfSmrg [test "x$enable_integration_tests" != xno]) 26270b0ce0bfSmrgAC_MSG_CHECKING([whether to build unit test cases]) 26280b0ce0bfSmrgAC_MSG_RESULT([$enable_integration_tests]) 26290b0ce0bfSmrg]) # XORG_ENABLE_INTEGRATION_TESTS 26300b0ce0bfSmrg 26310b0ce0bfSmrg# XORG_WITH_GLIB([MIN-VERSION], [DEFAULT]) 26320b0ce0bfSmrg# ---------------------------------------- 26330b0ce0bfSmrg# Minimum version: 1.13.0 26340b0ce0bfSmrg# 26350b0ce0bfSmrg# GLib is a library which provides advanced data structures and functions. 26360b0ce0bfSmrg# This macro enables a module to test for the presence of Glib. 26370b0ce0bfSmrg# 26380b0ce0bfSmrg# When used with ENABLE_UNIT_TESTS, it is assumed GLib is used for unit testing. 26390b0ce0bfSmrg# Otherwise the value of $enable_unit_tests is blank. 26400b0ce0bfSmrg# 26410b0ce0bfSmrg# Please see XORG_ENABLE_INTEGRATION_TESTS for integration test support. Unit 26420b0ce0bfSmrg# test support usually requires less dependencies and may be built and run under 26430b0ce0bfSmrg# less stringent environments than integration tests. 26440b0ce0bfSmrg# 26450b0ce0bfSmrg# Interface to module: 26460b0ce0bfSmrg# HAVE_GLIB: used in makefiles to conditionally build targets 26470b0ce0bfSmrg# with_glib: used in configure.ac to know if GLib has been found 26480b0ce0bfSmrg# --with-glib: 'yes' user instructs the module to use glib 26490b0ce0bfSmrg# 'no' user instructs the module not to use glib 26500b0ce0bfSmrg# 26510b0ce0bfSmrgAC_DEFUN([XORG_WITH_GLIB],[ 26520b0ce0bfSmrgAC_REQUIRE([PKG_PROG_PKG_CONFIG]) 26530b0ce0bfSmrgm4_define([_defopt], m4_default([$2], [auto])) 26540b0ce0bfSmrgAC_ARG_WITH(glib, AS_HELP_STRING([--with-glib], 26550b0ce0bfSmrg [Use GLib library for unit testing (default: ]_defopt[)]), 26560b0ce0bfSmrg [with_glib=$withval], [with_glib=]_defopt) 26570b0ce0bfSmrgm4_undefine([_defopt]) 26580b0ce0bfSmrg 26590b0ce0bfSmrghave_glib=no 26600b0ce0bfSmrg# Do not probe GLib if user explicitly disabled unit testing 26610b0ce0bfSmrgif test "x$enable_unit_tests" != x"no"; then 26620b0ce0bfSmrg # Do not probe GLib if user explicitly disabled it 26630b0ce0bfSmrg if test "x$with_glib" != x"no"; then 26640b0ce0bfSmrg m4_ifval( 26650b0ce0bfSmrg [$1], 26660b0ce0bfSmrg [PKG_CHECK_MODULES([GLIB], [glib-2.0 >= $1], [have_glib=yes], [have_glib=no])], 26670b0ce0bfSmrg [PKG_CHECK_MODULES([GLIB], [glib-2.0], [have_glib=yes], [have_glib=no])] 26680b0ce0bfSmrg ) 2669e35d4d8eSmrg fi 2670e35d4d8eSmrgfi 2671e35d4d8eSmrg 26720b0ce0bfSmrg# Not having GLib when unit testing has been explicitly requested is an error 26730b0ce0bfSmrgif test "x$enable_unit_tests" = x"yes"; then 26740b0ce0bfSmrg if test "x$have_glib" = x"no"; then 26750b0ce0bfSmrg AC_MSG_ERROR([--enable-unit-tests=yes specified but glib-2.0 not found]) 26760b0ce0bfSmrg fi 26770b0ce0bfSmrgfi 2678e35d4d8eSmrg 26790b0ce0bfSmrg# Having unit testing disabled when GLib has been explicitly requested is an error 26800b0ce0bfSmrgif test "x$enable_unit_tests" = x"no"; then 26810b0ce0bfSmrg if test "x$with_glib" = x"yes"; then 26820b0ce0bfSmrg AC_MSG_ERROR([--enable-unit-tests=yes specified but glib-2.0 not found]) 26830b0ce0bfSmrg fi 2684e35d4d8eSmrgfi 2685e35d4d8eSmrg 26860b0ce0bfSmrg# Not having GLib when it has been explicitly requested is an error 26870b0ce0bfSmrgif test "x$with_glib" = x"yes"; then 26880b0ce0bfSmrg if test "x$have_glib" = x"no"; then 26890b0ce0bfSmrg AC_MSG_ERROR([--with-glib=yes specified but glib-2.0 not found]) 26900b0ce0bfSmrg fi 26910b0ce0bfSmrgfi 2692e35d4d8eSmrg 26930b0ce0bfSmrgAM_CONDITIONAL([HAVE_GLIB], [test "$have_glib" = yes]) 26940b0ce0bfSmrg]) # XORG_WITH_GLIB 2695e35d4d8eSmrg 26960b0ce0bfSmrg# XORG_LD_WRAP([required|optional]) 26970b0ce0bfSmrg# --------------------------------- 26980b0ce0bfSmrg# Minimum version: 1.13.0 26990b0ce0bfSmrg# 27000b0ce0bfSmrg# Check if linker supports -wrap, passed via compiler flags 27010b0ce0bfSmrg# 27020b0ce0bfSmrg# When used with ENABLE_UNIT_TESTS, it is assumed -wrap is used for unit testing. 27030b0ce0bfSmrg# Otherwise the value of $enable_unit_tests is blank. 27040b0ce0bfSmrg# 27050b0ce0bfSmrg# Argument added in 1.16.0 - default is "required", to match existing behavior 27060b0ce0bfSmrg# of returning an error if enable_unit_tests is yes, and ld -wrap is not 27070b0ce0bfSmrg# available, an argument of "optional" allows use when some unit tests require 27080b0ce0bfSmrg# ld -wrap and others do not. 27090b0ce0bfSmrg# 27100b0ce0bfSmrgAC_DEFUN([XORG_LD_WRAP],[ 27110b0ce0bfSmrgXORG_CHECK_LINKER_FLAGS([-Wl,-wrap,exit],[have_ld_wrap=yes],[have_ld_wrap=no], 27120b0ce0bfSmrg [AC_LANG_PROGRAM([#include <stdlib.h> 27130b0ce0bfSmrg void __wrap_exit(int status) { return; }], 27140b0ce0bfSmrg [exit(0);])]) 27150b0ce0bfSmrg# Not having ld wrap when unit testing has been explicitly requested is an error 27160b0ce0bfSmrgif test "x$enable_unit_tests" = x"yes" -a "x$1" != "xoptional"; then 27170b0ce0bfSmrg if test "x$have_ld_wrap" = x"no"; then 27180b0ce0bfSmrg AC_MSG_ERROR([--enable-unit-tests=yes specified but ld -wrap support is not available]) 2719e35d4d8eSmrg fi 27200b0ce0bfSmrgfi 27210b0ce0bfSmrgAM_CONDITIONAL([HAVE_LD_WRAP], [test "$have_ld_wrap" = yes]) 27220b0ce0bfSmrg# 27230b0ce0bfSmrg]) # XORG_LD_WRAP 27240b0ce0bfSmrg 27250b0ce0bfSmrg# XORG_CHECK_LINKER_FLAGS 27260b0ce0bfSmrg# ----------------------- 27270b0ce0bfSmrg# SYNOPSIS 27280b0ce0bfSmrg# 27290b0ce0bfSmrg# XORG_CHECK_LINKER_FLAGS(FLAGS, [ACTION-SUCCESS], [ACTION-FAILURE], [PROGRAM-SOURCE]) 27300b0ce0bfSmrg# 27310b0ce0bfSmrg# DESCRIPTION 27320b0ce0bfSmrg# 27330b0ce0bfSmrg# Check whether the given linker FLAGS work with the current language's 27340b0ce0bfSmrg# linker, or whether they give an error. 27350b0ce0bfSmrg# 27360b0ce0bfSmrg# ACTION-SUCCESS/ACTION-FAILURE are shell commands to execute on 27370b0ce0bfSmrg# success/failure. 27380b0ce0bfSmrg# 27390b0ce0bfSmrg# PROGRAM-SOURCE is the program source to link with, if needed 27400b0ce0bfSmrg# 27410b0ce0bfSmrg# NOTE: Based on AX_CHECK_COMPILER_FLAGS. 27420b0ce0bfSmrg# 27430b0ce0bfSmrg# LICENSE 27440b0ce0bfSmrg# 27450b0ce0bfSmrg# Copyright (c) 2009 Mike Frysinger <vapier@gentoo.org> 27460b0ce0bfSmrg# Copyright (c) 2009 Steven G. Johnson <stevenj@alum.mit.edu> 27470b0ce0bfSmrg# Copyright (c) 2009 Matteo Frigo 27480b0ce0bfSmrg# 27490b0ce0bfSmrg# This program is free software: you can redistribute it and/or modify it 27500b0ce0bfSmrg# under the terms of the GNU General Public License as published by the 27510b0ce0bfSmrg# Free Software Foundation, either version 3 of the License, or (at your 27520b0ce0bfSmrg# option) any later version. 27530b0ce0bfSmrg# 27540b0ce0bfSmrg# This program is distributed in the hope that it will be useful, but 27550b0ce0bfSmrg# WITHOUT ANY WARRANTY; without even the implied warranty of 27560b0ce0bfSmrg# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General 27570b0ce0bfSmrg# Public License for more details. 27580b0ce0bfSmrg# 27590b0ce0bfSmrg# You should have received a copy of the GNU General Public License along 27600b0ce0bfSmrg# with this program. If not, see <http://www.gnu.org/licenses/>. 27610b0ce0bfSmrg# 27620b0ce0bfSmrg# As a special exception, the respective Autoconf Macro's copyright owner 27630b0ce0bfSmrg# gives unlimited permission to copy, distribute and modify the configure 27640b0ce0bfSmrg# scripts that are the output of Autoconf when processing the Macro. You 27650b0ce0bfSmrg# need not follow the terms of the GNU General Public License when using 27660b0ce0bfSmrg# or distributing such scripts, even though portions of the text of the 27670b0ce0bfSmrg# Macro appear in them. The GNU General Public License (GPL) does govern 27680b0ce0bfSmrg# all other use of the material that constitutes the Autoconf Macro. 27690b0ce0bfSmrg# 27700b0ce0bfSmrg# This special exception to the GPL applies to versions of the Autoconf 27710b0ce0bfSmrg# Macro released by the Autoconf Archive. When you make and distribute a 27720b0ce0bfSmrg# modified version of the Autoconf Macro, you may extend this special 27730b0ce0bfSmrg# exception to the GPL to apply to your modified version as well.# 27740b0ce0bfSmrgAC_DEFUN([XORG_CHECK_LINKER_FLAGS], 27750b0ce0bfSmrg[AC_MSG_CHECKING([whether the linker accepts $1]) 27760b0ce0bfSmrgdnl Some hackery here since AC_CACHE_VAL can't handle a non-literal varname: 27770b0ce0bfSmrgAS_LITERAL_IF([$1], 27780b0ce0bfSmrg [AC_CACHE_VAL(AS_TR_SH(xorg_cv_linker_flags_[$1]), [ 27790b0ce0bfSmrg ax_save_FLAGS=$LDFLAGS 27800b0ce0bfSmrg LDFLAGS="$1" 27810b0ce0bfSmrg AC_LINK_IFELSE([m4_default([$4],[AC_LANG_PROGRAM()])], 27820b0ce0bfSmrg AS_TR_SH(xorg_cv_linker_flags_[$1])=yes, 27830b0ce0bfSmrg AS_TR_SH(xorg_cv_linker_flags_[$1])=no) 27840b0ce0bfSmrg LDFLAGS=$ax_save_FLAGS])], 27850b0ce0bfSmrg [ax_save_FLAGS=$LDFLAGS 27860b0ce0bfSmrg LDFLAGS="$1" 27870b0ce0bfSmrg AC_LINK_IFELSE([AC_LANG_PROGRAM()], 27880b0ce0bfSmrg eval AS_TR_SH(xorg_cv_linker_flags_[$1])=yes, 27890b0ce0bfSmrg eval AS_TR_SH(xorg_cv_linker_flags_[$1])=no) 27900b0ce0bfSmrg LDFLAGS=$ax_save_FLAGS]) 27910b0ce0bfSmrgeval xorg_check_linker_flags=$AS_TR_SH(xorg_cv_linker_flags_[$1]) 27920b0ce0bfSmrgAC_MSG_RESULT($xorg_check_linker_flags) 27930b0ce0bfSmrgif test "x$xorg_check_linker_flags" = xyes; then 27940b0ce0bfSmrg m4_default([$2], :) 2795e35d4d8eSmrgelse 27960b0ce0bfSmrg m4_default([$3], :) 2797e35d4d8eSmrgfi 27980b0ce0bfSmrg]) # XORG_CHECK_LINKER_FLAGS 2799e35d4d8eSmrg 28000b0ce0bfSmrg# XORG_MEMORY_CHECK_FLAGS 28010b0ce0bfSmrg# ----------------------- 28020b0ce0bfSmrg# Minimum version: 1.16.0 28030b0ce0bfSmrg# 28040b0ce0bfSmrg# This macro attempts to find appropriate memory checking functionality 28050b0ce0bfSmrg# for various platforms which unit testing code may use to catch various 28060b0ce0bfSmrg# forms of memory allocation and access errors in testing. 28070b0ce0bfSmrg# 28080b0ce0bfSmrg# Interface to module: 28090b0ce0bfSmrg# XORG_MALLOC_DEBUG_ENV - environment variables to set to enable debugging 28100b0ce0bfSmrg# Usually added to TESTS_ENVIRONMENT in Makefile.am 28110b0ce0bfSmrg# 28120b0ce0bfSmrg# If the user sets the value of XORG_MALLOC_DEBUG_ENV, it is used verbatim. 28130b0ce0bfSmrg# 28140b0ce0bfSmrgAC_DEFUN([XORG_MEMORY_CHECK_FLAGS],[ 28150b0ce0bfSmrg 28160b0ce0bfSmrgAC_REQUIRE([AC_CANONICAL_HOST]) 28170b0ce0bfSmrgAC_ARG_VAR([XORG_MALLOC_DEBUG_ENV], 28180b0ce0bfSmrg [Environment variables to enable memory checking in tests]) 28190b0ce0bfSmrg 28200b0ce0bfSmrg# Check for different types of support on different platforms 28210b0ce0bfSmrgcase $host_os in 28220b0ce0bfSmrg solaris*) 28230b0ce0bfSmrg AC_CHECK_LIB([umem], [umem_alloc], 28240b0ce0bfSmrg [malloc_debug_env='LD_PRELOAD=libumem.so UMEM_DEBUG=default']) 28250b0ce0bfSmrg ;; 28260b0ce0bfSmrg *-gnu*) # GNU libc - Value is used as a single byte bit pattern, 28270b0ce0bfSmrg # both directly and inverted, so should not be 0 or 255. 28280b0ce0bfSmrg malloc_debug_env='MALLOC_PERTURB_=15' 28290b0ce0bfSmrg ;; 28300b0ce0bfSmrg darwin*) 28310b0ce0bfSmrg malloc_debug_env='MallocPreScribble=1 MallocScribble=1 DYLD_INSERT_LIBRARIES=/usr/lib/libgmalloc.dylib' 28320b0ce0bfSmrg ;; 28330b0ce0bfSmrg *bsd*) 28340b0ce0bfSmrg malloc_debug_env='MallocPreScribble=1 MallocScribble=1' 28350b0ce0bfSmrg ;; 28360b0ce0bfSmrgesac 28370b0ce0bfSmrg 28380b0ce0bfSmrg# User supplied flags override default flags 28390b0ce0bfSmrgif test "x$XORG_MALLOC_DEBUG_ENV" != "x"; then 28400b0ce0bfSmrg malloc_debug_env="$XORG_MALLOC_DEBUG_ENV" 2841e35d4d8eSmrgfi 2842e35d4d8eSmrg 28430b0ce0bfSmrgAC_SUBST([XORG_MALLOC_DEBUG_ENV],[$malloc_debug_env]) 28440b0ce0bfSmrg]) # XORG_WITH_LINT 2845e35d4d8eSmrg 28460b0ce0bfSmrg# XORG_CHECK_MALLOC_ZERO 28470b0ce0bfSmrg# ---------------------- 28480b0ce0bfSmrg# Minimum version: 1.0.0 28490b0ce0bfSmrg# 28500b0ce0bfSmrg# Defines {MALLOC,XMALLOC,XTMALLOC}_ZERO_CFLAGS appropriately if 28510b0ce0bfSmrg# malloc(0) returns NULL. Packages should add one of these cflags to 28520b0ce0bfSmrg# their AM_CFLAGS (or other appropriate *_CFLAGS) to use them. 28530b0ce0bfSmrgAC_DEFUN([XORG_CHECK_MALLOC_ZERO],[ 28540b0ce0bfSmrgAC_ARG_ENABLE(malloc0returnsnull, 28550b0ce0bfSmrg AS_HELP_STRING([--enable-malloc0returnsnull], 28560b0ce0bfSmrg [malloc(0) returns NULL (default: auto)]), 28570b0ce0bfSmrg [MALLOC_ZERO_RETURNS_NULL=$enableval], 28580b0ce0bfSmrg [MALLOC_ZERO_RETURNS_NULL=auto]) 28590b0ce0bfSmrg 28600b0ce0bfSmrgAC_MSG_CHECKING([whether malloc(0) returns NULL]) 28610b0ce0bfSmrgif test "x$MALLOC_ZERO_RETURNS_NULL" = xauto; then 28620b0ce0bfSmrgAC_CACHE_VAL([xorg_cv_malloc0_returns_null], 28630b0ce0bfSmrg [AC_RUN_IFELSE([AC_LANG_PROGRAM([ 28640b0ce0bfSmrg#include <stdlib.h> 28650b0ce0bfSmrg],[ 28660b0ce0bfSmrg char *m0, *r0, *c0, *p; 28670b0ce0bfSmrg m0 = malloc(0); 28680b0ce0bfSmrg p = malloc(10); 28690b0ce0bfSmrg r0 = realloc(p,0); 28700b0ce0bfSmrg c0 = calloc(0,10); 28710b0ce0bfSmrg exit((m0 == 0 || r0 == 0 || c0 == 0) ? 0 : 1); 28720b0ce0bfSmrg])], 28730b0ce0bfSmrg [xorg_cv_malloc0_returns_null=yes], 28740b0ce0bfSmrg [xorg_cv_malloc0_returns_null=no])]) 28750b0ce0bfSmrgMALLOC_ZERO_RETURNS_NULL=$xorg_cv_malloc0_returns_null 28760b0ce0bfSmrgfi 28770b0ce0bfSmrgAC_MSG_RESULT([$MALLOC_ZERO_RETURNS_NULL]) 28780b0ce0bfSmrg 28790b0ce0bfSmrgif test "x$MALLOC_ZERO_RETURNS_NULL" = xyes; then 28800b0ce0bfSmrg MALLOC_ZERO_CFLAGS="-DMALLOC_0_RETURNS_NULL" 28810b0ce0bfSmrg XMALLOC_ZERO_CFLAGS=$MALLOC_ZERO_CFLAGS 28820b0ce0bfSmrg XTMALLOC_ZERO_CFLAGS="$MALLOC_ZERO_CFLAGS -DXTMALLOC_BC" 2883e35d4d8eSmrgelse 28840b0ce0bfSmrg MALLOC_ZERO_CFLAGS="" 28850b0ce0bfSmrg XMALLOC_ZERO_CFLAGS="" 28860b0ce0bfSmrg XTMALLOC_ZERO_CFLAGS="" 2887e35d4d8eSmrgfi 2888e35d4d8eSmrg 28890b0ce0bfSmrgAC_SUBST([MALLOC_ZERO_CFLAGS]) 28900b0ce0bfSmrgAC_SUBST([XMALLOC_ZERO_CFLAGS]) 28910b0ce0bfSmrgAC_SUBST([XTMALLOC_ZERO_CFLAGS]) 28920b0ce0bfSmrg]) # XORG_CHECK_MALLOC_ZERO 2893e35d4d8eSmrg 28940b0ce0bfSmrg# XORG_WITH_LINT() 28950b0ce0bfSmrg# ---------------- 28960b0ce0bfSmrg# Minimum version: 1.1.0 28970b0ce0bfSmrg# 28980b0ce0bfSmrg# This macro enables the use of a tool that flags some suspicious and 28990b0ce0bfSmrg# non-portable constructs (likely to be bugs) in C language source code. 29000b0ce0bfSmrg# It will attempt to locate the tool and use appropriate options. 29010b0ce0bfSmrg# There are various lint type tools on different platforms. 29020b0ce0bfSmrg# 29030b0ce0bfSmrg# Interface to module: 29040b0ce0bfSmrg# LINT: returns the path to the tool found on the platform 29050b0ce0bfSmrg# or the value set to LINT on the configure cmd line 29060b0ce0bfSmrg# also an Automake conditional 29070b0ce0bfSmrg# LINT_FLAGS: an Automake variable with appropriate flags 29080b0ce0bfSmrg# 29090b0ce0bfSmrg# --with-lint: 'yes' user instructs the module to use lint 29100b0ce0bfSmrg# 'no' user instructs the module not to use lint (default) 29110b0ce0bfSmrg# 29120b0ce0bfSmrg# If the user sets the value of LINT, AC_PATH_PROG skips testing the path. 29130b0ce0bfSmrg# If the user sets the value of LINT_FLAGS, they are used verbatim. 29140b0ce0bfSmrg# 29150b0ce0bfSmrgAC_DEFUN([XORG_WITH_LINT],[ 2916e35d4d8eSmrg 29170b0ce0bfSmrgAC_ARG_VAR([LINT], [Path to a lint-style command]) 29180b0ce0bfSmrgAC_ARG_VAR([LINT_FLAGS], [Flags for the lint-style command]) 29190b0ce0bfSmrgAC_ARG_WITH(lint, [AS_HELP_STRING([--with-lint], 29200b0ce0bfSmrg [Use a lint-style source code checker (default: disabled)])], 29210b0ce0bfSmrg [use_lint=$withval], [use_lint=no]) 2922e35d4d8eSmrg 29230b0ce0bfSmrg# Obtain platform specific info like program name and options 29240b0ce0bfSmrg# The lint program on FreeBSD and NetBSD is different from the one on Solaris 2925e35d4d8eSmrgcase $host_os in 29260b0ce0bfSmrg *linux* | *openbsd* | kfreebsd*-gnu | darwin* | cygwin*) 29270b0ce0bfSmrg lint_name=splint 29280b0ce0bfSmrg lint_options="-badflag" 29290b0ce0bfSmrg ;; 29300b0ce0bfSmrg *freebsd* | *netbsd*) 29310b0ce0bfSmrg lint_name=lint 29320b0ce0bfSmrg lint_options="-u -b" 29330b0ce0bfSmrg ;; 29340b0ce0bfSmrg *solaris*) 29350b0ce0bfSmrg lint_name=lint 29360b0ce0bfSmrg lint_options="-u -b -h -erroff=E_INDISTING_FROM_TRUNC2" 29370b0ce0bfSmrg ;; 29380b0ce0bfSmrgesac 2939e35d4d8eSmrg 29400b0ce0bfSmrg# Test for the presence of the program (either guessed by the code or spelled out by the user) 29410b0ce0bfSmrgif test "x$use_lint" = x"yes" ; then 29420b0ce0bfSmrg AC_PATH_PROG([LINT], [$lint_name]) 29430b0ce0bfSmrg if test "x$LINT" = "x"; then 29440b0ce0bfSmrg AC_MSG_ERROR([--with-lint=yes specified but lint-style tool not found in PATH]) 29450b0ce0bfSmrg fi 29460b0ce0bfSmrgelif test "x$use_lint" = x"no" ; then 29470b0ce0bfSmrg if test "x$LINT" != "x"; then 29480b0ce0bfSmrg AC_MSG_WARN([ignoring LINT environment variable since --with-lint=no was specified]) 29490b0ce0bfSmrg fi 29500b0ce0bfSmrgelse 29510b0ce0bfSmrg AC_MSG_ERROR([--with-lint expects 'yes' or 'no'. Use LINT variable to specify path.]) 29520b0ce0bfSmrgfi 2953e35d4d8eSmrg 29540b0ce0bfSmrg# User supplied flags override default flags 29550b0ce0bfSmrgif test "x$LINT_FLAGS" != "x"; then 29560b0ce0bfSmrg lint_options=$LINT_FLAGS 29570b0ce0bfSmrgfi 2958e35d4d8eSmrg 29590b0ce0bfSmrgAC_SUBST([LINT_FLAGS],[$lint_options]) 29600b0ce0bfSmrgAM_CONDITIONAL(LINT, [test "x$LINT" != x]) 2961e35d4d8eSmrg 29620b0ce0bfSmrg]) # XORG_WITH_LINT 2963e35d4d8eSmrg 29640b0ce0bfSmrg# XORG_LINT_LIBRARY(LIBNAME) 29650b0ce0bfSmrg# -------------------------- 29660b0ce0bfSmrg# Minimum version: 1.1.0 29670b0ce0bfSmrg# 29680b0ce0bfSmrg# Sets up flags for building lint libraries for checking programs that call 29690b0ce0bfSmrg# functions in the library. 29700b0ce0bfSmrg# 29710b0ce0bfSmrg# Interface to module: 29720b0ce0bfSmrg# LINTLIB - Automake variable with the name of lint library file to make 29730b0ce0bfSmrg# MAKE_LINT_LIB - Automake conditional 29740b0ce0bfSmrg# 29750b0ce0bfSmrg# --enable-lint-library: - 'yes' user instructs the module to created a lint library 29760b0ce0bfSmrg# - 'no' user instructs the module not to create a lint library (default) 2977e35d4d8eSmrg 29780b0ce0bfSmrgAC_DEFUN([XORG_LINT_LIBRARY],[ 29790b0ce0bfSmrgAC_REQUIRE([XORG_WITH_LINT]) 29800b0ce0bfSmrgAC_ARG_ENABLE(lint-library, [AS_HELP_STRING([--enable-lint-library], 29810b0ce0bfSmrg [Create lint library (default: disabled)])], 29820b0ce0bfSmrg [make_lint_lib=$enableval], [make_lint_lib=no]) 2983e35d4d8eSmrg 29840b0ce0bfSmrgif test "x$make_lint_lib" = x"yes" ; then 29850b0ce0bfSmrg LINTLIB=llib-l$1.ln 29860b0ce0bfSmrg if test "x$LINT" = "x"; then 29870b0ce0bfSmrg AC_MSG_ERROR([Cannot make lint library without --with-lint]) 29880b0ce0bfSmrg fi 29890b0ce0bfSmrgelif test "x$make_lint_lib" != x"no" ; then 29900b0ce0bfSmrg AC_MSG_ERROR([--enable-lint-library expects 'yes' or 'no'.]) 29910b0ce0bfSmrgfi 2992e35d4d8eSmrg 29930b0ce0bfSmrgAC_SUBST(LINTLIB) 29940b0ce0bfSmrgAM_CONDITIONAL(MAKE_LINT_LIB, [test x$make_lint_lib != xno]) 2995e35d4d8eSmrg 29960b0ce0bfSmrg]) # XORG_LINT_LIBRARY 2997e35d4d8eSmrg 29980b0ce0bfSmrg# XORG_COMPILER_BRAND 29990b0ce0bfSmrg# ------------------- 30000b0ce0bfSmrg# Minimum version: 1.14.0 30010b0ce0bfSmrg# 30020b0ce0bfSmrg# Checks for various brands of compilers and sets flags as appropriate: 30030b0ce0bfSmrg# GNU gcc - relies on AC_PROG_CC (via AC_PROG_CC_C99) to set GCC to "yes" 30040b0ce0bfSmrg# GNU g++ - relies on AC_PROG_CXX to set GXX to "yes" 30050b0ce0bfSmrg# clang compiler - sets CLANGCC to "yes" 30060b0ce0bfSmrg# Intel compiler - sets INTELCC to "yes" 30070b0ce0bfSmrg# Sun/Oracle Solaris Studio cc - sets SUNCC to "yes" 30080b0ce0bfSmrg# 30090b0ce0bfSmrgAC_DEFUN([XORG_COMPILER_BRAND], [ 30100b0ce0bfSmrgAC_LANG_CASE( 30110b0ce0bfSmrg [C], [ 30120b0ce0bfSmrg AC_REQUIRE([AC_PROG_CC_C99]) 30130b0ce0bfSmrg ], 30140b0ce0bfSmrg [C++], [ 30150b0ce0bfSmrg AC_REQUIRE([AC_PROG_CXX]) 30160b0ce0bfSmrg ] 30170b0ce0bfSmrg) 30180b0ce0bfSmrgAC_CHECK_DECL([__clang__], [CLANGCC="yes"], [CLANGCC="no"]) 30190b0ce0bfSmrgAC_CHECK_DECL([__INTEL_COMPILER], [INTELCC="yes"], [INTELCC="no"]) 30200b0ce0bfSmrgAC_CHECK_DECL([__SUNPRO_C], [SUNCC="yes"], [SUNCC="no"]) 30210b0ce0bfSmrg]) # XORG_COMPILER_BRAND 3022e35d4d8eSmrg 30230b0ce0bfSmrg# XORG_TESTSET_CFLAG(<variable>, <flag>, [<alternative flag>, ...]) 30240b0ce0bfSmrg# --------------- 30250b0ce0bfSmrg# Minimum version: 1.16.0 30260b0ce0bfSmrg# 30270b0ce0bfSmrg# Test if the compiler works when passed the given flag as a command line argument. 30280b0ce0bfSmrg# If it succeeds, the flag is appeneded to the given variable. If not, it tries the 30290b0ce0bfSmrg# next flag in the list until there are no more options. 30300b0ce0bfSmrg# 30310b0ce0bfSmrg# Note that this does not guarantee that the compiler supports the flag as some 30320b0ce0bfSmrg# compilers will simply ignore arguments that they do not understand, but we do 30330b0ce0bfSmrg# attempt to weed out false positives by using -Werror=unknown-warning-option and 30340b0ce0bfSmrg# -Werror=unused-command-line-argument 30350b0ce0bfSmrg# 30360b0ce0bfSmrgAC_DEFUN([XORG_TESTSET_CFLAG], [ 30370b0ce0bfSmrgm4_if([$#], 0, [m4_fatal([XORG_TESTSET_CFLAG was given with an unsupported number of arguments])]) 30380b0ce0bfSmrgm4_if([$#], 1, [m4_fatal([XORG_TESTSET_CFLAG was given with an unsupported number of arguments])]) 3039e35d4d8eSmrg 30400b0ce0bfSmrgAC_LANG_COMPILER_REQUIRE 3041e35d4d8eSmrg 30420b0ce0bfSmrgAC_LANG_CASE( 30430b0ce0bfSmrg [C], [ 30440b0ce0bfSmrg AC_REQUIRE([AC_PROG_CC_C99]) 30450b0ce0bfSmrg define([PREFIX], [C]) 30460b0ce0bfSmrg define([CACHE_PREFIX], [cc]) 30470b0ce0bfSmrg define([COMPILER], [$CC]) 30480b0ce0bfSmrg ], 30490b0ce0bfSmrg [C++], [ 30500b0ce0bfSmrg define([PREFIX], [CXX]) 30510b0ce0bfSmrg define([CACHE_PREFIX], [cxx]) 30520b0ce0bfSmrg define([COMPILER], [$CXX]) 30530b0ce0bfSmrg ] 30540b0ce0bfSmrg) 3055e35d4d8eSmrg 30560b0ce0bfSmrg[xorg_testset_save_]PREFIX[FLAGS]="$PREFIX[FLAGS]" 3057e35d4d8eSmrg 30580b0ce0bfSmrgif test "x$[xorg_testset_]CACHE_PREFIX[_unknown_warning_option]" = "x" ; then 30590b0ce0bfSmrg PREFIX[FLAGS]="$PREFIX[FLAGS] -Werror=unknown-warning-option" 30600b0ce0bfSmrg AC_CACHE_CHECK([if ]COMPILER[ supports -Werror=unknown-warning-option], 30610b0ce0bfSmrg [xorg_cv_]CACHE_PREFIX[_flag_unknown_warning_option], 30620b0ce0bfSmrg AC_COMPILE_IFELSE([AC_LANG_SOURCE([int i;])], 30630b0ce0bfSmrg [xorg_cv_]CACHE_PREFIX[_flag_unknown_warning_option=yes], 30640b0ce0bfSmrg [xorg_cv_]CACHE_PREFIX[_flag_unknown_warning_option=no])) 30650b0ce0bfSmrg [xorg_testset_]CACHE_PREFIX[_unknown_warning_option]=$[xorg_cv_]CACHE_PREFIX[_flag_unknown_warning_option] 30660b0ce0bfSmrg PREFIX[FLAGS]="$[xorg_testset_save_]PREFIX[FLAGS]" 30670b0ce0bfSmrgfi 3068e35d4d8eSmrg 30690b0ce0bfSmrgif test "x$[xorg_testset_]CACHE_PREFIX[_unused_command_line_argument]" = "x" ; then 30700b0ce0bfSmrg if test "x$[xorg_testset_]CACHE_PREFIX[_unknown_warning_option]" = "xyes" ; then 30710b0ce0bfSmrg PREFIX[FLAGS]="$PREFIX[FLAGS] -Werror=unknown-warning-option" 30720b0ce0bfSmrg fi 30730b0ce0bfSmrg PREFIX[FLAGS]="$PREFIX[FLAGS] -Werror=unused-command-line-argument" 30740b0ce0bfSmrg AC_CACHE_CHECK([if ]COMPILER[ supports -Werror=unused-command-line-argument], 30750b0ce0bfSmrg [xorg_cv_]CACHE_PREFIX[_flag_unused_command_line_argument], 30760b0ce0bfSmrg AC_COMPILE_IFELSE([AC_LANG_SOURCE([int i;])], 30770b0ce0bfSmrg [xorg_cv_]CACHE_PREFIX[_flag_unused_command_line_argument=yes], 30780b0ce0bfSmrg [xorg_cv_]CACHE_PREFIX[_flag_unused_command_line_argument=no])) 30790b0ce0bfSmrg [xorg_testset_]CACHE_PREFIX[_unused_command_line_argument]=$[xorg_cv_]CACHE_PREFIX[_flag_unused_command_line_argument] 30800b0ce0bfSmrg PREFIX[FLAGS]="$[xorg_testset_save_]PREFIX[FLAGS]" 30810b0ce0bfSmrgfi 3082e35d4d8eSmrg 30830b0ce0bfSmrgfound="no" 30840b0ce0bfSmrgm4_foreach([flag], m4_cdr($@), [ 30850b0ce0bfSmrg if test $found = "no" ; then 30860b0ce0bfSmrg if test "x$xorg_testset_]CACHE_PREFIX[_unknown_warning_option" = "xyes" ; then 30870b0ce0bfSmrg PREFIX[FLAGS]="$PREFIX[FLAGS] -Werror=unknown-warning-option" 30880b0ce0bfSmrg fi 3089e35d4d8eSmrg 30900b0ce0bfSmrg if test "x$xorg_testset_]CACHE_PREFIX[_unused_command_line_argument" = "xyes" ; then 30910b0ce0bfSmrg PREFIX[FLAGS]="$PREFIX[FLAGS] -Werror=unused-command-line-argument" 30920b0ce0bfSmrg fi 3093e35d4d8eSmrg 30940b0ce0bfSmrg PREFIX[FLAGS]="$PREFIX[FLAGS] ]flag[" 3095e35d4d8eSmrg 30960b0ce0bfSmrgdnl Some hackery here since AC_CACHE_VAL can't handle a non-literal varname 30970b0ce0bfSmrg AC_MSG_CHECKING([if ]COMPILER[ supports ]flag[]) 30980b0ce0bfSmrg cacheid=AS_TR_SH([xorg_cv_]CACHE_PREFIX[_flag_]flag[]) 30990b0ce0bfSmrg AC_CACHE_VAL($cacheid, 31000b0ce0bfSmrg [AC_LINK_IFELSE([AC_LANG_PROGRAM([int i;])], 31010b0ce0bfSmrg [eval $cacheid=yes], 31020b0ce0bfSmrg [eval $cacheid=no])]) 3103e35d4d8eSmrg 31040b0ce0bfSmrg PREFIX[FLAGS]="$[xorg_testset_save_]PREFIX[FLAGS]" 3105e35d4d8eSmrg 31060b0ce0bfSmrg eval supported=\$$cacheid 31070b0ce0bfSmrg AC_MSG_RESULT([$supported]) 31080b0ce0bfSmrg if test "$supported" = "yes" ; then 31090b0ce0bfSmrg $1="$$1 ]flag[" 31100b0ce0bfSmrg found="yes" 31110b0ce0bfSmrg fi 31120b0ce0bfSmrg fi 31130b0ce0bfSmrg]) 31140b0ce0bfSmrg]) # XORG_TESTSET_CFLAG 31155a81ca49Smrg 31160b0ce0bfSmrg# XORG_COMPILER_FLAGS 31170b0ce0bfSmrg# --------------- 31180b0ce0bfSmrg# Minimum version: 1.16.0 31190b0ce0bfSmrg# 31200b0ce0bfSmrg# Defines BASE_CFLAGS or BASE_CXXFLAGS to contain a set of command line 31210b0ce0bfSmrg# arguments supported by the selected compiler which do NOT alter the generated 31220b0ce0bfSmrg# code. These arguments will cause the compiler to print various warnings 31230b0ce0bfSmrg# during compilation AND turn a conservative set of warnings into errors. 31240b0ce0bfSmrg# 31250b0ce0bfSmrg# The set of flags supported by BASE_CFLAGS and BASE_CXXFLAGS will grow in 31260b0ce0bfSmrg# future versions of util-macros as options are added to new compilers. 31270b0ce0bfSmrg# 31280b0ce0bfSmrgAC_DEFUN([XORG_COMPILER_FLAGS], [ 31290b0ce0bfSmrgAC_REQUIRE([XORG_COMPILER_BRAND]) 31305a81ca49Smrg 31310b0ce0bfSmrgAC_ARG_ENABLE(selective-werror, 31320b0ce0bfSmrg AS_HELP_STRING([--disable-selective-werror], 31330b0ce0bfSmrg [Turn off selective compiler errors. (default: enabled)]), 31340b0ce0bfSmrg [SELECTIVE_WERROR=$enableval], 31350b0ce0bfSmrg [SELECTIVE_WERROR=yes]) 3136e35d4d8eSmrg 31370b0ce0bfSmrgAC_LANG_CASE( 31380b0ce0bfSmrg [C], [ 31390b0ce0bfSmrg define([PREFIX], [C]) 31400b0ce0bfSmrg ], 31410b0ce0bfSmrg [C++], [ 31420b0ce0bfSmrg define([PREFIX], [CXX]) 31430b0ce0bfSmrg ] 31440b0ce0bfSmrg) 31450b0ce0bfSmrg# -v is too short to test reliably with XORG_TESTSET_CFLAG 31460b0ce0bfSmrgif test "x$SUNCC" = "xyes"; then 31470b0ce0bfSmrg [BASE_]PREFIX[FLAGS]="-v" 31480b0ce0bfSmrgelse 31490b0ce0bfSmrg [BASE_]PREFIX[FLAGS]="" 31500b0ce0bfSmrgfi 3151e35d4d8eSmrg 31520b0ce0bfSmrg# This chunk of warnings were those that existed in the legacy CWARNFLAGS 31530b0ce0bfSmrgXORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Wall]) 31540b0ce0bfSmrgXORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Wpointer-arith]) 31550b0ce0bfSmrgXORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Wmissing-declarations]) 31560b0ce0bfSmrgXORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Wformat=2], [-Wformat]) 3157e35d4d8eSmrg 31580b0ce0bfSmrgAC_LANG_CASE( 31590b0ce0bfSmrg [C], [ 31600b0ce0bfSmrg XORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Wstrict-prototypes]) 31610b0ce0bfSmrg XORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Wmissing-prototypes]) 31620b0ce0bfSmrg XORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Wnested-externs]) 31630b0ce0bfSmrg XORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Wbad-function-cast]) 31640b0ce0bfSmrg XORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Wold-style-definition], [-fd]) 31650b0ce0bfSmrg XORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Wdeclaration-after-statement]) 31660b0ce0bfSmrg ] 31670b0ce0bfSmrg) 3168e35d4d8eSmrg 31690b0ce0bfSmrg# This chunk adds additional warnings that could catch undesired effects. 31700b0ce0bfSmrgXORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Wunused]) 31710b0ce0bfSmrgXORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Wuninitialized]) 31720b0ce0bfSmrgXORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Wshadow]) 31730b0ce0bfSmrgXORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Wmissing-noreturn]) 31740b0ce0bfSmrgXORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Wmissing-format-attribute]) 31750b0ce0bfSmrgXORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Wredundant-decls]) 31760b0ce0bfSmrgXORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Wlogical-op]) 3177e35d4d8eSmrg 31780b0ce0bfSmrg# These are currently disabled because they are noisy. They will be enabled 31790b0ce0bfSmrg# in the future once the codebase is sufficiently modernized to silence 31800b0ce0bfSmrg# them. For now, I don't want them to drown out the other warnings. 31810b0ce0bfSmrg# XORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Wparentheses]) 31820b0ce0bfSmrg# XORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Wcast-align]) 31830b0ce0bfSmrg# XORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Wcast-qual]) 3184e35d4d8eSmrg 31850b0ce0bfSmrg# Turn some warnings into errors, so we don't accidently get successful builds 31860b0ce0bfSmrg# when there are problems that should be fixed. 3187e35d4d8eSmrg 31880b0ce0bfSmrgif test "x$SELECTIVE_WERROR" = "xyes" ; then 31890b0ce0bfSmrgXORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Werror=implicit], [-errwarn=E_NO_EXPLICIT_TYPE_GIVEN -errwarn=E_NO_IMPLICIT_DECL_ALLOWED]) 31900b0ce0bfSmrgXORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Werror=nonnull]) 31910b0ce0bfSmrgXORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Werror=init-self]) 31920b0ce0bfSmrgXORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Werror=main]) 31930b0ce0bfSmrgXORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Werror=missing-braces]) 31940b0ce0bfSmrgXORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Werror=sequence-point]) 31950b0ce0bfSmrgXORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Werror=return-type], [-errwarn=E_FUNC_HAS_NO_RETURN_STMT]) 31960b0ce0bfSmrgXORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Werror=trigraphs]) 31970b0ce0bfSmrgXORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Werror=array-bounds]) 31980b0ce0bfSmrgXORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Werror=write-strings]) 31990b0ce0bfSmrgXORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Werror=address]) 32000b0ce0bfSmrgXORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Werror=int-to-pointer-cast], [-errwarn=E_BAD_PTR_INT_COMBINATION]) 32010b0ce0bfSmrgXORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Werror=pointer-to-int-cast]) # Also -errwarn=E_BAD_PTR_INT_COMBINATION 32020b0ce0bfSmrgelse 32030b0ce0bfSmrgAC_MSG_WARN([You have chosen not to turn some select compiler warnings into errors. This should not be necessary. Please report why you needed to do so in a bug report at $PACKAGE_BUGREPORT]) 32040b0ce0bfSmrgXORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Wimplicit]) 32050b0ce0bfSmrgXORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Wnonnull]) 32060b0ce0bfSmrgXORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Winit-self]) 32070b0ce0bfSmrgXORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Wmain]) 32080b0ce0bfSmrgXORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Wmissing-braces]) 32090b0ce0bfSmrgXORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Wsequence-point]) 32100b0ce0bfSmrgXORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Wreturn-type]) 32110b0ce0bfSmrgXORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Wtrigraphs]) 32120b0ce0bfSmrgXORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Warray-bounds]) 32130b0ce0bfSmrgXORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Wwrite-strings]) 32140b0ce0bfSmrgXORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Waddress]) 32150b0ce0bfSmrgXORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Wint-to-pointer-cast]) 32160b0ce0bfSmrgXORG_TESTSET_CFLAG([[BASE_]PREFIX[FLAGS]], [-Wpointer-to-int-cast]) 32170b0ce0bfSmrgfi 3218e35d4d8eSmrg 32190b0ce0bfSmrgAC_SUBST([BASE_]PREFIX[FLAGS]) 32200b0ce0bfSmrg]) # XORG_COMPILER_FLAGS 3221e35d4d8eSmrg 32220b0ce0bfSmrg# XORG_CWARNFLAGS 32230b0ce0bfSmrg# --------------- 32240b0ce0bfSmrg# Minimum version: 1.2.0 32250b0ce0bfSmrg# Deprecated since: 1.16.0 (Use XORG_COMPILER_FLAGS instead) 32260b0ce0bfSmrg# 32270b0ce0bfSmrg# Defines CWARNFLAGS to enable C compiler warnings. 32280b0ce0bfSmrg# 32290b0ce0bfSmrg# This function is deprecated because it defines -fno-strict-aliasing 32300b0ce0bfSmrg# which alters the code generated by the compiler. If -fno-strict-aliasing 32310b0ce0bfSmrg# is needed, then it should be added explicitly in the module when 32320b0ce0bfSmrg# it is updated to use BASE_CFLAGS. 32330b0ce0bfSmrg# 32340b0ce0bfSmrgAC_DEFUN([XORG_CWARNFLAGS], [ 32350b0ce0bfSmrgAC_REQUIRE([XORG_COMPILER_FLAGS]) 32360b0ce0bfSmrgAC_REQUIRE([XORG_COMPILER_BRAND]) 32370b0ce0bfSmrgAC_LANG_CASE( 32380b0ce0bfSmrg [C], [ 32390b0ce0bfSmrg CWARNFLAGS="$BASE_CFLAGS" 32400b0ce0bfSmrg if test "x$GCC" = xyes ; then 32410b0ce0bfSmrg CWARNFLAGS="$CWARNFLAGS -fno-strict-aliasing" 32420b0ce0bfSmrg fi 32430b0ce0bfSmrg AC_SUBST(CWARNFLAGS) 32440b0ce0bfSmrg ] 32450b0ce0bfSmrg) 32460b0ce0bfSmrg]) # XORG_CWARNFLAGS 3247e35d4d8eSmrg 32480b0ce0bfSmrg# XORG_STRICT_OPTION 32490b0ce0bfSmrg# ----------------------- 32500b0ce0bfSmrg# Minimum version: 1.3.0 32510b0ce0bfSmrg# 32520b0ce0bfSmrg# Add configure option to enable strict compilation flags, such as treating 32530b0ce0bfSmrg# warnings as fatal errors. 32540b0ce0bfSmrg# If --enable-strict-compilation is passed to configure, adds strict flags to 32550b0ce0bfSmrg# $BASE_CFLAGS or $BASE_CXXFLAGS and the deprecated $CWARNFLAGS. 32560b0ce0bfSmrg# 32570b0ce0bfSmrg# Starting in 1.14.0 also exports $STRICT_CFLAGS for use in other tests or 32580b0ce0bfSmrg# when strict compilation is unconditionally desired. 32590b0ce0bfSmrgAC_DEFUN([XORG_STRICT_OPTION], [ 32600b0ce0bfSmrgAC_REQUIRE([XORG_CWARNFLAGS]) 32610b0ce0bfSmrgAC_REQUIRE([XORG_COMPILER_FLAGS]) 3262e35d4d8eSmrg 32630b0ce0bfSmrgAC_ARG_ENABLE(strict-compilation, 32640b0ce0bfSmrg AS_HELP_STRING([--enable-strict-compilation], 32650b0ce0bfSmrg [Enable all warnings from compiler and make them errors (default: disabled)]), 32660b0ce0bfSmrg [STRICT_COMPILE=$enableval], [STRICT_COMPILE=no]) 3267e35d4d8eSmrg 32680b0ce0bfSmrgAC_LANG_CASE( 32690b0ce0bfSmrg [C], [ 32700b0ce0bfSmrg define([PREFIX], [C]) 32710b0ce0bfSmrg ], 32720b0ce0bfSmrg [C++], [ 32730b0ce0bfSmrg define([PREFIX], [CXX]) 32740b0ce0bfSmrg ] 32750b0ce0bfSmrg) 3276e35d4d8eSmrg 32770b0ce0bfSmrg[STRICT_]PREFIX[FLAGS]="" 32780b0ce0bfSmrgXORG_TESTSET_CFLAG([[STRICT_]PREFIX[FLAGS]], [-pedantic]) 32790b0ce0bfSmrgXORG_TESTSET_CFLAG([[STRICT_]PREFIX[FLAGS]], [-Werror], [-errwarn]) 3280e35d4d8eSmrg 32810b0ce0bfSmrg# Earlier versions of gcc (eg: 4.2) support -Werror=attributes, but do not 32820b0ce0bfSmrg# activate it with -Werror, so we add it here explicitly. 32830b0ce0bfSmrgXORG_TESTSET_CFLAG([[STRICT_]PREFIX[FLAGS]], [-Werror=attributes]) 3284e35d4d8eSmrg 32850b0ce0bfSmrgif test "x$STRICT_COMPILE" = "xyes"; then 32860b0ce0bfSmrg [BASE_]PREFIX[FLAGS]="$[BASE_]PREFIX[FLAGS] $[STRICT_]PREFIX[FLAGS]" 32870b0ce0bfSmrg AC_LANG_CASE([C], [CWARNFLAGS="$CWARNFLAGS $STRICT_CFLAGS"]) 3288e35d4d8eSmrgfi 32890b0ce0bfSmrgAC_SUBST([STRICT_]PREFIX[FLAGS]) 32900b0ce0bfSmrgAC_SUBST([BASE_]PREFIX[FLAGS]) 32910b0ce0bfSmrgAC_LANG_CASE([C], AC_SUBST([CWARNFLAGS])) 32920b0ce0bfSmrg]) # XORG_STRICT_OPTION 3293e35d4d8eSmrg 32940b0ce0bfSmrg# XORG_DEFAULT_OPTIONS 32950b0ce0bfSmrg# -------------------- 32960b0ce0bfSmrg# Minimum version: 1.3.0 32970b0ce0bfSmrg# 32980b0ce0bfSmrg# Defines default options for X.Org modules. 32990b0ce0bfSmrg# 33000b0ce0bfSmrgAC_DEFUN([XORG_DEFAULT_OPTIONS], [ 33010b0ce0bfSmrgAC_REQUIRE([AC_PROG_INSTALL]) 33020b0ce0bfSmrgXORG_COMPILER_FLAGS 33030b0ce0bfSmrgXORG_CWARNFLAGS 33040b0ce0bfSmrgXORG_STRICT_OPTION 33050b0ce0bfSmrgXORG_RELEASE_VERSION 33060b0ce0bfSmrgXORG_CHANGELOG 33070b0ce0bfSmrgXORG_INSTALL 33080b0ce0bfSmrgXORG_MANPAGE_SECTIONS 33090b0ce0bfSmrgm4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])], 33100b0ce0bfSmrg [AC_SUBST([AM_DEFAULT_VERBOSITY], [1])]) 33110b0ce0bfSmrg]) # XORG_DEFAULT_OPTIONS 3312e35d4d8eSmrg 33130b0ce0bfSmrg# XORG_INSTALL() 33140b0ce0bfSmrg# ---------------- 33150b0ce0bfSmrg# Minimum version: 1.4.0 33160b0ce0bfSmrg# 33170b0ce0bfSmrg# Defines the variable INSTALL_CMD as the command to copy 33180b0ce0bfSmrg# INSTALL from $prefix/share/util-macros. 33190b0ce0bfSmrg# 33200b0ce0bfSmrgAC_DEFUN([XORG_INSTALL], [ 33210b0ce0bfSmrgAC_REQUIRE([PKG_PROG_PKG_CONFIG]) 33220b0ce0bfSmrgmacros_datadir=`$PKG_CONFIG --print-errors --variable=pkgdatadir xorg-macros` 33230b0ce0bfSmrgINSTALL_CMD="(cp -f "$macros_datadir/INSTALL" \$(top_srcdir)/.INSTALL.tmp && \ 33240b0ce0bfSmrgmv \$(top_srcdir)/.INSTALL.tmp \$(top_srcdir)/INSTALL) \ 33250b0ce0bfSmrg|| (rm -f \$(top_srcdir)/.INSTALL.tmp; test -e \$(top_srcdir)/INSTALL || ( \ 33260b0ce0bfSmrgtouch \$(top_srcdir)/INSTALL; \ 33270b0ce0bfSmrgecho 'failed to copy INSTALL from util-macros: installing empty INSTALL.' >&2))" 33280b0ce0bfSmrgAC_SUBST([INSTALL_CMD]) 33290b0ce0bfSmrg]) # XORG_INSTALL 33300b0ce0bfSmrgdnl Copyright 2005 Red Hat, Inc 33310b0ce0bfSmrgdnl 33320b0ce0bfSmrgdnl Permission to use, copy, modify, distribute, and sell this software and its 33330b0ce0bfSmrgdnl documentation for any purpose is hereby granted without fee, provided that 33340b0ce0bfSmrgdnl the above copyright notice appear in all copies and that both that 33350b0ce0bfSmrgdnl copyright notice and this permission notice appear in supporting 33360b0ce0bfSmrgdnl documentation. 33370b0ce0bfSmrgdnl 33380b0ce0bfSmrgdnl The above copyright notice and this permission notice shall be included 33390b0ce0bfSmrgdnl in all copies or substantial portions of the Software. 33400b0ce0bfSmrgdnl 33410b0ce0bfSmrgdnl THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS 33420b0ce0bfSmrgdnl OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 33430b0ce0bfSmrgdnl MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 33440b0ce0bfSmrgdnl IN NO EVENT SHALL THE OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR 33450b0ce0bfSmrgdnl OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, 33460b0ce0bfSmrgdnl ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 33470b0ce0bfSmrgdnl OTHER DEALINGS IN THE SOFTWARE. 33480b0ce0bfSmrgdnl 33490b0ce0bfSmrgdnl Except as contained in this notice, the name of the copyright holders shall 33500b0ce0bfSmrgdnl not be used in advertising or otherwise to promote the sale, use or 33510b0ce0bfSmrgdnl other dealings in this Software without prior written authorization 33520b0ce0bfSmrgdnl from the copyright holders. 33530b0ce0bfSmrgdnl 3354e35d4d8eSmrg 33550b0ce0bfSmrg# XORG_RELEASE_VERSION 33560b0ce0bfSmrg# -------------------- 33570b0ce0bfSmrg# Defines PACKAGE_VERSION_{MAJOR,MINOR,PATCHLEVEL} for modules to use. 3358e35d4d8eSmrg 33590b0ce0bfSmrgAC_DEFUN([XORG_RELEASE_VERSION],[ 33600b0ce0bfSmrg AC_DEFINE_UNQUOTED([PACKAGE_VERSION_MAJOR], 33610b0ce0bfSmrg [`echo $PACKAGE_VERSION | cut -d . -f 1`], 33620b0ce0bfSmrg [Major version of this package]) 33630b0ce0bfSmrg PVM=`echo $PACKAGE_VERSION | cut -d . -f 2 | cut -d - -f 1` 33640b0ce0bfSmrg if test "x$PVM" = "x"; then 33650b0ce0bfSmrg PVM="0" 33660b0ce0bfSmrg fi 33670b0ce0bfSmrg AC_DEFINE_UNQUOTED([PACKAGE_VERSION_MINOR], 33680b0ce0bfSmrg [$PVM], 33690b0ce0bfSmrg [Minor version of this package]) 33700b0ce0bfSmrg PVP=`echo $PACKAGE_VERSION | cut -d . -f 3 | cut -d - -f 1` 33710b0ce0bfSmrg if test "x$PVP" = "x"; then 33720b0ce0bfSmrg PVP="0" 33730b0ce0bfSmrg fi 33740b0ce0bfSmrg AC_DEFINE_UNQUOTED([PACKAGE_VERSION_PATCHLEVEL], 33750b0ce0bfSmrg [$PVP], 33760b0ce0bfSmrg [Patch version of this package]) 33770b0ce0bfSmrg]) 3378e35d4d8eSmrg 33790b0ce0bfSmrg# XORG_CHANGELOG() 33800b0ce0bfSmrg# ---------------- 33810b0ce0bfSmrg# Minimum version: 1.2.0 33820b0ce0bfSmrg# 33830b0ce0bfSmrg# Defines the variable CHANGELOG_CMD as the command to generate 33840b0ce0bfSmrg# ChangeLog from git. 33850b0ce0bfSmrg# 33860b0ce0bfSmrg# 33870b0ce0bfSmrgAC_DEFUN([XORG_CHANGELOG], [ 33880b0ce0bfSmrgCHANGELOG_CMD="((GIT_DIR=\$(top_srcdir)/.git git log > \$(top_srcdir)/.changelog.tmp) 2>/dev/null && \ 33890b0ce0bfSmrgmv \$(top_srcdir)/.changelog.tmp \$(top_srcdir)/ChangeLog) \ 33900b0ce0bfSmrg|| (rm -f \$(top_srcdir)/.changelog.tmp; test -e \$(top_srcdir)/ChangeLog || ( \ 33910b0ce0bfSmrgtouch \$(top_srcdir)/ChangeLog; \ 33920b0ce0bfSmrgecho 'git failed to create ChangeLog: installing empty ChangeLog.' >&2))" 33930b0ce0bfSmrgAC_SUBST([CHANGELOG_CMD]) 33940b0ce0bfSmrg]) # XORG_CHANGELOG 3395e35d4d8eSmrg 33960b0ce0bfSmrg# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*- 33970b0ce0bfSmrg# 33980b0ce0bfSmrg# Copyright (C) 1996-2001, 2003-2019, 2021-2022 Free Software 33990b0ce0bfSmrg# Foundation, Inc. 34000b0ce0bfSmrg# Written by Gordon Matzigkeit, 1996 34010b0ce0bfSmrg# 34020b0ce0bfSmrg# This file is free software; the Free Software Foundation gives 34030b0ce0bfSmrg# unlimited permission to copy and/or distribute it, with or without 34040b0ce0bfSmrg# modifications, as long as this notice is preserved. 3405e35d4d8eSmrg 34060b0ce0bfSmrgm4_define([_LT_COPYING], [dnl 34070b0ce0bfSmrg# Copyright (C) 2014 Free Software Foundation, Inc. 34080b0ce0bfSmrg# This is free software; see the source for copying conditions. There is NO 34090b0ce0bfSmrg# warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 3410e35d4d8eSmrg 34110b0ce0bfSmrg# GNU Libtool is free software; you can redistribute it and/or modify 34120b0ce0bfSmrg# it under the terms of the GNU General Public License as published by 34130b0ce0bfSmrg# the Free Software Foundation; either version 2 of of the License, or 34140b0ce0bfSmrg# (at your option) any later version. 34150b0ce0bfSmrg# 34160b0ce0bfSmrg# As a special exception to the GNU General Public License, if you 34170b0ce0bfSmrg# distribute this file as part of a program or library that is built 34180b0ce0bfSmrg# using GNU Libtool, you may include this file under the same 34190b0ce0bfSmrg# distribution terms that you use for the rest of that program. 34200b0ce0bfSmrg# 34210b0ce0bfSmrg# GNU Libtool is distributed in the hope that it will be useful, but 34220b0ce0bfSmrg# WITHOUT ANY WARRANTY; without even the implied warranty of 34230b0ce0bfSmrg# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 34240b0ce0bfSmrg# GNU General Public License for more details. 34250b0ce0bfSmrg# 34260b0ce0bfSmrg# You should have received a copy of the GNU General Public License 34270b0ce0bfSmrg# along with this program. If not, see <http://www.gnu.org/licenses/>. 34280b0ce0bfSmrg]) 3429e35d4d8eSmrg 34300b0ce0bfSmrg# serial 59 LT_INIT 3431e35d4d8eSmrg 3432e35d4d8eSmrg 34330b0ce0bfSmrg# LT_PREREQ(VERSION) 34340b0ce0bfSmrg# ------------------ 34350b0ce0bfSmrg# Complain and exit if this libtool version is less that VERSION. 34360b0ce0bfSmrgm4_defun([LT_PREREQ], 34370b0ce0bfSmrg[m4_if(m4_version_compare(m4_defn([LT_PACKAGE_VERSION]), [$1]), -1, 34380b0ce0bfSmrg [m4_default([$3], 34390b0ce0bfSmrg [m4_fatal([Libtool version $1 or higher is required], 34400b0ce0bfSmrg 63)])], 34410b0ce0bfSmrg [$2])]) 3442e35d4d8eSmrg 3443e35d4d8eSmrg 34440b0ce0bfSmrg# _LT_CHECK_BUILDDIR 34450b0ce0bfSmrg# ------------------ 34460b0ce0bfSmrg# Complain if the absolute build directory name contains unusual characters 34470b0ce0bfSmrgm4_defun([_LT_CHECK_BUILDDIR], 34480b0ce0bfSmrg[case `pwd` in 34490b0ce0bfSmrg *\ * | *\ *) 34500b0ce0bfSmrg AC_MSG_WARN([Libtool does not cope well with whitespace in `pwd`]) ;; 34510b0ce0bfSmrgesac 34520b0ce0bfSmrg]) 3453e35d4d8eSmrg 34540b0ce0bfSmrg 34550b0ce0bfSmrg# LT_INIT([OPTIONS]) 34560b0ce0bfSmrg# ------------------ 34570b0ce0bfSmrgAC_DEFUN([LT_INIT], 34580b0ce0bfSmrg[AC_PREREQ([2.62])dnl We use AC_PATH_PROGS_FEATURE_CHECK 34590b0ce0bfSmrgAC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl 34600b0ce0bfSmrgAC_BEFORE([$0], [LT_LANG])dnl 34610b0ce0bfSmrgAC_BEFORE([$0], [LT_OUTPUT])dnl 34620b0ce0bfSmrgAC_BEFORE([$0], [LTDL_INIT])dnl 34630b0ce0bfSmrgm4_require([_LT_CHECK_BUILDDIR])dnl 34640b0ce0bfSmrg 34650b0ce0bfSmrgdnl Autoconf doesn't catch unexpanded LT_ macros by default: 34660b0ce0bfSmrgm4_pattern_forbid([^_?LT_[A-Z_]+$])dnl 34670b0ce0bfSmrgm4_pattern_allow([^(_LT_EOF|LT_DLGLOBAL|LT_DLLAZY_OR_NOW|LT_MULTI_MODULE)$])dnl 34680b0ce0bfSmrgdnl aclocal doesn't pull ltoptions.m4, ltsugar.m4, or ltversion.m4 34690b0ce0bfSmrgdnl unless we require an AC_DEFUNed macro: 34700b0ce0bfSmrgAC_REQUIRE([LTOPTIONS_VERSION])dnl 34710b0ce0bfSmrgAC_REQUIRE([LTSUGAR_VERSION])dnl 34720b0ce0bfSmrgAC_REQUIRE([LTVERSION_VERSION])dnl 34730b0ce0bfSmrgAC_REQUIRE([LTOBSOLETE_VERSION])dnl 34740b0ce0bfSmrgm4_require([_LT_PROG_LTMAIN])dnl 34750b0ce0bfSmrg 34760b0ce0bfSmrg_LT_SHELL_INIT([SHELL=${CONFIG_SHELL-/bin/sh}]) 34770b0ce0bfSmrg 34780b0ce0bfSmrgdnl Parse OPTIONS 34790b0ce0bfSmrg_LT_SET_OPTIONS([$0], [$1]) 34800b0ce0bfSmrg 34810b0ce0bfSmrg# This can be used to rebuild libtool when needed 34820b0ce0bfSmrgLIBTOOL_DEPS=$ltmain 34830b0ce0bfSmrg 34840b0ce0bfSmrg# Always use our own libtool. 34850b0ce0bfSmrgLIBTOOL='$(SHELL) $(top_builddir)/libtool' 34860b0ce0bfSmrgAC_SUBST(LIBTOOL)dnl 34870b0ce0bfSmrg 34880b0ce0bfSmrg_LT_SETUP 34890b0ce0bfSmrg 34900b0ce0bfSmrg# Only expand once: 34910b0ce0bfSmrgm4_define([LT_INIT]) 34920b0ce0bfSmrg])# LT_INIT 3493e35d4d8eSmrg 3494e35d4d8eSmrg# Old names: 34950b0ce0bfSmrgAU_ALIAS([AC_PROG_LIBTOOL], [LT_INIT]) 34960b0ce0bfSmrgAU_ALIAS([AM_PROG_LIBTOOL], [LT_INIT]) 3497e35d4d8eSmrgdnl aclocal-1.4 backwards compatibility: 34980b0ce0bfSmrgdnl AC_DEFUN([AC_PROG_LIBTOOL], []) 34990b0ce0bfSmrgdnl AC_DEFUN([AM_PROG_LIBTOOL], []) 3500e35d4d8eSmrg 3501e35d4d8eSmrg 35020b0ce0bfSmrg# _LT_PREPARE_CC_BASENAME 35030b0ce0bfSmrg# ----------------------- 35040b0ce0bfSmrgm4_defun([_LT_PREPARE_CC_BASENAME], [ 35050b0ce0bfSmrg# Calculate cc_basename. Skip known compiler wrappers and cross-prefix. 35060b0ce0bfSmrgfunc_cc_basename () 35070b0ce0bfSmrg{ 35080b0ce0bfSmrg for cc_temp in @S|@*""; do 35090b0ce0bfSmrg case $cc_temp in 35100b0ce0bfSmrg compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;; 35110b0ce0bfSmrg distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;; 35120b0ce0bfSmrg \-*) ;; 35130b0ce0bfSmrg *) break;; 35140b0ce0bfSmrg esac 35150b0ce0bfSmrg done 35160b0ce0bfSmrg func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` 35170b0ce0bfSmrg} 35180b0ce0bfSmrg])# _LT_PREPARE_CC_BASENAME 3519e35d4d8eSmrg 3520e35d4d8eSmrg 35210b0ce0bfSmrg# _LT_CC_BASENAME(CC) 35220b0ce0bfSmrg# ------------------- 35230b0ce0bfSmrg# It would be clearer to call AC_REQUIREs from _LT_PREPARE_CC_BASENAME, 35240b0ce0bfSmrg# but that macro is also expanded into generated libtool script, which 35250b0ce0bfSmrg# arranges for $SED and $ECHO to be set by different means. 35260b0ce0bfSmrgm4_defun([_LT_CC_BASENAME], 35270b0ce0bfSmrg[m4_require([_LT_PREPARE_CC_BASENAME])dnl 35280b0ce0bfSmrgAC_REQUIRE([_LT_DECL_SED])dnl 35290b0ce0bfSmrgAC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl 35300b0ce0bfSmrgfunc_cc_basename $1 35310b0ce0bfSmrgcc_basename=$func_cc_basename_result 35320b0ce0bfSmrg]) 3533e35d4d8eSmrg 3534e35d4d8eSmrg 35350b0ce0bfSmrg# _LT_FILEUTILS_DEFAULTS 3536e35d4d8eSmrg# ---------------------- 35370b0ce0bfSmrg# It is okay to use these file commands and assume they have been set 35380b0ce0bfSmrg# sensibly after 'm4_require([_LT_FILEUTILS_DEFAULTS])'. 35390b0ce0bfSmrgm4_defun([_LT_FILEUTILS_DEFAULTS], 35400b0ce0bfSmrg[: ${CP="cp -f"} 35410b0ce0bfSmrg: ${MV="mv -f"} 35420b0ce0bfSmrg: ${RM="rm -f"} 35430b0ce0bfSmrg])# _LT_FILEUTILS_DEFAULTS 3544e35d4d8eSmrg 3545e35d4d8eSmrg 35460b0ce0bfSmrg# _LT_SETUP 35470b0ce0bfSmrg# --------- 35480b0ce0bfSmrgm4_defun([_LT_SETUP], 35490b0ce0bfSmrg[AC_REQUIRE([AC_CANONICAL_HOST])dnl 35500b0ce0bfSmrgAC_REQUIRE([AC_CANONICAL_BUILD])dnl 35510b0ce0bfSmrgAC_REQUIRE([_LT_PREPARE_SED_QUOTE_VARS])dnl 35520b0ce0bfSmrgAC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl 3553e35d4d8eSmrg 35540b0ce0bfSmrg_LT_DECL([], [PATH_SEPARATOR], [1], [The PATH separator for the build system])dnl 35550b0ce0bfSmrgdnl 35560b0ce0bfSmrg_LT_DECL([], [host_alias], [0], [The host system])dnl 35570b0ce0bfSmrg_LT_DECL([], [host], [0])dnl 35580b0ce0bfSmrg_LT_DECL([], [host_os], [0])dnl 35590b0ce0bfSmrgdnl 35600b0ce0bfSmrg_LT_DECL([], [build_alias], [0], [The build system])dnl 35610b0ce0bfSmrg_LT_DECL([], [build], [0])dnl 35620b0ce0bfSmrg_LT_DECL([], [build_os], [0])dnl 35630b0ce0bfSmrgdnl 35640b0ce0bfSmrgAC_REQUIRE([AC_PROG_CC])dnl 35650b0ce0bfSmrgAC_REQUIRE([LT_PATH_LD])dnl 35660b0ce0bfSmrgAC_REQUIRE([LT_PATH_NM])dnl 35670b0ce0bfSmrgdnl 35680b0ce0bfSmrgAC_REQUIRE([AC_PROG_LN_S])dnl 35690b0ce0bfSmrgtest -z "$LN_S" && LN_S="ln -s" 35700b0ce0bfSmrg_LT_DECL([], [LN_S], [1], [Whether we need soft or hard links])dnl 35710b0ce0bfSmrgdnl 35720b0ce0bfSmrgAC_REQUIRE([LT_CMD_MAX_LEN])dnl 35730b0ce0bfSmrg_LT_DECL([objext], [ac_objext], [0], [Object file suffix (normally "o")])dnl 35740b0ce0bfSmrg_LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl 35750b0ce0bfSmrgdnl 35760b0ce0bfSmrgm4_require([_LT_FILEUTILS_DEFAULTS])dnl 35770b0ce0bfSmrgm4_require([_LT_CHECK_SHELL_FEATURES])dnl 35780b0ce0bfSmrgm4_require([_LT_PATH_CONVERSION_FUNCTIONS])dnl 35790b0ce0bfSmrgm4_require([_LT_CMD_RELOAD])dnl 35800b0ce0bfSmrgm4_require([_LT_DECL_FILECMD])dnl 35810b0ce0bfSmrgm4_require([_LT_CHECK_MAGIC_METHOD])dnl 35820b0ce0bfSmrgm4_require([_LT_CHECK_SHAREDLIB_FROM_LINKLIB])dnl 35830b0ce0bfSmrgm4_require([_LT_CMD_OLD_ARCHIVE])dnl 35840b0ce0bfSmrgm4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl 35850b0ce0bfSmrgm4_require([_LT_WITH_SYSROOT])dnl 35860b0ce0bfSmrgm4_require([_LT_CMD_TRUNCATE])dnl 3587e35d4d8eSmrg 35880b0ce0bfSmrg_LT_CONFIG_LIBTOOL_INIT([ 35890b0ce0bfSmrg# See if we are running on zsh, and set the options that allow our 35900b0ce0bfSmrg# commands through without removal of \ escapes INIT. 35910b0ce0bfSmrgif test -n "\${ZSH_VERSION+set}"; then 35920b0ce0bfSmrg setopt NO_GLOB_SUBST 35930b0ce0bfSmrgfi 35940b0ce0bfSmrg]) 35950b0ce0bfSmrgif test -n "${ZSH_VERSION+set}"; then 35960b0ce0bfSmrg setopt NO_GLOB_SUBST 35970b0ce0bfSmrgfi 3598e35d4d8eSmrg 35990b0ce0bfSmrg_LT_CHECK_OBJDIR 3600e35d4d8eSmrg 36010b0ce0bfSmrgm4_require([_LT_TAG_COMPILER])dnl 3602e35d4d8eSmrg 36030b0ce0bfSmrgcase $host_os in 36040b0ce0bfSmrgaix3*) 36050b0ce0bfSmrg # AIX sometimes has problems with the GCC collect2 program. For some 36060b0ce0bfSmrg # reason, if we set the COLLECT_NAMES environment variable, the problems 36070b0ce0bfSmrg # vanish in a puff of smoke. 36080b0ce0bfSmrg if test set != "${COLLECT_NAMES+set}"; then 36090b0ce0bfSmrg COLLECT_NAMES= 36100b0ce0bfSmrg export COLLECT_NAMES 3611e35d4d8eSmrg fi 3612e35d4d8eSmrg ;; 36130b0ce0bfSmrgesac 3614e35d4d8eSmrg 36150b0ce0bfSmrg# Global variables: 36160b0ce0bfSmrgofile=libtool 36170b0ce0bfSmrgcan_build_shared=yes 3618e35d4d8eSmrg 36190b0ce0bfSmrg# All known linkers require a '.a' archive for static linking (except MSVC and 36200b0ce0bfSmrg# ICC, which need '.lib'). 36210b0ce0bfSmrglibext=a 3622e35d4d8eSmrg 36230b0ce0bfSmrgwith_gnu_ld=$lt_cv_prog_gnu_ld 3624e35d4d8eSmrg 36250b0ce0bfSmrgold_CC=$CC 36260b0ce0bfSmrgold_CFLAGS=$CFLAGS 3627e35d4d8eSmrg 36280b0ce0bfSmrg# Set sane defaults for various variables 36290b0ce0bfSmrgtest -z "$CC" && CC=cc 36300b0ce0bfSmrgtest -z "$LTCC" && LTCC=$CC 36310b0ce0bfSmrgtest -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS 36320b0ce0bfSmrgtest -z "$LD" && LD=ld 36330b0ce0bfSmrgtest -z "$ac_objext" && ac_objext=o 3634e35d4d8eSmrg 36350b0ce0bfSmrg_LT_CC_BASENAME([$compiler]) 3636e35d4d8eSmrg 36370b0ce0bfSmrg# Only perform the check for file, if the check method requires it 36380b0ce0bfSmrgtest -z "$MAGIC_CMD" && MAGIC_CMD=file 36390b0ce0bfSmrgcase $deplibs_check_method in 36400b0ce0bfSmrgfile_magic*) 36410b0ce0bfSmrg if test "$file_magic_cmd" = '$MAGIC_CMD'; then 36420b0ce0bfSmrg _LT_PATH_MAGIC 3643e35d4d8eSmrg fi 3644e35d4d8eSmrg ;; 36450b0ce0bfSmrgesac 3646e35d4d8eSmrg 36470b0ce0bfSmrg# Use C for the default configuration in the libtool script 36480b0ce0bfSmrgLT_SUPPORTED_TAG([CC]) 36490b0ce0bfSmrg_LT_LANG_C_CONFIG 36500b0ce0bfSmrg_LT_LANG_DEFAULT_CONFIG 36510b0ce0bfSmrg_LT_CONFIG_COMMANDS 36520b0ce0bfSmrg])# _LT_SETUP 3653e35d4d8eSmrg 3654e35d4d8eSmrg 36550b0ce0bfSmrg# _LT_PREPARE_SED_QUOTE_VARS 36560b0ce0bfSmrg# -------------------------- 36570b0ce0bfSmrg# Define a few sed substitution that help us do robust quoting. 36580b0ce0bfSmrgm4_defun([_LT_PREPARE_SED_QUOTE_VARS], 36590b0ce0bfSmrg[# Backslashify metacharacters that are still active within 36600b0ce0bfSmrg# double-quoted strings. 36610b0ce0bfSmrgsed_quote_subst='s/\([["`$\\]]\)/\\\1/g' 3662e35d4d8eSmrg 36630b0ce0bfSmrg# Same as above, but do not quote variable references. 36640b0ce0bfSmrgdouble_quote_subst='s/\([["`\\]]\)/\\\1/g' 3665e35d4d8eSmrg 36660b0ce0bfSmrg# Sed substitution to delay expansion of an escaped shell variable in a 36670b0ce0bfSmrg# double_quote_subst'ed string. 36680b0ce0bfSmrgdelay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' 3669e35d4d8eSmrg 36700b0ce0bfSmrg# Sed substitution to delay expansion of an escaped single quote. 36710b0ce0bfSmrgdelay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g' 3672e35d4d8eSmrg 36730b0ce0bfSmrg# Sed substitution to avoid accidental globbing in evaled expressions 36740b0ce0bfSmrgno_glob_subst='s/\*/\\\*/g' 36750b0ce0bfSmrg]) 3676e35d4d8eSmrg 36770b0ce0bfSmrg# _LT_PROG_LTMAIN 36780b0ce0bfSmrg# --------------- 36790b0ce0bfSmrg# Note that this code is called both from 'configure', and 'config.status' 36800b0ce0bfSmrg# now that we use AC_CONFIG_COMMANDS to generate libtool. Notably, 36810b0ce0bfSmrg# 'config.status' has no value for ac_aux_dir unless we are using Automake, 36820b0ce0bfSmrg# so we pass a copy along to make sure it has a sensible value anyway. 36830b0ce0bfSmrgm4_defun([_LT_PROG_LTMAIN], 36840b0ce0bfSmrg[m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl 36850b0ce0bfSmrg_LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir']) 36860b0ce0bfSmrgltmain=$ac_aux_dir/ltmain.sh 36870b0ce0bfSmrg])# _LT_PROG_LTMAIN 3688e35d4d8eSmrg 3689e35d4d8eSmrg 3690e35d4d8eSmrg 36910b0ce0bfSmrg# So that we can recreate a full libtool script including additional 36920b0ce0bfSmrg# tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS 36930b0ce0bfSmrg# in macros and then make a single call at the end using the 'libtool' 36940b0ce0bfSmrg# label. 3695e35d4d8eSmrg 3696e35d4d8eSmrg 36970b0ce0bfSmrg# _LT_CONFIG_LIBTOOL_INIT([INIT-COMMANDS]) 36980b0ce0bfSmrg# ---------------------------------------- 36990b0ce0bfSmrg# Register INIT-COMMANDS to be passed to AC_CONFIG_COMMANDS later. 37000b0ce0bfSmrgm4_define([_LT_CONFIG_LIBTOOL_INIT], 37010b0ce0bfSmrg[m4_ifval([$1], 37020b0ce0bfSmrg [m4_append([_LT_OUTPUT_LIBTOOL_INIT], 37030b0ce0bfSmrg [$1 37040b0ce0bfSmrg])])]) 3705e35d4d8eSmrg 37060b0ce0bfSmrg# Initialize. 37070b0ce0bfSmrgm4_define([_LT_OUTPUT_LIBTOOL_INIT]) 3708e35d4d8eSmrg 3709e35d4d8eSmrg 37100b0ce0bfSmrg# _LT_CONFIG_LIBTOOL([COMMANDS]) 37110b0ce0bfSmrg# ------------------------------ 37120b0ce0bfSmrg# Register COMMANDS to be passed to AC_CONFIG_COMMANDS later. 37130b0ce0bfSmrgm4_define([_LT_CONFIG_LIBTOOL], 37140b0ce0bfSmrg[m4_ifval([$1], 37150b0ce0bfSmrg [m4_append([_LT_OUTPUT_LIBTOOL_COMMANDS], 37160b0ce0bfSmrg [$1 37170b0ce0bfSmrg])])]) 3718e35d4d8eSmrg 37190b0ce0bfSmrg# Initialize. 37200b0ce0bfSmrgm4_define([_LT_OUTPUT_LIBTOOL_COMMANDS]) 3721e35d4d8eSmrg 37220b0ce0bfSmrg 37230b0ce0bfSmrg# _LT_CONFIG_SAVE_COMMANDS([COMMANDS], [INIT_COMMANDS]) 37240b0ce0bfSmrg# ----------------------------------------------------- 37250b0ce0bfSmrgm4_defun([_LT_CONFIG_SAVE_COMMANDS], 37260b0ce0bfSmrg[_LT_CONFIG_LIBTOOL([$1]) 37270b0ce0bfSmrg_LT_CONFIG_LIBTOOL_INIT([$2]) 3728e35d4d8eSmrg]) 3729e35d4d8eSmrg 3730e35d4d8eSmrg 37310b0ce0bfSmrg# _LT_FORMAT_COMMENT([COMMENT]) 37320b0ce0bfSmrg# ----------------------------- 37330b0ce0bfSmrg# Add leading comment marks to the start of each line, and a trailing 37340b0ce0bfSmrg# full-stop to the whole comment if one is not present already. 37350b0ce0bfSmrgm4_define([_LT_FORMAT_COMMENT], 37360b0ce0bfSmrg[m4_ifval([$1], [ 37370b0ce0bfSmrgm4_bpatsubst([m4_bpatsubst([$1], [^ *], [# ])], 37380b0ce0bfSmrg [['`$\]], [\\\&])]m4_bmatch([$1], [[!?.]$], [], [.]) 37390b0ce0bfSmrg)]) 3740e35d4d8eSmrg 3741e35d4d8eSmrg 3742e35d4d8eSmrg 3743e35d4d8eSmrg 3744e35d4d8eSmrg 37450b0ce0bfSmrg# _LT_DECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION], [IS-TAGGED?]) 37460b0ce0bfSmrg# ------------------------------------------------------------------- 37470b0ce0bfSmrg# CONFIGNAME is the name given to the value in the libtool script. 37480b0ce0bfSmrg# VARNAME is the (base) name used in the configure script. 37490b0ce0bfSmrg# VALUE may be 0, 1 or 2 for a computed quote escaped value based on 37500b0ce0bfSmrg# VARNAME. Any other value will be used directly. 37510b0ce0bfSmrgm4_define([_LT_DECL], 37520b0ce0bfSmrg[lt_if_append_uniq([lt_decl_varnames], [$2], [, ], 37530b0ce0bfSmrg [lt_dict_add_subkey([lt_decl_dict], [$2], [libtool_name], 37540b0ce0bfSmrg [m4_ifval([$1], [$1], [$2])]) 37550b0ce0bfSmrg lt_dict_add_subkey([lt_decl_dict], [$2], [value], [$3]) 37560b0ce0bfSmrg m4_ifval([$4], 37570b0ce0bfSmrg [lt_dict_add_subkey([lt_decl_dict], [$2], [description], [$4])]) 37580b0ce0bfSmrg lt_dict_add_subkey([lt_decl_dict], [$2], 37590b0ce0bfSmrg [tagged?], [m4_ifval([$5], [yes], [no])])]) 37600b0ce0bfSmrg]) 3761e35d4d8eSmrg 3762e35d4d8eSmrg 37630b0ce0bfSmrg# _LT_TAGDECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION]) 37640b0ce0bfSmrg# -------------------------------------------------------- 37650b0ce0bfSmrgm4_define([_LT_TAGDECL], [_LT_DECL([$1], [$2], [$3], [$4], [yes])]) 3766e35d4d8eSmrg 3767e35d4d8eSmrg 37680b0ce0bfSmrg# lt_decl_tag_varnames([SEPARATOR], [VARNAME1...]) 37690b0ce0bfSmrg# ------------------------------------------------ 37700b0ce0bfSmrgm4_define([lt_decl_tag_varnames], 37710b0ce0bfSmrg[_lt_decl_filter([tagged?], [yes], $@)]) 3772e35d4d8eSmrg 3773e35d4d8eSmrg 37740b0ce0bfSmrg# _lt_decl_filter(SUBKEY, VALUE, [SEPARATOR], [VARNAME1..]) 37750b0ce0bfSmrg# --------------------------------------------------------- 37760b0ce0bfSmrgm4_define([_lt_decl_filter], 37770b0ce0bfSmrg[m4_case([$#], 37780b0ce0bfSmrg [0], [m4_fatal([$0: too few arguments: $#])], 37790b0ce0bfSmrg [1], [m4_fatal([$0: too few arguments: $#: $1])], 37800b0ce0bfSmrg [2], [lt_dict_filter([lt_decl_dict], [$1], [$2], [], lt_decl_varnames)], 37810b0ce0bfSmrg [3], [lt_dict_filter([lt_decl_dict], [$1], [$2], [$3], lt_decl_varnames)], 37820b0ce0bfSmrg [lt_dict_filter([lt_decl_dict], $@)])[]dnl 37830b0ce0bfSmrg]) 3784e35d4d8eSmrg 3785e35d4d8eSmrg 37860b0ce0bfSmrg# lt_decl_quote_varnames([SEPARATOR], [VARNAME1...]) 37870b0ce0bfSmrg# -------------------------------------------------- 37880b0ce0bfSmrgm4_define([lt_decl_quote_varnames], 37890b0ce0bfSmrg[_lt_decl_filter([value], [1], $@)]) 3790e35d4d8eSmrg 3791e35d4d8eSmrg 37920b0ce0bfSmrg# lt_decl_dquote_varnames([SEPARATOR], [VARNAME1...]) 37930b0ce0bfSmrg# --------------------------------------------------- 37940b0ce0bfSmrgm4_define([lt_decl_dquote_varnames], 37950b0ce0bfSmrg[_lt_decl_filter([value], [2], $@)]) 3796e35d4d8eSmrg 3797e35d4d8eSmrg 37980b0ce0bfSmrg# lt_decl_varnames_tagged([SEPARATOR], [VARNAME1...]) 37990b0ce0bfSmrg# --------------------------------------------------- 38000b0ce0bfSmrgm4_define([lt_decl_varnames_tagged], 38010b0ce0bfSmrg[m4_assert([$# <= 2])dnl 38020b0ce0bfSmrg_$0(m4_quote(m4_default([$1], [[, ]])), 38030b0ce0bfSmrg m4_ifval([$2], [[$2]], [m4_dquote(lt_decl_tag_varnames)]), 38040b0ce0bfSmrg m4_split(m4_normalize(m4_quote(_LT_TAGS)), [ ]))]) 38050b0ce0bfSmrgm4_define([_lt_decl_varnames_tagged], 38060b0ce0bfSmrg[m4_ifval([$3], [lt_combine([$1], [$2], [_], $3)])]) 3807e35d4d8eSmrg 3808e35d4d8eSmrg 38090b0ce0bfSmrg# lt_decl_all_varnames([SEPARATOR], [VARNAME1...]) 38100b0ce0bfSmrg# ------------------------------------------------ 38110b0ce0bfSmrgm4_define([lt_decl_all_varnames], 38120b0ce0bfSmrg[_$0(m4_quote(m4_default([$1], [[, ]])), 38130b0ce0bfSmrg m4_if([$2], [], 38140b0ce0bfSmrg m4_quote(lt_decl_varnames), 38150b0ce0bfSmrg m4_quote(m4_shift($@))))[]dnl 38160b0ce0bfSmrg]) 38170b0ce0bfSmrgm4_define([_lt_decl_all_varnames], 38180b0ce0bfSmrg[lt_join($@, lt_decl_varnames_tagged([$1], 38190b0ce0bfSmrg lt_decl_tag_varnames([[, ]], m4_shift($@))))dnl 38200b0ce0bfSmrg]) 3821e35d4d8eSmrg 3822e35d4d8eSmrg 38230b0ce0bfSmrg# _LT_CONFIG_STATUS_DECLARE([VARNAME]) 38240b0ce0bfSmrg# ------------------------------------ 38250b0ce0bfSmrg# Quote a variable value, and forward it to 'config.status' so that its 38260b0ce0bfSmrg# declaration there will have the same value as in 'configure'. VARNAME 38270b0ce0bfSmrg# must have a single quote delimited value for this to work. 38280b0ce0bfSmrgm4_define([_LT_CONFIG_STATUS_DECLARE], 38290b0ce0bfSmrg[$1='`$ECHO "$][$1" | $SED "$delay_single_quote_subst"`']) 3830e35d4d8eSmrg 3831e35d4d8eSmrg 38320b0ce0bfSmrg# _LT_CONFIG_STATUS_DECLARATIONS 38330b0ce0bfSmrg# ------------------------------ 38340b0ce0bfSmrg# We delimit libtool config variables with single quotes, so when 38350b0ce0bfSmrg# we write them to config.status, we have to be sure to quote all 38360b0ce0bfSmrg# embedded single quotes properly. In configure, this macro expands 38370b0ce0bfSmrg# each variable declared with _LT_DECL (and _LT_TAGDECL) into: 38380b0ce0bfSmrg# 38390b0ce0bfSmrg# <var>='`$ECHO "$<var>" | $SED "$delay_single_quote_subst"`' 38400b0ce0bfSmrgm4_defun([_LT_CONFIG_STATUS_DECLARATIONS], 38410b0ce0bfSmrg[m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames), 38420b0ce0bfSmrg [m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])]) 3843e35d4d8eSmrg 3844e35d4d8eSmrg 38450b0ce0bfSmrg# _LT_LIBTOOL_TAGS 38460b0ce0bfSmrg# ---------------- 38470b0ce0bfSmrg# Output comment and list of tags supported by the script 38480b0ce0bfSmrgm4_defun([_LT_LIBTOOL_TAGS], 38490b0ce0bfSmrg[_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl 38500b0ce0bfSmrgavailable_tags='_LT_TAGS'dnl 38510b0ce0bfSmrg]) 3852e35d4d8eSmrg 3853e35d4d8eSmrg 38540b0ce0bfSmrg# _LT_LIBTOOL_DECLARE(VARNAME, [TAG]) 38550b0ce0bfSmrg# ----------------------------------- 38560b0ce0bfSmrg# Extract the dictionary values for VARNAME (optionally with TAG) and 38570b0ce0bfSmrg# expand to a commented shell variable setting: 38580b0ce0bfSmrg# 38590b0ce0bfSmrg# # Some comment about what VAR is for. 38600b0ce0bfSmrg# visible_name=$lt_internal_name 38610b0ce0bfSmrgm4_define([_LT_LIBTOOL_DECLARE], 38620b0ce0bfSmrg[_LT_FORMAT_COMMENT(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], 38630b0ce0bfSmrg [description])))[]dnl 38640b0ce0bfSmrgm4_pushdef([_libtool_name], 38650b0ce0bfSmrg m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [libtool_name])))[]dnl 38660b0ce0bfSmrgm4_case(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [value])), 38670b0ce0bfSmrg [0], [_libtool_name=[$]$1], 38680b0ce0bfSmrg [1], [_libtool_name=$lt_[]$1], 38690b0ce0bfSmrg [2], [_libtool_name=$lt_[]$1], 38700b0ce0bfSmrg [_libtool_name=lt_dict_fetch([lt_decl_dict], [$1], [value])])[]dnl 38710b0ce0bfSmrgm4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl 38720b0ce0bfSmrg]) 3873e35d4d8eSmrg 3874e35d4d8eSmrg 38750b0ce0bfSmrg# _LT_LIBTOOL_CONFIG_VARS 38760b0ce0bfSmrg# ----------------------- 38770b0ce0bfSmrg# Produce commented declarations of non-tagged libtool config variables 38780b0ce0bfSmrg# suitable for insertion in the LIBTOOL CONFIG section of the 'libtool' 38790b0ce0bfSmrg# script. Tagged libtool config variables (even for the LIBTOOL CONFIG 38800b0ce0bfSmrg# section) are produced by _LT_LIBTOOL_TAG_VARS. 38810b0ce0bfSmrgm4_defun([_LT_LIBTOOL_CONFIG_VARS], 38820b0ce0bfSmrg[m4_foreach([_lt_var], 38830b0ce0bfSmrg m4_quote(_lt_decl_filter([tagged?], [no], [], lt_decl_varnames)), 38840b0ce0bfSmrg [m4_n([_LT_LIBTOOL_DECLARE(_lt_var)])])]) 3885e35d4d8eSmrg 3886e35d4d8eSmrg 38870b0ce0bfSmrg# _LT_LIBTOOL_TAG_VARS(TAG) 38880b0ce0bfSmrg# ------------------------- 38890b0ce0bfSmrgm4_define([_LT_LIBTOOL_TAG_VARS], 38900b0ce0bfSmrg[m4_foreach([_lt_var], m4_quote(lt_decl_tag_varnames), 38910b0ce0bfSmrg [m4_n([_LT_LIBTOOL_DECLARE(_lt_var, [$1])])])]) 3892e35d4d8eSmrg 3893e35d4d8eSmrg 38940b0ce0bfSmrg# _LT_TAGVAR(VARNAME, [TAGNAME]) 38950b0ce0bfSmrg# ------------------------------ 38960b0ce0bfSmrgm4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])]) 3897e35d4d8eSmrg 3898e35d4d8eSmrg 38990b0ce0bfSmrg# _LT_CONFIG_COMMANDS 39000b0ce0bfSmrg# ------------------- 39010b0ce0bfSmrg# Send accumulated output to $CONFIG_STATUS. Thanks to the lists of 39020b0ce0bfSmrg# variables for single and double quote escaping we saved from calls 39030b0ce0bfSmrg# to _LT_DECL, we can put quote escaped variables declarations 39040b0ce0bfSmrg# into 'config.status', and then the shell code to quote escape them in 39050b0ce0bfSmrg# for loops in 'config.status'. Finally, any additional code accumulated 39060b0ce0bfSmrg# from calls to _LT_CONFIG_LIBTOOL_INIT is expanded. 39070b0ce0bfSmrgm4_defun([_LT_CONFIG_COMMANDS], 39080b0ce0bfSmrg[AC_PROVIDE_IFELSE([LT_OUTPUT], 39090b0ce0bfSmrg dnl If the libtool generation code has been placed in $CONFIG_LT, 39100b0ce0bfSmrg dnl instead of duplicating it all over again into config.status, 39110b0ce0bfSmrg dnl then we will have config.status run $CONFIG_LT later, so it 39120b0ce0bfSmrg dnl needs to know what name is stored there: 39130b0ce0bfSmrg [AC_CONFIG_COMMANDS([libtool], 39140b0ce0bfSmrg [$SHELL $CONFIG_LT || AS_EXIT(1)], [CONFIG_LT='$CONFIG_LT'])], 39150b0ce0bfSmrg dnl If the libtool generation code is destined for config.status, 39160b0ce0bfSmrg dnl expand the accumulated commands and init code now: 39170b0ce0bfSmrg [AC_CONFIG_COMMANDS([libtool], 39180b0ce0bfSmrg [_LT_OUTPUT_LIBTOOL_COMMANDS], [_LT_OUTPUT_LIBTOOL_COMMANDS_INIT])]) 39190b0ce0bfSmrg])#_LT_CONFIG_COMMANDS 3920e35d4d8eSmrg 3921e35d4d8eSmrg 39220b0ce0bfSmrg# Initialize. 39230b0ce0bfSmrgm4_define([_LT_OUTPUT_LIBTOOL_COMMANDS_INIT], 39240b0ce0bfSmrg[ 3925e35d4d8eSmrg 39260b0ce0bfSmrg# The HP-UX ksh and POSIX shell print the target directory to stdout 39270b0ce0bfSmrg# if CDPATH is set. 39280b0ce0bfSmrg(unset CDPATH) >/dev/null 2>&1 && unset CDPATH 392932b578d3Smrg 39300b0ce0bfSmrgsed_quote_subst='$sed_quote_subst' 39310b0ce0bfSmrgdouble_quote_subst='$double_quote_subst' 39320b0ce0bfSmrgdelay_variable_subst='$delay_variable_subst' 39330b0ce0bfSmrg_LT_CONFIG_STATUS_DECLARATIONS 39340b0ce0bfSmrgLTCC='$LTCC' 39350b0ce0bfSmrgLTCFLAGS='$LTCFLAGS' 39360b0ce0bfSmrgcompiler='$compiler_DEFAULT' 393732b578d3Smrg 39380b0ce0bfSmrg# A function that is used when there is no print builtin or printf. 39390b0ce0bfSmrgfunc_fallback_echo () 39400b0ce0bfSmrg{ 39410b0ce0bfSmrg eval 'cat <<_LTECHO_EOF 39420b0ce0bfSmrg\$[]1 39430b0ce0bfSmrg_LTECHO_EOF' 39440b0ce0bfSmrg} 39451b12faf6Smrg 39460b0ce0bfSmrg# Quote evaled strings. 39470b0ce0bfSmrgfor var in lt_decl_all_varnames([[ \ 39480b0ce0bfSmrg]], lt_decl_quote_varnames); do 39490b0ce0bfSmrg case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in 39500b0ce0bfSmrg *[[\\\\\\\`\\"\\\$]]*) 39510b0ce0bfSmrg eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes 39521b12faf6Smrg ;; 39530b0ce0bfSmrg *) 39540b0ce0bfSmrg eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" 39551b12faf6Smrg ;; 39560b0ce0bfSmrg esac 39570b0ce0bfSmrgdone 39580b0ce0bfSmrg 39590b0ce0bfSmrg# Double-quote double-evaled strings. 39600b0ce0bfSmrgfor var in lt_decl_all_varnames([[ \ 39610b0ce0bfSmrg]], lt_decl_dquote_varnames); do 39620b0ce0bfSmrg case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in 39630b0ce0bfSmrg *[[\\\\\\\`\\"\\\$]]*) 39640b0ce0bfSmrg eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes 39651b12faf6Smrg ;; 39661b12faf6Smrg *) 39670b0ce0bfSmrg eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" 39682a51b5beSmrg ;; 3969d31dbc53Smrg esac 39700b0ce0bfSmrgdone 397132b578d3Smrg 39720b0ce0bfSmrg_LT_OUTPUT_LIBTOOL_INIT 39730b0ce0bfSmrg]) 39742a51b5beSmrg 39750b0ce0bfSmrg# _LT_GENERATED_FILE_INIT(FILE, [COMMENT]) 39760b0ce0bfSmrg# ------------------------------------ 39770b0ce0bfSmrg# Generate a child script FILE with all initialization necessary to 39780b0ce0bfSmrg# reuse the environment learned by the parent script, and make the 39790b0ce0bfSmrg# file executable. If COMMENT is supplied, it is inserted after the 39800b0ce0bfSmrg# '#!' sequence but before initialization text begins. After this 39810b0ce0bfSmrg# macro, additional text can be appended to FILE to form the body of 39820b0ce0bfSmrg# the child script. The macro ends with non-zero status if the 39830b0ce0bfSmrg# file could not be fully written (such as if the disk is full). 39840b0ce0bfSmrgm4_ifdef([AS_INIT_GENERATED], 39850b0ce0bfSmrg[m4_defun([_LT_GENERATED_FILE_INIT],[AS_INIT_GENERATED($@)])], 39860b0ce0bfSmrg[m4_defun([_LT_GENERATED_FILE_INIT], 39870b0ce0bfSmrg[m4_require([AS_PREPARE])]dnl 39880b0ce0bfSmrg[m4_pushdef([AS_MESSAGE_LOG_FD])]dnl 39890b0ce0bfSmrg[lt_write_fail=0 39900b0ce0bfSmrgcat >$1 <<_ASEOF || lt_write_fail=1 39910b0ce0bfSmrg#! $SHELL 39920b0ce0bfSmrg# Generated by $as_me. 39930b0ce0bfSmrg$2 39940b0ce0bfSmrgSHELL=\${CONFIG_SHELL-$SHELL} 39950b0ce0bfSmrgexport SHELL 39960b0ce0bfSmrg_ASEOF 39970b0ce0bfSmrgcat >>$1 <<\_ASEOF || lt_write_fail=1 39980b0ce0bfSmrgAS_SHELL_SANITIZE 39990b0ce0bfSmrg_AS_PREPARE 40000b0ce0bfSmrgexec AS_MESSAGE_FD>&1 40010b0ce0bfSmrg_ASEOF 40020b0ce0bfSmrgtest 0 = "$lt_write_fail" && chmod +x $1[]dnl 40030b0ce0bfSmrgm4_popdef([AS_MESSAGE_LOG_FD])])])# _LT_GENERATED_FILE_INIT 40042a51b5beSmrg 40050b0ce0bfSmrg# LT_OUTPUT 40060b0ce0bfSmrg# --------- 40070b0ce0bfSmrg# This macro allows early generation of the libtool script (before 40080b0ce0bfSmrg# AC_OUTPUT is called), incase it is used in configure for compilation 40090b0ce0bfSmrg# tests. 40100b0ce0bfSmrgAC_DEFUN([LT_OUTPUT], 40110b0ce0bfSmrg[: ${CONFIG_LT=./config.lt} 40120b0ce0bfSmrgAC_MSG_NOTICE([creating $CONFIG_LT]) 40130b0ce0bfSmrg_LT_GENERATED_FILE_INIT(["$CONFIG_LT"], 40140b0ce0bfSmrg[# Run this file to recreate a libtool stub with the current configuration.]) 40151b12faf6Smrg 40160b0ce0bfSmrgcat >>"$CONFIG_LT" <<\_LTEOF 40170b0ce0bfSmrglt_cl_silent=false 40180b0ce0bfSmrgexec AS_MESSAGE_LOG_FD>>config.log 40190b0ce0bfSmrg{ 40200b0ce0bfSmrg echo 40210b0ce0bfSmrg AS_BOX([Running $as_me.]) 40220b0ce0bfSmrg} >&AS_MESSAGE_LOG_FD 40231b12faf6Smrg 40240b0ce0bfSmrglt_cl_help="\ 40250b0ce0bfSmrg'$as_me' creates a local libtool stub from the current configuration, 40260b0ce0bfSmrgfor use in further configure time tests before the real libtool is 40270b0ce0bfSmrggenerated. 40281b12faf6Smrg 40290b0ce0bfSmrgUsage: $[0] [[OPTIONS]] 4030e35d4d8eSmrg 40310b0ce0bfSmrg -h, --help print this help, then exit 40320b0ce0bfSmrg -V, --version print version number, then exit 40330b0ce0bfSmrg -q, --quiet do not print progress messages 40340b0ce0bfSmrg -d, --debug don't remove temporary files 40351b12faf6Smrg 40360b0ce0bfSmrgReport bugs to <bug-libtool@gnu.org>." 40371b12faf6Smrg 40380b0ce0bfSmrglt_cl_version="\ 40390b0ce0bfSmrgm4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl 40400b0ce0bfSmrgm4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION]) 40410b0ce0bfSmrgconfigured by $[0], generated by m4_PACKAGE_STRING. 40421b12faf6Smrg 40430b0ce0bfSmrgCopyright (C) 2011 Free Software Foundation, Inc. 40440b0ce0bfSmrgThis config.lt script is free software; the Free Software Foundation 40450b0ce0bfSmrggives unlimited permision to copy, distribute and modify it." 40461b12faf6Smrg 40470b0ce0bfSmrgwhile test 0 != $[#] 40480b0ce0bfSmrgdo 40490b0ce0bfSmrg case $[1] in 40500b0ce0bfSmrg --version | --v* | -V ) 40510b0ce0bfSmrg echo "$lt_cl_version"; exit 0 ;; 40520b0ce0bfSmrg --help | --h* | -h ) 40530b0ce0bfSmrg echo "$lt_cl_help"; exit 0 ;; 40540b0ce0bfSmrg --debug | --d* | -d ) 40550b0ce0bfSmrg debug=: ;; 40560b0ce0bfSmrg --quiet | --q* | --silent | --s* | -q ) 40570b0ce0bfSmrg lt_cl_silent=: ;; 40581b12faf6Smrg 40590b0ce0bfSmrg -*) AC_MSG_ERROR([unrecognized option: $[1] 40600b0ce0bfSmrgTry '$[0] --help' for more information.]) ;; 4061e35d4d8eSmrg 40620b0ce0bfSmrg *) AC_MSG_ERROR([unrecognized argument: $[1] 40630b0ce0bfSmrgTry '$[0] --help' for more information.]) ;; 40640b0ce0bfSmrg esac 40650b0ce0bfSmrg shift 40660b0ce0bfSmrgdone 40671b12faf6Smrg 40680b0ce0bfSmrgif $lt_cl_silent; then 40690b0ce0bfSmrg exec AS_MESSAGE_FD>/dev/null 40700b0ce0bfSmrgfi 40710b0ce0bfSmrg_LTEOF 40721b12faf6Smrg 40730b0ce0bfSmrgcat >>"$CONFIG_LT" <<_LTEOF 40740b0ce0bfSmrg_LT_OUTPUT_LIBTOOL_COMMANDS_INIT 40750b0ce0bfSmrg_LTEOF 40761b12faf6Smrg 40770b0ce0bfSmrgcat >>"$CONFIG_LT" <<\_LTEOF 40780b0ce0bfSmrgAC_MSG_NOTICE([creating $ofile]) 40790b0ce0bfSmrg_LT_OUTPUT_LIBTOOL_COMMANDS 40800b0ce0bfSmrgAS_EXIT(0) 40810b0ce0bfSmrg_LTEOF 40820b0ce0bfSmrgchmod +x "$CONFIG_LT" 40831b12faf6Smrg 40840b0ce0bfSmrg# configure is writing to config.log, but config.lt does its own redirection, 40850b0ce0bfSmrg# appending to config.log, which fails on DOS, as config.log is still kept 40860b0ce0bfSmrg# open by configure. Here we exec the FD to /dev/null, effectively closing 40870b0ce0bfSmrg# config.log, so it can be properly (re)opened and appended to by config.lt. 40880b0ce0bfSmrglt_cl_success=: 40890b0ce0bfSmrgtest yes = "$silent" && 40900b0ce0bfSmrg lt_config_lt_args="$lt_config_lt_args --quiet" 40910b0ce0bfSmrgexec AS_MESSAGE_LOG_FD>/dev/null 40920b0ce0bfSmrg$SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false 40930b0ce0bfSmrgexec AS_MESSAGE_LOG_FD>>config.log 40940b0ce0bfSmrg$lt_cl_success || AS_EXIT(1) 40950b0ce0bfSmrg])# LT_OUTPUT 409632b578d3Smrg 409732b578d3Smrg 40980b0ce0bfSmrg# _LT_CONFIG(TAG) 40990b0ce0bfSmrg# --------------- 41000b0ce0bfSmrg# If TAG is the built-in tag, create an initial libtool script with a 41010b0ce0bfSmrg# default configuration from the untagged config vars. Otherwise add code 41020b0ce0bfSmrg# to config.status for appending the configuration named by TAG from the 41030b0ce0bfSmrg# matching tagged config vars. 41040b0ce0bfSmrgm4_defun([_LT_CONFIG], 41050b0ce0bfSmrg[m4_require([_LT_FILEUTILS_DEFAULTS])dnl 41060b0ce0bfSmrg_LT_CONFIG_SAVE_COMMANDS([ 41070b0ce0bfSmrg m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl 41080b0ce0bfSmrg m4_if(_LT_TAG, [C], [ 41090b0ce0bfSmrg # See if we are running on zsh, and set the options that allow our 41100b0ce0bfSmrg # commands through without removal of \ escapes. 41110b0ce0bfSmrg if test -n "${ZSH_VERSION+set}"; then 41120b0ce0bfSmrg setopt NO_GLOB_SUBST 41130b0ce0bfSmrg fi 411432b578d3Smrg 41150b0ce0bfSmrg cfgfile=${ofile}T 41160b0ce0bfSmrg trap "$RM \"$cfgfile\"; exit 1" 1 2 15 41170b0ce0bfSmrg $RM "$cfgfile" 411832b578d3Smrg 41190b0ce0bfSmrg cat <<_LT_EOF >> "$cfgfile" 41200b0ce0bfSmrg#! $SHELL 41210b0ce0bfSmrg# Generated automatically by $as_me ($PACKAGE) $VERSION 41220b0ce0bfSmrg# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: 41230b0ce0bfSmrg# NOTE: Changes made to this file will be lost: look at ltmain.sh. 412432b578d3Smrg 41250b0ce0bfSmrg# Provide generalized library-building support services. 41260b0ce0bfSmrg# Written by Gordon Matzigkeit, 1996 412732b578d3Smrg 41280b0ce0bfSmrg_LT_COPYING 41290b0ce0bfSmrg_LT_LIBTOOL_TAGS 413032b578d3Smrg 41310b0ce0bfSmrg# Configured defaults for sys_lib_dlsearch_path munging. 41320b0ce0bfSmrg: \${LT_SYS_LIBRARY_PATH="$configure_time_lt_sys_library_path"} 413332b578d3Smrg 41340b0ce0bfSmrg# ### BEGIN LIBTOOL CONFIG 41350b0ce0bfSmrg_LT_LIBTOOL_CONFIG_VARS 41360b0ce0bfSmrg_LT_LIBTOOL_TAG_VARS 41370b0ce0bfSmrg# ### END LIBTOOL CONFIG 413832b578d3Smrg 41390b0ce0bfSmrg_LT_EOF 414032b578d3Smrg 41410b0ce0bfSmrg cat <<'_LT_EOF' >> "$cfgfile" 4142e35d4d8eSmrg 41430b0ce0bfSmrg# ### BEGIN FUNCTIONS SHARED WITH CONFIGURE 41442a51b5beSmrg 41450b0ce0bfSmrg_LT_PREPARE_MUNGE_PATH_LIST 41460b0ce0bfSmrg_LT_PREPARE_CC_BASENAME 41472a51b5beSmrg 41480b0ce0bfSmrg# ### END FUNCTIONS SHARED WITH CONFIGURE 414932b578d3Smrg 41500b0ce0bfSmrg_LT_EOF 41511b12faf6Smrg 41521b12faf6Smrg case $host_os in 41530b0ce0bfSmrg aix3*) 41540b0ce0bfSmrg cat <<\_LT_EOF >> "$cfgfile" 41550b0ce0bfSmrg# AIX sometimes has problems with the GCC collect2 program. For some 41560b0ce0bfSmrg# reason, if we set the COLLECT_NAMES environment variable, the problems 41570b0ce0bfSmrg# vanish in a puff of smoke. 41580b0ce0bfSmrgif test set != "${COLLECT_NAMES+set}"; then 41590b0ce0bfSmrg COLLECT_NAMES= 41600b0ce0bfSmrg export COLLECT_NAMES 41610b0ce0bfSmrgfi 41620b0ce0bfSmrg_LT_EOF 4163e35d4d8eSmrg ;; 41641b12faf6Smrg esac 416532b578d3Smrg 41660b0ce0bfSmrg _LT_PROG_LTMAIN 416732b578d3Smrg 41680b0ce0bfSmrg # We use sed instead of cat because bash on DJGPP gets confused if 41690b0ce0bfSmrg # if finds mixed CR/LF and LF-only lines. Since sed operates in 41700b0ce0bfSmrg # text mode, it properly converts lines to CR/LF. This bash problem 41710b0ce0bfSmrg # is reportedly fixed, but why not run on old versions too? 41720b0ce0bfSmrg $SED '$q' "$ltmain" >> "$cfgfile" \ 41730b0ce0bfSmrg || (rm -f "$cfgfile"; exit 1) 4174e35d4d8eSmrg 41750b0ce0bfSmrg mv -f "$cfgfile" "$ofile" || 41760b0ce0bfSmrg (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") 41770b0ce0bfSmrg chmod +x "$ofile" 41780b0ce0bfSmrg], 41790b0ce0bfSmrg[cat <<_LT_EOF >> "$ofile" 4180e35d4d8eSmrg 41810b0ce0bfSmrgdnl Unfortunately we have to use $1 here, since _LT_TAG is not expanded 41820b0ce0bfSmrgdnl in a comment (ie after a #). 41830b0ce0bfSmrg# ### BEGIN LIBTOOL TAG CONFIG: $1 41840b0ce0bfSmrg_LT_LIBTOOL_TAG_VARS(_LT_TAG) 41850b0ce0bfSmrg# ### END LIBTOOL TAG CONFIG: $1 41860b0ce0bfSmrg_LT_EOF 41870b0ce0bfSmrg])dnl /m4_if 41880b0ce0bfSmrg], 41890b0ce0bfSmrg[m4_if([$1], [], [ 41900b0ce0bfSmrg PACKAGE='$PACKAGE' 41910b0ce0bfSmrg VERSION='$VERSION' 41920b0ce0bfSmrg RM='$RM' 41930b0ce0bfSmrg ofile='$ofile'], []) 41940b0ce0bfSmrg])dnl /_LT_CONFIG_SAVE_COMMANDS 41950b0ce0bfSmrg])# _LT_CONFIG 419632b578d3Smrg 419732b578d3Smrg 41980b0ce0bfSmrg# LT_SUPPORTED_TAG(TAG) 41990b0ce0bfSmrg# --------------------- 42000b0ce0bfSmrg# Trace this macro to discover what tags are supported by the libtool 42010b0ce0bfSmrg# --tag option, using: 42020b0ce0bfSmrg# autoconf --trace 'LT_SUPPORTED_TAG:$1' 42030b0ce0bfSmrgAC_DEFUN([LT_SUPPORTED_TAG], []) 420432b578d3Smrg 420532b578d3Smrg 42060b0ce0bfSmrg# C support is built-in for now 42070b0ce0bfSmrgm4_define([_LT_LANG_C_enabled], []) 42080b0ce0bfSmrgm4_define([_LT_TAGS], []) 420932b578d3Smrg 421032b578d3Smrg 42110b0ce0bfSmrg# LT_LANG(LANG) 42120b0ce0bfSmrg# ------------- 42130b0ce0bfSmrg# Enable libtool support for the given language if not already enabled. 42140b0ce0bfSmrgAC_DEFUN([LT_LANG], 42150b0ce0bfSmrg[AC_BEFORE([$0], [LT_OUTPUT])dnl 42160b0ce0bfSmrgm4_case([$1], 42170b0ce0bfSmrg [C], [_LT_LANG(C)], 42180b0ce0bfSmrg [C++], [_LT_LANG(CXX)], 42190b0ce0bfSmrg [Go], [_LT_LANG(GO)], 42200b0ce0bfSmrg [Java], [_LT_LANG(GCJ)], 42210b0ce0bfSmrg [Fortran 77], [_LT_LANG(F77)], 42220b0ce0bfSmrg [Fortran], [_LT_LANG(FC)], 42230b0ce0bfSmrg [Windows Resource], [_LT_LANG(RC)], 42240b0ce0bfSmrg [m4_ifdef([_LT_LANG_]$1[_CONFIG], 42250b0ce0bfSmrg [_LT_LANG($1)], 42260b0ce0bfSmrg [m4_fatal([$0: unsupported language: "$1"])])])dnl 42270b0ce0bfSmrg])# LT_LANG 422832b578d3Smrg 42291b12faf6Smrg 42300b0ce0bfSmrg# _LT_LANG(LANGNAME) 42310b0ce0bfSmrg# ------------------ 42320b0ce0bfSmrgm4_defun([_LT_LANG], 42330b0ce0bfSmrg[m4_ifdef([_LT_LANG_]$1[_enabled], [], 42340b0ce0bfSmrg [LT_SUPPORTED_TAG([$1])dnl 42350b0ce0bfSmrg m4_append([_LT_TAGS], [$1 ])dnl 42360b0ce0bfSmrg m4_define([_LT_LANG_]$1[_enabled], [])dnl 42370b0ce0bfSmrg _LT_LANG_$1_CONFIG($1)])dnl 42380b0ce0bfSmrg])# _LT_LANG 423932b578d3Smrg 4240e35d4d8eSmrg 42410b0ce0bfSmrgm4_ifndef([AC_PROG_GO], [ 42420b0ce0bfSmrg# NOTE: This macro has been submitted for inclusion into # 42430b0ce0bfSmrg# GNU Autoconf as AC_PROG_GO. When it is available in # 42440b0ce0bfSmrg# a released version of Autoconf we should remove this # 42450b0ce0bfSmrg# macro and use it instead. # 42460b0ce0bfSmrgm4_defun([AC_PROG_GO], 42470b0ce0bfSmrg[AC_LANG_PUSH(Go)dnl 42480b0ce0bfSmrgAC_ARG_VAR([GOC], [Go compiler command])dnl 42490b0ce0bfSmrgAC_ARG_VAR([GOFLAGS], [Go compiler flags])dnl 42500b0ce0bfSmrg_AC_ARG_VAR_LDFLAGS()dnl 42510b0ce0bfSmrgAC_CHECK_TOOL(GOC, gccgo) 42520b0ce0bfSmrgif test -z "$GOC"; then 42530b0ce0bfSmrg if test -n "$ac_tool_prefix"; then 42540b0ce0bfSmrg AC_CHECK_PROG(GOC, [${ac_tool_prefix}gccgo], [${ac_tool_prefix}gccgo]) 42550b0ce0bfSmrg fi 42560b0ce0bfSmrgfi 42570b0ce0bfSmrgif test -z "$GOC"; then 42580b0ce0bfSmrg AC_CHECK_PROG(GOC, gccgo, gccgo, false) 42590b0ce0bfSmrgfi 42600b0ce0bfSmrg])#m4_defun 42610b0ce0bfSmrg])#m4_ifndef 426232b578d3Smrg 426332b578d3Smrg 42640b0ce0bfSmrg# _LT_LANG_DEFAULT_CONFIG 42650b0ce0bfSmrg# ----------------------- 42660b0ce0bfSmrgm4_defun([_LT_LANG_DEFAULT_CONFIG], 42670b0ce0bfSmrg[AC_PROVIDE_IFELSE([AC_PROG_CXX], 42680b0ce0bfSmrg [LT_LANG(CXX)], 42690b0ce0bfSmrg [m4_define([AC_PROG_CXX], defn([AC_PROG_CXX])[LT_LANG(CXX)])]) 427032b578d3Smrg 42710b0ce0bfSmrgAC_PROVIDE_IFELSE([AC_PROG_F77], 42720b0ce0bfSmrg [LT_LANG(F77)], 42730b0ce0bfSmrg [m4_define([AC_PROG_F77], defn([AC_PROG_F77])[LT_LANG(F77)])]) 427432b578d3Smrg 42750b0ce0bfSmrgAC_PROVIDE_IFELSE([AC_PROG_FC], 42760b0ce0bfSmrg [LT_LANG(FC)], 42770b0ce0bfSmrg [m4_define([AC_PROG_FC], defn([AC_PROG_FC])[LT_LANG(FC)])]) 427832b578d3Smrg 42790b0ce0bfSmrgdnl The call to [A][M_PROG_GCJ] is quoted like that to stop aclocal 42800b0ce0bfSmrgdnl pulling things in needlessly. 42810b0ce0bfSmrgAC_PROVIDE_IFELSE([AC_PROG_GCJ], 42820b0ce0bfSmrg [LT_LANG(GCJ)], 42830b0ce0bfSmrg [AC_PROVIDE_IFELSE([A][M_PROG_GCJ], 42840b0ce0bfSmrg [LT_LANG(GCJ)], 42850b0ce0bfSmrg [AC_PROVIDE_IFELSE([LT_PROG_GCJ], 42860b0ce0bfSmrg [LT_LANG(GCJ)], 42870b0ce0bfSmrg [m4_ifdef([AC_PROG_GCJ], 42880b0ce0bfSmrg [m4_define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[LT_LANG(GCJ)])]) 42890b0ce0bfSmrg m4_ifdef([A][M_PROG_GCJ], 42900b0ce0bfSmrg [m4_define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[LT_LANG(GCJ)])]) 42910b0ce0bfSmrg m4_ifdef([LT_PROG_GCJ], 42920b0ce0bfSmrg [m4_define([LT_PROG_GCJ], defn([LT_PROG_GCJ])[LT_LANG(GCJ)])])])])]) 429332b578d3Smrg 42940b0ce0bfSmrgAC_PROVIDE_IFELSE([AC_PROG_GO], 42950b0ce0bfSmrg [LT_LANG(GO)], 42960b0ce0bfSmrg [m4_define([AC_PROG_GO], defn([AC_PROG_GO])[LT_LANG(GO)])]) 429732b578d3Smrg 42980b0ce0bfSmrgAC_PROVIDE_IFELSE([LT_PROG_RC], 42990b0ce0bfSmrg [LT_LANG(RC)], 43000b0ce0bfSmrg [m4_define([LT_PROG_RC], defn([LT_PROG_RC])[LT_LANG(RC)])]) 43010b0ce0bfSmrg])# _LT_LANG_DEFAULT_CONFIG 430232b578d3Smrg 43030b0ce0bfSmrg# Obsolete macros: 43040b0ce0bfSmrgAU_DEFUN([AC_LIBTOOL_CXX], [LT_LANG(C++)]) 43050b0ce0bfSmrgAU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)]) 43060b0ce0bfSmrgAU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)]) 43070b0ce0bfSmrgAU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)]) 43080b0ce0bfSmrgAU_DEFUN([AC_LIBTOOL_RC], [LT_LANG(Windows Resource)]) 43090b0ce0bfSmrgdnl aclocal-1.4 backwards compatibility: 43100b0ce0bfSmrgdnl AC_DEFUN([AC_LIBTOOL_CXX], []) 43110b0ce0bfSmrgdnl AC_DEFUN([AC_LIBTOOL_F77], []) 43120b0ce0bfSmrgdnl AC_DEFUN([AC_LIBTOOL_FC], []) 43130b0ce0bfSmrgdnl AC_DEFUN([AC_LIBTOOL_GCJ], []) 43140b0ce0bfSmrgdnl AC_DEFUN([AC_LIBTOOL_RC], []) 431532b578d3Smrg 431632b578d3Smrg 43170b0ce0bfSmrg# _LT_TAG_COMPILER 43180b0ce0bfSmrg# ---------------- 43190b0ce0bfSmrgm4_defun([_LT_TAG_COMPILER], 43200b0ce0bfSmrg[AC_REQUIRE([AC_PROG_CC])dnl 432132b578d3Smrg 43220b0ce0bfSmrg_LT_DECL([LTCC], [CC], [1], [A C compiler])dnl 43230b0ce0bfSmrg_LT_DECL([LTCFLAGS], [CFLAGS], [1], [LTCC compiler flags])dnl 43240b0ce0bfSmrg_LT_TAGDECL([CC], [compiler], [1], [A language specific compiler])dnl 43250b0ce0bfSmrg_LT_TAGDECL([with_gcc], [GCC], [0], [Is the compiler the GNU compiler?])dnl 432632b578d3Smrg 43270b0ce0bfSmrg# If no C compiler was specified, use CC. 43280b0ce0bfSmrgLTCC=${LTCC-"$CC"} 432932b578d3Smrg 43300b0ce0bfSmrg# If no C compiler flags were specified, use CFLAGS. 43310b0ce0bfSmrgLTCFLAGS=${LTCFLAGS-"$CFLAGS"} 433232b578d3Smrg 43330b0ce0bfSmrg# Allow CC to be a program name with arguments. 43340b0ce0bfSmrgcompiler=$CC 43350b0ce0bfSmrg])# _LT_TAG_COMPILER 433632b578d3Smrg 433732b578d3Smrg 43380b0ce0bfSmrg# _LT_COMPILER_BOILERPLATE 43390b0ce0bfSmrg# ------------------------ 43400b0ce0bfSmrg# Check for compiler boilerplate output or warnings with 43410b0ce0bfSmrg# the simple compiler test code. 43420b0ce0bfSmrgm4_defun([_LT_COMPILER_BOILERPLATE], 43430b0ce0bfSmrg[m4_require([_LT_DECL_SED])dnl 43440b0ce0bfSmrgac_outfile=conftest.$ac_objext 43450b0ce0bfSmrgecho "$lt_simple_compile_test_code" >conftest.$ac_ext 43460b0ce0bfSmrgeval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err 43470b0ce0bfSmrg_lt_compiler_boilerplate=`cat conftest.err` 43480b0ce0bfSmrg$RM conftest* 43490b0ce0bfSmrg])# _LT_COMPILER_BOILERPLATE 43502a51b5beSmrg 43511b12faf6Smrg 43520b0ce0bfSmrg# _LT_LINKER_BOILERPLATE 43530b0ce0bfSmrg# ---------------------- 43540b0ce0bfSmrg# Check for linker boilerplate output or warnings with 43550b0ce0bfSmrg# the simple link test code. 43560b0ce0bfSmrgm4_defun([_LT_LINKER_BOILERPLATE], 43570b0ce0bfSmrg[m4_require([_LT_DECL_SED])dnl 43580b0ce0bfSmrgac_outfile=conftest.$ac_objext 43590b0ce0bfSmrgecho "$lt_simple_link_test_code" >conftest.$ac_ext 43600b0ce0bfSmrgeval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err 43610b0ce0bfSmrg_lt_linker_boilerplate=`cat conftest.err` 43620b0ce0bfSmrg$RM -r conftest* 43630b0ce0bfSmrg])# _LT_LINKER_BOILERPLATE 43642a51b5beSmrg 43650b0ce0bfSmrg# _LT_REQUIRED_DARWIN_CHECKS 43660b0ce0bfSmrg# ------------------------- 43670b0ce0bfSmrgm4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[ 43680b0ce0bfSmrg case $host_os in 43690b0ce0bfSmrg rhapsody* | darwin*) 43700b0ce0bfSmrg AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:]) 43710b0ce0bfSmrg AC_CHECK_TOOL([NMEDIT], [nmedit], [:]) 43720b0ce0bfSmrg AC_CHECK_TOOL([LIPO], [lipo], [:]) 43730b0ce0bfSmrg AC_CHECK_TOOL([OTOOL], [otool], [:]) 43740b0ce0bfSmrg AC_CHECK_TOOL([OTOOL64], [otool64], [:]) 43750b0ce0bfSmrg _LT_DECL([], [DSYMUTIL], [1], 43760b0ce0bfSmrg [Tool to manipulate archived DWARF debug symbol files on Mac OS X]) 43770b0ce0bfSmrg _LT_DECL([], [NMEDIT], [1], 43780b0ce0bfSmrg [Tool to change global to local symbols on Mac OS X]) 43790b0ce0bfSmrg _LT_DECL([], [LIPO], [1], 43800b0ce0bfSmrg [Tool to manipulate fat objects and archives on Mac OS X]) 43810b0ce0bfSmrg _LT_DECL([], [OTOOL], [1], 43820b0ce0bfSmrg [ldd/readelf like tool for Mach-O binaries on Mac OS X]) 43830b0ce0bfSmrg _LT_DECL([], [OTOOL64], [1], 43840b0ce0bfSmrg [ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4]) 43852a51b5beSmrg 43860b0ce0bfSmrg AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod], 43870b0ce0bfSmrg [lt_cv_apple_cc_single_mod=no 43880b0ce0bfSmrg if test -z "$LT_MULTI_MODULE"; then 43890b0ce0bfSmrg # By default we will add the -single_module flag. You can override 43900b0ce0bfSmrg # by either setting the environment variable LT_MULTI_MODULE 43910b0ce0bfSmrg # non-empty at configure time, or by adding -multi_module to the 43920b0ce0bfSmrg # link flags. 43930b0ce0bfSmrg rm -rf libconftest.dylib* 43940b0ce0bfSmrg echo "int foo(void){return 1;}" > conftest.c 43950b0ce0bfSmrg echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ 43960b0ce0bfSmrg-dynamiclib -Wl,-single_module conftest.c" >&AS_MESSAGE_LOG_FD 43970b0ce0bfSmrg $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ 43980b0ce0bfSmrg -dynamiclib -Wl,-single_module conftest.c 2>conftest.err 43990b0ce0bfSmrg _lt_result=$? 44000b0ce0bfSmrg # If there is a non-empty error log, and "single_module" 44010b0ce0bfSmrg # appears in it, assume the flag caused a linker warning 44020b0ce0bfSmrg if test -s conftest.err && $GREP single_module conftest.err; then 44030b0ce0bfSmrg cat conftest.err >&AS_MESSAGE_LOG_FD 44040b0ce0bfSmrg # Otherwise, if the output was created with a 0 exit code from 44050b0ce0bfSmrg # the compiler, it worked. 44060b0ce0bfSmrg elif test -f libconftest.dylib && test 0 = "$_lt_result"; then 44070b0ce0bfSmrg lt_cv_apple_cc_single_mod=yes 44081b12faf6Smrg else 44090b0ce0bfSmrg cat conftest.err >&AS_MESSAGE_LOG_FD 44101b12faf6Smrg fi 44110b0ce0bfSmrg rm -rf libconftest.dylib* 44120b0ce0bfSmrg rm -f conftest.* 44130b0ce0bfSmrg fi]) 4414d31dbc53Smrg 44150b0ce0bfSmrg AC_CACHE_CHECK([for -exported_symbols_list linker flag], 44160b0ce0bfSmrg [lt_cv_ld_exported_symbols_list], 44170b0ce0bfSmrg [lt_cv_ld_exported_symbols_list=no 44180b0ce0bfSmrg save_LDFLAGS=$LDFLAGS 44190b0ce0bfSmrg echo "_main" > conftest.sym 44200b0ce0bfSmrg LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" 44210b0ce0bfSmrg AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], 44220b0ce0bfSmrg [lt_cv_ld_exported_symbols_list=yes], 44230b0ce0bfSmrg [lt_cv_ld_exported_symbols_list=no]) 44240b0ce0bfSmrg LDFLAGS=$save_LDFLAGS 44250b0ce0bfSmrg ]) 44260b0ce0bfSmrg 44270b0ce0bfSmrg AC_CACHE_CHECK([for -force_load linker flag],[lt_cv_ld_force_load], 44280b0ce0bfSmrg [lt_cv_ld_force_load=no 44290b0ce0bfSmrg cat > conftest.c << _LT_EOF 44300b0ce0bfSmrgint forced_loaded() { return 2;} 44310b0ce0bfSmrg_LT_EOF 44320b0ce0bfSmrg echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&AS_MESSAGE_LOG_FD 44330b0ce0bfSmrg $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD 44340b0ce0bfSmrg echo "$AR $AR_FLAGS libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD 44350b0ce0bfSmrg $AR $AR_FLAGS libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD 44360b0ce0bfSmrg echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD 44370b0ce0bfSmrg $RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD 44380b0ce0bfSmrg cat > conftest.c << _LT_EOF 44390b0ce0bfSmrgint main() { return 0;} 44400b0ce0bfSmrg_LT_EOF 44410b0ce0bfSmrg echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&AS_MESSAGE_LOG_FD 44420b0ce0bfSmrg $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err 44430b0ce0bfSmrg _lt_result=$? 44440b0ce0bfSmrg if test -s conftest.err && $GREP force_load conftest.err; then 44450b0ce0bfSmrg cat conftest.err >&AS_MESSAGE_LOG_FD 44460b0ce0bfSmrg elif test -f conftest && test 0 = "$_lt_result" && $GREP forced_load conftest >/dev/null 2>&1; then 44470b0ce0bfSmrg lt_cv_ld_force_load=yes 44480b0ce0bfSmrg else 44490b0ce0bfSmrg cat conftest.err >&AS_MESSAGE_LOG_FD 44500b0ce0bfSmrg fi 44510b0ce0bfSmrg rm -f conftest.err libconftest.a conftest conftest.c 44520b0ce0bfSmrg rm -rf conftest.dSYM 44530b0ce0bfSmrg ]) 44540b0ce0bfSmrg case $host_os in 44550b0ce0bfSmrg rhapsody* | darwin1.[[012]]) 44560b0ce0bfSmrg _lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;; 44570b0ce0bfSmrg darwin1.*) 44580b0ce0bfSmrg _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; 44590b0ce0bfSmrg darwin*) 44600b0ce0bfSmrg case $MACOSX_DEPLOYMENT_TARGET,$host in 44610b0ce0bfSmrg 10.[[012]],*|,*powerpc*-darwin[[5-8]]*) 44620b0ce0bfSmrg _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; 44630b0ce0bfSmrg *) 44640b0ce0bfSmrg _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; 44651b12faf6Smrg esac 44660b0ce0bfSmrg ;; 44670b0ce0bfSmrg esac 44680b0ce0bfSmrg if test yes = "$lt_cv_apple_cc_single_mod"; then 44690b0ce0bfSmrg _lt_dar_single_mod='$single_module' 44700b0ce0bfSmrg fi 44710b0ce0bfSmrg if test yes = "$lt_cv_ld_exported_symbols_list"; then 44720b0ce0bfSmrg _lt_dar_export_syms=' $wl-exported_symbols_list,$output_objdir/$libname-symbols.expsym' 44730b0ce0bfSmrg else 44740b0ce0bfSmrg _lt_dar_export_syms='~$NMEDIT -s $output_objdir/$libname-symbols.expsym $lib' 44750b0ce0bfSmrg fi 44760b0ce0bfSmrg if test : != "$DSYMUTIL" && test no = "$lt_cv_ld_force_load"; then 44770b0ce0bfSmrg _lt_dsymutil='~$DSYMUTIL $lib || :' 44780b0ce0bfSmrg else 44790b0ce0bfSmrg _lt_dsymutil= 44800b0ce0bfSmrg fi 44810b0ce0bfSmrg ;; 44820b0ce0bfSmrg esac 44830b0ce0bfSmrg]) 4484d31dbc53Smrg 4485d31dbc53Smrg 44860b0ce0bfSmrg# _LT_DARWIN_LINKER_FEATURES([TAG]) 44870b0ce0bfSmrg# --------------------------------- 44880b0ce0bfSmrg# Checks for linker and compiler features on darwin 44890b0ce0bfSmrgm4_defun([_LT_DARWIN_LINKER_FEATURES], 44900b0ce0bfSmrg[ 44910b0ce0bfSmrg m4_require([_LT_REQUIRED_DARWIN_CHECKS]) 44920b0ce0bfSmrg _LT_TAGVAR(archive_cmds_need_lc, $1)=no 44930b0ce0bfSmrg _LT_TAGVAR(hardcode_direct, $1)=no 44940b0ce0bfSmrg _LT_TAGVAR(hardcode_automatic, $1)=yes 44950b0ce0bfSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported 44960b0ce0bfSmrg if test yes = "$lt_cv_ld_force_load"; then 44970b0ce0bfSmrg _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\"`' 44980b0ce0bfSmrg m4_case([$1], [F77], [_LT_TAGVAR(compiler_needs_object, $1)=yes], 44990b0ce0bfSmrg [FC], [_LT_TAGVAR(compiler_needs_object, $1)=yes]) 45000b0ce0bfSmrg else 45010b0ce0bfSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)='' 45020b0ce0bfSmrg fi 45030b0ce0bfSmrg _LT_TAGVAR(link_all_deplibs, $1)=yes 45040b0ce0bfSmrg _LT_TAGVAR(allow_undefined_flag, $1)=$_lt_dar_allow_undefined 45050b0ce0bfSmrg case $cc_basename in 45060b0ce0bfSmrg ifort*|nagfor*) _lt_dar_can_shared=yes ;; 45070b0ce0bfSmrg *) _lt_dar_can_shared=$GCC ;; 45080b0ce0bfSmrg esac 45090b0ce0bfSmrg if test yes = "$_lt_dar_can_shared"; then 45100b0ce0bfSmrg output_verbose_link_cmd=func_echo_all 45110b0ce0bfSmrg _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" 45120b0ce0bfSmrg _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil" 45130b0ce0bfSmrg _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" 45140b0ce0bfSmrg _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" 45150b0ce0bfSmrg m4_if([$1], [CXX], 45160b0ce0bfSmrg[ if test yes != "$lt_cv_apple_cc_single_mod"; then 45170b0ce0bfSmrg _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" 45180b0ce0bfSmrg _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" 45190b0ce0bfSmrg fi 45200b0ce0bfSmrg],[]) 45210b0ce0bfSmrg else 45220b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=no 45230b0ce0bfSmrg fi 45240b0ce0bfSmrg]) 4525d31dbc53Smrg 45260b0ce0bfSmrg# _LT_SYS_MODULE_PATH_AIX([TAGNAME]) 45270b0ce0bfSmrg# ---------------------------------- 45280b0ce0bfSmrg# Links a minimal program and checks the executable 45290b0ce0bfSmrg# for the system default hardcoded library path. In most cases, 45300b0ce0bfSmrg# this is /usr/lib:/lib, but when the MPI compilers are used 45310b0ce0bfSmrg# the location of the communication and MPI libs are included too. 45320b0ce0bfSmrg# If we don't find anything, use the default library path according 45330b0ce0bfSmrg# to the aix ld manual. 45340b0ce0bfSmrg# Store the results from the different compilers for each TAGNAME. 45350b0ce0bfSmrg# Allow to override them for all tags through lt_cv_aix_libpath. 45360b0ce0bfSmrgm4_defun([_LT_SYS_MODULE_PATH_AIX], 45370b0ce0bfSmrg[m4_require([_LT_DECL_SED])dnl 45380b0ce0bfSmrgif test set = "${lt_cv_aix_libpath+set}"; then 45390b0ce0bfSmrg aix_libpath=$lt_cv_aix_libpath 45400b0ce0bfSmrgelse 45410b0ce0bfSmrg AC_CACHE_VAL([_LT_TAGVAR([lt_cv_aix_libpath_], [$1])], 45420b0ce0bfSmrg [AC_LINK_IFELSE([AC_LANG_PROGRAM],[ 45430b0ce0bfSmrg lt_aix_libpath_sed='[ 45440b0ce0bfSmrg /Import File Strings/,/^$/ { 45450b0ce0bfSmrg /^0/ { 45460b0ce0bfSmrg s/^0 *\([^ ]*\) *$/\1/ 45470b0ce0bfSmrg p 45480b0ce0bfSmrg } 45490b0ce0bfSmrg }]' 45500b0ce0bfSmrg _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` 45510b0ce0bfSmrg # Check for a 64-bit object if we didn't find anything. 45520b0ce0bfSmrg if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then 45530b0ce0bfSmrg _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` 45540b0ce0bfSmrg fi],[]) 45550b0ce0bfSmrg if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then 45560b0ce0bfSmrg _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=/usr/lib:/lib 45570b0ce0bfSmrg fi 45580b0ce0bfSmrg ]) 45590b0ce0bfSmrg aix_libpath=$_LT_TAGVAR([lt_cv_aix_libpath_], [$1]) 45600b0ce0bfSmrgfi 45610b0ce0bfSmrg])# _LT_SYS_MODULE_PATH_AIX 4562d31dbc53Smrg 4563d31dbc53Smrg 45640b0ce0bfSmrg# _LT_SHELL_INIT(ARG) 45650b0ce0bfSmrg# ------------------- 45660b0ce0bfSmrgm4_define([_LT_SHELL_INIT], 45670b0ce0bfSmrg[m4_divert_text([M4SH-INIT], [$1 45680b0ce0bfSmrg])])# _LT_SHELL_INIT 4569d31dbc53Smrg 4570d31dbc53Smrg 4571d31dbc53Smrg 45720b0ce0bfSmrg# _LT_PROG_ECHO_BACKSLASH 45730b0ce0bfSmrg# ----------------------- 45740b0ce0bfSmrg# Find how we can fake an echo command that does not interpret backslash. 45750b0ce0bfSmrg# In particular, with Autoconf 2.60 or later we add some code to the start 45760b0ce0bfSmrg# of the generated configure script that will find a shell with a builtin 45770b0ce0bfSmrg# printf (that we can use as an echo command). 45780b0ce0bfSmrgm4_defun([_LT_PROG_ECHO_BACKSLASH], 45790b0ce0bfSmrg[ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' 45800b0ce0bfSmrgECHO=$ECHO$ECHO$ECHO$ECHO$ECHO 45810b0ce0bfSmrgECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO 4582d31dbc53Smrg 45830b0ce0bfSmrgAC_MSG_CHECKING([how to print strings]) 45840b0ce0bfSmrg# Test print first, because it will be a builtin if present. 45850b0ce0bfSmrgif test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \ 45860b0ce0bfSmrg test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then 45870b0ce0bfSmrg ECHO='print -r --' 45880b0ce0bfSmrgelif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then 45890b0ce0bfSmrg ECHO='printf %s\n' 45900b0ce0bfSmrgelse 45910b0ce0bfSmrg # Use this function as a fallback that always works. 45920b0ce0bfSmrg func_fallback_echo () 45930b0ce0bfSmrg { 45940b0ce0bfSmrg eval 'cat <<_LTECHO_EOF 45950b0ce0bfSmrg$[]1 45960b0ce0bfSmrg_LTECHO_EOF' 45970b0ce0bfSmrg } 45980b0ce0bfSmrg ECHO='func_fallback_echo' 45990b0ce0bfSmrgfi 460032b578d3Smrg 46010b0ce0bfSmrg# func_echo_all arg... 46020b0ce0bfSmrg# Invoke $ECHO with all args, space-separated. 46030b0ce0bfSmrgfunc_echo_all () 46040b0ce0bfSmrg{ 46050b0ce0bfSmrg $ECHO "$*" 46060b0ce0bfSmrg} 460732b578d3Smrg 46080b0ce0bfSmrgcase $ECHO in 46090b0ce0bfSmrg printf*) AC_MSG_RESULT([printf]) ;; 46100b0ce0bfSmrg print*) AC_MSG_RESULT([print -r]) ;; 46110b0ce0bfSmrg *) AC_MSG_RESULT([cat]) ;; 46120b0ce0bfSmrgesac 4613d31dbc53Smrg 46140b0ce0bfSmrgm4_ifdef([_AS_DETECT_SUGGESTED], 46150b0ce0bfSmrg[_AS_DETECT_SUGGESTED([ 46160b0ce0bfSmrg test -n "${ZSH_VERSION+set}${BASH_VERSION+set}" || ( 46170b0ce0bfSmrg ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' 46180b0ce0bfSmrg ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO 46190b0ce0bfSmrg ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO 46200b0ce0bfSmrg PATH=/empty FPATH=/empty; export PATH FPATH 46210b0ce0bfSmrg test "X`printf %s $ECHO`" = "X$ECHO" \ 46220b0ce0bfSmrg || test "X`print -r -- $ECHO`" = "X$ECHO" )])]) 462332b578d3Smrg 46240b0ce0bfSmrg_LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts]) 46250b0ce0bfSmrg_LT_DECL([], [ECHO], [1], [An echo program that protects backslashes]) 46260b0ce0bfSmrg])# _LT_PROG_ECHO_BACKSLASH 462732b578d3Smrg 462832b578d3Smrg 46290b0ce0bfSmrg# _LT_WITH_SYSROOT 46300b0ce0bfSmrg# ---------------- 46310b0ce0bfSmrgAC_DEFUN([_LT_WITH_SYSROOT], 46320b0ce0bfSmrg[m4_require([_LT_DECL_SED])dnl 46330b0ce0bfSmrgAC_MSG_CHECKING([for sysroot]) 46340b0ce0bfSmrgAC_ARG_WITH([sysroot], 46350b0ce0bfSmrg[AS_HELP_STRING([--with-sysroot@<:@=DIR@:>@], 46360b0ce0bfSmrg [Search for dependent libraries within DIR (or the compiler's sysroot 46370b0ce0bfSmrg if not specified).])], 46380b0ce0bfSmrg[], [with_sysroot=no]) 463932b578d3Smrg 46400b0ce0bfSmrgdnl lt_sysroot will always be passed unquoted. We quote it here 46410b0ce0bfSmrgdnl in case the user passed a directory name. 46420b0ce0bfSmrglt_sysroot= 46430b0ce0bfSmrgcase $with_sysroot in #( 46440b0ce0bfSmrg yes) 46450b0ce0bfSmrg if test yes = "$GCC"; then 46460b0ce0bfSmrg lt_sysroot=`$CC --print-sysroot 2>/dev/null` 46470b0ce0bfSmrg fi 46480b0ce0bfSmrg ;; #( 46490b0ce0bfSmrg /*) 46500b0ce0bfSmrg lt_sysroot=`echo "$with_sysroot" | $SED -e "$sed_quote_subst"` 46510b0ce0bfSmrg ;; #( 46520b0ce0bfSmrg no|'') 46530b0ce0bfSmrg ;; #( 46540b0ce0bfSmrg *) 46550b0ce0bfSmrg AC_MSG_RESULT([$with_sysroot]) 46560b0ce0bfSmrg AC_MSG_ERROR([The sysroot must be an absolute path.]) 46570b0ce0bfSmrg ;; 46580b0ce0bfSmrgesac 465932b578d3Smrg 46600b0ce0bfSmrg AC_MSG_RESULT([${lt_sysroot:-no}]) 46610b0ce0bfSmrg_LT_DECL([], [lt_sysroot], [0], [The root where to search for ]dnl 46620b0ce0bfSmrg[dependent libraries, and where our libraries should be installed.])]) 466332b578d3Smrg 46640b0ce0bfSmrg# _LT_ENABLE_LOCK 46650b0ce0bfSmrg# --------------- 46660b0ce0bfSmrgm4_defun([_LT_ENABLE_LOCK], 46670b0ce0bfSmrg[AC_ARG_ENABLE([libtool-lock], 46680b0ce0bfSmrg [AS_HELP_STRING([--disable-libtool-lock], 46690b0ce0bfSmrg [avoid locking (might break parallel builds)])]) 46700b0ce0bfSmrgtest no = "$enable_libtool_lock" || enable_libtool_lock=yes 467132b578d3Smrg 46720b0ce0bfSmrg# Some flags need to be propagated to the compiler or linker for good 46730b0ce0bfSmrg# libtool support. 46740b0ce0bfSmrgcase $host in 46750b0ce0bfSmrgia64-*-hpux*) 46760b0ce0bfSmrg # Find out what ABI is being produced by ac_compile, and set mode 46770b0ce0bfSmrg # options accordingly. 46780b0ce0bfSmrg echo 'int i;' > conftest.$ac_ext 46790b0ce0bfSmrg if AC_TRY_EVAL(ac_compile); then 46800b0ce0bfSmrg case `$FILECMD conftest.$ac_objext` in 46810b0ce0bfSmrg *ELF-32*) 46820b0ce0bfSmrg HPUX_IA64_MODE=32 46830b0ce0bfSmrg ;; 46840b0ce0bfSmrg *ELF-64*) 46850b0ce0bfSmrg HPUX_IA64_MODE=64 46860b0ce0bfSmrg ;; 46870b0ce0bfSmrg esac 46880b0ce0bfSmrg fi 46890b0ce0bfSmrg rm -rf conftest* 46900b0ce0bfSmrg ;; 46910b0ce0bfSmrg*-*-irix6*) 46920b0ce0bfSmrg # Find out what ABI is being produced by ac_compile, and set linker 46930b0ce0bfSmrg # options accordingly. 46940b0ce0bfSmrg echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext 46950b0ce0bfSmrg if AC_TRY_EVAL(ac_compile); then 46960b0ce0bfSmrg if test yes = "$lt_cv_prog_gnu_ld"; then 46970b0ce0bfSmrg case `$FILECMD conftest.$ac_objext` in 46980b0ce0bfSmrg *32-bit*) 46990b0ce0bfSmrg LD="${LD-ld} -melf32bsmip" 47001b12faf6Smrg ;; 47010b0ce0bfSmrg *N32*) 47020b0ce0bfSmrg LD="${LD-ld} -melf32bmipn32" 47031b12faf6Smrg ;; 47040b0ce0bfSmrg *64-bit*) 47050b0ce0bfSmrg LD="${LD-ld} -melf64bmip" 47061b12faf6Smrg ;; 47071b12faf6Smrg esac 47080b0ce0bfSmrg else 47090b0ce0bfSmrg case `$FILECMD conftest.$ac_objext` in 47100b0ce0bfSmrg *32-bit*) 47110b0ce0bfSmrg LD="${LD-ld} -32" 47120b0ce0bfSmrg ;; 47130b0ce0bfSmrg *N32*) 47140b0ce0bfSmrg LD="${LD-ld} -n32" 47150b0ce0bfSmrg ;; 47160b0ce0bfSmrg *64-bit*) 47170b0ce0bfSmrg LD="${LD-ld} -64" 47180b0ce0bfSmrg ;; 47190b0ce0bfSmrg esac 47200b0ce0bfSmrg fi 47210b0ce0bfSmrg fi 47220b0ce0bfSmrg rm -rf conftest* 47230b0ce0bfSmrg ;; 472432b578d3Smrg 47250b0ce0bfSmrgmips64*-*linux*) 47260b0ce0bfSmrg # Find out what ABI is being produced by ac_compile, and set linker 47270b0ce0bfSmrg # options accordingly. 47280b0ce0bfSmrg echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext 47290b0ce0bfSmrg if AC_TRY_EVAL(ac_compile); then 47300b0ce0bfSmrg emul=elf 47310b0ce0bfSmrg case `$FILECMD conftest.$ac_objext` in 47320b0ce0bfSmrg *32-bit*) 47330b0ce0bfSmrg emul="${emul}32" 47341b12faf6Smrg ;; 47350b0ce0bfSmrg *64-bit*) 47360b0ce0bfSmrg emul="${emul}64" 47370b0ce0bfSmrg ;; 47380b0ce0bfSmrg esac 47390b0ce0bfSmrg case `$FILECMD conftest.$ac_objext` in 47400b0ce0bfSmrg *MSB*) 47410b0ce0bfSmrg emul="${emul}btsmip" 47420b0ce0bfSmrg ;; 47430b0ce0bfSmrg *LSB*) 47440b0ce0bfSmrg emul="${emul}ltsmip" 47450b0ce0bfSmrg ;; 47460b0ce0bfSmrg esac 47470b0ce0bfSmrg case `$FILECMD conftest.$ac_objext` in 47480b0ce0bfSmrg *N32*) 47490b0ce0bfSmrg emul="${emul}n32" 47500b0ce0bfSmrg ;; 47510b0ce0bfSmrg esac 47520b0ce0bfSmrg LD="${LD-ld} -m $emul" 47530b0ce0bfSmrg fi 47540b0ce0bfSmrg rm -rf conftest* 47550b0ce0bfSmrg ;; 47560b0ce0bfSmrg 47570b0ce0bfSmrgx86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \ 47580b0ce0bfSmrgs390*-*linux*|s390*-*tpf*|sparc*-*linux*) 47590b0ce0bfSmrg # Find out what ABI is being produced by ac_compile, and set linker 47600b0ce0bfSmrg # options accordingly. Note that the listed cases only cover the 47610b0ce0bfSmrg # situations where additional linker options are needed (such as when 47620b0ce0bfSmrg # doing 32-bit compilation for a host where ld defaults to 64-bit, or 47630b0ce0bfSmrg # vice versa); the common cases where no linker options are needed do 47640b0ce0bfSmrg # not appear in the list. 47650b0ce0bfSmrg echo 'int i;' > conftest.$ac_ext 47660b0ce0bfSmrg if AC_TRY_EVAL(ac_compile); then 47670b0ce0bfSmrg case `$FILECMD conftest.o` in 47680b0ce0bfSmrg *32-bit*) 47690b0ce0bfSmrg case $host in 47700b0ce0bfSmrg x86_64-*kfreebsd*-gnu) 47710b0ce0bfSmrg LD="${LD-ld} -m elf_i386_fbsd" 47720b0ce0bfSmrg ;; 47730b0ce0bfSmrg x86_64-*linux*) 47740b0ce0bfSmrg case `$FILECMD conftest.o` in 47750b0ce0bfSmrg *x86-64*) 47760b0ce0bfSmrg LD="${LD-ld} -m elf32_x86_64" 47770b0ce0bfSmrg ;; 47780b0ce0bfSmrg *) 47790b0ce0bfSmrg LD="${LD-ld} -m elf_i386" 47800b0ce0bfSmrg ;; 47810b0ce0bfSmrg esac 47820b0ce0bfSmrg ;; 47830b0ce0bfSmrg powerpc64le-*linux*) 47840b0ce0bfSmrg LD="${LD-ld} -m elf32lppclinux" 47850b0ce0bfSmrg ;; 47860b0ce0bfSmrg powerpc64-*linux*) 47870b0ce0bfSmrg LD="${LD-ld} -m elf32ppclinux" 47880b0ce0bfSmrg ;; 47890b0ce0bfSmrg s390x-*linux*) 47900b0ce0bfSmrg LD="${LD-ld} -m elf_s390" 47910b0ce0bfSmrg ;; 47920b0ce0bfSmrg sparc64-*linux*) 47930b0ce0bfSmrg LD="${LD-ld} -m elf32_sparc" 47940b0ce0bfSmrg ;; 47950b0ce0bfSmrg esac 47960b0ce0bfSmrg ;; 47970b0ce0bfSmrg *64-bit*) 47980b0ce0bfSmrg case $host in 47990b0ce0bfSmrg x86_64-*kfreebsd*-gnu) 48000b0ce0bfSmrg LD="${LD-ld} -m elf_x86_64_fbsd" 48010b0ce0bfSmrg ;; 48020b0ce0bfSmrg x86_64-*linux*) 48030b0ce0bfSmrg LD="${LD-ld} -m elf_x86_64" 48040b0ce0bfSmrg ;; 48050b0ce0bfSmrg powerpcle-*linux*) 48060b0ce0bfSmrg LD="${LD-ld} -m elf64lppc" 48070b0ce0bfSmrg ;; 48080b0ce0bfSmrg powerpc-*linux*) 48090b0ce0bfSmrg LD="${LD-ld} -m elf64ppc" 48100b0ce0bfSmrg ;; 48110b0ce0bfSmrg s390*-*linux*|s390*-*tpf*) 48120b0ce0bfSmrg LD="${LD-ld} -m elf64_s390" 48130b0ce0bfSmrg ;; 48140b0ce0bfSmrg sparc*-*linux*) 48150b0ce0bfSmrg LD="${LD-ld} -m elf64_sparc" 48160b0ce0bfSmrg ;; 48170b0ce0bfSmrg esac 48180b0ce0bfSmrg ;; 48190b0ce0bfSmrg esac 48200b0ce0bfSmrg fi 48210b0ce0bfSmrg rm -rf conftest* 48220b0ce0bfSmrg ;; 48230b0ce0bfSmrg 48240b0ce0bfSmrg*-*-sco3.2v5*) 48250b0ce0bfSmrg # On SCO OpenServer 5, we need -belf to get full-featured binaries. 48260b0ce0bfSmrg SAVE_CFLAGS=$CFLAGS 48270b0ce0bfSmrg CFLAGS="$CFLAGS -belf" 48280b0ce0bfSmrg AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf, 48290b0ce0bfSmrg [AC_LANG_PUSH(C) 48300b0ce0bfSmrg AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no]) 48310b0ce0bfSmrg AC_LANG_POP]) 48320b0ce0bfSmrg if test yes != "$lt_cv_cc_needs_belf"; then 48330b0ce0bfSmrg # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf 48340b0ce0bfSmrg CFLAGS=$SAVE_CFLAGS 48350b0ce0bfSmrg fi 48360b0ce0bfSmrg ;; 48370b0ce0bfSmrg*-*solaris*) 48380b0ce0bfSmrg # Find out what ABI is being produced by ac_compile, and set linker 48390b0ce0bfSmrg # options accordingly. 48400b0ce0bfSmrg echo 'int i;' > conftest.$ac_ext 48410b0ce0bfSmrg if AC_TRY_EVAL(ac_compile); then 48420b0ce0bfSmrg case `$FILECMD conftest.o` in 48430b0ce0bfSmrg *64-bit*) 48440b0ce0bfSmrg case $lt_cv_prog_gnu_ld in 48450b0ce0bfSmrg yes*) 48460b0ce0bfSmrg case $host in 48470b0ce0bfSmrg i?86-*-solaris*|x86_64-*-solaris*) 48480b0ce0bfSmrg LD="${LD-ld} -m elf_x86_64" 48490b0ce0bfSmrg ;; 48500b0ce0bfSmrg sparc*-*-solaris*) 48510b0ce0bfSmrg LD="${LD-ld} -m elf64_sparc" 48520b0ce0bfSmrg ;; 48530b0ce0bfSmrg esac 48540b0ce0bfSmrg # GNU ld 2.21 introduced _sol2 emulations. Use them if available. 48550b0ce0bfSmrg if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then 48560b0ce0bfSmrg LD=${LD-ld}_sol2 48570b0ce0bfSmrg fi 48580b0ce0bfSmrg ;; 48590b0ce0bfSmrg *) 48600b0ce0bfSmrg if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then 48610b0ce0bfSmrg LD="${LD-ld} -64" 48620b0ce0bfSmrg fi 48631b12faf6Smrg ;; 48641b12faf6Smrg esac 48651b12faf6Smrg ;; 48660b0ce0bfSmrg esac 48670b0ce0bfSmrg fi 48680b0ce0bfSmrg rm -rf conftest* 48690b0ce0bfSmrg ;; 48700b0ce0bfSmrgesac 4871d31dbc53Smrg 48720b0ce0bfSmrgneed_locks=$enable_libtool_lock 48730b0ce0bfSmrg])# _LT_ENABLE_LOCK 487432b578d3Smrg 487532b578d3Smrg 48760b0ce0bfSmrg# _LT_PROG_AR 48770b0ce0bfSmrg# ----------- 48780b0ce0bfSmrgm4_defun([_LT_PROG_AR], 48790b0ce0bfSmrg[AC_CHECK_TOOLS(AR, [ar], false) 48800b0ce0bfSmrg: ${AR=ar} 48810b0ce0bfSmrg_LT_DECL([], [AR], [1], [The archiver]) 488232b578d3Smrg 48830b0ce0bfSmrg# Use ARFLAGS variable as AR's operation code to sync the variable naming with 48840b0ce0bfSmrg# Automake. If both AR_FLAGS and ARFLAGS are specified, AR_FLAGS should have 48850b0ce0bfSmrg# higher priority because thats what people were doing historically (setting 48860b0ce0bfSmrg# ARFLAGS for automake and AR_FLAGS for libtool). FIXME: Make the AR_FLAGS 48870b0ce0bfSmrg# variable obsoleted/removed. 488832b578d3Smrg 48890b0ce0bfSmrgtest ${AR_FLAGS+y} || AR_FLAGS=${ARFLAGS-cr} 48900b0ce0bfSmrglt_ar_flags=$AR_FLAGS 48910b0ce0bfSmrg_LT_DECL([], [lt_ar_flags], [0], [Flags to create an archive (by configure)]) 489232b578d3Smrg 48930b0ce0bfSmrg# Make AR_FLAGS overridable by 'make ARFLAGS='. Don't try to run-time override 48940b0ce0bfSmrg# by AR_FLAGS because that was never working and AR_FLAGS is about to die. 48950b0ce0bfSmrg_LT_DECL([], [AR_FLAGS], [\@S|@{ARFLAGS-"\@S|@lt_ar_flags"}], 48960b0ce0bfSmrg [Flags to create an archive]) 48970b0ce0bfSmrg 48980b0ce0bfSmrgAC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file], 48990b0ce0bfSmrg [lt_cv_ar_at_file=no 49000b0ce0bfSmrg AC_COMPILE_IFELSE([AC_LANG_PROGRAM], 49010b0ce0bfSmrg [echo conftest.$ac_objext > conftest.lst 49020b0ce0bfSmrg lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&AS_MESSAGE_LOG_FD' 49030b0ce0bfSmrg AC_TRY_EVAL([lt_ar_try]) 49040b0ce0bfSmrg if test 0 -eq "$ac_status"; then 49050b0ce0bfSmrg # Ensure the archiver fails upon bogus file names. 49060b0ce0bfSmrg rm -f conftest.$ac_objext libconftest.a 49070b0ce0bfSmrg AC_TRY_EVAL([lt_ar_try]) 49080b0ce0bfSmrg if test 0 -ne "$ac_status"; then 49090b0ce0bfSmrg lt_cv_ar_at_file=@ 49100b0ce0bfSmrg fi 49111b12faf6Smrg fi 49120b0ce0bfSmrg rm -f conftest.* libconftest.a 49130b0ce0bfSmrg ]) 49140b0ce0bfSmrg ]) 491532b578d3Smrg 49160b0ce0bfSmrgif test no = "$lt_cv_ar_at_file"; then 49170b0ce0bfSmrg archiver_list_spec= 49180b0ce0bfSmrgelse 49190b0ce0bfSmrg archiver_list_spec=$lt_cv_ar_at_file 49200b0ce0bfSmrgfi 49210b0ce0bfSmrg_LT_DECL([], [archiver_list_spec], [1], 49220b0ce0bfSmrg [How to feed a file listing to the archiver]) 49230b0ce0bfSmrg])# _LT_PROG_AR 492432b578d3Smrg 492532b578d3Smrg 49260b0ce0bfSmrg# _LT_CMD_OLD_ARCHIVE 49270b0ce0bfSmrg# ------------------- 49280b0ce0bfSmrgm4_defun([_LT_CMD_OLD_ARCHIVE], 49290b0ce0bfSmrg[_LT_PROG_AR 493032b578d3Smrg 49310b0ce0bfSmrgAC_CHECK_TOOL(STRIP, strip, :) 49320b0ce0bfSmrgtest -z "$STRIP" && STRIP=: 49330b0ce0bfSmrg_LT_DECL([], [STRIP], [1], [A symbol stripping program]) 493432b578d3Smrg 49350b0ce0bfSmrgAC_CHECK_TOOL(RANLIB, ranlib, :) 49360b0ce0bfSmrgtest -z "$RANLIB" && RANLIB=: 49370b0ce0bfSmrg_LT_DECL([], [RANLIB], [1], 49380b0ce0bfSmrg [Commands used to install an old-style archive]) 4939d31dbc53Smrg 49400b0ce0bfSmrg# Determine commands to create old-style static archives. 49410b0ce0bfSmrgold_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' 49420b0ce0bfSmrgold_postinstall_cmds='chmod 644 $oldlib' 49430b0ce0bfSmrgold_postuninstall_cmds= 4944d31dbc53Smrg 49450b0ce0bfSmrgif test -n "$RANLIB"; then 49460b0ce0bfSmrg case $host_os in 49470b0ce0bfSmrg bitrig* | openbsd*) 49480b0ce0bfSmrg old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib" 49490b0ce0bfSmrg ;; 49500b0ce0bfSmrg *) 49510b0ce0bfSmrg old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib" 49520b0ce0bfSmrg ;; 49530b0ce0bfSmrg esac 49540b0ce0bfSmrg old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib" 49550b0ce0bfSmrgfi 4956e35d4d8eSmrg 49570b0ce0bfSmrgcase $host_os in 49580b0ce0bfSmrg darwin*) 49590b0ce0bfSmrg lock_old_archive_extraction=yes ;; 49600b0ce0bfSmrg *) 49610b0ce0bfSmrg lock_old_archive_extraction=no ;; 49621b12faf6Smrgesac 49630b0ce0bfSmrg_LT_DECL([], [old_postinstall_cmds], [2]) 49640b0ce0bfSmrg_LT_DECL([], [old_postuninstall_cmds], [2]) 49650b0ce0bfSmrg_LT_TAGDECL([], [old_archive_cmds], [2], 49660b0ce0bfSmrg [Commands used to build an old-style archive]) 49670b0ce0bfSmrg_LT_DECL([], [lock_old_archive_extraction], [0], 49680b0ce0bfSmrg [Whether to use a lock for old archive extraction]) 49690b0ce0bfSmrg])# _LT_CMD_OLD_ARCHIVE 49701b12faf6Smrg 49711b12faf6Smrg 49720b0ce0bfSmrg# _LT_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, 49730b0ce0bfSmrg# [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE]) 49740b0ce0bfSmrg# ---------------------------------------------------------------- 49750b0ce0bfSmrg# Check whether the given compiler option works 49760b0ce0bfSmrgAC_DEFUN([_LT_COMPILER_OPTION], 49770b0ce0bfSmrg[m4_require([_LT_FILEUTILS_DEFAULTS])dnl 49780b0ce0bfSmrgm4_require([_LT_DECL_SED])dnl 49790b0ce0bfSmrgAC_CACHE_CHECK([$1], [$2], 49800b0ce0bfSmrg [$2=no 49810b0ce0bfSmrg m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4]) 49820b0ce0bfSmrg echo "$lt_simple_compile_test_code" > conftest.$ac_ext 49830b0ce0bfSmrg lt_compiler_flag="$3" ## exclude from sc_useless_quotes_in_assignment 49840b0ce0bfSmrg # Insert the option either (1) after the last *FLAGS variable, or 49850b0ce0bfSmrg # (2) before a word containing "conftest.", or (3) at the end. 49860b0ce0bfSmrg # Note that $ac_compile itself does not contain backslashes and begins 49870b0ce0bfSmrg # with a dollar sign (not a hyphen), so the echo should work correctly. 49880b0ce0bfSmrg # The option is referenced via a variable to avoid confusing sed. 49890b0ce0bfSmrg lt_compile=`echo "$ac_compile" | $SED \ 49900b0ce0bfSmrg -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ 49910b0ce0bfSmrg -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ 49920b0ce0bfSmrg -e 's:$: $lt_compiler_flag:'` 49930b0ce0bfSmrg (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD) 49940b0ce0bfSmrg (eval "$lt_compile" 2>conftest.err) 49950b0ce0bfSmrg ac_status=$? 49960b0ce0bfSmrg cat conftest.err >&AS_MESSAGE_LOG_FD 49970b0ce0bfSmrg echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD 49980b0ce0bfSmrg if (exit $ac_status) && test -s "$ac_outfile"; then 49990b0ce0bfSmrg # The compiler can only warn and ignore the option if not recognized 50000b0ce0bfSmrg # So say no if there are warnings other than the usual output. 50010b0ce0bfSmrg $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp 50020b0ce0bfSmrg $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 50030b0ce0bfSmrg if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then 50040b0ce0bfSmrg $2=yes 50050b0ce0bfSmrg fi 50060b0ce0bfSmrg fi 50070b0ce0bfSmrg $RM conftest* 50080b0ce0bfSmrg]) 5009d31dbc53Smrg 50100b0ce0bfSmrgif test yes = "[$]$2"; then 50110b0ce0bfSmrg m4_if([$5], , :, [$5]) 50120b0ce0bfSmrgelse 50130b0ce0bfSmrg m4_if([$6], , :, [$6]) 50140b0ce0bfSmrgfi 50150b0ce0bfSmrg])# _LT_COMPILER_OPTION 5016d31dbc53Smrg 50170b0ce0bfSmrg# Old name: 50180b0ce0bfSmrgAU_ALIAS([AC_LIBTOOL_COMPILER_OPTION], [_LT_COMPILER_OPTION]) 50190b0ce0bfSmrgdnl aclocal-1.4 backwards compatibility: 50200b0ce0bfSmrgdnl AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], []) 502132b578d3Smrg 502232b578d3Smrg 50230b0ce0bfSmrg# _LT_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, 50240b0ce0bfSmrg# [ACTION-SUCCESS], [ACTION-FAILURE]) 50250b0ce0bfSmrg# ---------------------------------------------------- 50260b0ce0bfSmrg# Check whether the given linker option works 50270b0ce0bfSmrgAC_DEFUN([_LT_LINKER_OPTION], 50280b0ce0bfSmrg[m4_require([_LT_FILEUTILS_DEFAULTS])dnl 50290b0ce0bfSmrgm4_require([_LT_DECL_SED])dnl 50300b0ce0bfSmrgAC_CACHE_CHECK([$1], [$2], 50310b0ce0bfSmrg [$2=no 50320b0ce0bfSmrg save_LDFLAGS=$LDFLAGS 50330b0ce0bfSmrg LDFLAGS="$LDFLAGS $3" 50340b0ce0bfSmrg echo "$lt_simple_link_test_code" > conftest.$ac_ext 50350b0ce0bfSmrg if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then 50360b0ce0bfSmrg # The linker can only warn and ignore the option if not recognized 50370b0ce0bfSmrg # So say no if there are warnings 50380b0ce0bfSmrg if test -s conftest.err; then 50390b0ce0bfSmrg # Append any errors to the config.log. 50400b0ce0bfSmrg cat conftest.err 1>&AS_MESSAGE_LOG_FD 50410b0ce0bfSmrg $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp 50420b0ce0bfSmrg $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 50430b0ce0bfSmrg if diff conftest.exp conftest.er2 >/dev/null; then 50440b0ce0bfSmrg $2=yes 50450b0ce0bfSmrg fi 50460b0ce0bfSmrg else 50470b0ce0bfSmrg $2=yes 50480b0ce0bfSmrg fi 50490b0ce0bfSmrg fi 50500b0ce0bfSmrg $RM -r conftest* 50510b0ce0bfSmrg LDFLAGS=$save_LDFLAGS 50520b0ce0bfSmrg]) 505332b578d3Smrg 50540b0ce0bfSmrgif test yes = "[$]$2"; then 50550b0ce0bfSmrg m4_if([$4], , :, [$4]) 50560b0ce0bfSmrgelse 50570b0ce0bfSmrg m4_if([$5], , :, [$5]) 50580b0ce0bfSmrgfi 50590b0ce0bfSmrg])# _LT_LINKER_OPTION 506032b578d3Smrg 50610b0ce0bfSmrg# Old name: 50620b0ce0bfSmrgAU_ALIAS([AC_LIBTOOL_LINKER_OPTION], [_LT_LINKER_OPTION]) 50630b0ce0bfSmrgdnl aclocal-1.4 backwards compatibility: 50640b0ce0bfSmrgdnl AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], []) 506532b578d3Smrg 50661b12faf6Smrg 50670b0ce0bfSmrg# LT_CMD_MAX_LEN 50680b0ce0bfSmrg#--------------- 50690b0ce0bfSmrgAC_DEFUN([LT_CMD_MAX_LEN], 50700b0ce0bfSmrg[AC_REQUIRE([AC_CANONICAL_HOST])dnl 50710b0ce0bfSmrg# find the maximum length of command line arguments 50720b0ce0bfSmrgAC_MSG_CHECKING([the maximum length of command line arguments]) 50730b0ce0bfSmrgAC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl 50740b0ce0bfSmrg i=0 50750b0ce0bfSmrg teststring=ABCD 50761b12faf6Smrg 50770b0ce0bfSmrg case $build_os in 50780b0ce0bfSmrg msdosdjgpp*) 50790b0ce0bfSmrg # On DJGPP, this test can blow up pretty badly due to problems in libc 50800b0ce0bfSmrg # (any single argument exceeding 2000 bytes causes a buffer overrun 50810b0ce0bfSmrg # during glob expansion). Even if it were fixed, the result of this 50820b0ce0bfSmrg # check would be larger than it should be. 50830b0ce0bfSmrg lt_cv_sys_max_cmd_len=12288; # 12K is about right 50840b0ce0bfSmrg ;; 50851b12faf6Smrg 50860b0ce0bfSmrg gnu*) 50870b0ce0bfSmrg # Under GNU Hurd, this test is not required because there is 50880b0ce0bfSmrg # no limit to the length of command line arguments. 50890b0ce0bfSmrg # Libtool will interpret -1 as no limit whatsoever 50900b0ce0bfSmrg lt_cv_sys_max_cmd_len=-1; 50911b12faf6Smrg ;; 509232b578d3Smrg 50930b0ce0bfSmrg cygwin* | mingw* | cegcc*) 50940b0ce0bfSmrg # On Win9x/ME, this test blows up -- it succeeds, but takes 50950b0ce0bfSmrg # about 5 minutes as the teststring grows exponentially. 50960b0ce0bfSmrg # Worse, since 9x/ME are not pre-emptively multitasking, 50970b0ce0bfSmrg # you end up with a "frozen" computer, even though with patience 50980b0ce0bfSmrg # the test eventually succeeds (with a max line length of 256k). 50990b0ce0bfSmrg # Instead, let's just punt: use the minimum linelength reported by 51000b0ce0bfSmrg # all of the supported platforms: 8192 (on NT/2K/XP). 51010b0ce0bfSmrg lt_cv_sys_max_cmd_len=8192; 51021b12faf6Smrg ;; 510332b578d3Smrg 51040b0ce0bfSmrg mint*) 51050b0ce0bfSmrg # On MiNT this can take a long time and run out of memory. 51060b0ce0bfSmrg lt_cv_sys_max_cmd_len=8192; 51070b0ce0bfSmrg ;; 510832b578d3Smrg 51090b0ce0bfSmrg amigaos*) 51100b0ce0bfSmrg # On AmigaOS with pdksh, this test takes hours, literally. 51110b0ce0bfSmrg # So we just punt and use a minimum line length of 8192. 51120b0ce0bfSmrg lt_cv_sys_max_cmd_len=8192; 51130b0ce0bfSmrg ;; 511432b578d3Smrg 51150b0ce0bfSmrg bitrig* | darwin* | dragonfly* | freebsd* | midnightbsd* | netbsd* | openbsd*) 51160b0ce0bfSmrg # This has been around since 386BSD, at least. Likely further. 51170b0ce0bfSmrg if test -x /sbin/sysctl; then 51180b0ce0bfSmrg lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` 51190b0ce0bfSmrg elif test -x /usr/sbin/sysctl; then 51200b0ce0bfSmrg lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` 51210b0ce0bfSmrg else 51220b0ce0bfSmrg lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs 51230b0ce0bfSmrg fi 51240b0ce0bfSmrg # And add a safety zone 51250b0ce0bfSmrg lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` 51260b0ce0bfSmrg lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` 51270b0ce0bfSmrg ;; 512832b578d3Smrg 51290b0ce0bfSmrg interix*) 51300b0ce0bfSmrg # We know the value 262144 and hardcode it with a safety zone (like BSD) 51310b0ce0bfSmrg lt_cv_sys_max_cmd_len=196608 51320b0ce0bfSmrg ;; 51330b0ce0bfSmrg 51340b0ce0bfSmrg os2*) 51350b0ce0bfSmrg # The test takes a long time on OS/2. 51360b0ce0bfSmrg lt_cv_sys_max_cmd_len=8192 51370b0ce0bfSmrg ;; 51380b0ce0bfSmrg 51390b0ce0bfSmrg osf*) 51400b0ce0bfSmrg # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure 51410b0ce0bfSmrg # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not 51420b0ce0bfSmrg # nice to cause kernel panics so lets avoid the loop below. 51430b0ce0bfSmrg # First set a reasonable default. 51440b0ce0bfSmrg lt_cv_sys_max_cmd_len=16384 51450b0ce0bfSmrg # 51460b0ce0bfSmrg if test -x /sbin/sysconfig; then 51470b0ce0bfSmrg case `/sbin/sysconfig -q proc exec_disable_arg_limit` in 51480b0ce0bfSmrg *1*) lt_cv_sys_max_cmd_len=-1 ;; 51490b0ce0bfSmrg esac 51500b0ce0bfSmrg fi 51510b0ce0bfSmrg ;; 51520b0ce0bfSmrg sco3.2v5*) 51530b0ce0bfSmrg lt_cv_sys_max_cmd_len=102400 51540b0ce0bfSmrg ;; 51550b0ce0bfSmrg sysv5* | sco5v6* | sysv4.2uw2*) 51560b0ce0bfSmrg kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` 51570b0ce0bfSmrg if test -n "$kargmax"; then 51580b0ce0bfSmrg lt_cv_sys_max_cmd_len=`echo $kargmax | $SED 's/.*[[ ]]//'` 51590b0ce0bfSmrg else 51600b0ce0bfSmrg lt_cv_sys_max_cmd_len=32768 51610b0ce0bfSmrg fi 51620b0ce0bfSmrg ;; 51630b0ce0bfSmrg *) 51640b0ce0bfSmrg lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` 51650b0ce0bfSmrg if test -n "$lt_cv_sys_max_cmd_len" && \ 51660b0ce0bfSmrg test undefined != "$lt_cv_sys_max_cmd_len"; then 51670b0ce0bfSmrg lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` 51680b0ce0bfSmrg lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` 51690b0ce0bfSmrg else 51700b0ce0bfSmrg # Make teststring a little bigger before we do anything with it. 51710b0ce0bfSmrg # a 1K string should be a reasonable start. 51720b0ce0bfSmrg for i in 1 2 3 4 5 6 7 8; do 51730b0ce0bfSmrg teststring=$teststring$teststring 51740b0ce0bfSmrg done 51750b0ce0bfSmrg SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} 51760b0ce0bfSmrg # If test is not a shell built-in, we'll probably end up computing a 51770b0ce0bfSmrg # maximum length that is only half of the actual maximum length, but 51780b0ce0bfSmrg # we can't tell. 51790b0ce0bfSmrg while { test X`env echo "$teststring$teststring" 2>/dev/null` \ 51800b0ce0bfSmrg = "X$teststring$teststring"; } >/dev/null 2>&1 && 51810b0ce0bfSmrg test 17 != "$i" # 1/2 MB should be enough 51820b0ce0bfSmrg do 51830b0ce0bfSmrg i=`expr $i + 1` 51840b0ce0bfSmrg teststring=$teststring$teststring 51850b0ce0bfSmrg done 51860b0ce0bfSmrg # Only check the string length outside the loop. 51870b0ce0bfSmrg lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1` 51880b0ce0bfSmrg teststring= 51890b0ce0bfSmrg # Add a significant safety factor because C++ compilers can tack on 51900b0ce0bfSmrg # massive amounts of additional arguments before passing them to the 51910b0ce0bfSmrg # linker. It appears as though 1/2 is a usable value. 51920b0ce0bfSmrg lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` 51930b0ce0bfSmrg fi 51940b0ce0bfSmrg ;; 51950b0ce0bfSmrg esac 51960b0ce0bfSmrg]) 51970b0ce0bfSmrgif test -n "$lt_cv_sys_max_cmd_len"; then 51980b0ce0bfSmrg AC_MSG_RESULT($lt_cv_sys_max_cmd_len) 5199e35d4d8eSmrgelse 52000b0ce0bfSmrg AC_MSG_RESULT(none) 5201e35d4d8eSmrgfi 52020b0ce0bfSmrgmax_cmd_len=$lt_cv_sys_max_cmd_len 52030b0ce0bfSmrg_LT_DECL([], [max_cmd_len], [0], 52040b0ce0bfSmrg [What is the maximum length of a command?]) 52050b0ce0bfSmrg])# LT_CMD_MAX_LEN 52061b12faf6Smrg 52070b0ce0bfSmrg# Old name: 52080b0ce0bfSmrgAU_ALIAS([AC_LIBTOOL_SYS_MAX_CMD_LEN], [LT_CMD_MAX_LEN]) 52090b0ce0bfSmrgdnl aclocal-1.4 backwards compatibility: 52100b0ce0bfSmrgdnl AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], []) 521132b578d3Smrg 521232b578d3Smrg 52130b0ce0bfSmrg# _LT_HEADER_DLFCN 52140b0ce0bfSmrg# ---------------- 52150b0ce0bfSmrgm4_defun([_LT_HEADER_DLFCN], 52160b0ce0bfSmrg[AC_CHECK_HEADERS([dlfcn.h], [], [], [AC_INCLUDES_DEFAULT])dnl 52170b0ce0bfSmrg])# _LT_HEADER_DLFCN 52181b12faf6Smrg 52191b12faf6Smrg 52200b0ce0bfSmrg# _LT_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE, 52210b0ce0bfSmrg# ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING) 52220b0ce0bfSmrg# ---------------------------------------------------------------- 52230b0ce0bfSmrgm4_defun([_LT_TRY_DLOPEN_SELF], 52240b0ce0bfSmrg[m4_require([_LT_HEADER_DLFCN])dnl 52250b0ce0bfSmrgif test yes = "$cross_compiling"; then : 52260b0ce0bfSmrg [$4] 52270b0ce0bfSmrgelse 52280b0ce0bfSmrg lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 52290b0ce0bfSmrg lt_status=$lt_dlunknown 52300b0ce0bfSmrg cat > conftest.$ac_ext <<_LT_EOF 52310b0ce0bfSmrg[#line $LINENO "configure" 52320b0ce0bfSmrg#include "confdefs.h" 52331b12faf6Smrg 52340b0ce0bfSmrg#if HAVE_DLFCN_H 52350b0ce0bfSmrg#include <dlfcn.h> 52360b0ce0bfSmrg#endif 52371b12faf6Smrg 52380b0ce0bfSmrg#include <stdio.h> 52391b12faf6Smrg 52400b0ce0bfSmrg#ifdef RTLD_GLOBAL 52410b0ce0bfSmrg# define LT_DLGLOBAL RTLD_GLOBAL 52420b0ce0bfSmrg#else 52430b0ce0bfSmrg# ifdef DL_GLOBAL 52440b0ce0bfSmrg# define LT_DLGLOBAL DL_GLOBAL 52450b0ce0bfSmrg# else 52460b0ce0bfSmrg# define LT_DLGLOBAL 0 52470b0ce0bfSmrg# endif 52480b0ce0bfSmrg#endif 524932b578d3Smrg 52500b0ce0bfSmrg/* We may have to define LT_DLLAZY_OR_NOW in the command line if we 52510b0ce0bfSmrg find out it does not work in some platform. */ 52520b0ce0bfSmrg#ifndef LT_DLLAZY_OR_NOW 52530b0ce0bfSmrg# ifdef RTLD_LAZY 52540b0ce0bfSmrg# define LT_DLLAZY_OR_NOW RTLD_LAZY 52550b0ce0bfSmrg# else 52560b0ce0bfSmrg# ifdef DL_LAZY 52570b0ce0bfSmrg# define LT_DLLAZY_OR_NOW DL_LAZY 52580b0ce0bfSmrg# else 52590b0ce0bfSmrg# ifdef RTLD_NOW 52600b0ce0bfSmrg# define LT_DLLAZY_OR_NOW RTLD_NOW 52610b0ce0bfSmrg# else 52620b0ce0bfSmrg# ifdef DL_NOW 52630b0ce0bfSmrg# define LT_DLLAZY_OR_NOW DL_NOW 52640b0ce0bfSmrg# else 52650b0ce0bfSmrg# define LT_DLLAZY_OR_NOW 0 52660b0ce0bfSmrg# endif 52670b0ce0bfSmrg# endif 52680b0ce0bfSmrg# endif 52690b0ce0bfSmrg# endif 52700b0ce0bfSmrg#endif 527132b578d3Smrg 52720b0ce0bfSmrg/* When -fvisibility=hidden is used, assume the code has been annotated 52730b0ce0bfSmrg correspondingly for the symbols needed. */ 52740b0ce0bfSmrg#if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) 52750b0ce0bfSmrgint fnord () __attribute__((visibility("default"))); 52760b0ce0bfSmrg#endif 527732b578d3Smrg 52780b0ce0bfSmrgint fnord () { return 42; } 52790b0ce0bfSmrgint main () 52800b0ce0bfSmrg{ 52810b0ce0bfSmrg void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); 52820b0ce0bfSmrg int status = $lt_dlunknown; 528332b578d3Smrg 52840b0ce0bfSmrg if (self) 52850b0ce0bfSmrg { 52860b0ce0bfSmrg if (dlsym (self,"fnord")) status = $lt_dlno_uscore; 52870b0ce0bfSmrg else 52880b0ce0bfSmrg { 52890b0ce0bfSmrg if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; 52900b0ce0bfSmrg else puts (dlerror ()); 52910b0ce0bfSmrg } 52920b0ce0bfSmrg /* dlclose (self); */ 52930b0ce0bfSmrg } 52940b0ce0bfSmrg else 52950b0ce0bfSmrg puts (dlerror ()); 529632b578d3Smrg 52970b0ce0bfSmrg return status; 52980b0ce0bfSmrg}] 52990b0ce0bfSmrg_LT_EOF 53000b0ce0bfSmrg if AC_TRY_EVAL(ac_link) && test -s "conftest$ac_exeext" 2>/dev/null; then 53010b0ce0bfSmrg (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null 53020b0ce0bfSmrg lt_status=$? 53030b0ce0bfSmrg case x$lt_status in 53040b0ce0bfSmrg x$lt_dlno_uscore) $1 ;; 53050b0ce0bfSmrg x$lt_dlneed_uscore) $2 ;; 53060b0ce0bfSmrg x$lt_dlunknown|x*) $3 ;; 53070b0ce0bfSmrg esac 53080b0ce0bfSmrg else : 53090b0ce0bfSmrg # compilation failed 53100b0ce0bfSmrg $3 53110b0ce0bfSmrg fi 53120b0ce0bfSmrgfi 53130b0ce0bfSmrgrm -fr conftest* 53140b0ce0bfSmrg])# _LT_TRY_DLOPEN_SELF 531532b578d3Smrg 5316d31dbc53Smrg 53170b0ce0bfSmrg# LT_SYS_DLOPEN_SELF 53180b0ce0bfSmrg# ------------------ 53190b0ce0bfSmrgAC_DEFUN([LT_SYS_DLOPEN_SELF], 53200b0ce0bfSmrg[m4_require([_LT_HEADER_DLFCN])dnl 53210b0ce0bfSmrgif test yes != "$enable_dlopen"; then 53220b0ce0bfSmrg enable_dlopen=unknown 53230b0ce0bfSmrg enable_dlopen_self=unknown 53240b0ce0bfSmrg enable_dlopen_self_static=unknown 53250b0ce0bfSmrgelse 53260b0ce0bfSmrg lt_cv_dlopen=no 53270b0ce0bfSmrg lt_cv_dlopen_libs= 53281b12faf6Smrg 53290b0ce0bfSmrg case $host_os in 53300b0ce0bfSmrg beos*) 53310b0ce0bfSmrg lt_cv_dlopen=load_add_on 53320b0ce0bfSmrg lt_cv_dlopen_libs= 53330b0ce0bfSmrg lt_cv_dlopen_self=yes 53340b0ce0bfSmrg ;; 533532b578d3Smrg 53360b0ce0bfSmrg mingw* | pw32* | cegcc*) 53370b0ce0bfSmrg lt_cv_dlopen=LoadLibrary 53380b0ce0bfSmrg lt_cv_dlopen_libs= 53390b0ce0bfSmrg ;; 534032b578d3Smrg 53410b0ce0bfSmrg cygwin*) 53420b0ce0bfSmrg lt_cv_dlopen=dlopen 53430b0ce0bfSmrg lt_cv_dlopen_libs= 53440b0ce0bfSmrg ;; 534532b578d3Smrg 53460b0ce0bfSmrg darwin*) 53470b0ce0bfSmrg # if libdl is installed we need to link against it 53480b0ce0bfSmrg AC_CHECK_LIB([dl], [dlopen], 53490b0ce0bfSmrg [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl],[ 53500b0ce0bfSmrg lt_cv_dlopen=dyld 53510b0ce0bfSmrg lt_cv_dlopen_libs= 53520b0ce0bfSmrg lt_cv_dlopen_self=yes 53530b0ce0bfSmrg ]) 53540b0ce0bfSmrg ;; 53551b12faf6Smrg 53560b0ce0bfSmrg tpf*) 53570b0ce0bfSmrg # Don't try to run any link tests for TPF. We know it's impossible 53580b0ce0bfSmrg # because TPF is a cross-compiler, and we know how we open DSOs. 53590b0ce0bfSmrg lt_cv_dlopen=dlopen 53600b0ce0bfSmrg lt_cv_dlopen_libs= 53610b0ce0bfSmrg lt_cv_dlopen_self=no 53620b0ce0bfSmrg ;; 536332b578d3Smrg 53640b0ce0bfSmrg *) 53650b0ce0bfSmrg AC_CHECK_FUNC([shl_load], 53660b0ce0bfSmrg [lt_cv_dlopen=shl_load], 53670b0ce0bfSmrg [AC_CHECK_LIB([dld], [shl_load], 53680b0ce0bfSmrg [lt_cv_dlopen=shl_load lt_cv_dlopen_libs=-ldld], 53690b0ce0bfSmrg [AC_CHECK_FUNC([dlopen], 53700b0ce0bfSmrg [lt_cv_dlopen=dlopen], 53710b0ce0bfSmrg [AC_CHECK_LIB([dl], [dlopen], 53720b0ce0bfSmrg [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl], 53730b0ce0bfSmrg [AC_CHECK_LIB([svld], [dlopen], 53740b0ce0bfSmrg [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-lsvld], 53750b0ce0bfSmrg [AC_CHECK_LIB([dld], [dld_link], 53760b0ce0bfSmrg [lt_cv_dlopen=dld_link lt_cv_dlopen_libs=-ldld]) 53770b0ce0bfSmrg ]) 53780b0ce0bfSmrg ]) 53790b0ce0bfSmrg ]) 53800b0ce0bfSmrg ]) 53810b0ce0bfSmrg ]) 53820b0ce0bfSmrg ;; 53830b0ce0bfSmrg esac 538432b578d3Smrg 53850b0ce0bfSmrg if test no = "$lt_cv_dlopen"; then 53860b0ce0bfSmrg enable_dlopen=no 53870b0ce0bfSmrg else 53880b0ce0bfSmrg enable_dlopen=yes 53890b0ce0bfSmrg fi 53901b12faf6Smrg 53910b0ce0bfSmrg case $lt_cv_dlopen in 53920b0ce0bfSmrg dlopen) 53930b0ce0bfSmrg save_CPPFLAGS=$CPPFLAGS 53940b0ce0bfSmrg test yes = "$ac_cv_header_dlfcn_h" && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" 53951b12faf6Smrg 53960b0ce0bfSmrg save_LDFLAGS=$LDFLAGS 53970b0ce0bfSmrg wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" 539832b578d3Smrg 53990b0ce0bfSmrg save_LIBS=$LIBS 54000b0ce0bfSmrg LIBS="$lt_cv_dlopen_libs $LIBS" 54011b12faf6Smrg 54020b0ce0bfSmrg AC_CACHE_CHECK([whether a program can dlopen itself], 54030b0ce0bfSmrg lt_cv_dlopen_self, [dnl 54040b0ce0bfSmrg _LT_TRY_DLOPEN_SELF( 54050b0ce0bfSmrg lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes, 54060b0ce0bfSmrg lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross) 54070b0ce0bfSmrg ]) 540832b578d3Smrg 54090b0ce0bfSmrg if test yes = "$lt_cv_dlopen_self"; then 54100b0ce0bfSmrg wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" 54110b0ce0bfSmrg AC_CACHE_CHECK([whether a statically linked program can dlopen itself], 54120b0ce0bfSmrg lt_cv_dlopen_self_static, [dnl 54130b0ce0bfSmrg _LT_TRY_DLOPEN_SELF( 54140b0ce0bfSmrg lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes, 54150b0ce0bfSmrg lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross) 54160b0ce0bfSmrg ]) 54170b0ce0bfSmrg fi 541832b578d3Smrg 54190b0ce0bfSmrg CPPFLAGS=$save_CPPFLAGS 54200b0ce0bfSmrg LDFLAGS=$save_LDFLAGS 54210b0ce0bfSmrg LIBS=$save_LIBS 54220b0ce0bfSmrg ;; 54230b0ce0bfSmrg esac 542432b578d3Smrg 54250b0ce0bfSmrg case $lt_cv_dlopen_self in 54260b0ce0bfSmrg yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; 54270b0ce0bfSmrg *) enable_dlopen_self=unknown ;; 54280b0ce0bfSmrg esac 542932b578d3Smrg 54300b0ce0bfSmrg case $lt_cv_dlopen_self_static in 54310b0ce0bfSmrg yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; 54320b0ce0bfSmrg *) enable_dlopen_self_static=unknown ;; 54330b0ce0bfSmrg esac 54340b0ce0bfSmrgfi 54350b0ce0bfSmrg_LT_DECL([dlopen_support], [enable_dlopen], [0], 54360b0ce0bfSmrg [Whether dlopen is supported]) 54370b0ce0bfSmrg_LT_DECL([dlopen_self], [enable_dlopen_self], [0], 54380b0ce0bfSmrg [Whether dlopen of programs is supported]) 54390b0ce0bfSmrg_LT_DECL([dlopen_self_static], [enable_dlopen_self_static], [0], 54400b0ce0bfSmrg [Whether dlopen of statically linked programs is supported]) 54410b0ce0bfSmrg])# LT_SYS_DLOPEN_SELF 544232b578d3Smrg 54430b0ce0bfSmrg# Old name: 54440b0ce0bfSmrgAU_ALIAS([AC_LIBTOOL_DLOPEN_SELF], [LT_SYS_DLOPEN_SELF]) 54450b0ce0bfSmrgdnl aclocal-1.4 backwards compatibility: 54460b0ce0bfSmrgdnl AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], []) 544732b578d3Smrg 544832b578d3Smrg 54490b0ce0bfSmrg# _LT_COMPILER_C_O([TAGNAME]) 54500b0ce0bfSmrg# --------------------------- 54510b0ce0bfSmrg# Check to see if options -c and -o are simultaneously supported by compiler. 54520b0ce0bfSmrg# This macro does not hard code the compiler like AC_PROG_CC_C_O. 54530b0ce0bfSmrgm4_defun([_LT_COMPILER_C_O], 54540b0ce0bfSmrg[m4_require([_LT_DECL_SED])dnl 54550b0ce0bfSmrgm4_require([_LT_FILEUTILS_DEFAULTS])dnl 54560b0ce0bfSmrgm4_require([_LT_TAG_COMPILER])dnl 54570b0ce0bfSmrgAC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext], 54580b0ce0bfSmrg [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)], 54590b0ce0bfSmrg [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no 54600b0ce0bfSmrg $RM -r conftest 2>/dev/null 54610b0ce0bfSmrg mkdir conftest 54620b0ce0bfSmrg cd conftest 54630b0ce0bfSmrg mkdir out 54640b0ce0bfSmrg echo "$lt_simple_compile_test_code" > conftest.$ac_ext 546532b578d3Smrg 54660b0ce0bfSmrg lt_compiler_flag="-o out/conftest2.$ac_objext" 54670b0ce0bfSmrg # Insert the option either (1) after the last *FLAGS variable, or 54680b0ce0bfSmrg # (2) before a word containing "conftest.", or (3) at the end. 54690b0ce0bfSmrg # Note that $ac_compile itself does not contain backslashes and begins 54700b0ce0bfSmrg # with a dollar sign (not a hyphen), so the echo should work correctly. 54710b0ce0bfSmrg lt_compile=`echo "$ac_compile" | $SED \ 54720b0ce0bfSmrg -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ 54730b0ce0bfSmrg -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ 54740b0ce0bfSmrg -e 's:$: $lt_compiler_flag:'` 54750b0ce0bfSmrg (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD) 54760b0ce0bfSmrg (eval "$lt_compile" 2>out/conftest.err) 54770b0ce0bfSmrg ac_status=$? 54780b0ce0bfSmrg cat out/conftest.err >&AS_MESSAGE_LOG_FD 54790b0ce0bfSmrg echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD 54800b0ce0bfSmrg if (exit $ac_status) && test -s out/conftest2.$ac_objext 54810b0ce0bfSmrg then 54820b0ce0bfSmrg # The compiler can only warn and ignore the option if not recognized 54830b0ce0bfSmrg # So say no if there are warnings 54840b0ce0bfSmrg $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp 54850b0ce0bfSmrg $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 54860b0ce0bfSmrg if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then 54870b0ce0bfSmrg _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes 54880b0ce0bfSmrg fi 54890b0ce0bfSmrg fi 54900b0ce0bfSmrg chmod u+w . 2>&AS_MESSAGE_LOG_FD 54910b0ce0bfSmrg $RM conftest* 54920b0ce0bfSmrg # SGI C++ compiler will create directory out/ii_files/ for 54930b0ce0bfSmrg # template instantiation 54940b0ce0bfSmrg test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files 54950b0ce0bfSmrg $RM out/* && rmdir out 54960b0ce0bfSmrg cd .. 54970b0ce0bfSmrg $RM -r conftest 54980b0ce0bfSmrg $RM conftest* 54990b0ce0bfSmrg]) 55000b0ce0bfSmrg_LT_TAGDECL([compiler_c_o], [lt_cv_prog_compiler_c_o], [1], 55010b0ce0bfSmrg [Does compiler simultaneously support -c and -o options?]) 55020b0ce0bfSmrg])# _LT_COMPILER_C_O 550332b578d3Smrg 5504e35d4d8eSmrg 55050b0ce0bfSmrg# _LT_COMPILER_FILE_LOCKS([TAGNAME]) 55060b0ce0bfSmrg# ---------------------------------- 55070b0ce0bfSmrg# Check to see if we can do hard links to lock some files if needed 55080b0ce0bfSmrgm4_defun([_LT_COMPILER_FILE_LOCKS], 55090b0ce0bfSmrg[m4_require([_LT_ENABLE_LOCK])dnl 55100b0ce0bfSmrgm4_require([_LT_FILEUTILS_DEFAULTS])dnl 55110b0ce0bfSmrg_LT_COMPILER_C_O([$1]) 55121b12faf6Smrg 55130b0ce0bfSmrghard_links=nottested 55140b0ce0bfSmrgif test no = "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" && test no != "$need_locks"; then 55150b0ce0bfSmrg # do not overwrite the value of need_locks provided by the user 55160b0ce0bfSmrg AC_MSG_CHECKING([if we can lock with hard links]) 55170b0ce0bfSmrg hard_links=yes 55180b0ce0bfSmrg $RM conftest* 55190b0ce0bfSmrg ln conftest.a conftest.b 2>/dev/null && hard_links=no 55200b0ce0bfSmrg touch conftest.a 55210b0ce0bfSmrg ln conftest.a conftest.b 2>&5 || hard_links=no 55220b0ce0bfSmrg ln conftest.a conftest.b 2>/dev/null && hard_links=no 55230b0ce0bfSmrg AC_MSG_RESULT([$hard_links]) 55240b0ce0bfSmrg if test no = "$hard_links"; then 55250b0ce0bfSmrg AC_MSG_WARN(['$CC' does not support '-c -o', so 'make -j' may be unsafe]) 55260b0ce0bfSmrg need_locks=warn 55270b0ce0bfSmrg fi 55280b0ce0bfSmrgelse 55290b0ce0bfSmrg need_locks=no 55300b0ce0bfSmrgfi 55310b0ce0bfSmrg_LT_DECL([], [need_locks], [1], [Must we lock files when doing compilation?]) 55320b0ce0bfSmrg])# _LT_COMPILER_FILE_LOCKS 553332b578d3Smrg 55341b12faf6Smrg 55350b0ce0bfSmrg# _LT_CHECK_OBJDIR 55360b0ce0bfSmrg# ---------------- 55370b0ce0bfSmrgm4_defun([_LT_CHECK_OBJDIR], 55380b0ce0bfSmrg[AC_CACHE_CHECK([for objdir], [lt_cv_objdir], 55390b0ce0bfSmrg[rm -f .libs 2>/dev/null 55400b0ce0bfSmrgmkdir .libs 2>/dev/null 55410b0ce0bfSmrgif test -d .libs; then 55420b0ce0bfSmrg lt_cv_objdir=.libs 55430b0ce0bfSmrgelse 55440b0ce0bfSmrg # MS-DOS does not allow filenames that begin with a dot. 55450b0ce0bfSmrg lt_cv_objdir=_libs 55460b0ce0bfSmrgfi 55470b0ce0bfSmrgrmdir .libs 2>/dev/null]) 55480b0ce0bfSmrgobjdir=$lt_cv_objdir 55490b0ce0bfSmrg_LT_DECL([], [objdir], [0], 55500b0ce0bfSmrg [The name of the directory that contains temporary libtool files])dnl 55510b0ce0bfSmrgm4_pattern_allow([LT_OBJDIR])dnl 55520b0ce0bfSmrgAC_DEFINE_UNQUOTED([LT_OBJDIR], "$lt_cv_objdir/", 55530b0ce0bfSmrg [Define to the sub-directory where libtool stores uninstalled libraries.]) 55540b0ce0bfSmrg])# _LT_CHECK_OBJDIR 55551b12faf6Smrg 555632b578d3Smrg 55570b0ce0bfSmrg# _LT_LINKER_HARDCODE_LIBPATH([TAGNAME]) 55580b0ce0bfSmrg# -------------------------------------- 55590b0ce0bfSmrg# Check hardcoding attributes. 55600b0ce0bfSmrgm4_defun([_LT_LINKER_HARDCODE_LIBPATH], 55610b0ce0bfSmrg[AC_MSG_CHECKING([how to hardcode library paths into programs]) 55620b0ce0bfSmrg_LT_TAGVAR(hardcode_action, $1)= 55630b0ce0bfSmrgif test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" || 55640b0ce0bfSmrg test -n "$_LT_TAGVAR(runpath_var, $1)" || 55650b0ce0bfSmrg test yes = "$_LT_TAGVAR(hardcode_automatic, $1)"; then 556632b578d3Smrg 55670b0ce0bfSmrg # We can hardcode non-existent directories. 55680b0ce0bfSmrg if test no != "$_LT_TAGVAR(hardcode_direct, $1)" && 55690b0ce0bfSmrg # If the only mechanism to avoid hardcoding is shlibpath_var, we 55700b0ce0bfSmrg # have to relink, otherwise we might link with an installed library 55710b0ce0bfSmrg # when we should be linking with a yet-to-be-installed one 55720b0ce0bfSmrg ## test no != "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" && 55730b0ce0bfSmrg test no != "$_LT_TAGVAR(hardcode_minus_L, $1)"; then 55740b0ce0bfSmrg # Linking always hardcodes the temporary library directory. 55750b0ce0bfSmrg _LT_TAGVAR(hardcode_action, $1)=relink 55760b0ce0bfSmrg else 55770b0ce0bfSmrg # We can link without hardcoding, and we can hardcode nonexisting dirs. 55780b0ce0bfSmrg _LT_TAGVAR(hardcode_action, $1)=immediate 55790b0ce0bfSmrg fi 55800b0ce0bfSmrgelse 55810b0ce0bfSmrg # We cannot hardcode anything, or else we can only hardcode existing 55820b0ce0bfSmrg # directories. 55830b0ce0bfSmrg _LT_TAGVAR(hardcode_action, $1)=unsupported 55840b0ce0bfSmrgfi 55850b0ce0bfSmrgAC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)]) 558632b578d3Smrg 55870b0ce0bfSmrgif test relink = "$_LT_TAGVAR(hardcode_action, $1)" || 55880b0ce0bfSmrg test yes = "$_LT_TAGVAR(inherit_rpath, $1)"; then 55890b0ce0bfSmrg # Fast installation is not supported 55900b0ce0bfSmrg enable_fast_install=no 55910b0ce0bfSmrgelif test yes = "$shlibpath_overrides_runpath" || 55920b0ce0bfSmrg test no = "$enable_shared"; then 55930b0ce0bfSmrg # Fast installation is not necessary 55940b0ce0bfSmrg enable_fast_install=needless 55950b0ce0bfSmrgfi 55960b0ce0bfSmrg_LT_TAGDECL([], [hardcode_action], [0], 55970b0ce0bfSmrg [How to hardcode a shared library path into an executable]) 55980b0ce0bfSmrg])# _LT_LINKER_HARDCODE_LIBPATH 55991b12faf6Smrg 56001b12faf6Smrg 56010b0ce0bfSmrg# _LT_CMD_STRIPLIB 56020b0ce0bfSmrg# ---------------- 56030b0ce0bfSmrgm4_defun([_LT_CMD_STRIPLIB], 56040b0ce0bfSmrg[m4_require([_LT_DECL_EGREP]) 56050b0ce0bfSmrgstriplib= 56060b0ce0bfSmrgold_striplib= 56070b0ce0bfSmrgAC_MSG_CHECKING([whether stripping libraries is possible]) 56080b0ce0bfSmrgif test -z "$STRIP"; then 56090b0ce0bfSmrg AC_MSG_RESULT([no]) 56100b0ce0bfSmrgelse 56110b0ce0bfSmrg if $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then 56120b0ce0bfSmrg old_striplib="$STRIP --strip-debug" 56130b0ce0bfSmrg striplib="$STRIP --strip-unneeded" 56140b0ce0bfSmrg AC_MSG_RESULT([yes]) 56150b0ce0bfSmrg else 56160b0ce0bfSmrg case $host_os in 56170b0ce0bfSmrg darwin*) 56180b0ce0bfSmrg # FIXME - insert some real tests, host_os isn't really good enough 56190b0ce0bfSmrg striplib="$STRIP -x" 56200b0ce0bfSmrg old_striplib="$STRIP -S" 56210b0ce0bfSmrg AC_MSG_RESULT([yes]) 56220b0ce0bfSmrg ;; 56230b0ce0bfSmrg freebsd*) 56240b0ce0bfSmrg if $STRIP -V 2>&1 | $GREP "elftoolchain" >/dev/null; then 56250b0ce0bfSmrg old_striplib="$STRIP --strip-debug" 56260b0ce0bfSmrg striplib="$STRIP --strip-unneeded" 56270b0ce0bfSmrg AC_MSG_RESULT([yes]) 56280b0ce0bfSmrg else 56290b0ce0bfSmrg AC_MSG_RESULT([no]) 56300b0ce0bfSmrg fi 56310b0ce0bfSmrg ;; 56320b0ce0bfSmrg *) 56330b0ce0bfSmrg AC_MSG_RESULT([no]) 56340b0ce0bfSmrg ;; 56350b0ce0bfSmrg esac 56360b0ce0bfSmrg fi 56370b0ce0bfSmrgfi 56380b0ce0bfSmrg_LT_DECL([], [old_striplib], [1], [Commands to strip libraries]) 56390b0ce0bfSmrg_LT_DECL([], [striplib], [1]) 56400b0ce0bfSmrg])# _LT_CMD_STRIPLIB 564132b578d3Smrg 564232b578d3Smrg 56430b0ce0bfSmrg# _LT_PREPARE_MUNGE_PATH_LIST 56440b0ce0bfSmrg# --------------------------- 56450b0ce0bfSmrg# Make sure func_munge_path_list() is defined correctly. 56460b0ce0bfSmrgm4_defun([_LT_PREPARE_MUNGE_PATH_LIST], 56470b0ce0bfSmrg[[# func_munge_path_list VARIABLE PATH 56480b0ce0bfSmrg# ----------------------------------- 56490b0ce0bfSmrg# VARIABLE is name of variable containing _space_ separated list of 56500b0ce0bfSmrg# directories to be munged by the contents of PATH, which is string 56510b0ce0bfSmrg# having a format: 56520b0ce0bfSmrg# "DIR[:DIR]:" 56530b0ce0bfSmrg# string "DIR[ DIR]" will be prepended to VARIABLE 56540b0ce0bfSmrg# ":DIR[:DIR]" 56550b0ce0bfSmrg# string "DIR[ DIR]" will be appended to VARIABLE 56560b0ce0bfSmrg# "DIRP[:DIRP]::[DIRA:]DIRA" 56570b0ce0bfSmrg# string "DIRP[ DIRP]" will be prepended to VARIABLE and string 56580b0ce0bfSmrg# "DIRA[ DIRA]" will be appended to VARIABLE 56590b0ce0bfSmrg# "DIR[:DIR]" 56600b0ce0bfSmrg# VARIABLE will be replaced by "DIR[ DIR]" 56610b0ce0bfSmrgfunc_munge_path_list () 56620b0ce0bfSmrg{ 56630b0ce0bfSmrg case x@S|@2 in 56640b0ce0bfSmrg x) 56650b0ce0bfSmrg ;; 56660b0ce0bfSmrg *:) 56670b0ce0bfSmrg eval @S|@1=\"`$ECHO @S|@2 | $SED 's/:/ /g'` \@S|@@S|@1\" 56680b0ce0bfSmrg ;; 56690b0ce0bfSmrg x:*) 56700b0ce0bfSmrg eval @S|@1=\"\@S|@@S|@1 `$ECHO @S|@2 | $SED 's/:/ /g'`\" 56710b0ce0bfSmrg ;; 56720b0ce0bfSmrg *::*) 56730b0ce0bfSmrg eval @S|@1=\"\@S|@@S|@1\ `$ECHO @S|@2 | $SED -e 's/.*:://' -e 's/:/ /g'`\" 56740b0ce0bfSmrg eval @S|@1=\"`$ECHO @S|@2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \@S|@@S|@1\" 56750b0ce0bfSmrg ;; 56760b0ce0bfSmrg *) 56770b0ce0bfSmrg eval @S|@1=\"`$ECHO @S|@2 | $SED 's/:/ /g'`\" 56780b0ce0bfSmrg ;; 56790b0ce0bfSmrg esac 56800b0ce0bfSmrg} 56810b0ce0bfSmrg]])# _LT_PREPARE_PATH_LIST 568232b578d3Smrg 56831b12faf6Smrg 56840b0ce0bfSmrg# _LT_SYS_DYNAMIC_LINKER([TAG]) 56850b0ce0bfSmrg# ----------------------------- 56860b0ce0bfSmrg# PORTME Fill in your ld.so characteristics 56870b0ce0bfSmrgm4_defun([_LT_SYS_DYNAMIC_LINKER], 56880b0ce0bfSmrg[AC_REQUIRE([AC_CANONICAL_HOST])dnl 56890b0ce0bfSmrgm4_require([_LT_DECL_EGREP])dnl 56900b0ce0bfSmrgm4_require([_LT_FILEUTILS_DEFAULTS])dnl 56910b0ce0bfSmrgm4_require([_LT_DECL_OBJDUMP])dnl 56920b0ce0bfSmrgm4_require([_LT_DECL_SED])dnl 56930b0ce0bfSmrgm4_require([_LT_CHECK_SHELL_FEATURES])dnl 56940b0ce0bfSmrgm4_require([_LT_PREPARE_MUNGE_PATH_LIST])dnl 56950b0ce0bfSmrgAC_MSG_CHECKING([dynamic linker characteristics]) 56960b0ce0bfSmrgm4_if([$1], 56970b0ce0bfSmrg [], [ 56980b0ce0bfSmrgif test yes = "$GCC"; then 56990b0ce0bfSmrg case $host_os in 57000b0ce0bfSmrg darwin*) lt_awk_arg='/^libraries:/,/LR/' ;; 57010b0ce0bfSmrg *) lt_awk_arg='/^libraries:/' ;; 57020b0ce0bfSmrg esac 57030b0ce0bfSmrg case $host_os in 57040b0ce0bfSmrg mingw* | cegcc*) lt_sed_strip_eq='s|=\([[A-Za-z]]:\)|\1|g' ;; 57050b0ce0bfSmrg *) lt_sed_strip_eq='s|=/|/|g' ;; 57060b0ce0bfSmrg esac 57070b0ce0bfSmrg lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq` 57080b0ce0bfSmrg case $lt_search_path_spec in 57090b0ce0bfSmrg *\;*) 57100b0ce0bfSmrg # if the path contains ";" then we assume it to be the separator 57110b0ce0bfSmrg # otherwise default to the standard path separator (i.e. ":") - it is 57120b0ce0bfSmrg # assumed that no part of a normal pathname contains ";" but that should 57130b0ce0bfSmrg # okay in the real world where ";" in dirpaths is itself problematic. 57140b0ce0bfSmrg lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'` 57150b0ce0bfSmrg ;; 57160b0ce0bfSmrg *) 57170b0ce0bfSmrg lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"` 57180b0ce0bfSmrg ;; 57190b0ce0bfSmrg esac 57200b0ce0bfSmrg # Ok, now we have the path, separated by spaces, we can step through it 57210b0ce0bfSmrg # and add multilib dir if necessary... 57220b0ce0bfSmrg lt_tmp_lt_search_path_spec= 57230b0ce0bfSmrg lt_multi_os_dir=/`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` 57240b0ce0bfSmrg # ...but if some path component already ends with the multilib dir we assume 57250b0ce0bfSmrg # that all is fine and trust -print-search-dirs as is (GCC 4.2? or newer). 57260b0ce0bfSmrg case "$lt_multi_os_dir; $lt_search_path_spec " in 57270b0ce0bfSmrg "/; "* | "/.; "* | "/./; "* | *"$lt_multi_os_dir "* | *"$lt_multi_os_dir/ "*) 57280b0ce0bfSmrg lt_multi_os_dir= 57290b0ce0bfSmrg ;; 57300b0ce0bfSmrg esac 57310b0ce0bfSmrg for lt_sys_path in $lt_search_path_spec; do 57320b0ce0bfSmrg if test -d "$lt_sys_path$lt_multi_os_dir"; then 57330b0ce0bfSmrg lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path$lt_multi_os_dir" 57340b0ce0bfSmrg elif test -n "$lt_multi_os_dir"; then 57350b0ce0bfSmrg test -d "$lt_sys_path" && \ 57360b0ce0bfSmrg lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" 57370b0ce0bfSmrg fi 57380b0ce0bfSmrg done 57390b0ce0bfSmrg lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk ' 57400b0ce0bfSmrgBEGIN {RS = " "; FS = "/|\n";} { 57410b0ce0bfSmrg lt_foo = ""; 57420b0ce0bfSmrg lt_count = 0; 57430b0ce0bfSmrg for (lt_i = NF; lt_i > 0; lt_i--) { 57440b0ce0bfSmrg if ($lt_i != "" && $lt_i != ".") { 57450b0ce0bfSmrg if ($lt_i == "..") { 57460b0ce0bfSmrg lt_count++; 57470b0ce0bfSmrg } else { 57480b0ce0bfSmrg if (lt_count == 0) { 57490b0ce0bfSmrg lt_foo = "/" $lt_i lt_foo; 57500b0ce0bfSmrg } else { 57510b0ce0bfSmrg lt_count--; 57520b0ce0bfSmrg } 57530b0ce0bfSmrg } 57540b0ce0bfSmrg } 57550b0ce0bfSmrg } 57560b0ce0bfSmrg if (lt_foo != "") { lt_freq[[lt_foo]]++; } 57570b0ce0bfSmrg if (lt_freq[[lt_foo]] == 1) { print lt_foo; } 57580b0ce0bfSmrg}'` 57590b0ce0bfSmrg # AWK program above erroneously prepends '/' to C:/dos/paths 57600b0ce0bfSmrg # for these hosts. 57610b0ce0bfSmrg case $host_os in 57620b0ce0bfSmrg mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ 57630b0ce0bfSmrg $SED 's|/\([[A-Za-z]]:\)|\1|g'` ;; 57640b0ce0bfSmrg esac 57650b0ce0bfSmrg sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP` 57660b0ce0bfSmrgelse 57670b0ce0bfSmrg sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" 57680b0ce0bfSmrgfi]) 57690b0ce0bfSmrglibrary_names_spec= 57700b0ce0bfSmrglibname_spec='lib$name' 57710b0ce0bfSmrgsoname_spec= 57720b0ce0bfSmrgshrext_cmds=.so 57730b0ce0bfSmrgpostinstall_cmds= 57740b0ce0bfSmrgpostuninstall_cmds= 57750b0ce0bfSmrgfinish_cmds= 57760b0ce0bfSmrgfinish_eval= 57770b0ce0bfSmrgshlibpath_var= 57780b0ce0bfSmrgshlibpath_overrides_runpath=unknown 57790b0ce0bfSmrgversion_type=none 57800b0ce0bfSmrgdynamic_linker="$host_os ld.so" 57810b0ce0bfSmrgsys_lib_dlsearch_path_spec="/lib /usr/lib" 57820b0ce0bfSmrgneed_lib_prefix=unknown 57830b0ce0bfSmrghardcode_into_libs=no 57841b12faf6Smrg 57850b0ce0bfSmrg# when you set need_version to no, make sure it does not cause -set_version 57860b0ce0bfSmrg# flags to be left without arguments 57870b0ce0bfSmrgneed_version=unknown 578832b578d3Smrg 57890b0ce0bfSmrgAC_ARG_VAR([LT_SYS_LIBRARY_PATH], 57900b0ce0bfSmrg[User-defined run-time library search path.]) 579132b578d3Smrg 57920b0ce0bfSmrgcase $host_os in 57930b0ce0bfSmrgaix3*) 57940b0ce0bfSmrg version_type=linux # correct to gnu/linux during the next big refactor 57950b0ce0bfSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname.a' 57960b0ce0bfSmrg shlibpath_var=LIBPATH 579732b578d3Smrg 57980b0ce0bfSmrg # AIX 3 has no versioning support, so we append a major version to the name. 57990b0ce0bfSmrg soname_spec='$libname$release$shared_ext$major' 58000b0ce0bfSmrg ;; 580132b578d3Smrg 58020b0ce0bfSmrgaix[[4-9]]*) 58030b0ce0bfSmrg version_type=linux # correct to gnu/linux during the next big refactor 58040b0ce0bfSmrg need_lib_prefix=no 58050b0ce0bfSmrg need_version=no 58060b0ce0bfSmrg hardcode_into_libs=yes 58070b0ce0bfSmrg if test ia64 = "$host_cpu"; then 58080b0ce0bfSmrg # AIX 5 supports IA64 58090b0ce0bfSmrg library_names_spec='$libname$release$shared_ext$major $libname$release$shared_ext$versuffix $libname$shared_ext' 58100b0ce0bfSmrg shlibpath_var=LD_LIBRARY_PATH 58110b0ce0bfSmrg else 58120b0ce0bfSmrg # With GCC up to 2.95.x, collect2 would create an import file 58130b0ce0bfSmrg # for dependence libraries. The import file would start with 58140b0ce0bfSmrg # the line '#! .'. This would cause the generated library to 58150b0ce0bfSmrg # depend on '.', always an invalid library. This was fixed in 58160b0ce0bfSmrg # development snapshots of GCC prior to 3.0. 58170b0ce0bfSmrg case $host_os in 58180b0ce0bfSmrg aix4 | aix4.[[01]] | aix4.[[01]].*) 58190b0ce0bfSmrg if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' 58200b0ce0bfSmrg echo ' yes ' 58210b0ce0bfSmrg echo '#endif'; } | $CC -E - | $GREP yes > /dev/null; then 58220b0ce0bfSmrg : 58230b0ce0bfSmrg else 58240b0ce0bfSmrg can_build_shared=no 58250b0ce0bfSmrg fi 58260b0ce0bfSmrg ;; 58270b0ce0bfSmrg esac 58280b0ce0bfSmrg # Using Import Files as archive members, it is possible to support 58290b0ce0bfSmrg # filename-based versioning of shared library archives on AIX. While 58300b0ce0bfSmrg # this would work for both with and without runtime linking, it will 58310b0ce0bfSmrg # prevent static linking of such archives. So we do filename-based 58320b0ce0bfSmrg # shared library versioning with .so extension only, which is used 58330b0ce0bfSmrg # when both runtime linking and shared linking is enabled. 58340b0ce0bfSmrg # Unfortunately, runtime linking may impact performance, so we do 58350b0ce0bfSmrg # not want this to be the default eventually. Also, we use the 58360b0ce0bfSmrg # versioned .so libs for executables only if there is the -brtl 58370b0ce0bfSmrg # linker flag in LDFLAGS as well, or --with-aix-soname=svr4 only. 58380b0ce0bfSmrg # To allow for filename-based versioning support, we need to create 58390b0ce0bfSmrg # libNAME.so.V as an archive file, containing: 58400b0ce0bfSmrg # *) an Import File, referring to the versioned filename of the 58410b0ce0bfSmrg # archive as well as the shared archive member, telling the 58420b0ce0bfSmrg # bitwidth (32 or 64) of that shared object, and providing the 58430b0ce0bfSmrg # list of exported symbols of that shared object, eventually 58440b0ce0bfSmrg # decorated with the 'weak' keyword 58450b0ce0bfSmrg # *) the shared object with the F_LOADONLY flag set, to really avoid 58460b0ce0bfSmrg # it being seen by the linker. 58470b0ce0bfSmrg # At run time we better use the real file rather than another symlink, 58480b0ce0bfSmrg # but for link time we create the symlink libNAME.so -> libNAME.so.V 58490b0ce0bfSmrg 58500b0ce0bfSmrg case $with_aix_soname,$aix_use_runtimelinking in 58510b0ce0bfSmrg # AIX (on Power*) has no versioning support, so currently we cannot hardcode correct 58520b0ce0bfSmrg # soname into executable. Probably we can add versioning support to 58530b0ce0bfSmrg # collect2, so additional links can be useful in future. 58540b0ce0bfSmrg aix,yes) # traditional libtool 58550b0ce0bfSmrg dynamic_linker='AIX unversionable lib.so' 58560b0ce0bfSmrg # If using run time linking (on AIX 4.2 or later) use lib<name>.so 58570b0ce0bfSmrg # instead of lib<name>.a to let people know that these are not 58580b0ce0bfSmrg # typical AIX shared libraries. 58590b0ce0bfSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 58600b0ce0bfSmrg ;; 58610b0ce0bfSmrg aix,no) # traditional AIX only 58620b0ce0bfSmrg dynamic_linker='AIX lib.a[(]lib.so.V[)]' 58630b0ce0bfSmrg # We preserve .a as extension for shared libraries through AIX4.2 58640b0ce0bfSmrg # and later when we are not doing run time linking. 58650b0ce0bfSmrg library_names_spec='$libname$release.a $libname.a' 58660b0ce0bfSmrg soname_spec='$libname$release$shared_ext$major' 58670b0ce0bfSmrg ;; 58680b0ce0bfSmrg svr4,*) # full svr4 only 58690b0ce0bfSmrg dynamic_linker="AIX lib.so.V[(]$shared_archive_member_spec.o[)]" 58700b0ce0bfSmrg library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' 58710b0ce0bfSmrg # We do not specify a path in Import Files, so LIBPATH fires. 58720b0ce0bfSmrg shlibpath_overrides_runpath=yes 58730b0ce0bfSmrg ;; 58740b0ce0bfSmrg *,yes) # both, prefer svr4 58750b0ce0bfSmrg dynamic_linker="AIX lib.so.V[(]$shared_archive_member_spec.o[)], lib.a[(]lib.so.V[)]" 58760b0ce0bfSmrg library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' 58770b0ce0bfSmrg # unpreferred sharedlib libNAME.a needs extra handling 58780b0ce0bfSmrg 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"' 58790b0ce0bfSmrg 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"' 58800b0ce0bfSmrg # We do not specify a path in Import Files, so LIBPATH fires. 58810b0ce0bfSmrg shlibpath_overrides_runpath=yes 58820b0ce0bfSmrg ;; 58830b0ce0bfSmrg *,no) # both, prefer aix 58840b0ce0bfSmrg dynamic_linker="AIX lib.a[(]lib.so.V[)], lib.so.V[(]$shared_archive_member_spec.o[)]" 58850b0ce0bfSmrg library_names_spec='$libname$release.a $libname.a' 58860b0ce0bfSmrg soname_spec='$libname$release$shared_ext$major' 58870b0ce0bfSmrg # unpreferred sharedlib libNAME.so.V and symlink libNAME.so need extra handling 58880b0ce0bfSmrg 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)' 58890b0ce0bfSmrg 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"' 58900b0ce0bfSmrg ;; 58910b0ce0bfSmrg esac 58920b0ce0bfSmrg shlibpath_var=LIBPATH 58930b0ce0bfSmrg fi 58940b0ce0bfSmrg ;; 589532b578d3Smrg 58960b0ce0bfSmrgamigaos*) 58970b0ce0bfSmrg case $host_cpu in 58980b0ce0bfSmrg powerpc) 58990b0ce0bfSmrg # Since July 2007 AmigaOS4 officially supports .so libraries. 59000b0ce0bfSmrg # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. 59010b0ce0bfSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 59020b0ce0bfSmrg ;; 59030b0ce0bfSmrg m68k) 59040b0ce0bfSmrg library_names_spec='$libname.ixlibrary $libname.a' 59050b0ce0bfSmrg # Create ${libname}_ixlibrary.a entries in /sys/libs. 59060b0ce0bfSmrg 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' 59070b0ce0bfSmrg ;; 59080b0ce0bfSmrg esac 59090b0ce0bfSmrg ;; 59101b12faf6Smrg 59110b0ce0bfSmrgbeos*) 59120b0ce0bfSmrg library_names_spec='$libname$shared_ext' 59130b0ce0bfSmrg dynamic_linker="$host_os ld.so" 59140b0ce0bfSmrg shlibpath_var=LIBRARY_PATH 59150b0ce0bfSmrg ;; 59161b12faf6Smrg 59170b0ce0bfSmrgbsdi[[45]]*) 59180b0ce0bfSmrg version_type=linux # correct to gnu/linux during the next big refactor 59190b0ce0bfSmrg need_version=no 59200b0ce0bfSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 59210b0ce0bfSmrg soname_spec='$libname$release$shared_ext$major' 59220b0ce0bfSmrg finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' 59230b0ce0bfSmrg shlibpath_var=LD_LIBRARY_PATH 59240b0ce0bfSmrg sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" 59250b0ce0bfSmrg sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" 59260b0ce0bfSmrg # the default ld.so.conf also contains /usr/contrib/lib and 59270b0ce0bfSmrg # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow 59280b0ce0bfSmrg # libtool to hard-code these into programs 59290b0ce0bfSmrg ;; 59301b12faf6Smrg 59310b0ce0bfSmrgcygwin* | mingw* | pw32* | cegcc*) 59320b0ce0bfSmrg version_type=windows 59330b0ce0bfSmrg shrext_cmds=.dll 59340b0ce0bfSmrg need_version=no 59350b0ce0bfSmrg need_lib_prefix=no 593632b578d3Smrg 59370b0ce0bfSmrg case $GCC,$cc_basename in 59380b0ce0bfSmrg yes,*) 59390b0ce0bfSmrg # gcc 59400b0ce0bfSmrg library_names_spec='$libname.dll.a' 59410b0ce0bfSmrg # DLL is installed to $(libdir)/../bin by postinstall_cmds 59420b0ce0bfSmrg postinstall_cmds='base_file=`basename \$file`~ 59430b0ce0bfSmrg dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ 59440b0ce0bfSmrg dldir=$destdir/`dirname \$dlpath`~ 59450b0ce0bfSmrg test -d \$dldir || mkdir -p \$dldir~ 59460b0ce0bfSmrg $install_prog $dir/$dlname \$dldir/$dlname~ 59470b0ce0bfSmrg chmod a+x \$dldir/$dlname~ 59480b0ce0bfSmrg if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then 59490b0ce0bfSmrg eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; 59500b0ce0bfSmrg fi' 59510b0ce0bfSmrg postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ 59520b0ce0bfSmrg dlpath=$dir/\$dldll~ 59530b0ce0bfSmrg $RM \$dlpath' 59540b0ce0bfSmrg shlibpath_overrides_runpath=yes 595532b578d3Smrg 59560b0ce0bfSmrg case $host_os in 59570b0ce0bfSmrg cygwin*) 59580b0ce0bfSmrg # Cygwin DLLs use 'cyg' prefix rather than 'lib' 59590b0ce0bfSmrg soname_spec='`echo $libname | $SED -e 's/^lib/cyg/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' 59600b0ce0bfSmrgm4_if([$1], [],[ 59610b0ce0bfSmrg sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"]) 59620b0ce0bfSmrg ;; 59630b0ce0bfSmrg mingw* | cegcc*) 59640b0ce0bfSmrg # MinGW DLLs use traditional 'lib' prefix 59650b0ce0bfSmrg soname_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' 59660b0ce0bfSmrg ;; 59670b0ce0bfSmrg pw32*) 59680b0ce0bfSmrg # pw32 DLLs use 'pw' prefix rather than 'lib' 59690b0ce0bfSmrg library_names_spec='`echo $libname | $SED -e 's/^lib/pw/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' 59700b0ce0bfSmrg ;; 59710b0ce0bfSmrg esac 59720b0ce0bfSmrg dynamic_linker='Win32 ld.exe' 59730b0ce0bfSmrg ;; 59741b12faf6Smrg 59750b0ce0bfSmrg *,cl* | *,icl*) 59760b0ce0bfSmrg # Native MSVC or ICC 59770b0ce0bfSmrg libname_spec='$name' 59780b0ce0bfSmrg soname_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' 59790b0ce0bfSmrg library_names_spec='$libname.dll.lib' 59801b12faf6Smrg 59810b0ce0bfSmrg case $build_os in 59820b0ce0bfSmrg mingw*) 59830b0ce0bfSmrg sys_lib_search_path_spec= 59840b0ce0bfSmrg lt_save_ifs=$IFS 59850b0ce0bfSmrg IFS=';' 59860b0ce0bfSmrg for lt_path in $LIB 59870b0ce0bfSmrg do 59880b0ce0bfSmrg IFS=$lt_save_ifs 59890b0ce0bfSmrg # Let DOS variable expansion print the short 8.3 style file name. 59900b0ce0bfSmrg lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` 59910b0ce0bfSmrg sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" 59920b0ce0bfSmrg done 59930b0ce0bfSmrg IFS=$lt_save_ifs 59940b0ce0bfSmrg # Convert to MSYS style. 59950b0ce0bfSmrg sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's|\\\\|/|g' -e 's| \\([[a-zA-Z]]\\):| /\\1|g' -e 's|^ ||'` 59960b0ce0bfSmrg ;; 59970b0ce0bfSmrg cygwin*) 59980b0ce0bfSmrg # Convert to unix form, then to dos form, then back to unix form 59990b0ce0bfSmrg # but this time dos style (no spaces!) so that the unix form looks 60000b0ce0bfSmrg # like /cygdrive/c/PROGRA~1:/cygdr... 60010b0ce0bfSmrg sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` 60020b0ce0bfSmrg sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` 60030b0ce0bfSmrg sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` 60040b0ce0bfSmrg ;; 60050b0ce0bfSmrg *) 60060b0ce0bfSmrg sys_lib_search_path_spec=$LIB 60070b0ce0bfSmrg if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then 60080b0ce0bfSmrg # It is most probably a Windows format PATH. 60090b0ce0bfSmrg sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` 60100b0ce0bfSmrg else 60110b0ce0bfSmrg sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` 60120b0ce0bfSmrg fi 60130b0ce0bfSmrg # FIXME: find the short name or the path components, as spaces are 60140b0ce0bfSmrg # common. (e.g. "Program Files" -> "PROGRA~1") 60150b0ce0bfSmrg ;; 60160b0ce0bfSmrg esac 60171b12faf6Smrg 60180b0ce0bfSmrg # DLL is installed to $(libdir)/../bin by postinstall_cmds 60190b0ce0bfSmrg postinstall_cmds='base_file=`basename \$file`~ 60200b0ce0bfSmrg dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ 60210b0ce0bfSmrg dldir=$destdir/`dirname \$dlpath`~ 60220b0ce0bfSmrg test -d \$dldir || mkdir -p \$dldir~ 60230b0ce0bfSmrg $install_prog $dir/$dlname \$dldir/$dlname' 60240b0ce0bfSmrg postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ 60250b0ce0bfSmrg dlpath=$dir/\$dldll~ 60260b0ce0bfSmrg $RM \$dlpath' 60270b0ce0bfSmrg shlibpath_overrides_runpath=yes 60280b0ce0bfSmrg dynamic_linker='Win32 link.exe' 60290b0ce0bfSmrg ;; 603032b578d3Smrg 60310b0ce0bfSmrg *) 60320b0ce0bfSmrg # Assume MSVC and ICC wrapper 60330b0ce0bfSmrg library_names_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext $libname.lib' 60340b0ce0bfSmrg dynamic_linker='Win32 ld.exe' 60350b0ce0bfSmrg ;; 60360b0ce0bfSmrg esac 60370b0ce0bfSmrg # FIXME: first we should search . and the directory the executable is in 60380b0ce0bfSmrg shlibpath_var=PATH 60390b0ce0bfSmrg ;; 604032b578d3Smrg 60410b0ce0bfSmrgdarwin* | rhapsody*) 60420b0ce0bfSmrg dynamic_linker="$host_os dyld" 60430b0ce0bfSmrg version_type=darwin 60440b0ce0bfSmrg need_lib_prefix=no 60450b0ce0bfSmrg need_version=no 60460b0ce0bfSmrg library_names_spec='$libname$release$major$shared_ext $libname$shared_ext' 60470b0ce0bfSmrg soname_spec='$libname$release$major$shared_ext' 60480b0ce0bfSmrg shlibpath_overrides_runpath=yes 60490b0ce0bfSmrg shlibpath_var=DYLD_LIBRARY_PATH 60500b0ce0bfSmrg shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' 60510b0ce0bfSmrgm4_if([$1], [],[ 60520b0ce0bfSmrg sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"]) 60530b0ce0bfSmrg sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' 60540b0ce0bfSmrg ;; 605532b578d3Smrg 60560b0ce0bfSmrgdgux*) 60570b0ce0bfSmrg version_type=linux # correct to gnu/linux during the next big refactor 60580b0ce0bfSmrg need_lib_prefix=no 60590b0ce0bfSmrg need_version=no 60600b0ce0bfSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 60610b0ce0bfSmrg soname_spec='$libname$release$shared_ext$major' 60620b0ce0bfSmrg shlibpath_var=LD_LIBRARY_PATH 60630b0ce0bfSmrg ;; 60641b12faf6Smrg 60650b0ce0bfSmrgfreebsd* | dragonfly* | midnightbsd*) 60660b0ce0bfSmrg # DragonFly does not have aout. When/if they implement a new 60670b0ce0bfSmrg # versioning mechanism, adjust this. 60680b0ce0bfSmrg if test -x /usr/bin/objformat; then 60690b0ce0bfSmrg objformat=`/usr/bin/objformat` 60700b0ce0bfSmrg else 60710b0ce0bfSmrg case $host_os in 60720b0ce0bfSmrg freebsd[[23]].*) objformat=aout ;; 60730b0ce0bfSmrg *) objformat=elf ;; 60740b0ce0bfSmrg esac 60750b0ce0bfSmrg fi 60760b0ce0bfSmrg version_type=freebsd-$objformat 60770b0ce0bfSmrg case $version_type in 60780b0ce0bfSmrg freebsd-elf*) 60790b0ce0bfSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 60800b0ce0bfSmrg soname_spec='$libname$release$shared_ext$major' 60810b0ce0bfSmrg need_version=no 60820b0ce0bfSmrg need_lib_prefix=no 60830b0ce0bfSmrg ;; 60840b0ce0bfSmrg freebsd-*) 60850b0ce0bfSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' 60860b0ce0bfSmrg need_version=yes 60870b0ce0bfSmrg ;; 60880b0ce0bfSmrg esac 60890b0ce0bfSmrg shlibpath_var=LD_LIBRARY_PATH 60900b0ce0bfSmrg case $host_os in 60910b0ce0bfSmrg freebsd2.*) 60920b0ce0bfSmrg shlibpath_overrides_runpath=yes 60930b0ce0bfSmrg ;; 60940b0ce0bfSmrg freebsd3.[[01]]* | freebsdelf3.[[01]]*) 60950b0ce0bfSmrg shlibpath_overrides_runpath=yes 60960b0ce0bfSmrg hardcode_into_libs=yes 60970b0ce0bfSmrg ;; 60980b0ce0bfSmrg freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \ 60990b0ce0bfSmrg freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1) 61000b0ce0bfSmrg shlibpath_overrides_runpath=no 61010b0ce0bfSmrg hardcode_into_libs=yes 61020b0ce0bfSmrg ;; 61030b0ce0bfSmrg *) # from 4.6 on, and DragonFly 61040b0ce0bfSmrg shlibpath_overrides_runpath=yes 61050b0ce0bfSmrg hardcode_into_libs=yes 61060b0ce0bfSmrg ;; 61070b0ce0bfSmrg esac 61080b0ce0bfSmrg ;; 610932b578d3Smrg 61100b0ce0bfSmrghaiku*) 61110b0ce0bfSmrg version_type=linux # correct to gnu/linux during the next big refactor 61120b0ce0bfSmrg need_lib_prefix=no 61130b0ce0bfSmrg need_version=no 61140b0ce0bfSmrg dynamic_linker="$host_os runtime_loader" 61150b0ce0bfSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 61160b0ce0bfSmrg soname_spec='$libname$release$shared_ext$major' 61170b0ce0bfSmrg shlibpath_var=LIBRARY_PATH 61180b0ce0bfSmrg shlibpath_overrides_runpath=no 61190b0ce0bfSmrg sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' 61200b0ce0bfSmrg hardcode_into_libs=yes 61210b0ce0bfSmrg ;; 612232b578d3Smrg 61230b0ce0bfSmrghpux9* | hpux10* | hpux11*) 61240b0ce0bfSmrg # Give a soname corresponding to the major version so that dld.sl refuses to 61250b0ce0bfSmrg # link against other versions. 61260b0ce0bfSmrg version_type=sunos 61270b0ce0bfSmrg need_lib_prefix=no 61280b0ce0bfSmrg need_version=no 61290b0ce0bfSmrg case $host_cpu in 61300b0ce0bfSmrg ia64*) 61310b0ce0bfSmrg shrext_cmds='.so' 61320b0ce0bfSmrg hardcode_into_libs=yes 61330b0ce0bfSmrg dynamic_linker="$host_os dld.so" 61340b0ce0bfSmrg shlibpath_var=LD_LIBRARY_PATH 61350b0ce0bfSmrg shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. 61360b0ce0bfSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 61370b0ce0bfSmrg soname_spec='$libname$release$shared_ext$major' 61380b0ce0bfSmrg if test 32 = "$HPUX_IA64_MODE"; then 61390b0ce0bfSmrg sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" 61400b0ce0bfSmrg sys_lib_dlsearch_path_spec=/usr/lib/hpux32 61410b0ce0bfSmrg else 61420b0ce0bfSmrg sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" 61430b0ce0bfSmrg sys_lib_dlsearch_path_spec=/usr/lib/hpux64 61440b0ce0bfSmrg fi 61450b0ce0bfSmrg ;; 61460b0ce0bfSmrg hppa*64*) 61470b0ce0bfSmrg shrext_cmds='.sl' 61480b0ce0bfSmrg hardcode_into_libs=yes 61490b0ce0bfSmrg dynamic_linker="$host_os dld.sl" 61500b0ce0bfSmrg shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH 61510b0ce0bfSmrg shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. 61520b0ce0bfSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 61530b0ce0bfSmrg soname_spec='$libname$release$shared_ext$major' 61540b0ce0bfSmrg sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" 61550b0ce0bfSmrg sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec 61560b0ce0bfSmrg ;; 61570b0ce0bfSmrg *) 61580b0ce0bfSmrg shrext_cmds='.sl' 61590b0ce0bfSmrg dynamic_linker="$host_os dld.sl" 61600b0ce0bfSmrg shlibpath_var=SHLIB_PATH 61610b0ce0bfSmrg shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH 61620b0ce0bfSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 61630b0ce0bfSmrg soname_spec='$libname$release$shared_ext$major' 61640b0ce0bfSmrg ;; 61650b0ce0bfSmrg esac 61660b0ce0bfSmrg # HP-UX runs *really* slowly unless shared libraries are mode 555, ... 61670b0ce0bfSmrg postinstall_cmds='chmod 555 $lib' 61680b0ce0bfSmrg # or fails outright, so override atomically: 61690b0ce0bfSmrg install_override_mode=555 61700b0ce0bfSmrg ;; 617132b578d3Smrg 61720b0ce0bfSmrginterix[[3-9]]*) 61730b0ce0bfSmrg version_type=linux # correct to gnu/linux during the next big refactor 61740b0ce0bfSmrg need_lib_prefix=no 61750b0ce0bfSmrg need_version=no 61760b0ce0bfSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 61770b0ce0bfSmrg soname_spec='$libname$release$shared_ext$major' 61780b0ce0bfSmrg dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' 61790b0ce0bfSmrg shlibpath_var=LD_LIBRARY_PATH 61800b0ce0bfSmrg shlibpath_overrides_runpath=no 61810b0ce0bfSmrg hardcode_into_libs=yes 61820b0ce0bfSmrg ;; 61831b12faf6Smrg 61840b0ce0bfSmrgirix5* | irix6* | nonstopux*) 61850b0ce0bfSmrg case $host_os in 61860b0ce0bfSmrg nonstopux*) version_type=nonstopux ;; 61870b0ce0bfSmrg *) 61880b0ce0bfSmrg if test yes = "$lt_cv_prog_gnu_ld"; then 61890b0ce0bfSmrg version_type=linux # correct to gnu/linux during the next big refactor 61900b0ce0bfSmrg else 61910b0ce0bfSmrg version_type=irix 61920b0ce0bfSmrg fi ;; 61930b0ce0bfSmrg esac 61940b0ce0bfSmrg need_lib_prefix=no 61950b0ce0bfSmrg need_version=no 61960b0ce0bfSmrg soname_spec='$libname$release$shared_ext$major' 61970b0ce0bfSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$release$shared_ext $libname$shared_ext' 61980b0ce0bfSmrg case $host_os in 61990b0ce0bfSmrg irix5* | nonstopux*) 62000b0ce0bfSmrg libsuff= shlibsuff= 62010b0ce0bfSmrg ;; 62020b0ce0bfSmrg *) 62030b0ce0bfSmrg case $LD in # libtool.m4 will add one of these switches to LD 62040b0ce0bfSmrg *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") 62050b0ce0bfSmrg libsuff= shlibsuff= libmagic=32-bit;; 62060b0ce0bfSmrg *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") 62070b0ce0bfSmrg libsuff=32 shlibsuff=N32 libmagic=N32;; 62080b0ce0bfSmrg *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") 62090b0ce0bfSmrg libsuff=64 shlibsuff=64 libmagic=64-bit;; 62100b0ce0bfSmrg *) libsuff= shlibsuff= libmagic=never-match;; 62110b0ce0bfSmrg esac 62120b0ce0bfSmrg ;; 62130b0ce0bfSmrg esac 62140b0ce0bfSmrg shlibpath_var=LD_LIBRARY${shlibsuff}_PATH 62150b0ce0bfSmrg shlibpath_overrides_runpath=no 62160b0ce0bfSmrg sys_lib_search_path_spec="/usr/lib$libsuff /lib$libsuff /usr/local/lib$libsuff" 62170b0ce0bfSmrg sys_lib_dlsearch_path_spec="/usr/lib$libsuff /lib$libsuff" 62180b0ce0bfSmrg hardcode_into_libs=yes 62190b0ce0bfSmrg ;; 62201b12faf6Smrg 62210b0ce0bfSmrg# No shared lib support for Linux oldld, aout, or coff. 62220b0ce0bfSmrglinux*oldld* | linux*aout* | linux*coff*) 62230b0ce0bfSmrg dynamic_linker=no 62240b0ce0bfSmrg ;; 62251b12faf6Smrg 62260b0ce0bfSmrglinux*android*) 62270b0ce0bfSmrg version_type=none # Android doesn't support versioned libraries. 62280b0ce0bfSmrg need_lib_prefix=no 62290b0ce0bfSmrg need_version=no 62300b0ce0bfSmrg library_names_spec='$libname$release$shared_ext' 62310b0ce0bfSmrg soname_spec='$libname$release$shared_ext' 62320b0ce0bfSmrg finish_cmds= 62330b0ce0bfSmrg shlibpath_var=LD_LIBRARY_PATH 62340b0ce0bfSmrg shlibpath_overrides_runpath=yes 623532b578d3Smrg 62360b0ce0bfSmrg # This implies no fast_install, which is unacceptable. 62370b0ce0bfSmrg # Some rework will be needed to allow for fast_install 62380b0ce0bfSmrg # before this can be enabled. 62390b0ce0bfSmrg hardcode_into_libs=yes 6240d31dbc53Smrg 62410b0ce0bfSmrg dynamic_linker='Android linker' 62420b0ce0bfSmrg # Don't embed -rpath directories since the linker doesn't support them. 62430b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 62440b0ce0bfSmrg ;; 6245d31dbc53Smrg 62460b0ce0bfSmrg# This must be glibc/ELF. 62470b0ce0bfSmrglinux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) 62480b0ce0bfSmrg version_type=linux # correct to gnu/linux during the next big refactor 62490b0ce0bfSmrg need_lib_prefix=no 62500b0ce0bfSmrg need_version=no 62510b0ce0bfSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 62520b0ce0bfSmrg soname_spec='$libname$release$shared_ext$major' 62530b0ce0bfSmrg finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' 62540b0ce0bfSmrg shlibpath_var=LD_LIBRARY_PATH 62550b0ce0bfSmrg shlibpath_overrides_runpath=no 6256d31dbc53Smrg 62570b0ce0bfSmrg # Some binutils ld are patched to set DT_RUNPATH 62580b0ce0bfSmrg AC_CACHE_VAL([lt_cv_shlibpath_overrides_runpath], 62590b0ce0bfSmrg [lt_cv_shlibpath_overrides_runpath=no 62600b0ce0bfSmrg save_LDFLAGS=$LDFLAGS 62610b0ce0bfSmrg save_libdir=$libdir 62620b0ce0bfSmrg eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \ 62630b0ce0bfSmrg LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\"" 62640b0ce0bfSmrg AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], 62650b0ce0bfSmrg [AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null], 62660b0ce0bfSmrg [lt_cv_shlibpath_overrides_runpath=yes])]) 62670b0ce0bfSmrg LDFLAGS=$save_LDFLAGS 62680b0ce0bfSmrg libdir=$save_libdir 62690b0ce0bfSmrg ]) 62700b0ce0bfSmrg shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath 6271d31dbc53Smrg 62720b0ce0bfSmrg # This implies no fast_install, which is unacceptable. 62730b0ce0bfSmrg # Some rework will be needed to allow for fast_install 62740b0ce0bfSmrg # before this can be enabled. 62750b0ce0bfSmrg hardcode_into_libs=yes 6276d31dbc53Smrg 62770b0ce0bfSmrg # Ideally, we could use ldconfig to report *all* directores which are 62780b0ce0bfSmrg # searched for libraries, however this is still not possible. Aside from not 62790b0ce0bfSmrg # being certain /sbin/ldconfig is available, command 62800b0ce0bfSmrg # 'ldconfig -N -X -v | grep ^/' on 64bit Fedora does not report /usr/lib64, 62810b0ce0bfSmrg # even though it is searched at run-time. Try to do the best guess by 62820b0ce0bfSmrg # appending ld.so.conf contents (and includes) to the search path. 62830b0ce0bfSmrg if test -f /etc/ld.so.conf; then 62840b0ce0bfSmrg 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' ' '` 62850b0ce0bfSmrg sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" 62860b0ce0bfSmrg fi 6287d31dbc53Smrg 62880b0ce0bfSmrg # We used to test for /lib/ld.so.1 and disable shared libraries on 62890b0ce0bfSmrg # powerpc, because MkLinux only supported shared libraries with the 62900b0ce0bfSmrg # GNU dynamic linker. Since this was broken with cross compilers, 62910b0ce0bfSmrg # most powerpc-linux boxes support dynamic linking these days and 62920b0ce0bfSmrg # people can always --disable-shared, the test was removed, and we 62930b0ce0bfSmrg # assume the GNU/Linux dynamic linker is in use. 62940b0ce0bfSmrg dynamic_linker='GNU/Linux ld.so' 62950b0ce0bfSmrg ;; 6296d31dbc53Smrg 62970b0ce0bfSmrgnetbsd*) 62980b0ce0bfSmrg version_type=sunos 62990b0ce0bfSmrg need_lib_prefix=no 63000b0ce0bfSmrg need_version=no 63010b0ce0bfSmrg if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then 63020b0ce0bfSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' 63030b0ce0bfSmrg finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' 63040b0ce0bfSmrg dynamic_linker='NetBSD (a.out) ld.so' 63050b0ce0bfSmrg else 63060b0ce0bfSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 63070b0ce0bfSmrg soname_spec='$libname$release$shared_ext$major' 63080b0ce0bfSmrg dynamic_linker='NetBSD ld.elf_so' 63090b0ce0bfSmrg fi 63100b0ce0bfSmrg shlibpath_var=LD_LIBRARY_PATH 63110b0ce0bfSmrg shlibpath_overrides_runpath=yes 63120b0ce0bfSmrg hardcode_into_libs=yes 63130b0ce0bfSmrg ;; 63141b12faf6Smrg 63150b0ce0bfSmrgnewsos6) 63160b0ce0bfSmrg version_type=linux # correct to gnu/linux during the next big refactor 63170b0ce0bfSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 63180b0ce0bfSmrg shlibpath_var=LD_LIBRARY_PATH 63190b0ce0bfSmrg shlibpath_overrides_runpath=yes 63200b0ce0bfSmrg ;; 63211b12faf6Smrg 63220b0ce0bfSmrg*nto* | *qnx*) 63230b0ce0bfSmrg version_type=qnx 63240b0ce0bfSmrg need_lib_prefix=no 63250b0ce0bfSmrg need_version=no 63260b0ce0bfSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 63270b0ce0bfSmrg soname_spec='$libname$release$shared_ext$major' 63280b0ce0bfSmrg shlibpath_var=LD_LIBRARY_PATH 63290b0ce0bfSmrg shlibpath_overrides_runpath=no 63300b0ce0bfSmrg hardcode_into_libs=yes 63310b0ce0bfSmrg dynamic_linker='ldqnx.so' 63320b0ce0bfSmrg ;; 63331b12faf6Smrg 63340b0ce0bfSmrgopenbsd* | bitrig*) 63350b0ce0bfSmrg version_type=sunos 63360b0ce0bfSmrg sys_lib_dlsearch_path_spec=/usr/lib 63370b0ce0bfSmrg need_lib_prefix=no 63380b0ce0bfSmrg if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then 63390b0ce0bfSmrg need_version=no 63400b0ce0bfSmrg else 63410b0ce0bfSmrg need_version=yes 63420b0ce0bfSmrg fi 63430b0ce0bfSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' 63440b0ce0bfSmrg finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' 63450b0ce0bfSmrg shlibpath_var=LD_LIBRARY_PATH 63460b0ce0bfSmrg shlibpath_overrides_runpath=yes 63470b0ce0bfSmrg ;; 63481b12faf6Smrg 63490b0ce0bfSmrgos2*) 63500b0ce0bfSmrg libname_spec='$name' 63510b0ce0bfSmrg version_type=windows 63520b0ce0bfSmrg shrext_cmds=.dll 63530b0ce0bfSmrg need_version=no 63540b0ce0bfSmrg need_lib_prefix=no 63550b0ce0bfSmrg # OS/2 can only load a DLL with a base name of 8 characters or less. 63560b0ce0bfSmrg soname_spec='`test -n "$os2dllname" && libname="$os2dllname"; 63570b0ce0bfSmrg v=$($ECHO $release$versuffix | tr -d .-); 63580b0ce0bfSmrg n=$($ECHO $libname | cut -b -$((8 - ${#v})) | tr . _); 63590b0ce0bfSmrg $ECHO $n$v`$shared_ext' 63600b0ce0bfSmrg library_names_spec='${libname}_dll.$libext' 63610b0ce0bfSmrg dynamic_linker='OS/2 ld.exe' 63620b0ce0bfSmrg shlibpath_var=BEGINLIBPATH 63630b0ce0bfSmrg sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" 63640b0ce0bfSmrg sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec 63650b0ce0bfSmrg postinstall_cmds='base_file=`basename \$file`~ 63660b0ce0bfSmrg dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; $ECHO \$dlname'\''`~ 63670b0ce0bfSmrg dldir=$destdir/`dirname \$dlpath`~ 63680b0ce0bfSmrg test -d \$dldir || mkdir -p \$dldir~ 63690b0ce0bfSmrg $install_prog $dir/$dlname \$dldir/$dlname~ 63700b0ce0bfSmrg chmod a+x \$dldir/$dlname~ 63710b0ce0bfSmrg if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then 63720b0ce0bfSmrg eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; 63730b0ce0bfSmrg fi' 63740b0ce0bfSmrg postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; $ECHO \$dlname'\''`~ 63750b0ce0bfSmrg dlpath=$dir/\$dldll~ 63760b0ce0bfSmrg $RM \$dlpath' 63770b0ce0bfSmrg ;; 6378d31dbc53Smrg 63790b0ce0bfSmrgosf3* | osf4* | osf5*) 63800b0ce0bfSmrg version_type=osf 63810b0ce0bfSmrg need_lib_prefix=no 63820b0ce0bfSmrg need_version=no 63830b0ce0bfSmrg soname_spec='$libname$release$shared_ext$major' 63840b0ce0bfSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 63850b0ce0bfSmrg shlibpath_var=LD_LIBRARY_PATH 63860b0ce0bfSmrg sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" 63870b0ce0bfSmrg sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec 63880b0ce0bfSmrg ;; 6389d31dbc53Smrg 63900b0ce0bfSmrgrdos*) 63910b0ce0bfSmrg dynamic_linker=no 63920b0ce0bfSmrg ;; 6393d31dbc53Smrg 63940b0ce0bfSmrgsolaris*) 63950b0ce0bfSmrg version_type=linux # correct to gnu/linux during the next big refactor 63960b0ce0bfSmrg need_lib_prefix=no 63970b0ce0bfSmrg need_version=no 63980b0ce0bfSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 63990b0ce0bfSmrg soname_spec='$libname$release$shared_ext$major' 64000b0ce0bfSmrg shlibpath_var=LD_LIBRARY_PATH 64010b0ce0bfSmrg shlibpath_overrides_runpath=yes 64020b0ce0bfSmrg hardcode_into_libs=yes 64030b0ce0bfSmrg # ldd complains unless libraries are executable 64040b0ce0bfSmrg postinstall_cmds='chmod +x $lib' 64050b0ce0bfSmrg ;; 64060b0ce0bfSmrg 64070b0ce0bfSmrgsunos4*) 64080b0ce0bfSmrg version_type=sunos 64090b0ce0bfSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' 64100b0ce0bfSmrg finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' 64110b0ce0bfSmrg shlibpath_var=LD_LIBRARY_PATH 64120b0ce0bfSmrg shlibpath_overrides_runpath=yes 64130b0ce0bfSmrg if test yes = "$with_gnu_ld"; then 64140b0ce0bfSmrg need_lib_prefix=no 64150b0ce0bfSmrg fi 64160b0ce0bfSmrg need_version=yes 64170b0ce0bfSmrg ;; 64180b0ce0bfSmrg 64190b0ce0bfSmrgsysv4 | sysv4.3*) 64200b0ce0bfSmrg version_type=linux # correct to gnu/linux during the next big refactor 64210b0ce0bfSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 64220b0ce0bfSmrg soname_spec='$libname$release$shared_ext$major' 64230b0ce0bfSmrg shlibpath_var=LD_LIBRARY_PATH 64240b0ce0bfSmrg case $host_vendor in 64250b0ce0bfSmrg sni) 64260b0ce0bfSmrg shlibpath_overrides_runpath=no 64270b0ce0bfSmrg need_lib_prefix=no 64280b0ce0bfSmrg runpath_var=LD_RUN_PATH 64290b0ce0bfSmrg ;; 64300b0ce0bfSmrg siemens) 64310b0ce0bfSmrg need_lib_prefix=no 64320b0ce0bfSmrg ;; 64330b0ce0bfSmrg motorola) 64340b0ce0bfSmrg need_lib_prefix=no 64350b0ce0bfSmrg need_version=no 64360b0ce0bfSmrg shlibpath_overrides_runpath=no 64370b0ce0bfSmrg sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' 64380b0ce0bfSmrg ;; 6439e35d4d8eSmrg esac 64400b0ce0bfSmrg ;; 6441e35d4d8eSmrg 64420b0ce0bfSmrgsysv4*MP*) 64430b0ce0bfSmrg if test -d /usr/nec; then 64440b0ce0bfSmrg version_type=linux # correct to gnu/linux during the next big refactor 64450b0ce0bfSmrg library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext' 64460b0ce0bfSmrg soname_spec='$libname$shared_ext.$major' 64470b0ce0bfSmrg shlibpath_var=LD_LIBRARY_PATH 64480b0ce0bfSmrg fi 64490b0ce0bfSmrg ;; 6450d31dbc53Smrg 64510b0ce0bfSmrgsysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) 64520b0ce0bfSmrg version_type=sco 64530b0ce0bfSmrg need_lib_prefix=no 64540b0ce0bfSmrg need_version=no 64550b0ce0bfSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext' 64560b0ce0bfSmrg soname_spec='$libname$release$shared_ext$major' 64570b0ce0bfSmrg shlibpath_var=LD_LIBRARY_PATH 64580b0ce0bfSmrg shlibpath_overrides_runpath=yes 64590b0ce0bfSmrg hardcode_into_libs=yes 64600b0ce0bfSmrg if test yes = "$with_gnu_ld"; then 64610b0ce0bfSmrg sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' 64620b0ce0bfSmrg else 64630b0ce0bfSmrg sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' 64640b0ce0bfSmrg case $host_os in 64650b0ce0bfSmrg sco3.2v5*) 64660b0ce0bfSmrg sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" 64670b0ce0bfSmrg ;; 64681b12faf6Smrg esac 64690b0ce0bfSmrg fi 64700b0ce0bfSmrg sys_lib_dlsearch_path_spec='/usr/lib' 64712a51b5beSmrg ;; 64721b12faf6Smrg 64730b0ce0bfSmrgtpf*) 64740b0ce0bfSmrg # TPF is a cross-target only. Preferred cross-host = GNU/Linux. 64750b0ce0bfSmrg version_type=linux # correct to gnu/linux during the next big refactor 64760b0ce0bfSmrg need_lib_prefix=no 64770b0ce0bfSmrg need_version=no 64780b0ce0bfSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 64790b0ce0bfSmrg shlibpath_var=LD_LIBRARY_PATH 64800b0ce0bfSmrg shlibpath_overrides_runpath=no 64810b0ce0bfSmrg hardcode_into_libs=yes 64822a51b5beSmrg ;; 64831b12faf6Smrg 64840b0ce0bfSmrguts4*) 64850b0ce0bfSmrg version_type=linux # correct to gnu/linux during the next big refactor 64860b0ce0bfSmrg library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' 64870b0ce0bfSmrg soname_spec='$libname$release$shared_ext$major' 64880b0ce0bfSmrg shlibpath_var=LD_LIBRARY_PATH 64890b0ce0bfSmrg ;; 649032b578d3Smrg 64910b0ce0bfSmrg*) 64920b0ce0bfSmrg dynamic_linker=no 6493e35d4d8eSmrg ;; 6494e35d4d8eSmrgesac 64950b0ce0bfSmrgAC_MSG_RESULT([$dynamic_linker]) 64960b0ce0bfSmrgtest no = "$dynamic_linker" && can_build_shared=no 64971b12faf6Smrg 64980b0ce0bfSmrgvariables_saved_for_relink="PATH $shlibpath_var $runpath_var" 64990b0ce0bfSmrgif test yes = "$GCC"; then 65000b0ce0bfSmrg variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" 65012a51b5beSmrgfi 650232b578d3Smrg 65030b0ce0bfSmrgif test set = "${lt_cv_sys_lib_search_path_spec+set}"; then 65040b0ce0bfSmrg sys_lib_search_path_spec=$lt_cv_sys_lib_search_path_spec 6505e35d4d8eSmrgfi 65061b12faf6Smrg 65070b0ce0bfSmrgif test set = "${lt_cv_sys_lib_dlsearch_path_spec+set}"; then 65080b0ce0bfSmrg sys_lib_dlsearch_path_spec=$lt_cv_sys_lib_dlsearch_path_spec 65090b0ce0bfSmrgfi 65101b12faf6Smrg 65110b0ce0bfSmrg# remember unaugmented sys_lib_dlsearch_path content for libtool script decls... 65120b0ce0bfSmrgconfigure_time_dlsearch_path=$sys_lib_dlsearch_path_spec 65131b12faf6Smrg 65140b0ce0bfSmrg# ... but it needs LT_SYS_LIBRARY_PATH munging for other configure-time code 65150b0ce0bfSmrgfunc_munge_path_list sys_lib_dlsearch_path_spec "$LT_SYS_LIBRARY_PATH" 65161b12faf6Smrg 65170b0ce0bfSmrg# to be used as default LT_SYS_LIBRARY_PATH value in generated libtool 65180b0ce0bfSmrgconfigure_time_lt_sys_library_path=$LT_SYS_LIBRARY_PATH 65191b12faf6Smrg 65200b0ce0bfSmrg_LT_DECL([], [variables_saved_for_relink], [1], 65210b0ce0bfSmrg [Variables whose values should be saved in libtool wrapper scripts and 65220b0ce0bfSmrg restored at link time]) 65230b0ce0bfSmrg_LT_DECL([], [need_lib_prefix], [0], 65240b0ce0bfSmrg [Do we need the "lib" prefix for modules?]) 65250b0ce0bfSmrg_LT_DECL([], [need_version], [0], [Do we need a version for libraries?]) 65260b0ce0bfSmrg_LT_DECL([], [version_type], [0], [Library versioning type]) 65270b0ce0bfSmrg_LT_DECL([], [runpath_var], [0], [Shared library runtime path variable]) 65280b0ce0bfSmrg_LT_DECL([], [shlibpath_var], [0],[Shared library path variable]) 65290b0ce0bfSmrg_LT_DECL([], [shlibpath_overrides_runpath], [0], 65300b0ce0bfSmrg [Is shlibpath searched before the hard-coded library search path?]) 65310b0ce0bfSmrg_LT_DECL([], [libname_spec], [1], [Format of library name prefix]) 65320b0ce0bfSmrg_LT_DECL([], [library_names_spec], [1], 65330b0ce0bfSmrg [[List of archive names. First name is the real one, the rest are links. 65340b0ce0bfSmrg The last name is the one that the linker finds with -lNAME]]) 65350b0ce0bfSmrg_LT_DECL([], [soname_spec], [1], 65360b0ce0bfSmrg [[The coded name of the library, if different from the real name]]) 65370b0ce0bfSmrg_LT_DECL([], [install_override_mode], [1], 65380b0ce0bfSmrg [Permission mode override for installation of shared libraries]) 65390b0ce0bfSmrg_LT_DECL([], [postinstall_cmds], [2], 65400b0ce0bfSmrg [Command to use after installation of a shared archive]) 65410b0ce0bfSmrg_LT_DECL([], [postuninstall_cmds], [2], 65420b0ce0bfSmrg [Command to use after uninstallation of a shared archive]) 65430b0ce0bfSmrg_LT_DECL([], [finish_cmds], [2], 65440b0ce0bfSmrg [Commands used to finish a libtool library installation in a directory]) 65450b0ce0bfSmrg_LT_DECL([], [finish_eval], [1], 65460b0ce0bfSmrg [[As "finish_cmds", except a single script fragment to be evaled but 65470b0ce0bfSmrg not shown]]) 65480b0ce0bfSmrg_LT_DECL([], [hardcode_into_libs], [0], 65490b0ce0bfSmrg [Whether we should hardcode library paths into libraries]) 65500b0ce0bfSmrg_LT_DECL([], [sys_lib_search_path_spec], [2], 65510b0ce0bfSmrg [Compile-time system search path for libraries]) 65520b0ce0bfSmrg_LT_DECL([sys_lib_dlsearch_path_spec], [configure_time_dlsearch_path], [2], 65530b0ce0bfSmrg [Detected run-time system search path for libraries]) 65540b0ce0bfSmrg_LT_DECL([], [configure_time_lt_sys_library_path], [2], 65550b0ce0bfSmrg [Explicit LT_SYS_LIBRARY_PATH set during ./configure time]) 65560b0ce0bfSmrg])# _LT_SYS_DYNAMIC_LINKER 655732b578d3Smrg 65581b12faf6Smrg 65590b0ce0bfSmrg# _LT_PATH_TOOL_PREFIX(TOOL) 65600b0ce0bfSmrg# -------------------------- 65610b0ce0bfSmrg# find a file program that can recognize shared library 65620b0ce0bfSmrgAC_DEFUN([_LT_PATH_TOOL_PREFIX], 65630b0ce0bfSmrg[m4_require([_LT_DECL_EGREP])dnl 65640b0ce0bfSmrgAC_MSG_CHECKING([for $1]) 65650b0ce0bfSmrgAC_CACHE_VAL(lt_cv_path_MAGIC_CMD, 65660b0ce0bfSmrg[case $MAGIC_CMD in 65670b0ce0bfSmrg[[\\/*] | ?:[\\/]*]) 65680b0ce0bfSmrg lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path. 65690b0ce0bfSmrg ;; 65700b0ce0bfSmrg*) 65710b0ce0bfSmrg lt_save_MAGIC_CMD=$MAGIC_CMD 65720b0ce0bfSmrg lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR 65730b0ce0bfSmrgdnl $ac_dummy forces splitting on constant user-supplied paths. 65740b0ce0bfSmrgdnl POSIX.2 word splitting is done only on the output of word expansions, 65750b0ce0bfSmrgdnl not every word. This closes a longstanding sh security hole. 65760b0ce0bfSmrg ac_dummy="m4_if([$2], , $PATH, [$2])" 65770b0ce0bfSmrg for ac_dir in $ac_dummy; do 65780b0ce0bfSmrg IFS=$lt_save_ifs 65790b0ce0bfSmrg test -z "$ac_dir" && ac_dir=. 65800b0ce0bfSmrg if test -f "$ac_dir/$1"; then 65810b0ce0bfSmrg lt_cv_path_MAGIC_CMD=$ac_dir/"$1" 65820b0ce0bfSmrg if test -n "$file_magic_test_file"; then 65830b0ce0bfSmrg case $deplibs_check_method in 65840b0ce0bfSmrg "file_magic "*) 65850b0ce0bfSmrg file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` 65860b0ce0bfSmrg MAGIC_CMD=$lt_cv_path_MAGIC_CMD 65870b0ce0bfSmrg if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | 65880b0ce0bfSmrg $EGREP "$file_magic_regex" > /dev/null; then 65890b0ce0bfSmrg : 65900b0ce0bfSmrg else 65910b0ce0bfSmrg cat <<_LT_EOF 1>&2 65921b12faf6Smrg 65930b0ce0bfSmrg*** Warning: the command libtool uses to detect shared libraries, 65940b0ce0bfSmrg*** $file_magic_cmd, produces output that libtool cannot recognize. 65950b0ce0bfSmrg*** The result is that libtool may fail to recognize shared libraries 65960b0ce0bfSmrg*** as such. This will affect the creation of libtool libraries that 65970b0ce0bfSmrg*** depend on shared libraries, but programs linked with such libtool 65980b0ce0bfSmrg*** libraries will work regardless of this problem. Nevertheless, you 65990b0ce0bfSmrg*** may want to report the problem to your system manager and/or to 66000b0ce0bfSmrg*** bug-libtool@gnu.org 66011b12faf6Smrg 66020b0ce0bfSmrg_LT_EOF 66030b0ce0bfSmrg fi ;; 66040b0ce0bfSmrg esac 66050b0ce0bfSmrg fi 66060b0ce0bfSmrg break 66070b0ce0bfSmrg fi 66080b0ce0bfSmrg done 66090b0ce0bfSmrg IFS=$lt_save_ifs 66100b0ce0bfSmrg MAGIC_CMD=$lt_save_MAGIC_CMD 66110b0ce0bfSmrg ;; 66120b0ce0bfSmrgesac]) 66130b0ce0bfSmrgMAGIC_CMD=$lt_cv_path_MAGIC_CMD 66140b0ce0bfSmrgif test -n "$MAGIC_CMD"; then 66150b0ce0bfSmrg AC_MSG_RESULT($MAGIC_CMD) 66160b0ce0bfSmrgelse 66170b0ce0bfSmrg AC_MSG_RESULT(no) 66180b0ce0bfSmrgfi 66190b0ce0bfSmrg_LT_DECL([], [MAGIC_CMD], [0], 66200b0ce0bfSmrg [Used to examine libraries when file_magic_cmd begins with "file"])dnl 66210b0ce0bfSmrg])# _LT_PATH_TOOL_PREFIX 66221b12faf6Smrg 66230b0ce0bfSmrg# Old name: 66240b0ce0bfSmrgAU_ALIAS([AC_PATH_TOOL_PREFIX], [_LT_PATH_TOOL_PREFIX]) 66250b0ce0bfSmrgdnl aclocal-1.4 backwards compatibility: 66260b0ce0bfSmrgdnl AC_DEFUN([AC_PATH_TOOL_PREFIX], []) 66271b12faf6Smrg 66281b12faf6Smrg 66290b0ce0bfSmrg# _LT_PATH_MAGIC 66300b0ce0bfSmrg# -------------- 66310b0ce0bfSmrg# find a file program that can recognize a shared library 66320b0ce0bfSmrgm4_defun([_LT_PATH_MAGIC], 66330b0ce0bfSmrg[_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH) 66340b0ce0bfSmrgif test -z "$lt_cv_path_MAGIC_CMD"; then 66350b0ce0bfSmrg if test -n "$ac_tool_prefix"; then 66360b0ce0bfSmrg _LT_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH) 66370b0ce0bfSmrg else 66380b0ce0bfSmrg MAGIC_CMD=: 66390b0ce0bfSmrg fi 66400b0ce0bfSmrgfi 66410b0ce0bfSmrg])# _LT_PATH_MAGIC 664232b578d3Smrg 664332b578d3Smrg 66440b0ce0bfSmrg# LT_PATH_LD 66450b0ce0bfSmrg# ---------- 66460b0ce0bfSmrg# find the pathname to the GNU or non-GNU linker 66470b0ce0bfSmrgAC_DEFUN([LT_PATH_LD], 66480b0ce0bfSmrg[AC_REQUIRE([AC_PROG_CC])dnl 66490b0ce0bfSmrgAC_REQUIRE([AC_CANONICAL_HOST])dnl 66500b0ce0bfSmrgAC_REQUIRE([AC_CANONICAL_BUILD])dnl 66510b0ce0bfSmrgm4_require([_LT_DECL_SED])dnl 66520b0ce0bfSmrgm4_require([_LT_DECL_EGREP])dnl 66530b0ce0bfSmrgm4_require([_LT_PROG_ECHO_BACKSLASH])dnl 665432b578d3Smrg 66550b0ce0bfSmrgAC_ARG_WITH([gnu-ld], 66560b0ce0bfSmrg [AS_HELP_STRING([--with-gnu-ld], 66570b0ce0bfSmrg [assume the C compiler uses GNU ld @<:@default=no@:>@])], 66580b0ce0bfSmrg [test no = "$withval" || with_gnu_ld=yes], 66590b0ce0bfSmrg [with_gnu_ld=no])dnl 666032b578d3Smrg 66610b0ce0bfSmrgac_prog=ld 66620b0ce0bfSmrgif test yes = "$GCC"; then 66630b0ce0bfSmrg # Check if gcc -print-prog-name=ld gives a path. 66640b0ce0bfSmrg AC_MSG_CHECKING([for ld used by $CC]) 66650b0ce0bfSmrg case $host in 66660b0ce0bfSmrg *-*-mingw*) 66670b0ce0bfSmrg # gcc leaves a trailing carriage return, which upsets mingw 66680b0ce0bfSmrg ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; 66690b0ce0bfSmrg *) 66700b0ce0bfSmrg ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; 66710b0ce0bfSmrg esac 66720b0ce0bfSmrg case $ac_prog in 66730b0ce0bfSmrg # Accept absolute paths. 66740b0ce0bfSmrg [[\\/]]* | ?:[[\\/]]*) 66750b0ce0bfSmrg re_direlt='/[[^/]][[^/]]*/\.\./' 66760b0ce0bfSmrg # Canonicalize the pathname of ld 66770b0ce0bfSmrg ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` 66780b0ce0bfSmrg while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do 66790b0ce0bfSmrg ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` 66800b0ce0bfSmrg done 66810b0ce0bfSmrg test -z "$LD" && LD=$ac_prog 66820b0ce0bfSmrg ;; 66830b0ce0bfSmrg "") 66840b0ce0bfSmrg # If it fails, then pretend we aren't using GCC. 66850b0ce0bfSmrg ac_prog=ld 66860b0ce0bfSmrg ;; 66870b0ce0bfSmrg *) 66880b0ce0bfSmrg # If it is relative, then search for the first ld in PATH. 66890b0ce0bfSmrg with_gnu_ld=unknown 66900b0ce0bfSmrg ;; 66910b0ce0bfSmrg esac 66920b0ce0bfSmrgelif test yes = "$with_gnu_ld"; then 66930b0ce0bfSmrg AC_MSG_CHECKING([for GNU ld]) 66940b0ce0bfSmrgelse 66950b0ce0bfSmrg AC_MSG_CHECKING([for non-GNU ld]) 66960b0ce0bfSmrgfi 66970b0ce0bfSmrgAC_CACHE_VAL(lt_cv_path_LD, 66980b0ce0bfSmrg[if test -z "$LD"; then 66990b0ce0bfSmrg lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR 67000b0ce0bfSmrg for ac_dir in $PATH; do 67010b0ce0bfSmrg IFS=$lt_save_ifs 67020b0ce0bfSmrg test -z "$ac_dir" && ac_dir=. 67030b0ce0bfSmrg if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then 67040b0ce0bfSmrg lt_cv_path_LD=$ac_dir/$ac_prog 67050b0ce0bfSmrg # Check to see if the program is GNU ld. I'd rather use --version, 67060b0ce0bfSmrg # but apparently some variants of GNU ld only accept -v. 67070b0ce0bfSmrg # Break only if it was the GNU/non-GNU ld that we prefer. 67080b0ce0bfSmrg case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in 67090b0ce0bfSmrg *GNU* | *'with BFD'*) 67100b0ce0bfSmrg test no != "$with_gnu_ld" && break 67110b0ce0bfSmrg ;; 67120b0ce0bfSmrg *) 67130b0ce0bfSmrg test yes != "$with_gnu_ld" && break 67140b0ce0bfSmrg ;; 67150b0ce0bfSmrg esac 67160b0ce0bfSmrg fi 67170b0ce0bfSmrg done 67180b0ce0bfSmrg IFS=$lt_save_ifs 67190b0ce0bfSmrgelse 67200b0ce0bfSmrg lt_cv_path_LD=$LD # Let the user override the test with a path. 67210b0ce0bfSmrgfi]) 67220b0ce0bfSmrgLD=$lt_cv_path_LD 67230b0ce0bfSmrgif test -n "$LD"; then 67240b0ce0bfSmrg AC_MSG_RESULT($LD) 67250b0ce0bfSmrgelse 67260b0ce0bfSmrg AC_MSG_RESULT(no) 67270b0ce0bfSmrgfi 67280b0ce0bfSmrgtest -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH]) 67290b0ce0bfSmrg_LT_PATH_LD_GNU 67300b0ce0bfSmrgAC_SUBST([LD]) 673132b578d3Smrg 67320b0ce0bfSmrg_LT_TAGDECL([], [LD], [1], [The linker used to build libraries]) 67330b0ce0bfSmrg])# LT_PATH_LD 67341b12faf6Smrg 67350b0ce0bfSmrg# Old names: 67360b0ce0bfSmrgAU_ALIAS([AM_PROG_LD], [LT_PATH_LD]) 67370b0ce0bfSmrgAU_ALIAS([AC_PROG_LD], [LT_PATH_LD]) 67380b0ce0bfSmrgdnl aclocal-1.4 backwards compatibility: 67390b0ce0bfSmrgdnl AC_DEFUN([AM_PROG_LD], []) 67400b0ce0bfSmrgdnl AC_DEFUN([AC_PROG_LD], []) 67411b12faf6Smrg 67421b12faf6Smrg 67430b0ce0bfSmrg# _LT_PATH_LD_GNU 67440b0ce0bfSmrg#- -------------- 67450b0ce0bfSmrgm4_defun([_LT_PATH_LD_GNU], 67460b0ce0bfSmrg[AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld, 67470b0ce0bfSmrg[# I'd rather use --version here, but apparently some GNU lds only accept -v. 67480b0ce0bfSmrgcase `$LD -v 2>&1 </dev/null` in 67490b0ce0bfSmrg*GNU* | *'with BFD'*) 67500b0ce0bfSmrg lt_cv_prog_gnu_ld=yes 67510b0ce0bfSmrg ;; 67520b0ce0bfSmrg*) 67530b0ce0bfSmrg lt_cv_prog_gnu_ld=no 67540b0ce0bfSmrg ;; 67550b0ce0bfSmrgesac]) 67560b0ce0bfSmrgwith_gnu_ld=$lt_cv_prog_gnu_ld 67570b0ce0bfSmrg])# _LT_PATH_LD_GNU 675832b578d3Smrg 675932b578d3Smrg 67600b0ce0bfSmrg# _LT_CMD_RELOAD 67610b0ce0bfSmrg# -------------- 67620b0ce0bfSmrg# find reload flag for linker 67630b0ce0bfSmrg# -- PORTME Some linkers may need a different reload flag. 67640b0ce0bfSmrgm4_defun([_LT_CMD_RELOAD], 67650b0ce0bfSmrg[AC_CACHE_CHECK([for $LD option to reload object files], 67660b0ce0bfSmrg lt_cv_ld_reload_flag, 67670b0ce0bfSmrg [lt_cv_ld_reload_flag='-r']) 67680b0ce0bfSmrgreload_flag=$lt_cv_ld_reload_flag 67690b0ce0bfSmrgcase $reload_flag in 67700b0ce0bfSmrg"" | " "*) ;; 67710b0ce0bfSmrg*) reload_flag=" $reload_flag" ;; 67720b0ce0bfSmrgesac 67730b0ce0bfSmrgreload_cmds='$LD$reload_flag -o $output$reload_objs' 67740b0ce0bfSmrgcase $host_os in 67750b0ce0bfSmrg cygwin* | mingw* | pw32* | cegcc*) 67760b0ce0bfSmrg if test yes != "$GCC"; then 67770b0ce0bfSmrg reload_cmds=false 67780b0ce0bfSmrg fi 67790b0ce0bfSmrg ;; 67800b0ce0bfSmrg darwin*) 67810b0ce0bfSmrg if test yes = "$GCC"; then 67820b0ce0bfSmrg reload_cmds='$LTCC $LTCFLAGS -nostdlib $wl-r -o $output$reload_objs' 67830b0ce0bfSmrg else 67840b0ce0bfSmrg reload_cmds='$LD$reload_flag -o $output$reload_objs' 67850b0ce0bfSmrg fi 67860b0ce0bfSmrg ;; 67870b0ce0bfSmrgesac 67880b0ce0bfSmrg_LT_TAGDECL([], [reload_flag], [1], [How to create reloadable object files])dnl 67890b0ce0bfSmrg_LT_TAGDECL([], [reload_cmds], [2])dnl 67900b0ce0bfSmrg])# _LT_CMD_RELOAD 679132b578d3Smrg 6792d31dbc53Smrg 67930b0ce0bfSmrg# _LT_PATH_DD 67940b0ce0bfSmrg# ----------- 67950b0ce0bfSmrg# find a working dd 67960b0ce0bfSmrgm4_defun([_LT_PATH_DD], 67970b0ce0bfSmrg[AC_CACHE_CHECK([for a working dd], [ac_cv_path_lt_DD], 67980b0ce0bfSmrg[printf 0123456789abcdef0123456789abcdef >conftest.i 67990b0ce0bfSmrgcat conftest.i conftest.i >conftest2.i 68000b0ce0bfSmrg: ${lt_DD:=$DD} 68010b0ce0bfSmrgAC_PATH_PROGS_FEATURE_CHECK([lt_DD], [dd], 68020b0ce0bfSmrg[if "$ac_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then 68030b0ce0bfSmrg cmp -s conftest.i conftest.out \ 68040b0ce0bfSmrg && ac_cv_path_lt_DD="$ac_path_lt_DD" ac_path_lt_DD_found=: 68050b0ce0bfSmrgfi]) 68060b0ce0bfSmrgrm -f conftest.i conftest2.i conftest.out]) 68070b0ce0bfSmrg])# _LT_PATH_DD 6808d31dbc53Smrg 6809d31dbc53Smrg 68100b0ce0bfSmrg# _LT_CMD_TRUNCATE 68110b0ce0bfSmrg# ---------------- 68120b0ce0bfSmrg# find command to truncate a binary pipe 68130b0ce0bfSmrgm4_defun([_LT_CMD_TRUNCATE], 68140b0ce0bfSmrg[m4_require([_LT_PATH_DD]) 68150b0ce0bfSmrgAC_CACHE_CHECK([how to truncate binary pipes], [lt_cv_truncate_bin], 68160b0ce0bfSmrg[printf 0123456789abcdef0123456789abcdef >conftest.i 68170b0ce0bfSmrgcat conftest.i conftest.i >conftest2.i 68180b0ce0bfSmrglt_cv_truncate_bin= 68190b0ce0bfSmrgif "$ac_cv_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then 68200b0ce0bfSmrg cmp -s conftest.i conftest.out \ 68210b0ce0bfSmrg && lt_cv_truncate_bin="$ac_cv_path_lt_DD bs=4096 count=1" 68220b0ce0bfSmrgfi 68230b0ce0bfSmrgrm -f conftest.i conftest2.i conftest.out 68240b0ce0bfSmrgtest -z "$lt_cv_truncate_bin" && lt_cv_truncate_bin="$SED -e 4q"]) 68250b0ce0bfSmrg_LT_DECL([lt_truncate_bin], [lt_cv_truncate_bin], [1], 68260b0ce0bfSmrg [Command to truncate a binary pipe]) 68270b0ce0bfSmrg])# _LT_CMD_TRUNCATE 6828d31dbc53Smrg 68292a51b5beSmrg 68300b0ce0bfSmrg# _LT_CHECK_MAGIC_METHOD 68310b0ce0bfSmrg# ---------------------- 68320b0ce0bfSmrg# how to check for library dependencies 68330b0ce0bfSmrg# -- PORTME fill in with the dynamic library characteristics 68340b0ce0bfSmrgm4_defun([_LT_CHECK_MAGIC_METHOD], 68350b0ce0bfSmrg[m4_require([_LT_DECL_EGREP]) 68360b0ce0bfSmrgm4_require([_LT_DECL_OBJDUMP]) 68370b0ce0bfSmrgAC_CACHE_CHECK([how to recognize dependent libraries], 68380b0ce0bfSmrglt_cv_deplibs_check_method, 68390b0ce0bfSmrg[lt_cv_file_magic_cmd='$MAGIC_CMD' 68400b0ce0bfSmrglt_cv_file_magic_test_file= 68410b0ce0bfSmrglt_cv_deplibs_check_method='unknown' 68420b0ce0bfSmrg# Need to set the preceding variable on all platforms that support 68430b0ce0bfSmrg# interlibrary dependencies. 68440b0ce0bfSmrg# 'none' -- dependencies not supported. 68450b0ce0bfSmrg# 'unknown' -- same as none, but documents that we really don't know. 68460b0ce0bfSmrg# 'pass_all' -- all dependencies passed with no checks. 68470b0ce0bfSmrg# 'test_compile' -- check by making test program. 68480b0ce0bfSmrg# 'file_magic [[regex]]' -- check by looking for files in library path 68490b0ce0bfSmrg# that responds to the $file_magic_cmd with a given extended regex. 68500b0ce0bfSmrg# If you have 'file' or equivalent on your system and you're not sure 68510b0ce0bfSmrg# whether 'pass_all' will *always* work, you probably want this one. 68522a51b5beSmrg 68530b0ce0bfSmrgcase $host_os in 68540b0ce0bfSmrgaix[[4-9]]*) 68550b0ce0bfSmrg lt_cv_deplibs_check_method=pass_all 68560b0ce0bfSmrg ;; 68572a51b5beSmrg 68580b0ce0bfSmrgbeos*) 68590b0ce0bfSmrg lt_cv_deplibs_check_method=pass_all 68600b0ce0bfSmrg ;; 6861e35d4d8eSmrg 68620b0ce0bfSmrgbsdi[[45]]*) 68630b0ce0bfSmrg lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)' 68640b0ce0bfSmrg lt_cv_file_magic_cmd='$FILECMD -L' 68650b0ce0bfSmrg lt_cv_file_magic_test_file=/shlib/libc.so 68660b0ce0bfSmrg ;; 6867e35d4d8eSmrg 68680b0ce0bfSmrgcygwin*) 68690b0ce0bfSmrg # func_win32_libid is a shell function defined in ltmain.sh 68700b0ce0bfSmrg lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' 68710b0ce0bfSmrg lt_cv_file_magic_cmd='func_win32_libid' 68720b0ce0bfSmrg ;; 6873e35d4d8eSmrg 68740b0ce0bfSmrgmingw* | pw32*) 68750b0ce0bfSmrg # Base MSYS/MinGW do not provide the 'file' command needed by 68760b0ce0bfSmrg # func_win32_libid shell function, so use a weaker test based on 'objdump', 68770b0ce0bfSmrg # unless we find 'file', for example because we are cross-compiling. 68780b0ce0bfSmrg if ( file / ) >/dev/null 2>&1; then 68790b0ce0bfSmrg lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' 68800b0ce0bfSmrg lt_cv_file_magic_cmd='func_win32_libid' 68810b0ce0bfSmrg else 68820b0ce0bfSmrg # Keep this pattern in sync with the one in func_win32_libid. 68830b0ce0bfSmrg lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' 68840b0ce0bfSmrg lt_cv_file_magic_cmd='$OBJDUMP -f' 68850b0ce0bfSmrg fi 68860b0ce0bfSmrg ;; 68871b12faf6Smrg 68880b0ce0bfSmrgcegcc*) 68890b0ce0bfSmrg # use the weaker test based on 'objdump'. See mingw*. 68900b0ce0bfSmrg lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?' 68910b0ce0bfSmrg lt_cv_file_magic_cmd='$OBJDUMP -f' 68920b0ce0bfSmrg ;; 68932a51b5beSmrg 68940b0ce0bfSmrgdarwin* | rhapsody*) 68950b0ce0bfSmrg lt_cv_deplibs_check_method=pass_all 68960b0ce0bfSmrg ;; 6897d31dbc53Smrg 68980b0ce0bfSmrgfreebsd* | dragonfly* | midnightbsd*) 68990b0ce0bfSmrg if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then 69000b0ce0bfSmrg case $host_cpu in 69010b0ce0bfSmrg i*86 ) 69020b0ce0bfSmrg # Not sure whether the presence of OpenBSD here was a mistake. 69030b0ce0bfSmrg # Let's accept both of them until this is cleared up. 69040b0ce0bfSmrg lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library' 69050b0ce0bfSmrg lt_cv_file_magic_cmd=$FILECMD 69060b0ce0bfSmrg lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` 69070b0ce0bfSmrg ;; 69080b0ce0bfSmrg esac 69090b0ce0bfSmrg else 69100b0ce0bfSmrg lt_cv_deplibs_check_method=pass_all 69110b0ce0bfSmrg fi 69120b0ce0bfSmrg ;; 69131b12faf6Smrg 69140b0ce0bfSmrghaiku*) 69150b0ce0bfSmrg lt_cv_deplibs_check_method=pass_all 69160b0ce0bfSmrg ;; 6917d31dbc53Smrg 69180b0ce0bfSmrghpux10.20* | hpux11*) 69190b0ce0bfSmrg lt_cv_file_magic_cmd=$FILECMD 69200b0ce0bfSmrg case $host_cpu in 69210b0ce0bfSmrg ia64*) 69220b0ce0bfSmrg lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64' 69230b0ce0bfSmrg lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so 69240b0ce0bfSmrg ;; 69250b0ce0bfSmrg hppa*64*) 69260b0ce0bfSmrg [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]'] 69270b0ce0bfSmrg lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl 69280b0ce0bfSmrg ;; 69290b0ce0bfSmrg *) 69300b0ce0bfSmrg lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]]\.[[0-9]]) shared library' 69310b0ce0bfSmrg lt_cv_file_magic_test_file=/usr/lib/libc.sl 69320b0ce0bfSmrg ;; 69330b0ce0bfSmrg esac 69340b0ce0bfSmrg ;; 6935d31dbc53Smrg 69360b0ce0bfSmrginterix[[3-9]]*) 69370b0ce0bfSmrg # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here 69380b0ce0bfSmrg lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$' 69390b0ce0bfSmrg ;; 6940d31dbc53Smrg 69410b0ce0bfSmrgirix5* | irix6* | nonstopux*) 69420b0ce0bfSmrg case $LD in 69430b0ce0bfSmrg *-32|*"-32 ") libmagic=32-bit;; 69440b0ce0bfSmrg *-n32|*"-n32 ") libmagic=N32;; 69450b0ce0bfSmrg *-64|*"-64 ") libmagic=64-bit;; 69460b0ce0bfSmrg *) libmagic=never-match;; 69470b0ce0bfSmrg esac 69480b0ce0bfSmrg lt_cv_deplibs_check_method=pass_all 69490b0ce0bfSmrg ;; 6950d31dbc53Smrg 69510b0ce0bfSmrg# This must be glibc/ELF. 69520b0ce0bfSmrglinux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) 69530b0ce0bfSmrg lt_cv_deplibs_check_method=pass_all 69540b0ce0bfSmrg ;; 6955d31dbc53Smrg 69560b0ce0bfSmrgnetbsd*) 69570b0ce0bfSmrg if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then 69580b0ce0bfSmrg lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' 69590b0ce0bfSmrg else 69600b0ce0bfSmrg lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$' 69610b0ce0bfSmrg fi 69620b0ce0bfSmrg ;; 6963d31dbc53Smrg 69640b0ce0bfSmrgnewos6*) 69650b0ce0bfSmrg lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)' 69660b0ce0bfSmrg lt_cv_file_magic_cmd=$FILECMD 69670b0ce0bfSmrg lt_cv_file_magic_test_file=/usr/lib/libnls.so 69680b0ce0bfSmrg ;; 6969d31dbc53Smrg 69700b0ce0bfSmrg*nto* | *qnx*) 69710b0ce0bfSmrg lt_cv_deplibs_check_method=pass_all 69720b0ce0bfSmrg ;; 6973d31dbc53Smrg 69740b0ce0bfSmrgopenbsd* | bitrig*) 69750b0ce0bfSmrg if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then 69760b0ce0bfSmrg lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$' 69770b0ce0bfSmrg else 69780b0ce0bfSmrg lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' 69790b0ce0bfSmrg fi 69800b0ce0bfSmrg ;; 6981d31dbc53Smrg 69820b0ce0bfSmrgosf3* | osf4* | osf5*) 69830b0ce0bfSmrg lt_cv_deplibs_check_method=pass_all 69840b0ce0bfSmrg ;; 6985d31dbc53Smrg 69860b0ce0bfSmrgrdos*) 69870b0ce0bfSmrg lt_cv_deplibs_check_method=pass_all 69880b0ce0bfSmrg ;; 6989d31dbc53Smrg 69900b0ce0bfSmrgsolaris*) 69910b0ce0bfSmrg lt_cv_deplibs_check_method=pass_all 69920b0ce0bfSmrg ;; 6993d31dbc53Smrg 69940b0ce0bfSmrgsysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) 69950b0ce0bfSmrg lt_cv_deplibs_check_method=pass_all 69960b0ce0bfSmrg ;; 6997d31dbc53Smrg 69980b0ce0bfSmrgsysv4 | sysv4.3*) 69990b0ce0bfSmrg case $host_vendor in 70000b0ce0bfSmrg motorola) 70010b0ce0bfSmrg 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]]' 70020b0ce0bfSmrg lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` 70030b0ce0bfSmrg ;; 70040b0ce0bfSmrg ncr) 70050b0ce0bfSmrg lt_cv_deplibs_check_method=pass_all 70060b0ce0bfSmrg ;; 70070b0ce0bfSmrg sequent) 70080b0ce0bfSmrg lt_cv_file_magic_cmd='/bin/file' 70090b0ce0bfSmrg lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )' 70100b0ce0bfSmrg ;; 70110b0ce0bfSmrg sni) 70120b0ce0bfSmrg lt_cv_file_magic_cmd='/bin/file' 70130b0ce0bfSmrg lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib" 70140b0ce0bfSmrg lt_cv_file_magic_test_file=/lib/libc.so 70150b0ce0bfSmrg ;; 70160b0ce0bfSmrg siemens) 70170b0ce0bfSmrg lt_cv_deplibs_check_method=pass_all 70180b0ce0bfSmrg ;; 70190b0ce0bfSmrg pc) 70200b0ce0bfSmrg lt_cv_deplibs_check_method=pass_all 70210b0ce0bfSmrg ;; 70220b0ce0bfSmrg esac 70230b0ce0bfSmrg ;; 7024d31dbc53Smrg 70250b0ce0bfSmrgtpf*) 70260b0ce0bfSmrg lt_cv_deplibs_check_method=pass_all 70270b0ce0bfSmrg ;; 70280b0ce0bfSmrgos2*) 70290b0ce0bfSmrg lt_cv_deplibs_check_method=pass_all 70300b0ce0bfSmrg ;; 70310b0ce0bfSmrgesac 70320b0ce0bfSmrg]) 7033d31dbc53Smrg 70340b0ce0bfSmrgfile_magic_glob= 70350b0ce0bfSmrgwant_nocaseglob=no 70360b0ce0bfSmrgif test "$build" = "$host"; then 70370b0ce0bfSmrg case $host_os in 70380b0ce0bfSmrg mingw* | pw32*) 70390b0ce0bfSmrg if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then 70400b0ce0bfSmrg want_nocaseglob=yes 70410b0ce0bfSmrg else 70420b0ce0bfSmrg file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[[\1]]\/[[\1]]\/g;/g"` 70430b0ce0bfSmrg fi 70440b0ce0bfSmrg ;; 70450b0ce0bfSmrg esac 70460b0ce0bfSmrgfi 7047d31dbc53Smrg 70480b0ce0bfSmrgfile_magic_cmd=$lt_cv_file_magic_cmd 70490b0ce0bfSmrgdeplibs_check_method=$lt_cv_deplibs_check_method 70500b0ce0bfSmrgtest -z "$deplibs_check_method" && deplibs_check_method=unknown 7051d31dbc53Smrg 70520b0ce0bfSmrg_LT_DECL([], [deplibs_check_method], [1], 70530b0ce0bfSmrg [Method to check whether dependent libraries are shared objects]) 70540b0ce0bfSmrg_LT_DECL([], [file_magic_cmd], [1], 70550b0ce0bfSmrg [Command to use when deplibs_check_method = "file_magic"]) 70560b0ce0bfSmrg_LT_DECL([], [file_magic_glob], [1], 70570b0ce0bfSmrg [How to find potential files when deplibs_check_method = "file_magic"]) 70580b0ce0bfSmrg_LT_DECL([], [want_nocaseglob], [1], 70590b0ce0bfSmrg [Find potential files using nocaseglob when deplibs_check_method = "file_magic"]) 70600b0ce0bfSmrg])# _LT_CHECK_MAGIC_METHOD 7061d31dbc53Smrg 70621b12faf6Smrg 70630b0ce0bfSmrg# LT_PATH_NM 70640b0ce0bfSmrg# ---------- 70650b0ce0bfSmrg# find the pathname to a BSD- or MS-compatible name lister 70660b0ce0bfSmrgAC_DEFUN([LT_PATH_NM], 70670b0ce0bfSmrg[AC_REQUIRE([AC_PROG_CC])dnl 70680b0ce0bfSmrgAC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM, 70690b0ce0bfSmrg[if test -n "$NM"; then 70700b0ce0bfSmrg # Let the user override the test. 70710b0ce0bfSmrg lt_cv_path_NM=$NM 70720b0ce0bfSmrgelse 70730b0ce0bfSmrg lt_nm_to_check=${ac_tool_prefix}nm 70740b0ce0bfSmrg if test -n "$ac_tool_prefix" && test "$build" = "$host"; then 70750b0ce0bfSmrg lt_nm_to_check="$lt_nm_to_check nm" 70760b0ce0bfSmrg fi 70770b0ce0bfSmrg for lt_tmp_nm in $lt_nm_to_check; do 70780b0ce0bfSmrg lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR 70790b0ce0bfSmrg for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do 70800b0ce0bfSmrg IFS=$lt_save_ifs 70810b0ce0bfSmrg test -z "$ac_dir" && ac_dir=. 70820b0ce0bfSmrg tmp_nm=$ac_dir/$lt_tmp_nm 70830b0ce0bfSmrg if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext"; then 70840b0ce0bfSmrg # Check to see if the nm accepts a BSD-compat flag. 70850b0ce0bfSmrg # Adding the 'sed 1q' prevents false positives on HP-UX, which says: 70860b0ce0bfSmrg # nm: unknown option "B" ignored 70870b0ce0bfSmrg # Tru64's nm complains that /dev/null is an invalid object file 70880b0ce0bfSmrg # MSYS converts /dev/null to NUL, MinGW nm treats NUL as empty 70890b0ce0bfSmrg case $build_os in 70900b0ce0bfSmrg mingw*) lt_bad_file=conftest.nm/nofile ;; 70910b0ce0bfSmrg *) lt_bad_file=/dev/null ;; 70920b0ce0bfSmrg esac 70930b0ce0bfSmrg case `"$tmp_nm" -B $lt_bad_file 2>&1 | $SED '1q'` in 70940b0ce0bfSmrg *$lt_bad_file* | *'Invalid file or object type'*) 70950b0ce0bfSmrg lt_cv_path_NM="$tmp_nm -B" 70960b0ce0bfSmrg break 2 70970b0ce0bfSmrg ;; 70980b0ce0bfSmrg *) 70990b0ce0bfSmrg case `"$tmp_nm" -p /dev/null 2>&1 | $SED '1q'` in 71000b0ce0bfSmrg */dev/null*) 71010b0ce0bfSmrg lt_cv_path_NM="$tmp_nm -p" 71020b0ce0bfSmrg break 2 71030b0ce0bfSmrg ;; 71040b0ce0bfSmrg *) 71050b0ce0bfSmrg lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but 71060b0ce0bfSmrg continue # so that we can try to find one that supports BSD flags 71070b0ce0bfSmrg ;; 71080b0ce0bfSmrg esac 71090b0ce0bfSmrg ;; 71100b0ce0bfSmrg esac 71110b0ce0bfSmrg fi 71120b0ce0bfSmrg done 71130b0ce0bfSmrg IFS=$lt_save_ifs 71140b0ce0bfSmrg done 71150b0ce0bfSmrg : ${lt_cv_path_NM=no} 71160b0ce0bfSmrgfi]) 71170b0ce0bfSmrgif test no != "$lt_cv_path_NM"; then 71180b0ce0bfSmrg NM=$lt_cv_path_NM 71190b0ce0bfSmrgelse 71200b0ce0bfSmrg # Didn't find any BSD compatible name lister, look for dumpbin. 71210b0ce0bfSmrg if test -n "$DUMPBIN"; then : 71220b0ce0bfSmrg # Let the user override the test. 71230b0ce0bfSmrg else 71240b0ce0bfSmrg AC_CHECK_TOOLS(DUMPBIN, [dumpbin "link -dump"], :) 71250b0ce0bfSmrg case `$DUMPBIN -symbols -headers /dev/null 2>&1 | $SED '1q'` in 71260b0ce0bfSmrg *COFF*) 71270b0ce0bfSmrg DUMPBIN="$DUMPBIN -symbols -headers" 71280b0ce0bfSmrg ;; 71290b0ce0bfSmrg *) 71300b0ce0bfSmrg DUMPBIN=: 71310b0ce0bfSmrg ;; 71320b0ce0bfSmrg esac 71330b0ce0bfSmrg fi 71340b0ce0bfSmrg AC_SUBST([DUMPBIN]) 71350b0ce0bfSmrg if test : != "$DUMPBIN"; then 71360b0ce0bfSmrg NM=$DUMPBIN 71370b0ce0bfSmrg fi 71380b0ce0bfSmrgfi 71390b0ce0bfSmrgtest -z "$NM" && NM=nm 71400b0ce0bfSmrgAC_SUBST([NM]) 71410b0ce0bfSmrg_LT_DECL([], [NM], [1], [A BSD- or MS-compatible name lister])dnl 71421b12faf6Smrg 71430b0ce0bfSmrgAC_CACHE_CHECK([the name lister ($NM) interface], [lt_cv_nm_interface], 71440b0ce0bfSmrg [lt_cv_nm_interface="BSD nm" 71450b0ce0bfSmrg echo "int some_variable = 0;" > conftest.$ac_ext 71460b0ce0bfSmrg (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&AS_MESSAGE_LOG_FD) 71470b0ce0bfSmrg (eval "$ac_compile" 2>conftest.err) 71480b0ce0bfSmrg cat conftest.err >&AS_MESSAGE_LOG_FD 71490b0ce0bfSmrg (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD) 71500b0ce0bfSmrg (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) 71510b0ce0bfSmrg cat conftest.err >&AS_MESSAGE_LOG_FD 71520b0ce0bfSmrg (eval echo "\"\$as_me:$LINENO: output\"" >&AS_MESSAGE_LOG_FD) 71530b0ce0bfSmrg cat conftest.out >&AS_MESSAGE_LOG_FD 71540b0ce0bfSmrg if $GREP 'External.*some_variable' conftest.out > /dev/null; then 71550b0ce0bfSmrg lt_cv_nm_interface="MS dumpbin" 71560b0ce0bfSmrg fi 71570b0ce0bfSmrg rm -f conftest*]) 71580b0ce0bfSmrg])# LT_PATH_NM 71591b12faf6Smrg 71600b0ce0bfSmrg# Old names: 71610b0ce0bfSmrgAU_ALIAS([AM_PROG_NM], [LT_PATH_NM]) 71620b0ce0bfSmrgAU_ALIAS([AC_PROG_NM], [LT_PATH_NM]) 71630b0ce0bfSmrgdnl aclocal-1.4 backwards compatibility: 71640b0ce0bfSmrgdnl AC_DEFUN([AM_PROG_NM], []) 71650b0ce0bfSmrgdnl AC_DEFUN([AC_PROG_NM], []) 71661b12faf6Smrg 71670b0ce0bfSmrg# _LT_CHECK_SHAREDLIB_FROM_LINKLIB 71680b0ce0bfSmrg# -------------------------------- 71690b0ce0bfSmrg# how to determine the name of the shared library 71700b0ce0bfSmrg# associated with a specific link library. 71710b0ce0bfSmrg# -- PORTME fill in with the dynamic library characteristics 71720b0ce0bfSmrgm4_defun([_LT_CHECK_SHAREDLIB_FROM_LINKLIB], 71730b0ce0bfSmrg[m4_require([_LT_DECL_EGREP]) 71740b0ce0bfSmrgm4_require([_LT_DECL_OBJDUMP]) 71750b0ce0bfSmrgm4_require([_LT_DECL_DLLTOOL]) 71760b0ce0bfSmrgAC_CACHE_CHECK([how to associate runtime and link libraries], 71770b0ce0bfSmrglt_cv_sharedlib_from_linklib_cmd, 71780b0ce0bfSmrg[lt_cv_sharedlib_from_linklib_cmd='unknown' 71791b12faf6Smrg 71800b0ce0bfSmrgcase $host_os in 71810b0ce0bfSmrgcygwin* | mingw* | pw32* | cegcc*) 71820b0ce0bfSmrg # two different shell functions defined in ltmain.sh; 71830b0ce0bfSmrg # decide which one to use based on capabilities of $DLLTOOL 71840b0ce0bfSmrg case `$DLLTOOL --help 2>&1` in 71850b0ce0bfSmrg *--identify-strict*) 71860b0ce0bfSmrg lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib 71870b0ce0bfSmrg ;; 71880b0ce0bfSmrg *) 71890b0ce0bfSmrg lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback 71900b0ce0bfSmrg ;; 71910b0ce0bfSmrg esac 71920b0ce0bfSmrg ;; 71930b0ce0bfSmrg*) 71940b0ce0bfSmrg # fallback: assume linklib IS sharedlib 71950b0ce0bfSmrg lt_cv_sharedlib_from_linklib_cmd=$ECHO 71960b0ce0bfSmrg ;; 71970b0ce0bfSmrgesac 71980b0ce0bfSmrg]) 71990b0ce0bfSmrgsharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd 72000b0ce0bfSmrgtest -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO 72011b12faf6Smrg 72020b0ce0bfSmrg_LT_DECL([], [sharedlib_from_linklib_cmd], [1], 72030b0ce0bfSmrg [Command to associate shared and link libraries]) 72040b0ce0bfSmrg])# _LT_CHECK_SHAREDLIB_FROM_LINKLIB 72051b12faf6Smrg 72061b12faf6Smrg 72070b0ce0bfSmrg# _LT_PATH_MANIFEST_TOOL 72080b0ce0bfSmrg# ---------------------- 72090b0ce0bfSmrg# locate the manifest tool 72100b0ce0bfSmrgm4_defun([_LT_PATH_MANIFEST_TOOL], 72110b0ce0bfSmrg[AC_CHECK_TOOL(MANIFEST_TOOL, mt, :) 72120b0ce0bfSmrgtest -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt 72130b0ce0bfSmrgAC_CACHE_CHECK([if $MANIFEST_TOOL is a manifest tool], [lt_cv_path_mainfest_tool], 72140b0ce0bfSmrg [lt_cv_path_mainfest_tool=no 72150b0ce0bfSmrg echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&AS_MESSAGE_LOG_FD 72160b0ce0bfSmrg $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out 72170b0ce0bfSmrg cat conftest.err >&AS_MESSAGE_LOG_FD 72180b0ce0bfSmrg if $GREP 'Manifest Tool' conftest.out > /dev/null; then 72190b0ce0bfSmrg lt_cv_path_mainfest_tool=yes 72200b0ce0bfSmrg fi 72210b0ce0bfSmrg rm -f conftest*]) 72220b0ce0bfSmrgif test yes != "$lt_cv_path_mainfest_tool"; then 72230b0ce0bfSmrg MANIFEST_TOOL=: 7224e35d4d8eSmrgfi 72250b0ce0bfSmrg_LT_DECL([], [MANIFEST_TOOL], [1], [Manifest tool])dnl 72260b0ce0bfSmrg])# _LT_PATH_MANIFEST_TOOL 72271b12faf6Smrg 72281b12faf6Smrg 72290b0ce0bfSmrg# _LT_DLL_DEF_P([FILE]) 72300b0ce0bfSmrg# --------------------- 72310b0ce0bfSmrg# True iff FILE is a Windows DLL '.def' file. 72320b0ce0bfSmrg# Keep in sync with func_dll_def_p in the libtool script 72330b0ce0bfSmrgAC_DEFUN([_LT_DLL_DEF_P], 72340b0ce0bfSmrg[dnl 72350b0ce0bfSmrg test DEF = "`$SED -n dnl 72360b0ce0bfSmrg -e '\''s/^[[ ]]*//'\'' dnl Strip leading whitespace 72370b0ce0bfSmrg -e '\''/^\(;.*\)*$/d'\'' dnl Delete empty lines and comments 72380b0ce0bfSmrg -e '\''s/^\(EXPORTS\|LIBRARY\)\([[ ]].*\)*$/DEF/p'\'' dnl 72390b0ce0bfSmrg -e q dnl Only consider the first "real" line 72400b0ce0bfSmrg $1`" dnl 72410b0ce0bfSmrg])# _LT_DLL_DEF_P 7242d31dbc53Smrg 7243d31dbc53Smrg 72440b0ce0bfSmrg# LT_LIB_M 72450b0ce0bfSmrg# -------- 72460b0ce0bfSmrg# check for math library 72470b0ce0bfSmrgAC_DEFUN([LT_LIB_M], 72480b0ce0bfSmrg[AC_REQUIRE([AC_CANONICAL_HOST])dnl 72490b0ce0bfSmrgLIBM= 72500b0ce0bfSmrgcase $host in 72510b0ce0bfSmrg*-*-beos* | *-*-cegcc* | *-*-cygwin* | *-*-haiku* | *-*-pw32* | *-*-darwin*) 72520b0ce0bfSmrg # These system don't have libm, or don't need it 72530b0ce0bfSmrg ;; 72540b0ce0bfSmrg*-ncr-sysv4.3*) 72550b0ce0bfSmrg AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM=-lmw) 72560b0ce0bfSmrg AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm") 72570b0ce0bfSmrg ;; 72580b0ce0bfSmrg*) 72590b0ce0bfSmrg AC_CHECK_LIB(m, cos, LIBM=-lm) 72600b0ce0bfSmrg ;; 72610b0ce0bfSmrgesac 72620b0ce0bfSmrgAC_SUBST([LIBM]) 72630b0ce0bfSmrg])# LT_LIB_M 7264d31dbc53Smrg 72650b0ce0bfSmrg# Old name: 72660b0ce0bfSmrgAU_ALIAS([AC_CHECK_LIBM], [LT_LIB_M]) 72670b0ce0bfSmrgdnl aclocal-1.4 backwards compatibility: 72680b0ce0bfSmrgdnl AC_DEFUN([AC_CHECK_LIBM], []) 7269d31dbc53Smrg 7270d31dbc53Smrg 72710b0ce0bfSmrg# _LT_COMPILER_NO_RTTI([TAGNAME]) 72720b0ce0bfSmrg# ------------------------------- 72730b0ce0bfSmrgm4_defun([_LT_COMPILER_NO_RTTI], 72740b0ce0bfSmrg[m4_require([_LT_TAG_COMPILER])dnl 7275d31dbc53Smrg 72760b0ce0bfSmrg_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= 7277d31dbc53Smrg 72780b0ce0bfSmrgif test yes = "$GCC"; then 72790b0ce0bfSmrg case $cc_basename in 72800b0ce0bfSmrg nvcc*) 72810b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -Xcompiler -fno-builtin' ;; 72820b0ce0bfSmrg *) 72830b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' ;; 72840b0ce0bfSmrg esac 7285d31dbc53Smrg 72860b0ce0bfSmrg _LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions], 72870b0ce0bfSmrg lt_cv_prog_compiler_rtti_exceptions, 72880b0ce0bfSmrg [-fno-rtti -fno-exceptions], [], 72890b0ce0bfSmrg [_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"]) 72900b0ce0bfSmrgfi 72910b0ce0bfSmrg_LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1], 72920b0ce0bfSmrg [Compiler flag to turn off builtin functions]) 72930b0ce0bfSmrg])# _LT_COMPILER_NO_RTTI 7294d31dbc53Smrg 7295d31dbc53Smrg 72960b0ce0bfSmrg# _LT_CMD_GLOBAL_SYMBOLS 72970b0ce0bfSmrg# ---------------------- 72980b0ce0bfSmrgm4_defun([_LT_CMD_GLOBAL_SYMBOLS], 72990b0ce0bfSmrg[AC_REQUIRE([AC_CANONICAL_HOST])dnl 73000b0ce0bfSmrgAC_REQUIRE([AC_PROG_CC])dnl 73010b0ce0bfSmrgAC_REQUIRE([AC_PROG_AWK])dnl 73020b0ce0bfSmrgAC_REQUIRE([LT_PATH_NM])dnl 73030b0ce0bfSmrgAC_REQUIRE([LT_PATH_LD])dnl 73040b0ce0bfSmrgm4_require([_LT_DECL_SED])dnl 73050b0ce0bfSmrgm4_require([_LT_DECL_EGREP])dnl 73060b0ce0bfSmrgm4_require([_LT_TAG_COMPILER])dnl 73070b0ce0bfSmrg 73080b0ce0bfSmrg# Check for command to grab the raw symbol name followed by C symbol from nm. 73090b0ce0bfSmrgAC_MSG_CHECKING([command to parse $NM output from $compiler object]) 73100b0ce0bfSmrgAC_CACHE_VAL([lt_cv_sys_global_symbol_pipe], 73110b0ce0bfSmrg[ 73120b0ce0bfSmrg# These are sane defaults that work on at least a few old systems. 73130b0ce0bfSmrg# [They come from Ultrix. What could be older than Ultrix?!! ;)] 73140b0ce0bfSmrg 73150b0ce0bfSmrg# Character class describing NM global symbol codes. 73160b0ce0bfSmrgsymcode='[[BCDEGRST]]' 73170b0ce0bfSmrg 73180b0ce0bfSmrg# Regexp to match symbols that can be accessed directly from C. 73190b0ce0bfSmrgsympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)' 73200b0ce0bfSmrg 73210b0ce0bfSmrg# Define system-specific variables. 73220b0ce0bfSmrgcase $host_os in 73230b0ce0bfSmrgaix*) 73240b0ce0bfSmrg symcode='[[BCDT]]' 73250b0ce0bfSmrg ;; 73260b0ce0bfSmrgcygwin* | mingw* | pw32* | cegcc*) 73270b0ce0bfSmrg symcode='[[ABCDGISTW]]' 73280b0ce0bfSmrg ;; 73290b0ce0bfSmrghpux*) 73300b0ce0bfSmrg if test ia64 = "$host_cpu"; then 73310b0ce0bfSmrg symcode='[[ABCDEGRST]]' 73320b0ce0bfSmrg fi 73330b0ce0bfSmrg ;; 73340b0ce0bfSmrgirix* | nonstopux*) 73350b0ce0bfSmrg symcode='[[BCDEGRST]]' 73360b0ce0bfSmrg ;; 73370b0ce0bfSmrgosf*) 73380b0ce0bfSmrg symcode='[[BCDEGQRST]]' 73390b0ce0bfSmrg ;; 73400b0ce0bfSmrgsolaris*) 73410b0ce0bfSmrg symcode='[[BDRT]]' 73420b0ce0bfSmrg ;; 73430b0ce0bfSmrgsco3.2v5*) 73440b0ce0bfSmrg symcode='[[DT]]' 73450b0ce0bfSmrg ;; 73460b0ce0bfSmrgsysv4.2uw2*) 73470b0ce0bfSmrg symcode='[[DT]]' 73480b0ce0bfSmrg ;; 73490b0ce0bfSmrgsysv5* | sco5v6* | unixware* | OpenUNIX*) 73500b0ce0bfSmrg symcode='[[ABDT]]' 73510b0ce0bfSmrg ;; 73520b0ce0bfSmrgsysv4) 73530b0ce0bfSmrg symcode='[[DFNSTU]]' 73540b0ce0bfSmrg ;; 73550b0ce0bfSmrgesac 73560b0ce0bfSmrg 73570b0ce0bfSmrg# If we're using GNU nm, then use its standard symbol codes. 73580b0ce0bfSmrgcase `$NM -V 2>&1` in 73590b0ce0bfSmrg*GNU* | *'with BFD'*) 73600b0ce0bfSmrg symcode='[[ABCDGIRSTW]]' ;; 73610b0ce0bfSmrgesac 73620b0ce0bfSmrg 73630b0ce0bfSmrgif test "$lt_cv_nm_interface" = "MS dumpbin"; then 73640b0ce0bfSmrg # Gets list of data symbols to import. 73650b0ce0bfSmrg lt_cv_sys_global_symbol_to_import="$SED -n -e 's/^I .* \(.*\)$/\1/p'" 73660b0ce0bfSmrg # Adjust the below global symbol transforms to fixup imported variables. 73670b0ce0bfSmrg lt_cdecl_hook=" -e 's/^I .* \(.*\)$/extern __declspec(dllimport) char \1;/p'" 73680b0ce0bfSmrg lt_c_name_hook=" -e 's/^I .* \(.*\)$/ {\"\1\", (void *) 0},/p'" 73690b0ce0bfSmrg lt_c_name_lib_hook="\ 73700b0ce0bfSmrg -e 's/^I .* \(lib.*\)$/ {\"\1\", (void *) 0},/p'\ 73710b0ce0bfSmrg -e 's/^I .* \(.*\)$/ {\"lib\1\", (void *) 0},/p'" 73720b0ce0bfSmrgelse 73730b0ce0bfSmrg # Disable hooks by default. 73740b0ce0bfSmrg lt_cv_sys_global_symbol_to_import= 73750b0ce0bfSmrg lt_cdecl_hook= 73760b0ce0bfSmrg lt_c_name_hook= 73770b0ce0bfSmrg lt_c_name_lib_hook= 7378e35d4d8eSmrgfi 7379d31dbc53Smrg 73800b0ce0bfSmrg# Transform an extracted symbol line into a proper C declaration. 73810b0ce0bfSmrg# Some systems (esp. on ia64) link data and code symbols differently, 73820b0ce0bfSmrg# so use this general approach. 73830b0ce0bfSmrglt_cv_sys_global_symbol_to_cdecl="$SED -n"\ 73840b0ce0bfSmrg$lt_cdecl_hook\ 73850b0ce0bfSmrg" -e 's/^T .* \(.*\)$/extern int \1();/p'"\ 73860b0ce0bfSmrg" -e 's/^$symcode$symcode* .* \(.*\)$/extern char \1;/p'" 7387d31dbc53Smrg 73880b0ce0bfSmrg# Transform an extracted symbol line into symbol name and symbol address 73890b0ce0bfSmrglt_cv_sys_global_symbol_to_c_name_address="$SED -n"\ 73900b0ce0bfSmrg$lt_c_name_hook\ 73910b0ce0bfSmrg" -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ 73920b0ce0bfSmrg" -e 's/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/p'" 73930b0ce0bfSmrg 73940b0ce0bfSmrg# Transform an extracted symbol line into symbol name with lib prefix and 73950b0ce0bfSmrg# symbol address. 73960b0ce0bfSmrglt_cv_sys_global_symbol_to_c_name_address_lib_prefix="$SED -n"\ 73970b0ce0bfSmrg$lt_c_name_lib_hook\ 73980b0ce0bfSmrg" -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ 73990b0ce0bfSmrg" -e 's/^$symcode$symcode* .* \(lib.*\)$/ {\"\1\", (void *) \&\1},/p'"\ 74000b0ce0bfSmrg" -e 's/^$symcode$symcode* .* \(.*\)$/ {\"lib\1\", (void *) \&\1},/p'" 7401e35d4d8eSmrg 74020b0ce0bfSmrg# Handle CRLF in mingw tool chain 74030b0ce0bfSmrgopt_cr= 74040b0ce0bfSmrgcase $build_os in 74050b0ce0bfSmrgmingw*) 74060b0ce0bfSmrg opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp 74070b0ce0bfSmrg ;; 74080b0ce0bfSmrgesac 7409d31dbc53Smrg 74100b0ce0bfSmrg# Try without a prefix underscore, then with it. 74110b0ce0bfSmrgfor ac_symprfx in "" "_"; do 7412d31dbc53Smrg 74130b0ce0bfSmrg # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. 74140b0ce0bfSmrg symxfrm="\\1 $ac_symprfx\\2 \\2" 7415d31dbc53Smrg 74160b0ce0bfSmrg # Write the raw and C identifiers. 74170b0ce0bfSmrg if test "$lt_cv_nm_interface" = "MS dumpbin"; then 74180b0ce0bfSmrg # Fake it for dumpbin and say T for any non-static function, 74190b0ce0bfSmrg # D for any global variable and I for any imported variable. 74200b0ce0bfSmrg # Also find C++ and __fastcall symbols from MSVC++ or ICC, 74210b0ce0bfSmrg # which start with @ or ?. 74220b0ce0bfSmrg lt_cv_sys_global_symbol_pipe="$AWK ['"\ 74230b0ce0bfSmrg" {last_section=section; section=\$ 3};"\ 74240b0ce0bfSmrg" /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\ 74250b0ce0bfSmrg" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\ 74260b0ce0bfSmrg" /^ *Symbol name *: /{split(\$ 0,sn,\":\"); si=substr(sn[2],2)};"\ 74270b0ce0bfSmrg" /^ *Type *: code/{print \"T\",si,substr(si,length(prfx))};"\ 74280b0ce0bfSmrg" /^ *Type *: data/{print \"I\",si,substr(si,length(prfx))};"\ 74290b0ce0bfSmrg" \$ 0!~/External *\|/{next};"\ 74300b0ce0bfSmrg" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\ 74310b0ce0bfSmrg" {if(hide[section]) next};"\ 74320b0ce0bfSmrg" {f=\"D\"}; \$ 0~/\(\).*\|/{f=\"T\"};"\ 74330b0ce0bfSmrg" {split(\$ 0,a,/\||\r/); split(a[2],s)};"\ 74340b0ce0bfSmrg" s[1]~/^[@?]/{print f,s[1],s[1]; next};"\ 74350b0ce0bfSmrg" s[1]~prfx {split(s[1],t,\"@\"); print f,t[1],substr(t[1],length(prfx))}"\ 74360b0ce0bfSmrg" ' prfx=^$ac_symprfx]" 74370b0ce0bfSmrg else 74380b0ce0bfSmrg lt_cv_sys_global_symbol_pipe="$SED -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" 74390b0ce0bfSmrg fi 74400b0ce0bfSmrg lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | $SED '/ __gnu_lto/d'" 74410b0ce0bfSmrg 74420b0ce0bfSmrg # Check to see that the pipe works correctly. 74430b0ce0bfSmrg pipe_works=no 74440b0ce0bfSmrg 74450b0ce0bfSmrg rm -f conftest* 74460b0ce0bfSmrg cat > conftest.$ac_ext <<_LT_EOF 74470b0ce0bfSmrg#ifdef __cplusplus 74480b0ce0bfSmrgextern "C" { 74490b0ce0bfSmrg#endif 74500b0ce0bfSmrgchar nm_test_var; 74510b0ce0bfSmrgvoid nm_test_func(void); 74520b0ce0bfSmrgvoid nm_test_func(void){} 74530b0ce0bfSmrg#ifdef __cplusplus 74540b0ce0bfSmrg} 74550b0ce0bfSmrg#endif 74560b0ce0bfSmrgint main(){nm_test_var='a';nm_test_func();return(0);} 74570b0ce0bfSmrg_LT_EOF 74580b0ce0bfSmrg 74590b0ce0bfSmrg if AC_TRY_EVAL(ac_compile); then 74600b0ce0bfSmrg # Now try to grab the symbols. 74610b0ce0bfSmrg nlist=conftest.nm 74620b0ce0bfSmrg if AC_TRY_EVAL(NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) && test -s "$nlist"; then 74630b0ce0bfSmrg # Try sorting and uniquifying the output. 74640b0ce0bfSmrg if sort "$nlist" | uniq > "$nlist"T; then 74650b0ce0bfSmrg mv -f "$nlist"T "$nlist" 74660b0ce0bfSmrg else 74670b0ce0bfSmrg rm -f "$nlist"T 74680b0ce0bfSmrg fi 74690b0ce0bfSmrg 74700b0ce0bfSmrg # Make sure that we snagged all the symbols we need. 74710b0ce0bfSmrg if $GREP ' nm_test_var$' "$nlist" >/dev/null; then 74720b0ce0bfSmrg if $GREP ' nm_test_func$' "$nlist" >/dev/null; then 74730b0ce0bfSmrg cat <<_LT_EOF > conftest.$ac_ext 74740b0ce0bfSmrg/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ 74750b0ce0bfSmrg#if defined _WIN32 || defined __CYGWIN__ || defined _WIN32_WCE 74760b0ce0bfSmrg/* DATA imports from DLLs on WIN32 can't be const, because runtime 74770b0ce0bfSmrg relocations are performed -- see ld's documentation on pseudo-relocs. */ 74780b0ce0bfSmrg# define LT@&t@_DLSYM_CONST 74790b0ce0bfSmrg#elif defined __osf__ 74800b0ce0bfSmrg/* This system does not cope well with relocations in const data. */ 74810b0ce0bfSmrg# define LT@&t@_DLSYM_CONST 74820b0ce0bfSmrg#else 74830b0ce0bfSmrg# define LT@&t@_DLSYM_CONST const 74840b0ce0bfSmrg#endif 74850b0ce0bfSmrg 74860b0ce0bfSmrg#ifdef __cplusplus 74870b0ce0bfSmrgextern "C" { 74880b0ce0bfSmrg#endif 74890b0ce0bfSmrg 74900b0ce0bfSmrg_LT_EOF 74910b0ce0bfSmrg # Now generate the symbol file. 74920b0ce0bfSmrg eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext' 74930b0ce0bfSmrg 74940b0ce0bfSmrg cat <<_LT_EOF >> conftest.$ac_ext 74950b0ce0bfSmrg 74960b0ce0bfSmrg/* The mapping between symbol names and symbols. */ 74970b0ce0bfSmrgLT@&t@_DLSYM_CONST struct { 74980b0ce0bfSmrg const char *name; 74990b0ce0bfSmrg void *address; 75000b0ce0bfSmrg} 75010b0ce0bfSmrglt__PROGRAM__LTX_preloaded_symbols[[]] = 75020b0ce0bfSmrg{ 75030b0ce0bfSmrg { "@PROGRAM@", (void *) 0 }, 75040b0ce0bfSmrg_LT_EOF 75050b0ce0bfSmrg $SED "s/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext 75060b0ce0bfSmrg cat <<\_LT_EOF >> conftest.$ac_ext 75070b0ce0bfSmrg {0, (void *) 0} 75080b0ce0bfSmrg}; 75090b0ce0bfSmrg 75100b0ce0bfSmrg/* This works around a problem in FreeBSD linker */ 75110b0ce0bfSmrg#ifdef FREEBSD_WORKAROUND 75120b0ce0bfSmrgstatic const void *lt_preloaded_setup() { 75130b0ce0bfSmrg return lt__PROGRAM__LTX_preloaded_symbols; 75140b0ce0bfSmrg} 75150b0ce0bfSmrg#endif 75160b0ce0bfSmrg 75170b0ce0bfSmrg#ifdef __cplusplus 75180b0ce0bfSmrg} 75190b0ce0bfSmrg#endif 75200b0ce0bfSmrg_LT_EOF 75210b0ce0bfSmrg # Now try linking the two files. 75220b0ce0bfSmrg mv conftest.$ac_objext conftstm.$ac_objext 75230b0ce0bfSmrg lt_globsym_save_LIBS=$LIBS 75240b0ce0bfSmrg lt_globsym_save_CFLAGS=$CFLAGS 75250b0ce0bfSmrg LIBS=conftstm.$ac_objext 75260b0ce0bfSmrg CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)" 75270b0ce0bfSmrg if AC_TRY_EVAL(ac_link) && test -s conftest$ac_exeext; then 75280b0ce0bfSmrg pipe_works=yes 75290b0ce0bfSmrg fi 75300b0ce0bfSmrg LIBS=$lt_globsym_save_LIBS 75310b0ce0bfSmrg CFLAGS=$lt_globsym_save_CFLAGS 75320b0ce0bfSmrg else 75330b0ce0bfSmrg echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD 75340b0ce0bfSmrg fi 75350b0ce0bfSmrg else 75360b0ce0bfSmrg echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD 75370b0ce0bfSmrg fi 75380b0ce0bfSmrg else 75390b0ce0bfSmrg echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD 75400b0ce0bfSmrg fi 75410b0ce0bfSmrg else 75420b0ce0bfSmrg echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD 75430b0ce0bfSmrg cat conftest.$ac_ext >&5 75440b0ce0bfSmrg fi 75450b0ce0bfSmrg rm -rf conftest* conftst* 75460b0ce0bfSmrg 75470b0ce0bfSmrg # Do not use the global_symbol_pipe unless it works. 75480b0ce0bfSmrg if test yes = "$pipe_works"; then 75490b0ce0bfSmrg break 75500b0ce0bfSmrg else 75510b0ce0bfSmrg lt_cv_sys_global_symbol_pipe= 75520b0ce0bfSmrg fi 75530b0ce0bfSmrgdone 75540b0ce0bfSmrg]) 75550b0ce0bfSmrgif test -z "$lt_cv_sys_global_symbol_pipe"; then 75560b0ce0bfSmrg lt_cv_sys_global_symbol_to_cdecl= 75570b0ce0bfSmrgfi 75580b0ce0bfSmrgif test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then 75590b0ce0bfSmrg AC_MSG_RESULT(failed) 75600b0ce0bfSmrgelse 75610b0ce0bfSmrg AC_MSG_RESULT(ok) 75620b0ce0bfSmrgfi 75630b0ce0bfSmrg 75640b0ce0bfSmrg# Response file support. 75650b0ce0bfSmrgif test "$lt_cv_nm_interface" = "MS dumpbin"; then 75660b0ce0bfSmrg nm_file_list_spec='@' 75670b0ce0bfSmrgelif $NM --help 2>/dev/null | grep '[[@]]FILE' >/dev/null; then 75680b0ce0bfSmrg nm_file_list_spec='@' 75690b0ce0bfSmrgfi 75700b0ce0bfSmrg 75710b0ce0bfSmrg_LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1], 75720b0ce0bfSmrg [Take the output of nm and produce a listing of raw symbols and C names]) 75730b0ce0bfSmrg_LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1], 75740b0ce0bfSmrg [Transform the output of nm in a proper C declaration]) 75750b0ce0bfSmrg_LT_DECL([global_symbol_to_import], [lt_cv_sys_global_symbol_to_import], [1], 75760b0ce0bfSmrg [Transform the output of nm into a list of symbols to manually relocate]) 75770b0ce0bfSmrg_LT_DECL([global_symbol_to_c_name_address], 75780b0ce0bfSmrg [lt_cv_sys_global_symbol_to_c_name_address], [1], 75790b0ce0bfSmrg [Transform the output of nm in a C name address pair]) 75800b0ce0bfSmrg_LT_DECL([global_symbol_to_c_name_address_lib_prefix], 75810b0ce0bfSmrg [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1], 75820b0ce0bfSmrg [Transform the output of nm in a C name address pair when lib prefix is needed]) 75830b0ce0bfSmrg_LT_DECL([nm_interface], [lt_cv_nm_interface], [1], 75840b0ce0bfSmrg [The name lister interface]) 75850b0ce0bfSmrg_LT_DECL([], [nm_file_list_spec], [1], 75860b0ce0bfSmrg [Specify filename containing input files for $NM]) 75870b0ce0bfSmrg]) # _LT_CMD_GLOBAL_SYMBOLS 75880b0ce0bfSmrg 75890b0ce0bfSmrg 75900b0ce0bfSmrg# _LT_COMPILER_PIC([TAGNAME]) 75910b0ce0bfSmrg# --------------------------- 75920b0ce0bfSmrgm4_defun([_LT_COMPILER_PIC], 75930b0ce0bfSmrg[m4_require([_LT_TAG_COMPILER])dnl 75940b0ce0bfSmrg_LT_TAGVAR(lt_prog_compiler_wl, $1)= 75950b0ce0bfSmrg_LT_TAGVAR(lt_prog_compiler_pic, $1)= 75960b0ce0bfSmrg_LT_TAGVAR(lt_prog_compiler_static, $1)= 75970b0ce0bfSmrg 75980b0ce0bfSmrgm4_if([$1], [CXX], [ 75990b0ce0bfSmrg # C++ specific cases for pic, static, wl, etc. 76000b0ce0bfSmrg if test yes = "$GXX"; then 76010b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 76020b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 76030b0ce0bfSmrg 76040b0ce0bfSmrg case $host_os in 76050b0ce0bfSmrg aix*) 76060b0ce0bfSmrg # All AIX code is PIC. 76070b0ce0bfSmrg if test ia64 = "$host_cpu"; then 76080b0ce0bfSmrg # AIX 5 now supports IA64 processor 76090b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 76100b0ce0bfSmrg fi 76110b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 76120b0ce0bfSmrg ;; 76130b0ce0bfSmrg 76140b0ce0bfSmrg amigaos*) 76150b0ce0bfSmrg case $host_cpu in 76160b0ce0bfSmrg powerpc) 76170b0ce0bfSmrg # see comment about AmigaOS4 .so support 76180b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 76190b0ce0bfSmrg ;; 76200b0ce0bfSmrg m68k) 76210b0ce0bfSmrg # FIXME: we need at least 68020 code to build shared libraries, but 76220b0ce0bfSmrg # adding the '-m68020' flag to GCC prevents building anything better, 76230b0ce0bfSmrg # like '-m68040'. 76240b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' 76250b0ce0bfSmrg ;; 76260b0ce0bfSmrg esac 76270b0ce0bfSmrg ;; 76280b0ce0bfSmrg 76290b0ce0bfSmrg beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) 76300b0ce0bfSmrg # PIC is the default for these OSes. 76310b0ce0bfSmrg ;; 76320b0ce0bfSmrg mingw* | cygwin* | os2* | pw32* | cegcc*) 76330b0ce0bfSmrg # This hack is so that the source file can tell whether it is being 76340b0ce0bfSmrg # built for inclusion in a dll (and should export symbols for example). 76350b0ce0bfSmrg # Although the cygwin gcc ignores -fPIC, still need this for old-style 76360b0ce0bfSmrg # (--disable-auto-import) libraries 76370b0ce0bfSmrg m4_if([$1], [GCJ], [], 76380b0ce0bfSmrg [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) 76390b0ce0bfSmrg case $host_os in 76400b0ce0bfSmrg os2*) 76410b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static' 76420b0ce0bfSmrg ;; 76430b0ce0bfSmrg esac 76440b0ce0bfSmrg ;; 76450b0ce0bfSmrg darwin* | rhapsody*) 76460b0ce0bfSmrg # PIC is the default on this platform 76470b0ce0bfSmrg # Common symbols not allowed in MH_DYLIB files 76480b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' 76490b0ce0bfSmrg ;; 76500b0ce0bfSmrg *djgpp*) 76510b0ce0bfSmrg # DJGPP does not support shared libraries at all 76520b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)= 76530b0ce0bfSmrg ;; 76540b0ce0bfSmrg haiku*) 76550b0ce0bfSmrg # PIC is the default for Haiku. 76560b0ce0bfSmrg # The "-static" flag exists, but is broken. 76570b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)= 76580b0ce0bfSmrg ;; 76590b0ce0bfSmrg interix[[3-9]]*) 76600b0ce0bfSmrg # Interix 3.x gcc -fpic/-fPIC options generate broken code. 76610b0ce0bfSmrg # Instead, we relocate shared libraries at runtime. 76620b0ce0bfSmrg ;; 76630b0ce0bfSmrg sysv4*MP*) 76640b0ce0bfSmrg if test -d /usr/nec; then 76650b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic 76660b0ce0bfSmrg fi 76670b0ce0bfSmrg ;; 76680b0ce0bfSmrg hpux*) 76690b0ce0bfSmrg # PIC is the default for 64-bit PA HP-UX, but not for 32-bit 76700b0ce0bfSmrg # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag 76710b0ce0bfSmrg # sets the default TLS model and affects inlining. 76720b0ce0bfSmrg case $host_cpu in 76730b0ce0bfSmrg hppa*64*) 76740b0ce0bfSmrg ;; 76750b0ce0bfSmrg *) 76760b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 76770b0ce0bfSmrg ;; 76780b0ce0bfSmrg esac 76790b0ce0bfSmrg ;; 76800b0ce0bfSmrg *qnx* | *nto*) 76810b0ce0bfSmrg # QNX uses GNU C++, but need to define -shared option too, otherwise 76820b0ce0bfSmrg # it will coredump. 76830b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' 76840b0ce0bfSmrg ;; 76850b0ce0bfSmrg *) 76860b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 76870b0ce0bfSmrg ;; 76880b0ce0bfSmrg esac 76890b0ce0bfSmrg else 76900b0ce0bfSmrg case $host_os in 76910b0ce0bfSmrg aix[[4-9]]*) 76920b0ce0bfSmrg # All AIX code is PIC. 76930b0ce0bfSmrg if test ia64 = "$host_cpu"; then 76940b0ce0bfSmrg # AIX 5 now supports IA64 processor 76950b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 76960b0ce0bfSmrg else 76970b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' 76980b0ce0bfSmrg fi 76990b0ce0bfSmrg ;; 77000b0ce0bfSmrg chorus*) 77010b0ce0bfSmrg case $cc_basename in 77020b0ce0bfSmrg cxch68*) 77030b0ce0bfSmrg # Green Hills C++ Compiler 77040b0ce0bfSmrg # _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" 77050b0ce0bfSmrg ;; 77060b0ce0bfSmrg esac 77070b0ce0bfSmrg ;; 77080b0ce0bfSmrg mingw* | cygwin* | os2* | pw32* | cegcc*) 77090b0ce0bfSmrg # This hack is so that the source file can tell whether it is being 77100b0ce0bfSmrg # built for inclusion in a dll (and should export symbols for example). 77110b0ce0bfSmrg m4_if([$1], [GCJ], [], 77120b0ce0bfSmrg [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) 77130b0ce0bfSmrg ;; 77140b0ce0bfSmrg dgux*) 77150b0ce0bfSmrg case $cc_basename in 77160b0ce0bfSmrg ec++*) 77170b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 77180b0ce0bfSmrg ;; 77190b0ce0bfSmrg ghcx*) 77200b0ce0bfSmrg # Green Hills C++ Compiler 77210b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 77220b0ce0bfSmrg ;; 77230b0ce0bfSmrg *) 77240b0ce0bfSmrg ;; 77250b0ce0bfSmrg esac 77260b0ce0bfSmrg ;; 77270b0ce0bfSmrg freebsd* | dragonfly* | midnightbsd*) 77280b0ce0bfSmrg # FreeBSD uses GNU C++ 77290b0ce0bfSmrg ;; 77300b0ce0bfSmrg hpux9* | hpux10* | hpux11*) 77310b0ce0bfSmrg case $cc_basename in 77320b0ce0bfSmrg CC*) 77330b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 77340b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive' 77350b0ce0bfSmrg if test ia64 != "$host_cpu"; then 77360b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' 77370b0ce0bfSmrg fi 77380b0ce0bfSmrg ;; 77390b0ce0bfSmrg aCC*) 77400b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 77410b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive' 77420b0ce0bfSmrg case $host_cpu in 77430b0ce0bfSmrg hppa*64*|ia64*) 77440b0ce0bfSmrg # +Z the default 77450b0ce0bfSmrg ;; 77460b0ce0bfSmrg *) 77470b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' 77480b0ce0bfSmrg ;; 77490b0ce0bfSmrg esac 77500b0ce0bfSmrg ;; 77510b0ce0bfSmrg *) 77520b0ce0bfSmrg ;; 77530b0ce0bfSmrg esac 77540b0ce0bfSmrg ;; 77550b0ce0bfSmrg interix*) 77560b0ce0bfSmrg # This is c89, which is MS Visual C++ (no shared libs) 77570b0ce0bfSmrg # Anyone wants to do a port? 77580b0ce0bfSmrg ;; 77590b0ce0bfSmrg irix5* | irix6* | nonstopux*) 77600b0ce0bfSmrg case $cc_basename in 77610b0ce0bfSmrg CC*) 77620b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 77630b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 77640b0ce0bfSmrg # CC pic flag -KPIC is the default. 77650b0ce0bfSmrg ;; 77660b0ce0bfSmrg *) 77670b0ce0bfSmrg ;; 77680b0ce0bfSmrg esac 77690b0ce0bfSmrg ;; 77700b0ce0bfSmrg linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) 77710b0ce0bfSmrg case $cc_basename in 77720b0ce0bfSmrg KCC*) 77730b0ce0bfSmrg # KAI C++ Compiler 77740b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' 77750b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 77760b0ce0bfSmrg ;; 77770b0ce0bfSmrg ecpc* ) 77780b0ce0bfSmrg # old Intel C++ for x86_64, which still supported -KPIC. 77790b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 77800b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 77810b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 77820b0ce0bfSmrg ;; 77830b0ce0bfSmrg icpc* ) 77840b0ce0bfSmrg # Intel C++, used to be incompatible with GCC. 77850b0ce0bfSmrg # ICC 10 doesn't accept -KPIC any more. 77860b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 77870b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 77880b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 77890b0ce0bfSmrg ;; 77900b0ce0bfSmrg pgCC* | pgcpp*) 77910b0ce0bfSmrg # Portland Group C++ compiler 77920b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 77930b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' 77940b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 77950b0ce0bfSmrg ;; 77960b0ce0bfSmrg cxx*) 77970b0ce0bfSmrg # Compaq C++ 77980b0ce0bfSmrg # Make sure the PIC flag is empty. It appears that all Alpha 77990b0ce0bfSmrg # Linux and Compaq Tru64 Unix objects are PIC. 78000b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)= 78010b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 78020b0ce0bfSmrg ;; 78030b0ce0bfSmrg xlc* | xlC* | bgxl[[cC]]* | mpixl[[cC]]*) 78040b0ce0bfSmrg # IBM XL 8.0, 9.0 on PPC and BlueGene 78050b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 78060b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' 78070b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' 78080b0ce0bfSmrg ;; 78090b0ce0bfSmrg *) 78100b0ce0bfSmrg case `$CC -V 2>&1 | $SED 5q` in 78110b0ce0bfSmrg *Sun\ C*) 78120b0ce0bfSmrg # Sun C++ 5.9 78130b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 78140b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 78150b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' 78160b0ce0bfSmrg ;; 78170b0ce0bfSmrg esac 78180b0ce0bfSmrg ;; 78190b0ce0bfSmrg esac 78200b0ce0bfSmrg ;; 78210b0ce0bfSmrg lynxos*) 78220b0ce0bfSmrg ;; 78230b0ce0bfSmrg m88k*) 78240b0ce0bfSmrg ;; 78250b0ce0bfSmrg mvs*) 78260b0ce0bfSmrg case $cc_basename in 78270b0ce0bfSmrg cxx*) 78280b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall' 78290b0ce0bfSmrg ;; 78300b0ce0bfSmrg *) 78310b0ce0bfSmrg ;; 78320b0ce0bfSmrg esac 78330b0ce0bfSmrg ;; 78340b0ce0bfSmrg netbsd*) 78350b0ce0bfSmrg ;; 78360b0ce0bfSmrg *qnx* | *nto*) 78370b0ce0bfSmrg # QNX uses GNU C++, but need to define -shared option too, otherwise 78380b0ce0bfSmrg # it will coredump. 78390b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' 78400b0ce0bfSmrg ;; 78410b0ce0bfSmrg osf3* | osf4* | osf5*) 78420b0ce0bfSmrg case $cc_basename in 78430b0ce0bfSmrg KCC*) 78440b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' 78450b0ce0bfSmrg ;; 78460b0ce0bfSmrg RCC*) 78470b0ce0bfSmrg # Rational C++ 2.4.1 78480b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 78490b0ce0bfSmrg ;; 78500b0ce0bfSmrg cxx*) 78510b0ce0bfSmrg # Digital/Compaq C++ 78520b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 78530b0ce0bfSmrg # Make sure the PIC flag is empty. It appears that all Alpha 78540b0ce0bfSmrg # Linux and Compaq Tru64 Unix objects are PIC. 78550b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)= 78560b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 78570b0ce0bfSmrg ;; 78580b0ce0bfSmrg *) 78590b0ce0bfSmrg ;; 78600b0ce0bfSmrg esac 78610b0ce0bfSmrg ;; 78620b0ce0bfSmrg psos*) 78630b0ce0bfSmrg ;; 78640b0ce0bfSmrg solaris*) 78650b0ce0bfSmrg case $cc_basename in 78660b0ce0bfSmrg CC* | sunCC*) 78670b0ce0bfSmrg # Sun C++ 4.2, 5.x and Centerline C++ 78680b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 78690b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 78700b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' 78710b0ce0bfSmrg ;; 78720b0ce0bfSmrg gcx*) 78730b0ce0bfSmrg # Green Hills C++ Compiler 78740b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' 78750b0ce0bfSmrg ;; 78760b0ce0bfSmrg *) 78770b0ce0bfSmrg ;; 78780b0ce0bfSmrg esac 78790b0ce0bfSmrg ;; 78800b0ce0bfSmrg sunos4*) 78810b0ce0bfSmrg case $cc_basename in 78820b0ce0bfSmrg CC*) 78830b0ce0bfSmrg # Sun C++ 4.x 78840b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 78850b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 78860b0ce0bfSmrg ;; 78870b0ce0bfSmrg lcc*) 78880b0ce0bfSmrg # Lucid 78890b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 78900b0ce0bfSmrg ;; 78910b0ce0bfSmrg *) 78920b0ce0bfSmrg ;; 78930b0ce0bfSmrg esac 78940b0ce0bfSmrg ;; 78950b0ce0bfSmrg sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) 78960b0ce0bfSmrg case $cc_basename in 78970b0ce0bfSmrg CC*) 78980b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 78990b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 79000b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 79010b0ce0bfSmrg ;; 79020b0ce0bfSmrg esac 79030b0ce0bfSmrg ;; 79040b0ce0bfSmrg tandem*) 79050b0ce0bfSmrg case $cc_basename in 79060b0ce0bfSmrg NCC*) 79070b0ce0bfSmrg # NonStop-UX NCC 3.20 79080b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 79090b0ce0bfSmrg ;; 79100b0ce0bfSmrg *) 79110b0ce0bfSmrg ;; 79120b0ce0bfSmrg esac 79130b0ce0bfSmrg ;; 79140b0ce0bfSmrg vxworks*) 79150b0ce0bfSmrg ;; 79160b0ce0bfSmrg *) 79170b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 79180b0ce0bfSmrg ;; 79190b0ce0bfSmrg esac 79200b0ce0bfSmrg fi 79210b0ce0bfSmrg], 79220b0ce0bfSmrg[ 79230b0ce0bfSmrg if test yes = "$GCC"; then 79240b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 79250b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 7926d31dbc53Smrg 79270b0ce0bfSmrg case $host_os in 79280b0ce0bfSmrg aix*) 79290b0ce0bfSmrg # All AIX code is PIC. 79300b0ce0bfSmrg if test ia64 = "$host_cpu"; then 79310b0ce0bfSmrg # AIX 5 now supports IA64 processor 79320b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 79330b0ce0bfSmrg fi 79340b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 79350b0ce0bfSmrg ;; 7936d31dbc53Smrg 79370b0ce0bfSmrg amigaos*) 79380b0ce0bfSmrg case $host_cpu in 79390b0ce0bfSmrg powerpc) 79400b0ce0bfSmrg # see comment about AmigaOS4 .so support 79410b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 79420b0ce0bfSmrg ;; 79430b0ce0bfSmrg m68k) 79440b0ce0bfSmrg # FIXME: we need at least 68020 code to build shared libraries, but 79450b0ce0bfSmrg # adding the '-m68020' flag to GCC prevents building anything better, 79460b0ce0bfSmrg # like '-m68040'. 79470b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' 79480b0ce0bfSmrg ;; 79490b0ce0bfSmrg esac 79500b0ce0bfSmrg ;; 79511b12faf6Smrg 79520b0ce0bfSmrg beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) 79530b0ce0bfSmrg # PIC is the default for these OSes. 79540b0ce0bfSmrg ;; 7955d31dbc53Smrg 79560b0ce0bfSmrg mingw* | cygwin* | pw32* | os2* | cegcc*) 79570b0ce0bfSmrg # This hack is so that the source file can tell whether it is being 79580b0ce0bfSmrg # built for inclusion in a dll (and should export symbols for example). 79590b0ce0bfSmrg # Although the cygwin gcc ignores -fPIC, still need this for old-style 79600b0ce0bfSmrg # (--disable-auto-import) libraries 79610b0ce0bfSmrg m4_if([$1], [GCJ], [], 79620b0ce0bfSmrg [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) 79630b0ce0bfSmrg case $host_os in 79640b0ce0bfSmrg os2*) 79650b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static' 79660b0ce0bfSmrg ;; 79670b0ce0bfSmrg esac 79680b0ce0bfSmrg ;; 79691b12faf6Smrg 79700b0ce0bfSmrg darwin* | rhapsody*) 79710b0ce0bfSmrg # PIC is the default on this platform 79720b0ce0bfSmrg # Common symbols not allowed in MH_DYLIB files 79730b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' 79740b0ce0bfSmrg ;; 79751b12faf6Smrg 79760b0ce0bfSmrg haiku*) 79770b0ce0bfSmrg # PIC is the default for Haiku. 79780b0ce0bfSmrg # The "-static" flag exists, but is broken. 79790b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)= 79800b0ce0bfSmrg ;; 79811b12faf6Smrg 79820b0ce0bfSmrg hpux*) 79830b0ce0bfSmrg # PIC is the default for 64-bit PA HP-UX, but not for 32-bit 79840b0ce0bfSmrg # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag 79850b0ce0bfSmrg # sets the default TLS model and affects inlining. 79860b0ce0bfSmrg case $host_cpu in 79870b0ce0bfSmrg hppa*64*) 79880b0ce0bfSmrg # +Z the default 79890b0ce0bfSmrg ;; 79900b0ce0bfSmrg *) 79910b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 79920b0ce0bfSmrg ;; 79930b0ce0bfSmrg esac 79940b0ce0bfSmrg ;; 7995d31dbc53Smrg 79960b0ce0bfSmrg interix[[3-9]]*) 79970b0ce0bfSmrg # Interix 3.x gcc -fpic/-fPIC options generate broken code. 79980b0ce0bfSmrg # Instead, we relocate shared libraries at runtime. 79990b0ce0bfSmrg ;; 8000d31dbc53Smrg 80010b0ce0bfSmrg msdosdjgpp*) 80020b0ce0bfSmrg # Just because we use GCC doesn't mean we suddenly get shared libraries 80030b0ce0bfSmrg # on systems that don't support them. 80040b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 80050b0ce0bfSmrg enable_shared=no 80060b0ce0bfSmrg ;; 8007e35d4d8eSmrg 80080b0ce0bfSmrg *nto* | *qnx*) 80090b0ce0bfSmrg # QNX uses GNU C++, but need to define -shared option too, otherwise 80100b0ce0bfSmrg # it will coredump. 80110b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' 80120b0ce0bfSmrg ;; 8013e35d4d8eSmrg 80140b0ce0bfSmrg sysv4*MP*) 80150b0ce0bfSmrg if test -d /usr/nec; then 80160b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic 8017e35d4d8eSmrg fi 80180b0ce0bfSmrg ;; 80191b12faf6Smrg 80200b0ce0bfSmrg *) 80210b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 80220b0ce0bfSmrg ;; 80230b0ce0bfSmrg esac 8024d31dbc53Smrg 80250b0ce0bfSmrg case $cc_basename in 80260b0ce0bfSmrg nvcc*) # Cuda Compiler Driver 2.2 80270b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Xlinker ' 80280b0ce0bfSmrg if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then 80290b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)="-Xcompiler $_LT_TAGVAR(lt_prog_compiler_pic, $1)" 80300b0ce0bfSmrg fi 80310b0ce0bfSmrg ;; 80320b0ce0bfSmrg esac 80330b0ce0bfSmrg else 80340b0ce0bfSmrg # PORTME Check for flag to pass linker flags through the system compiler. 80350b0ce0bfSmrg case $host_os in 80360b0ce0bfSmrg aix*) 80370b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 80380b0ce0bfSmrg if test ia64 = "$host_cpu"; then 80390b0ce0bfSmrg # AIX 5 now supports IA64 processor 80400b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 80410b0ce0bfSmrg else 80420b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' 80430b0ce0bfSmrg fi 80440b0ce0bfSmrg ;; 8045d31dbc53Smrg 80460b0ce0bfSmrg darwin* | rhapsody*) 80470b0ce0bfSmrg # PIC is the default on this platform 80480b0ce0bfSmrg # Common symbols not allowed in MH_DYLIB files 80490b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' 80500b0ce0bfSmrg case $cc_basename in 80510b0ce0bfSmrg nagfor*) 80520b0ce0bfSmrg # NAG Fortran compiler 80530b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,' 80540b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' 80550b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 80560b0ce0bfSmrg ;; 80570b0ce0bfSmrg esac 80580b0ce0bfSmrg ;; 80591b12faf6Smrg 80600b0ce0bfSmrg mingw* | cygwin* | pw32* | os2* | cegcc*) 80610b0ce0bfSmrg # This hack is so that the source file can tell whether it is being 80620b0ce0bfSmrg # built for inclusion in a dll (and should export symbols for example). 80630b0ce0bfSmrg m4_if([$1], [GCJ], [], 80640b0ce0bfSmrg [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) 80650b0ce0bfSmrg case $host_os in 80660b0ce0bfSmrg os2*) 80670b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static' 80680b0ce0bfSmrg ;; 80690b0ce0bfSmrg esac 80700b0ce0bfSmrg ;; 8071d31dbc53Smrg 80720b0ce0bfSmrg hpux9* | hpux10* | hpux11*) 80730b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 80740b0ce0bfSmrg # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but 80750b0ce0bfSmrg # not for PA HP-UX. 80760b0ce0bfSmrg case $host_cpu in 80770b0ce0bfSmrg hppa*64*|ia64*) 80780b0ce0bfSmrg # +Z the default 80790b0ce0bfSmrg ;; 80800b0ce0bfSmrg *) 80810b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' 80820b0ce0bfSmrg ;; 80830b0ce0bfSmrg esac 80840b0ce0bfSmrg # Is there a better lt_prog_compiler_static that works with the bundled CC? 80850b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive' 80860b0ce0bfSmrg ;; 8087d31dbc53Smrg 80880b0ce0bfSmrg irix5* | irix6* | nonstopux*) 80890b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 80900b0ce0bfSmrg # PIC (with -KPIC) is the default. 80910b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 80920b0ce0bfSmrg ;; 8093d31dbc53Smrg 80940b0ce0bfSmrg linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) 80950b0ce0bfSmrg case $cc_basename in 80960b0ce0bfSmrg # old Intel for x86_64, which still supported -KPIC. 80970b0ce0bfSmrg ecc*) 80980b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 80990b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 81000b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 81010b0ce0bfSmrg ;; 81020b0ce0bfSmrg # icc used to be incompatible with GCC. 81030b0ce0bfSmrg # ICC 10 doesn't accept -KPIC any more. 81040b0ce0bfSmrg icc* | ifort*) 81050b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 81060b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 81070b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 81080b0ce0bfSmrg ;; 81090b0ce0bfSmrg # Lahey Fortran 8.1. 81100b0ce0bfSmrg lf95*) 81110b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 81120b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='--shared' 81130b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='--static' 81140b0ce0bfSmrg ;; 81150b0ce0bfSmrg nagfor*) 81160b0ce0bfSmrg # NAG Fortran compiler 81170b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,' 81180b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' 81190b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 81200b0ce0bfSmrg ;; 81210b0ce0bfSmrg tcc*) 81220b0ce0bfSmrg # Fabrice Bellard et al's Tiny C Compiler 81230b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 81240b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 81250b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 81260b0ce0bfSmrg ;; 81270b0ce0bfSmrg pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) 81280b0ce0bfSmrg # Portland Group compilers (*not* the Pentium gcc compiler, 81290b0ce0bfSmrg # which looks to be a dead project) 81300b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 81310b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' 81320b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 81330b0ce0bfSmrg ;; 81340b0ce0bfSmrg ccc*) 81350b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 81360b0ce0bfSmrg # All Alpha code is PIC. 81370b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 81380b0ce0bfSmrg ;; 81390b0ce0bfSmrg xl* | bgxl* | bgf* | mpixl*) 81400b0ce0bfSmrg # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene 81410b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 81420b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' 81430b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' 81440b0ce0bfSmrg ;; 81450b0ce0bfSmrg *) 81460b0ce0bfSmrg case `$CC -V 2>&1 | $SED 5q` in 81470b0ce0bfSmrg *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [[1-7]].* | *Sun*Fortran*\ 8.[[0-3]]*) 81480b0ce0bfSmrg # Sun Fortran 8.3 passes all unrecognized flags to the linker 81490b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 81500b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 81510b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='' 81520b0ce0bfSmrg ;; 81530b0ce0bfSmrg *Sun\ F* | *Sun*Fortran*) 81540b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 81550b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 81560b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' 81570b0ce0bfSmrg ;; 81580b0ce0bfSmrg *Sun\ C*) 81590b0ce0bfSmrg # Sun C 5.9 81600b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 81610b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 81620b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 81630b0ce0bfSmrg ;; 81640b0ce0bfSmrg *Intel*\ [[CF]]*Compiler*) 81650b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 81660b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 81670b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' 81680b0ce0bfSmrg ;; 81690b0ce0bfSmrg *Portland\ Group*) 81700b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 81710b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' 81720b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 81730b0ce0bfSmrg ;; 81740b0ce0bfSmrg esac 81750b0ce0bfSmrg ;; 81760b0ce0bfSmrg esac 81770b0ce0bfSmrg ;; 8178d31dbc53Smrg 81790b0ce0bfSmrg newsos6) 81800b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 81810b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 81820b0ce0bfSmrg ;; 8183d31dbc53Smrg 81840b0ce0bfSmrg *nto* | *qnx*) 81850b0ce0bfSmrg # QNX uses GNU C++, but need to define -shared option too, otherwise 81860b0ce0bfSmrg # it will coredump. 81870b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' 81880b0ce0bfSmrg ;; 81891b12faf6Smrg 81900b0ce0bfSmrg osf3* | osf4* | osf5*) 81910b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 81920b0ce0bfSmrg # All OSF/1 code is PIC. 81930b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 81940b0ce0bfSmrg ;; 81951b12faf6Smrg 81960b0ce0bfSmrg rdos*) 81970b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 81980b0ce0bfSmrg ;; 81991b12faf6Smrg 82000b0ce0bfSmrg solaris*) 82010b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 82020b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 82030b0ce0bfSmrg case $cc_basename in 82040b0ce0bfSmrg f77* | f90* | f95* | sunf77* | sunf90* | sunf95*) 82050b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';; 82060b0ce0bfSmrg *) 82070b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';; 82080b0ce0bfSmrg esac 82090b0ce0bfSmrg ;; 8210d31dbc53Smrg 82110b0ce0bfSmrg sunos4*) 82120b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' 82130b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' 82140b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 82150b0ce0bfSmrg ;; 8216d31dbc53Smrg 82170b0ce0bfSmrg sysv4 | sysv4.2uw2* | sysv4.3*) 82180b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 82190b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 82200b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 82210b0ce0bfSmrg ;; 8222d31dbc53Smrg 82230b0ce0bfSmrg sysv4*MP*) 82240b0ce0bfSmrg if test -d /usr/nec; then 82250b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic' 82260b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 82270b0ce0bfSmrg fi 82280b0ce0bfSmrg ;; 8229d31dbc53Smrg 82300b0ce0bfSmrg sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) 82310b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 82320b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 82330b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 82340b0ce0bfSmrg ;; 8235d31dbc53Smrg 82360b0ce0bfSmrg unicos*) 82370b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 82380b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 82390b0ce0bfSmrg ;; 8240e35d4d8eSmrg 82410b0ce0bfSmrg uts4*) 82420b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 82430b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 82440b0ce0bfSmrg ;; 8245e35d4d8eSmrg 82460b0ce0bfSmrg *) 82470b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 82480b0ce0bfSmrg ;; 8249e35d4d8eSmrg esac 82500b0ce0bfSmrg fi 82510b0ce0bfSmrg]) 82520b0ce0bfSmrgcase $host_os in 82530b0ce0bfSmrg # For platforms that do not support PIC, -DPIC is meaningless: 82540b0ce0bfSmrg *djgpp*) 82550b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)= 82560b0ce0bfSmrg ;; 82570b0ce0bfSmrg *) 82580b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])" 8259e35d4d8eSmrg ;; 8260e35d4d8eSmrgesac 8261e35d4d8eSmrg 82620b0ce0bfSmrgAC_CACHE_CHECK([for $compiler option to produce PIC], 82630b0ce0bfSmrg [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)], 82640b0ce0bfSmrg [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_prog_compiler_pic, $1)]) 82650b0ce0bfSmrg_LT_TAGVAR(lt_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_cv_prog_compiler_pic, $1) 82660b0ce0bfSmrg 82671b12faf6Smrg# 82680b0ce0bfSmrg# Check to make sure the PIC flag actually works. 82691b12faf6Smrg# 82700b0ce0bfSmrgif test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then 82710b0ce0bfSmrg _LT_COMPILER_OPTION([if $compiler PIC flag $_LT_TAGVAR(lt_prog_compiler_pic, $1) works], 82720b0ce0bfSmrg [_LT_TAGVAR(lt_cv_prog_compiler_pic_works, $1)], 82730b0ce0bfSmrg [$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])], [], 82740b0ce0bfSmrg [case $_LT_TAGVAR(lt_prog_compiler_pic, $1) in 82750b0ce0bfSmrg "" | " "*) ;; 82760b0ce0bfSmrg *) _LT_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_TAGVAR(lt_prog_compiler_pic, $1)" ;; 82770b0ce0bfSmrg esac], 82780b0ce0bfSmrg [_LT_TAGVAR(lt_prog_compiler_pic, $1)= 82790b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no]) 82800b0ce0bfSmrgfi 82810b0ce0bfSmrg_LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1], 82820b0ce0bfSmrg [Additional compiler flags for building library objects]) 82831b12faf6Smrg 82840b0ce0bfSmrg_LT_TAGDECL([wl], [lt_prog_compiler_wl], [1], 82850b0ce0bfSmrg [How to pass a linker flag through the compiler]) 82860b0ce0bfSmrg# 82870b0ce0bfSmrg# Check to make sure the static flag actually works. 82880b0ce0bfSmrg# 82890b0ce0bfSmrgwl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_TAGVAR(lt_prog_compiler_static, $1)\" 82900b0ce0bfSmrg_LT_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works], 82910b0ce0bfSmrg _LT_TAGVAR(lt_cv_prog_compiler_static_works, $1), 82920b0ce0bfSmrg $lt_tmp_static_flag, 82930b0ce0bfSmrg [], 82940b0ce0bfSmrg [_LT_TAGVAR(lt_prog_compiler_static, $1)=]) 82950b0ce0bfSmrg_LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1], 82960b0ce0bfSmrg [Compiler flag to prevent dynamic linking]) 82970b0ce0bfSmrg])# _LT_COMPILER_PIC 82981b12faf6Smrg 82991b12faf6Smrg 83000b0ce0bfSmrg# _LT_LINKER_SHLIBS([TAGNAME]) 83010b0ce0bfSmrg# ---------------------------- 83020b0ce0bfSmrg# See if the linker supports building shared libraries. 83030b0ce0bfSmrgm4_defun([_LT_LINKER_SHLIBS], 83040b0ce0bfSmrg[AC_REQUIRE([LT_PATH_LD])dnl 83050b0ce0bfSmrgAC_REQUIRE([LT_PATH_NM])dnl 83060b0ce0bfSmrgm4_require([_LT_PATH_MANIFEST_TOOL])dnl 83070b0ce0bfSmrgm4_require([_LT_FILEUTILS_DEFAULTS])dnl 83080b0ce0bfSmrgm4_require([_LT_DECL_EGREP])dnl 83090b0ce0bfSmrgm4_require([_LT_DECL_SED])dnl 83100b0ce0bfSmrgm4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl 83110b0ce0bfSmrgm4_require([_LT_TAG_COMPILER])dnl 83120b0ce0bfSmrgAC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) 83130b0ce0bfSmrgm4_if([$1], [CXX], [ 83140b0ce0bfSmrg _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' 83150b0ce0bfSmrg _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] 83160b0ce0bfSmrg case $host_os in 83170b0ce0bfSmrg aix[[4-9]]*) 83180b0ce0bfSmrg # If we're using GNU nm, then we don't want the "-C" option. 83190b0ce0bfSmrg # -C means demangle to GNU nm, but means don't demangle to AIX nm. 83200b0ce0bfSmrg # Without the "-l" option, or with the "-B" option, AIX nm treats 83210b0ce0bfSmrg # weak defined symbols like other global defined symbols, whereas 83220b0ce0bfSmrg # GNU nm marks them as "W". 83230b0ce0bfSmrg # While the 'weak' keyword is ignored in the Export File, we need 83240b0ce0bfSmrg # it in the Import File for the 'aix-soname' feature, so we have 83250b0ce0bfSmrg # to replace the "-B" option with "-P" for AIX nm. 83260b0ce0bfSmrg if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then 83270b0ce0bfSmrg _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' 83280b0ce0bfSmrg else 83290b0ce0bfSmrg _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' 83300b0ce0bfSmrg fi 83310b0ce0bfSmrg ;; 83320b0ce0bfSmrg pw32*) 83330b0ce0bfSmrg _LT_TAGVAR(export_symbols_cmds, $1)=$ltdll_cmds 83340b0ce0bfSmrg ;; 83350b0ce0bfSmrg cygwin* | mingw* | cegcc*) 83360b0ce0bfSmrg case $cc_basename in 83370b0ce0bfSmrg cl* | icl*) 83380b0ce0bfSmrg _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' 83390b0ce0bfSmrg ;; 83400b0ce0bfSmrg *) 83410b0ce0bfSmrg _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' 83420b0ce0bfSmrg _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'] 83430b0ce0bfSmrg ;; 83440b0ce0bfSmrg esac 83450b0ce0bfSmrg ;; 83460b0ce0bfSmrg *) 83470b0ce0bfSmrg _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' 83480b0ce0bfSmrg ;; 83490b0ce0bfSmrg esac 83500b0ce0bfSmrg], [ 83510b0ce0bfSmrg runpath_var= 83520b0ce0bfSmrg _LT_TAGVAR(allow_undefined_flag, $1)= 83530b0ce0bfSmrg _LT_TAGVAR(always_export_symbols, $1)=no 83540b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)= 83550b0ce0bfSmrg _LT_TAGVAR(archive_expsym_cmds, $1)= 83560b0ce0bfSmrg _LT_TAGVAR(compiler_needs_object, $1)=no 83570b0ce0bfSmrg _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no 83580b0ce0bfSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)= 83590b0ce0bfSmrg _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' 83600b0ce0bfSmrg _LT_TAGVAR(hardcode_automatic, $1)=no 83610b0ce0bfSmrg _LT_TAGVAR(hardcode_direct, $1)=no 83620b0ce0bfSmrg _LT_TAGVAR(hardcode_direct_absolute, $1)=no 83630b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 83640b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)= 83650b0ce0bfSmrg _LT_TAGVAR(hardcode_minus_L, $1)=no 83660b0ce0bfSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported 83670b0ce0bfSmrg _LT_TAGVAR(inherit_rpath, $1)=no 83680b0ce0bfSmrg _LT_TAGVAR(link_all_deplibs, $1)=unknown 83690b0ce0bfSmrg _LT_TAGVAR(module_cmds, $1)= 83700b0ce0bfSmrg _LT_TAGVAR(module_expsym_cmds, $1)= 83710b0ce0bfSmrg _LT_TAGVAR(old_archive_from_new_cmds, $1)= 83720b0ce0bfSmrg _LT_TAGVAR(old_archive_from_expsyms_cmds, $1)= 83730b0ce0bfSmrg _LT_TAGVAR(thread_safe_flag_spec, $1)= 83740b0ce0bfSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)= 83750b0ce0bfSmrg # include_expsyms should be a list of space-separated symbols to be *always* 83760b0ce0bfSmrg # included in the symbol list 83770b0ce0bfSmrg _LT_TAGVAR(include_expsyms, $1)= 83780b0ce0bfSmrg # exclude_expsyms can be an extended regexp of symbols to exclude 83790b0ce0bfSmrg # it will be wrapped by ' (' and ')$', so one must not match beginning or 83800b0ce0bfSmrg # end of line. Example: 'a|bc|.*d.*' will exclude the symbols 'a' and 'bc', 83810b0ce0bfSmrg # as well as any symbol that contains 'd'. 83820b0ce0bfSmrg _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] 83830b0ce0bfSmrg # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out 83840b0ce0bfSmrg # platforms (ab)use it in PIC code, but their linkers get confused if 83850b0ce0bfSmrg # the symbol is explicitly referenced. Since portable code cannot 83860b0ce0bfSmrg # rely on this symbol name, it's probably fine to never include it in 83870b0ce0bfSmrg # preloaded symbol tables. 83880b0ce0bfSmrg # Exclude shared library initialization/finalization symbols. 83890b0ce0bfSmrgdnl Note also adjust exclude_expsyms for C++ above. 83900b0ce0bfSmrg extract_expsyms_cmds= 83911b12faf6Smrg 83920b0ce0bfSmrg case $host_os in 83930b0ce0bfSmrg cygwin* | mingw* | pw32* | cegcc*) 83940b0ce0bfSmrg # FIXME: the MSVC++ and ICC port hasn't been tested in a loooong time 83950b0ce0bfSmrg # When not using gcc, we currently assume that we are using 83960b0ce0bfSmrg # Microsoft Visual C++ or Intel C++ Compiler. 83970b0ce0bfSmrg if test yes != "$GCC"; then 83980b0ce0bfSmrg with_gnu_ld=no 83990b0ce0bfSmrg fi 84000b0ce0bfSmrg ;; 84010b0ce0bfSmrg interix*) 84020b0ce0bfSmrg # we just hope/assume this is gcc and not c89 (= MSVC++ or ICC) 84030b0ce0bfSmrg with_gnu_ld=yes 84040b0ce0bfSmrg ;; 84050b0ce0bfSmrg openbsd* | bitrig*) 84060b0ce0bfSmrg with_gnu_ld=no 84070b0ce0bfSmrg ;; 84080b0ce0bfSmrg esac 84091b12faf6Smrg 84100b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=yes 84111b12faf6Smrg 84120b0ce0bfSmrg # On some targets, GNU ld is compatible enough with the native linker 84130b0ce0bfSmrg # that we're better off using the native interface for both. 84140b0ce0bfSmrg lt_use_gnu_ld_interface=no 84150b0ce0bfSmrg if test yes = "$with_gnu_ld"; then 84160b0ce0bfSmrg case $host_os in 84170b0ce0bfSmrg aix*) 84180b0ce0bfSmrg # The AIX port of GNU ld has always aspired to compatibility 84190b0ce0bfSmrg # with the native linker. However, as the warning in the GNU ld 84200b0ce0bfSmrg # block says, versions before 2.19.5* couldn't really create working 84210b0ce0bfSmrg # shared libraries, regardless of the interface used. 84220b0ce0bfSmrg case `$LD -v 2>&1` in 84230b0ce0bfSmrg *\ \(GNU\ Binutils\)\ 2.19.5*) ;; 84240b0ce0bfSmrg *\ \(GNU\ Binutils\)\ 2.[[2-9]]*) ;; 84250b0ce0bfSmrg *\ \(GNU\ Binutils\)\ [[3-9]]*) ;; 84260b0ce0bfSmrg *) 84270b0ce0bfSmrg lt_use_gnu_ld_interface=yes 84280b0ce0bfSmrg ;; 84290b0ce0bfSmrg esac 84300b0ce0bfSmrg ;; 84310b0ce0bfSmrg *) 84320b0ce0bfSmrg lt_use_gnu_ld_interface=yes 84330b0ce0bfSmrg ;; 84340b0ce0bfSmrg esac 84350b0ce0bfSmrg fi 84361b12faf6Smrg 84370b0ce0bfSmrg if test yes = "$lt_use_gnu_ld_interface"; then 84380b0ce0bfSmrg # If archive_cmds runs LD, not CC, wlarc should be empty 84390b0ce0bfSmrg wlarc='$wl' 84401b12faf6Smrg 84410b0ce0bfSmrg # Set some defaults for GNU ld with shared library support. These 84420b0ce0bfSmrg # are reset later if shared libraries are not supported. Putting them 84430b0ce0bfSmrg # here allows them to be overridden if necessary. 84440b0ce0bfSmrg runpath_var=LD_RUN_PATH 84450b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' 84460b0ce0bfSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' 84470b0ce0bfSmrg # ancient GNU ld didn't support --whole-archive et. al. 84480b0ce0bfSmrg if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then 84490b0ce0bfSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' 84500b0ce0bfSmrg else 84510b0ce0bfSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)= 84520b0ce0bfSmrg fi 84530b0ce0bfSmrg supports_anon_versioning=no 84540b0ce0bfSmrg case `$LD -v | $SED -e 's/([[^)]]\+)\s\+//' 2>&1` in 84550b0ce0bfSmrg *GNU\ gold*) supports_anon_versioning=yes ;; 84560b0ce0bfSmrg *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11 84570b0ce0bfSmrg *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... 84580b0ce0bfSmrg *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... 84590b0ce0bfSmrg *\ 2.11.*) ;; # other 2.11 versions 84600b0ce0bfSmrg *) supports_anon_versioning=yes ;; 84610b0ce0bfSmrg esac 84621b12faf6Smrg 84630b0ce0bfSmrg # See if GNU ld supports shared libraries. 84640b0ce0bfSmrg case $host_os in 84650b0ce0bfSmrg aix[[3-9]]*) 84660b0ce0bfSmrg # On AIX/PPC, the GNU linker is very broken 84670b0ce0bfSmrg if test ia64 != "$host_cpu"; then 84680b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=no 84690b0ce0bfSmrg cat <<_LT_EOF 1>&2 84701b12faf6Smrg 84710b0ce0bfSmrg*** Warning: the GNU linker, at least up to release 2.19, is reported 84720b0ce0bfSmrg*** to be unable to reliably create shared libraries on AIX. 84730b0ce0bfSmrg*** Therefore, libtool is disabling shared libraries support. If you 84740b0ce0bfSmrg*** really care for shared libraries, you may want to install binutils 84750b0ce0bfSmrg*** 2.20 or above, or modify your PATH so that a non-GNU linker is found. 84760b0ce0bfSmrg*** You will then need to restart the configuration process. 8477d31dbc53Smrg 84780b0ce0bfSmrg_LT_EOF 84790b0ce0bfSmrg fi 84800b0ce0bfSmrg ;; 84811b12faf6Smrg 84820b0ce0bfSmrg amigaos*) 84830b0ce0bfSmrg case $host_cpu in 84840b0ce0bfSmrg powerpc) 84850b0ce0bfSmrg # see comment about AmigaOS4 .so support 84860b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' 84870b0ce0bfSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='' 84880b0ce0bfSmrg ;; 84890b0ce0bfSmrg m68k) 84900b0ce0bfSmrg _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)' 84910b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 84920b0ce0bfSmrg _LT_TAGVAR(hardcode_minus_L, $1)=yes 84930b0ce0bfSmrg ;; 84940b0ce0bfSmrg esac 84950b0ce0bfSmrg ;; 84961b12faf6Smrg 84970b0ce0bfSmrg beos*) 84980b0ce0bfSmrg if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 84990b0ce0bfSmrg _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 85000b0ce0bfSmrg # Joseph Beckenbach <jrb3@best.com> says some releases of gcc 85010b0ce0bfSmrg # support --undefined. This deserves some investigation. FIXME 85020b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' 85030b0ce0bfSmrg else 85040b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=no 85050b0ce0bfSmrg fi 85060b0ce0bfSmrg ;; 85071b12faf6Smrg 85080b0ce0bfSmrg cygwin* | mingw* | pw32* | cegcc*) 85090b0ce0bfSmrg # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, 85100b0ce0bfSmrg # as there is no search path for DLLs. 85110b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 85120b0ce0bfSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-all-symbols' 85130b0ce0bfSmrg _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 85140b0ce0bfSmrg _LT_TAGVAR(always_export_symbols, $1)=no 85150b0ce0bfSmrg _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 85160b0ce0bfSmrg _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' 85170b0ce0bfSmrg _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'] 85181b12faf6Smrg 85190b0ce0bfSmrg if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then 85200b0ce0bfSmrg _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' 85210b0ce0bfSmrg # If the export-symbols file already is a .def file, use it as 85220b0ce0bfSmrg # is; otherwise, prepend EXPORTS... 85230b0ce0bfSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then 85240b0ce0bfSmrg cp $export_symbols $output_objdir/$soname.def; 85250b0ce0bfSmrg else 85260b0ce0bfSmrg echo EXPORTS > $output_objdir/$soname.def; 85270b0ce0bfSmrg cat $export_symbols >> $output_objdir/$soname.def; 85280b0ce0bfSmrg fi~ 85290b0ce0bfSmrg $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' 85300b0ce0bfSmrg else 85310b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=no 85320b0ce0bfSmrg fi 85330b0ce0bfSmrg ;; 85341b12faf6Smrg 85350b0ce0bfSmrg haiku*) 85360b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' 85370b0ce0bfSmrg _LT_TAGVAR(link_all_deplibs, $1)=yes 85380b0ce0bfSmrg ;; 8539d31dbc53Smrg 85400b0ce0bfSmrg os2*) 85410b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 85420b0ce0bfSmrg _LT_TAGVAR(hardcode_minus_L, $1)=yes 85430b0ce0bfSmrg _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 85440b0ce0bfSmrg shrext_cmds=.dll 85450b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ 85460b0ce0bfSmrg $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ 85470b0ce0bfSmrg $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ 85480b0ce0bfSmrg $ECHO EXPORTS >> $output_objdir/$libname.def~ 85490b0ce0bfSmrg emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ 85500b0ce0bfSmrg $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ 85510b0ce0bfSmrg emximp -o $lib $output_objdir/$libname.def' 85520b0ce0bfSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ 85530b0ce0bfSmrg $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ 85540b0ce0bfSmrg $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ 85550b0ce0bfSmrg $ECHO EXPORTS >> $output_objdir/$libname.def~ 85560b0ce0bfSmrg prefix_cmds="$SED"~ 85570b0ce0bfSmrg if test EXPORTS = "`$SED 1q $export_symbols`"; then 85580b0ce0bfSmrg prefix_cmds="$prefix_cmds -e 1d"; 85590b0ce0bfSmrg fi~ 85600b0ce0bfSmrg prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ 85610b0ce0bfSmrg cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ 85620b0ce0bfSmrg $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ 85630b0ce0bfSmrg emximp -o $lib $output_objdir/$libname.def' 85640b0ce0bfSmrg _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' 85650b0ce0bfSmrg _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 85660b0ce0bfSmrg _LT_TAGVAR(file_list_spec, $1)='@' 85670b0ce0bfSmrg ;; 85681b12faf6Smrg 85690b0ce0bfSmrg interix[[3-9]]*) 85700b0ce0bfSmrg _LT_TAGVAR(hardcode_direct, $1)=no 85710b0ce0bfSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 85720b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' 85730b0ce0bfSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' 85740b0ce0bfSmrg # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. 85750b0ce0bfSmrg # Instead, shared libraries are loaded at an image base (0x10000000 by 85760b0ce0bfSmrg # default) and relocated if they conflict, which is a slow very memory 85770b0ce0bfSmrg # consuming and fragmenting process. To avoid this, we pick a random, 85780b0ce0bfSmrg # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link 85790b0ce0bfSmrg # time. Moving up from 0x10000000 also allows more sbrk(2) space. 85800b0ce0bfSmrg _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' 85810b0ce0bfSmrg _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' 85820b0ce0bfSmrg ;; 8583d31dbc53Smrg 85840b0ce0bfSmrg gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) 85850b0ce0bfSmrg tmp_diet=no 85860b0ce0bfSmrg if test linux-dietlibc = "$host_os"; then 85870b0ce0bfSmrg case $cc_basename in 85880b0ce0bfSmrg diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn) 85890b0ce0bfSmrg esac 85900b0ce0bfSmrg fi 85910b0ce0bfSmrg if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ 85920b0ce0bfSmrg && test no = "$tmp_diet" 85930b0ce0bfSmrg then 85940b0ce0bfSmrg tmp_addflag=' $pic_flag' 85950b0ce0bfSmrg tmp_sharedflag='-shared' 85960b0ce0bfSmrg case $cc_basename,$host_cpu in 85970b0ce0bfSmrg pgcc*) # Portland Group C compiler 85980b0ce0bfSmrg _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' 85990b0ce0bfSmrg tmp_addflag=' $pic_flag' 86000b0ce0bfSmrg ;; 86010b0ce0bfSmrg pgf77* | pgf90* | pgf95* | pgfortran*) 86020b0ce0bfSmrg # Portland Group f77 and f90 compilers 86030b0ce0bfSmrg _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' 86040b0ce0bfSmrg tmp_addflag=' $pic_flag -Mnomain' ;; 86050b0ce0bfSmrg ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 86060b0ce0bfSmrg tmp_addflag=' -i_dynamic' ;; 86070b0ce0bfSmrg efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 86080b0ce0bfSmrg tmp_addflag=' -i_dynamic -nofor_main' ;; 86090b0ce0bfSmrg ifc* | ifort*) # Intel Fortran compiler 86100b0ce0bfSmrg tmp_addflag=' -nofor_main' ;; 86110b0ce0bfSmrg lf95*) # Lahey Fortran 8.1 86120b0ce0bfSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)= 86130b0ce0bfSmrg tmp_sharedflag='--shared' ;; 86140b0ce0bfSmrg nagfor*) # NAGFOR 5.3 86150b0ce0bfSmrg tmp_sharedflag='-Wl,-shared' ;; 86160b0ce0bfSmrg xl[[cC]]* | bgxl[[cC]]* | mpixl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below) 86170b0ce0bfSmrg tmp_sharedflag='-qmkshrobj' 86180b0ce0bfSmrg tmp_addflag= ;; 86190b0ce0bfSmrg nvcc*) # Cuda Compiler Driver 2.2 86200b0ce0bfSmrg _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' 86210b0ce0bfSmrg _LT_TAGVAR(compiler_needs_object, $1)=yes 86220b0ce0bfSmrg ;; 86230b0ce0bfSmrg esac 86240b0ce0bfSmrg case `$CC -V 2>&1 | $SED 5q` in 86250b0ce0bfSmrg *Sun\ C*) # Sun C 5.9 86260b0ce0bfSmrg _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' 86270b0ce0bfSmrg _LT_TAGVAR(compiler_needs_object, $1)=yes 86280b0ce0bfSmrg tmp_sharedflag='-G' ;; 86290b0ce0bfSmrg *Sun\ F*) # Sun Fortran 8.3 86300b0ce0bfSmrg tmp_sharedflag='-G' ;; 86310b0ce0bfSmrg esac 86320b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' 8633d31dbc53Smrg 86340b0ce0bfSmrg if test yes = "$supports_anon_versioning"; then 86350b0ce0bfSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ 86360b0ce0bfSmrg cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ 86370b0ce0bfSmrg echo "local: *; };" >> $output_objdir/$libname.ver~ 86380b0ce0bfSmrg $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib' 86390b0ce0bfSmrg fi 8640d31dbc53Smrg 86410b0ce0bfSmrg case $cc_basename in 86420b0ce0bfSmrg tcc*) 86430b0ce0bfSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='-rdynamic' 86440b0ce0bfSmrg ;; 86450b0ce0bfSmrg xlf* | bgf* | bgxlf* | mpixlf*) 86460b0ce0bfSmrg # IBM XL Fortran 10.1 on PPC cannot create shared libs itself 86470b0ce0bfSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive' 86480b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' 86490b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib' 86500b0ce0bfSmrg if test yes = "$supports_anon_versioning"; then 86510b0ce0bfSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ 86520b0ce0bfSmrg cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ 86530b0ce0bfSmrg echo "local: *; };" >> $output_objdir/$libname.ver~ 86540b0ce0bfSmrg $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' 86550b0ce0bfSmrg fi 86560b0ce0bfSmrg ;; 86570b0ce0bfSmrg esac 86580b0ce0bfSmrg else 86590b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=no 86600b0ce0bfSmrg fi 86610b0ce0bfSmrg ;; 8662d31dbc53Smrg 86630b0ce0bfSmrg netbsd*) 86640b0ce0bfSmrg if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then 86650b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' 86660b0ce0bfSmrg wlarc= 86670b0ce0bfSmrg else 86680b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' 86690b0ce0bfSmrg _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' 86700b0ce0bfSmrg fi 86710b0ce0bfSmrg ;; 8672d31dbc53Smrg 86730b0ce0bfSmrg solaris*) 86740b0ce0bfSmrg if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then 86750b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=no 86760b0ce0bfSmrg cat <<_LT_EOF 1>&2 8677d31dbc53Smrg 86780b0ce0bfSmrg*** Warning: The releases 2.8.* of the GNU linker cannot reliably 86790b0ce0bfSmrg*** create shared libraries on Solaris systems. Therefore, libtool 86800b0ce0bfSmrg*** is disabling shared libraries support. We urge you to upgrade GNU 86810b0ce0bfSmrg*** binutils to release 2.9.1 or newer. Another option is to modify 86820b0ce0bfSmrg*** your PATH or compiler configuration so that the native linker is 86830b0ce0bfSmrg*** used, and then restart. 8684d31dbc53Smrg 86850b0ce0bfSmrg_LT_EOF 86860b0ce0bfSmrg elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 86870b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' 86880b0ce0bfSmrg _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' 86890b0ce0bfSmrg else 86900b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=no 86910b0ce0bfSmrg fi 86920b0ce0bfSmrg ;; 8693d31dbc53Smrg 86940b0ce0bfSmrg sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) 86950b0ce0bfSmrg case `$LD -v 2>&1` in 86960b0ce0bfSmrg *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*) 86970b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=no 86980b0ce0bfSmrg cat <<_LT_EOF 1>&2 8699d31dbc53Smrg 87000b0ce0bfSmrg*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 cannot 87010b0ce0bfSmrg*** reliably create shared libraries on SCO systems. Therefore, libtool 87020b0ce0bfSmrg*** is disabling shared libraries support. We urge you to upgrade GNU 87030b0ce0bfSmrg*** binutils to release 2.16.91.0.3 or newer. Another option is to modify 87040b0ce0bfSmrg*** your PATH or compiler configuration so that the native linker is 87050b0ce0bfSmrg*** used, and then restart. 8706d31dbc53Smrg 87070b0ce0bfSmrg_LT_EOF 87080b0ce0bfSmrg ;; 87090b0ce0bfSmrg *) 87100b0ce0bfSmrg # For security reasons, it is highly recommended that you always 87110b0ce0bfSmrg # use absolute paths for naming shared libraries, and exclude the 87120b0ce0bfSmrg # DT_RUNPATH tag from executables and libraries. But doing so 87130b0ce0bfSmrg # requires that you compile everything twice, which is a pain. 87140b0ce0bfSmrg if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 87150b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' 87160b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' 87170b0ce0bfSmrg _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' 87180b0ce0bfSmrg else 87190b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=no 87200b0ce0bfSmrg fi 87210b0ce0bfSmrg ;; 87220b0ce0bfSmrg esac 87230b0ce0bfSmrg ;; 87240b0ce0bfSmrg 87250b0ce0bfSmrg sunos4*) 87260b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' 87270b0ce0bfSmrg wlarc= 87280b0ce0bfSmrg _LT_TAGVAR(hardcode_direct, $1)=yes 87290b0ce0bfSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 87300b0ce0bfSmrg ;; 8731d31dbc53Smrg 8732e35d4d8eSmrg *) 87330b0ce0bfSmrg if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 87340b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' 87350b0ce0bfSmrg _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' 87360b0ce0bfSmrg else 87370b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=no 87380b0ce0bfSmrg fi 87390b0ce0bfSmrg ;; 87400b0ce0bfSmrg esac 87410b0ce0bfSmrg 87420b0ce0bfSmrg if test no = "$_LT_TAGVAR(ld_shlibs, $1)"; then 87430b0ce0bfSmrg runpath_var= 87440b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 87450b0ce0bfSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)= 87460b0ce0bfSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)= 87470b0ce0bfSmrg fi 87480b0ce0bfSmrg else 87490b0ce0bfSmrg # PORTME fill in a description of your system's linker (not GNU ld) 87500b0ce0bfSmrg case $host_os in 87510b0ce0bfSmrg aix3*) 87520b0ce0bfSmrg _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 87530b0ce0bfSmrg _LT_TAGVAR(always_export_symbols, $1)=yes 87540b0ce0bfSmrg _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' 87550b0ce0bfSmrg # Note: this linker hardcodes the directories in LIBPATH if there 87560b0ce0bfSmrg # are no directories specified by -L. 87570b0ce0bfSmrg _LT_TAGVAR(hardcode_minus_L, $1)=yes 87580b0ce0bfSmrg if test yes = "$GCC" && test -z "$lt_prog_compiler_static"; then 87590b0ce0bfSmrg # Neither direct hardcoding nor static linking is supported with a 87600b0ce0bfSmrg # broken collect2. 87610b0ce0bfSmrg _LT_TAGVAR(hardcode_direct, $1)=unsupported 87620b0ce0bfSmrg fi 8763e35d4d8eSmrg ;; 8764d31dbc53Smrg 87650b0ce0bfSmrg aix[[4-9]]*) 87660b0ce0bfSmrg if test ia64 = "$host_cpu"; then 87670b0ce0bfSmrg # On IA64, the linker does run time linking by default, so we don't 87680b0ce0bfSmrg # have to do anything special. 87690b0ce0bfSmrg aix_use_runtimelinking=no 87700b0ce0bfSmrg exp_sym_flag='-Bexport' 87710b0ce0bfSmrg no_entry_flag= 87720b0ce0bfSmrg else 87730b0ce0bfSmrg # If we're using GNU nm, then we don't want the "-C" option. 87740b0ce0bfSmrg # -C means demangle to GNU nm, but means don't demangle to AIX nm. 87750b0ce0bfSmrg # Without the "-l" option, or with the "-B" option, AIX nm treats 87760b0ce0bfSmrg # weak defined symbols like other global defined symbols, whereas 87770b0ce0bfSmrg # GNU nm marks them as "W". 87780b0ce0bfSmrg # While the 'weak' keyword is ignored in the Export File, we need 87790b0ce0bfSmrg # it in the Import File for the 'aix-soname' feature, so we have 87800b0ce0bfSmrg # to replace the "-B" option with "-P" for AIX nm. 87810b0ce0bfSmrg if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then 87820b0ce0bfSmrg _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' 87830b0ce0bfSmrg else 87840b0ce0bfSmrg _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' 87850b0ce0bfSmrg fi 87860b0ce0bfSmrg aix_use_runtimelinking=no 8787d31dbc53Smrg 87880b0ce0bfSmrg # Test if we are trying to use run time linking or normal 87890b0ce0bfSmrg # AIX style linking. If -brtl is somewhere in LDFLAGS, we 87900b0ce0bfSmrg # have runtime linking enabled, and use it for executables. 87910b0ce0bfSmrg # For shared libraries, we enable/disable runtime linking 87920b0ce0bfSmrg # depending on the kind of the shared library created - 87930b0ce0bfSmrg # when "with_aix_soname,aix_use_runtimelinking" is: 87940b0ce0bfSmrg # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables 87950b0ce0bfSmrg # "aix,yes" lib.so shared, rtl:yes, for executables 87960b0ce0bfSmrg # lib.a static archive 87970b0ce0bfSmrg # "both,no" lib.so.V(shr.o) shared, rtl:yes 87980b0ce0bfSmrg # lib.a(lib.so.V) shared, rtl:no, for executables 87990b0ce0bfSmrg # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables 88000b0ce0bfSmrg # lib.a(lib.so.V) shared, rtl:no 88010b0ce0bfSmrg # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables 88020b0ce0bfSmrg # lib.a static archive 88030b0ce0bfSmrg case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) 88040b0ce0bfSmrg for ld_flag in $LDFLAGS; do 88050b0ce0bfSmrg if (test x-brtl = "x$ld_flag" || test x-Wl,-brtl = "x$ld_flag"); then 88060b0ce0bfSmrg aix_use_runtimelinking=yes 88070b0ce0bfSmrg break 88080b0ce0bfSmrg fi 88090b0ce0bfSmrg done 88100b0ce0bfSmrg if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then 88110b0ce0bfSmrg # With aix-soname=svr4, we create the lib.so.V shared archives only, 88120b0ce0bfSmrg # so we don't have lib.a shared libs to link our executables. 88130b0ce0bfSmrg # We have to force runtime linking in this case. 88140b0ce0bfSmrg aix_use_runtimelinking=yes 88150b0ce0bfSmrg LDFLAGS="$LDFLAGS -Wl,-brtl" 88160b0ce0bfSmrg fi 88170b0ce0bfSmrg ;; 88180b0ce0bfSmrg esac 8819d31dbc53Smrg 88200b0ce0bfSmrg exp_sym_flag='-bexport' 88210b0ce0bfSmrg no_entry_flag='-bnoentry' 88220b0ce0bfSmrg fi 8823d31dbc53Smrg 88240b0ce0bfSmrg # When large executables or shared objects are built, AIX ld can 88250b0ce0bfSmrg # have problems creating the table of contents. If linking a library 88260b0ce0bfSmrg # or program results in "error TOC overflow" add -mminimal-toc to 88270b0ce0bfSmrg # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not 88280b0ce0bfSmrg # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. 8829d31dbc53Smrg 88300b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='' 88310b0ce0bfSmrg _LT_TAGVAR(hardcode_direct, $1)=yes 88320b0ce0bfSmrg _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 88330b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)=':' 88340b0ce0bfSmrg _LT_TAGVAR(link_all_deplibs, $1)=yes 88350b0ce0bfSmrg _LT_TAGVAR(file_list_spec, $1)='$wl-f,' 88360b0ce0bfSmrg case $with_aix_soname,$aix_use_runtimelinking in 88370b0ce0bfSmrg aix,*) ;; # traditional, no import file 88380b0ce0bfSmrg svr4,* | *,yes) # use import file 88390b0ce0bfSmrg # The Import File defines what to hardcode. 88400b0ce0bfSmrg _LT_TAGVAR(hardcode_direct, $1)=no 88410b0ce0bfSmrg _LT_TAGVAR(hardcode_direct_absolute, $1)=no 88420b0ce0bfSmrg ;; 88430b0ce0bfSmrg esac 88442a51b5beSmrg 88450b0ce0bfSmrg if test yes = "$GCC"; then 88460b0ce0bfSmrg case $host_os in aix4.[[012]]|aix4.[[012]].*) 88470b0ce0bfSmrg # We only want to do this on AIX 4.2 and lower, the check 88480b0ce0bfSmrg # below for broken collect2 doesn't work under 4.3+ 88490b0ce0bfSmrg collect2name=`$CC -print-prog-name=collect2` 88500b0ce0bfSmrg if test -f "$collect2name" && 88510b0ce0bfSmrg strings "$collect2name" | $GREP resolve_lib_name >/dev/null 88520b0ce0bfSmrg then 88530b0ce0bfSmrg # We have reworked collect2 88540b0ce0bfSmrg : 88550b0ce0bfSmrg else 88560b0ce0bfSmrg # We have old collect2 88570b0ce0bfSmrg _LT_TAGVAR(hardcode_direct, $1)=unsupported 88580b0ce0bfSmrg # It fails to find uninstalled libraries when the uninstalled 88590b0ce0bfSmrg # path is not listed in the libpath. Setting hardcode_minus_L 88600b0ce0bfSmrg # to unsupported forces relinking 88610b0ce0bfSmrg _LT_TAGVAR(hardcode_minus_L, $1)=yes 88620b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 88630b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)= 88640b0ce0bfSmrg fi 88650b0ce0bfSmrg ;; 88660b0ce0bfSmrg esac 88670b0ce0bfSmrg shared_flag='-shared' 88680b0ce0bfSmrg if test yes = "$aix_use_runtimelinking"; then 88690b0ce0bfSmrg shared_flag="$shared_flag "'$wl-G' 88700b0ce0bfSmrg fi 88710b0ce0bfSmrg # Need to ensure runtime linking is disabled for the traditional 88720b0ce0bfSmrg # shared library, or the linker may eventually find shared libraries 88730b0ce0bfSmrg # /with/ Import File - we do not want to mix them. 88740b0ce0bfSmrg shared_flag_aix='-shared' 88750b0ce0bfSmrg shared_flag_svr4='-shared $wl-G' 88760b0ce0bfSmrg else 88770b0ce0bfSmrg # not using gcc 88780b0ce0bfSmrg if test ia64 = "$host_cpu"; then 88790b0ce0bfSmrg # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release 88800b0ce0bfSmrg # chokes on -Wl,-G. The following line is correct: 88810b0ce0bfSmrg shared_flag='-G' 88820b0ce0bfSmrg else 88830b0ce0bfSmrg if test yes = "$aix_use_runtimelinking"; then 88840b0ce0bfSmrg shared_flag='$wl-G' 88850b0ce0bfSmrg else 88860b0ce0bfSmrg shared_flag='$wl-bM:SRE' 88870b0ce0bfSmrg fi 88880b0ce0bfSmrg shared_flag_aix='$wl-bM:SRE' 88890b0ce0bfSmrg shared_flag_svr4='$wl-G' 88900b0ce0bfSmrg fi 88910b0ce0bfSmrg fi 88922a51b5beSmrg 88930b0ce0bfSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-bexpall' 88940b0ce0bfSmrg # It seems that -bexpall does not export symbols beginning with 88950b0ce0bfSmrg # underscore (_), so it is better to generate a list of symbols to export. 88960b0ce0bfSmrg _LT_TAGVAR(always_export_symbols, $1)=yes 88970b0ce0bfSmrg if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then 88980b0ce0bfSmrg # Warning - without using the other runtime loading flags (-brtl), 88990b0ce0bfSmrg # -berok will link without error, but may produce a broken library. 89000b0ce0bfSmrg _LT_TAGVAR(allow_undefined_flag, $1)='-berok' 89010b0ce0bfSmrg # Determine the default libpath from the value encoded in an 89020b0ce0bfSmrg # empty executable. 89030b0ce0bfSmrg _LT_SYS_MODULE_PATH_AIX([$1]) 89040b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" 89050b0ce0bfSmrg _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 89060b0ce0bfSmrg else 89070b0ce0bfSmrg if test ia64 = "$host_cpu"; then 89080b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $libdir:/usr/lib:/lib' 89090b0ce0bfSmrg _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" 89100b0ce0bfSmrg _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" 89110b0ce0bfSmrg else 89120b0ce0bfSmrg # Determine the default libpath from the value encoded in an 89130b0ce0bfSmrg # empty executable. 89140b0ce0bfSmrg _LT_SYS_MODULE_PATH_AIX([$1]) 89150b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" 89160b0ce0bfSmrg # Warning - without using the other run time loading flags, 89170b0ce0bfSmrg # -berok will link without error, but may produce a broken library. 89180b0ce0bfSmrg _LT_TAGVAR(no_undefined_flag, $1)=' $wl-bernotok' 89190b0ce0bfSmrg _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-berok' 89200b0ce0bfSmrg if test yes = "$with_gnu_ld"; then 89210b0ce0bfSmrg # We only use this code for GNU lds that support --whole-archive. 89220b0ce0bfSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive' 89230b0ce0bfSmrg else 89240b0ce0bfSmrg # Exported symbols can be pulled into shared objects from archives 89250b0ce0bfSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' 89260b0ce0bfSmrg fi 89270b0ce0bfSmrg _LT_TAGVAR(archive_cmds_need_lc, $1)=yes 89280b0ce0bfSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d' 89290b0ce0bfSmrg # -brtl affects multiple linker settings, -berok does not and is overridden later 89300b0ce0bfSmrg compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([[, ]]\\)%-berok\\1%g"`' 89310b0ce0bfSmrg if test svr4 != "$with_aix_soname"; then 89320b0ce0bfSmrg # This is similar to how AIX traditionally builds its shared libraries. 89330b0ce0bfSmrg _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' 89340b0ce0bfSmrg fi 89350b0ce0bfSmrg if test aix != "$with_aix_soname"; then 89360b0ce0bfSmrg _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' 89370b0ce0bfSmrg else 89380b0ce0bfSmrg # used by -dlpreopen to get the symbols 89390b0ce0bfSmrg _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$MV $output_objdir/$realname.d/$soname $output_objdir' 89400b0ce0bfSmrg fi 89410b0ce0bfSmrg _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$RM -r $output_objdir/$realname.d' 89422a51b5beSmrg fi 89430b0ce0bfSmrg fi 8944e35d4d8eSmrg ;; 8945e35d4d8eSmrg 89460b0ce0bfSmrg amigaos*) 89470b0ce0bfSmrg case $host_cpu in 89480b0ce0bfSmrg powerpc) 89490b0ce0bfSmrg # see comment about AmigaOS4 .so support 89500b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' 89510b0ce0bfSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='' 89520b0ce0bfSmrg ;; 89530b0ce0bfSmrg m68k) 89540b0ce0bfSmrg _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)' 89550b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 89560b0ce0bfSmrg _LT_TAGVAR(hardcode_minus_L, $1)=yes 89570b0ce0bfSmrg ;; 89580b0ce0bfSmrg esac 89590b0ce0bfSmrg ;; 89602a51b5beSmrg 89610b0ce0bfSmrg bsdi[[45]]*) 89620b0ce0bfSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic 89630b0ce0bfSmrg ;; 8964d31dbc53Smrg 89650b0ce0bfSmrg cygwin* | mingw* | pw32* | cegcc*) 89660b0ce0bfSmrg # When not using gcc, we currently assume that we are using 89670b0ce0bfSmrg # Microsoft Visual C++ or Intel C++ Compiler. 89680b0ce0bfSmrg # hardcode_libdir_flag_spec is actually meaningless, as there is 89690b0ce0bfSmrg # no search path for DLLs. 89700b0ce0bfSmrg case $cc_basename in 89710b0ce0bfSmrg cl* | icl*) 89720b0ce0bfSmrg # Native MSVC or ICC 89730b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' 89740b0ce0bfSmrg _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 89750b0ce0bfSmrg _LT_TAGVAR(always_export_symbols, $1)=yes 89760b0ce0bfSmrg _LT_TAGVAR(file_list_spec, $1)='@' 89770b0ce0bfSmrg # Tell ltmain to make .lib files, not .a files. 89780b0ce0bfSmrg libext=lib 89790b0ce0bfSmrg # Tell ltmain to make .dll files, not .so files. 89800b0ce0bfSmrg shrext_cmds=.dll 89810b0ce0bfSmrg # FIXME: Setting linknames here is a bad hack. 89820b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames=' 89830b0ce0bfSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then 89840b0ce0bfSmrg cp "$export_symbols" "$output_objdir/$soname.def"; 89850b0ce0bfSmrg echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp"; 89860b0ce0bfSmrg else 89870b0ce0bfSmrg $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp; 89880b0ce0bfSmrg fi~ 89890b0ce0bfSmrg $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ 89900b0ce0bfSmrg linknames=' 89910b0ce0bfSmrg # The linker will not automatically build a static lib if we build a DLL. 89920b0ce0bfSmrg # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' 89930b0ce0bfSmrg _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 89940b0ce0bfSmrg _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' 89950b0ce0bfSmrg _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' 89960b0ce0bfSmrg # Don't use ranlib 89970b0ce0bfSmrg _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib' 89980b0ce0bfSmrg _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~ 89990b0ce0bfSmrg lt_tool_outputfile="@TOOL_OUTPUT@"~ 90000b0ce0bfSmrg case $lt_outputfile in 90010b0ce0bfSmrg *.exe|*.EXE) ;; 90020b0ce0bfSmrg *) 90030b0ce0bfSmrg lt_outputfile=$lt_outputfile.exe 90040b0ce0bfSmrg lt_tool_outputfile=$lt_tool_outputfile.exe 90050b0ce0bfSmrg ;; 90060b0ce0bfSmrg esac~ 90070b0ce0bfSmrg if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then 90080b0ce0bfSmrg $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; 90090b0ce0bfSmrg $RM "$lt_outputfile.manifest"; 90100b0ce0bfSmrg fi' 90110b0ce0bfSmrg ;; 90120b0ce0bfSmrg *) 90130b0ce0bfSmrg # Assume MSVC and ICC wrapper 90140b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' 90150b0ce0bfSmrg _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 90160b0ce0bfSmrg # Tell ltmain to make .lib files, not .a files. 90170b0ce0bfSmrg libext=lib 90180b0ce0bfSmrg # Tell ltmain to make .dll files, not .so files. 90190b0ce0bfSmrg shrext_cmds=.dll 90200b0ce0bfSmrg # FIXME: Setting linknames here is a bad hack. 90210b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames=' 90220b0ce0bfSmrg # The linker will automatically build a .lib file if we build a DLL. 90230b0ce0bfSmrg _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' 90240b0ce0bfSmrg # FIXME: Should let the user specify the lib program. 90250b0ce0bfSmrg _LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs' 90260b0ce0bfSmrg _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 90270b0ce0bfSmrg ;; 90280b0ce0bfSmrg esac 90290b0ce0bfSmrg ;; 903032b578d3Smrg 90310b0ce0bfSmrg darwin* | rhapsody*) 90320b0ce0bfSmrg _LT_DARWIN_LINKER_FEATURES($1) 9033e35d4d8eSmrg ;; 903432b578d3Smrg 90350b0ce0bfSmrg dgux*) 90360b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 90370b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 90380b0ce0bfSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 90390b0ce0bfSmrg ;; 904032b578d3Smrg 90410b0ce0bfSmrg # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor 90420b0ce0bfSmrg # support. Future versions do this automatically, but an explicit c++rt0.o 90430b0ce0bfSmrg # does not break anything, and helps significantly (at the cost of a little 90440b0ce0bfSmrg # extra space). 90450b0ce0bfSmrg freebsd2.2*) 90460b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' 90470b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 90480b0ce0bfSmrg _LT_TAGVAR(hardcode_direct, $1)=yes 90490b0ce0bfSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 90500b0ce0bfSmrg ;; 90511b12faf6Smrg 90520b0ce0bfSmrg # Unfortunately, older versions of FreeBSD 2 do not have this feature. 90530b0ce0bfSmrg freebsd2.*) 90540b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' 90550b0ce0bfSmrg _LT_TAGVAR(hardcode_direct, $1)=yes 90560b0ce0bfSmrg _LT_TAGVAR(hardcode_minus_L, $1)=yes 90570b0ce0bfSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 90580b0ce0bfSmrg ;; 90591b12faf6Smrg 90600b0ce0bfSmrg # FreeBSD 3 and greater uses gcc -shared to do shared libraries. 90610b0ce0bfSmrg freebsd* | dragonfly* | midnightbsd*) 90620b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' 90630b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 90640b0ce0bfSmrg _LT_TAGVAR(hardcode_direct, $1)=yes 90650b0ce0bfSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 90660b0ce0bfSmrg ;; 906732b578d3Smrg 90680b0ce0bfSmrg hpux9*) 90690b0ce0bfSmrg if test yes = "$GCC"; then 90700b0ce0bfSmrg _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' 90710b0ce0bfSmrg else 90720b0ce0bfSmrg _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' 90730b0ce0bfSmrg fi 90740b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' 90750b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)=: 90760b0ce0bfSmrg _LT_TAGVAR(hardcode_direct, $1)=yes 90771b12faf6Smrg 90780b0ce0bfSmrg # hardcode_minus_L: Not really in the search PATH, 90790b0ce0bfSmrg # but as the default location of the library. 90800b0ce0bfSmrg _LT_TAGVAR(hardcode_minus_L, $1)=yes 90810b0ce0bfSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' 90820b0ce0bfSmrg ;; 90831b12faf6Smrg 90840b0ce0bfSmrg hpux10*) 90850b0ce0bfSmrg if test yes,no = "$GCC,$with_gnu_ld"; then 90860b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' 90870b0ce0bfSmrg else 90880b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' 90890b0ce0bfSmrg fi 90900b0ce0bfSmrg if test no = "$with_gnu_ld"; then 90910b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' 90920b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)=: 90930b0ce0bfSmrg _LT_TAGVAR(hardcode_direct, $1)=yes 90940b0ce0bfSmrg _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 90950b0ce0bfSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' 90960b0ce0bfSmrg # hardcode_minus_L: Not really in the search PATH, 90970b0ce0bfSmrg # but as the default location of the library. 90980b0ce0bfSmrg _LT_TAGVAR(hardcode_minus_L, $1)=yes 90990b0ce0bfSmrg fi 9100e35d4d8eSmrg ;; 91011b12faf6Smrg 91020b0ce0bfSmrg hpux11*) 91030b0ce0bfSmrg if test yes,no = "$GCC,$with_gnu_ld"; then 91040b0ce0bfSmrg case $host_cpu in 91050b0ce0bfSmrg hppa*64*) 91060b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' 91070b0ce0bfSmrg ;; 91080b0ce0bfSmrg ia64*) 91090b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' 91100b0ce0bfSmrg ;; 91110b0ce0bfSmrg *) 91120b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' 91130b0ce0bfSmrg ;; 91140b0ce0bfSmrg esac 91150b0ce0bfSmrg else 91160b0ce0bfSmrg case $host_cpu in 91170b0ce0bfSmrg hppa*64*) 91180b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' 91190b0ce0bfSmrg ;; 91200b0ce0bfSmrg ia64*) 91210b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' 91220b0ce0bfSmrg ;; 91230b0ce0bfSmrg *) 91240b0ce0bfSmrg m4_if($1, [], [ 91250b0ce0bfSmrg # Older versions of the 11.00 compiler do not understand -b yet 91260b0ce0bfSmrg # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does) 91270b0ce0bfSmrg _LT_LINKER_OPTION([if $CC understands -b], 91280b0ce0bfSmrg _LT_TAGVAR(lt_cv_prog_compiler__b, $1), [-b], 91290b0ce0bfSmrg [_LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'], 91300b0ce0bfSmrg [_LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'])], 91310b0ce0bfSmrg [_LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags']) 91320b0ce0bfSmrg ;; 91330b0ce0bfSmrg esac 91340b0ce0bfSmrg fi 91350b0ce0bfSmrg if test no = "$with_gnu_ld"; then 91360b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' 91370b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)=: 913832b578d3Smrg 91390b0ce0bfSmrg case $host_cpu in 91400b0ce0bfSmrg hppa*64*|ia64*) 91410b0ce0bfSmrg _LT_TAGVAR(hardcode_direct, $1)=no 91420b0ce0bfSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 91430b0ce0bfSmrg ;; 91440b0ce0bfSmrg *) 91450b0ce0bfSmrg _LT_TAGVAR(hardcode_direct, $1)=yes 91460b0ce0bfSmrg _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 91470b0ce0bfSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' 914832b578d3Smrg 91490b0ce0bfSmrg # hardcode_minus_L: Not really in the search PATH, 91500b0ce0bfSmrg # but as the default location of the library. 91510b0ce0bfSmrg _LT_TAGVAR(hardcode_minus_L, $1)=yes 91520b0ce0bfSmrg ;; 91530b0ce0bfSmrg esac 91540b0ce0bfSmrg fi 91550b0ce0bfSmrg ;; 915632b578d3Smrg 91570b0ce0bfSmrg irix5* | irix6* | nonstopux*) 91580b0ce0bfSmrg if test yes = "$GCC"; then 91590b0ce0bfSmrg _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' 91600b0ce0bfSmrg # Try to use the -exported_symbol ld option, if it does not 91610b0ce0bfSmrg # work, assume that -exports_file does not work either and 91620b0ce0bfSmrg # implicitly export all symbols. 91630b0ce0bfSmrg # This should be the same for all languages, so no per-tag cache variable. 91640b0ce0bfSmrg AC_CACHE_CHECK([whether the $host_os linker accepts -exported_symbol], 91650b0ce0bfSmrg [lt_cv_irix_exported_symbol], 91660b0ce0bfSmrg [save_LDFLAGS=$LDFLAGS 91670b0ce0bfSmrg LDFLAGS="$LDFLAGS -shared $wl-exported_symbol ${wl}foo $wl-update_registry $wl/dev/null" 91680b0ce0bfSmrg AC_LINK_IFELSE( 91690b0ce0bfSmrg [AC_LANG_SOURCE( 91700b0ce0bfSmrg [AC_LANG_CASE([C], [[int foo (void) { return 0; }]], 91710b0ce0bfSmrg [C++], [[int foo (void) { return 0; }]], 91720b0ce0bfSmrg [Fortran 77], [[ 91730b0ce0bfSmrg subroutine foo 91740b0ce0bfSmrg end]], 91750b0ce0bfSmrg [Fortran], [[ 91760b0ce0bfSmrg subroutine foo 91770b0ce0bfSmrg end]])])], 91780b0ce0bfSmrg [lt_cv_irix_exported_symbol=yes], 91790b0ce0bfSmrg [lt_cv_irix_exported_symbol=no]) 91800b0ce0bfSmrg LDFLAGS=$save_LDFLAGS]) 91810b0ce0bfSmrg if test yes = "$lt_cv_irix_exported_symbol"; then 91820b0ce0bfSmrg _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' 91830b0ce0bfSmrg fi 91840b0ce0bfSmrg else 91850b0ce0bfSmrg _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' 91860b0ce0bfSmrg _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' 91870b0ce0bfSmrg fi 91880b0ce0bfSmrg _LT_TAGVAR(archive_cmds_need_lc, $1)='no' 91890b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' 91900b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)=: 91910b0ce0bfSmrg _LT_TAGVAR(inherit_rpath, $1)=yes 91920b0ce0bfSmrg _LT_TAGVAR(link_all_deplibs, $1)=yes 91930b0ce0bfSmrg ;; 919432b578d3Smrg 91950b0ce0bfSmrg linux*) 91960b0ce0bfSmrg case $cc_basename in 91970b0ce0bfSmrg tcc*) 91980b0ce0bfSmrg # Fabrice Bellard et al's Tiny C Compiler 91990b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=yes 92000b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' 92010b0ce0bfSmrg ;; 92020b0ce0bfSmrg esac 92030b0ce0bfSmrg ;; 920432b578d3Smrg 92050b0ce0bfSmrg netbsd*) 92060b0ce0bfSmrg if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then 92070b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out 92080b0ce0bfSmrg else 92090b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF 92100b0ce0bfSmrg fi 92110b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 92120b0ce0bfSmrg _LT_TAGVAR(hardcode_direct, $1)=yes 92130b0ce0bfSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 92140b0ce0bfSmrg ;; 921532b578d3Smrg 92160b0ce0bfSmrg newsos6) 92170b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 92180b0ce0bfSmrg _LT_TAGVAR(hardcode_direct, $1)=yes 92190b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' 92200b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)=: 92210b0ce0bfSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 92220b0ce0bfSmrg ;; 922332b578d3Smrg 92240b0ce0bfSmrg *nto* | *qnx*) 92250b0ce0bfSmrg ;; 92261b12faf6Smrg 92270b0ce0bfSmrg openbsd* | bitrig*) 92280b0ce0bfSmrg if test -f /usr/libexec/ld.so; then 92290b0ce0bfSmrg _LT_TAGVAR(hardcode_direct, $1)=yes 92300b0ce0bfSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 92310b0ce0bfSmrg _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 92320b0ce0bfSmrg if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then 92330b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' 92340b0ce0bfSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags $wl-retain-symbols-file,$export_symbols' 92350b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' 92360b0ce0bfSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' 92370b0ce0bfSmrg else 92380b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' 92390b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' 92400b0ce0bfSmrg fi 92410b0ce0bfSmrg else 92420b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=no 92430b0ce0bfSmrg fi 92440b0ce0bfSmrg ;; 92451b12faf6Smrg 92460b0ce0bfSmrg os2*) 92470b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 92480b0ce0bfSmrg _LT_TAGVAR(hardcode_minus_L, $1)=yes 92490b0ce0bfSmrg _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 92500b0ce0bfSmrg shrext_cmds=.dll 92510b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ 92520b0ce0bfSmrg $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ 92530b0ce0bfSmrg $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ 92540b0ce0bfSmrg $ECHO EXPORTS >> $output_objdir/$libname.def~ 92550b0ce0bfSmrg emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ 92560b0ce0bfSmrg $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ 92570b0ce0bfSmrg emximp -o $lib $output_objdir/$libname.def' 92580b0ce0bfSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ 92590b0ce0bfSmrg $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ 92600b0ce0bfSmrg $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ 92610b0ce0bfSmrg $ECHO EXPORTS >> $output_objdir/$libname.def~ 92620b0ce0bfSmrg prefix_cmds="$SED"~ 92630b0ce0bfSmrg if test EXPORTS = "`$SED 1q $export_symbols`"; then 92640b0ce0bfSmrg prefix_cmds="$prefix_cmds -e 1d"; 92650b0ce0bfSmrg fi~ 92660b0ce0bfSmrg prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ 92670b0ce0bfSmrg cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ 92680b0ce0bfSmrg $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ 92690b0ce0bfSmrg emximp -o $lib $output_objdir/$libname.def' 92700b0ce0bfSmrg _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' 92710b0ce0bfSmrg _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 92720b0ce0bfSmrg _LT_TAGVAR(file_list_spec, $1)='@' 92730b0ce0bfSmrg ;; 92741b12faf6Smrg 92750b0ce0bfSmrg osf3*) 92760b0ce0bfSmrg if test yes = "$GCC"; then 92770b0ce0bfSmrg _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' 92780b0ce0bfSmrg _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' 92790b0ce0bfSmrg else 92800b0ce0bfSmrg _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' 92810b0ce0bfSmrg _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' 92820b0ce0bfSmrg fi 92830b0ce0bfSmrg _LT_TAGVAR(archive_cmds_need_lc, $1)='no' 92840b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' 92850b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)=: 92860b0ce0bfSmrg ;; 92871b12faf6Smrg 92880b0ce0bfSmrg osf4* | osf5*) # as osf3* with the addition of -msym flag 92890b0ce0bfSmrg if test yes = "$GCC"; then 92900b0ce0bfSmrg _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' 92910b0ce0bfSmrg _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' 92920b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' 92930b0ce0bfSmrg else 92940b0ce0bfSmrg _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' 92950b0ce0bfSmrg _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' 92960b0ce0bfSmrg _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~ 92970b0ce0bfSmrg $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' 92981b12faf6Smrg 92990b0ce0bfSmrg # Both c and cxx compiler support -rpath directly 93000b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' 93010b0ce0bfSmrg fi 93020b0ce0bfSmrg _LT_TAGVAR(archive_cmds_need_lc, $1)='no' 93030b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)=: 93040b0ce0bfSmrg ;; 9305e35d4d8eSmrg 93060b0ce0bfSmrg solaris*) 93070b0ce0bfSmrg _LT_TAGVAR(no_undefined_flag, $1)=' -z defs' 93080b0ce0bfSmrg if test yes = "$GCC"; then 93090b0ce0bfSmrg wlarc='$wl' 93100b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl-z ${wl}text $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' 93110b0ce0bfSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 93120b0ce0bfSmrg $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' 93130b0ce0bfSmrg else 93140b0ce0bfSmrg case `$CC -V 2>&1` in 93150b0ce0bfSmrg *"Compilers 5.0"*) 93160b0ce0bfSmrg wlarc='' 93170b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$LD -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $linker_flags' 93180b0ce0bfSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 93190b0ce0bfSmrg $LD -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' 93200b0ce0bfSmrg ;; 93210b0ce0bfSmrg *) 93220b0ce0bfSmrg wlarc='$wl' 93230b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $compiler_flags' 93240b0ce0bfSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 93250b0ce0bfSmrg $CC -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' 93260b0ce0bfSmrg ;; 93270b0ce0bfSmrg esac 93280b0ce0bfSmrg fi 93290b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 93300b0ce0bfSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 93310b0ce0bfSmrg case $host_os in 93320b0ce0bfSmrg solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; 93330b0ce0bfSmrg *) 93340b0ce0bfSmrg # The compiler driver will combine and reorder linker options, 93350b0ce0bfSmrg # but understands '-z linker_flag'. GCC discards it without '$wl', 93360b0ce0bfSmrg # but is careful enough not to reorder. 93370b0ce0bfSmrg # Supported since Solaris 2.6 (maybe 2.5.1?) 93380b0ce0bfSmrg if test yes = "$GCC"; then 93390b0ce0bfSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract' 93400b0ce0bfSmrg else 93410b0ce0bfSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' 93420b0ce0bfSmrg fi 93430b0ce0bfSmrg ;; 93440b0ce0bfSmrg esac 93450b0ce0bfSmrg _LT_TAGVAR(link_all_deplibs, $1)=yes 93460b0ce0bfSmrg ;; 93471b12faf6Smrg 93480b0ce0bfSmrg sunos4*) 93490b0ce0bfSmrg if test sequent = "$host_vendor"; then 93500b0ce0bfSmrg # Use $CC to link under sequent, because it throws in some extra .o 93510b0ce0bfSmrg # files that make .init and .fini sections work. 93520b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h $soname -o $lib $libobjs $deplibs $compiler_flags' 93530b0ce0bfSmrg else 93540b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' 93550b0ce0bfSmrg fi 93560b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 93570b0ce0bfSmrg _LT_TAGVAR(hardcode_direct, $1)=yes 93580b0ce0bfSmrg _LT_TAGVAR(hardcode_minus_L, $1)=yes 93590b0ce0bfSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 93600b0ce0bfSmrg ;; 93611b12faf6Smrg 93620b0ce0bfSmrg sysv4) 93630b0ce0bfSmrg case $host_vendor in 93640b0ce0bfSmrg sni) 93650b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 93660b0ce0bfSmrg _LT_TAGVAR(hardcode_direct, $1)=yes # is this really true??? 93670b0ce0bfSmrg ;; 93680b0ce0bfSmrg siemens) 93690b0ce0bfSmrg ## LD is ld it makes a PLAMLIB 93700b0ce0bfSmrg ## CC just makes a GrossModule. 93710b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags' 93720b0ce0bfSmrg _LT_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs' 93730b0ce0bfSmrg _LT_TAGVAR(hardcode_direct, $1)=no 93740b0ce0bfSmrg ;; 93750b0ce0bfSmrg motorola) 93760b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 93770b0ce0bfSmrg _LT_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie 93780b0ce0bfSmrg ;; 93790b0ce0bfSmrg esac 93800b0ce0bfSmrg runpath_var='LD_RUN_PATH' 93810b0ce0bfSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 93820b0ce0bfSmrg ;; 93831b12faf6Smrg 93840b0ce0bfSmrg sysv4.3*) 93850b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 93860b0ce0bfSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 93870b0ce0bfSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport' 93880b0ce0bfSmrg ;; 93891b12faf6Smrg 93900b0ce0bfSmrg sysv4*MP*) 93910b0ce0bfSmrg if test -d /usr/nec; then 93920b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 93930b0ce0bfSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 93940b0ce0bfSmrg runpath_var=LD_RUN_PATH 93950b0ce0bfSmrg hardcode_runpath_var=yes 93960b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=yes 93970b0ce0bfSmrg fi 93980b0ce0bfSmrg ;; 93991b12faf6Smrg 94000b0ce0bfSmrg sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) 94010b0ce0bfSmrg _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' 94020b0ce0bfSmrg _LT_TAGVAR(archive_cmds_need_lc, $1)=no 94030b0ce0bfSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 94040b0ce0bfSmrg runpath_var='LD_RUN_PATH' 94051b12faf6Smrg 94060b0ce0bfSmrg if test yes = "$GCC"; then 94070b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 94080b0ce0bfSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 94090b0ce0bfSmrg else 94100b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 94110b0ce0bfSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 94120b0ce0bfSmrg fi 94130b0ce0bfSmrg ;; 94141b12faf6Smrg 94150b0ce0bfSmrg sysv5* | sco3.2v5* | sco5v6*) 94160b0ce0bfSmrg # Note: We CANNOT use -z defs as we might desire, because we do not 94170b0ce0bfSmrg # link with -lc, and that would cause any symbols used from libc to 94180b0ce0bfSmrg # always be unresolved, which means just about no library would 94190b0ce0bfSmrg # ever link correctly. If we're not using GNU ld we use -z text 94200b0ce0bfSmrg # though, which does catch some bad symbols but isn't as heavy-handed 94210b0ce0bfSmrg # as -z defs. 94220b0ce0bfSmrg _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' 94230b0ce0bfSmrg _LT_TAGVAR(allow_undefined_flag, $1)='$wl-z,nodefs' 94240b0ce0bfSmrg _LT_TAGVAR(archive_cmds_need_lc, $1)=no 94250b0ce0bfSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 94260b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R,$libdir' 94270b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)=':' 94280b0ce0bfSmrg _LT_TAGVAR(link_all_deplibs, $1)=yes 94290b0ce0bfSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Bexport' 94300b0ce0bfSmrg runpath_var='LD_RUN_PATH' 94311b12faf6Smrg 94320b0ce0bfSmrg if test yes = "$GCC"; then 94330b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 94340b0ce0bfSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 94350b0ce0bfSmrg else 94360b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 94370b0ce0bfSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 94380b0ce0bfSmrg fi 94390b0ce0bfSmrg ;; 94401b12faf6Smrg 94410b0ce0bfSmrg uts4*) 94420b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 94430b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 94440b0ce0bfSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 94450b0ce0bfSmrg ;; 94461b12faf6Smrg 94470b0ce0bfSmrg *) 94480b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=no 94490b0ce0bfSmrg ;; 94500b0ce0bfSmrg esac 94511b12faf6Smrg 94520b0ce0bfSmrg if test sni = "$host_vendor"; then 94530b0ce0bfSmrg case $host in 94540b0ce0bfSmrg sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) 94550b0ce0bfSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Blargedynsym' 94560b0ce0bfSmrg ;; 94570b0ce0bfSmrg esac 94580b0ce0bfSmrg fi 94590b0ce0bfSmrg fi 94600b0ce0bfSmrg]) 94610b0ce0bfSmrgAC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) 94620b0ce0bfSmrgtest no = "$_LT_TAGVAR(ld_shlibs, $1)" && can_build_shared=no 94631b12faf6Smrg 94640b0ce0bfSmrg_LT_TAGVAR(with_gnu_ld, $1)=$with_gnu_ld 94651b12faf6Smrg 94660b0ce0bfSmrg_LT_DECL([], [libext], [0], [Old archive suffix (normally "a")])dnl 94670b0ce0bfSmrg_LT_DECL([], [shrext_cmds], [1], [Shared library suffix (normally ".so")])dnl 94680b0ce0bfSmrg_LT_DECL([], [extract_expsyms_cmds], [2], 94690b0ce0bfSmrg [The commands to extract the exported symbol list from a shared archive]) 94701b12faf6Smrg 94710b0ce0bfSmrg# 94720b0ce0bfSmrg# Do we need to explicitly link libc? 94730b0ce0bfSmrg# 94740b0ce0bfSmrgcase "x$_LT_TAGVAR(archive_cmds_need_lc, $1)" in 94750b0ce0bfSmrgx|xyes) 94760b0ce0bfSmrg # Assume -lc should be added 94770b0ce0bfSmrg _LT_TAGVAR(archive_cmds_need_lc, $1)=yes 94781b12faf6Smrg 94790b0ce0bfSmrg if test yes,yes = "$GCC,$enable_shared"; then 94800b0ce0bfSmrg case $_LT_TAGVAR(archive_cmds, $1) in 94810b0ce0bfSmrg *'~'*) 94820b0ce0bfSmrg # FIXME: we may have to deal with multi-command sequences. 94830b0ce0bfSmrg ;; 94840b0ce0bfSmrg '$CC '*) 94850b0ce0bfSmrg # Test whether the compiler implicitly links with -lc since on some 94860b0ce0bfSmrg # systems, -lgcc has to come before -lc. If gcc already passes -lc 94870b0ce0bfSmrg # to ld, don't add -lc before -lgcc. 94880b0ce0bfSmrg AC_CACHE_CHECK([whether -lc should be explicitly linked in], 94890b0ce0bfSmrg [lt_cv_]_LT_TAGVAR(archive_cmds_need_lc, $1), 94900b0ce0bfSmrg [$RM conftest* 94910b0ce0bfSmrg echo "$lt_simple_compile_test_code" > conftest.$ac_ext 9492e35d4d8eSmrg 94930b0ce0bfSmrg if AC_TRY_EVAL(ac_compile) 2>conftest.err; then 94940b0ce0bfSmrg soname=conftest 94950b0ce0bfSmrg lib=conftest 94960b0ce0bfSmrg libobjs=conftest.$ac_objext 94970b0ce0bfSmrg deplibs= 94980b0ce0bfSmrg wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) 94990b0ce0bfSmrg pic_flag=$_LT_TAGVAR(lt_prog_compiler_pic, $1) 95000b0ce0bfSmrg compiler_flags=-v 95010b0ce0bfSmrg linker_flags=-v 95020b0ce0bfSmrg verstring= 95030b0ce0bfSmrg output_objdir=. 95040b0ce0bfSmrg libname=conftest 95050b0ce0bfSmrg lt_save_allow_undefined_flag=$_LT_TAGVAR(allow_undefined_flag, $1) 95060b0ce0bfSmrg _LT_TAGVAR(allow_undefined_flag, $1)= 95070b0ce0bfSmrg if AC_TRY_EVAL(_LT_TAGVAR(archive_cmds, $1) 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 95080b0ce0bfSmrg then 95090b0ce0bfSmrg lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=no 95100b0ce0bfSmrg else 95110b0ce0bfSmrg lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=yes 95120b0ce0bfSmrg fi 95130b0ce0bfSmrg _LT_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag 95140b0ce0bfSmrg else 95150b0ce0bfSmrg cat conftest.err 1>&5 95160b0ce0bfSmrg fi 95170b0ce0bfSmrg $RM conftest* 95180b0ce0bfSmrg ]) 95190b0ce0bfSmrg _LT_TAGVAR(archive_cmds_need_lc, $1)=$lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1) 95200b0ce0bfSmrg ;; 95210b0ce0bfSmrg esac 95220b0ce0bfSmrg fi 95230b0ce0bfSmrg ;; 95240b0ce0bfSmrgesac 9525e35d4d8eSmrg 95260b0ce0bfSmrg_LT_TAGDECL([build_libtool_need_lc], [archive_cmds_need_lc], [0], 95270b0ce0bfSmrg [Whether or not to add -lc for building shared libraries]) 95280b0ce0bfSmrg_LT_TAGDECL([allow_libtool_libs_with_static_runtimes], 95290b0ce0bfSmrg [enable_shared_with_static_runtimes], [0], 95300b0ce0bfSmrg [Whether or not to disallow shared libs when runtime libs are static]) 95310b0ce0bfSmrg_LT_TAGDECL([], [export_dynamic_flag_spec], [1], 95320b0ce0bfSmrg [Compiler flag to allow reflexive dlopens]) 95330b0ce0bfSmrg_LT_TAGDECL([], [whole_archive_flag_spec], [1], 95340b0ce0bfSmrg [Compiler flag to generate shared objects directly from archives]) 95350b0ce0bfSmrg_LT_TAGDECL([], [compiler_needs_object], [1], 95360b0ce0bfSmrg [Whether the compiler copes with passing no objects directly]) 95370b0ce0bfSmrg_LT_TAGDECL([], [old_archive_from_new_cmds], [2], 95380b0ce0bfSmrg [Create an old-style archive from a shared archive]) 95390b0ce0bfSmrg_LT_TAGDECL([], [old_archive_from_expsyms_cmds], [2], 95400b0ce0bfSmrg [Create a temporary old-style archive to link instead of a shared archive]) 95410b0ce0bfSmrg_LT_TAGDECL([], [archive_cmds], [2], [Commands used to build a shared archive]) 95420b0ce0bfSmrg_LT_TAGDECL([], [archive_expsym_cmds], [2]) 95430b0ce0bfSmrg_LT_TAGDECL([], [module_cmds], [2], 95440b0ce0bfSmrg [Commands used to build a loadable module if different from building 95450b0ce0bfSmrg a shared archive.]) 95460b0ce0bfSmrg_LT_TAGDECL([], [module_expsym_cmds], [2]) 95470b0ce0bfSmrg_LT_TAGDECL([], [with_gnu_ld], [1], 95480b0ce0bfSmrg [Whether we are building with GNU ld or not]) 95490b0ce0bfSmrg_LT_TAGDECL([], [allow_undefined_flag], [1], 95500b0ce0bfSmrg [Flag that allows shared libraries with undefined symbols to be built]) 95510b0ce0bfSmrg_LT_TAGDECL([], [no_undefined_flag], [1], 95520b0ce0bfSmrg [Flag that enforces no undefined symbols]) 95530b0ce0bfSmrg_LT_TAGDECL([], [hardcode_libdir_flag_spec], [1], 95540b0ce0bfSmrg [Flag to hardcode $libdir into a binary during linking. 95550b0ce0bfSmrg This must work even if $libdir does not exist]) 95560b0ce0bfSmrg_LT_TAGDECL([], [hardcode_libdir_separator], [1], 95570b0ce0bfSmrg [Whether we need a single "-rpath" flag with a separated argument]) 95580b0ce0bfSmrg_LT_TAGDECL([], [hardcode_direct], [0], 95590b0ce0bfSmrg [Set to "yes" if using DIR/libNAME$shared_ext during linking hardcodes 95600b0ce0bfSmrg DIR into the resulting binary]) 95610b0ce0bfSmrg_LT_TAGDECL([], [hardcode_direct_absolute], [0], 95620b0ce0bfSmrg [Set to "yes" if using DIR/libNAME$shared_ext during linking hardcodes 95630b0ce0bfSmrg DIR into the resulting binary and the resulting library dependency is 95640b0ce0bfSmrg "absolute", i.e impossible to change by setting $shlibpath_var if the 95650b0ce0bfSmrg library is relocated]) 95660b0ce0bfSmrg_LT_TAGDECL([], [hardcode_minus_L], [0], 95670b0ce0bfSmrg [Set to "yes" if using the -LDIR flag during linking hardcodes DIR 95680b0ce0bfSmrg into the resulting binary]) 95690b0ce0bfSmrg_LT_TAGDECL([], [hardcode_shlibpath_var], [0], 95700b0ce0bfSmrg [Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR 95710b0ce0bfSmrg into the resulting binary]) 95720b0ce0bfSmrg_LT_TAGDECL([], [hardcode_automatic], [0], 95730b0ce0bfSmrg [Set to "yes" if building a shared library automatically hardcodes DIR 95740b0ce0bfSmrg into the library and all subsequent libraries and executables linked 95750b0ce0bfSmrg against it]) 95760b0ce0bfSmrg_LT_TAGDECL([], [inherit_rpath], [0], 95770b0ce0bfSmrg [Set to yes if linker adds runtime paths of dependent libraries 95780b0ce0bfSmrg to runtime path list]) 95790b0ce0bfSmrg_LT_TAGDECL([], [link_all_deplibs], [0], 95800b0ce0bfSmrg [Whether libtool must link a program against all its dependency libraries]) 95810b0ce0bfSmrg_LT_TAGDECL([], [always_export_symbols], [0], 95820b0ce0bfSmrg [Set to "yes" if exported symbols are required]) 95830b0ce0bfSmrg_LT_TAGDECL([], [export_symbols_cmds], [2], 95840b0ce0bfSmrg [The commands to list exported symbols]) 95850b0ce0bfSmrg_LT_TAGDECL([], [exclude_expsyms], [1], 95860b0ce0bfSmrg [Symbols that should not be listed in the preloaded symbols]) 95870b0ce0bfSmrg_LT_TAGDECL([], [include_expsyms], [1], 95880b0ce0bfSmrg [Symbols that must always be exported]) 95890b0ce0bfSmrg_LT_TAGDECL([], [prelink_cmds], [2], 95900b0ce0bfSmrg [Commands necessary for linking programs (against libraries) with templates]) 95910b0ce0bfSmrg_LT_TAGDECL([], [postlink_cmds], [2], 95920b0ce0bfSmrg [Commands necessary for finishing linking programs]) 95930b0ce0bfSmrg_LT_TAGDECL([], [file_list_spec], [1], 95940b0ce0bfSmrg [Specify filename containing input files]) 95950b0ce0bfSmrgdnl FIXME: Not yet implemented 95960b0ce0bfSmrgdnl _LT_TAGDECL([], [thread_safe_flag_spec], [1], 95970b0ce0bfSmrgdnl [Compiler flag to generate thread safe objects]) 95980b0ce0bfSmrg])# _LT_LINKER_SHLIBS 9599e35d4d8eSmrg 9600e35d4d8eSmrg 96010b0ce0bfSmrg# _LT_LANG_C_CONFIG([TAG]) 96020b0ce0bfSmrg# ------------------------ 96030b0ce0bfSmrg# Ensure that the configuration variables for a C compiler are suitably 96040b0ce0bfSmrg# defined. These variables are subsequently used by _LT_CONFIG to write 96050b0ce0bfSmrg# the compiler configuration to 'libtool'. 96060b0ce0bfSmrgm4_defun([_LT_LANG_C_CONFIG], 96070b0ce0bfSmrg[m4_require([_LT_DECL_EGREP])dnl 96080b0ce0bfSmrglt_save_CC=$CC 96090b0ce0bfSmrgAC_LANG_PUSH(C) 96101b12faf6Smrg 96110b0ce0bfSmrg# Source file extension for C test sources. 96120b0ce0bfSmrgac_ext=c 96131b12faf6Smrg 96140b0ce0bfSmrg# Object file extension for compiled C test sources. 96150b0ce0bfSmrgobjext=o 96160b0ce0bfSmrg_LT_TAGVAR(objext, $1)=$objext 9617e35d4d8eSmrg 96180b0ce0bfSmrg# Code to be used in simple compile tests 96190b0ce0bfSmrglt_simple_compile_test_code="int some_variable = 0;" 9620e35d4d8eSmrg 96210b0ce0bfSmrg# Code to be used in simple link tests 96220b0ce0bfSmrglt_simple_link_test_code='int main(){return(0);}' 9623e35d4d8eSmrg 96240b0ce0bfSmrg_LT_TAG_COMPILER 96250b0ce0bfSmrg# Save the default compiler, since it gets overwritten when the other 96260b0ce0bfSmrg# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP. 96270b0ce0bfSmrgcompiler_DEFAULT=$CC 9628e35d4d8eSmrg 96290b0ce0bfSmrg# save warnings/boilerplate of simple test code 96300b0ce0bfSmrg_LT_COMPILER_BOILERPLATE 96310b0ce0bfSmrg_LT_LINKER_BOILERPLATE 9632e35d4d8eSmrg 96330b0ce0bfSmrgif test -n "$compiler"; then 96340b0ce0bfSmrg _LT_COMPILER_NO_RTTI($1) 96350b0ce0bfSmrg _LT_COMPILER_PIC($1) 96360b0ce0bfSmrg _LT_COMPILER_C_O($1) 96370b0ce0bfSmrg _LT_COMPILER_FILE_LOCKS($1) 96380b0ce0bfSmrg _LT_LINKER_SHLIBS($1) 96390b0ce0bfSmrg _LT_SYS_DYNAMIC_LINKER($1) 96400b0ce0bfSmrg _LT_LINKER_HARDCODE_LIBPATH($1) 96410b0ce0bfSmrg LT_SYS_DLOPEN_SELF 96420b0ce0bfSmrg _LT_CMD_STRIPLIB 964332b578d3Smrg 96440b0ce0bfSmrg # Report what library types will actually be built 96450b0ce0bfSmrg AC_MSG_CHECKING([if libtool supports shared libraries]) 96460b0ce0bfSmrg AC_MSG_RESULT([$can_build_shared]) 964732b578d3Smrg 96480b0ce0bfSmrg AC_MSG_CHECKING([whether to build shared libraries]) 96490b0ce0bfSmrg test no = "$can_build_shared" && enable_shared=no 965032b578d3Smrg 96510b0ce0bfSmrg # On AIX, shared libraries and static libraries use the same namespace, and 96520b0ce0bfSmrg # are all built from PIC. 96530b0ce0bfSmrg case $host_os in 96540b0ce0bfSmrg aix3*) 96550b0ce0bfSmrg test yes = "$enable_shared" && enable_static=no 96560b0ce0bfSmrg if test -n "$RANLIB"; then 96570b0ce0bfSmrg archive_cmds="$archive_cmds~\$RANLIB \$lib" 96580b0ce0bfSmrg postinstall_cmds='$RANLIB $lib' 96590b0ce0bfSmrg fi 96600b0ce0bfSmrg ;; 96611b12faf6Smrg 96620b0ce0bfSmrg aix[[4-9]]*) 96630b0ce0bfSmrg if test ia64 != "$host_cpu"; then 96640b0ce0bfSmrg case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in 96650b0ce0bfSmrg yes,aix,yes) ;; # shared object as lib.so file only 96660b0ce0bfSmrg yes,svr4,*) ;; # shared object as lib.so archive member only 96670b0ce0bfSmrg yes,*) enable_static=no ;; # shared object in lib.a archive as well 96680b0ce0bfSmrg esac 96690b0ce0bfSmrg fi 96700b0ce0bfSmrg ;; 96710b0ce0bfSmrg esac 96720b0ce0bfSmrg AC_MSG_RESULT([$enable_shared]) 96735a81ca49Smrg 96740b0ce0bfSmrg AC_MSG_CHECKING([whether to build static libraries]) 96750b0ce0bfSmrg # Make sure either enable_shared or enable_static is yes. 96760b0ce0bfSmrg test yes = "$enable_shared" || enable_static=yes 96770b0ce0bfSmrg AC_MSG_RESULT([$enable_static]) 967832b578d3Smrg 96790b0ce0bfSmrg _LT_CONFIG($1) 96800b0ce0bfSmrgfi 96810b0ce0bfSmrgAC_LANG_POP 96820b0ce0bfSmrgCC=$lt_save_CC 96830b0ce0bfSmrg])# _LT_LANG_C_CONFIG 96841b12faf6Smrg 9685e35d4d8eSmrg 96860b0ce0bfSmrg# _LT_LANG_CXX_CONFIG([TAG]) 96870b0ce0bfSmrg# -------------------------- 96880b0ce0bfSmrg# Ensure that the configuration variables for a C++ compiler are suitably 96890b0ce0bfSmrg# defined. These variables are subsequently used by _LT_CONFIG to write 96900b0ce0bfSmrg# the compiler configuration to 'libtool'. 96910b0ce0bfSmrgm4_defun([_LT_LANG_CXX_CONFIG], 96920b0ce0bfSmrg[m4_require([_LT_FILEUTILS_DEFAULTS])dnl 96930b0ce0bfSmrgm4_require([_LT_DECL_EGREP])dnl 96940b0ce0bfSmrgm4_require([_LT_PATH_MANIFEST_TOOL])dnl 96950b0ce0bfSmrgif test -n "$CXX" && ( test no != "$CXX" && 96960b0ce0bfSmrg ( (test g++ = "$CXX" && `g++ -v >/dev/null 2>&1` ) || 96970b0ce0bfSmrg (test g++ != "$CXX"))); then 96980b0ce0bfSmrg AC_PROG_CXXCPP 96991b12faf6Smrgelse 97000b0ce0bfSmrg _lt_caught_CXX_error=yes 97010b0ce0bfSmrgfi 970232b578d3Smrg 97030b0ce0bfSmrgAC_LANG_PUSH(C++) 97040b0ce0bfSmrg_LT_TAGVAR(archive_cmds_need_lc, $1)=no 97050b0ce0bfSmrg_LT_TAGVAR(allow_undefined_flag, $1)= 97060b0ce0bfSmrg_LT_TAGVAR(always_export_symbols, $1)=no 97070b0ce0bfSmrg_LT_TAGVAR(archive_expsym_cmds, $1)= 97080b0ce0bfSmrg_LT_TAGVAR(compiler_needs_object, $1)=no 97090b0ce0bfSmrg_LT_TAGVAR(export_dynamic_flag_spec, $1)= 97100b0ce0bfSmrg_LT_TAGVAR(hardcode_direct, $1)=no 97110b0ce0bfSmrg_LT_TAGVAR(hardcode_direct_absolute, $1)=no 97120b0ce0bfSmrg_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 97130b0ce0bfSmrg_LT_TAGVAR(hardcode_libdir_separator, $1)= 97140b0ce0bfSmrg_LT_TAGVAR(hardcode_minus_L, $1)=no 97150b0ce0bfSmrg_LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported 97160b0ce0bfSmrg_LT_TAGVAR(hardcode_automatic, $1)=no 97170b0ce0bfSmrg_LT_TAGVAR(inherit_rpath, $1)=no 97180b0ce0bfSmrg_LT_TAGVAR(module_cmds, $1)= 97190b0ce0bfSmrg_LT_TAGVAR(module_expsym_cmds, $1)= 97200b0ce0bfSmrg_LT_TAGVAR(link_all_deplibs, $1)=unknown 97210b0ce0bfSmrg_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 97220b0ce0bfSmrg_LT_TAGVAR(reload_flag, $1)=$reload_flag 97230b0ce0bfSmrg_LT_TAGVAR(reload_cmds, $1)=$reload_cmds 97240b0ce0bfSmrg_LT_TAGVAR(no_undefined_flag, $1)= 97250b0ce0bfSmrg_LT_TAGVAR(whole_archive_flag_spec, $1)= 97260b0ce0bfSmrg_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no 97271b12faf6Smrg 97280b0ce0bfSmrg# Source file extension for C++ test sources. 97290b0ce0bfSmrgac_ext=cpp 9730e35d4d8eSmrg 97310b0ce0bfSmrg# Object file extension for compiled C++ test sources. 97320b0ce0bfSmrgobjext=o 97330b0ce0bfSmrg_LT_TAGVAR(objext, $1)=$objext 973432b578d3Smrg 97350b0ce0bfSmrg# No sense in running all these tests if we already determined that 97360b0ce0bfSmrg# the CXX compiler isn't working. Some variables (like enable_shared) 97370b0ce0bfSmrg# are currently assumed to apply to all compilers on this platform, 97380b0ce0bfSmrg# and will be corrupted by setting them based on a non-working compiler. 97390b0ce0bfSmrgif test yes != "$_lt_caught_CXX_error"; then 97400b0ce0bfSmrg # Code to be used in simple compile tests 97410b0ce0bfSmrg lt_simple_compile_test_code="int some_variable = 0;" 97422a51b5beSmrg 97430b0ce0bfSmrg # Code to be used in simple link tests 97440b0ce0bfSmrg lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }' 97452a51b5beSmrg 97460b0ce0bfSmrg # ltmain only uses $CC for tagged configurations so make sure $CC is set. 97470b0ce0bfSmrg _LT_TAG_COMPILER 9748e35d4d8eSmrg 97490b0ce0bfSmrg # save warnings/boilerplate of simple test code 97500b0ce0bfSmrg _LT_COMPILER_BOILERPLATE 97510b0ce0bfSmrg _LT_LINKER_BOILERPLATE 9752e35d4d8eSmrg 97530b0ce0bfSmrg # Allow CC to be a program name with arguments. 97540b0ce0bfSmrg lt_save_CC=$CC 97550b0ce0bfSmrg lt_save_CFLAGS=$CFLAGS 97560b0ce0bfSmrg lt_save_LD=$LD 97570b0ce0bfSmrg lt_save_GCC=$GCC 97580b0ce0bfSmrg GCC=$GXX 97590b0ce0bfSmrg lt_save_with_gnu_ld=$with_gnu_ld 97600b0ce0bfSmrg lt_save_path_LD=$lt_cv_path_LD 97610b0ce0bfSmrg if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then 97620b0ce0bfSmrg lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx 97630b0ce0bfSmrg else 97640b0ce0bfSmrg $as_unset lt_cv_prog_gnu_ld 97650b0ce0bfSmrg fi 97660b0ce0bfSmrg if test -n "${lt_cv_path_LDCXX+set}"; then 97670b0ce0bfSmrg lt_cv_path_LD=$lt_cv_path_LDCXX 97680b0ce0bfSmrg else 97690b0ce0bfSmrg $as_unset lt_cv_path_LD 97700b0ce0bfSmrg fi 97710b0ce0bfSmrg test -z "${LDCXX+set}" || LD=$LDCXX 97720b0ce0bfSmrg CC=${CXX-"c++"} 97730b0ce0bfSmrg CFLAGS=$CXXFLAGS 97740b0ce0bfSmrg compiler=$CC 97750b0ce0bfSmrg _LT_TAGVAR(compiler, $1)=$CC 97760b0ce0bfSmrg _LT_CC_BASENAME([$compiler]) 9777e35d4d8eSmrg 97780b0ce0bfSmrg if test -n "$compiler"; then 97790b0ce0bfSmrg # We don't want -fno-exception when compiling C++ code, so set the 97800b0ce0bfSmrg # no_builtin_flag separately 97810b0ce0bfSmrg if test yes = "$GXX"; then 97820b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' 97830b0ce0bfSmrg else 97840b0ce0bfSmrg _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= 97850b0ce0bfSmrg fi 9786e35d4d8eSmrg 97870b0ce0bfSmrg if test yes = "$GXX"; then 97880b0ce0bfSmrg # Set up default GNU C++ configuration 9789e35d4d8eSmrg 97900b0ce0bfSmrg LT_PATH_LD 9791e35d4d8eSmrg 97920b0ce0bfSmrg # Check if GNU C++ uses GNU ld as the underlying linker, since the 97930b0ce0bfSmrg # archiving commands below assume that GNU ld is being used. 97940b0ce0bfSmrg if test yes = "$with_gnu_ld"; then 97950b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' 97960b0ce0bfSmrg _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' 97972a51b5beSmrg 97980b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' 97990b0ce0bfSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' 98005a81ca49Smrg 98010b0ce0bfSmrg # If archive_cmds runs LD, not CC, wlarc should be empty 98020b0ce0bfSmrg # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to 98030b0ce0bfSmrg # investigate it a little bit more. (MM) 98040b0ce0bfSmrg wlarc='$wl' 98055a81ca49Smrg 98060b0ce0bfSmrg # ancient GNU ld didn't support --whole-archive et. al. 98070b0ce0bfSmrg if eval "`$CC -print-prog-name=ld` --help 2>&1" | 98080b0ce0bfSmrg $GREP 'no-whole-archive' > /dev/null; then 98090b0ce0bfSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' 98100b0ce0bfSmrg else 98110b0ce0bfSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)= 98120b0ce0bfSmrg fi 98130b0ce0bfSmrg else 98140b0ce0bfSmrg with_gnu_ld=no 98150b0ce0bfSmrg wlarc= 98165a81ca49Smrg 98170b0ce0bfSmrg # A generic and very simple default shared library creation 98180b0ce0bfSmrg # command for GNU C++ for the case where it uses the native 98190b0ce0bfSmrg # linker, instead of GNU ld. If possible, this setting should 98200b0ce0bfSmrg # overridden to take advantage of the native linker features on 98210b0ce0bfSmrg # the platform it is being used on. 98220b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' 98230b0ce0bfSmrg fi 98245a81ca49Smrg 98250b0ce0bfSmrg # Commands to make compiler produce verbose output that lists 98260b0ce0bfSmrg # what "hidden" libraries, object files and flags are used when 98270b0ce0bfSmrg # linking a shared library. 98280b0ce0bfSmrg output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' 98295a81ca49Smrg 98300b0ce0bfSmrg else 98310b0ce0bfSmrg GXX=no 98320b0ce0bfSmrg with_gnu_ld=no 98330b0ce0bfSmrg wlarc= 98340b0ce0bfSmrg fi 98355a81ca49Smrg 98360b0ce0bfSmrg # PORTME: fill in a description of your system's C++ link characteristics 98370b0ce0bfSmrg AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) 98380b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=yes 98390b0ce0bfSmrg case $host_os in 98400b0ce0bfSmrg aix3*) 98410b0ce0bfSmrg # FIXME: insert proper C++ library support 98420b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=no 98430b0ce0bfSmrg ;; 98440b0ce0bfSmrg aix[[4-9]]*) 98450b0ce0bfSmrg if test ia64 = "$host_cpu"; then 98460b0ce0bfSmrg # On IA64, the linker does run time linking by default, so we don't 98470b0ce0bfSmrg # have to do anything special. 98480b0ce0bfSmrg aix_use_runtimelinking=no 98490b0ce0bfSmrg exp_sym_flag='-Bexport' 98500b0ce0bfSmrg no_entry_flag= 98510b0ce0bfSmrg else 98520b0ce0bfSmrg aix_use_runtimelinking=no 98535a81ca49Smrg 98540b0ce0bfSmrg # Test if we are trying to use run time linking or normal 98550b0ce0bfSmrg # AIX style linking. If -brtl is somewhere in LDFLAGS, we 98560b0ce0bfSmrg # have runtime linking enabled, and use it for executables. 98570b0ce0bfSmrg # For shared libraries, we enable/disable runtime linking 98580b0ce0bfSmrg # depending on the kind of the shared library created - 98590b0ce0bfSmrg # when "with_aix_soname,aix_use_runtimelinking" is: 98600b0ce0bfSmrg # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables 98610b0ce0bfSmrg # "aix,yes" lib.so shared, rtl:yes, for executables 98620b0ce0bfSmrg # lib.a static archive 98630b0ce0bfSmrg # "both,no" lib.so.V(shr.o) shared, rtl:yes 98640b0ce0bfSmrg # lib.a(lib.so.V) shared, rtl:no, for executables 98650b0ce0bfSmrg # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables 98660b0ce0bfSmrg # lib.a(lib.so.V) shared, rtl:no 98670b0ce0bfSmrg # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables 98680b0ce0bfSmrg # lib.a static archive 98690b0ce0bfSmrg case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) 98700b0ce0bfSmrg for ld_flag in $LDFLAGS; do 98710b0ce0bfSmrg case $ld_flag in 98720b0ce0bfSmrg *-brtl*) 98730b0ce0bfSmrg aix_use_runtimelinking=yes 98740b0ce0bfSmrg break 98750b0ce0bfSmrg ;; 98760b0ce0bfSmrg esac 98770b0ce0bfSmrg done 98780b0ce0bfSmrg if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then 98790b0ce0bfSmrg # With aix-soname=svr4, we create the lib.so.V shared archives only, 98800b0ce0bfSmrg # so we don't have lib.a shared libs to link our executables. 98810b0ce0bfSmrg # We have to force runtime linking in this case. 98820b0ce0bfSmrg aix_use_runtimelinking=yes 98830b0ce0bfSmrg LDFLAGS="$LDFLAGS -Wl,-brtl" 98840b0ce0bfSmrg fi 98850b0ce0bfSmrg ;; 98860b0ce0bfSmrg esac 98870b0ce0bfSmrg 98880b0ce0bfSmrg exp_sym_flag='-bexport' 98890b0ce0bfSmrg no_entry_flag='-bnoentry' 98900b0ce0bfSmrg fi 98910b0ce0bfSmrg 98920b0ce0bfSmrg # When large executables or shared objects are built, AIX ld can 98930b0ce0bfSmrg # have problems creating the table of contents. If linking a library 98940b0ce0bfSmrg # or program results in "error TOC overflow" add -mminimal-toc to 98950b0ce0bfSmrg # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not 98960b0ce0bfSmrg # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. 98970b0ce0bfSmrg 98980b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='' 98990b0ce0bfSmrg _LT_TAGVAR(hardcode_direct, $1)=yes 99000b0ce0bfSmrg _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 99010b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)=':' 99020b0ce0bfSmrg _LT_TAGVAR(link_all_deplibs, $1)=yes 99030b0ce0bfSmrg _LT_TAGVAR(file_list_spec, $1)='$wl-f,' 99040b0ce0bfSmrg case $with_aix_soname,$aix_use_runtimelinking in 99050b0ce0bfSmrg aix,*) ;; # no import file 99060b0ce0bfSmrg svr4,* | *,yes) # use import file 99070b0ce0bfSmrg # The Import File defines what to hardcode. 99080b0ce0bfSmrg _LT_TAGVAR(hardcode_direct, $1)=no 99090b0ce0bfSmrg _LT_TAGVAR(hardcode_direct_absolute, $1)=no 99100b0ce0bfSmrg ;; 99110b0ce0bfSmrg esac 99125a81ca49Smrg 99130b0ce0bfSmrg if test yes = "$GXX"; then 99140b0ce0bfSmrg case $host_os in aix4.[[012]]|aix4.[[012]].*) 99150b0ce0bfSmrg # We only want to do this on AIX 4.2 and lower, the check 99160b0ce0bfSmrg # below for broken collect2 doesn't work under 4.3+ 99170b0ce0bfSmrg collect2name=`$CC -print-prog-name=collect2` 99180b0ce0bfSmrg if test -f "$collect2name" && 99190b0ce0bfSmrg strings "$collect2name" | $GREP resolve_lib_name >/dev/null 99200b0ce0bfSmrg then 99210b0ce0bfSmrg # We have reworked collect2 99220b0ce0bfSmrg : 99230b0ce0bfSmrg else 99240b0ce0bfSmrg # We have old collect2 99250b0ce0bfSmrg _LT_TAGVAR(hardcode_direct, $1)=unsupported 99260b0ce0bfSmrg # It fails to find uninstalled libraries when the uninstalled 99270b0ce0bfSmrg # path is not listed in the libpath. Setting hardcode_minus_L 99280b0ce0bfSmrg # to unsupported forces relinking 99290b0ce0bfSmrg _LT_TAGVAR(hardcode_minus_L, $1)=yes 99300b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 99310b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)= 99320b0ce0bfSmrg fi 99330b0ce0bfSmrg esac 99340b0ce0bfSmrg shared_flag='-shared' 99350b0ce0bfSmrg if test yes = "$aix_use_runtimelinking"; then 99360b0ce0bfSmrg shared_flag=$shared_flag' $wl-G' 99370b0ce0bfSmrg fi 99380b0ce0bfSmrg # Need to ensure runtime linking is disabled for the traditional 99390b0ce0bfSmrg # shared library, or the linker may eventually find shared libraries 99400b0ce0bfSmrg # /with/ Import File - we do not want to mix them. 99410b0ce0bfSmrg shared_flag_aix='-shared' 99420b0ce0bfSmrg shared_flag_svr4='-shared $wl-G' 99430b0ce0bfSmrg else 99440b0ce0bfSmrg # not using gcc 99450b0ce0bfSmrg if test ia64 = "$host_cpu"; then 99460b0ce0bfSmrg # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release 99470b0ce0bfSmrg # chokes on -Wl,-G. The following line is correct: 99480b0ce0bfSmrg shared_flag='-G' 99490b0ce0bfSmrg else 99500b0ce0bfSmrg if test yes = "$aix_use_runtimelinking"; then 99510b0ce0bfSmrg shared_flag='$wl-G' 99520b0ce0bfSmrg else 99530b0ce0bfSmrg shared_flag='$wl-bM:SRE' 99540b0ce0bfSmrg fi 99550b0ce0bfSmrg shared_flag_aix='$wl-bM:SRE' 99560b0ce0bfSmrg shared_flag_svr4='$wl-G' 99570b0ce0bfSmrg fi 99580b0ce0bfSmrg fi 995932b578d3Smrg 99600b0ce0bfSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-bexpall' 99610b0ce0bfSmrg # It seems that -bexpall does not export symbols beginning with 99620b0ce0bfSmrg # underscore (_), so it is better to generate a list of symbols to 99630b0ce0bfSmrg # export. 99640b0ce0bfSmrg _LT_TAGVAR(always_export_symbols, $1)=yes 99650b0ce0bfSmrg if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then 99660b0ce0bfSmrg # Warning - without using the other runtime loading flags (-brtl), 99670b0ce0bfSmrg # -berok will link without error, but may produce a broken library. 99680b0ce0bfSmrg # The "-G" linker flag allows undefined symbols. 99690b0ce0bfSmrg _LT_TAGVAR(no_undefined_flag, $1)='-bernotok' 99700b0ce0bfSmrg # Determine the default libpath from the value encoded in an empty 99710b0ce0bfSmrg # executable. 99720b0ce0bfSmrg _LT_SYS_MODULE_PATH_AIX([$1]) 99730b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" 99741b12faf6Smrg 99750b0ce0bfSmrg _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 99760b0ce0bfSmrg else 99770b0ce0bfSmrg if test ia64 = "$host_cpu"; then 99780b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $libdir:/usr/lib:/lib' 99790b0ce0bfSmrg _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" 99800b0ce0bfSmrg _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" 99810b0ce0bfSmrg else 99820b0ce0bfSmrg # Determine the default libpath from the value encoded in an 99830b0ce0bfSmrg # empty executable. 99840b0ce0bfSmrg _LT_SYS_MODULE_PATH_AIX([$1]) 99850b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" 99860b0ce0bfSmrg # Warning - without using the other run time loading flags, 99870b0ce0bfSmrg # -berok will link without error, but may produce a broken library. 99880b0ce0bfSmrg _LT_TAGVAR(no_undefined_flag, $1)=' $wl-bernotok' 99890b0ce0bfSmrg _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-berok' 99900b0ce0bfSmrg if test yes = "$with_gnu_ld"; then 99910b0ce0bfSmrg # We only use this code for GNU lds that support --whole-archive. 99920b0ce0bfSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive' 99930b0ce0bfSmrg else 99940b0ce0bfSmrg # Exported symbols can be pulled into shared objects from archives 99950b0ce0bfSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' 99960b0ce0bfSmrg fi 99970b0ce0bfSmrg _LT_TAGVAR(archive_cmds_need_lc, $1)=yes 99980b0ce0bfSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d' 99990b0ce0bfSmrg # -brtl affects multiple linker settings, -berok does not and is overridden later 100000b0ce0bfSmrg compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([[, ]]\\)%-berok\\1%g"`' 100010b0ce0bfSmrg if test svr4 != "$with_aix_soname"; then 100020b0ce0bfSmrg # This is similar to how AIX traditionally builds its shared 100030b0ce0bfSmrg # libraries. Need -bnortl late, we may have -brtl in LDFLAGS. 100040b0ce0bfSmrg _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' 100050b0ce0bfSmrg fi 100060b0ce0bfSmrg if test aix != "$with_aix_soname"; then 100070b0ce0bfSmrg _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' 100080b0ce0bfSmrg else 100090b0ce0bfSmrg # used by -dlpreopen to get the symbols 100100b0ce0bfSmrg _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$MV $output_objdir/$realname.d/$soname $output_objdir' 100110b0ce0bfSmrg fi 100120b0ce0bfSmrg _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$RM -r $output_objdir/$realname.d' 100130b0ce0bfSmrg fi 100140b0ce0bfSmrg fi 100150b0ce0bfSmrg ;; 100161b12faf6Smrg 100170b0ce0bfSmrg beos*) 100180b0ce0bfSmrg if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then 100190b0ce0bfSmrg _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 100200b0ce0bfSmrg # Joseph Beckenbach <jrb3@best.com> says some releases of gcc 100210b0ce0bfSmrg # support --undefined. This deserves some investigation. FIXME 100220b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' 10023e35d4d8eSmrg else 100240b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=no 10025e35d4d8eSmrg fi 100260b0ce0bfSmrg ;; 100271b12faf6Smrg 100280b0ce0bfSmrg chorus*) 100290b0ce0bfSmrg case $cc_basename in 100300b0ce0bfSmrg *) 100310b0ce0bfSmrg # FIXME: insert proper C++ library support 100320b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=no 100330b0ce0bfSmrg ;; 100340b0ce0bfSmrg esac 100350b0ce0bfSmrg ;; 1003632b578d3Smrg 100370b0ce0bfSmrg cygwin* | mingw* | pw32* | cegcc*) 100380b0ce0bfSmrg case $GXX,$cc_basename in 100390b0ce0bfSmrg ,cl* | no,cl* | ,icl* | no,icl*) 100400b0ce0bfSmrg # Native MSVC or ICC 100410b0ce0bfSmrg # hardcode_libdir_flag_spec is actually meaningless, as there is 100420b0ce0bfSmrg # no search path for DLLs. 100430b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' 100440b0ce0bfSmrg _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 100450b0ce0bfSmrg _LT_TAGVAR(always_export_symbols, $1)=yes 100460b0ce0bfSmrg _LT_TAGVAR(file_list_spec, $1)='@' 100470b0ce0bfSmrg # Tell ltmain to make .lib files, not .a files. 100480b0ce0bfSmrg libext=lib 100490b0ce0bfSmrg # Tell ltmain to make .dll files, not .so files. 100500b0ce0bfSmrg shrext_cmds=.dll 100510b0ce0bfSmrg # FIXME: Setting linknames here is a bad hack. 100520b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames=' 100530b0ce0bfSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then 100540b0ce0bfSmrg cp "$export_symbols" "$output_objdir/$soname.def"; 100550b0ce0bfSmrg echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp"; 100560b0ce0bfSmrg else 100570b0ce0bfSmrg $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp; 100580b0ce0bfSmrg fi~ 100590b0ce0bfSmrg $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ 100600b0ce0bfSmrg linknames=' 100610b0ce0bfSmrg # The linker will not automatically build a static lib if we build a DLL. 100620b0ce0bfSmrg # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' 100630b0ce0bfSmrg _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 100640b0ce0bfSmrg # Don't use ranlib 100650b0ce0bfSmrg _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib' 100660b0ce0bfSmrg _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~ 100670b0ce0bfSmrg lt_tool_outputfile="@TOOL_OUTPUT@"~ 100680b0ce0bfSmrg case $lt_outputfile in 100690b0ce0bfSmrg *.exe|*.EXE) ;; 100700b0ce0bfSmrg *) 100710b0ce0bfSmrg lt_outputfile=$lt_outputfile.exe 100720b0ce0bfSmrg lt_tool_outputfile=$lt_tool_outputfile.exe 100730b0ce0bfSmrg ;; 100740b0ce0bfSmrg esac~ 100750b0ce0bfSmrg func_to_tool_file "$lt_outputfile"~ 100760b0ce0bfSmrg if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then 100770b0ce0bfSmrg $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; 100780b0ce0bfSmrg $RM "$lt_outputfile.manifest"; 100790b0ce0bfSmrg fi' 100800b0ce0bfSmrg ;; 100810b0ce0bfSmrg *) 100820b0ce0bfSmrg # g++ 100830b0ce0bfSmrg # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, 100840b0ce0bfSmrg # as there is no search path for DLLs. 100850b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 100860b0ce0bfSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-all-symbols' 100870b0ce0bfSmrg _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 100880b0ce0bfSmrg _LT_TAGVAR(always_export_symbols, $1)=no 100890b0ce0bfSmrg _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 100902a51b5beSmrg 100910b0ce0bfSmrg if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then 100920b0ce0bfSmrg _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' 100930b0ce0bfSmrg # If the export-symbols file already is a .def file, use it as 100940b0ce0bfSmrg # is; otherwise, prepend EXPORTS... 100950b0ce0bfSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then 100960b0ce0bfSmrg cp $export_symbols $output_objdir/$soname.def; 100970b0ce0bfSmrg else 100980b0ce0bfSmrg echo EXPORTS > $output_objdir/$soname.def; 100990b0ce0bfSmrg cat $export_symbols >> $output_objdir/$soname.def; 101000b0ce0bfSmrg fi~ 101010b0ce0bfSmrg $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' 101020b0ce0bfSmrg else 101030b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=no 101040b0ce0bfSmrg fi 101050b0ce0bfSmrg ;; 101060b0ce0bfSmrg esac 101070b0ce0bfSmrg ;; 101080b0ce0bfSmrg darwin* | rhapsody*) 101090b0ce0bfSmrg _LT_DARWIN_LINKER_FEATURES($1) 101100b0ce0bfSmrg ;; 101111b12faf6Smrg 101120b0ce0bfSmrg os2*) 101130b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 101140b0ce0bfSmrg _LT_TAGVAR(hardcode_minus_L, $1)=yes 101150b0ce0bfSmrg _LT_TAGVAR(allow_undefined_flag, $1)=unsupported 101160b0ce0bfSmrg shrext_cmds=.dll 101170b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ 101180b0ce0bfSmrg $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ 101190b0ce0bfSmrg $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ 101200b0ce0bfSmrg $ECHO EXPORTS >> $output_objdir/$libname.def~ 101210b0ce0bfSmrg emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ 101220b0ce0bfSmrg $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ 101230b0ce0bfSmrg emximp -o $lib $output_objdir/$libname.def' 101240b0ce0bfSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ 101250b0ce0bfSmrg $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ 101260b0ce0bfSmrg $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ 101270b0ce0bfSmrg $ECHO EXPORTS >> $output_objdir/$libname.def~ 101280b0ce0bfSmrg prefix_cmds="$SED"~ 101290b0ce0bfSmrg if test EXPORTS = "`$SED 1q $export_symbols`"; then 101300b0ce0bfSmrg prefix_cmds="$prefix_cmds -e 1d"; 101310b0ce0bfSmrg fi~ 101320b0ce0bfSmrg prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ 101330b0ce0bfSmrg cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ 101340b0ce0bfSmrg $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ 101350b0ce0bfSmrg emximp -o $lib $output_objdir/$libname.def' 101360b0ce0bfSmrg _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' 101370b0ce0bfSmrg _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 101380b0ce0bfSmrg _LT_TAGVAR(file_list_spec, $1)='@' 101390b0ce0bfSmrg ;; 101400b0ce0bfSmrg 101410b0ce0bfSmrg dgux*) 101420b0ce0bfSmrg case $cc_basename in 101430b0ce0bfSmrg ec++*) 101440b0ce0bfSmrg # FIXME: insert proper C++ library support 101450b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=no 101460b0ce0bfSmrg ;; 101470b0ce0bfSmrg ghcx*) 101480b0ce0bfSmrg # Green Hills C++ Compiler 101490b0ce0bfSmrg # FIXME: insert proper C++ library support 101500b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=no 101510b0ce0bfSmrg ;; 101520b0ce0bfSmrg *) 101530b0ce0bfSmrg # FIXME: insert proper C++ library support 101540b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=no 101550b0ce0bfSmrg ;; 101560b0ce0bfSmrg esac 101570b0ce0bfSmrg ;; 101580b0ce0bfSmrg 101590b0ce0bfSmrg freebsd2.*) 101600b0ce0bfSmrg # C++ shared libraries reported to be fairly broken before 101610b0ce0bfSmrg # switch to ELF 101620b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=no 101630b0ce0bfSmrg ;; 10164e35d4d8eSmrg 101650b0ce0bfSmrg freebsd-elf*) 101660b0ce0bfSmrg _LT_TAGVAR(archive_cmds_need_lc, $1)=no 101670b0ce0bfSmrg ;; 101681b12faf6Smrg 101690b0ce0bfSmrg freebsd* | dragonfly* | midnightbsd*) 101700b0ce0bfSmrg # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF 101710b0ce0bfSmrg # conventions 101720b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=yes 101730b0ce0bfSmrg ;; 1017432b578d3Smrg 101750b0ce0bfSmrg haiku*) 101760b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' 101770b0ce0bfSmrg _LT_TAGVAR(link_all_deplibs, $1)=yes 101780b0ce0bfSmrg ;; 101791b12faf6Smrg 101800b0ce0bfSmrg hpux9*) 101810b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' 101820b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)=: 101830b0ce0bfSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' 101840b0ce0bfSmrg _LT_TAGVAR(hardcode_direct, $1)=yes 101850b0ce0bfSmrg _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, 101860b0ce0bfSmrg # but as the default 101870b0ce0bfSmrg # location of the library. 101881b12faf6Smrg 101890b0ce0bfSmrg case $cc_basename in 101900b0ce0bfSmrg CC*) 101910b0ce0bfSmrg # FIXME: insert proper C++ library support 101920b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=no 101930b0ce0bfSmrg ;; 101940b0ce0bfSmrg aCC*) 101950b0ce0bfSmrg _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' 101960b0ce0bfSmrg # Commands to make compiler produce verbose output that lists 101970b0ce0bfSmrg # what "hidden" libraries, object files and flags are used when 101980b0ce0bfSmrg # linking a shared library. 101990b0ce0bfSmrg # 102000b0ce0bfSmrg # There doesn't appear to be a way to prevent this compiler from 102010b0ce0bfSmrg # explicitly linking system object files so we need to strip them 102020b0ce0bfSmrg # from the output so that they don't get included in the library 102030b0ce0bfSmrg # dependencies. 102040b0ce0bfSmrg 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"' 102050b0ce0bfSmrg ;; 102060b0ce0bfSmrg *) 102070b0ce0bfSmrg if test yes = "$GXX"; then 102080b0ce0bfSmrg _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' 102090b0ce0bfSmrg else 102100b0ce0bfSmrg # FIXME: insert proper C++ library support 102110b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=no 102120b0ce0bfSmrg fi 102130b0ce0bfSmrg ;; 102140b0ce0bfSmrg esac 102150b0ce0bfSmrg ;; 102165a81ca49Smrg 102170b0ce0bfSmrg hpux10*|hpux11*) 102180b0ce0bfSmrg if test no = "$with_gnu_ld"; then 102190b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' 102200b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)=: 102215a81ca49Smrg 102220b0ce0bfSmrg case $host_cpu in 102230b0ce0bfSmrg hppa*64*|ia64*) 102240b0ce0bfSmrg ;; 102250b0ce0bfSmrg *) 102260b0ce0bfSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' 102270b0ce0bfSmrg ;; 102280b0ce0bfSmrg esac 102290b0ce0bfSmrg fi 102300b0ce0bfSmrg case $host_cpu in 102310b0ce0bfSmrg hppa*64*|ia64*) 102320b0ce0bfSmrg _LT_TAGVAR(hardcode_direct, $1)=no 102330b0ce0bfSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 102340b0ce0bfSmrg ;; 102350b0ce0bfSmrg *) 102360b0ce0bfSmrg _LT_TAGVAR(hardcode_direct, $1)=yes 102370b0ce0bfSmrg _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 102380b0ce0bfSmrg _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, 102390b0ce0bfSmrg # but as the default 102400b0ce0bfSmrg # location of the library. 102410b0ce0bfSmrg ;; 102420b0ce0bfSmrg esac 102435a81ca49Smrg 102440b0ce0bfSmrg case $cc_basename in 102450b0ce0bfSmrg CC*) 102460b0ce0bfSmrg # FIXME: insert proper C++ library support 102470b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=no 102480b0ce0bfSmrg ;; 102490b0ce0bfSmrg aCC*) 102500b0ce0bfSmrg case $host_cpu in 102510b0ce0bfSmrg hppa*64*) 102520b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 102530b0ce0bfSmrg ;; 102540b0ce0bfSmrg ia64*) 102550b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 102560b0ce0bfSmrg ;; 102570b0ce0bfSmrg *) 102580b0ce0bfSmrg _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' 102590b0ce0bfSmrg ;; 102600b0ce0bfSmrg esac 102610b0ce0bfSmrg # Commands to make compiler produce verbose output that lists 102620b0ce0bfSmrg # what "hidden" libraries, object files and flags are used when 102630b0ce0bfSmrg # linking a shared library. 102640b0ce0bfSmrg # 102650b0ce0bfSmrg # There doesn't appear to be a way to prevent this compiler from 102660b0ce0bfSmrg # explicitly linking system object files so we need to strip them 102670b0ce0bfSmrg # from the output so that they don't get included in the library 102680b0ce0bfSmrg # dependencies. 102690b0ce0bfSmrg 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"' 102700b0ce0bfSmrg ;; 102710b0ce0bfSmrg *) 102720b0ce0bfSmrg if test yes = "$GXX"; then 102730b0ce0bfSmrg if test no = "$with_gnu_ld"; then 102740b0ce0bfSmrg case $host_cpu in 102750b0ce0bfSmrg hppa*64*) 102760b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 102770b0ce0bfSmrg ;; 102780b0ce0bfSmrg ia64*) 102790b0ce0bfSmrg _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' 102800b0ce0bfSmrg ;; 102810b0ce0bfSmrg *) 102820b0ce0bfSmrg _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' 102830b0ce0bfSmrg ;; 102840b0ce0bfSmrg esac 102850b0ce0bfSmrg fi 102860b0ce0bfSmrg else 102870b0ce0bfSmrg # FIXME: insert proper C++ library support 102880b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=no 102890b0ce0bfSmrg fi 102900b0ce0bfSmrg ;; 102910b0ce0bfSmrg esac 102920b0ce0bfSmrg ;; 102935a81ca49Smrg 102940b0ce0bfSmrg interix[[3-9]]*) 102950b0ce0bfSmrg _LT_TAGVAR(hardcode_direct, $1)=no 102960b0ce0bfSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 102970b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' 102980b0ce0bfSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' 102990b0ce0bfSmrg # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. 103000b0ce0bfSmrg # Instead, shared libraries are loaded at an image base (0x10000000 by 103010b0ce0bfSmrg # default) and relocated if they conflict, which is a slow very memory 103020b0ce0bfSmrg # consuming and fragmenting process. To avoid this, we pick a random, 103030b0ce0bfSmrg # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link 103040b0ce0bfSmrg # time. Moving up from 0x10000000 also allows more sbrk(2) space. 103050b0ce0bfSmrg _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' 103060b0ce0bfSmrg _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' 103070b0ce0bfSmrg ;; 103080b0ce0bfSmrg irix5* | irix6*) 103090b0ce0bfSmrg case $cc_basename in 103100b0ce0bfSmrg CC*) 103110b0ce0bfSmrg # SGI C++ 103120b0ce0bfSmrg _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' 103135a81ca49Smrg 103140b0ce0bfSmrg # Archives containing C++ object files must be created using 103150b0ce0bfSmrg # "CC -ar", where "CC" is the IRIX C++ compiler. This is 103160b0ce0bfSmrg # necessary to make sure instantiated templates are included 103170b0ce0bfSmrg # in the archive. 103180b0ce0bfSmrg _LT_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs' 103190b0ce0bfSmrg ;; 103200b0ce0bfSmrg *) 103210b0ce0bfSmrg if test yes = "$GXX"; then 103220b0ce0bfSmrg if test no = "$with_gnu_ld"; then 103230b0ce0bfSmrg _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' 103240b0ce0bfSmrg else 103250b0ce0bfSmrg _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' 103260b0ce0bfSmrg fi 103270b0ce0bfSmrg fi 103280b0ce0bfSmrg _LT_TAGVAR(link_all_deplibs, $1)=yes 103290b0ce0bfSmrg ;; 103300b0ce0bfSmrg esac 103310b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' 103320b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)=: 103330b0ce0bfSmrg _LT_TAGVAR(inherit_rpath, $1)=yes 103340b0ce0bfSmrg ;; 103355a81ca49Smrg 103360b0ce0bfSmrg linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) 103370b0ce0bfSmrg case $cc_basename in 103380b0ce0bfSmrg KCC*) 103390b0ce0bfSmrg # Kuck and Associates, Inc. (KAI) C++ Compiler 103405a81ca49Smrg 103410b0ce0bfSmrg # KCC will only create a shared library if the output file 103420b0ce0bfSmrg # ends with ".so" (or ".sl" for HP-UX), so rename the library 103430b0ce0bfSmrg # to its proper name (with version) after linking. 103440b0ce0bfSmrg _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' 103450b0ce0bfSmrg _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' 103460b0ce0bfSmrg # Commands to make compiler produce verbose output that lists 103470b0ce0bfSmrg # what "hidden" libraries, object files and flags are used when 103480b0ce0bfSmrg # linking a shared library. 103490b0ce0bfSmrg # 103500b0ce0bfSmrg # There doesn't appear to be a way to prevent this compiler from 103510b0ce0bfSmrg # explicitly linking system object files so we need to strip them 103520b0ce0bfSmrg # from the output so that they don't get included in the library 103530b0ce0bfSmrg # dependencies. 103540b0ce0bfSmrg 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"' 103555a81ca49Smrg 103560b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' 103570b0ce0bfSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' 103580b0ce0bfSmrg 103590b0ce0bfSmrg # Archives containing C++ object files must be created using 103600b0ce0bfSmrg # "CC -Bstatic", where "CC" is the KAI C++ compiler. 103610b0ce0bfSmrg _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' 103620b0ce0bfSmrg ;; 103630b0ce0bfSmrg icpc* | ecpc* ) 103640b0ce0bfSmrg # Intel C++ 103650b0ce0bfSmrg with_gnu_ld=yes 103660b0ce0bfSmrg # version 8.0 and above of icpc choke on multiply defined symbols 103670b0ce0bfSmrg # if we add $predep_objects and $postdep_objects, however 7.1 and 103680b0ce0bfSmrg # earlier do not add the objects themselves. 103690b0ce0bfSmrg case `$CC -V 2>&1` in 103700b0ce0bfSmrg *"Version 7."*) 103710b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' 103720b0ce0bfSmrg _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' 103730b0ce0bfSmrg ;; 103740b0ce0bfSmrg *) # Version 8.0 or newer 103750b0ce0bfSmrg tmp_idyn= 103760b0ce0bfSmrg case $host_cpu in 103770b0ce0bfSmrg ia64*) tmp_idyn=' -i_dynamic';; 103780b0ce0bfSmrg esac 103790b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' 103800b0ce0bfSmrg _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' 103810b0ce0bfSmrg ;; 103820b0ce0bfSmrg esac 103830b0ce0bfSmrg _LT_TAGVAR(archive_cmds_need_lc, $1)=no 103840b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' 103850b0ce0bfSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' 103860b0ce0bfSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive' 103870b0ce0bfSmrg ;; 103880b0ce0bfSmrg pgCC* | pgcpp*) 103890b0ce0bfSmrg # Portland Group C++ compiler 103900b0ce0bfSmrg case `$CC -V` in 103910b0ce0bfSmrg *pgCC\ [[1-5]].* | *pgcpp\ [[1-5]].*) 103920b0ce0bfSmrg _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~ 103930b0ce0bfSmrg rm -rf $tpldir~ 103940b0ce0bfSmrg $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~ 103950b0ce0bfSmrg compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"' 103960b0ce0bfSmrg _LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~ 103970b0ce0bfSmrg rm -rf $tpldir~ 103980b0ce0bfSmrg $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~ 103990b0ce0bfSmrg $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~ 104000b0ce0bfSmrg $RANLIB $oldlib' 104010b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~ 104020b0ce0bfSmrg rm -rf $tpldir~ 104030b0ce0bfSmrg $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ 104040b0ce0bfSmrg $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' 104050b0ce0bfSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~ 104060b0ce0bfSmrg rm -rf $tpldir~ 104070b0ce0bfSmrg $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ 104080b0ce0bfSmrg $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' 104090b0ce0bfSmrg ;; 104100b0ce0bfSmrg *) # Version 6 and above use weak symbols 104110b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' 104120b0ce0bfSmrg _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' 104130b0ce0bfSmrg ;; 104140b0ce0bfSmrg esac 104155a81ca49Smrg 104160b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl--rpath $wl$libdir' 104170b0ce0bfSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' 104180b0ce0bfSmrg _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' 104190b0ce0bfSmrg ;; 104200b0ce0bfSmrg cxx*) 104210b0ce0bfSmrg # Compaq C++ 104220b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' 104230b0ce0bfSmrg _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' 104245a81ca49Smrg 104250b0ce0bfSmrg runpath_var=LD_RUN_PATH 104260b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' 104270b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)=: 104285a81ca49Smrg 104290b0ce0bfSmrg # Commands to make compiler produce verbose output that lists 104300b0ce0bfSmrg # what "hidden" libraries, object files and flags are used when 104310b0ce0bfSmrg # linking a shared library. 104320b0ce0bfSmrg # 104330b0ce0bfSmrg # There doesn't appear to be a way to prevent this compiler from 104340b0ce0bfSmrg # explicitly linking system object files so we need to strip them 104350b0ce0bfSmrg # from the output so that they don't get included in the library 104360b0ce0bfSmrg # dependencies. 104370b0ce0bfSmrg 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' 104380b0ce0bfSmrg ;; 104390b0ce0bfSmrg xl* | mpixl* | bgxl*) 104400b0ce0bfSmrg # IBM XL 8.0 on PPC, with GNU ld 104410b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' 104420b0ce0bfSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' 104430b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' 104440b0ce0bfSmrg if test yes = "$supports_anon_versioning"; then 104450b0ce0bfSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ 104460b0ce0bfSmrg cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ 104470b0ce0bfSmrg echo "local: *; };" >> $output_objdir/$libname.ver~ 104480b0ce0bfSmrg $CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib' 104490b0ce0bfSmrg fi 104500b0ce0bfSmrg ;; 104510b0ce0bfSmrg *) 104520b0ce0bfSmrg case `$CC -V 2>&1 | $SED 5q` in 104530b0ce0bfSmrg *Sun\ C*) 104540b0ce0bfSmrg # Sun C++ 5.9 104550b0ce0bfSmrg _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' 104560b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 104570b0ce0bfSmrg _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' 104580b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 104590b0ce0bfSmrg _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' 104600b0ce0bfSmrg _LT_TAGVAR(compiler_needs_object, $1)=yes 104615a81ca49Smrg 104620b0ce0bfSmrg # Not sure whether something based on 104630b0ce0bfSmrg # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 104640b0ce0bfSmrg # would be better. 104650b0ce0bfSmrg output_verbose_link_cmd='func_echo_all' 104665a81ca49Smrg 104670b0ce0bfSmrg # Archives containing C++ object files must be created using 104680b0ce0bfSmrg # "CC -xar", where "CC" is the Sun C++ compiler. This is 104690b0ce0bfSmrg # necessary to make sure instantiated templates are included 104700b0ce0bfSmrg # in the archive. 104710b0ce0bfSmrg _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' 104720b0ce0bfSmrg ;; 104730b0ce0bfSmrg esac 104740b0ce0bfSmrg ;; 104750b0ce0bfSmrg esac 104760b0ce0bfSmrg ;; 104775a81ca49Smrg 104780b0ce0bfSmrg lynxos*) 104790b0ce0bfSmrg # FIXME: insert proper C++ library support 104800b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=no 104810b0ce0bfSmrg ;; 104825a81ca49Smrg 104830b0ce0bfSmrg m88k*) 104840b0ce0bfSmrg # FIXME: insert proper C++ library support 104850b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=no 104860b0ce0bfSmrg ;; 104875a81ca49Smrg 104880b0ce0bfSmrg mvs*) 104890b0ce0bfSmrg case $cc_basename in 104900b0ce0bfSmrg cxx*) 104910b0ce0bfSmrg # FIXME: insert proper C++ library support 104920b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=no 104930b0ce0bfSmrg ;; 104940b0ce0bfSmrg *) 104950b0ce0bfSmrg # FIXME: insert proper C++ library support 104960b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=no 104970b0ce0bfSmrg ;; 104980b0ce0bfSmrg esac 104990b0ce0bfSmrg ;; 105005a81ca49Smrg 105010b0ce0bfSmrg netbsd*) 105020b0ce0bfSmrg if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then 105030b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' 105040b0ce0bfSmrg wlarc= 105050b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 105060b0ce0bfSmrg _LT_TAGVAR(hardcode_direct, $1)=yes 105070b0ce0bfSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 105080b0ce0bfSmrg fi 105090b0ce0bfSmrg # Workaround some broken pre-1.5 toolchains 105100b0ce0bfSmrg output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' 105110b0ce0bfSmrg ;; 105125a81ca49Smrg 105130b0ce0bfSmrg *nto* | *qnx*) 105140b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=yes 105150b0ce0bfSmrg ;; 105165a81ca49Smrg 105170b0ce0bfSmrg openbsd* | bitrig*) 105180b0ce0bfSmrg if test -f /usr/libexec/ld.so; then 105190b0ce0bfSmrg _LT_TAGVAR(hardcode_direct, $1)=yes 105200b0ce0bfSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 105210b0ce0bfSmrg _LT_TAGVAR(hardcode_direct_absolute, $1)=yes 105220b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' 105230b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' 105240b0ce0bfSmrg if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`"; then 105250b0ce0bfSmrg _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' 105260b0ce0bfSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' 105270b0ce0bfSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' 105280b0ce0bfSmrg fi 105290b0ce0bfSmrg output_verbose_link_cmd=func_echo_all 105300b0ce0bfSmrg else 105310b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=no 105320b0ce0bfSmrg fi 105330b0ce0bfSmrg ;; 105345a81ca49Smrg 105350b0ce0bfSmrg osf3* | osf4* | osf5*) 105360b0ce0bfSmrg case $cc_basename in 105370b0ce0bfSmrg KCC*) 105380b0ce0bfSmrg # Kuck and Associates, Inc. (KAI) C++ Compiler 105395a81ca49Smrg 105400b0ce0bfSmrg # KCC will only create a shared library if the output file 105410b0ce0bfSmrg # ends with ".so" (or ".sl" for HP-UX), so rename the library 105420b0ce0bfSmrg # to its proper name (with version) after linking. 105430b0ce0bfSmrg _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' 105445a81ca49Smrg 105450b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' 105460b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)=: 105475a81ca49Smrg 105480b0ce0bfSmrg # Archives containing C++ object files must be created using 105490b0ce0bfSmrg # the KAI C++ compiler. 105500b0ce0bfSmrg case $host in 105510b0ce0bfSmrg osf3*) _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;; 105520b0ce0bfSmrg *) _LT_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' ;; 105530b0ce0bfSmrg esac 105540b0ce0bfSmrg ;; 105550b0ce0bfSmrg RCC*) 105560b0ce0bfSmrg # Rational C++ 2.4.1 105570b0ce0bfSmrg # FIXME: insert proper C++ library support 105580b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=no 105590b0ce0bfSmrg ;; 105600b0ce0bfSmrg cxx*) 105610b0ce0bfSmrg case $host in 105620b0ce0bfSmrg osf3*) 105630b0ce0bfSmrg _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' 105640b0ce0bfSmrg _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' 105650b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' 105660b0ce0bfSmrg ;; 105670b0ce0bfSmrg *) 105680b0ce0bfSmrg _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' 105690b0ce0bfSmrg _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' 105700b0ce0bfSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ 105710b0ce0bfSmrg echo "-hidden">> $lib.exp~ 105720b0ce0bfSmrg $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~ 105730b0ce0bfSmrg $RM $lib.exp' 105740b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' 105750b0ce0bfSmrg ;; 105760b0ce0bfSmrg esac 105775a81ca49Smrg 105780b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)=: 105795a81ca49Smrg 105800b0ce0bfSmrg # Commands to make compiler produce verbose output that lists 105810b0ce0bfSmrg # what "hidden" libraries, object files and flags are used when 105820b0ce0bfSmrg # linking a shared library. 105830b0ce0bfSmrg # 105840b0ce0bfSmrg # There doesn't appear to be a way to prevent this compiler from 105850b0ce0bfSmrg # explicitly linking system object files so we need to strip them 105860b0ce0bfSmrg # from the output so that they don't get included in the library 105870b0ce0bfSmrg # dependencies. 105880b0ce0bfSmrg 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"' 105890b0ce0bfSmrg ;; 105900b0ce0bfSmrg *) 105910b0ce0bfSmrg if test yes,no = "$GXX,$with_gnu_ld"; then 105920b0ce0bfSmrg _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' 105930b0ce0bfSmrg case $host in 105940b0ce0bfSmrg osf3*) 105950b0ce0bfSmrg _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' 105960b0ce0bfSmrg ;; 105970b0ce0bfSmrg *) 105980b0ce0bfSmrg _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' 105990b0ce0bfSmrg ;; 106000b0ce0bfSmrg esac 106015a81ca49Smrg 106020b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' 106030b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)=: 106045a81ca49Smrg 106050b0ce0bfSmrg # Commands to make compiler produce verbose output that lists 106060b0ce0bfSmrg # what "hidden" libraries, object files and flags are used when 106070b0ce0bfSmrg # linking a shared library. 106080b0ce0bfSmrg output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' 106095a81ca49Smrg 106100b0ce0bfSmrg else 106110b0ce0bfSmrg # FIXME: insert proper C++ library support 106120b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=no 106130b0ce0bfSmrg fi 106140b0ce0bfSmrg ;; 106150b0ce0bfSmrg esac 106160b0ce0bfSmrg ;; 106175a81ca49Smrg 106180b0ce0bfSmrg psos*) 106190b0ce0bfSmrg # FIXME: insert proper C++ library support 106200b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=no 106210b0ce0bfSmrg ;; 106225a81ca49Smrg 106230b0ce0bfSmrg sunos4*) 106240b0ce0bfSmrg case $cc_basename in 106250b0ce0bfSmrg CC*) 106260b0ce0bfSmrg # Sun C++ 4.x 106270b0ce0bfSmrg # FIXME: insert proper C++ library support 106280b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=no 106290b0ce0bfSmrg ;; 106300b0ce0bfSmrg lcc*) 106310b0ce0bfSmrg # Lucid 106320b0ce0bfSmrg # FIXME: insert proper C++ library support 106330b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=no 106340b0ce0bfSmrg ;; 106350b0ce0bfSmrg *) 106360b0ce0bfSmrg # FIXME: insert proper C++ library support 106370b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=no 106380b0ce0bfSmrg ;; 106390b0ce0bfSmrg esac 106400b0ce0bfSmrg ;; 106415a81ca49Smrg 106420b0ce0bfSmrg solaris*) 106430b0ce0bfSmrg case $cc_basename in 106440b0ce0bfSmrg CC* | sunCC*) 106450b0ce0bfSmrg # Sun C++ 4.2, 5.x and Centerline C++ 106460b0ce0bfSmrg _LT_TAGVAR(archive_cmds_need_lc,$1)=yes 106470b0ce0bfSmrg _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' 106480b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 106490b0ce0bfSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 106500b0ce0bfSmrg $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' 106511b12faf6Smrg 106520b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 106530b0ce0bfSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 106540b0ce0bfSmrg case $host_os in 106550b0ce0bfSmrg solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; 106560b0ce0bfSmrg *) 106570b0ce0bfSmrg # The compiler driver will combine and reorder linker options, 106580b0ce0bfSmrg # but understands '-z linker_flag'. 106590b0ce0bfSmrg # Supported since Solaris 2.6 (maybe 2.5.1?) 106600b0ce0bfSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' 106610b0ce0bfSmrg ;; 106620b0ce0bfSmrg esac 106630b0ce0bfSmrg _LT_TAGVAR(link_all_deplibs, $1)=yes 106641b12faf6Smrg 106650b0ce0bfSmrg output_verbose_link_cmd='func_echo_all' 1066632b578d3Smrg 106670b0ce0bfSmrg # Archives containing C++ object files must be created using 106680b0ce0bfSmrg # "CC -xar", where "CC" is the Sun C++ compiler. This is 106690b0ce0bfSmrg # necessary to make sure instantiated templates are included 106700b0ce0bfSmrg # in the archive. 106710b0ce0bfSmrg _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' 106720b0ce0bfSmrg ;; 106730b0ce0bfSmrg gcx*) 106740b0ce0bfSmrg # Green Hills C++ Compiler 106750b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' 1067632b578d3Smrg 106770b0ce0bfSmrg # The C++ compiler must be used to create the archive. 106780b0ce0bfSmrg _LT_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs' 106790b0ce0bfSmrg ;; 106800b0ce0bfSmrg *) 106810b0ce0bfSmrg # GNU C++ compiler with Solaris linker 106820b0ce0bfSmrg if test yes,no = "$GXX,$with_gnu_ld"; then 106830b0ce0bfSmrg _LT_TAGVAR(no_undefined_flag, $1)=' $wl-z ${wl}defs' 106840b0ce0bfSmrg if $CC --version | $GREP -v '^2\.7' > /dev/null; then 106850b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' 106860b0ce0bfSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 106870b0ce0bfSmrg $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' 10688e35d4d8eSmrg 106890b0ce0bfSmrg # Commands to make compiler produce verbose output that lists 106900b0ce0bfSmrg # what "hidden" libraries, object files and flags are used when 106910b0ce0bfSmrg # linking a shared library. 106920b0ce0bfSmrg output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' 106930b0ce0bfSmrg else 106940b0ce0bfSmrg # g++ 2.7 appears to require '-G' NOT '-shared' on this 106950b0ce0bfSmrg # platform. 106960b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' 106970b0ce0bfSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ 106980b0ce0bfSmrg $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' 10699e35d4d8eSmrg 107000b0ce0bfSmrg # Commands to make compiler produce verbose output that lists 107010b0ce0bfSmrg # what "hidden" libraries, object files and flags are used when 107020b0ce0bfSmrg # linking a shared library. 107030b0ce0bfSmrg output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' 107040b0ce0bfSmrg fi 10705e35d4d8eSmrg 107060b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $wl$libdir' 107070b0ce0bfSmrg case $host_os in 107080b0ce0bfSmrg solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; 107090b0ce0bfSmrg *) 107100b0ce0bfSmrg _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract' 107110b0ce0bfSmrg ;; 107120b0ce0bfSmrg esac 107130b0ce0bfSmrg fi 107140b0ce0bfSmrg ;; 107150b0ce0bfSmrg esac 107160b0ce0bfSmrg ;; 10717e35d4d8eSmrg 107180b0ce0bfSmrg sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) 107190b0ce0bfSmrg _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' 107200b0ce0bfSmrg _LT_TAGVAR(archive_cmds_need_lc, $1)=no 107210b0ce0bfSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 107220b0ce0bfSmrg runpath_var='LD_RUN_PATH' 107231b12faf6Smrg 107240b0ce0bfSmrg case $cc_basename in 107250b0ce0bfSmrg CC*) 107260b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 107270b0ce0bfSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 107280b0ce0bfSmrg ;; 107290b0ce0bfSmrg *) 107300b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 107310b0ce0bfSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 107320b0ce0bfSmrg ;; 107330b0ce0bfSmrg esac 107340b0ce0bfSmrg ;; 107351b12faf6Smrg 107360b0ce0bfSmrg sysv5* | sco3.2v5* | sco5v6*) 107370b0ce0bfSmrg # Note: We CANNOT use -z defs as we might desire, because we do not 107380b0ce0bfSmrg # link with -lc, and that would cause any symbols used from libc to 107390b0ce0bfSmrg # always be unresolved, which means just about no library would 107400b0ce0bfSmrg # ever link correctly. If we're not using GNU ld we use -z text 107410b0ce0bfSmrg # though, which does catch some bad symbols but isn't as heavy-handed 107420b0ce0bfSmrg # as -z defs. 107430b0ce0bfSmrg _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' 107440b0ce0bfSmrg _LT_TAGVAR(allow_undefined_flag, $1)='$wl-z,nodefs' 107450b0ce0bfSmrg _LT_TAGVAR(archive_cmds_need_lc, $1)=no 107460b0ce0bfSmrg _LT_TAGVAR(hardcode_shlibpath_var, $1)=no 107470b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R,$libdir' 107480b0ce0bfSmrg _LT_TAGVAR(hardcode_libdir_separator, $1)=':' 107490b0ce0bfSmrg _LT_TAGVAR(link_all_deplibs, $1)=yes 107500b0ce0bfSmrg _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Bexport' 107510b0ce0bfSmrg runpath_var='LD_RUN_PATH' 1075232b578d3Smrg 107530b0ce0bfSmrg case $cc_basename in 107540b0ce0bfSmrg CC*) 107550b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 107560b0ce0bfSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 107570b0ce0bfSmrg _LT_TAGVAR(old_archive_cmds, $1)='$CC -Tprelink_objects $oldobjs~ 107580b0ce0bfSmrg '"$_LT_TAGVAR(old_archive_cmds, $1)" 107590b0ce0bfSmrg _LT_TAGVAR(reload_cmds, $1)='$CC -Tprelink_objects $reload_objs~ 107600b0ce0bfSmrg '"$_LT_TAGVAR(reload_cmds, $1)" 107610b0ce0bfSmrg ;; 107620b0ce0bfSmrg *) 107630b0ce0bfSmrg _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 107640b0ce0bfSmrg _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 107650b0ce0bfSmrg ;; 107660b0ce0bfSmrg esac 107670b0ce0bfSmrg ;; 1076832b578d3Smrg 107690b0ce0bfSmrg tandem*) 107700b0ce0bfSmrg case $cc_basename in 107710b0ce0bfSmrg NCC*) 107720b0ce0bfSmrg # NonStop-UX NCC 3.20 107730b0ce0bfSmrg # FIXME: insert proper C++ library support 107740b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=no 107750b0ce0bfSmrg ;; 107760b0ce0bfSmrg *) 107770b0ce0bfSmrg # FIXME: insert proper C++ library support 107780b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=no 107790b0ce0bfSmrg ;; 107800b0ce0bfSmrg esac 107810b0ce0bfSmrg ;; 10782e35d4d8eSmrg 107830b0ce0bfSmrg vxworks*) 107840b0ce0bfSmrg # FIXME: insert proper C++ library support 107850b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=no 107860b0ce0bfSmrg ;; 1078732b578d3Smrg 107880b0ce0bfSmrg *) 107890b0ce0bfSmrg # FIXME: insert proper C++ library support 107900b0ce0bfSmrg _LT_TAGVAR(ld_shlibs, $1)=no 107910b0ce0bfSmrg ;; 107920b0ce0bfSmrg esac 10793e35d4d8eSmrg 107940b0ce0bfSmrg AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) 107950b0ce0bfSmrg test no = "$_LT_TAGVAR(ld_shlibs, $1)" && can_build_shared=no 10796e35d4d8eSmrg 107970b0ce0bfSmrg _LT_TAGVAR(GCC, $1)=$GXX 107980b0ce0bfSmrg _LT_TAGVAR(LD, $1)=$LD 10799e35d4d8eSmrg 108000b0ce0bfSmrg ## CAVEAT EMPTOR: 108010b0ce0bfSmrg ## There is no encapsulation within the following macros, do not change 108020b0ce0bfSmrg ## the running order or otherwise move them around unless you know exactly 108030b0ce0bfSmrg ## what you are doing... 108040b0ce0bfSmrg _LT_SYS_HIDDEN_LIBDEPS($1) 108050b0ce0bfSmrg _LT_COMPILER_PIC($1) 108060b0ce0bfSmrg _LT_COMPILER_C_O($1) 108070b0ce0bfSmrg _LT_COMPILER_FILE_LOCKS($1) 108080b0ce0bfSmrg _LT_LINKER_SHLIBS($1) 108090b0ce0bfSmrg _LT_SYS_DYNAMIC_LINKER($1) 108100b0ce0bfSmrg _LT_LINKER_HARDCODE_LIBPATH($1) 10811e35d4d8eSmrg 108120b0ce0bfSmrg _LT_CONFIG($1) 108130b0ce0bfSmrg fi # test -n "$compiler" 108145a81ca49Smrg 108150b0ce0bfSmrg CC=$lt_save_CC 108160b0ce0bfSmrg CFLAGS=$lt_save_CFLAGS 108170b0ce0bfSmrg LDCXX=$LD 108180b0ce0bfSmrg LD=$lt_save_LD 108190b0ce0bfSmrg GCC=$lt_save_GCC 108200b0ce0bfSmrg with_gnu_ld=$lt_save_with_gnu_ld 108210b0ce0bfSmrg lt_cv_path_LDCXX=$lt_cv_path_LD 108220b0ce0bfSmrg lt_cv_path_LD=$lt_save_path_LD 108230b0ce0bfSmrg lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld 108240b0ce0bfSmrg lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld 108250b0ce0bfSmrgfi # test yes != "$_lt_caught_CXX_error" 108265a81ca49Smrg 108270b0ce0bfSmrgAC_LANG_POP 108280b0ce0bfSmrg])# _LT_LANG_CXX_CONFIG 10829e35d4d8eSmrg 10830e35d4d8eSmrg 108310b0ce0bfSmrg# _LT_FUNC_STRIPNAME_CNF 108320b0ce0bfSmrg# ---------------------- 108330b0ce0bfSmrg# func_stripname_cnf prefix suffix name 108340b0ce0bfSmrg# strip PREFIX and SUFFIX off of NAME. 108350b0ce0bfSmrg# PREFIX and SUFFIX must not contain globbing or regex special 108360b0ce0bfSmrg# characters, hashes, percent signs, but SUFFIX may contain a leading 108370b0ce0bfSmrg# dot (in which case that matches only a dot). 108385a81ca49Smrg# 108390b0ce0bfSmrg# This function is identical to the (non-XSI) version of func_stripname, 108400b0ce0bfSmrg# except this one can be used by m4 code that may be executed by configure, 108410b0ce0bfSmrg# rather than the libtool script. 108420b0ce0bfSmrgm4_defun([_LT_FUNC_STRIPNAME_CNF],[dnl 108430b0ce0bfSmrgAC_REQUIRE([_LT_DECL_SED]) 108440b0ce0bfSmrgAC_REQUIRE([_LT_PROG_ECHO_BACKSLASH]) 108450b0ce0bfSmrgfunc_stripname_cnf () 108460b0ce0bfSmrg{ 108470b0ce0bfSmrg case @S|@2 in 108480b0ce0bfSmrg .*) func_stripname_result=`$ECHO "@S|@3" | $SED "s%^@S|@1%%; s%\\\\@S|@2\$%%"`;; 108490b0ce0bfSmrg *) func_stripname_result=`$ECHO "@S|@3" | $SED "s%^@S|@1%%; s%@S|@2\$%%"`;; 108500b0ce0bfSmrg esac 108510b0ce0bfSmrg} # func_stripname_cnf 108520b0ce0bfSmrg])# _LT_FUNC_STRIPNAME_CNF 108530b0ce0bfSmrg 108540b0ce0bfSmrg 108550b0ce0bfSmrg# _LT_SYS_HIDDEN_LIBDEPS([TAGNAME]) 108560b0ce0bfSmrg# --------------------------------- 108570b0ce0bfSmrg# Figure out "hidden" library dependencies from verbose 108580b0ce0bfSmrg# compiler output when linking a shared library. 108590b0ce0bfSmrg# Parse the compiler output and extract the necessary 108600b0ce0bfSmrg# objects, libraries and library flags. 108610b0ce0bfSmrgm4_defun([_LT_SYS_HIDDEN_LIBDEPS], 108620b0ce0bfSmrg[m4_require([_LT_FILEUTILS_DEFAULTS])dnl 108630b0ce0bfSmrgAC_REQUIRE([_LT_FUNC_STRIPNAME_CNF])dnl 108640b0ce0bfSmrg# Dependencies to place before and after the object being linked: 108650b0ce0bfSmrg_LT_TAGVAR(predep_objects, $1)= 108660b0ce0bfSmrg_LT_TAGVAR(postdep_objects, $1)= 108670b0ce0bfSmrg_LT_TAGVAR(predeps, $1)= 108680b0ce0bfSmrg_LT_TAGVAR(postdeps, $1)= 108690b0ce0bfSmrg_LT_TAGVAR(compiler_lib_search_path, $1)= 108700b0ce0bfSmrg 108710b0ce0bfSmrgdnl we can't use the lt_simple_compile_test_code here, 108720b0ce0bfSmrgdnl because it contains code intended for an executable, 108730b0ce0bfSmrgdnl not a library. It's possible we should let each 108740b0ce0bfSmrgdnl tag define a new lt_????_link_test_code variable, 108750b0ce0bfSmrgdnl but it's only used here... 108760b0ce0bfSmrgm4_if([$1], [], [cat > conftest.$ac_ext <<_LT_EOF 108770b0ce0bfSmrgint a; 108780b0ce0bfSmrgvoid foo (void) { a = 0; } 108790b0ce0bfSmrg_LT_EOF 108800b0ce0bfSmrg], [$1], [CXX], [cat > conftest.$ac_ext <<_LT_EOF 108810b0ce0bfSmrgclass Foo 108820b0ce0bfSmrg{ 108830b0ce0bfSmrgpublic: 108840b0ce0bfSmrg Foo (void) { a = 0; } 108850b0ce0bfSmrgprivate: 108860b0ce0bfSmrg int a; 108870b0ce0bfSmrg}; 108880b0ce0bfSmrg_LT_EOF 108890b0ce0bfSmrg], [$1], [F77], [cat > conftest.$ac_ext <<_LT_EOF 108900b0ce0bfSmrg subroutine foo 108910b0ce0bfSmrg implicit none 108920b0ce0bfSmrg integer*4 a 108930b0ce0bfSmrg a=0 108940b0ce0bfSmrg return 108950b0ce0bfSmrg end 108960b0ce0bfSmrg_LT_EOF 108970b0ce0bfSmrg], [$1], [FC], [cat > conftest.$ac_ext <<_LT_EOF 108980b0ce0bfSmrg subroutine foo 108990b0ce0bfSmrg implicit none 109000b0ce0bfSmrg integer a 109010b0ce0bfSmrg a=0 109020b0ce0bfSmrg return 109030b0ce0bfSmrg end 109040b0ce0bfSmrg_LT_EOF 109050b0ce0bfSmrg], [$1], [GCJ], [cat > conftest.$ac_ext <<_LT_EOF 109060b0ce0bfSmrgpublic class foo { 109070b0ce0bfSmrg private int a; 109080b0ce0bfSmrg public void bar (void) { 109090b0ce0bfSmrg a = 0; 109100b0ce0bfSmrg } 109110b0ce0bfSmrg}; 109120b0ce0bfSmrg_LT_EOF 109130b0ce0bfSmrg], [$1], [GO], [cat > conftest.$ac_ext <<_LT_EOF 109140b0ce0bfSmrgpackage foo 109150b0ce0bfSmrgfunc foo() { 109160b0ce0bfSmrg} 109170b0ce0bfSmrg_LT_EOF 109180b0ce0bfSmrg]) 10919e35d4d8eSmrg 109200b0ce0bfSmrg_lt_libdeps_save_CFLAGS=$CFLAGS 109210b0ce0bfSmrgcase "$CC $CFLAGS " in #( 109220b0ce0bfSmrg*\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;; 109230b0ce0bfSmrg*\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;; 109240b0ce0bfSmrg*\ -fuse-linker-plugin*\ *) CFLAGS="$CFLAGS -fno-use-linker-plugin" ;; 109250b0ce0bfSmrgesac 10926e35d4d8eSmrg 109270b0ce0bfSmrgdnl Parse the compiler output and extract the necessary 109280b0ce0bfSmrgdnl objects, libraries and library flags. 109290b0ce0bfSmrgif AC_TRY_EVAL(ac_compile); then 109300b0ce0bfSmrg # Parse the compiler output and extract the necessary 109310b0ce0bfSmrg # objects, libraries and library flags. 109325a81ca49Smrg 109330b0ce0bfSmrg # Sentinel used to keep track of whether or not we are before 109340b0ce0bfSmrg # the conftest object file. 109350b0ce0bfSmrg pre_test_object_deps_done=no 109365a81ca49Smrg 109370b0ce0bfSmrg for p in `eval "$output_verbose_link_cmd"`; do 109380b0ce0bfSmrg case $prev$p in 109395a81ca49Smrg 109400b0ce0bfSmrg -L* | -R* | -l*) 109410b0ce0bfSmrg # Some compilers place space between "-{L,R}" and the path. 109420b0ce0bfSmrg # Remove the space. 109430b0ce0bfSmrg if test x-L = "$p" || 109440b0ce0bfSmrg test x-R = "$p"; then 109450b0ce0bfSmrg prev=$p 109460b0ce0bfSmrg continue 109470b0ce0bfSmrg fi 109485a81ca49Smrg 109490b0ce0bfSmrg # Expand the sysroot to ease extracting the directories later. 109500b0ce0bfSmrg if test -z "$prev"; then 109510b0ce0bfSmrg case $p in 109520b0ce0bfSmrg -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;; 109530b0ce0bfSmrg -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;; 109540b0ce0bfSmrg -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;; 109550b0ce0bfSmrg esac 109560b0ce0bfSmrg fi 109570b0ce0bfSmrg case $p in 109580b0ce0bfSmrg =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;; 109590b0ce0bfSmrg esac 109600b0ce0bfSmrg if test no = "$pre_test_object_deps_done"; then 109610b0ce0bfSmrg case $prev in 109620b0ce0bfSmrg -L | -R) 109630b0ce0bfSmrg # Internal compiler library paths should come after those 109640b0ce0bfSmrg # provided the user. The postdeps already come after the 109650b0ce0bfSmrg # user supplied libs so there is no need to process them. 109660b0ce0bfSmrg if test -z "$_LT_TAGVAR(compiler_lib_search_path, $1)"; then 109670b0ce0bfSmrg _LT_TAGVAR(compiler_lib_search_path, $1)=$prev$p 109680b0ce0bfSmrg else 109690b0ce0bfSmrg _LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} $prev$p" 109700b0ce0bfSmrg fi 109710b0ce0bfSmrg ;; 109720b0ce0bfSmrg # The "-l" case would never come before the object being 109730b0ce0bfSmrg # linked, so don't bother handling this case. 109740b0ce0bfSmrg esac 109750b0ce0bfSmrg else 109760b0ce0bfSmrg if test -z "$_LT_TAGVAR(postdeps, $1)"; then 109770b0ce0bfSmrg _LT_TAGVAR(postdeps, $1)=$prev$p 109780b0ce0bfSmrg else 109790b0ce0bfSmrg _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} $prev$p" 109800b0ce0bfSmrg fi 109810b0ce0bfSmrg fi 109820b0ce0bfSmrg prev= 109830b0ce0bfSmrg ;; 109845a81ca49Smrg 109850b0ce0bfSmrg *.lto.$objext) ;; # Ignore GCC LTO objects 109860b0ce0bfSmrg *.$objext) 109870b0ce0bfSmrg # This assumes that the test object file only shows up 109880b0ce0bfSmrg # once in the compiler output. 109890b0ce0bfSmrg if test "$p" = "conftest.$objext"; then 109900b0ce0bfSmrg pre_test_object_deps_done=yes 109910b0ce0bfSmrg continue 109920b0ce0bfSmrg fi 109930b0ce0bfSmrg 109940b0ce0bfSmrg if test no = "$pre_test_object_deps_done"; then 109950b0ce0bfSmrg if test -z "$_LT_TAGVAR(predep_objects, $1)"; then 109960b0ce0bfSmrg _LT_TAGVAR(predep_objects, $1)=$p 109970b0ce0bfSmrg else 109980b0ce0bfSmrg _LT_TAGVAR(predep_objects, $1)="$_LT_TAGVAR(predep_objects, $1) $p" 109990b0ce0bfSmrg fi 110000b0ce0bfSmrg else 110010b0ce0bfSmrg if test -z "$_LT_TAGVAR(postdep_objects, $1)"; then 110020b0ce0bfSmrg _LT_TAGVAR(postdep_objects, $1)=$p 110030b0ce0bfSmrg else 110040b0ce0bfSmrg _LT_TAGVAR(postdep_objects, $1)="$_LT_TAGVAR(postdep_objects, $1) $p" 110050b0ce0bfSmrg fi 110060b0ce0bfSmrg fi 110070b0ce0bfSmrg ;; 1100832b578d3Smrg 110090b0ce0bfSmrg *) ;; # Ignore the rest. 11010e35d4d8eSmrg 110110b0ce0bfSmrg esac 110120b0ce0bfSmrg done 11013e35d4d8eSmrg 110140b0ce0bfSmrg # Clean up. 110150b0ce0bfSmrg rm -f a.out a.exe 110160b0ce0bfSmrgelse 110170b0ce0bfSmrg echo "libtool.m4: error: problem compiling $1 test program" 110185a81ca49Smrgfi 110195a81ca49Smrg 110200b0ce0bfSmrg$RM -f confest.$objext 110210b0ce0bfSmrgCFLAGS=$_lt_libdeps_save_CFLAGS 110225a81ca49Smrg 110230b0ce0bfSmrg# PORTME: override above test on systems where it is broken 110240b0ce0bfSmrgm4_if([$1], [CXX], 110250b0ce0bfSmrg[case $host_os in 110260b0ce0bfSmrginterix[[3-9]]*) 110270b0ce0bfSmrg # Interix 3.5 installs completely hosed .la files for C++, so rather than 110280b0ce0bfSmrg # hack all around it, let's just trust "g++" to DTRT. 110290b0ce0bfSmrg _LT_TAGVAR(predep_objects,$1)= 110300b0ce0bfSmrg _LT_TAGVAR(postdep_objects,$1)= 110310b0ce0bfSmrg _LT_TAGVAR(postdeps,$1)= 110320b0ce0bfSmrg ;; 110330b0ce0bfSmrgesac 110340b0ce0bfSmrg]) 1103532b578d3Smrg 110360b0ce0bfSmrgcase " $_LT_TAGVAR(postdeps, $1) " in 110370b0ce0bfSmrg*" -lc "*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;; 110380b0ce0bfSmrgesac 110390b0ce0bfSmrg _LT_TAGVAR(compiler_lib_search_dirs, $1)= 110400b0ce0bfSmrgif test -n "${_LT_TAGVAR(compiler_lib_search_path, $1)}"; then 110410b0ce0bfSmrg _LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | $SED -e 's! -L! !g' -e 's!^ !!'` 110425a81ca49Smrgfi 110430b0ce0bfSmrg_LT_TAGDECL([], [compiler_lib_search_dirs], [1], 110440b0ce0bfSmrg [The directories searched by this compiler when creating a shared library]) 110450b0ce0bfSmrg_LT_TAGDECL([], [predep_objects], [1], 110460b0ce0bfSmrg [Dependencies to place before and after the objects being linked to 110470b0ce0bfSmrg create a shared library]) 110480b0ce0bfSmrg_LT_TAGDECL([], [postdep_objects], [1]) 110490b0ce0bfSmrg_LT_TAGDECL([], [predeps], [1]) 110500b0ce0bfSmrg_LT_TAGDECL([], [postdeps], [1]) 110510b0ce0bfSmrg_LT_TAGDECL([], [compiler_lib_search_path], [1], 110520b0ce0bfSmrg [The library search path used internally by the compiler when linking 110530b0ce0bfSmrg a shared library]) 110540b0ce0bfSmrg])# _LT_SYS_HIDDEN_LIBDEPS 1105532b578d3Smrg 110565a81ca49Smrg 110570b0ce0bfSmrg# _LT_LANG_F77_CONFIG([TAG]) 110580b0ce0bfSmrg# -------------------------- 110590b0ce0bfSmrg# Ensure that the configuration variables for a Fortran 77 compiler are 110600b0ce0bfSmrg# suitably defined. These variables are subsequently used by _LT_CONFIG 110610b0ce0bfSmrg# to write the compiler configuration to 'libtool'. 110620b0ce0bfSmrgm4_defun([_LT_LANG_F77_CONFIG], 110630b0ce0bfSmrg[AC_LANG_PUSH(Fortran 77) 110640b0ce0bfSmrgif test -z "$F77" || test no = "$F77"; then 110650b0ce0bfSmrg _lt_disable_F77=yes 11066e35d4d8eSmrgfi 110672a51b5beSmrg 110680b0ce0bfSmrg_LT_TAGVAR(archive_cmds_need_lc, $1)=no 110690b0ce0bfSmrg_LT_TAGVAR(allow_undefined_flag, $1)= 110700b0ce0bfSmrg_LT_TAGVAR(always_export_symbols, $1)=no 110710b0ce0bfSmrg_LT_TAGVAR(archive_expsym_cmds, $1)= 110720b0ce0bfSmrg_LT_TAGVAR(export_dynamic_flag_spec, $1)= 110730b0ce0bfSmrg_LT_TAGVAR(hardcode_direct, $1)=no 110740b0ce0bfSmrg_LT_TAGVAR(hardcode_direct_absolute, $1)=no 110750b0ce0bfSmrg_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 110760b0ce0bfSmrg_LT_TAGVAR(hardcode_libdir_separator, $1)= 110770b0ce0bfSmrg_LT_TAGVAR(hardcode_minus_L, $1)=no 110780b0ce0bfSmrg_LT_TAGVAR(hardcode_automatic, $1)=no 110790b0ce0bfSmrg_LT_TAGVAR(inherit_rpath, $1)=no 110800b0ce0bfSmrg_LT_TAGVAR(module_cmds, $1)= 110810b0ce0bfSmrg_LT_TAGVAR(module_expsym_cmds, $1)= 110820b0ce0bfSmrg_LT_TAGVAR(link_all_deplibs, $1)=unknown 110830b0ce0bfSmrg_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 110840b0ce0bfSmrg_LT_TAGVAR(reload_flag, $1)=$reload_flag 110850b0ce0bfSmrg_LT_TAGVAR(reload_cmds, $1)=$reload_cmds 110860b0ce0bfSmrg_LT_TAGVAR(no_undefined_flag, $1)= 110870b0ce0bfSmrg_LT_TAGVAR(whole_archive_flag_spec, $1)= 110880b0ce0bfSmrg_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no 110895a81ca49Smrg 110900b0ce0bfSmrg# Source file extension for f77 test sources. 110910b0ce0bfSmrgac_ext=f 1109232b578d3Smrg 110930b0ce0bfSmrg# Object file extension for compiled f77 test sources. 110940b0ce0bfSmrgobjext=o 110950b0ce0bfSmrg_LT_TAGVAR(objext, $1)=$objext 1109632b578d3Smrg 110970b0ce0bfSmrg# No sense in running all these tests if we already determined that 110980b0ce0bfSmrg# the F77 compiler isn't working. Some variables (like enable_shared) 110990b0ce0bfSmrg# are currently assumed to apply to all compilers on this platform, 111000b0ce0bfSmrg# and will be corrupted by setting them based on a non-working compiler. 111010b0ce0bfSmrgif test yes != "$_lt_disable_F77"; then 111020b0ce0bfSmrg # Code to be used in simple compile tests 111030b0ce0bfSmrg lt_simple_compile_test_code="\ 111040b0ce0bfSmrg subroutine t 111050b0ce0bfSmrg return 111060b0ce0bfSmrg end 111070b0ce0bfSmrg" 111080b0ce0bfSmrg 111090b0ce0bfSmrg # Code to be used in simple link tests 111100b0ce0bfSmrg lt_simple_link_test_code="\ 111110b0ce0bfSmrg program t 111120b0ce0bfSmrg end 111130b0ce0bfSmrg" 111140b0ce0bfSmrg 111150b0ce0bfSmrg # ltmain only uses $CC for tagged configurations so make sure $CC is set. 111160b0ce0bfSmrg _LT_TAG_COMPILER 111170b0ce0bfSmrg 111180b0ce0bfSmrg # save warnings/boilerplate of simple test code 111190b0ce0bfSmrg _LT_COMPILER_BOILERPLATE 111200b0ce0bfSmrg _LT_LINKER_BOILERPLATE 111210b0ce0bfSmrg 111220b0ce0bfSmrg # Allow CC to be a program name with arguments. 111230b0ce0bfSmrg lt_save_CC=$CC 111240b0ce0bfSmrg lt_save_GCC=$GCC 111250b0ce0bfSmrg lt_save_CFLAGS=$CFLAGS 111260b0ce0bfSmrg CC=${F77-"f77"} 111270b0ce0bfSmrg CFLAGS=$FFLAGS 111280b0ce0bfSmrg compiler=$CC 111290b0ce0bfSmrg _LT_TAGVAR(compiler, $1)=$CC 111300b0ce0bfSmrg _LT_CC_BASENAME([$compiler]) 111310b0ce0bfSmrg GCC=$G77 111320b0ce0bfSmrg if test -n "$compiler"; then 111330b0ce0bfSmrg AC_MSG_CHECKING([if libtool supports shared libraries]) 111340b0ce0bfSmrg AC_MSG_RESULT([$can_build_shared]) 111350b0ce0bfSmrg 111360b0ce0bfSmrg AC_MSG_CHECKING([whether to build shared libraries]) 111370b0ce0bfSmrg test no = "$can_build_shared" && enable_shared=no 111380b0ce0bfSmrg 111390b0ce0bfSmrg # On AIX, shared libraries and static libraries use the same namespace, and 111400b0ce0bfSmrg # are all built from PIC. 111410b0ce0bfSmrg case $host_os in 111420b0ce0bfSmrg aix3*) 111430b0ce0bfSmrg test yes = "$enable_shared" && enable_static=no 111440b0ce0bfSmrg if test -n "$RANLIB"; then 111450b0ce0bfSmrg archive_cmds="$archive_cmds~\$RANLIB \$lib" 111460b0ce0bfSmrg postinstall_cmds='$RANLIB $lib' 111470b0ce0bfSmrg fi 111485a81ca49Smrg ;; 111490b0ce0bfSmrg aix[[4-9]]*) 111500b0ce0bfSmrg if test ia64 != "$host_cpu"; then 111510b0ce0bfSmrg case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in 111520b0ce0bfSmrg yes,aix,yes) ;; # shared object as lib.so file only 111530b0ce0bfSmrg yes,svr4,*) ;; # shared object as lib.so archive member only 111540b0ce0bfSmrg yes,*) enable_static=no ;; # shared object in lib.a archive as well 111550b0ce0bfSmrg esac 111560b0ce0bfSmrg fi 111575a81ca49Smrg ;; 111580b0ce0bfSmrg esac 111590b0ce0bfSmrg AC_MSG_RESULT([$enable_shared]) 1116032b578d3Smrg 111610b0ce0bfSmrg AC_MSG_CHECKING([whether to build static libraries]) 111620b0ce0bfSmrg # Make sure either enable_shared or enable_static is yes. 111630b0ce0bfSmrg test yes = "$enable_shared" || enable_static=yes 111640b0ce0bfSmrg AC_MSG_RESULT([$enable_static]) 1116532b578d3Smrg 111660b0ce0bfSmrg _LT_TAGVAR(GCC, $1)=$G77 111670b0ce0bfSmrg _LT_TAGVAR(LD, $1)=$LD 111682a51b5beSmrg 111690b0ce0bfSmrg ## CAVEAT EMPTOR: 111700b0ce0bfSmrg ## There is no encapsulation within the following macros, do not change 111710b0ce0bfSmrg ## the running order or otherwise move them around unless you know exactly 111720b0ce0bfSmrg ## what you are doing... 111730b0ce0bfSmrg _LT_COMPILER_PIC($1) 111740b0ce0bfSmrg _LT_COMPILER_C_O($1) 111750b0ce0bfSmrg _LT_COMPILER_FILE_LOCKS($1) 111760b0ce0bfSmrg _LT_LINKER_SHLIBS($1) 111770b0ce0bfSmrg _LT_SYS_DYNAMIC_LINKER($1) 111780b0ce0bfSmrg _LT_LINKER_HARDCODE_LIBPATH($1) 111795a81ca49Smrg 111800b0ce0bfSmrg _LT_CONFIG($1) 111810b0ce0bfSmrg fi # test -n "$compiler" 1118232b578d3Smrg 111830b0ce0bfSmrg GCC=$lt_save_GCC 111840b0ce0bfSmrg CC=$lt_save_CC 111850b0ce0bfSmrg CFLAGS=$lt_save_CFLAGS 111860b0ce0bfSmrgfi # test yes != "$_lt_disable_F77" 1118732b578d3Smrg 111880b0ce0bfSmrgAC_LANG_POP 111890b0ce0bfSmrg])# _LT_LANG_F77_CONFIG 111905a81ca49Smrg 111915a81ca49Smrg 111920b0ce0bfSmrg# _LT_LANG_FC_CONFIG([TAG]) 111930b0ce0bfSmrg# ------------------------- 111940b0ce0bfSmrg# Ensure that the configuration variables for a Fortran compiler are 111950b0ce0bfSmrg# suitably defined. These variables are subsequently used by _LT_CONFIG 111960b0ce0bfSmrg# to write the compiler configuration to 'libtool'. 111970b0ce0bfSmrgm4_defun([_LT_LANG_FC_CONFIG], 111980b0ce0bfSmrg[AC_LANG_PUSH(Fortran) 1119932b578d3Smrg 112000b0ce0bfSmrgif test -z "$FC" || test no = "$FC"; then 112010b0ce0bfSmrg _lt_disable_FC=yes 112022a51b5beSmrgfi 1120332b578d3Smrg 112040b0ce0bfSmrg_LT_TAGVAR(archive_cmds_need_lc, $1)=no 112050b0ce0bfSmrg_LT_TAGVAR(allow_undefined_flag, $1)= 112060b0ce0bfSmrg_LT_TAGVAR(always_export_symbols, $1)=no 112070b0ce0bfSmrg_LT_TAGVAR(archive_expsym_cmds, $1)= 112080b0ce0bfSmrg_LT_TAGVAR(export_dynamic_flag_spec, $1)= 112090b0ce0bfSmrg_LT_TAGVAR(hardcode_direct, $1)=no 112100b0ce0bfSmrg_LT_TAGVAR(hardcode_direct_absolute, $1)=no 112110b0ce0bfSmrg_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= 112120b0ce0bfSmrg_LT_TAGVAR(hardcode_libdir_separator, $1)= 112130b0ce0bfSmrg_LT_TAGVAR(hardcode_minus_L, $1)=no 112140b0ce0bfSmrg_LT_TAGVAR(hardcode_automatic, $1)=no 112150b0ce0bfSmrg_LT_TAGVAR(inherit_rpath, $1)=no 112160b0ce0bfSmrg_LT_TAGVAR(module_cmds, $1)= 112170b0ce0bfSmrg_LT_TAGVAR(module_expsym_cmds, $1)= 112180b0ce0bfSmrg_LT_TAGVAR(link_all_deplibs, $1)=unknown 112190b0ce0bfSmrg_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 112200b0ce0bfSmrg_LT_TAGVAR(reload_flag, $1)=$reload_flag 112210b0ce0bfSmrg_LT_TAGVAR(reload_cmds, $1)=$reload_cmds 112220b0ce0bfSmrg_LT_TAGVAR(no_undefined_flag, $1)= 112230b0ce0bfSmrg_LT_TAGVAR(whole_archive_flag_spec, $1)= 112240b0ce0bfSmrg_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no 112255a81ca49Smrg 112260b0ce0bfSmrg# Source file extension for fc test sources. 112270b0ce0bfSmrgac_ext=${ac_fc_srcext-f} 112285a81ca49Smrg 112290b0ce0bfSmrg# Object file extension for compiled fc test sources. 112300b0ce0bfSmrgobjext=o 112310b0ce0bfSmrg_LT_TAGVAR(objext, $1)=$objext 112325a81ca49Smrg 112330b0ce0bfSmrg# No sense in running all these tests if we already determined that 112340b0ce0bfSmrg# the FC compiler isn't working. Some variables (like enable_shared) 112350b0ce0bfSmrg# are currently assumed to apply to all compilers on this platform, 112360b0ce0bfSmrg# and will be corrupted by setting them based on a non-working compiler. 112370b0ce0bfSmrgif test yes != "$_lt_disable_FC"; then 112380b0ce0bfSmrg # Code to be used in simple compile tests 112390b0ce0bfSmrg lt_simple_compile_test_code="\ 112400b0ce0bfSmrg subroutine t 112410b0ce0bfSmrg return 112420b0ce0bfSmrg end 112430b0ce0bfSmrg" 1124432b578d3Smrg 112450b0ce0bfSmrg # Code to be used in simple link tests 112460b0ce0bfSmrg lt_simple_link_test_code="\ 112470b0ce0bfSmrg program t 112480b0ce0bfSmrg end 112490b0ce0bfSmrg" 112505a81ca49Smrg 112510b0ce0bfSmrg # ltmain only uses $CC for tagged configurations so make sure $CC is set. 112520b0ce0bfSmrg _LT_TAG_COMPILER 112535a81ca49Smrg 112540b0ce0bfSmrg # save warnings/boilerplate of simple test code 112550b0ce0bfSmrg _LT_COMPILER_BOILERPLATE 112560b0ce0bfSmrg _LT_LINKER_BOILERPLATE 112575a81ca49Smrg 112580b0ce0bfSmrg # Allow CC to be a program name with arguments. 112590b0ce0bfSmrg lt_save_CC=$CC 112600b0ce0bfSmrg lt_save_GCC=$GCC 112610b0ce0bfSmrg lt_save_CFLAGS=$CFLAGS 112620b0ce0bfSmrg CC=${FC-"f95"} 112630b0ce0bfSmrg CFLAGS=$FCFLAGS 112640b0ce0bfSmrg compiler=$CC 112650b0ce0bfSmrg GCC=$ac_cv_fc_compiler_gnu 112665a81ca49Smrg 112670b0ce0bfSmrg _LT_TAGVAR(compiler, $1)=$CC 112680b0ce0bfSmrg _LT_CC_BASENAME([$compiler]) 1126932b578d3Smrg 112700b0ce0bfSmrg if test -n "$compiler"; then 112710b0ce0bfSmrg AC_MSG_CHECKING([if libtool supports shared libraries]) 112720b0ce0bfSmrg AC_MSG_RESULT([$can_build_shared]) 112735a81ca49Smrg 112740b0ce0bfSmrg AC_MSG_CHECKING([whether to build shared libraries]) 112750b0ce0bfSmrg test no = "$can_build_shared" && enable_shared=no 112765a81ca49Smrg 112770b0ce0bfSmrg # On AIX, shared libraries and static libraries use the same namespace, and 112780b0ce0bfSmrg # are all built from PIC. 112790b0ce0bfSmrg case $host_os in 112800b0ce0bfSmrg aix3*) 112810b0ce0bfSmrg test yes = "$enable_shared" && enable_static=no 112820b0ce0bfSmrg if test -n "$RANLIB"; then 112830b0ce0bfSmrg archive_cmds="$archive_cmds~\$RANLIB \$lib" 112840b0ce0bfSmrg postinstall_cmds='$RANLIB $lib' 112850b0ce0bfSmrg fi 112860b0ce0bfSmrg ;; 112870b0ce0bfSmrg aix[[4-9]]*) 112880b0ce0bfSmrg if test ia64 != "$host_cpu"; then 112890b0ce0bfSmrg case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in 112900b0ce0bfSmrg yes,aix,yes) ;; # shared object as lib.so file only 112910b0ce0bfSmrg yes,svr4,*) ;; # shared object as lib.so archive member only 112920b0ce0bfSmrg yes,*) enable_static=no ;; # shared object in lib.a archive as well 112930b0ce0bfSmrg esac 112940b0ce0bfSmrg fi 112950b0ce0bfSmrg ;; 112960b0ce0bfSmrg esac 112970b0ce0bfSmrg AC_MSG_RESULT([$enable_shared]) 112985a81ca49Smrg 112990b0ce0bfSmrg AC_MSG_CHECKING([whether to build static libraries]) 113000b0ce0bfSmrg # Make sure either enable_shared or enable_static is yes. 113010b0ce0bfSmrg test yes = "$enable_shared" || enable_static=yes 113020b0ce0bfSmrg AC_MSG_RESULT([$enable_static]) 113035a81ca49Smrg 113040b0ce0bfSmrg _LT_TAGVAR(GCC, $1)=$ac_cv_fc_compiler_gnu 113050b0ce0bfSmrg _LT_TAGVAR(LD, $1)=$LD 113065a81ca49Smrg 113070b0ce0bfSmrg ## CAVEAT EMPTOR: 113080b0ce0bfSmrg ## There is no encapsulation within the following macros, do not change 113090b0ce0bfSmrg ## the running order or otherwise move them around unless you know exactly 113100b0ce0bfSmrg ## what you are doing... 113110b0ce0bfSmrg _LT_SYS_HIDDEN_LIBDEPS($1) 113120b0ce0bfSmrg _LT_COMPILER_PIC($1) 113130b0ce0bfSmrg _LT_COMPILER_C_O($1) 113140b0ce0bfSmrg _LT_COMPILER_FILE_LOCKS($1) 113150b0ce0bfSmrg _LT_LINKER_SHLIBS($1) 113160b0ce0bfSmrg _LT_SYS_DYNAMIC_LINKER($1) 113170b0ce0bfSmrg _LT_LINKER_HARDCODE_LIBPATH($1) 113185a81ca49Smrg 113190b0ce0bfSmrg _LT_CONFIG($1) 113200b0ce0bfSmrg fi # test -n "$compiler" 113215a81ca49Smrg 113220b0ce0bfSmrg GCC=$lt_save_GCC 113230b0ce0bfSmrg CC=$lt_save_CC 113240b0ce0bfSmrg CFLAGS=$lt_save_CFLAGS 113250b0ce0bfSmrgfi # test yes != "$_lt_disable_FC" 1132632b578d3Smrg 113270b0ce0bfSmrgAC_LANG_POP 113280b0ce0bfSmrg])# _LT_LANG_FC_CONFIG 11329e35d4d8eSmrg 113305a81ca49Smrg 113310b0ce0bfSmrg# _LT_LANG_GCJ_CONFIG([TAG]) 113320b0ce0bfSmrg# -------------------------- 113330b0ce0bfSmrg# Ensure that the configuration variables for the GNU Java Compiler compiler 113340b0ce0bfSmrg# are suitably defined. These variables are subsequently used by _LT_CONFIG 113350b0ce0bfSmrg# to write the compiler configuration to 'libtool'. 113360b0ce0bfSmrgm4_defun([_LT_LANG_GCJ_CONFIG], 113370b0ce0bfSmrg[AC_REQUIRE([LT_PROG_GCJ])dnl 113380b0ce0bfSmrgAC_LANG_SAVE 113395a81ca49Smrg 113400b0ce0bfSmrg# Source file extension for Java test sources. 113410b0ce0bfSmrgac_ext=java 113425a81ca49Smrg 113430b0ce0bfSmrg# Object file extension for compiled Java test sources. 113440b0ce0bfSmrgobjext=o 113450b0ce0bfSmrg_LT_TAGVAR(objext, $1)=$objext 11346e35d4d8eSmrg 113470b0ce0bfSmrg# Code to be used in simple compile tests 113480b0ce0bfSmrglt_simple_compile_test_code="class foo {}" 113495a81ca49Smrg 113500b0ce0bfSmrg# Code to be used in simple link tests 113510b0ce0bfSmrglt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }' 113525a81ca49Smrg 113530b0ce0bfSmrg# ltmain only uses $CC for tagged configurations so make sure $CC is set. 113540b0ce0bfSmrg_LT_TAG_COMPILER 113555a81ca49Smrg 113560b0ce0bfSmrg# save warnings/boilerplate of simple test code 113570b0ce0bfSmrg_LT_COMPILER_BOILERPLATE 113580b0ce0bfSmrg_LT_LINKER_BOILERPLATE 113595a81ca49Smrg 113600b0ce0bfSmrg# Allow CC to be a program name with arguments. 113610b0ce0bfSmrglt_save_CC=$CC 113620b0ce0bfSmrglt_save_CFLAGS=$CFLAGS 113630b0ce0bfSmrglt_save_GCC=$GCC 113640b0ce0bfSmrgGCC=yes 113650b0ce0bfSmrgCC=${GCJ-"gcj"} 113660b0ce0bfSmrgCFLAGS=$GCJFLAGS 113670b0ce0bfSmrgcompiler=$CC 113680b0ce0bfSmrg_LT_TAGVAR(compiler, $1)=$CC 113690b0ce0bfSmrg_LT_TAGVAR(LD, $1)=$LD 113700b0ce0bfSmrg_LT_CC_BASENAME([$compiler]) 113715a81ca49Smrg 113720b0ce0bfSmrg# GCJ did not exist at the time GCC didn't implicitly link libc in. 113730b0ce0bfSmrg_LT_TAGVAR(archive_cmds_need_lc, $1)=no 113745a81ca49Smrg 113750b0ce0bfSmrg_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 113760b0ce0bfSmrg_LT_TAGVAR(reload_flag, $1)=$reload_flag 113770b0ce0bfSmrg_LT_TAGVAR(reload_cmds, $1)=$reload_cmds 113785a81ca49Smrg 113790b0ce0bfSmrgif test -n "$compiler"; then 113800b0ce0bfSmrg _LT_COMPILER_NO_RTTI($1) 113810b0ce0bfSmrg _LT_COMPILER_PIC($1) 113820b0ce0bfSmrg _LT_COMPILER_C_O($1) 113830b0ce0bfSmrg _LT_COMPILER_FILE_LOCKS($1) 113840b0ce0bfSmrg _LT_LINKER_SHLIBS($1) 113850b0ce0bfSmrg _LT_LINKER_HARDCODE_LIBPATH($1) 113860b0ce0bfSmrg 113870b0ce0bfSmrg _LT_CONFIG($1) 113885a81ca49Smrgfi 113895a81ca49Smrg 113900b0ce0bfSmrgAC_LANG_RESTORE 113915a81ca49Smrg 113920b0ce0bfSmrgGCC=$lt_save_GCC 113930b0ce0bfSmrgCC=$lt_save_CC 113940b0ce0bfSmrgCFLAGS=$lt_save_CFLAGS 113950b0ce0bfSmrg])# _LT_LANG_GCJ_CONFIG 113965a81ca49Smrg 11397e35d4d8eSmrg 113980b0ce0bfSmrg# _LT_LANG_GO_CONFIG([TAG]) 113990b0ce0bfSmrg# -------------------------- 114000b0ce0bfSmrg# Ensure that the configuration variables for the GNU Go compiler 114010b0ce0bfSmrg# are suitably defined. These variables are subsequently used by _LT_CONFIG 114020b0ce0bfSmrg# to write the compiler configuration to 'libtool'. 114030b0ce0bfSmrgm4_defun([_LT_LANG_GO_CONFIG], 114040b0ce0bfSmrg[AC_REQUIRE([LT_PROG_GO])dnl 114050b0ce0bfSmrgAC_LANG_SAVE 1140632b578d3Smrg 114070b0ce0bfSmrg# Source file extension for Go test sources. 114080b0ce0bfSmrgac_ext=go 1140932b578d3Smrg 114100b0ce0bfSmrg# Object file extension for compiled Go test sources. 114110b0ce0bfSmrgobjext=o 114120b0ce0bfSmrg_LT_TAGVAR(objext, $1)=$objext 1141332b578d3Smrg 114140b0ce0bfSmrg# Code to be used in simple compile tests 114150b0ce0bfSmrglt_simple_compile_test_code="package main; func main() { }" 1141632b578d3Smrg 114170b0ce0bfSmrg# Code to be used in simple link tests 114180b0ce0bfSmrglt_simple_link_test_code='package main; func main() { }' 1141932b578d3Smrg 114200b0ce0bfSmrg# ltmain only uses $CC for tagged configurations so make sure $CC is set. 114210b0ce0bfSmrg_LT_TAG_COMPILER 1142232b578d3Smrg 114230b0ce0bfSmrg# save warnings/boilerplate of simple test code 114240b0ce0bfSmrg_LT_COMPILER_BOILERPLATE 114250b0ce0bfSmrg_LT_LINKER_BOILERPLATE 114260b0ce0bfSmrg 114270b0ce0bfSmrg# Allow CC to be a program name with arguments. 114280b0ce0bfSmrglt_save_CC=$CC 114290b0ce0bfSmrglt_save_CFLAGS=$CFLAGS 114300b0ce0bfSmrglt_save_GCC=$GCC 114310b0ce0bfSmrgGCC=yes 114320b0ce0bfSmrgCC=${GOC-"gccgo"} 114330b0ce0bfSmrgCFLAGS=$GOFLAGS 114340b0ce0bfSmrgcompiler=$CC 114350b0ce0bfSmrg_LT_TAGVAR(compiler, $1)=$CC 114360b0ce0bfSmrg_LT_TAGVAR(LD, $1)=$LD 114370b0ce0bfSmrg_LT_CC_BASENAME([$compiler]) 114380b0ce0bfSmrg 114390b0ce0bfSmrg# Go did not exist at the time GCC didn't implicitly link libc in. 114400b0ce0bfSmrg_LT_TAGVAR(archive_cmds_need_lc, $1)=no 114410b0ce0bfSmrg 114420b0ce0bfSmrg_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 114430b0ce0bfSmrg_LT_TAGVAR(reload_flag, $1)=$reload_flag 114440b0ce0bfSmrg_LT_TAGVAR(reload_cmds, $1)=$reload_cmds 114455a81ca49Smrg 114460b0ce0bfSmrgif test -n "$compiler"; then 114470b0ce0bfSmrg _LT_COMPILER_NO_RTTI($1) 114480b0ce0bfSmrg _LT_COMPILER_PIC($1) 114490b0ce0bfSmrg _LT_COMPILER_C_O($1) 114500b0ce0bfSmrg _LT_COMPILER_FILE_LOCKS($1) 114510b0ce0bfSmrg _LT_LINKER_SHLIBS($1) 114520b0ce0bfSmrg _LT_LINKER_HARDCODE_LIBPATH($1) 114535a81ca49Smrg 114540b0ce0bfSmrg _LT_CONFIG($1) 114550b0ce0bfSmrgfi 114565a81ca49Smrg 114570b0ce0bfSmrgAC_LANG_RESTORE 114585a81ca49Smrg 114590b0ce0bfSmrgGCC=$lt_save_GCC 114600b0ce0bfSmrgCC=$lt_save_CC 114610b0ce0bfSmrgCFLAGS=$lt_save_CFLAGS 114620b0ce0bfSmrg])# _LT_LANG_GO_CONFIG 114635a81ca49Smrg 114645a81ca49Smrg 114650b0ce0bfSmrg# _LT_LANG_RC_CONFIG([TAG]) 114660b0ce0bfSmrg# ------------------------- 114670b0ce0bfSmrg# Ensure that the configuration variables for the Windows resource compiler 114680b0ce0bfSmrg# are suitably defined. These variables are subsequently used by _LT_CONFIG 114690b0ce0bfSmrg# to write the compiler configuration to 'libtool'. 114700b0ce0bfSmrgm4_defun([_LT_LANG_RC_CONFIG], 114710b0ce0bfSmrg[AC_REQUIRE([LT_PROG_RC])dnl 114720b0ce0bfSmrgAC_LANG_SAVE 114735a81ca49Smrg 114740b0ce0bfSmrg# Source file extension for RC test sources. 114750b0ce0bfSmrgac_ext=rc 114765a81ca49Smrg 114770b0ce0bfSmrg# Object file extension for compiled RC test sources. 114780b0ce0bfSmrgobjext=o 114790b0ce0bfSmrg_LT_TAGVAR(objext, $1)=$objext 114805a81ca49Smrg 114810b0ce0bfSmrg# Code to be used in simple compile tests 114820b0ce0bfSmrglt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }' 114835a81ca49Smrg 114840b0ce0bfSmrg# Code to be used in simple link tests 114850b0ce0bfSmrglt_simple_link_test_code=$lt_simple_compile_test_code 114865a81ca49Smrg 114870b0ce0bfSmrg# ltmain only uses $CC for tagged configurations so make sure $CC is set. 114880b0ce0bfSmrg_LT_TAG_COMPILER 114895a81ca49Smrg 114900b0ce0bfSmrg# save warnings/boilerplate of simple test code 114910b0ce0bfSmrg_LT_COMPILER_BOILERPLATE 114920b0ce0bfSmrg_LT_LINKER_BOILERPLATE 114935a81ca49Smrg 114940b0ce0bfSmrg# Allow CC to be a program name with arguments. 114950b0ce0bfSmrglt_save_CC=$CC 114960b0ce0bfSmrglt_save_CFLAGS=$CFLAGS 114970b0ce0bfSmrglt_save_GCC=$GCC 114980b0ce0bfSmrgGCC= 114990b0ce0bfSmrgCC=${RC-"windres"} 115000b0ce0bfSmrgCFLAGS= 115010b0ce0bfSmrgcompiler=$CC 115020b0ce0bfSmrg_LT_TAGVAR(compiler, $1)=$CC 115030b0ce0bfSmrg_LT_CC_BASENAME([$compiler]) 115040b0ce0bfSmrg_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes 115055a81ca49Smrg 115060b0ce0bfSmrgif test -n "$compiler"; then 115070b0ce0bfSmrg : 115080b0ce0bfSmrg _LT_CONFIG($1) 115090b0ce0bfSmrgfi 115100b0ce0bfSmrg 115110b0ce0bfSmrgGCC=$lt_save_GCC 115120b0ce0bfSmrgAC_LANG_RESTORE 115130b0ce0bfSmrgCC=$lt_save_CC 115140b0ce0bfSmrgCFLAGS=$lt_save_CFLAGS 115150b0ce0bfSmrg])# _LT_LANG_RC_CONFIG 115160b0ce0bfSmrg 115170b0ce0bfSmrg 115180b0ce0bfSmrg# LT_PROG_GCJ 115190b0ce0bfSmrg# ----------- 115200b0ce0bfSmrgAC_DEFUN([LT_PROG_GCJ], 115210b0ce0bfSmrg[m4_ifdef([AC_PROG_GCJ], [AC_PROG_GCJ], 115220b0ce0bfSmrg [m4_ifdef([A][M_PROG_GCJ], [A][M_PROG_GCJ], 115230b0ce0bfSmrg [AC_CHECK_TOOL(GCJ, gcj,) 115240b0ce0bfSmrg test set = "${GCJFLAGS+set}" || GCJFLAGS="-g -O2" 115250b0ce0bfSmrg AC_SUBST(GCJFLAGS)])])[]dnl 115265a81ca49Smrg]) 115275a81ca49Smrg 115280b0ce0bfSmrg# Old name: 115290b0ce0bfSmrgAU_ALIAS([LT_AC_PROG_GCJ], [LT_PROG_GCJ]) 115300b0ce0bfSmrgdnl aclocal-1.4 backwards compatibility: 115310b0ce0bfSmrgdnl AC_DEFUN([LT_AC_PROG_GCJ], []) 115325a81ca49Smrg 115335a81ca49Smrg 115340b0ce0bfSmrg# LT_PROG_GO 115350b0ce0bfSmrg# ---------- 115360b0ce0bfSmrgAC_DEFUN([LT_PROG_GO], 115370b0ce0bfSmrg[AC_CHECK_TOOL(GOC, gccgo,) 115380b0ce0bfSmrg]) 1153932b578d3Smrg 115405a81ca49Smrg 115410b0ce0bfSmrg# LT_PROG_RC 115420b0ce0bfSmrg# ---------- 115430b0ce0bfSmrgAC_DEFUN([LT_PROG_RC], 115440b0ce0bfSmrg[AC_CHECK_TOOL(RC, windres,) 115450b0ce0bfSmrg]) 115465a81ca49Smrg 115470b0ce0bfSmrg# Old name: 115480b0ce0bfSmrgAU_ALIAS([LT_AC_PROG_RC], [LT_PROG_RC]) 115490b0ce0bfSmrgdnl aclocal-1.4 backwards compatibility: 115500b0ce0bfSmrgdnl AC_DEFUN([LT_AC_PROG_RC], []) 115515a81ca49Smrg 115525a81ca49Smrg 115530b0ce0bfSmrg# _LT_DECL_EGREP 115540b0ce0bfSmrg# -------------- 115550b0ce0bfSmrg# If we don't have a new enough Autoconf to choose the best grep 115560b0ce0bfSmrg# available, choose the one first in the user's PATH. 115570b0ce0bfSmrgm4_defun([_LT_DECL_EGREP], 115580b0ce0bfSmrg[AC_REQUIRE([AC_PROG_EGREP])dnl 115590b0ce0bfSmrgAC_REQUIRE([AC_PROG_FGREP])dnl 115600b0ce0bfSmrgtest -z "$GREP" && GREP=grep 115610b0ce0bfSmrg_LT_DECL([], [GREP], [1], [A grep program that handles long lines]) 115620b0ce0bfSmrg_LT_DECL([], [EGREP], [1], [An ERE matcher]) 115630b0ce0bfSmrg_LT_DECL([], [FGREP], [1], [A literal string matcher]) 115640b0ce0bfSmrgdnl Non-bleeding-edge autoconf doesn't subst GREP, so do it here too 115650b0ce0bfSmrgAC_SUBST([GREP]) 115660b0ce0bfSmrg]) 1156732b578d3Smrg 1156832b578d3Smrg 115690b0ce0bfSmrg# _LT_DECL_OBJDUMP 115700b0ce0bfSmrg# -------------- 115710b0ce0bfSmrg# If we don't have a new enough Autoconf to choose the best objdump 115720b0ce0bfSmrg# available, choose the one first in the user's PATH. 115730b0ce0bfSmrgm4_defun([_LT_DECL_OBJDUMP], 115740b0ce0bfSmrg[AC_CHECK_TOOL(OBJDUMP, objdump, false) 115750b0ce0bfSmrgtest -z "$OBJDUMP" && OBJDUMP=objdump 115760b0ce0bfSmrg_LT_DECL([], [OBJDUMP], [1], [An object symbol dumper]) 115770b0ce0bfSmrgAC_SUBST([OBJDUMP]) 115780b0ce0bfSmrg]) 115795a81ca49Smrg 115800b0ce0bfSmrg# _LT_DECL_DLLTOOL 115810b0ce0bfSmrg# ---------------- 115820b0ce0bfSmrg# Ensure DLLTOOL variable is set. 115830b0ce0bfSmrgm4_defun([_LT_DECL_DLLTOOL], 115840b0ce0bfSmrg[AC_CHECK_TOOL(DLLTOOL, dlltool, false) 115850b0ce0bfSmrgtest -z "$DLLTOOL" && DLLTOOL=dlltool 115860b0ce0bfSmrg_LT_DECL([], [DLLTOOL], [1], [DLL creation program]) 115870b0ce0bfSmrgAC_SUBST([DLLTOOL]) 115880b0ce0bfSmrg]) 115895a81ca49Smrg 115900b0ce0bfSmrg# _LT_DECL_FILECMD 115910b0ce0bfSmrg# ---------------- 115920b0ce0bfSmrg# Check for a file(cmd) program that can be used to detect file type and magic 115930b0ce0bfSmrgm4_defun([_LT_DECL_FILECMD], 115940b0ce0bfSmrg[AC_CHECK_TOOL([FILECMD], [file], [:]) 115950b0ce0bfSmrg_LT_DECL([], [FILECMD], [1], [A file(cmd) program that detects file types]) 115960b0ce0bfSmrg])# _LD_DECL_FILECMD 115975a81ca49Smrg 115980b0ce0bfSmrg# _LT_DECL_SED 115990b0ce0bfSmrg# ------------ 116000b0ce0bfSmrg# Check for a fully-functional sed program, that truncates 116010b0ce0bfSmrg# as few characters as possible. Prefer GNU sed if found. 116020b0ce0bfSmrgm4_defun([_LT_DECL_SED], 116030b0ce0bfSmrg[AC_PROG_SED 116040b0ce0bfSmrgtest -z "$SED" && SED=sed 116050b0ce0bfSmrgXsed="$SED -e 1s/^X//" 116060b0ce0bfSmrg_LT_DECL([], [SED], [1], [A sed program that does not truncate output]) 116070b0ce0bfSmrg_LT_DECL([], [Xsed], ["\$SED -e 1s/^X//"], 116080b0ce0bfSmrg [Sed that helps us avoid accidentally triggering echo(1) options like -n]) 116090b0ce0bfSmrg])# _LT_DECL_SED 116100b0ce0bfSmrg 116110b0ce0bfSmrgm4_ifndef([AC_PROG_SED], [ 116120b0ce0bfSmrg# NOTE: This macro has been submitted for inclusion into # 116130b0ce0bfSmrg# GNU Autoconf as AC_PROG_SED. When it is available in # 116140b0ce0bfSmrg# a released version of Autoconf we should remove this # 116150b0ce0bfSmrg# macro and use it instead. # 116160b0ce0bfSmrg 116170b0ce0bfSmrgm4_defun([AC_PROG_SED], 116180b0ce0bfSmrg[AC_MSG_CHECKING([for a sed that does not truncate output]) 116190b0ce0bfSmrgAC_CACHE_VAL(lt_cv_path_SED, 116200b0ce0bfSmrg[# Loop through the user's path and test for sed and gsed. 116210b0ce0bfSmrg# Then use that list of sed's as ones to test for truncation. 116220b0ce0bfSmrgas_save_IFS=$IFS; IFS=$PATH_SEPARATOR 116230b0ce0bfSmrgfor as_dir in $PATH 116240b0ce0bfSmrgdo 116250b0ce0bfSmrg IFS=$as_save_IFS 116260b0ce0bfSmrg test -z "$as_dir" && as_dir=. 116270b0ce0bfSmrg for lt_ac_prog in sed gsed; do 116280b0ce0bfSmrg for ac_exec_ext in '' $ac_executable_extensions; do 116290b0ce0bfSmrg if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then 116300b0ce0bfSmrg lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext" 116315a81ca49Smrg fi 116320b0ce0bfSmrg done 116330b0ce0bfSmrg done 116340b0ce0bfSmrgdone 116350b0ce0bfSmrgIFS=$as_save_IFS 116360b0ce0bfSmrglt_ac_max=0 116370b0ce0bfSmrglt_ac_count=0 116380b0ce0bfSmrg# Add /usr/xpg4/bin/sed as it is typically found on Solaris 116390b0ce0bfSmrg# along with /bin/sed that truncates output. 116400b0ce0bfSmrgfor lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do 116410b0ce0bfSmrg test ! -f "$lt_ac_sed" && continue 116420b0ce0bfSmrg cat /dev/null > conftest.in 116430b0ce0bfSmrg lt_ac_count=0 116440b0ce0bfSmrg echo $ECHO_N "0123456789$ECHO_C" >conftest.in 116450b0ce0bfSmrg # Check for GNU sed and select it if it is found. 116460b0ce0bfSmrg if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then 116470b0ce0bfSmrg lt_cv_path_SED=$lt_ac_sed 116480b0ce0bfSmrg break 116490b0ce0bfSmrg fi 116500b0ce0bfSmrg while true; do 116510b0ce0bfSmrg cat conftest.in conftest.in >conftest.tmp 116520b0ce0bfSmrg mv conftest.tmp conftest.in 116530b0ce0bfSmrg cp conftest.in conftest.nl 116540b0ce0bfSmrg echo >>conftest.nl 116550b0ce0bfSmrg $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break 116560b0ce0bfSmrg cmp -s conftest.out conftest.nl || break 116570b0ce0bfSmrg # 10000 chars as input seems more than enough 116580b0ce0bfSmrg test 10 -lt "$lt_ac_count" && break 116590b0ce0bfSmrg lt_ac_count=`expr $lt_ac_count + 1` 116600b0ce0bfSmrg if test "$lt_ac_count" -gt "$lt_ac_max"; then 116610b0ce0bfSmrg lt_ac_max=$lt_ac_count 116620b0ce0bfSmrg lt_cv_path_SED=$lt_ac_sed 116635a81ca49Smrg fi 116645a81ca49Smrg done 116650b0ce0bfSmrgdone 116660b0ce0bfSmrg]) 116670b0ce0bfSmrgSED=$lt_cv_path_SED 116680b0ce0bfSmrgAC_SUBST([SED]) 116690b0ce0bfSmrgAC_MSG_RESULT([$SED]) 116700b0ce0bfSmrg])#AC_PROG_SED 116710b0ce0bfSmrg])#m4_ifndef 1167232b578d3Smrg 116730b0ce0bfSmrg# Old name: 116740b0ce0bfSmrgAU_ALIAS([LT_AC_PROG_SED], [AC_PROG_SED]) 116750b0ce0bfSmrgdnl aclocal-1.4 backwards compatibility: 116760b0ce0bfSmrgdnl AC_DEFUN([LT_AC_PROG_SED], []) 116770b0ce0bfSmrg 116780b0ce0bfSmrg 116790b0ce0bfSmrg# _LT_CHECK_SHELL_FEATURES 116800b0ce0bfSmrg# ------------------------ 116810b0ce0bfSmrg# Find out whether the shell is Bourne or XSI compatible, 116820b0ce0bfSmrg# or has some other useful features. 116830b0ce0bfSmrgm4_defun([_LT_CHECK_SHELL_FEATURES], 116840b0ce0bfSmrg[if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then 116850b0ce0bfSmrg lt_unset=unset 116865a81ca49Smrgelse 116870b0ce0bfSmrg lt_unset=false 11688e35d4d8eSmrgfi 116890b0ce0bfSmrg_LT_DECL([], [lt_unset], [0], [whether the shell understands "unset"])dnl 116900b0ce0bfSmrg 116910b0ce0bfSmrg# test EBCDIC or ASCII 116920b0ce0bfSmrgcase `echo X|tr X '\101'` in 116930b0ce0bfSmrg A) # ASCII based system 116940b0ce0bfSmrg # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr 116950b0ce0bfSmrg lt_SP2NL='tr \040 \012' 116960b0ce0bfSmrg lt_NL2SP='tr \015\012 \040\040' 116970b0ce0bfSmrg ;; 116980b0ce0bfSmrg *) # EBCDIC based system 116990b0ce0bfSmrg lt_SP2NL='tr \100 \n' 117000b0ce0bfSmrg lt_NL2SP='tr \r\n \100\100' 117010b0ce0bfSmrg ;; 117020b0ce0bfSmrgesac 117030b0ce0bfSmrg_LT_DECL([SP2NL], [lt_SP2NL], [1], [turn spaces into newlines])dnl 117040b0ce0bfSmrg_LT_DECL([NL2SP], [lt_NL2SP], [1], [turn newlines into spaces])dnl 117050b0ce0bfSmrg])# _LT_CHECK_SHELL_FEATURES 117060b0ce0bfSmrg 117070b0ce0bfSmrg 117080b0ce0bfSmrg# _LT_PATH_CONVERSION_FUNCTIONS 117090b0ce0bfSmrg# ----------------------------- 117100b0ce0bfSmrg# Determine what file name conversion functions should be used by 117110b0ce0bfSmrg# func_to_host_file (and, implicitly, by func_to_host_path). These are needed 117120b0ce0bfSmrg# for certain cross-compile configurations and native mingw. 117130b0ce0bfSmrgm4_defun([_LT_PATH_CONVERSION_FUNCTIONS], 117140b0ce0bfSmrg[AC_REQUIRE([AC_CANONICAL_HOST])dnl 117150b0ce0bfSmrgAC_REQUIRE([AC_CANONICAL_BUILD])dnl 117160b0ce0bfSmrgAC_MSG_CHECKING([how to convert $build file names to $host format]) 117170b0ce0bfSmrgAC_CACHE_VAL(lt_cv_to_host_file_cmd, 117180b0ce0bfSmrg[case $host in 117190b0ce0bfSmrg *-*-mingw* ) 117200b0ce0bfSmrg case $build in 117210b0ce0bfSmrg *-*-mingw* ) # actually msys 117220b0ce0bfSmrg lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32 117230b0ce0bfSmrg ;; 117240b0ce0bfSmrg *-*-cygwin* ) 117250b0ce0bfSmrg lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32 117260b0ce0bfSmrg ;; 117270b0ce0bfSmrg * ) # otherwise, assume *nix 117280b0ce0bfSmrg lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32 117290b0ce0bfSmrg ;; 117300b0ce0bfSmrg esac 117310b0ce0bfSmrg ;; 117320b0ce0bfSmrg *-*-cygwin* ) 117330b0ce0bfSmrg case $build in 117340b0ce0bfSmrg *-*-mingw* ) # actually msys 117350b0ce0bfSmrg lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin 117360b0ce0bfSmrg ;; 117370b0ce0bfSmrg *-*-cygwin* ) 117380b0ce0bfSmrg lt_cv_to_host_file_cmd=func_convert_file_noop 117390b0ce0bfSmrg ;; 117400b0ce0bfSmrg * ) # otherwise, assume *nix 117410b0ce0bfSmrg lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin 117420b0ce0bfSmrg ;; 117430b0ce0bfSmrg esac 117440b0ce0bfSmrg ;; 117450b0ce0bfSmrg * ) # unhandled hosts (and "normal" native builds) 117460b0ce0bfSmrg lt_cv_to_host_file_cmd=func_convert_file_noop 117470b0ce0bfSmrg ;; 117480b0ce0bfSmrgesac 117495a81ca49Smrg]) 117500b0ce0bfSmrgto_host_file_cmd=$lt_cv_to_host_file_cmd 117510b0ce0bfSmrgAC_MSG_RESULT([$lt_cv_to_host_file_cmd]) 117520b0ce0bfSmrg_LT_DECL([to_host_file_cmd], [lt_cv_to_host_file_cmd], 117530b0ce0bfSmrg [0], [convert $build file names to $host format])dnl 117540b0ce0bfSmrg 117550b0ce0bfSmrgAC_MSG_CHECKING([how to convert $build file names to toolchain format]) 117560b0ce0bfSmrgAC_CACHE_VAL(lt_cv_to_tool_file_cmd, 117570b0ce0bfSmrg[#assume ordinary cross tools, or native build. 117580b0ce0bfSmrglt_cv_to_tool_file_cmd=func_convert_file_noop 117590b0ce0bfSmrgcase $host in 117600b0ce0bfSmrg *-*-mingw* ) 117610b0ce0bfSmrg case $build in 117620b0ce0bfSmrg *-*-mingw* ) # actually msys 117630b0ce0bfSmrg lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32 117640b0ce0bfSmrg ;; 117650b0ce0bfSmrg esac 117660b0ce0bfSmrg ;; 117670b0ce0bfSmrgesac 117685a81ca49Smrg]) 117690b0ce0bfSmrgto_tool_file_cmd=$lt_cv_to_tool_file_cmd 117700b0ce0bfSmrgAC_MSG_RESULT([$lt_cv_to_tool_file_cmd]) 117710b0ce0bfSmrg_LT_DECL([to_tool_file_cmd], [lt_cv_to_tool_file_cmd], 117720b0ce0bfSmrg [0], [convert $build files to toolchain format])dnl 117730b0ce0bfSmrg])# _LT_PATH_CONVERSION_FUNCTIONS 117740b0ce0bfSmrg 117750b0ce0bfSmrg# Helper functions for option handling. -*- Autoconf -*- 117760b0ce0bfSmrg# 117770b0ce0bfSmrg# Copyright (C) 2004-2005, 2007-2009, 2011-2019, 2021-2022 Free 117780b0ce0bfSmrg# Software Foundation, Inc. 117790b0ce0bfSmrg# Written by Gary V. Vaughan, 2004 117800b0ce0bfSmrg# 117810b0ce0bfSmrg# This file is free software; the Free Software Foundation gives 117820b0ce0bfSmrg# unlimited permission to copy and/or distribute it, with or without 117830b0ce0bfSmrg# modifications, as long as this notice is preserved. 1178432b578d3Smrg 117850b0ce0bfSmrg# serial 8 ltoptions.m4 1178632b578d3Smrg 117870b0ce0bfSmrg# This is to help aclocal find these macros, as it can't see m4_define. 117880b0ce0bfSmrgAC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])]) 117890b0ce0bfSmrg 117900b0ce0bfSmrg 117910b0ce0bfSmrg# _LT_MANGLE_OPTION(MACRO-NAME, OPTION-NAME) 117920b0ce0bfSmrg# ------------------------------------------ 117930b0ce0bfSmrgm4_define([_LT_MANGLE_OPTION], 117940b0ce0bfSmrg[[_LT_OPTION_]m4_bpatsubst($1__$2, [[^a-zA-Z0-9_]], [_])]) 117950b0ce0bfSmrg 117960b0ce0bfSmrg 117970b0ce0bfSmrg# _LT_SET_OPTION(MACRO-NAME, OPTION-NAME) 117980b0ce0bfSmrg# --------------------------------------- 117990b0ce0bfSmrg# Set option OPTION-NAME for macro MACRO-NAME, and if there is a 118000b0ce0bfSmrg# matching handler defined, dispatch to it. Other OPTION-NAMEs are 118010b0ce0bfSmrg# saved as a flag. 118020b0ce0bfSmrgm4_define([_LT_SET_OPTION], 118030b0ce0bfSmrg[m4_define(_LT_MANGLE_OPTION([$1], [$2]))dnl 118040b0ce0bfSmrgm4_ifdef(_LT_MANGLE_DEFUN([$1], [$2]), 118050b0ce0bfSmrg _LT_MANGLE_DEFUN([$1], [$2]), 118060b0ce0bfSmrg [m4_warning([Unknown $1 option '$2'])])[]dnl 118075a81ca49Smrg]) 1180832b578d3Smrg 1180932b578d3Smrg 118100b0ce0bfSmrg# _LT_IF_OPTION(MACRO-NAME, OPTION-NAME, IF-SET, [IF-NOT-SET]) 118110b0ce0bfSmrg# ------------------------------------------------------------ 118120b0ce0bfSmrg# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. 118130b0ce0bfSmrgm4_define([_LT_IF_OPTION], 118140b0ce0bfSmrg[m4_ifdef(_LT_MANGLE_OPTION([$1], [$2]), [$3], [$4])]) 118150b0ce0bfSmrg 118160b0ce0bfSmrg 118170b0ce0bfSmrg# _LT_UNLESS_OPTIONS(MACRO-NAME, OPTION-LIST, IF-NOT-SET) 118180b0ce0bfSmrg# ------------------------------------------------------- 118190b0ce0bfSmrg# Execute IF-NOT-SET unless all options in OPTION-LIST for MACRO-NAME 118200b0ce0bfSmrg# are set. 118210b0ce0bfSmrgm4_define([_LT_UNLESS_OPTIONS], 118220b0ce0bfSmrg[m4_foreach([_LT_Option], m4_split(m4_normalize([$2])), 118230b0ce0bfSmrg [m4_ifdef(_LT_MANGLE_OPTION([$1], _LT_Option), 118240b0ce0bfSmrg [m4_define([$0_found])])])[]dnl 118250b0ce0bfSmrgm4_ifdef([$0_found], [m4_undefine([$0_found])], [$3 118260b0ce0bfSmrg])[]dnl 118275a81ca49Smrg]) 1182832b578d3Smrg 1182932b578d3Smrg 118300b0ce0bfSmrg# _LT_SET_OPTIONS(MACRO-NAME, OPTION-LIST) 118310b0ce0bfSmrg# ---------------------------------------- 118320b0ce0bfSmrg# OPTION-LIST is a space-separated list of Libtool options associated 118330b0ce0bfSmrg# with MACRO-NAME. If any OPTION has a matching handler declared with 118340b0ce0bfSmrg# LT_OPTION_DEFINE, dispatch to that macro; otherwise complain about 118350b0ce0bfSmrg# the unknown option and exit. 118360b0ce0bfSmrgm4_defun([_LT_SET_OPTIONS], 118370b0ce0bfSmrg[# Set options 118380b0ce0bfSmrgm4_foreach([_LT_Option], m4_split(m4_normalize([$2])), 118390b0ce0bfSmrg [_LT_SET_OPTION([$1], _LT_Option)]) 118400b0ce0bfSmrg 118410b0ce0bfSmrgm4_if([$1],[LT_INIT],[ 118420b0ce0bfSmrg dnl 118430b0ce0bfSmrg dnl Simply set some default values (i.e off) if boolean options were not 118440b0ce0bfSmrg dnl specified: 118450b0ce0bfSmrg _LT_UNLESS_OPTIONS([LT_INIT], [dlopen], [enable_dlopen=no 118460b0ce0bfSmrg ]) 118470b0ce0bfSmrg _LT_UNLESS_OPTIONS([LT_INIT], [win32-dll], [enable_win32_dll=no 118480b0ce0bfSmrg ]) 118490b0ce0bfSmrg dnl 118500b0ce0bfSmrg dnl If no reference was made to various pairs of opposing options, then 118510b0ce0bfSmrg dnl we run the default mode handler for the pair. For example, if neither 118520b0ce0bfSmrg dnl 'shared' nor 'disable-shared' was passed, we enable building of shared 118530b0ce0bfSmrg dnl archives by default: 118540b0ce0bfSmrg _LT_UNLESS_OPTIONS([LT_INIT], [shared disable-shared], [_LT_ENABLE_SHARED]) 118550b0ce0bfSmrg _LT_UNLESS_OPTIONS([LT_INIT], [static disable-static], [_LT_ENABLE_STATIC]) 118560b0ce0bfSmrg _LT_UNLESS_OPTIONS([LT_INIT], [pic-only no-pic], [_LT_WITH_PIC]) 118570b0ce0bfSmrg _LT_UNLESS_OPTIONS([LT_INIT], [fast-install disable-fast-install], 118580b0ce0bfSmrg [_LT_ENABLE_FAST_INSTALL]) 118590b0ce0bfSmrg _LT_UNLESS_OPTIONS([LT_INIT], [aix-soname=aix aix-soname=both aix-soname=svr4], 118600b0ce0bfSmrg [_LT_WITH_AIX_SONAME([aix])]) 118610b0ce0bfSmrg ]) 118620b0ce0bfSmrg])# _LT_SET_OPTIONS 118635a81ca49Smrg 118645a81ca49Smrg 118655a81ca49Smrg 118660b0ce0bfSmrg# _LT_MANGLE_DEFUN(MACRO-NAME, OPTION-NAME) 118670b0ce0bfSmrg# ----------------------------------------- 118680b0ce0bfSmrgm4_define([_LT_MANGLE_DEFUN], 118690b0ce0bfSmrg[[_LT_OPTION_DEFUN_]m4_bpatsubst(m4_toupper([$1__$2]), [[^A-Z0-9_]], [_])]) 118705a81ca49Smrg 118715a81ca49Smrg 118720b0ce0bfSmrg# LT_OPTION_DEFINE(MACRO-NAME, OPTION-NAME, CODE) 118730b0ce0bfSmrg# ----------------------------------------------- 118740b0ce0bfSmrgm4_define([LT_OPTION_DEFINE], 118750b0ce0bfSmrg[m4_define(_LT_MANGLE_DEFUN([$1], [$2]), [$3])[]dnl 118760b0ce0bfSmrg])# LT_OPTION_DEFINE 118775a81ca49Smrg 1187832b578d3Smrg 118790b0ce0bfSmrg# dlopen 118800b0ce0bfSmrg# ------ 118810b0ce0bfSmrgLT_OPTION_DEFINE([LT_INIT], [dlopen], [enable_dlopen=yes 118820b0ce0bfSmrg]) 1188332b578d3Smrg 118840b0ce0bfSmrgAU_DEFUN([AC_LIBTOOL_DLOPEN], 118850b0ce0bfSmrg[_LT_SET_OPTION([LT_INIT], [dlopen]) 118860b0ce0bfSmrgAC_DIAGNOSE([obsolete], 118870b0ce0bfSmrg[$0: Remove this warning and the call to _LT_SET_OPTION when you 118880b0ce0bfSmrgput the 'dlopen' option into LT_INIT's first parameter.]) 118895a81ca49Smrg]) 1189032b578d3Smrg 118910b0ce0bfSmrgdnl aclocal-1.4 backwards compatibility: 118920b0ce0bfSmrgdnl AC_DEFUN([AC_LIBTOOL_DLOPEN], []) 118930b0ce0bfSmrg 118940b0ce0bfSmrg 118950b0ce0bfSmrg# win32-dll 118960b0ce0bfSmrg# --------- 118970b0ce0bfSmrg# Declare package support for building win32 dll's. 118980b0ce0bfSmrgLT_OPTION_DEFINE([LT_INIT], [win32-dll], 118990b0ce0bfSmrg[enable_win32_dll=yes 119000b0ce0bfSmrg 119010b0ce0bfSmrgcase $host in 119020b0ce0bfSmrg*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-cegcc*) 119030b0ce0bfSmrg AC_CHECK_TOOL(AS, as, false) 119040b0ce0bfSmrg AC_CHECK_TOOL(DLLTOOL, dlltool, false) 119050b0ce0bfSmrg AC_CHECK_TOOL(OBJDUMP, objdump, false) 119060b0ce0bfSmrg ;; 119070b0ce0bfSmrgesac 119082a51b5beSmrg 119090b0ce0bfSmrgtest -z "$AS" && AS=as 119100b0ce0bfSmrg_LT_DECL([], [AS], [1], [Assembler program])dnl 119115a81ca49Smrg 119120b0ce0bfSmrgtest -z "$DLLTOOL" && DLLTOOL=dlltool 119130b0ce0bfSmrg_LT_DECL([], [DLLTOOL], [1], [DLL creation program])dnl 119145a81ca49Smrg 119150b0ce0bfSmrgtest -z "$OBJDUMP" && OBJDUMP=objdump 119160b0ce0bfSmrg_LT_DECL([], [OBJDUMP], [1], [Object dumper program])dnl 119170b0ce0bfSmrg])# win32-dll 119185a81ca49Smrg 119190b0ce0bfSmrgAU_DEFUN([AC_LIBTOOL_WIN32_DLL], 119200b0ce0bfSmrg[AC_REQUIRE([AC_CANONICAL_HOST])dnl 119210b0ce0bfSmrg_LT_SET_OPTION([LT_INIT], [win32-dll]) 119220b0ce0bfSmrgAC_DIAGNOSE([obsolete], 119230b0ce0bfSmrg[$0: Remove this warning and the call to _LT_SET_OPTION when you 119240b0ce0bfSmrgput the 'win32-dll' option into LT_INIT's first parameter.]) 119255a81ca49Smrg]) 119262a51b5beSmrg 119270b0ce0bfSmrgdnl aclocal-1.4 backwards compatibility: 119280b0ce0bfSmrgdnl AC_DEFUN([AC_LIBTOOL_WIN32_DLL], []) 119295a81ca49Smrg 119305a81ca49Smrg 119310b0ce0bfSmrg# _LT_ENABLE_SHARED([DEFAULT]) 119320b0ce0bfSmrg# ---------------------------- 119330b0ce0bfSmrg# implement the --enable-shared flag, and supports the 'shared' and 119340b0ce0bfSmrg# 'disable-shared' LT_INIT options. 119350b0ce0bfSmrg# DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'. 119360b0ce0bfSmrgm4_define([_LT_ENABLE_SHARED], 119370b0ce0bfSmrg[m4_define([_LT_ENABLE_SHARED_DEFAULT], [m4_if($1, no, no, yes)])dnl 119380b0ce0bfSmrgAC_ARG_ENABLE([shared], 119390b0ce0bfSmrg [AS_HELP_STRING([--enable-shared@<:@=PKGS@:>@], 119400b0ce0bfSmrg [build shared libraries @<:@default=]_LT_ENABLE_SHARED_DEFAULT[@:>@])], 119410b0ce0bfSmrg [p=${PACKAGE-default} 119420b0ce0bfSmrg case $enableval in 119430b0ce0bfSmrg yes) enable_shared=yes ;; 119440b0ce0bfSmrg no) enable_shared=no ;; 119450b0ce0bfSmrg *) 119460b0ce0bfSmrg enable_shared=no 119470b0ce0bfSmrg # Look at the argument we got. We use all the common list separators. 119480b0ce0bfSmrg lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, 119490b0ce0bfSmrg for pkg in $enableval; do 119500b0ce0bfSmrg IFS=$lt_save_ifs 119510b0ce0bfSmrg if test "X$pkg" = "X$p"; then 119520b0ce0bfSmrg enable_shared=yes 119530b0ce0bfSmrg fi 119540b0ce0bfSmrg done 119550b0ce0bfSmrg IFS=$lt_save_ifs 119560b0ce0bfSmrg ;; 119570b0ce0bfSmrg esac], 119580b0ce0bfSmrg [enable_shared=]_LT_ENABLE_SHARED_DEFAULT) 1195932b578d3Smrg 119600b0ce0bfSmrg _LT_DECL([build_libtool_libs], [enable_shared], [0], 119610b0ce0bfSmrg [Whether or not to build shared libraries]) 119620b0ce0bfSmrg])# _LT_ENABLE_SHARED 1196332b578d3Smrg 119640b0ce0bfSmrgLT_OPTION_DEFINE([LT_INIT], [shared], [_LT_ENABLE_SHARED([yes])]) 119650b0ce0bfSmrgLT_OPTION_DEFINE([LT_INIT], [disable-shared], [_LT_ENABLE_SHARED([no])]) 1196632b578d3Smrg 119670b0ce0bfSmrg# Old names: 119680b0ce0bfSmrgAC_DEFUN([AC_ENABLE_SHARED], 119690b0ce0bfSmrg[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[shared]) 119700b0ce0bfSmrg]) 1197132b578d3Smrg 119720b0ce0bfSmrgAC_DEFUN([AC_DISABLE_SHARED], 119730b0ce0bfSmrg[_LT_SET_OPTION([LT_INIT], [disable-shared]) 119745a81ca49Smrg]) 1197532b578d3Smrg 119760b0ce0bfSmrgAU_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)]) 119770b0ce0bfSmrgAU_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)]) 1197832b578d3Smrg 119790b0ce0bfSmrgdnl aclocal-1.4 backwards compatibility: 119800b0ce0bfSmrgdnl AC_DEFUN([AM_ENABLE_SHARED], []) 119810b0ce0bfSmrgdnl AC_DEFUN([AM_DISABLE_SHARED], []) 1198232b578d3Smrg 1198332b578d3Smrg 11984e35d4d8eSmrg 119850b0ce0bfSmrg# _LT_ENABLE_STATIC([DEFAULT]) 119860b0ce0bfSmrg# ---------------------------- 119870b0ce0bfSmrg# implement the --enable-static flag, and support the 'static' and 119880b0ce0bfSmrg# 'disable-static' LT_INIT options. 119890b0ce0bfSmrg# DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'. 119900b0ce0bfSmrgm4_define([_LT_ENABLE_STATIC], 119910b0ce0bfSmrg[m4_define([_LT_ENABLE_STATIC_DEFAULT], [m4_if($1, no, no, yes)])dnl 119920b0ce0bfSmrgAC_ARG_ENABLE([static], 119930b0ce0bfSmrg [AS_HELP_STRING([--enable-static@<:@=PKGS@:>@], 119940b0ce0bfSmrg [build static libraries @<:@default=]_LT_ENABLE_STATIC_DEFAULT[@:>@])], 119950b0ce0bfSmrg [p=${PACKAGE-default} 119960b0ce0bfSmrg case $enableval in 119970b0ce0bfSmrg yes) enable_static=yes ;; 119980b0ce0bfSmrg no) enable_static=no ;; 119990b0ce0bfSmrg *) 120000b0ce0bfSmrg enable_static=no 120010b0ce0bfSmrg # Look at the argument we got. We use all the common list separators. 120020b0ce0bfSmrg lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, 120030b0ce0bfSmrg for pkg in $enableval; do 120040b0ce0bfSmrg IFS=$lt_save_ifs 120050b0ce0bfSmrg if test "X$pkg" = "X$p"; then 120060b0ce0bfSmrg enable_static=yes 120070b0ce0bfSmrg fi 120080b0ce0bfSmrg done 120090b0ce0bfSmrg IFS=$lt_save_ifs 120100b0ce0bfSmrg ;; 120110b0ce0bfSmrg esac], 120120b0ce0bfSmrg [enable_static=]_LT_ENABLE_STATIC_DEFAULT) 120130b0ce0bfSmrg 120140b0ce0bfSmrg _LT_DECL([build_old_libs], [enable_static], [0], 120150b0ce0bfSmrg [Whether or not to build static libraries]) 120160b0ce0bfSmrg])# _LT_ENABLE_STATIC 120170b0ce0bfSmrg 120180b0ce0bfSmrgLT_OPTION_DEFINE([LT_INIT], [static], [_LT_ENABLE_STATIC([yes])]) 120190b0ce0bfSmrgLT_OPTION_DEFINE([LT_INIT], [disable-static], [_LT_ENABLE_STATIC([no])]) 120200b0ce0bfSmrg 120210b0ce0bfSmrg# Old names: 120220b0ce0bfSmrgAC_DEFUN([AC_ENABLE_STATIC], 120230b0ce0bfSmrg[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[static]) 120240b0ce0bfSmrg]) 12025d31dbc53Smrg 120260b0ce0bfSmrgAC_DEFUN([AC_DISABLE_STATIC], 120270b0ce0bfSmrg[_LT_SET_OPTION([LT_INIT], [disable-static]) 120280b0ce0bfSmrg]) 120295a81ca49Smrg 120300b0ce0bfSmrgAU_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)]) 120310b0ce0bfSmrgAU_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)]) 12032d31dbc53Smrg 120330b0ce0bfSmrgdnl aclocal-1.4 backwards compatibility: 120340b0ce0bfSmrgdnl AC_DEFUN([AM_ENABLE_STATIC], []) 120350b0ce0bfSmrgdnl AC_DEFUN([AM_DISABLE_STATIC], []) 12036e35d4d8eSmrg 12037e35d4d8eSmrg 120380b0ce0bfSmrg 120390b0ce0bfSmrg# _LT_ENABLE_FAST_INSTALL([DEFAULT]) 120405a81ca49Smrg# ---------------------------------- 120410b0ce0bfSmrg# implement the --enable-fast-install flag, and support the 'fast-install' 120420b0ce0bfSmrg# and 'disable-fast-install' LT_INIT options. 120430b0ce0bfSmrg# DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'. 120440b0ce0bfSmrgm4_define([_LT_ENABLE_FAST_INSTALL], 120450b0ce0bfSmrg[m4_define([_LT_ENABLE_FAST_INSTALL_DEFAULT], [m4_if($1, no, no, yes)])dnl 120460b0ce0bfSmrgAC_ARG_ENABLE([fast-install], 120470b0ce0bfSmrg [AS_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@], 120480b0ce0bfSmrg [optimize for fast installation @<:@default=]_LT_ENABLE_FAST_INSTALL_DEFAULT[@:>@])], 120490b0ce0bfSmrg [p=${PACKAGE-default} 120500b0ce0bfSmrg case $enableval in 120510b0ce0bfSmrg yes) enable_fast_install=yes ;; 120520b0ce0bfSmrg no) enable_fast_install=no ;; 120530b0ce0bfSmrg *) 120540b0ce0bfSmrg enable_fast_install=no 120550b0ce0bfSmrg # Look at the argument we got. We use all the common list separators. 120560b0ce0bfSmrg lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, 120570b0ce0bfSmrg for pkg in $enableval; do 120580b0ce0bfSmrg IFS=$lt_save_ifs 120590b0ce0bfSmrg if test "X$pkg" = "X$p"; then 120600b0ce0bfSmrg enable_fast_install=yes 120610b0ce0bfSmrg fi 120620b0ce0bfSmrg done 120630b0ce0bfSmrg IFS=$lt_save_ifs 120640b0ce0bfSmrg ;; 120650b0ce0bfSmrg esac], 120660b0ce0bfSmrg [enable_fast_install=]_LT_ENABLE_FAST_INSTALL_DEFAULT) 12067e35d4d8eSmrg 120680b0ce0bfSmrg_LT_DECL([fast_install], [enable_fast_install], [0], 120690b0ce0bfSmrg [Whether or not to optimize for fast installation])dnl 120700b0ce0bfSmrg])# _LT_ENABLE_FAST_INSTALL 12071e35d4d8eSmrg 120720b0ce0bfSmrgLT_OPTION_DEFINE([LT_INIT], [fast-install], [_LT_ENABLE_FAST_INSTALL([yes])]) 120730b0ce0bfSmrgLT_OPTION_DEFINE([LT_INIT], [disable-fast-install], [_LT_ENABLE_FAST_INSTALL([no])]) 12074e35d4d8eSmrg 120750b0ce0bfSmrg# Old names: 120760b0ce0bfSmrgAU_DEFUN([AC_ENABLE_FAST_INSTALL], 120770b0ce0bfSmrg[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[fast-install]) 120780b0ce0bfSmrgAC_DIAGNOSE([obsolete], 120790b0ce0bfSmrg[$0: Remove this warning and the call to _LT_SET_OPTION when you put 120800b0ce0bfSmrgthe 'fast-install' option into LT_INIT's first parameter.]) 12081e35d4d8eSmrg]) 12082e35d4d8eSmrg 120830b0ce0bfSmrgAU_DEFUN([AC_DISABLE_FAST_INSTALL], 120840b0ce0bfSmrg[_LT_SET_OPTION([LT_INIT], [disable-fast-install]) 120850b0ce0bfSmrgAC_DIAGNOSE([obsolete], 120860b0ce0bfSmrg[$0: Remove this warning and the call to _LT_SET_OPTION when you put 120870b0ce0bfSmrgthe 'disable-fast-install' option into LT_INIT's first parameter.]) 120880b0ce0bfSmrg]) 120895a81ca49Smrg 120900b0ce0bfSmrgdnl aclocal-1.4 backwards compatibility: 120910b0ce0bfSmrgdnl AC_DEFUN([AC_ENABLE_FAST_INSTALL], []) 120920b0ce0bfSmrgdnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], []) 12093e35d4d8eSmrg 12094e35d4d8eSmrg 120950b0ce0bfSmrg# _LT_WITH_AIX_SONAME([DEFAULT]) 120960b0ce0bfSmrg# ---------------------------------- 120970b0ce0bfSmrg# implement the --with-aix-soname flag, and support the `aix-soname=aix' 120980b0ce0bfSmrg# and `aix-soname=both' and `aix-soname=svr4' LT_INIT options. DEFAULT 120990b0ce0bfSmrg# is either `aix', `both' or `svr4'. If omitted, it defaults to `aix'. 121000b0ce0bfSmrgm4_define([_LT_WITH_AIX_SONAME], 121010b0ce0bfSmrg[m4_define([_LT_WITH_AIX_SONAME_DEFAULT], [m4_if($1, svr4, svr4, m4_if($1, both, both, aix))])dnl 121020b0ce0bfSmrgshared_archive_member_spec= 121030b0ce0bfSmrgcase $host,$enable_shared in 121040b0ce0bfSmrgpower*-*-aix[[5-9]]*,yes) 121050b0ce0bfSmrg AC_MSG_CHECKING([which variant of shared library versioning to provide]) 121060b0ce0bfSmrg AC_ARG_WITH([aix-soname], 121070b0ce0bfSmrg [AS_HELP_STRING([--with-aix-soname=aix|svr4|both], 121080b0ce0bfSmrg [shared library versioning (aka "SONAME") variant to provide on AIX, @<:@default=]_LT_WITH_AIX_SONAME_DEFAULT[@:>@.])], 121090b0ce0bfSmrg [case $withval in 121100b0ce0bfSmrg aix|svr4|both) 121110b0ce0bfSmrg ;; 121120b0ce0bfSmrg *) 121130b0ce0bfSmrg AC_MSG_ERROR([Unknown argument to --with-aix-soname]) 121140b0ce0bfSmrg ;; 121150b0ce0bfSmrg esac 121160b0ce0bfSmrg lt_cv_with_aix_soname=$with_aix_soname], 121170b0ce0bfSmrg [AC_CACHE_VAL([lt_cv_with_aix_soname], 121180b0ce0bfSmrg [lt_cv_with_aix_soname=]_LT_WITH_AIX_SONAME_DEFAULT) 121190b0ce0bfSmrg with_aix_soname=$lt_cv_with_aix_soname]) 121200b0ce0bfSmrg AC_MSG_RESULT([$with_aix_soname]) 121210b0ce0bfSmrg if test aix != "$with_aix_soname"; then 121220b0ce0bfSmrg # For the AIX way of multilib, we name the shared archive member 121230b0ce0bfSmrg # based on the bitwidth used, traditionally 'shr.o' or 'shr_64.o', 121240b0ce0bfSmrg # and 'shr.imp' or 'shr_64.imp', respectively, for the Import File. 121250b0ce0bfSmrg # Even when GNU compilers ignore OBJECT_MODE but need '-maix64' flag, 121260b0ce0bfSmrg # the AIX toolchain works better with OBJECT_MODE set (default 32). 121270b0ce0bfSmrg if test 64 = "${OBJECT_MODE-32}"; then 121280b0ce0bfSmrg shared_archive_member_spec=shr_64 121290b0ce0bfSmrg else 121300b0ce0bfSmrg shared_archive_member_spec=shr 121310b0ce0bfSmrg fi 121320b0ce0bfSmrg fi 121330b0ce0bfSmrg ;; 121340b0ce0bfSmrg*) 121350b0ce0bfSmrg with_aix_soname=aix 121360b0ce0bfSmrg ;; 121370b0ce0bfSmrgesac 121382a51b5beSmrg 121390b0ce0bfSmrg_LT_DECL([], [shared_archive_member_spec], [0], 121400b0ce0bfSmrg [Shared archive member basename, for filename based shared library versioning on AIX])dnl 121410b0ce0bfSmrg])# _LT_WITH_AIX_SONAME 12142e35d4d8eSmrg 121430b0ce0bfSmrgLT_OPTION_DEFINE([LT_INIT], [aix-soname=aix], [_LT_WITH_AIX_SONAME([aix])]) 121440b0ce0bfSmrgLT_OPTION_DEFINE([LT_INIT], [aix-soname=both], [_LT_WITH_AIX_SONAME([both])]) 121450b0ce0bfSmrgLT_OPTION_DEFINE([LT_INIT], [aix-soname=svr4], [_LT_WITH_AIX_SONAME([svr4])]) 121461b12faf6Smrg 12147e35d4d8eSmrg 121480b0ce0bfSmrg# _LT_WITH_PIC([MODE]) 121495a81ca49Smrg# -------------------- 121500b0ce0bfSmrg# implement the --with-pic flag, and support the 'pic-only' and 'no-pic' 121510b0ce0bfSmrg# LT_INIT options. 121520b0ce0bfSmrg# MODE is either 'yes' or 'no'. If omitted, it defaults to 'both'. 121530b0ce0bfSmrgm4_define([_LT_WITH_PIC], 121540b0ce0bfSmrg[AC_ARG_WITH([pic], 121550b0ce0bfSmrg [AS_HELP_STRING([--with-pic@<:@=PKGS@:>@], 121560b0ce0bfSmrg [try to use only PIC/non-PIC objects @<:@default=use both@:>@])], 121570b0ce0bfSmrg [lt_p=${PACKAGE-default} 121580b0ce0bfSmrg case $withval in 121590b0ce0bfSmrg yes|no) pic_mode=$withval ;; 121600b0ce0bfSmrg *) 121610b0ce0bfSmrg pic_mode=default 121620b0ce0bfSmrg # Look at the argument we got. We use all the common list separators. 121630b0ce0bfSmrg lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, 121640b0ce0bfSmrg for lt_pkg in $withval; do 121650b0ce0bfSmrg IFS=$lt_save_ifs 121660b0ce0bfSmrg if test "X$lt_pkg" = "X$lt_p"; then 121670b0ce0bfSmrg pic_mode=yes 121680b0ce0bfSmrg fi 121690b0ce0bfSmrg done 121700b0ce0bfSmrg IFS=$lt_save_ifs 121710b0ce0bfSmrg ;; 121720b0ce0bfSmrg esac], 121730b0ce0bfSmrg [pic_mode=m4_default([$1], [default])]) 12174e35d4d8eSmrg 121750b0ce0bfSmrg_LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl 121760b0ce0bfSmrg])# _LT_WITH_PIC 12177e35d4d8eSmrg 121780b0ce0bfSmrgLT_OPTION_DEFINE([LT_INIT], [pic-only], [_LT_WITH_PIC([yes])]) 121790b0ce0bfSmrgLT_OPTION_DEFINE([LT_INIT], [no-pic], [_LT_WITH_PIC([no])]) 121801b12faf6Smrg 121810b0ce0bfSmrg# Old name: 121820b0ce0bfSmrgAU_DEFUN([AC_LIBTOOL_PICMODE], 121830b0ce0bfSmrg[_LT_SET_OPTION([LT_INIT], [pic-only]) 121840b0ce0bfSmrgAC_DIAGNOSE([obsolete], 121850b0ce0bfSmrg[$0: Remove this warning and the call to _LT_SET_OPTION when you 121860b0ce0bfSmrgput the 'pic-only' option into LT_INIT's first parameter.]) 121870b0ce0bfSmrg]) 1218832b578d3Smrg 121890b0ce0bfSmrgdnl aclocal-1.4 backwards compatibility: 121900b0ce0bfSmrgdnl AC_DEFUN([AC_LIBTOOL_PICMODE], []) 1219132b578d3Smrg 121925a81ca49Smrg 121930b0ce0bfSmrgm4_define([_LTDL_MODE], []) 121940b0ce0bfSmrgLT_OPTION_DEFINE([LTDL_INIT], [nonrecursive], 121950b0ce0bfSmrg [m4_define([_LTDL_MODE], [nonrecursive])]) 121960b0ce0bfSmrgLT_OPTION_DEFINE([LTDL_INIT], [recursive], 121970b0ce0bfSmrg [m4_define([_LTDL_MODE], [recursive])]) 121980b0ce0bfSmrgLT_OPTION_DEFINE([LTDL_INIT], [subproject], 121990b0ce0bfSmrg [m4_define([_LTDL_MODE], [subproject])]) 122000b0ce0bfSmrg 122010b0ce0bfSmrgm4_define([_LTDL_TYPE], []) 122020b0ce0bfSmrgLT_OPTION_DEFINE([LTDL_INIT], [installable], 122030b0ce0bfSmrg [m4_define([_LTDL_TYPE], [installable])]) 122040b0ce0bfSmrgLT_OPTION_DEFINE([LTDL_INIT], [convenience], 122050b0ce0bfSmrg [m4_define([_LTDL_TYPE], [convenience])]) 122060b0ce0bfSmrg 122070b0ce0bfSmrg# ltsugar.m4 -- libtool m4 base layer. -*-Autoconf-*- 12208d31dbc53Smrg# 122090b0ce0bfSmrg# Copyright (C) 2004-2005, 2007-2008, 2011-2019, 2021-2022 Free Software 122100b0ce0bfSmrg# Foundation, Inc. 122110b0ce0bfSmrg# Written by Gary V. Vaughan, 2004 122120b0ce0bfSmrg# 122130b0ce0bfSmrg# This file is free software; the Free Software Foundation gives 122140b0ce0bfSmrg# unlimited permission to copy and/or distribute it, with or without 122150b0ce0bfSmrg# modifications, as long as this notice is preserved. 122165a81ca49Smrg 122170b0ce0bfSmrg# serial 6 ltsugar.m4 122185a81ca49Smrg 122190b0ce0bfSmrg# This is to help aclocal find these macros, as it can't see m4_define. 122200b0ce0bfSmrgAC_DEFUN([LTSUGAR_VERSION], [m4_if([0.1])]) 122215a81ca49Smrg 1222232b578d3Smrg 122230b0ce0bfSmrg# lt_join(SEP, ARG1, [ARG2...]) 122240b0ce0bfSmrg# ----------------------------- 122250b0ce0bfSmrg# Produce ARG1SEPARG2...SEPARGn, omitting [] arguments and their 122260b0ce0bfSmrg# associated separator. 122270b0ce0bfSmrg# Needed until we can rely on m4_join from Autoconf 2.62, since all earlier 122280b0ce0bfSmrg# versions in m4sugar had bugs. 122290b0ce0bfSmrgm4_define([lt_join], 122300b0ce0bfSmrg[m4_if([$#], [1], [], 122310b0ce0bfSmrg [$#], [2], [[$2]], 122320b0ce0bfSmrg [m4_if([$2], [], [], [[$2]_])$0([$1], m4_shift(m4_shift($@)))])]) 122330b0ce0bfSmrgm4_define([_lt_join], 122340b0ce0bfSmrg[m4_if([$#$2], [2], [], 122350b0ce0bfSmrg [m4_if([$2], [], [], [[$1$2]])$0([$1], m4_shift(m4_shift($@)))])]) 122365a81ca49Smrg 122375a81ca49Smrg 122380b0ce0bfSmrg# lt_car(LIST) 122390b0ce0bfSmrg# lt_cdr(LIST) 122400b0ce0bfSmrg# ------------ 122410b0ce0bfSmrg# Manipulate m4 lists. 122420b0ce0bfSmrg# These macros are necessary as long as will still need to support 122430b0ce0bfSmrg# Autoconf-2.59, which quotes differently. 122440b0ce0bfSmrgm4_define([lt_car], [[$1]]) 122450b0ce0bfSmrgm4_define([lt_cdr], 122460b0ce0bfSmrg[m4_if([$#], 0, [m4_fatal([$0: cannot be called without arguments])], 122470b0ce0bfSmrg [$#], 1, [], 122480b0ce0bfSmrg [m4_dquote(m4_shift($@))])]) 122490b0ce0bfSmrgm4_define([lt_unquote], $1) 122500b0ce0bfSmrg 1225132b578d3Smrg 122520b0ce0bfSmrg# lt_append(MACRO-NAME, STRING, [SEPARATOR]) 122530b0ce0bfSmrg# ------------------------------------------ 122540b0ce0bfSmrg# Redefine MACRO-NAME to hold its former content plus 'SEPARATOR''STRING'. 122550b0ce0bfSmrg# Note that neither SEPARATOR nor STRING are expanded; they are appended 122560b0ce0bfSmrg# to MACRO-NAME as is (leaving the expansion for when MACRO-NAME is invoked). 122570b0ce0bfSmrg# No SEPARATOR is output if MACRO-NAME was previously undefined (different 122580b0ce0bfSmrg# than defined and empty). 122595a81ca49Smrg# 122600b0ce0bfSmrg# This macro is needed until we can rely on Autoconf 2.62, since earlier 122610b0ce0bfSmrg# versions of m4sugar mistakenly expanded SEPARATOR but not STRING. 122620b0ce0bfSmrgm4_define([lt_append], 122630b0ce0bfSmrg[m4_define([$1], 122640b0ce0bfSmrg m4_ifdef([$1], [m4_defn([$1])[$3]])[$2])]) 1226532b578d3Smrg 122662a51b5beSmrg 122672a51b5beSmrg 122680b0ce0bfSmrg# lt_combine(SEP, PREFIX-LIST, INFIX, SUFFIX1, [SUFFIX2...]) 122690b0ce0bfSmrg# ---------------------------------------------------------- 122700b0ce0bfSmrg# Produce a SEP delimited list of all paired combinations of elements of 122710b0ce0bfSmrg# PREFIX-LIST with SUFFIX1 through SUFFIXn. Each element of the list 122720b0ce0bfSmrg# has the form PREFIXmINFIXSUFFIXn. 122730b0ce0bfSmrg# Needed until we can rely on m4_combine added in Autoconf 2.62. 122740b0ce0bfSmrgm4_define([lt_combine], 122750b0ce0bfSmrg[m4_if(m4_eval([$# > 3]), [1], 122760b0ce0bfSmrg [m4_pushdef([_Lt_sep], [m4_define([_Lt_sep], m4_defn([lt_car]))])]]dnl 122770b0ce0bfSmrg[[m4_foreach([_Lt_prefix], [$2], 122780b0ce0bfSmrg [m4_foreach([_Lt_suffix], 122790b0ce0bfSmrg ]m4_dquote(m4_dquote(m4_shift(m4_shift(m4_shift($@)))))[, 122800b0ce0bfSmrg [_Lt_sep([$1])[]m4_defn([_Lt_prefix])[$3]m4_defn([_Lt_suffix])])])])]) 12281e35d4d8eSmrg 122822a51b5beSmrg 122830b0ce0bfSmrg# lt_if_append_uniq(MACRO-NAME, VARNAME, [SEPARATOR], [UNIQ], [NOT-UNIQ]) 122840b0ce0bfSmrg# ----------------------------------------------------------------------- 122850b0ce0bfSmrg# Iff MACRO-NAME does not yet contain VARNAME, then append it (delimited 122860b0ce0bfSmrg# by SEPARATOR if supplied) and expand UNIQ, else NOT-UNIQ. 122870b0ce0bfSmrgm4_define([lt_if_append_uniq], 122880b0ce0bfSmrg[m4_ifdef([$1], 122890b0ce0bfSmrg [m4_if(m4_index([$3]m4_defn([$1])[$3], [$3$2$3]), [-1], 122900b0ce0bfSmrg [lt_append([$1], [$2], [$3])$4], 122910b0ce0bfSmrg [$5])], 122920b0ce0bfSmrg [lt_append([$1], [$2], [$3])$4])]) 122930b0ce0bfSmrg 122940b0ce0bfSmrg 122950b0ce0bfSmrg# lt_dict_add(DICT, KEY, VALUE) 122960b0ce0bfSmrg# ----------------------------- 122970b0ce0bfSmrgm4_define([lt_dict_add], 122980b0ce0bfSmrg[m4_define([$1($2)], [$3])]) 122990b0ce0bfSmrg 123005a81ca49Smrg 123010b0ce0bfSmrg# lt_dict_add_subkey(DICT, KEY, SUBKEY, VALUE) 123020b0ce0bfSmrg# -------------------------------------------- 123030b0ce0bfSmrgm4_define([lt_dict_add_subkey], 123040b0ce0bfSmrg[m4_define([$1($2:$3)], [$4])]) 123055a81ca49Smrg 123065a81ca49Smrg 123070b0ce0bfSmrg# lt_dict_fetch(DICT, KEY, [SUBKEY]) 123080b0ce0bfSmrg# ---------------------------------- 123090b0ce0bfSmrgm4_define([lt_dict_fetch], 123100b0ce0bfSmrg[m4_ifval([$3], 123110b0ce0bfSmrg m4_ifdef([$1($2:$3)], [m4_defn([$1($2:$3)])]), 123120b0ce0bfSmrg m4_ifdef([$1($2)], [m4_defn([$1($2)])]))]) 123132a51b5beSmrg 1231432b578d3Smrg 123150b0ce0bfSmrg# lt_if_dict_fetch(DICT, KEY, [SUBKEY], VALUE, IF-TRUE, [IF-FALSE]) 123160b0ce0bfSmrg# ----------------------------------------------------------------- 123170b0ce0bfSmrgm4_define([lt_if_dict_fetch], 123180b0ce0bfSmrg[m4_if(lt_dict_fetch([$1], [$2], [$3]), [$4], 123190b0ce0bfSmrg [$5], 123200b0ce0bfSmrg [$6])]) 1232132b578d3Smrg 123225a81ca49Smrg 123230b0ce0bfSmrg# lt_dict_filter(DICT, [SUBKEY], VALUE, [SEPARATOR], KEY, [...]) 123240b0ce0bfSmrg# -------------------------------------------------------------- 123250b0ce0bfSmrgm4_define([lt_dict_filter], 123260b0ce0bfSmrg[m4_if([$5], [], [], 123270b0ce0bfSmrg [lt_join(m4_quote(m4_default([$4], [[, ]])), 123280b0ce0bfSmrg lt_unquote(m4_split(m4_normalize(m4_foreach(_Lt_key, lt_car([m4_shiftn(4, $@)]), 123290b0ce0bfSmrg [lt_if_dict_fetch([$1], _Lt_key, [$2], [$3], [_Lt_key ])])))))])[]dnl 123300b0ce0bfSmrg]) 1233132b578d3Smrg 123320b0ce0bfSmrg# ltversion.m4 -- version numbers -*- Autoconf -*- 123330b0ce0bfSmrg# 123340b0ce0bfSmrg# Copyright (C) 2004, 2011-2019, 2021-2022 Free Software Foundation, 123350b0ce0bfSmrg# Inc. 123360b0ce0bfSmrg# Written by Scott James Remnant, 2004 123370b0ce0bfSmrg# 123380b0ce0bfSmrg# This file is free software; the Free Software Foundation gives 123390b0ce0bfSmrg# unlimited permission to copy and/or distribute it, with or without 123400b0ce0bfSmrg# modifications, as long as this notice is preserved. 123415a81ca49Smrg 123420b0ce0bfSmrg# @configure_input@ 123435a81ca49Smrg 123440b0ce0bfSmrg# serial 4245 ltversion.m4 123450b0ce0bfSmrg# This file is part of GNU Libtool 123465a81ca49Smrg 123470b0ce0bfSmrgm4_define([LT_PACKAGE_VERSION], [2.4.7]) 123480b0ce0bfSmrgm4_define([LT_PACKAGE_REVISION], [2.4.7]) 123495a81ca49Smrg 123500b0ce0bfSmrgAC_DEFUN([LTVERSION_VERSION], 123510b0ce0bfSmrg[macro_version='2.4.7' 123520b0ce0bfSmrgmacro_revision='2.4.7' 123530b0ce0bfSmrg_LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?]) 123540b0ce0bfSmrg_LT_DECL(, macro_revision, 0) 123550b0ce0bfSmrg]) 123565a81ca49Smrg 123570b0ce0bfSmrg# lt~obsolete.m4 -- aclocal satisfying obsolete definitions. -*-Autoconf-*- 123580b0ce0bfSmrg# 123590b0ce0bfSmrg# Copyright (C) 2004-2005, 2007, 2009, 2011-2019, 2021-2022 Free 123600b0ce0bfSmrg# Software Foundation, Inc. 123610b0ce0bfSmrg# Written by Scott James Remnant, 2004. 123620b0ce0bfSmrg# 123630b0ce0bfSmrg# This file is free software; the Free Software Foundation gives 123640b0ce0bfSmrg# unlimited permission to copy and/or distribute it, with or without 123650b0ce0bfSmrg# modifications, as long as this notice is preserved. 123665a81ca49Smrg 123670b0ce0bfSmrg# serial 5 lt~obsolete.m4 123685a81ca49Smrg 123690b0ce0bfSmrg# These exist entirely to fool aclocal when bootstrapping libtool. 123700b0ce0bfSmrg# 123710b0ce0bfSmrg# In the past libtool.m4 has provided macros via AC_DEFUN (or AU_DEFUN), 123720b0ce0bfSmrg# which have later been changed to m4_define as they aren't part of the 123730b0ce0bfSmrg# exported API, or moved to Autoconf or Automake where they belong. 123740b0ce0bfSmrg# 123750b0ce0bfSmrg# The trouble is, aclocal is a bit thick. It'll see the old AC_DEFUN 123760b0ce0bfSmrg# in /usr/share/aclocal/libtool.m4 and remember it, then when it sees us 123770b0ce0bfSmrg# using a macro with the same name in our local m4/libtool.m4 it'll 123780b0ce0bfSmrg# pull the old libtool.m4 in (it doesn't see our shiny new m4_define 123790b0ce0bfSmrg# and doesn't know about Autoconf macros at all.) 123800b0ce0bfSmrg# 123810b0ce0bfSmrg# So we provide this file, which has a silly filename so it's always 123820b0ce0bfSmrg# included after everything else. This provides aclocal with the 123830b0ce0bfSmrg# AC_DEFUNs it wants, but when m4 processes it, it doesn't do anything 123840b0ce0bfSmrg# because those macros already exist, or will be overwritten later. 123850b0ce0bfSmrg# We use AC_DEFUN over AU_DEFUN for compatibility with aclocal-1.6. 123860b0ce0bfSmrg# 123870b0ce0bfSmrg# Anytime we withdraw an AC_DEFUN or AU_DEFUN, remember to add it here. 123880b0ce0bfSmrg# Yes, that means every name once taken will need to remain here until 123890b0ce0bfSmrg# we give up compatibility with versions before 1.7, at which point 123900b0ce0bfSmrg# we need to keep only those names which we still refer to. 123915a81ca49Smrg 123920b0ce0bfSmrg# This is to help aclocal find these macros, as it can't see m4_define. 123930b0ce0bfSmrgAC_DEFUN([LTOBSOLETE_VERSION], [m4_if([1])]) 123940b0ce0bfSmrg 123950b0ce0bfSmrgm4_ifndef([AC_LIBTOOL_LINKER_OPTION], [AC_DEFUN([AC_LIBTOOL_LINKER_OPTION])]) 123960b0ce0bfSmrgm4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP])]) 123970b0ce0bfSmrgm4_ifndef([_LT_AC_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH])]) 123980b0ce0bfSmrgm4_ifndef([_LT_AC_SHELL_INIT], [AC_DEFUN([_LT_AC_SHELL_INIT])]) 123990b0ce0bfSmrgm4_ifndef([_LT_AC_SYS_LIBPATH_AIX], [AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX])]) 124000b0ce0bfSmrgm4_ifndef([_LT_PROG_LTMAIN], [AC_DEFUN([_LT_PROG_LTMAIN])]) 124010b0ce0bfSmrgm4_ifndef([_LT_AC_TAGVAR], [AC_DEFUN([_LT_AC_TAGVAR])]) 124020b0ce0bfSmrgm4_ifndef([AC_LTDL_ENABLE_INSTALL], [AC_DEFUN([AC_LTDL_ENABLE_INSTALL])]) 124030b0ce0bfSmrgm4_ifndef([AC_LTDL_PREOPEN], [AC_DEFUN([AC_LTDL_PREOPEN])]) 124040b0ce0bfSmrgm4_ifndef([_LT_AC_SYS_COMPILER], [AC_DEFUN([_LT_AC_SYS_COMPILER])]) 124050b0ce0bfSmrgm4_ifndef([_LT_AC_LOCK], [AC_DEFUN([_LT_AC_LOCK])]) 124060b0ce0bfSmrgm4_ifndef([AC_LIBTOOL_SYS_OLD_ARCHIVE], [AC_DEFUN([AC_LIBTOOL_SYS_OLD_ARCHIVE])]) 124070b0ce0bfSmrgm4_ifndef([_LT_AC_TRY_DLOPEN_SELF], [AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF])]) 124080b0ce0bfSmrgm4_ifndef([AC_LIBTOOL_PROG_CC_C_O], [AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O])]) 124090b0ce0bfSmrgm4_ifndef([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], [AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS])]) 124100b0ce0bfSmrgm4_ifndef([AC_LIBTOOL_OBJDIR], [AC_DEFUN([AC_LIBTOOL_OBJDIR])]) 124110b0ce0bfSmrgm4_ifndef([AC_LTDL_OBJDIR], [AC_DEFUN([AC_LTDL_OBJDIR])]) 124120b0ce0bfSmrgm4_ifndef([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], [AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH])]) 124130b0ce0bfSmrgm4_ifndef([AC_LIBTOOL_SYS_LIB_STRIP], [AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP])]) 124140b0ce0bfSmrgm4_ifndef([AC_PATH_MAGIC], [AC_DEFUN([AC_PATH_MAGIC])]) 124150b0ce0bfSmrgm4_ifndef([AC_PROG_LD_GNU], [AC_DEFUN([AC_PROG_LD_GNU])]) 124160b0ce0bfSmrgm4_ifndef([AC_PROG_LD_RELOAD_FLAG], [AC_DEFUN([AC_PROG_LD_RELOAD_FLAG])]) 124170b0ce0bfSmrgm4_ifndef([AC_DEPLIBS_CHECK_METHOD], [AC_DEFUN([AC_DEPLIBS_CHECK_METHOD])]) 124180b0ce0bfSmrgm4_ifndef([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI])]) 124190b0ce0bfSmrgm4_ifndef([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], [AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE])]) 124200b0ce0bfSmrgm4_ifndef([AC_LIBTOOL_PROG_COMPILER_PIC], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC])]) 124210b0ce0bfSmrgm4_ifndef([AC_LIBTOOL_PROG_LD_SHLIBS], [AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS])]) 124220b0ce0bfSmrgm4_ifndef([AC_LIBTOOL_POSTDEP_PREDEP], [AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP])]) 124230b0ce0bfSmrgm4_ifndef([LT_AC_PROG_EGREP], [AC_DEFUN([LT_AC_PROG_EGREP])]) 124240b0ce0bfSmrgm4_ifndef([LT_AC_PROG_SED], [AC_DEFUN([LT_AC_PROG_SED])]) 124250b0ce0bfSmrgm4_ifndef([_LT_CC_BASENAME], [AC_DEFUN([_LT_CC_BASENAME])]) 124260b0ce0bfSmrgm4_ifndef([_LT_COMPILER_BOILERPLATE], [AC_DEFUN([_LT_COMPILER_BOILERPLATE])]) 124270b0ce0bfSmrgm4_ifndef([_LT_LINKER_BOILERPLATE], [AC_DEFUN([_LT_LINKER_BOILERPLATE])]) 124280b0ce0bfSmrgm4_ifndef([_AC_PROG_LIBTOOL], [AC_DEFUN([_AC_PROG_LIBTOOL])]) 124290b0ce0bfSmrgm4_ifndef([AC_LIBTOOL_SETUP], [AC_DEFUN([AC_LIBTOOL_SETUP])]) 124300b0ce0bfSmrgm4_ifndef([_LT_AC_CHECK_DLFCN], [AC_DEFUN([_LT_AC_CHECK_DLFCN])]) 124310b0ce0bfSmrgm4_ifndef([AC_LIBTOOL_SYS_DYNAMIC_LINKER], [AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER])]) 124320b0ce0bfSmrgm4_ifndef([_LT_AC_TAGCONFIG], [AC_DEFUN([_LT_AC_TAGCONFIG])]) 124330b0ce0bfSmrgm4_ifndef([AC_DISABLE_FAST_INSTALL], [AC_DEFUN([AC_DISABLE_FAST_INSTALL])]) 124340b0ce0bfSmrgm4_ifndef([_LT_AC_LANG_CXX], [AC_DEFUN([_LT_AC_LANG_CXX])]) 124350b0ce0bfSmrgm4_ifndef([_LT_AC_LANG_F77], [AC_DEFUN([_LT_AC_LANG_F77])]) 124360b0ce0bfSmrgm4_ifndef([_LT_AC_LANG_GCJ], [AC_DEFUN([_LT_AC_LANG_GCJ])]) 124370b0ce0bfSmrgm4_ifndef([AC_LIBTOOL_LANG_C_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG])]) 124380b0ce0bfSmrgm4_ifndef([_LT_AC_LANG_C_CONFIG], [AC_DEFUN([_LT_AC_LANG_C_CONFIG])]) 124390b0ce0bfSmrgm4_ifndef([AC_LIBTOOL_LANG_CXX_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG])]) 124400b0ce0bfSmrgm4_ifndef([_LT_AC_LANG_CXX_CONFIG], [AC_DEFUN([_LT_AC_LANG_CXX_CONFIG])]) 124410b0ce0bfSmrgm4_ifndef([AC_LIBTOOL_LANG_F77_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG])]) 124420b0ce0bfSmrgm4_ifndef([_LT_AC_LANG_F77_CONFIG], [AC_DEFUN([_LT_AC_LANG_F77_CONFIG])]) 124430b0ce0bfSmrgm4_ifndef([AC_LIBTOOL_LANG_GCJ_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG])]) 124440b0ce0bfSmrgm4_ifndef([_LT_AC_LANG_GCJ_CONFIG], [AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG])]) 124450b0ce0bfSmrgm4_ifndef([AC_LIBTOOL_LANG_RC_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG])]) 124460b0ce0bfSmrgm4_ifndef([_LT_AC_LANG_RC_CONFIG], [AC_DEFUN([_LT_AC_LANG_RC_CONFIG])]) 124470b0ce0bfSmrgm4_ifndef([AC_LIBTOOL_CONFIG], [AC_DEFUN([AC_LIBTOOL_CONFIG])]) 124480b0ce0bfSmrgm4_ifndef([_LT_AC_FILE_LTDLL_C], [AC_DEFUN([_LT_AC_FILE_LTDLL_C])]) 124490b0ce0bfSmrgm4_ifndef([_LT_REQUIRED_DARWIN_CHECKS], [AC_DEFUN([_LT_REQUIRED_DARWIN_CHECKS])]) 124500b0ce0bfSmrgm4_ifndef([_LT_AC_PROG_CXXCPP], [AC_DEFUN([_LT_AC_PROG_CXXCPP])]) 124510b0ce0bfSmrgm4_ifndef([_LT_PREPARE_SED_QUOTE_VARS], [AC_DEFUN([_LT_PREPARE_SED_QUOTE_VARS])]) 124520b0ce0bfSmrgm4_ifndef([_LT_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_PROG_ECHO_BACKSLASH])]) 124530b0ce0bfSmrgm4_ifndef([_LT_PROG_F77], [AC_DEFUN([_LT_PROG_F77])]) 124540b0ce0bfSmrgm4_ifndef([_LT_PROG_FC], [AC_DEFUN([_LT_PROG_FC])]) 124550b0ce0bfSmrgm4_ifndef([_LT_PROG_CXX], [AC_DEFUN([_LT_PROG_CXX])]) 1245632b578d3Smrg 12457