aclocal.m4 revision 578741aa
1578741aaSmrg# generated automatically by aclocal 1.11 -*- Autoconf -*- 2145b7b3cSmrg 3145b7b3cSmrg# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 4578741aaSmrg# 2005, 2006, 2007, 2008, 2009 Free Software Foundation, Inc. 5145b7b3cSmrg# This file is free software; the Free Software Foundation 6145b7b3cSmrg# gives unlimited permission to copy and/or distribute it, 7145b7b3cSmrg# with or without modifications, as long as this notice is preserved. 8145b7b3cSmrg 9145b7b3cSmrg# This program is distributed in the hope that it will be useful, 10145b7b3cSmrg# but WITHOUT ANY WARRANTY, to the extent permitted by law; without 11145b7b3cSmrg# even the implied warranty of MERCHANTABILITY or FITNESS FOR A 12145b7b3cSmrg# PARTICULAR PURPOSE. 13145b7b3cSmrg 14578741aaSmrgm4_ifndef([AC_AUTOCONF_VERSION], 15578741aaSmrg [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl 16578741aaSmrgm4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.63],, 17578741aaSmrg[m4_warning([this file was generated for autoconf 2.63. 18578741aaSmrgYou have another version of autoconf. It may work, but is not guaranteed to. 19578741aaSmrgIf you have problems, you may need to regenerate the build system entirely. 20578741aaSmrgTo do so, use the procedure documented by the package, typically `autoreconf'.])]) 21145b7b3cSmrg 22578741aaSmrg# Copyright (C) 2002, 2003, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. 23145b7b3cSmrg# 24145b7b3cSmrg# This file is free software; the Free Software Foundation 25145b7b3cSmrg# gives unlimited permission to copy and/or distribute it, 26145b7b3cSmrg# with or without modifications, as long as this notice is preserved. 27145b7b3cSmrg 28145b7b3cSmrg# AM_AUTOMAKE_VERSION(VERSION) 29145b7b3cSmrg# ---------------------------- 30145b7b3cSmrg# Automake X.Y traces this macro to ensure aclocal.m4 has been 31145b7b3cSmrg# generated from the m4 files accompanying Automake X.Y. 32145b7b3cSmrg# (This private macro should not be called outside this file.) 33145b7b3cSmrgAC_DEFUN([AM_AUTOMAKE_VERSION], 34578741aaSmrg[am__api_version='1.11' 35145b7b3cSmrgdnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to 36145b7b3cSmrgdnl require some minimum version. Point them to the right macro. 37578741aaSmrgm4_if([$1], [1.11], [], 38145b7b3cSmrg [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl 39145b7b3cSmrg]) 40145b7b3cSmrg 41145b7b3cSmrg# _AM_AUTOCONF_VERSION(VERSION) 42145b7b3cSmrg# ----------------------------- 43145b7b3cSmrg# aclocal traces this macro to find the Autoconf version. 44145b7b3cSmrg# This is a private macro too. Using m4_define simplifies 45145b7b3cSmrg# the logic in aclocal, which can simply ignore this definition. 46145b7b3cSmrgm4_define([_AM_AUTOCONF_VERSION], []) 47145b7b3cSmrg 48145b7b3cSmrg# AM_SET_CURRENT_AUTOMAKE_VERSION 49145b7b3cSmrg# ------------------------------- 50145b7b3cSmrg# Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced. 51578741aaSmrg# This function is AC_REQUIREd by AM_INIT_AUTOMAKE. 52145b7b3cSmrgAC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION], 53578741aaSmrg[AM_AUTOMAKE_VERSION([1.11])dnl 54578741aaSmrgm4_ifndef([AC_AUTOCONF_VERSION], 55578741aaSmrg [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl 56578741aaSmrg_AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))]) 57145b7b3cSmrg 58145b7b3cSmrg# AM_AUX_DIR_EXPAND -*- Autoconf -*- 59145b7b3cSmrg 60145b7b3cSmrg# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. 61145b7b3cSmrg# 62145b7b3cSmrg# This file is free software; the Free Software Foundation 63145b7b3cSmrg# gives unlimited permission to copy and/or distribute it, 64145b7b3cSmrg# with or without modifications, as long as this notice is preserved. 65145b7b3cSmrg 66145b7b3cSmrg# For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets 67145b7b3cSmrg# $ac_aux_dir to `$srcdir/foo'. In other projects, it is set to 68145b7b3cSmrg# `$srcdir', `$srcdir/..', or `$srcdir/../..'. 69145b7b3cSmrg# 70145b7b3cSmrg# Of course, Automake must honor this variable whenever it calls a 71145b7b3cSmrg# tool from the auxiliary directory. The problem is that $srcdir (and 72145b7b3cSmrg# therefore $ac_aux_dir as well) can be either absolute or relative, 73145b7b3cSmrg# depending on how configure is run. This is pretty annoying, since 74145b7b3cSmrg# it makes $ac_aux_dir quite unusable in subdirectories: in the top 75145b7b3cSmrg# source directory, any form will work fine, but in subdirectories a 76145b7b3cSmrg# relative path needs to be adjusted first. 77145b7b3cSmrg# 78145b7b3cSmrg# $ac_aux_dir/missing 79145b7b3cSmrg# fails when called from a subdirectory if $ac_aux_dir is relative 80145b7b3cSmrg# $top_srcdir/$ac_aux_dir/missing 81145b7b3cSmrg# fails if $ac_aux_dir is absolute, 82145b7b3cSmrg# fails when called from a subdirectory in a VPATH build with 83145b7b3cSmrg# a relative $ac_aux_dir 84145b7b3cSmrg# 85145b7b3cSmrg# The reason of the latter failure is that $top_srcdir and $ac_aux_dir 86145b7b3cSmrg# are both prefixed by $srcdir. In an in-source build this is usually 87145b7b3cSmrg# harmless because $srcdir is `.', but things will broke when you 88145b7b3cSmrg# start a VPATH build or use an absolute $srcdir. 89145b7b3cSmrg# 90145b7b3cSmrg# So we could use something similar to $top_srcdir/$ac_aux_dir/missing, 91145b7b3cSmrg# iff we strip the leading $srcdir from $ac_aux_dir. That would be: 92145b7b3cSmrg# am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"` 93145b7b3cSmrg# and then we would define $MISSING as 94145b7b3cSmrg# MISSING="\${SHELL} $am_aux_dir/missing" 95145b7b3cSmrg# This will work as long as MISSING is not called from configure, because 96145b7b3cSmrg# unfortunately $(top_srcdir) has no meaning in configure. 97145b7b3cSmrg# However there are other variables, like CC, which are often used in 98145b7b3cSmrg# configure, and could therefore not use this "fixed" $ac_aux_dir. 99145b7b3cSmrg# 100145b7b3cSmrg# Another solution, used here, is to always expand $ac_aux_dir to an 101145b7b3cSmrg# absolute PATH. The drawback is that using absolute paths prevent a 102145b7b3cSmrg# configured tree to be moved without reconfiguration. 103145b7b3cSmrg 104145b7b3cSmrgAC_DEFUN([AM_AUX_DIR_EXPAND], 105145b7b3cSmrg[dnl Rely on autoconf to set up CDPATH properly. 106145b7b3cSmrgAC_PREREQ([2.50])dnl 107145b7b3cSmrg# expand $ac_aux_dir to an absolute path 108145b7b3cSmrgam_aux_dir=`cd $ac_aux_dir && pwd` 109145b7b3cSmrg]) 110145b7b3cSmrg 111145b7b3cSmrg# AM_CONDITIONAL -*- Autoconf -*- 112145b7b3cSmrg 113578741aaSmrg# Copyright (C) 1997, 2000, 2001, 2003, 2004, 2005, 2006, 2008 114145b7b3cSmrg# Free Software Foundation, Inc. 115145b7b3cSmrg# 116145b7b3cSmrg# This file is free software; the Free Software Foundation 117145b7b3cSmrg# gives unlimited permission to copy and/or distribute it, 118145b7b3cSmrg# with or without modifications, as long as this notice is preserved. 119145b7b3cSmrg 120578741aaSmrg# serial 9 121145b7b3cSmrg 122145b7b3cSmrg# AM_CONDITIONAL(NAME, SHELL-CONDITION) 123145b7b3cSmrg# ------------------------------------- 124145b7b3cSmrg# Define a conditional. 125145b7b3cSmrgAC_DEFUN([AM_CONDITIONAL], 126145b7b3cSmrg[AC_PREREQ(2.52)dnl 127145b7b3cSmrg ifelse([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])], 128145b7b3cSmrg [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl 129145b7b3cSmrgAC_SUBST([$1_TRUE])dnl 130145b7b3cSmrgAC_SUBST([$1_FALSE])dnl 131145b7b3cSmrg_AM_SUBST_NOTMAKE([$1_TRUE])dnl 132145b7b3cSmrg_AM_SUBST_NOTMAKE([$1_FALSE])dnl 133578741aaSmrgm4_define([_AM_COND_VALUE_$1], [$2])dnl 134145b7b3cSmrgif $2; then 135145b7b3cSmrg $1_TRUE= 136145b7b3cSmrg $1_FALSE='#' 137145b7b3cSmrgelse 138145b7b3cSmrg $1_TRUE='#' 139145b7b3cSmrg $1_FALSE= 140145b7b3cSmrgfi 141145b7b3cSmrgAC_CONFIG_COMMANDS_PRE( 142145b7b3cSmrg[if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then 143145b7b3cSmrg AC_MSG_ERROR([[conditional "$1" was never defined. 144145b7b3cSmrgUsually this means the macro was only invoked conditionally.]]) 145145b7b3cSmrgfi])]) 146145b7b3cSmrg 147578741aaSmrg# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2009 148145b7b3cSmrg# Free Software Foundation, Inc. 149145b7b3cSmrg# 150145b7b3cSmrg# This file is free software; the Free Software Foundation 151145b7b3cSmrg# gives unlimited permission to copy and/or distribute it, 152145b7b3cSmrg# with or without modifications, as long as this notice is preserved. 153145b7b3cSmrg 154578741aaSmrg# serial 10 155145b7b3cSmrg 156145b7b3cSmrg# There are a few dirty hacks below to avoid letting `AC_PROG_CC' be 157145b7b3cSmrg# written in clear, in which case automake, when reading aclocal.m4, 158145b7b3cSmrg# will think it sees a *use*, and therefore will trigger all it's 159145b7b3cSmrg# C support machinery. Also note that it means that autoscan, seeing 160145b7b3cSmrg# CC etc. in the Makefile, will ask for an AC_PROG_CC use... 161145b7b3cSmrg 162145b7b3cSmrg 163145b7b3cSmrg# _AM_DEPENDENCIES(NAME) 164145b7b3cSmrg# ---------------------- 165145b7b3cSmrg# See how the compiler implements dependency checking. 166145b7b3cSmrg# NAME is "CC", "CXX", "GCJ", or "OBJC". 167145b7b3cSmrg# We try a few techniques and use that to set a single cache variable. 168145b7b3cSmrg# 169145b7b3cSmrg# We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was 170145b7b3cSmrg# modified to invoke _AM_DEPENDENCIES(CC); we would have a circular 171145b7b3cSmrg# dependency, and given that the user is not expected to run this macro, 172145b7b3cSmrg# just rely on AC_PROG_CC. 173145b7b3cSmrgAC_DEFUN([_AM_DEPENDENCIES], 174145b7b3cSmrg[AC_REQUIRE([AM_SET_DEPDIR])dnl 175145b7b3cSmrgAC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl 176145b7b3cSmrgAC_REQUIRE([AM_MAKE_INCLUDE])dnl 177145b7b3cSmrgAC_REQUIRE([AM_DEP_TRACK])dnl 178145b7b3cSmrg 179145b7b3cSmrgifelse([$1], CC, [depcc="$CC" am_compiler_list=], 180145b7b3cSmrg [$1], CXX, [depcc="$CXX" am_compiler_list=], 181145b7b3cSmrg [$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc'], 182145b7b3cSmrg [$1], UPC, [depcc="$UPC" am_compiler_list=], 183145b7b3cSmrg [$1], GCJ, [depcc="$GCJ" am_compiler_list='gcc3 gcc'], 184145b7b3cSmrg [depcc="$$1" am_compiler_list=]) 185145b7b3cSmrg 186145b7b3cSmrgAC_CACHE_CHECK([dependency style of $depcc], 187145b7b3cSmrg [am_cv_$1_dependencies_compiler_type], 188145b7b3cSmrg[if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then 189145b7b3cSmrg # We make a subdir and do the tests there. Otherwise we can end up 190145b7b3cSmrg # making bogus files that we don't know about and never remove. For 191145b7b3cSmrg # instance it was reported that on HP-UX the gcc test will end up 192145b7b3cSmrg # making a dummy file named `D' -- because `-MD' means `put the output 193145b7b3cSmrg # in D'. 194145b7b3cSmrg mkdir conftest.dir 195145b7b3cSmrg # Copy depcomp to subdir because otherwise we won't find it if we're 196145b7b3cSmrg # using a relative directory. 197145b7b3cSmrg cp "$am_depcomp" conftest.dir 198145b7b3cSmrg cd conftest.dir 199145b7b3cSmrg # We will build objects and dependencies in a subdirectory because 200145b7b3cSmrg # it helps to detect inapplicable dependency modes. For instance 201145b7b3cSmrg # both Tru64's cc and ICC support -MD to output dependencies as a 202145b7b3cSmrg # side effect of compilation, but ICC will put the dependencies in 203145b7b3cSmrg # the current directory while Tru64 will put them in the object 204145b7b3cSmrg # directory. 205145b7b3cSmrg mkdir sub 206145b7b3cSmrg 207145b7b3cSmrg am_cv_$1_dependencies_compiler_type=none 208145b7b3cSmrg if test "$am_compiler_list" = ""; then 209145b7b3cSmrg am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp` 210145b7b3cSmrg fi 211578741aaSmrg am__universal=false 212578741aaSmrg m4_case([$1], [CC], 213578741aaSmrg [case " $depcc " in #( 214578741aaSmrg *\ -arch\ *\ -arch\ *) am__universal=true ;; 215578741aaSmrg esac], 216578741aaSmrg [CXX], 217578741aaSmrg [case " $depcc " in #( 218578741aaSmrg *\ -arch\ *\ -arch\ *) am__universal=true ;; 219578741aaSmrg esac]) 220578741aaSmrg 221145b7b3cSmrg for depmode in $am_compiler_list; do 222145b7b3cSmrg # Setup a source with many dependencies, because some compilers 223145b7b3cSmrg # like to wrap large dependency lists on column 80 (with \), and 224145b7b3cSmrg # we should not choose a depcomp mode which is confused by this. 225145b7b3cSmrg # 226145b7b3cSmrg # We need to recreate these files for each test, as the compiler may 227145b7b3cSmrg # overwrite some of them when testing with obscure command lines. 228145b7b3cSmrg # This happens at least with the AIX C compiler. 229145b7b3cSmrg : > sub/conftest.c 230145b7b3cSmrg for i in 1 2 3 4 5 6; do 231145b7b3cSmrg echo '#include "conftst'$i'.h"' >> sub/conftest.c 232145b7b3cSmrg # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with 233145b7b3cSmrg # Solaris 8's {/usr,}/bin/sh. 234145b7b3cSmrg touch sub/conftst$i.h 235145b7b3cSmrg done 236145b7b3cSmrg echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf 237145b7b3cSmrg 238578741aaSmrg # We check with `-c' and `-o' for the sake of the "dashmstdout" 239578741aaSmrg # mode. It turns out that the SunPro C++ compiler does not properly 240578741aaSmrg # handle `-M -o', and we need to detect this. Also, some Intel 241578741aaSmrg # versions had trouble with output in subdirs 242578741aaSmrg am__obj=sub/conftest.${OBJEXT-o} 243578741aaSmrg am__minus_obj="-o $am__obj" 244145b7b3cSmrg case $depmode in 245578741aaSmrg gcc) 246578741aaSmrg # This depmode causes a compiler race in universal mode. 247578741aaSmrg test "$am__universal" = false || continue 248578741aaSmrg ;; 249145b7b3cSmrg nosideeffect) 250145b7b3cSmrg # after this tag, mechanisms are not by side-effect, so they'll 251145b7b3cSmrg # only be used when explicitly requested 252145b7b3cSmrg if test "x$enable_dependency_tracking" = xyes; then 253145b7b3cSmrg continue 254145b7b3cSmrg else 255145b7b3cSmrg break 256145b7b3cSmrg fi 257145b7b3cSmrg ;; 258578741aaSmrg msvisualcpp | msvcmsys) 259578741aaSmrg # This compiler won't grok `-c -o', but also, the minuso test has 260578741aaSmrg # not run yet. These depmodes are late enough in the game, and 261578741aaSmrg # so weak that their functioning should not be impacted. 262578741aaSmrg am__obj=conftest.${OBJEXT-o} 263578741aaSmrg am__minus_obj= 264578741aaSmrg ;; 265145b7b3cSmrg none) break ;; 266145b7b3cSmrg esac 267145b7b3cSmrg if depmode=$depmode \ 268578741aaSmrg source=sub/conftest.c object=$am__obj \ 269145b7b3cSmrg depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ 270578741aaSmrg $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ 271145b7b3cSmrg >/dev/null 2>conftest.err && 272145b7b3cSmrg grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && 273145b7b3cSmrg grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && 274578741aaSmrg grep $am__obj sub/conftest.Po > /dev/null 2>&1 && 275145b7b3cSmrg ${MAKE-make} -s -f confmf > /dev/null 2>&1; then 276145b7b3cSmrg # icc doesn't choke on unknown options, it will just issue warnings 277145b7b3cSmrg # or remarks (even with -Werror). So we grep stderr for any message 278145b7b3cSmrg # that says an option was ignored or not supported. 279145b7b3cSmrg # When given -MP, icc 7.0 and 7.1 complain thusly: 280145b7b3cSmrg # icc: Command line warning: ignoring option '-M'; no argument required 281145b7b3cSmrg # The diagnosis changed in icc 8.0: 282145b7b3cSmrg # icc: Command line remark: option '-MP' not supported 283145b7b3cSmrg if (grep 'ignoring option' conftest.err || 284145b7b3cSmrg grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else 285145b7b3cSmrg am_cv_$1_dependencies_compiler_type=$depmode 286145b7b3cSmrg break 287145b7b3cSmrg fi 288145b7b3cSmrg fi 289145b7b3cSmrg done 290145b7b3cSmrg 291145b7b3cSmrg cd .. 292145b7b3cSmrg rm -rf conftest.dir 293145b7b3cSmrgelse 294145b7b3cSmrg am_cv_$1_dependencies_compiler_type=none 295145b7b3cSmrgfi 296145b7b3cSmrg]) 297145b7b3cSmrgAC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type]) 298145b7b3cSmrgAM_CONDITIONAL([am__fastdep$1], [ 299145b7b3cSmrg test "x$enable_dependency_tracking" != xno \ 300145b7b3cSmrg && test "$am_cv_$1_dependencies_compiler_type" = gcc3]) 301145b7b3cSmrg]) 302145b7b3cSmrg 303145b7b3cSmrg 304145b7b3cSmrg# AM_SET_DEPDIR 305145b7b3cSmrg# ------------- 306145b7b3cSmrg# Choose a directory name for dependency files. 307145b7b3cSmrg# This macro is AC_REQUIREd in _AM_DEPENDENCIES 308145b7b3cSmrgAC_DEFUN([AM_SET_DEPDIR], 309145b7b3cSmrg[AC_REQUIRE([AM_SET_LEADING_DOT])dnl 310145b7b3cSmrgAC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl 311145b7b3cSmrg]) 312145b7b3cSmrg 313145b7b3cSmrg 314145b7b3cSmrg# AM_DEP_TRACK 315145b7b3cSmrg# ------------ 316145b7b3cSmrgAC_DEFUN([AM_DEP_TRACK], 317145b7b3cSmrg[AC_ARG_ENABLE(dependency-tracking, 318145b7b3cSmrg[ --disable-dependency-tracking speeds up one-time build 319145b7b3cSmrg --enable-dependency-tracking do not reject slow dependency extractors]) 320145b7b3cSmrgif test "x$enable_dependency_tracking" != xno; then 321145b7b3cSmrg am_depcomp="$ac_aux_dir/depcomp" 322145b7b3cSmrg AMDEPBACKSLASH='\' 323145b7b3cSmrgfi 324145b7b3cSmrgAM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno]) 325145b7b3cSmrgAC_SUBST([AMDEPBACKSLASH])dnl 326145b7b3cSmrg_AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl 327145b7b3cSmrg]) 328145b7b3cSmrg 329145b7b3cSmrg# Generate code to set up dependency tracking. -*- Autoconf -*- 330145b7b3cSmrg 331578741aaSmrg# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2008 332145b7b3cSmrg# Free Software Foundation, Inc. 333145b7b3cSmrg# 334145b7b3cSmrg# This file is free software; the Free Software Foundation 335145b7b3cSmrg# gives unlimited permission to copy and/or distribute it, 336145b7b3cSmrg# with or without modifications, as long as this notice is preserved. 337145b7b3cSmrg 338578741aaSmrg#serial 5 339145b7b3cSmrg 340145b7b3cSmrg# _AM_OUTPUT_DEPENDENCY_COMMANDS 341145b7b3cSmrg# ------------------------------ 342145b7b3cSmrgAC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], 343578741aaSmrg[{ 344578741aaSmrg # Autoconf 2.62 quotes --file arguments for eval, but not when files 345578741aaSmrg # are listed without --file. Let's play safe and only enable the eval 346578741aaSmrg # if we detect the quoting. 347578741aaSmrg case $CONFIG_FILES in 348578741aaSmrg *\'*) eval set x "$CONFIG_FILES" ;; 349578741aaSmrg *) set x $CONFIG_FILES ;; 350578741aaSmrg esac 351578741aaSmrg shift 352578741aaSmrg for mf 353578741aaSmrg do 354578741aaSmrg # Strip MF so we end up with the name of the file. 355578741aaSmrg mf=`echo "$mf" | sed -e 's/:.*$//'` 356578741aaSmrg # Check whether this is an Automake generated Makefile or not. 357578741aaSmrg # We used to match only the files named `Makefile.in', but 358578741aaSmrg # some people rename them; so instead we look at the file content. 359578741aaSmrg # Grep'ing the first line is not enough: some people post-process 360578741aaSmrg # each Makefile.in and add a new line on top of each file to say so. 361578741aaSmrg # Grep'ing the whole file is not good either: AIX grep has a line 362578741aaSmrg # limit of 2048, but all sed's we know have understand at least 4000. 363578741aaSmrg if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then 364578741aaSmrg dirpart=`AS_DIRNAME("$mf")` 365578741aaSmrg else 366578741aaSmrg continue 367578741aaSmrg fi 368578741aaSmrg # Extract the definition of DEPDIR, am__include, and am__quote 369578741aaSmrg # from the Makefile without running `make'. 370578741aaSmrg DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` 371578741aaSmrg test -z "$DEPDIR" && continue 372578741aaSmrg am__include=`sed -n 's/^am__include = //p' < "$mf"` 373578741aaSmrg test -z "am__include" && continue 374578741aaSmrg am__quote=`sed -n 's/^am__quote = //p' < "$mf"` 375578741aaSmrg # When using ansi2knr, U may be empty or an underscore; expand it 376578741aaSmrg U=`sed -n 's/^U = //p' < "$mf"` 377578741aaSmrg # Find all dependency output files, they are included files with 378578741aaSmrg # $(DEPDIR) in their names. We invoke sed twice because it is the 379578741aaSmrg # simplest approach to changing $(DEPDIR) to its actual value in the 380578741aaSmrg # expansion. 381578741aaSmrg for file in `sed -n " 382578741aaSmrg s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ 383578741aaSmrg sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do 384578741aaSmrg # Make sure the directory exists. 385578741aaSmrg test -f "$dirpart/$file" && continue 386578741aaSmrg fdir=`AS_DIRNAME(["$file"])` 387578741aaSmrg AS_MKDIR_P([$dirpart/$fdir]) 388578741aaSmrg # echo "creating $dirpart/$file" 389578741aaSmrg echo '# dummy' > "$dirpart/$file" 390578741aaSmrg done 391145b7b3cSmrg done 392578741aaSmrg} 393145b7b3cSmrg])# _AM_OUTPUT_DEPENDENCY_COMMANDS 394145b7b3cSmrg 395145b7b3cSmrg 396145b7b3cSmrg# AM_OUTPUT_DEPENDENCY_COMMANDS 397145b7b3cSmrg# ----------------------------- 398145b7b3cSmrg# This macro should only be invoked once -- use via AC_REQUIRE. 399145b7b3cSmrg# 400145b7b3cSmrg# This code is only required when automatic dependency tracking 401145b7b3cSmrg# is enabled. FIXME. This creates each `.P' file that we will 402145b7b3cSmrg# need in order to bootstrap the dependency handling code. 403145b7b3cSmrgAC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS], 404145b7b3cSmrg[AC_CONFIG_COMMANDS([depfiles], 405145b7b3cSmrg [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS], 406145b7b3cSmrg [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"]) 407145b7b3cSmrg]) 408145b7b3cSmrg 409145b7b3cSmrg# Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005 410145b7b3cSmrg# Free Software Foundation, Inc. 411145b7b3cSmrg# 412145b7b3cSmrg# This file is free software; the Free Software Foundation 413145b7b3cSmrg# gives unlimited permission to copy and/or distribute it, 414145b7b3cSmrg# with or without modifications, as long as this notice is preserved. 415145b7b3cSmrg 416145b7b3cSmrg# serial 8 417145b7b3cSmrg 418145b7b3cSmrg# AM_CONFIG_HEADER is obsolete. It has been replaced by AC_CONFIG_HEADERS. 419145b7b3cSmrgAU_DEFUN([AM_CONFIG_HEADER], [AC_CONFIG_HEADERS($@)]) 420145b7b3cSmrg 421145b7b3cSmrg# Do all the work for Automake. -*- Autoconf -*- 422145b7b3cSmrg 423145b7b3cSmrg# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 424578741aaSmrg# 2005, 2006, 2008, 2009 Free Software Foundation, Inc. 425145b7b3cSmrg# 426145b7b3cSmrg# This file is free software; the Free Software Foundation 427145b7b3cSmrg# gives unlimited permission to copy and/or distribute it, 428145b7b3cSmrg# with or without modifications, as long as this notice is preserved. 429145b7b3cSmrg 430578741aaSmrg# serial 16 431145b7b3cSmrg 432145b7b3cSmrg# This macro actually does too much. Some checks are only needed if 433145b7b3cSmrg# your package does certain things. But this isn't really a big deal. 434145b7b3cSmrg 435145b7b3cSmrg# AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE]) 436145b7b3cSmrg# AM_INIT_AUTOMAKE([OPTIONS]) 437145b7b3cSmrg# ----------------------------------------------- 438145b7b3cSmrg# The call with PACKAGE and VERSION arguments is the old style 439145b7b3cSmrg# call (pre autoconf-2.50), which is being phased out. PACKAGE 440145b7b3cSmrg# and VERSION should now be passed to AC_INIT and removed from 441145b7b3cSmrg# the call to AM_INIT_AUTOMAKE. 442145b7b3cSmrg# We support both call styles for the transition. After 443145b7b3cSmrg# the next Automake release, Autoconf can make the AC_INIT 444145b7b3cSmrg# arguments mandatory, and then we can depend on a new Autoconf 445145b7b3cSmrg# release and drop the old call support. 446145b7b3cSmrgAC_DEFUN([AM_INIT_AUTOMAKE], 447578741aaSmrg[AC_PREREQ([2.62])dnl 448145b7b3cSmrgdnl Autoconf wants to disallow AM_ names. We explicitly allow 449145b7b3cSmrgdnl the ones we care about. 450145b7b3cSmrgm4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl 451145b7b3cSmrgAC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl 452145b7b3cSmrgAC_REQUIRE([AC_PROG_INSTALL])dnl 453145b7b3cSmrgif test "`cd $srcdir && pwd`" != "`pwd`"; then 454145b7b3cSmrg # Use -I$(srcdir) only when $(srcdir) != ., so that make's output 455145b7b3cSmrg # is not polluted with repeated "-I." 456145b7b3cSmrg AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl 457145b7b3cSmrg # test to see if srcdir already configured 458145b7b3cSmrg if test -f $srcdir/config.status; then 459145b7b3cSmrg AC_MSG_ERROR([source directory already configured; run "make distclean" there first]) 460145b7b3cSmrg fi 461145b7b3cSmrgfi 462145b7b3cSmrg 463145b7b3cSmrg# test whether we have cygpath 464145b7b3cSmrgif test -z "$CYGPATH_W"; then 465145b7b3cSmrg if (cygpath --version) >/dev/null 2>/dev/null; then 466145b7b3cSmrg CYGPATH_W='cygpath -w' 467145b7b3cSmrg else 468145b7b3cSmrg CYGPATH_W=echo 469145b7b3cSmrg fi 470145b7b3cSmrgfi 471145b7b3cSmrgAC_SUBST([CYGPATH_W]) 472145b7b3cSmrg 473145b7b3cSmrg# Define the identity of the package. 474145b7b3cSmrgdnl Distinguish between old-style and new-style calls. 475145b7b3cSmrgm4_ifval([$2], 476145b7b3cSmrg[m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl 477145b7b3cSmrg AC_SUBST([PACKAGE], [$1])dnl 478145b7b3cSmrg AC_SUBST([VERSION], [$2])], 479145b7b3cSmrg[_AM_SET_OPTIONS([$1])dnl 480145b7b3cSmrgdnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT. 481145b7b3cSmrgm4_if(m4_ifdef([AC_PACKAGE_NAME], 1)m4_ifdef([AC_PACKAGE_VERSION], 1), 11,, 482145b7b3cSmrg [m4_fatal([AC_INIT should be called with package and version arguments])])dnl 483145b7b3cSmrg AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl 484145b7b3cSmrg AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl 485145b7b3cSmrg 486145b7b3cSmrg_AM_IF_OPTION([no-define],, 487145b7b3cSmrg[AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package]) 488145b7b3cSmrg AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl 489145b7b3cSmrg 490145b7b3cSmrg# Some tools Automake needs. 491145b7b3cSmrgAC_REQUIRE([AM_SANITY_CHECK])dnl 492145b7b3cSmrgAC_REQUIRE([AC_ARG_PROGRAM])dnl 493145b7b3cSmrgAM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version}) 494145b7b3cSmrgAM_MISSING_PROG(AUTOCONF, autoconf) 495145b7b3cSmrgAM_MISSING_PROG(AUTOMAKE, automake-${am__api_version}) 496145b7b3cSmrgAM_MISSING_PROG(AUTOHEADER, autoheader) 497145b7b3cSmrgAM_MISSING_PROG(MAKEINFO, makeinfo) 498578741aaSmrgAC_REQUIRE([AM_PROG_INSTALL_SH])dnl 499578741aaSmrgAC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl 500145b7b3cSmrgAC_REQUIRE([AM_PROG_MKDIR_P])dnl 501145b7b3cSmrg# We need awk for the "check" target. The system "awk" is bad on 502145b7b3cSmrg# some platforms. 503145b7b3cSmrgAC_REQUIRE([AC_PROG_AWK])dnl 504145b7b3cSmrgAC_REQUIRE([AC_PROG_MAKE_SET])dnl 505145b7b3cSmrgAC_REQUIRE([AM_SET_LEADING_DOT])dnl 506145b7b3cSmrg_AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])], 507578741aaSmrg [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])], 508578741aaSmrg [_AM_PROG_TAR([v7])])]) 509145b7b3cSmrg_AM_IF_OPTION([no-dependencies],, 510145b7b3cSmrg[AC_PROVIDE_IFELSE([AC_PROG_CC], 511578741aaSmrg [_AM_DEPENDENCIES(CC)], 512578741aaSmrg [define([AC_PROG_CC], 513578741aaSmrg defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl 514145b7b3cSmrgAC_PROVIDE_IFELSE([AC_PROG_CXX], 515578741aaSmrg [_AM_DEPENDENCIES(CXX)], 516578741aaSmrg [define([AC_PROG_CXX], 517578741aaSmrg defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl 518145b7b3cSmrgAC_PROVIDE_IFELSE([AC_PROG_OBJC], 519578741aaSmrg [_AM_DEPENDENCIES(OBJC)], 520578741aaSmrg [define([AC_PROG_OBJC], 521578741aaSmrg defn([AC_PROG_OBJC])[_AM_DEPENDENCIES(OBJC)])])dnl 522145b7b3cSmrg]) 523578741aaSmrg_AM_IF_OPTION([silent-rules], [AC_REQUIRE([AM_SILENT_RULES])])dnl 524578741aaSmrgdnl The `parallel-tests' driver may need to know about EXEEXT, so add the 525578741aaSmrgdnl `am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This macro 526578741aaSmrgdnl is hooked onto _AC_COMPILER_EXEEXT early, see below. 527578741aaSmrgAC_CONFIG_COMMANDS_PRE(dnl 528578741aaSmrg[m4_provide_if([_AM_COMPILER_EXEEXT], 529578741aaSmrg [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl 530145b7b3cSmrg]) 531145b7b3cSmrg 532578741aaSmrgdnl Hook into `_AC_COMPILER_EXEEXT' early to learn its expansion. Do not 533578741aaSmrgdnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further 534578741aaSmrgdnl mangled by Autoconf and run in a shell conditional statement. 535578741aaSmrgm4_define([_AC_COMPILER_EXEEXT], 536578741aaSmrgm4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])]) 537578741aaSmrg 538145b7b3cSmrg 539145b7b3cSmrg# When config.status generates a header, we must update the stamp-h file. 540145b7b3cSmrg# This file resides in the same directory as the config header 541145b7b3cSmrg# that is generated. The stamp files are numbered to have different names. 542145b7b3cSmrg 543145b7b3cSmrg# Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the 544145b7b3cSmrg# loop where config.status creates the headers, so we can generate 545145b7b3cSmrg# our stamp files there. 546145b7b3cSmrgAC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK], 547145b7b3cSmrg[# Compute $1's index in $config_headers. 548578741aaSmrg_am_arg=$1 549145b7b3cSmrg_am_stamp_count=1 550145b7b3cSmrgfor _am_header in $config_headers :; do 551145b7b3cSmrg case $_am_header in 552578741aaSmrg $_am_arg | $_am_arg:* ) 553145b7b3cSmrg break ;; 554145b7b3cSmrg * ) 555145b7b3cSmrg _am_stamp_count=`expr $_am_stamp_count + 1` ;; 556145b7b3cSmrg esac 557145b7b3cSmrgdone 558578741aaSmrgecho "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count]) 559145b7b3cSmrg 560578741aaSmrg# Copyright (C) 2001, 2003, 2005, 2008 Free Software Foundation, Inc. 561145b7b3cSmrg# 562145b7b3cSmrg# This file is free software; the Free Software Foundation 563145b7b3cSmrg# gives unlimited permission to copy and/or distribute it, 564145b7b3cSmrg# with or without modifications, as long as this notice is preserved. 565145b7b3cSmrg 566145b7b3cSmrg# AM_PROG_INSTALL_SH 567145b7b3cSmrg# ------------------ 568145b7b3cSmrg# Define $install_sh. 569145b7b3cSmrgAC_DEFUN([AM_PROG_INSTALL_SH], 570145b7b3cSmrg[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl 571578741aaSmrgif test x"${install_sh}" != xset; then 572578741aaSmrg case $am_aux_dir in 573578741aaSmrg *\ * | *\ *) 574578741aaSmrg install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;; 575578741aaSmrg *) 576578741aaSmrg install_sh="\${SHELL} $am_aux_dir/install-sh" 577578741aaSmrg esac 578578741aaSmrgfi 579145b7b3cSmrgAC_SUBST(install_sh)]) 580145b7b3cSmrg 581145b7b3cSmrg# Copyright (C) 2003, 2005 Free Software Foundation, Inc. 582145b7b3cSmrg# 583145b7b3cSmrg# This file is free software; the Free Software Foundation 584145b7b3cSmrg# gives unlimited permission to copy and/or distribute it, 585145b7b3cSmrg# with or without modifications, as long as this notice is preserved. 586145b7b3cSmrg 587145b7b3cSmrg# serial 2 588145b7b3cSmrg 589145b7b3cSmrg# Check whether the underlying file-system supports filenames 590145b7b3cSmrg# with a leading dot. For instance MS-DOS doesn't. 591145b7b3cSmrgAC_DEFUN([AM_SET_LEADING_DOT], 592145b7b3cSmrg[rm -rf .tst 2>/dev/null 593145b7b3cSmrgmkdir .tst 2>/dev/null 594145b7b3cSmrgif test -d .tst; then 595145b7b3cSmrg am__leading_dot=. 596145b7b3cSmrgelse 597145b7b3cSmrg am__leading_dot=_ 598145b7b3cSmrgfi 599145b7b3cSmrgrmdir .tst 2>/dev/null 600145b7b3cSmrgAC_SUBST([am__leading_dot])]) 601145b7b3cSmrg 602145b7b3cSmrg# Add --enable-maintainer-mode option to configure. -*- Autoconf -*- 603145b7b3cSmrg# From Jim Meyering 604145b7b3cSmrg 605578741aaSmrg# Copyright (C) 1996, 1998, 2000, 2001, 2002, 2003, 2004, 2005, 2008 606145b7b3cSmrg# Free Software Foundation, Inc. 607145b7b3cSmrg# 608145b7b3cSmrg# This file is free software; the Free Software Foundation 609145b7b3cSmrg# gives unlimited permission to copy and/or distribute it, 610145b7b3cSmrg# with or without modifications, as long as this notice is preserved. 611145b7b3cSmrg 612578741aaSmrg# serial 5 613145b7b3cSmrg 614578741aaSmrg# AM_MAINTAINER_MODE([DEFAULT-MODE]) 615578741aaSmrg# ---------------------------------- 616578741aaSmrg# Control maintainer-specific portions of Makefiles. 617578741aaSmrg# Default is to disable them, unless `enable' is passed literally. 618578741aaSmrg# For symmetry, `disable' may be passed as well. Anyway, the user 619578741aaSmrg# can override the default with the --enable/--disable switch. 620145b7b3cSmrgAC_DEFUN([AM_MAINTAINER_MODE], 621578741aaSmrg[m4_case(m4_default([$1], [disable]), 622578741aaSmrg [enable], [m4_define([am_maintainer_other], [disable])], 623578741aaSmrg [disable], [m4_define([am_maintainer_other], [enable])], 624578741aaSmrg [m4_define([am_maintainer_other], [enable]) 625578741aaSmrg m4_warn([syntax], [unexpected argument to AM@&t@_MAINTAINER_MODE: $1])]) 626578741aaSmrgAC_MSG_CHECKING([whether to am_maintainer_other maintainer-specific portions of Makefiles]) 627578741aaSmrg dnl maintainer-mode's default is 'disable' unless 'enable' is passed 628578741aaSmrg AC_ARG_ENABLE([maintainer-mode], 629578741aaSmrg[ --][am_maintainer_other][-maintainer-mode am_maintainer_other make rules and dependencies not useful 630145b7b3cSmrg (and sometimes confusing) to the casual installer], 631578741aaSmrg [USE_MAINTAINER_MODE=$enableval], 632578741aaSmrg [USE_MAINTAINER_MODE=]m4_if(am_maintainer_other, [enable], [no], [yes])) 633145b7b3cSmrg AC_MSG_RESULT([$USE_MAINTAINER_MODE]) 634578741aaSmrg AM_CONDITIONAL([MAINTAINER_MODE], [test $USE_MAINTAINER_MODE = yes]) 635145b7b3cSmrg MAINT=$MAINTAINER_MODE_TRUE 636578741aaSmrg AC_SUBST([MAINT])dnl 637145b7b3cSmrg] 638145b7b3cSmrg) 639145b7b3cSmrg 640145b7b3cSmrgAU_DEFUN([jm_MAINTAINER_MODE], [AM_MAINTAINER_MODE]) 641145b7b3cSmrg 642145b7b3cSmrg# Check to see how 'make' treats includes. -*- Autoconf -*- 643145b7b3cSmrg 644578741aaSmrg# Copyright (C) 2001, 2002, 2003, 2005, 2009 Free Software Foundation, Inc. 645145b7b3cSmrg# 646145b7b3cSmrg# This file is free software; the Free Software Foundation 647145b7b3cSmrg# gives unlimited permission to copy and/or distribute it, 648145b7b3cSmrg# with or without modifications, as long as this notice is preserved. 649145b7b3cSmrg 650578741aaSmrg# serial 4 651145b7b3cSmrg 652145b7b3cSmrg# AM_MAKE_INCLUDE() 653145b7b3cSmrg# ----------------- 654145b7b3cSmrg# Check to see how make treats includes. 655145b7b3cSmrgAC_DEFUN([AM_MAKE_INCLUDE], 656145b7b3cSmrg[am_make=${MAKE-make} 657145b7b3cSmrgcat > confinc << 'END' 658145b7b3cSmrgam__doit: 659578741aaSmrg @echo this is the am__doit target 660145b7b3cSmrg.PHONY: am__doit 661145b7b3cSmrgEND 662145b7b3cSmrg# If we don't find an include directive, just comment out the code. 663145b7b3cSmrgAC_MSG_CHECKING([for style of include used by $am_make]) 664145b7b3cSmrgam__include="#" 665145b7b3cSmrgam__quote= 666145b7b3cSmrg_am_result=none 667145b7b3cSmrg# First try GNU make style include. 668145b7b3cSmrgecho "include confinc" > confmf 669578741aaSmrg# Ignore all kinds of additional output from `make'. 670578741aaSmrgcase `$am_make -s -f confmf 2> /dev/null` in #( 671578741aaSmrg*the\ am__doit\ target*) 672578741aaSmrg am__include=include 673578741aaSmrg am__quote= 674578741aaSmrg _am_result=GNU 675578741aaSmrg ;; 676578741aaSmrgesac 677145b7b3cSmrg# Now try BSD make style include. 678145b7b3cSmrgif test "$am__include" = "#"; then 679145b7b3cSmrg echo '.include "confinc"' > confmf 680578741aaSmrg case `$am_make -s -f confmf 2> /dev/null` in #( 681578741aaSmrg *the\ am__doit\ target*) 682578741aaSmrg am__include=.include 683578741aaSmrg am__quote="\"" 684578741aaSmrg _am_result=BSD 685578741aaSmrg ;; 686578741aaSmrg esac 687145b7b3cSmrgfi 688145b7b3cSmrgAC_SUBST([am__include]) 689145b7b3cSmrgAC_SUBST([am__quote]) 690145b7b3cSmrgAC_MSG_RESULT([$_am_result]) 691145b7b3cSmrgrm -f confinc confmf 692145b7b3cSmrg]) 693145b7b3cSmrg 694578741aaSmrg# Copyright (C) 1999, 2000, 2001, 2003, 2004, 2005, 2008 695145b7b3cSmrg# Free Software Foundation, Inc. 696145b7b3cSmrg# 697145b7b3cSmrg# This file is free software; the Free Software Foundation 698145b7b3cSmrg# gives unlimited permission to copy and/or distribute it, 699145b7b3cSmrg# with or without modifications, as long as this notice is preserved. 700145b7b3cSmrg 701578741aaSmrg# serial 6 702145b7b3cSmrg 703145b7b3cSmrg# AM_PROG_CC_C_O 704145b7b3cSmrg# -------------- 705145b7b3cSmrg# Like AC_PROG_CC_C_O, but changed for automake. 706145b7b3cSmrgAC_DEFUN([AM_PROG_CC_C_O], 707145b7b3cSmrg[AC_REQUIRE([AC_PROG_CC_C_O])dnl 708145b7b3cSmrgAC_REQUIRE([AM_AUX_DIR_EXPAND])dnl 709145b7b3cSmrgAC_REQUIRE_AUX_FILE([compile])dnl 710145b7b3cSmrg# FIXME: we rely on the cache variable name because 711145b7b3cSmrg# there is no other way. 712145b7b3cSmrgset dummy $CC 713578741aaSmrgam_cc=`echo $[2] | sed ['s/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/']` 714578741aaSmrgeval am_t=\$ac_cv_prog_cc_${am_cc}_c_o 715578741aaSmrgif test "$am_t" != yes; then 716145b7b3cSmrg # Losing compiler, so override with the script. 717145b7b3cSmrg # FIXME: It is wrong to rewrite CC. 718145b7b3cSmrg # But if we don't then we get into trouble of one sort or another. 719145b7b3cSmrg # A longer-term fix would be to have automake use am__CC in this case, 720145b7b3cSmrg # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)" 721145b7b3cSmrg CC="$am_aux_dir/compile $CC" 722145b7b3cSmrgfi 723145b7b3cSmrgdnl Make sure AC_PROG_CC is never called again, or it will override our 724145b7b3cSmrgdnl setting of CC. 725145b7b3cSmrgm4_define([AC_PROG_CC], 726145b7b3cSmrg [m4_fatal([AC_PROG_CC cannot be called after AM_PROG_CC_C_O])]) 727145b7b3cSmrg]) 728145b7b3cSmrg 729145b7b3cSmrg# Fake the existence of programs that GNU maintainers use. -*- Autoconf -*- 730145b7b3cSmrg 731578741aaSmrg# Copyright (C) 1997, 1999, 2000, 2001, 2003, 2004, 2005, 2008 732145b7b3cSmrg# Free Software Foundation, Inc. 733145b7b3cSmrg# 734145b7b3cSmrg# This file is free software; the Free Software Foundation 735145b7b3cSmrg# gives unlimited permission to copy and/or distribute it, 736145b7b3cSmrg# with or without modifications, as long as this notice is preserved. 737145b7b3cSmrg 738578741aaSmrg# serial 6 739145b7b3cSmrg 740145b7b3cSmrg# AM_MISSING_PROG(NAME, PROGRAM) 741145b7b3cSmrg# ------------------------------ 742145b7b3cSmrgAC_DEFUN([AM_MISSING_PROG], 743145b7b3cSmrg[AC_REQUIRE([AM_MISSING_HAS_RUN]) 744145b7b3cSmrg$1=${$1-"${am_missing_run}$2"} 745145b7b3cSmrgAC_SUBST($1)]) 746145b7b3cSmrg 747145b7b3cSmrg 748145b7b3cSmrg# AM_MISSING_HAS_RUN 749145b7b3cSmrg# ------------------ 750145b7b3cSmrg# Define MISSING if not defined so far and test if it supports --run. 751145b7b3cSmrg# If it does, set am_missing_run to use it, otherwise, to nothing. 752145b7b3cSmrgAC_DEFUN([AM_MISSING_HAS_RUN], 753145b7b3cSmrg[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl 754145b7b3cSmrgAC_REQUIRE_AUX_FILE([missing])dnl 755578741aaSmrgif test x"${MISSING+set}" != xset; then 756578741aaSmrg case $am_aux_dir in 757578741aaSmrg *\ * | *\ *) 758578741aaSmrg MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;; 759578741aaSmrg *) 760578741aaSmrg MISSING="\${SHELL} $am_aux_dir/missing" ;; 761578741aaSmrg esac 762578741aaSmrgfi 763145b7b3cSmrg# Use eval to expand $SHELL 764145b7b3cSmrgif eval "$MISSING --run true"; then 765145b7b3cSmrg am_missing_run="$MISSING --run " 766145b7b3cSmrgelse 767145b7b3cSmrg am_missing_run= 768145b7b3cSmrg AC_MSG_WARN([`missing' script is too old or missing]) 769145b7b3cSmrgfi 770145b7b3cSmrg]) 771145b7b3cSmrg 772145b7b3cSmrg# Copyright (C) 2003, 2004, 2005, 2006 Free Software Foundation, Inc. 773145b7b3cSmrg# 774145b7b3cSmrg# This file is free software; the Free Software Foundation 775145b7b3cSmrg# gives unlimited permission to copy and/or distribute it, 776145b7b3cSmrg# with or without modifications, as long as this notice is preserved. 777145b7b3cSmrg 778145b7b3cSmrg# AM_PROG_MKDIR_P 779145b7b3cSmrg# --------------- 780145b7b3cSmrg# Check for `mkdir -p'. 781145b7b3cSmrgAC_DEFUN([AM_PROG_MKDIR_P], 782145b7b3cSmrg[AC_PREREQ([2.60])dnl 783145b7b3cSmrgAC_REQUIRE([AC_PROG_MKDIR_P])dnl 784145b7b3cSmrgdnl Automake 1.8 to 1.9.6 used to define mkdir_p. We now use MKDIR_P, 785145b7b3cSmrgdnl while keeping a definition of mkdir_p for backward compatibility. 786145b7b3cSmrgdnl @MKDIR_P@ is magic: AC_OUTPUT adjusts its value for each Makefile. 787145b7b3cSmrgdnl However we cannot define mkdir_p as $(MKDIR_P) for the sake of 788145b7b3cSmrgdnl Makefile.ins that do not define MKDIR_P, so we do our own 789145b7b3cSmrgdnl adjustment using top_builddir (which is defined more often than 790145b7b3cSmrgdnl MKDIR_P). 791145b7b3cSmrgAC_SUBST([mkdir_p], ["$MKDIR_P"])dnl 792145b7b3cSmrgcase $mkdir_p in 793145b7b3cSmrg [[\\/$]]* | ?:[[\\/]]*) ;; 794145b7b3cSmrg */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;; 795145b7b3cSmrgesac 796145b7b3cSmrg]) 797145b7b3cSmrg 798145b7b3cSmrg# Helper functions for option handling. -*- Autoconf -*- 799145b7b3cSmrg 800578741aaSmrg# Copyright (C) 2001, 2002, 2003, 2005, 2008 Free Software Foundation, Inc. 801145b7b3cSmrg# 802145b7b3cSmrg# This file is free software; the Free Software Foundation 803145b7b3cSmrg# gives unlimited permission to copy and/or distribute it, 804145b7b3cSmrg# with or without modifications, as long as this notice is preserved. 805145b7b3cSmrg 806578741aaSmrg# serial 4 807145b7b3cSmrg 808145b7b3cSmrg# _AM_MANGLE_OPTION(NAME) 809145b7b3cSmrg# ----------------------- 810145b7b3cSmrgAC_DEFUN([_AM_MANGLE_OPTION], 811145b7b3cSmrg[[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])]) 812145b7b3cSmrg 813145b7b3cSmrg# _AM_SET_OPTION(NAME) 814145b7b3cSmrg# ------------------------------ 815145b7b3cSmrg# Set option NAME. Presently that only means defining a flag for this option. 816145b7b3cSmrgAC_DEFUN([_AM_SET_OPTION], 817145b7b3cSmrg[m4_define(_AM_MANGLE_OPTION([$1]), 1)]) 818145b7b3cSmrg 819145b7b3cSmrg# _AM_SET_OPTIONS(OPTIONS) 820145b7b3cSmrg# ---------------------------------- 821145b7b3cSmrg# OPTIONS is a space-separated list of Automake options. 822145b7b3cSmrgAC_DEFUN([_AM_SET_OPTIONS], 823578741aaSmrg[m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])]) 824145b7b3cSmrg 825145b7b3cSmrg# _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET]) 826145b7b3cSmrg# ------------------------------------------- 827145b7b3cSmrg# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. 828145b7b3cSmrgAC_DEFUN([_AM_IF_OPTION], 829145b7b3cSmrg[m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])]) 830145b7b3cSmrg 831145b7b3cSmrg# Check to make sure that the build environment is sane. -*- Autoconf -*- 832145b7b3cSmrg 833578741aaSmrg# Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005, 2008 834145b7b3cSmrg# Free Software Foundation, Inc. 835145b7b3cSmrg# 836145b7b3cSmrg# This file is free software; the Free Software Foundation 837145b7b3cSmrg# gives unlimited permission to copy and/or distribute it, 838145b7b3cSmrg# with or without modifications, as long as this notice is preserved. 839145b7b3cSmrg 840578741aaSmrg# serial 5 841145b7b3cSmrg 842145b7b3cSmrg# AM_SANITY_CHECK 843145b7b3cSmrg# --------------- 844145b7b3cSmrgAC_DEFUN([AM_SANITY_CHECK], 845145b7b3cSmrg[AC_MSG_CHECKING([whether build environment is sane]) 846145b7b3cSmrg# Just in case 847145b7b3cSmrgsleep 1 848145b7b3cSmrgecho timestamp > conftest.file 849578741aaSmrg# Reject unsafe characters in $srcdir or the absolute working directory 850578741aaSmrg# name. Accept space and tab only in the latter. 851578741aaSmrgam_lf=' 852578741aaSmrg' 853578741aaSmrgcase `pwd` in 854578741aaSmrg *[[\\\"\#\$\&\'\`$am_lf]]*) 855578741aaSmrg AC_MSG_ERROR([unsafe absolute working directory name]);; 856578741aaSmrgesac 857578741aaSmrgcase $srcdir in 858578741aaSmrg *[[\\\"\#\$\&\'\`$am_lf\ \ ]]*) 859578741aaSmrg AC_MSG_ERROR([unsafe srcdir value: `$srcdir']);; 860578741aaSmrgesac 861578741aaSmrg 862145b7b3cSmrg# Do `set' in a subshell so we don't clobber the current shell's 863145b7b3cSmrg# arguments. Must try -L first in case configure is actually a 864145b7b3cSmrg# symlink; some systems play weird games with the mod time of symlinks 865145b7b3cSmrg# (eg FreeBSD returns the mod time of the symlink's containing 866145b7b3cSmrg# directory). 867145b7b3cSmrgif ( 868578741aaSmrg set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` 869145b7b3cSmrg if test "$[*]" = "X"; then 870145b7b3cSmrg # -L didn't work. 871578741aaSmrg set X `ls -t "$srcdir/configure" conftest.file` 872145b7b3cSmrg fi 873145b7b3cSmrg rm -f conftest.file 874145b7b3cSmrg if test "$[*]" != "X $srcdir/configure conftest.file" \ 875145b7b3cSmrg && test "$[*]" != "X conftest.file $srcdir/configure"; then 876145b7b3cSmrg 877145b7b3cSmrg # If neither matched, then we have a broken ls. This can happen 878145b7b3cSmrg # if, for instance, CONFIG_SHELL is bash and it inherits a 879145b7b3cSmrg # broken ls alias from the environment. This has actually 880145b7b3cSmrg # happened. Such a system could not be considered "sane". 881145b7b3cSmrg AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken 882145b7b3cSmrgalias in your environment]) 883145b7b3cSmrg fi 884145b7b3cSmrg 885145b7b3cSmrg test "$[2]" = conftest.file 886145b7b3cSmrg ) 887145b7b3cSmrgthen 888145b7b3cSmrg # Ok. 889145b7b3cSmrg : 890145b7b3cSmrgelse 891145b7b3cSmrg AC_MSG_ERROR([newly created file is older than distributed files! 892145b7b3cSmrgCheck your system clock]) 893145b7b3cSmrgfi 894145b7b3cSmrgAC_MSG_RESULT(yes)]) 895145b7b3cSmrg 896578741aaSmrg# Copyright (C) 2009 Free Software Foundation, Inc. 897578741aaSmrg# 898578741aaSmrg# This file is free software; the Free Software Foundation 899578741aaSmrg# gives unlimited permission to copy and/or distribute it, 900578741aaSmrg# with or without modifications, as long as this notice is preserved. 901578741aaSmrg 902578741aaSmrg# serial 1 903578741aaSmrg 904578741aaSmrg# AM_SILENT_RULES([DEFAULT]) 905578741aaSmrg# -------------------------- 906578741aaSmrg# Enable less verbose build rules; with the default set to DEFAULT 907578741aaSmrg# (`yes' being less verbose, `no' or empty being verbose). 908578741aaSmrgAC_DEFUN([AM_SILENT_RULES], 909578741aaSmrg[AC_ARG_ENABLE([silent-rules], 910578741aaSmrg[ --enable-silent-rules less verbose build output (undo: `make V=1') 911578741aaSmrg --disable-silent-rules verbose build output (undo: `make V=0')]) 912578741aaSmrgcase $enable_silent_rules in 913578741aaSmrgyes) AM_DEFAULT_VERBOSITY=0;; 914578741aaSmrgno) AM_DEFAULT_VERBOSITY=1;; 915578741aaSmrg*) AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);; 916578741aaSmrgesac 917578741aaSmrgAC_SUBST([AM_DEFAULT_VERBOSITY])dnl 918578741aaSmrgAM_BACKSLASH='\' 919578741aaSmrgAC_SUBST([AM_BACKSLASH])dnl 920578741aaSmrg_AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl 921578741aaSmrg]) 922578741aaSmrg 923145b7b3cSmrg# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. 924145b7b3cSmrg# 925145b7b3cSmrg# This file is free software; the Free Software Foundation 926145b7b3cSmrg# gives unlimited permission to copy and/or distribute it, 927145b7b3cSmrg# with or without modifications, as long as this notice is preserved. 928145b7b3cSmrg 929145b7b3cSmrg# AM_PROG_INSTALL_STRIP 930145b7b3cSmrg# --------------------- 931145b7b3cSmrg# One issue with vendor `install' (even GNU) is that you can't 932145b7b3cSmrg# specify the program used to strip binaries. This is especially 933145b7b3cSmrg# annoying in cross-compiling environments, where the build's strip 934145b7b3cSmrg# is unlikely to handle the host's binaries. 935145b7b3cSmrg# Fortunately install-sh will honor a STRIPPROG variable, so we 936145b7b3cSmrg# always use install-sh in `make install-strip', and initialize 937145b7b3cSmrg# STRIPPROG with the value of the STRIP variable (set by the user). 938145b7b3cSmrgAC_DEFUN([AM_PROG_INSTALL_STRIP], 939145b7b3cSmrg[AC_REQUIRE([AM_PROG_INSTALL_SH])dnl 940145b7b3cSmrg# Installed binaries are usually stripped using `strip' when the user 941145b7b3cSmrg# run `make install-strip'. However `strip' might not be the right 942145b7b3cSmrg# tool to use in cross-compilation environments, therefore Automake 943145b7b3cSmrg# will honor the `STRIP' environment variable to overrule this program. 944145b7b3cSmrgdnl Don't test for $cross_compiling = yes, because it might be `maybe'. 945145b7b3cSmrgif test "$cross_compiling" != no; then 946145b7b3cSmrg AC_CHECK_TOOL([STRIP], [strip], :) 947145b7b3cSmrgfi 948145b7b3cSmrgINSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" 949145b7b3cSmrgAC_SUBST([INSTALL_STRIP_PROGRAM])]) 950145b7b3cSmrg 951578741aaSmrg# Copyright (C) 2006, 2008 Free Software Foundation, Inc. 952145b7b3cSmrg# 953145b7b3cSmrg# This file is free software; the Free Software Foundation 954145b7b3cSmrg# gives unlimited permission to copy and/or distribute it, 955145b7b3cSmrg# with or without modifications, as long as this notice is preserved. 956145b7b3cSmrg 957578741aaSmrg# serial 2 958578741aaSmrg 959145b7b3cSmrg# _AM_SUBST_NOTMAKE(VARIABLE) 960145b7b3cSmrg# --------------------------- 961578741aaSmrg# Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in. 962145b7b3cSmrg# This macro is traced by Automake. 963145b7b3cSmrgAC_DEFUN([_AM_SUBST_NOTMAKE]) 964145b7b3cSmrg 965578741aaSmrg# AM_SUBST_NOTMAKE(VARIABLE) 966578741aaSmrg# --------------------------- 967578741aaSmrg# Public sister of _AM_SUBST_NOTMAKE. 968578741aaSmrgAC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)]) 969578741aaSmrg 970145b7b3cSmrg# Check how to create a tarball. -*- Autoconf -*- 971145b7b3cSmrg 972145b7b3cSmrg# Copyright (C) 2004, 2005 Free Software Foundation, Inc. 973145b7b3cSmrg# 974145b7b3cSmrg# This file is free software; the Free Software Foundation 975145b7b3cSmrg# gives unlimited permission to copy and/or distribute it, 976145b7b3cSmrg# with or without modifications, as long as this notice is preserved. 977145b7b3cSmrg 978145b7b3cSmrg# serial 2 979145b7b3cSmrg 980145b7b3cSmrg# _AM_PROG_TAR(FORMAT) 981145b7b3cSmrg# -------------------- 982145b7b3cSmrg# Check how to create a tarball in format FORMAT. 983145b7b3cSmrg# FORMAT should be one of `v7', `ustar', or `pax'. 984145b7b3cSmrg# 985145b7b3cSmrg# Substitute a variable $(am__tar) that is a command 986145b7b3cSmrg# writing to stdout a FORMAT-tarball containing the directory 987145b7b3cSmrg# $tardir. 988145b7b3cSmrg# tardir=directory && $(am__tar) > result.tar 989145b7b3cSmrg# 990145b7b3cSmrg# Substitute a variable $(am__untar) that extract such 991145b7b3cSmrg# a tarball read from stdin. 992145b7b3cSmrg# $(am__untar) < result.tar 993145b7b3cSmrgAC_DEFUN([_AM_PROG_TAR], 994145b7b3cSmrg[# Always define AMTAR for backward compatibility. 995145b7b3cSmrgAM_MISSING_PROG([AMTAR], [tar]) 996145b7b3cSmrgm4_if([$1], [v7], 997145b7b3cSmrg [am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'], 998145b7b3cSmrg [m4_case([$1], [ustar],, [pax],, 999145b7b3cSmrg [m4_fatal([Unknown tar format])]) 1000145b7b3cSmrgAC_MSG_CHECKING([how to create a $1 tar archive]) 1001145b7b3cSmrg# Loop over all known methods to create a tar archive until one works. 1002145b7b3cSmrg_am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none' 1003145b7b3cSmrg_am_tools=${am_cv_prog_tar_$1-$_am_tools} 1004145b7b3cSmrg# Do not fold the above two line into one, because Tru64 sh and 1005145b7b3cSmrg# Solaris sh will not grok spaces in the rhs of `-'. 1006145b7b3cSmrgfor _am_tool in $_am_tools 1007145b7b3cSmrgdo 1008145b7b3cSmrg case $_am_tool in 1009145b7b3cSmrg gnutar) 1010145b7b3cSmrg for _am_tar in tar gnutar gtar; 1011145b7b3cSmrg do 1012145b7b3cSmrg AM_RUN_LOG([$_am_tar --version]) && break 1013145b7b3cSmrg done 1014145b7b3cSmrg am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"' 1015145b7b3cSmrg am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"' 1016145b7b3cSmrg am__untar="$_am_tar -xf -" 1017145b7b3cSmrg ;; 1018145b7b3cSmrg plaintar) 1019145b7b3cSmrg # Must skip GNU tar: if it does not support --format= it doesn't create 1020145b7b3cSmrg # ustar tarball either. 1021145b7b3cSmrg (tar --version) >/dev/null 2>&1 && continue 1022145b7b3cSmrg am__tar='tar chf - "$$tardir"' 1023145b7b3cSmrg am__tar_='tar chf - "$tardir"' 1024145b7b3cSmrg am__untar='tar xf -' 1025145b7b3cSmrg ;; 1026145b7b3cSmrg pax) 1027145b7b3cSmrg am__tar='pax -L -x $1 -w "$$tardir"' 1028145b7b3cSmrg am__tar_='pax -L -x $1 -w "$tardir"' 1029145b7b3cSmrg am__untar='pax -r' 1030145b7b3cSmrg ;; 1031145b7b3cSmrg cpio) 1032145b7b3cSmrg am__tar='find "$$tardir" -print | cpio -o -H $1 -L' 1033145b7b3cSmrg am__tar_='find "$tardir" -print | cpio -o -H $1 -L' 1034145b7b3cSmrg am__untar='cpio -i -H $1 -d' 1035145b7b3cSmrg ;; 1036145b7b3cSmrg none) 1037145b7b3cSmrg am__tar=false 1038145b7b3cSmrg am__tar_=false 1039145b7b3cSmrg am__untar=false 1040145b7b3cSmrg ;; 1041145b7b3cSmrg esac 1042145b7b3cSmrg 1043145b7b3cSmrg # If the value was cached, stop now. We just wanted to have am__tar 1044145b7b3cSmrg # and am__untar set. 1045145b7b3cSmrg test -n "${am_cv_prog_tar_$1}" && break 1046145b7b3cSmrg 1047145b7b3cSmrg # tar/untar a dummy directory, and stop if the command works 1048145b7b3cSmrg rm -rf conftest.dir 1049145b7b3cSmrg mkdir conftest.dir 1050145b7b3cSmrg echo GrepMe > conftest.dir/file 1051145b7b3cSmrg AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar]) 1052145b7b3cSmrg rm -rf conftest.dir 1053145b7b3cSmrg if test -s conftest.tar; then 1054145b7b3cSmrg AM_RUN_LOG([$am__untar <conftest.tar]) 1055145b7b3cSmrg grep GrepMe conftest.dir/file >/dev/null 2>&1 && break 1056145b7b3cSmrg fi 1057145b7b3cSmrgdone 1058145b7b3cSmrgrm -rf conftest.dir 1059145b7b3cSmrg 1060145b7b3cSmrgAC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool]) 1061145b7b3cSmrgAC_MSG_RESULT([$am_cv_prog_tar_$1])]) 1062145b7b3cSmrgAC_SUBST([am__tar]) 1063145b7b3cSmrgAC_SUBST([am__untar]) 1064145b7b3cSmrg]) # _AM_PROG_TAR 1065145b7b3cSmrg 1066578741aaSmrgdnl xorg-macros.m4. Generated from xorg-macros.m4.in xorgversion.m4 by configure. 1067145b7b3cSmrgdnl 1068145b7b3cSmrgdnl Copyright 2005-2006 Sun Microsystems, Inc. All rights reserved. 1069145b7b3cSmrgdnl 1070145b7b3cSmrgdnl Permission is hereby granted, free of charge, to any person obtaining a 1071145b7b3cSmrgdnl copy of this software and associated documentation files (the 1072145b7b3cSmrgdnl "Software"), to deal in the Software without restriction, including 1073145b7b3cSmrgdnl without limitation the rights to use, copy, modify, merge, publish, 1074145b7b3cSmrgdnl distribute, and/or sell copies of the Software, and to permit persons 1075145b7b3cSmrgdnl to whom the Software is furnished to do so, provided that the above 1076145b7b3cSmrgdnl copyright notice(s) and this permission notice appear in all copies of 1077145b7b3cSmrgdnl the Software and that both the above copyright notice(s) and this 1078145b7b3cSmrgdnl permission notice appear in supporting documentation. 1079145b7b3cSmrgdnl 1080145b7b3cSmrgdnl THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS 1081145b7b3cSmrgdnl OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 1082145b7b3cSmrgdnl MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT 1083145b7b3cSmrgdnl OF THIRD PARTY RIGHTS. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR 1084145b7b3cSmrgdnl HOLDERS INCLUDED IN THIS NOTICE BE LIABLE FOR ANY CLAIM, OR ANY SPECIAL 1085145b7b3cSmrgdnl INDIRECT OR CONSEQUENTIAL DAMAGES, OR ANY DAMAGES WHATSOEVER RESULTING 1086145b7b3cSmrgdnl FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, 1087145b7b3cSmrgdnl NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION 1088145b7b3cSmrgdnl WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. 1089145b7b3cSmrgdnl 1090145b7b3cSmrgdnl Except as contained in this notice, the name of a copyright holder 1091145b7b3cSmrgdnl shall not be used in advertising or otherwise to promote the sale, use 1092145b7b3cSmrgdnl or other dealings in this Software without prior written authorization 1093145b7b3cSmrgdnl of the copyright holder. 1094145b7b3cSmrg 1095145b7b3cSmrg# XORG_MACROS_VERSION(required-version) 1096145b7b3cSmrg# ------------------------------------- 1097145b7b3cSmrg# Minimum version: 1.1.0 1098145b7b3cSmrg# 1099145b7b3cSmrg# If you're using a macro added in Version 1.1 or newer, include this in 1100145b7b3cSmrg# your configure.ac with the minimum required version, such as: 1101145b7b3cSmrg# XORG_MACROS_VERSION(1.1) 1102145b7b3cSmrg# 1103578741aaSmrg# To ensure that this macro is defined, also add: 1104578741aaSmrg# m4_ifndef([XORG_MACROS_VERSION], 1105578741aaSmrg# [m4_fatal([must install xorg-macros 1.1 or later before running autoconf/autogen])]) 1106145b7b3cSmrg# 1107145b7b3cSmrg# 1108145b7b3cSmrg# See the "minimum version" comment for each macro you use to see what 1109145b7b3cSmrg# version you require. 1110578741aaSmrgm4_defun([XORG_MACROS_VERSION],[ 1111578741aaSmrgm4_define([vers_have], [1.3.0]) 1112578741aaSmrgm4_define([maj_have], m4_substr(vers_have, 0, m4_index(vers_have, [.]))) 1113578741aaSmrgm4_define([maj_needed], m4_substr([$1], 0, m4_index([$1], [.]))) 1114578741aaSmrgm4_if(m4_cmp(maj_have, maj_needed), 0,, 1115578741aaSmrg [m4_fatal([xorg-macros major version ]maj_needed[ is required but ]vers_have[ found])]) 1116578741aaSmrgm4_if(m4_version_compare(vers_have, [$1]), -1, 1117578741aaSmrg [m4_fatal([xorg-macros version $1 or higher is required but ]vers_have[ found])]) 1118578741aaSmrgm4_undefine([vers_have]) 1119578741aaSmrgm4_undefine([maj_have]) 1120578741aaSmrgm4_undefine([maj_needed]) 1121145b7b3cSmrg]) # XORG_MACROS_VERSION 1122145b7b3cSmrg 1123145b7b3cSmrg# XORG_PROG_RAWCPP() 1124145b7b3cSmrg# ------------------ 1125145b7b3cSmrg# Minimum version: 1.0.0 1126145b7b3cSmrg# 1127145b7b3cSmrg# Find cpp program and necessary flags for use in pre-processing text files 1128145b7b3cSmrg# such as man pages and config files 1129145b7b3cSmrgAC_DEFUN([XORG_PROG_RAWCPP],[ 1130145b7b3cSmrgAC_REQUIRE([AC_PROG_CPP]) 1131145b7b3cSmrgAC_PATH_PROGS(RAWCPP, [cpp], [${CPP}], 1132145b7b3cSmrg [$PATH:/bin:/usr/bin:/usr/lib:/usr/libexec:/usr/ccs/lib:/usr/ccs/lbin:/lib]) 1133145b7b3cSmrg 1134145b7b3cSmrg# Check for flag to avoid builtin definitions - assumes unix is predefined, 1135145b7b3cSmrg# which is not the best choice for supporting other OS'es, but covers most 1136145b7b3cSmrg# of the ones we need for now. 1137145b7b3cSmrgAC_MSG_CHECKING([if $RAWCPP requires -undef]) 1138145b7b3cSmrgAC_LANG_CONFTEST([Does cpp redefine unix ?]) 1139145b7b3cSmrgif test `${RAWCPP} < conftest.$ac_ext | grep -c 'unix'` -eq 1 ; then 1140145b7b3cSmrg AC_MSG_RESULT([no]) 1141145b7b3cSmrgelse 1142145b7b3cSmrg if test `${RAWCPP} -undef < conftest.$ac_ext | grep -c 'unix'` -eq 1 ; then 1143145b7b3cSmrg RAWCPPFLAGS=-undef 1144145b7b3cSmrg AC_MSG_RESULT([yes]) 1145578741aaSmrg # under Cygwin unix is still defined even with -undef 1146578741aaSmrg elif test `${RAWCPP} -undef -ansi < conftest.$ac_ext | grep -c 'unix'` -eq 1 ; then 1147578741aaSmrg RAWCPPFLAGS="-undef -ansi" 1148578741aaSmrg AC_MSG_RESULT([yes, with -ansi]) 1149145b7b3cSmrg else 1150145b7b3cSmrg AC_MSG_ERROR([${RAWCPP} defines unix with or without -undef. I don't know what to do.]) 1151145b7b3cSmrg fi 1152145b7b3cSmrgfi 1153145b7b3cSmrgrm -f conftest.$ac_ext 1154145b7b3cSmrg 1155145b7b3cSmrgAC_MSG_CHECKING([if $RAWCPP requires -traditional]) 1156145b7b3cSmrgAC_LANG_CONFTEST([Does cpp preserve "whitespace"?]) 1157145b7b3cSmrgif test `${RAWCPP} < conftest.$ac_ext | grep -c 'preserve \"'` -eq 1 ; then 1158145b7b3cSmrg AC_MSG_RESULT([no]) 1159145b7b3cSmrgelse 1160145b7b3cSmrg if test `${RAWCPP} -traditional < conftest.$ac_ext | grep -c 'preserve \"'` -eq 1 ; then 1161145b7b3cSmrg RAWCPPFLAGS="${RAWCPPFLAGS} -traditional" 1162145b7b3cSmrg AC_MSG_RESULT([yes]) 1163145b7b3cSmrg else 1164145b7b3cSmrg AC_MSG_ERROR([${RAWCPP} does not preserve whitespace with or without -traditional. I don't know what to do.]) 1165145b7b3cSmrg fi 1166145b7b3cSmrgfi 1167145b7b3cSmrgrm -f conftest.$ac_ext 1168145b7b3cSmrgAC_SUBST(RAWCPPFLAGS) 1169145b7b3cSmrg]) # XORG_PROG_RAWCPP 1170145b7b3cSmrg 1171145b7b3cSmrg# XORG_MANPAGE_SECTIONS() 1172145b7b3cSmrg# ----------------------- 1173145b7b3cSmrg# Minimum version: 1.0.0 1174145b7b3cSmrg# 1175145b7b3cSmrg# Determine which sections man pages go in for the different man page types 1176145b7b3cSmrg# on this OS - replaces *ManSuffix settings in old Imake *.cf per-os files. 1177145b7b3cSmrg# Not sure if there's any better way than just hardcoding by OS name. 1178145b7b3cSmrg# Override default settings by setting environment variables 1179145b7b3cSmrg 1180145b7b3cSmrgAC_DEFUN([XORG_MANPAGE_SECTIONS],[ 1181145b7b3cSmrgAC_REQUIRE([AC_CANONICAL_HOST]) 1182145b7b3cSmrg 1183145b7b3cSmrgif test x$APP_MAN_SUFFIX = x ; then 1184145b7b3cSmrg APP_MAN_SUFFIX=1 1185145b7b3cSmrgfi 1186145b7b3cSmrgif test x$APP_MAN_DIR = x ; then 1187145b7b3cSmrg APP_MAN_DIR='$(mandir)/man$(APP_MAN_SUFFIX)' 1188145b7b3cSmrgfi 1189145b7b3cSmrg 1190145b7b3cSmrgif test x$LIB_MAN_SUFFIX = x ; then 1191145b7b3cSmrg LIB_MAN_SUFFIX=3 1192145b7b3cSmrgfi 1193145b7b3cSmrgif test x$LIB_MAN_DIR = x ; then 1194145b7b3cSmrg LIB_MAN_DIR='$(mandir)/man$(LIB_MAN_SUFFIX)' 1195145b7b3cSmrgfi 1196145b7b3cSmrg 1197145b7b3cSmrgif test x$FILE_MAN_SUFFIX = x ; then 1198145b7b3cSmrg case $host_os in 1199145b7b3cSmrg solaris*) FILE_MAN_SUFFIX=4 ;; 1200145b7b3cSmrg *) FILE_MAN_SUFFIX=5 ;; 1201145b7b3cSmrg esac 1202145b7b3cSmrgfi 1203145b7b3cSmrgif test x$FILE_MAN_DIR = x ; then 1204145b7b3cSmrg FILE_MAN_DIR='$(mandir)/man$(FILE_MAN_SUFFIX)' 1205145b7b3cSmrgfi 1206145b7b3cSmrg 1207145b7b3cSmrgif test x$MISC_MAN_SUFFIX = x ; then 1208145b7b3cSmrg case $host_os in 1209145b7b3cSmrg solaris*) MISC_MAN_SUFFIX=5 ;; 1210145b7b3cSmrg *) MISC_MAN_SUFFIX=7 ;; 1211145b7b3cSmrg esac 1212145b7b3cSmrgfi 1213145b7b3cSmrgif test x$MISC_MAN_DIR = x ; then 1214145b7b3cSmrg MISC_MAN_DIR='$(mandir)/man$(MISC_MAN_SUFFIX)' 1215145b7b3cSmrgfi 1216145b7b3cSmrg 1217145b7b3cSmrgif test x$DRIVER_MAN_SUFFIX = x ; then 1218145b7b3cSmrg case $host_os in 1219145b7b3cSmrg solaris*) DRIVER_MAN_SUFFIX=7 ;; 1220145b7b3cSmrg *) DRIVER_MAN_SUFFIX=4 ;; 1221145b7b3cSmrg esac 1222145b7b3cSmrgfi 1223145b7b3cSmrgif test x$DRIVER_MAN_DIR = x ; then 1224145b7b3cSmrg DRIVER_MAN_DIR='$(mandir)/man$(DRIVER_MAN_SUFFIX)' 1225145b7b3cSmrgfi 1226145b7b3cSmrg 1227145b7b3cSmrgif test x$ADMIN_MAN_SUFFIX = x ; then 1228145b7b3cSmrg case $host_os in 1229145b7b3cSmrg solaris*) ADMIN_MAN_SUFFIX=1m ;; 1230145b7b3cSmrg *) ADMIN_MAN_SUFFIX=8 ;; 1231145b7b3cSmrg esac 1232145b7b3cSmrgfi 1233145b7b3cSmrgif test x$ADMIN_MAN_DIR = x ; then 1234145b7b3cSmrg ADMIN_MAN_DIR='$(mandir)/man$(ADMIN_MAN_SUFFIX)' 1235145b7b3cSmrgfi 1236145b7b3cSmrg 1237145b7b3cSmrg 1238145b7b3cSmrgAC_SUBST([APP_MAN_SUFFIX]) 1239145b7b3cSmrgAC_SUBST([LIB_MAN_SUFFIX]) 1240145b7b3cSmrgAC_SUBST([FILE_MAN_SUFFIX]) 1241145b7b3cSmrgAC_SUBST([MISC_MAN_SUFFIX]) 1242145b7b3cSmrgAC_SUBST([DRIVER_MAN_SUFFIX]) 1243145b7b3cSmrgAC_SUBST([ADMIN_MAN_SUFFIX]) 1244145b7b3cSmrgAC_SUBST([APP_MAN_DIR]) 1245145b7b3cSmrgAC_SUBST([LIB_MAN_DIR]) 1246145b7b3cSmrgAC_SUBST([FILE_MAN_DIR]) 1247145b7b3cSmrgAC_SUBST([MISC_MAN_DIR]) 1248145b7b3cSmrgAC_SUBST([DRIVER_MAN_DIR]) 1249145b7b3cSmrgAC_SUBST([ADMIN_MAN_DIR]) 1250145b7b3cSmrg]) # XORG_MANPAGE_SECTIONS 1251145b7b3cSmrg 1252145b7b3cSmrg# XORG_CHECK_LINUXDOC 1253145b7b3cSmrg# ------------------- 1254145b7b3cSmrg# Minimum version: 1.0.0 1255145b7b3cSmrg# 1256145b7b3cSmrg# Defines the variable MAKE_TEXT if the necessary tools and 1257145b7b3cSmrg# files are found. $(MAKE_TEXT) blah.sgml will then produce blah.txt. 1258145b7b3cSmrg# Whether or not the necessary tools and files are found can be checked 1259145b7b3cSmrg# with the AM_CONDITIONAL "BUILD_LINUXDOC" 1260145b7b3cSmrgAC_DEFUN([XORG_CHECK_LINUXDOC],[ 1261578741aaSmrgif test x$XORG_SGML_PATH = x ; then 1262578741aaSmrg XORG_SGML_PATH=$prefix/share/sgml 1263578741aaSmrgfi 1264145b7b3cSmrgHAVE_DEFS_ENT= 1265145b7b3cSmrg 1266145b7b3cSmrgif test x"$cross_compiling" = x"yes" ; then 1267145b7b3cSmrg HAVE_DEFS_ENT=no 1268145b7b3cSmrgelse 1269145b7b3cSmrg AC_CHECK_FILE([$XORG_SGML_PATH/X11/defs.ent], [HAVE_DEFS_ENT=yes]) 1270145b7b3cSmrgfi 1271145b7b3cSmrg 1272145b7b3cSmrgAC_PATH_PROG(LINUXDOC, linuxdoc) 1273145b7b3cSmrgAC_PATH_PROG(PS2PDF, ps2pdf) 1274145b7b3cSmrg 1275145b7b3cSmrgAC_MSG_CHECKING([Whether to build documentation]) 1276145b7b3cSmrg 1277145b7b3cSmrgif test x$HAVE_DEFS_ENT != x && test x$LINUXDOC != x ; then 1278145b7b3cSmrg BUILDDOC=yes 1279145b7b3cSmrgelse 1280145b7b3cSmrg BUILDDOC=no 1281145b7b3cSmrgfi 1282145b7b3cSmrg 1283145b7b3cSmrgAM_CONDITIONAL(BUILD_LINUXDOC, [test x$BUILDDOC = xyes]) 1284145b7b3cSmrg 1285145b7b3cSmrgAC_MSG_RESULT([$BUILDDOC]) 1286145b7b3cSmrg 1287145b7b3cSmrgAC_MSG_CHECKING([Whether to build pdf documentation]) 1288145b7b3cSmrg 1289145b7b3cSmrgif test x$PS2PDF != x && test x$BUILD_PDFDOC != xno; then 1290145b7b3cSmrg BUILDPDFDOC=yes 1291145b7b3cSmrgelse 1292145b7b3cSmrg BUILDPDFDOC=no 1293145b7b3cSmrgfi 1294145b7b3cSmrg 1295145b7b3cSmrgAM_CONDITIONAL(BUILD_PDFDOC, [test x$BUILDPDFDOC = xyes]) 1296145b7b3cSmrg 1297145b7b3cSmrgAC_MSG_RESULT([$BUILDPDFDOC]) 1298145b7b3cSmrg 1299145b7b3cSmrgMAKE_TEXT="SGML_SEARCH_PATH=$XORG_SGML_PATH GROFF_NO_SGR=y $LINUXDOC -B txt" 1300145b7b3cSmrgMAKE_PS="SGML_SEARCH_PATH=$XORG_SGML_PATH $LINUXDOC -B latex --papersize=letter --output=ps" 1301145b7b3cSmrgMAKE_PDF="$PS2PDF" 1302145b7b3cSmrgMAKE_HTML="SGML_SEARCH_PATH=$XORG_SGML_PATH $LINUXDOC -B html --split=0" 1303145b7b3cSmrg 1304145b7b3cSmrgAC_SUBST(MAKE_TEXT) 1305145b7b3cSmrgAC_SUBST(MAKE_PS) 1306145b7b3cSmrgAC_SUBST(MAKE_PDF) 1307145b7b3cSmrgAC_SUBST(MAKE_HTML) 1308145b7b3cSmrg]) # XORG_CHECK_LINUXDOC 1309145b7b3cSmrg 1310145b7b3cSmrg# XORG_CHECK_DOCBOOK 1311145b7b3cSmrg# ------------------- 1312145b7b3cSmrg# Minimum version: 1.0.0 1313145b7b3cSmrg# 1314145b7b3cSmrg# Checks for the ability to build output formats from SGML DocBook source. 1315145b7b3cSmrg# For XXX in {TXT, PDF, PS, HTML}, the AM_CONDITIONAL "BUILD_XXXDOC" 1316145b7b3cSmrg# indicates whether the necessary tools and files are found and, if set, 1317145b7b3cSmrg# $(MAKE_XXX) blah.sgml will produce blah.xxx. 1318145b7b3cSmrgAC_DEFUN([XORG_CHECK_DOCBOOK],[ 1319578741aaSmrgif test x$XORG_SGML_PATH = x ; then 1320578741aaSmrg XORG_SGML_PATH=$prefix/share/sgml 1321578741aaSmrgfi 1322145b7b3cSmrgHAVE_DEFS_ENT= 1323145b7b3cSmrgBUILDTXTDOC=no 1324145b7b3cSmrgBUILDPDFDOC=no 1325145b7b3cSmrgBUILDPSDOC=no 1326145b7b3cSmrgBUILDHTMLDOC=no 1327145b7b3cSmrg 1328145b7b3cSmrgAC_CHECK_FILE([$XORG_SGML_PATH/X11/defs.ent], [HAVE_DEFS_ENT=yes]) 1329145b7b3cSmrg 1330145b7b3cSmrgAC_PATH_PROG(DOCBOOKPS, docbook2ps) 1331145b7b3cSmrgAC_PATH_PROG(DOCBOOKPDF, docbook2pdf) 1332145b7b3cSmrgAC_PATH_PROG(DOCBOOKHTML, docbook2html) 1333145b7b3cSmrgAC_PATH_PROG(DOCBOOKTXT, docbook2txt) 1334145b7b3cSmrg 1335145b7b3cSmrgAC_MSG_CHECKING([Whether to build text documentation]) 1336145b7b3cSmrgif test x$HAVE_DEFS_ENT != x && test x$DOCBOOKTXT != x && 1337145b7b3cSmrg test x$BUILD_TXTDOC != xno; then 1338145b7b3cSmrg BUILDTXTDOC=yes 1339145b7b3cSmrgfi 1340145b7b3cSmrgAM_CONDITIONAL(BUILD_TXTDOC, [test x$BUILDTXTDOC = xyes]) 1341145b7b3cSmrgAC_MSG_RESULT([$BUILDTXTDOC]) 1342145b7b3cSmrg 1343145b7b3cSmrgAC_MSG_CHECKING([Whether to build PDF documentation]) 1344145b7b3cSmrgif test x$HAVE_DEFS_ENT != x && test x$DOCBOOKPDF != x && 1345145b7b3cSmrg test x$BUILD_PDFDOC != xno; then 1346145b7b3cSmrg BUILDPDFDOC=yes 1347145b7b3cSmrgfi 1348145b7b3cSmrgAM_CONDITIONAL(BUILD_PDFDOC, [test x$BUILDPDFDOC = xyes]) 1349145b7b3cSmrgAC_MSG_RESULT([$BUILDPDFDOC]) 1350145b7b3cSmrg 1351145b7b3cSmrgAC_MSG_CHECKING([Whether to build PostScript documentation]) 1352145b7b3cSmrgif test x$HAVE_DEFS_ENT != x && test x$DOCBOOKPS != x && 1353145b7b3cSmrg test x$BUILD_PSDOC != xno; then 1354145b7b3cSmrg BUILDPSDOC=yes 1355145b7b3cSmrgfi 1356145b7b3cSmrgAM_CONDITIONAL(BUILD_PSDOC, [test x$BUILDPSDOC = xyes]) 1357145b7b3cSmrgAC_MSG_RESULT([$BUILDPSDOC]) 1358145b7b3cSmrg 1359145b7b3cSmrgAC_MSG_CHECKING([Whether to build HTML documentation]) 1360145b7b3cSmrgif test x$HAVE_DEFS_ENT != x && test x$DOCBOOKHTML != x && 1361145b7b3cSmrg test x$BUILD_HTMLDOC != xno; then 1362145b7b3cSmrg BUILDHTMLDOC=yes 1363145b7b3cSmrgfi 1364145b7b3cSmrgAM_CONDITIONAL(BUILD_HTMLDOC, [test x$BUILDHTMLDOC = xyes]) 1365145b7b3cSmrgAC_MSG_RESULT([$BUILDHTMLDOC]) 1366145b7b3cSmrg 1367145b7b3cSmrgMAKE_TEXT="SGML_SEARCH_PATH=$XORG_SGML_PATH $DOCBOOKTXT" 1368145b7b3cSmrgMAKE_PS="SGML_SEARCH_PATH=$XORG_SGML_PATH $DOCBOOKPS" 1369145b7b3cSmrgMAKE_PDF="SGML_SEARCH_PATH=$XORG_SGML_PATH $DOCBOOKPDF" 1370145b7b3cSmrgMAKE_HTML="SGML_SEARCH_PATH=$XORG_SGML_PATH $DOCBOOKHTML" 1371145b7b3cSmrg 1372145b7b3cSmrgAC_SUBST(MAKE_TEXT) 1373145b7b3cSmrgAC_SUBST(MAKE_PS) 1374145b7b3cSmrgAC_SUBST(MAKE_PDF) 1375145b7b3cSmrgAC_SUBST(MAKE_HTML) 1376145b7b3cSmrg]) # XORG_CHECK_DOCBOOK 1377145b7b3cSmrg 1378145b7b3cSmrg# XORG_CHECK_MALLOC_ZERO 1379145b7b3cSmrg# ---------------------- 1380145b7b3cSmrg# Minimum version: 1.0.0 1381145b7b3cSmrg# 1382145b7b3cSmrg# Defines {MALLOC,XMALLOC,XTMALLOC}_ZERO_CFLAGS appropriately if 1383145b7b3cSmrg# malloc(0) returns NULL. Packages should add one of these cflags to 1384145b7b3cSmrg# their AM_CFLAGS (or other appropriate *_CFLAGS) to use them. 1385145b7b3cSmrgAC_DEFUN([XORG_CHECK_MALLOC_ZERO],[ 1386145b7b3cSmrgAC_ARG_ENABLE(malloc0returnsnull, 1387578741aaSmrg AS_HELP_STRING([--enable-malloc0returnsnull], 1388145b7b3cSmrg [malloc(0) returns NULL (default: auto)]), 1389145b7b3cSmrg [MALLOC_ZERO_RETURNS_NULL=$enableval], 1390145b7b3cSmrg [MALLOC_ZERO_RETURNS_NULL=auto]) 1391145b7b3cSmrg 1392145b7b3cSmrgAC_MSG_CHECKING([whether malloc(0) returns NULL]) 1393145b7b3cSmrgif test "x$MALLOC_ZERO_RETURNS_NULL" = xauto; then 1394145b7b3cSmrg AC_RUN_IFELSE([ 1395145b7b3cSmrgchar *malloc(); 1396145b7b3cSmrgchar *realloc(); 1397145b7b3cSmrgchar *calloc(); 1398145b7b3cSmrgmain() { 1399145b7b3cSmrg char *m0, *r0, *c0, *p; 1400145b7b3cSmrg m0 = malloc(0); 1401145b7b3cSmrg p = malloc(10); 1402145b7b3cSmrg r0 = realloc(p,0); 1403145b7b3cSmrg c0 = calloc(0); 1404145b7b3cSmrg exit(m0 == 0 || r0 == 0 || c0 == 0 ? 0 : 1); 1405145b7b3cSmrg}], 1406145b7b3cSmrg [MALLOC_ZERO_RETURNS_NULL=yes], 1407145b7b3cSmrg [MALLOC_ZERO_RETURNS_NULL=no]) 1408145b7b3cSmrgfi 1409145b7b3cSmrgAC_MSG_RESULT([$MALLOC_ZERO_RETURNS_NULL]) 1410145b7b3cSmrg 1411145b7b3cSmrgif test "x$MALLOC_ZERO_RETURNS_NULL" = xyes; then 1412145b7b3cSmrg MALLOC_ZERO_CFLAGS="-DMALLOC_0_RETURNS_NULL" 1413145b7b3cSmrg XMALLOC_ZERO_CFLAGS=$MALLOC_ZERO_CFLAGS 1414145b7b3cSmrg XTMALLOC_ZERO_CFLAGS="$MALLOC_ZERO_CFLAGS -DXTMALLOC_BC" 1415145b7b3cSmrgelse 1416145b7b3cSmrg MALLOC_ZERO_CFLAGS="" 1417145b7b3cSmrg XMALLOC_ZERO_CFLAGS="" 1418145b7b3cSmrg XTMALLOC_ZERO_CFLAGS="" 1419145b7b3cSmrgfi 1420145b7b3cSmrg 1421145b7b3cSmrgAC_SUBST([MALLOC_ZERO_CFLAGS]) 1422145b7b3cSmrgAC_SUBST([XMALLOC_ZERO_CFLAGS]) 1423145b7b3cSmrgAC_SUBST([XTMALLOC_ZERO_CFLAGS]) 1424145b7b3cSmrg]) # XORG_CHECK_MALLOC_ZERO 1425145b7b3cSmrg 1426145b7b3cSmrg# XORG_WITH_LINT() 1427145b7b3cSmrg# ---------------- 1428145b7b3cSmrg# Minimum version: 1.1.0 1429145b7b3cSmrg# 1430145b7b3cSmrg# Sets up flags for source checkers such as lint and sparse if --with-lint 1431145b7b3cSmrg# is specified. (Use --with-lint=sparse for sparse.) 1432145b7b3cSmrg# Sets $LINT to name of source checker passed with --with-lint (default: lint) 1433145b7b3cSmrg# Sets $LINT_FLAGS to flags to pass to source checker 1434145b7b3cSmrg# Sets LINT automake conditional if enabled (default: disabled) 1435145b7b3cSmrg# 1436145b7b3cSmrgAC_DEFUN([XORG_WITH_LINT],[ 1437145b7b3cSmrg 1438145b7b3cSmrg# Allow checking code with lint, sparse, etc. 1439578741aaSmrgAC_ARG_WITH(lint, [AS_HELP_STRING([--with-lint], 1440145b7b3cSmrg [Use a lint-style source code checker (default: disabled)])], 1441145b7b3cSmrg [use_lint=$withval], [use_lint=no]) 1442145b7b3cSmrgif test "x$use_lint" = "xyes" ; then 1443145b7b3cSmrg LINT="lint" 1444145b7b3cSmrgelse 1445145b7b3cSmrg LINT="$use_lint" 1446145b7b3cSmrgfi 1447145b7b3cSmrgif test "x$LINT_FLAGS" = "x" -a "x$LINT" != "xno" ; then 1448145b7b3cSmrg case $LINT in 1449145b7b3cSmrg lint|*/lint) 1450145b7b3cSmrg case $host_os in 1451145b7b3cSmrg solaris*) 1452145b7b3cSmrg LINT_FLAGS="-u -b -h -erroff=E_INDISTING_FROM_TRUNC2" 1453145b7b3cSmrg ;; 1454145b7b3cSmrg esac 1455145b7b3cSmrg ;; 1456145b7b3cSmrg esac 1457145b7b3cSmrgfi 1458145b7b3cSmrg 1459145b7b3cSmrgAC_SUBST(LINT) 1460145b7b3cSmrgAC_SUBST(LINT_FLAGS) 1461145b7b3cSmrgAM_CONDITIONAL(LINT, [test x$LINT != xno]) 1462145b7b3cSmrg 1463145b7b3cSmrg]) # XORG_WITH_LINT 1464145b7b3cSmrg 1465145b7b3cSmrg# XORG_LINT_LIBRARY(LIBNAME) 1466145b7b3cSmrg# -------------------------- 1467145b7b3cSmrg# Minimum version: 1.1.0 1468145b7b3cSmrg# 1469145b7b3cSmrg# Sets up flags for building lint libraries for checking programs that call 1470145b7b3cSmrg# functions in the library. 1471145b7b3cSmrg# Disabled by default, enable with --enable-lint-library 1472145b7b3cSmrg# Sets: 1473145b7b3cSmrg# @LINTLIB@ - name of lint library file to make 1474145b7b3cSmrg# MAKE_LINT_LIB - automake conditional 1475145b7b3cSmrg# 1476145b7b3cSmrg 1477145b7b3cSmrgAC_DEFUN([XORG_LINT_LIBRARY],[ 1478145b7b3cSmrgAC_REQUIRE([XORG_WITH_LINT]) 1479145b7b3cSmrg# Build lint "library" for more indepth checks of programs calling this library 1480578741aaSmrgAC_ARG_ENABLE(lint-library, [AS_HELP_STRING([--enable-lint-library], 1481145b7b3cSmrg [Create lint library (default: disabled)])], 1482145b7b3cSmrg [make_lint_lib=$enableval], [make_lint_lib=no]) 1483145b7b3cSmrgif test "x$make_lint_lib" != "xno" ; then 1484145b7b3cSmrg if test "x$LINT" = "xno" ; then 1485145b7b3cSmrg AC_MSG_ERROR([Cannot make lint library without --with-lint]) 1486145b7b3cSmrg fi 1487145b7b3cSmrg if test "x$make_lint_lib" = "xyes" ; then 1488145b7b3cSmrg LINTLIB=llib-l$1.ln 1489145b7b3cSmrg else 1490145b7b3cSmrg LINTLIB=$make_lint_lib 1491145b7b3cSmrg fi 1492145b7b3cSmrgfi 1493145b7b3cSmrgAC_SUBST(LINTLIB) 1494145b7b3cSmrgAM_CONDITIONAL(MAKE_LINT_LIB, [test x$make_lint_lib != xno]) 1495145b7b3cSmrg 1496145b7b3cSmrg]) # XORG_LINT_LIBRARY 1497145b7b3cSmrg 1498578741aaSmrg# XORG_CWARNFLAGS 1499578741aaSmrg# --------------- 1500578741aaSmrg# Minimum version: 1.2.0 1501578741aaSmrg# 1502578741aaSmrg# Defines CWARNFLAGS to enable C compiler warnings. 1503578741aaSmrg# 1504578741aaSmrgAC_DEFUN([XORG_CWARNFLAGS], [ 1505578741aaSmrgAC_REQUIRE([AC_PROG_CC]) 1506578741aaSmrgif test "x$GCC" = xyes ; then 1507578741aaSmrg CWARNFLAGS="-Wall -Wpointer-arith -Wstrict-prototypes -Wmissing-prototypes \ 1508578741aaSmrg-Wmissing-declarations -Wnested-externs -fno-strict-aliasing \ 1509578741aaSmrg-Wbad-function-cast" 1510578741aaSmrg case `$CC -dumpversion` in 1511578741aaSmrg 3.4.* | 4.*) 1512578741aaSmrg CWARNFLAGS="$CWARNFLAGS -Wold-style-definition -Wdeclaration-after-statement" 1513578741aaSmrg ;; 1514578741aaSmrg esac 1515578741aaSmrgelse 1516578741aaSmrg AC_CHECK_DECL([__SUNPRO_C], [SUNCC="yes"], [SUNCC="no"]) 1517578741aaSmrg if test "x$SUNCC" = "xyes"; then 1518578741aaSmrg CWARNFLAGS="-v" 1519578741aaSmrg fi 1520578741aaSmrgfi 1521578741aaSmrgAC_SUBST(CWARNFLAGS) 1522578741aaSmrgm4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])]) 1523578741aaSmrg]) # XORG_CWARNFLAGS 1524578741aaSmrg 1525578741aaSmrg# XORG_STRICT_OPTION 1526578741aaSmrg# ----------------------- 1527578741aaSmrg# Minimum version: 1.3.0 1528578741aaSmrg# 1529578741aaSmrg# Add configure option to enable strict compilation 1530578741aaSmrgAC_DEFUN([XORG_STRICT_OPTION], [ 1531578741aaSmrgAC_REQUIRE([AC_PROG_CC]) 1532578741aaSmrgAC_REQUIRE([AC_PROG_CC_C99]) 1533578741aaSmrgAC_REQUIRE([XORG_CWARNFLAGS]) 1534578741aaSmrg 1535578741aaSmrgAC_ARG_ENABLE(strict-compilation, 1536578741aaSmrg AS_HELP_STRING([--enable-strict-compilation], 1537578741aaSmrg [Enable all warnings from compiler and make them errors (default: disabled)]), 1538578741aaSmrg [STRICT_COMPILE=$enableval], [STRICT_COMPILE=no]) 1539578741aaSmrgif test "x$STRICT_COMPILE" = "xyes"; then 1540578741aaSmrg AC_CHECK_DECL([__SUNPRO_C], [SUNCC="yes"], [SUNCC="no"]) 1541578741aaSmrg AC_CHECK_DECL([__INTEL_COMPILER], [INTELCC="yes"], [INTELCC="no"]) 1542578741aaSmrg if test "x$GCC" = xyes ; then 1543578741aaSmrg STRICT_CFLAGS="-pedantic -Werror" 1544578741aaSmrg elif test "x$SUNCC" = "xyes"; then 1545578741aaSmrg STRICT_CFLAGS="-errwarn" 1546578741aaSmrg elif test "x$INTELCC" = "xyes"; then 1547578741aaSmrg STRICT_CFLAGS="-Werror" 1548578741aaSmrg fi 1549578741aaSmrgfi 1550578741aaSmrgCWARNFLAGS="$CWARNFLAGS $STRICT_CFLAGS" 1551578741aaSmrgAC_SUBST([CWARNFLAGS]) 1552578741aaSmrg]) # XORG_STRICT_OPTION 1553578741aaSmrg 1554578741aaSmrg# XORG_DEFAULT_OPTIONS 1555578741aaSmrg# -------------------- 1556578741aaSmrg# Minimum version: 1.3.0 1557578741aaSmrg# 1558578741aaSmrg# Defines default options for X.Org modules. 1559578741aaSmrg# 1560578741aaSmrgAC_DEFUN([XORG_DEFAULT_OPTIONS], [ 1561578741aaSmrgXORG_CWARNFLAGS 1562578741aaSmrgXORG_STRICT_OPTION 1563578741aaSmrgXORG_RELEASE_VERSION 1564578741aaSmrgXORG_CHANGELOG 1565578741aaSmrgXORG_MANPAGE_SECTIONS 1566578741aaSmrg]) # XORG_DEFAULT_OPTIONS 1567145b7b3cSmrgdnl Copyright 2005 Red Hat, Inc 1568145b7b3cSmrgdnl 1569145b7b3cSmrgdnl Permission to use, copy, modify, distribute, and sell this software and its 1570145b7b3cSmrgdnl documentation for any purpose is hereby granted without fee, provided that 1571145b7b3cSmrgdnl the above copyright notice appear in all copies and that both that 1572145b7b3cSmrgdnl copyright notice and this permission notice appear in supporting 1573145b7b3cSmrgdnl documentation. 1574145b7b3cSmrgdnl 1575145b7b3cSmrgdnl The above copyright notice and this permission notice shall be included 1576145b7b3cSmrgdnl in all copies or substantial portions of the Software. 1577145b7b3cSmrgdnl 1578145b7b3cSmrgdnl THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS 1579145b7b3cSmrgdnl OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 1580145b7b3cSmrgdnl MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 1581145b7b3cSmrgdnl IN NO EVENT SHALL THE OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR 1582145b7b3cSmrgdnl OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, 1583145b7b3cSmrgdnl ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 1584145b7b3cSmrgdnl OTHER DEALINGS IN THE SOFTWARE. 1585145b7b3cSmrgdnl 1586145b7b3cSmrgdnl Except as contained in this notice, the name of the copyright holders shall 1587145b7b3cSmrgdnl not be used in advertising or otherwise to promote the sale, use or 1588145b7b3cSmrgdnl other dealings in this Software without prior written authorization 1589145b7b3cSmrgdnl from the copyright holders. 1590145b7b3cSmrgdnl 1591145b7b3cSmrg 1592145b7b3cSmrg# XORG_RELEASE_VERSION 1593145b7b3cSmrg# -------------------- 1594145b7b3cSmrg# Adds --with/without-release-string and changes the PACKAGE and 1595145b7b3cSmrg# PACKAGE_TARNAME to use "$PACKAGE{_TARNAME}-$RELEASE_VERSION". If 1596145b7b3cSmrg# no option is given, PACKAGE and PACKAGE_TARNAME are unchanged. Also 1597145b7b3cSmrg# defines PACKAGE_VERSION_{MAJOR,MINOR,PATCHLEVEL} for modules to use. 1598145b7b3cSmrg 1599145b7b3cSmrgAC_DEFUN([XORG_RELEASE_VERSION],[ 1600145b7b3cSmrg AC_ARG_WITH(release-version, 1601578741aaSmrg AS_HELP_STRING([--with-release-version=STRING], 1602145b7b3cSmrg [Use release version string in package name]), 1603145b7b3cSmrg [RELEASE_VERSION="$withval"], 1604145b7b3cSmrg [RELEASE_VERSION=""]) 1605145b7b3cSmrg if test "x$RELEASE_VERSION" != "x"; then 1606145b7b3cSmrg PACKAGE="$PACKAGE-$RELEASE_VERSION" 1607145b7b3cSmrg PACKAGE_TARNAME="$PACKAGE_TARNAME-$RELEASE_VERSION" 1608145b7b3cSmrg AC_MSG_NOTICE([Building with package name set to $PACKAGE]) 1609145b7b3cSmrg fi 1610145b7b3cSmrg AC_DEFINE_UNQUOTED([PACKAGE_VERSION_MAJOR], 1611145b7b3cSmrg [`echo $PACKAGE_VERSION | cut -d . -f 1`], 1612145b7b3cSmrg [Major version of this package]) 1613578741aaSmrg PVM=`echo $PACKAGE_VERSION | cut -d . -f 2 | cut -d - -f 1` 1614145b7b3cSmrg if test "x$PVM" = "x"; then 1615145b7b3cSmrg PVM="0" 1616145b7b3cSmrg fi 1617145b7b3cSmrg AC_DEFINE_UNQUOTED([PACKAGE_VERSION_MINOR], 1618145b7b3cSmrg [$PVM], 1619145b7b3cSmrg [Minor version of this package]) 1620578741aaSmrg PVP=`echo $PACKAGE_VERSION | cut -d . -f 3 | cut -d - -f 1` 1621145b7b3cSmrg if test "x$PVP" = "x"; then 1622145b7b3cSmrg PVP="0" 1623145b7b3cSmrg fi 1624145b7b3cSmrg AC_DEFINE_UNQUOTED([PACKAGE_VERSION_PATCHLEVEL], 1625145b7b3cSmrg [$PVP], 1626145b7b3cSmrg [Patch version of this package]) 1627145b7b3cSmrg]) 1628145b7b3cSmrg 1629578741aaSmrg# XORG_CHANGELOG() 1630578741aaSmrg# ---------------- 1631578741aaSmrg# Minimum version: 1.2.0 1632578741aaSmrg# 1633578741aaSmrg# Defines the variable CHANGELOG_CMD as the command to generate 1634578741aaSmrg# ChangeLog from git. 1635578741aaSmrg# 1636578741aaSmrg# Arrange that distcleancheck ignores ChangeLog left over by distclean. 1637578741aaSmrg# 1638578741aaSmrgAC_DEFUN([XORG_CHANGELOG], [ 1639578741aaSmrgCHANGELOG_CMD="(GIT_DIR=\$(top_srcdir)/.git git log > .changelog.tmp && \ 1640578741aaSmrgmv .changelog.tmp ChangeLog) || (rm -f .changelog.tmp; touch ChangeLog; \ 1641578741aaSmrgecho 'git directory not found: installing possibly empty changelog.' >&2)" 1642578741aaSmrgAC_SUBST([CHANGELOG_CMD]) 1643578741aaSmrgAC_SUBST([distcleancheck_listfiles], ['find . -type f ! -name ChangeLog -print']) 1644578741aaSmrg]) # XORG_CHANGELOG 1645578741aaSmrg 1646145b7b3cSmrgdnl $XdotOrg: lib/xtrans/xtrans.m4,v 1.6 2005/07/26 18:59:11 alanc Exp $ 1647145b7b3cSmrgdnl 1648145b7b3cSmrgdnl Copyright 2005 Sun Microsystems, Inc. All rights reserved. 1649145b7b3cSmrgdnl 1650145b7b3cSmrgdnl Permission to use, copy, modify, distribute, and sell this software and its 1651145b7b3cSmrgdnl documentation for any purpose is hereby granted without fee, provided that 1652145b7b3cSmrgdnl the above copyright notice appear in all copies and that both that 1653145b7b3cSmrgdnl copyright notice and this permission notice appear in supporting 1654145b7b3cSmrgdnl documentation. 1655145b7b3cSmrgdnl 1656145b7b3cSmrgdnl The above copyright notice and this permission notice shall be included 1657145b7b3cSmrgdnl in all copies or substantial portions of the Software. 1658145b7b3cSmrgdnl 1659145b7b3cSmrgdnl THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS 1660145b7b3cSmrgdnl OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 1661145b7b3cSmrgdnl MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 1662145b7b3cSmrgdnl IN NO EVENT SHALL THE OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR 1663145b7b3cSmrgdnl OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, 1664145b7b3cSmrgdnl ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 1665145b7b3cSmrgdnl OTHER DEALINGS IN THE SOFTWARE. 1666145b7b3cSmrgdnl 1667145b7b3cSmrgdnl Except as contained in this notice, the name of the copyright holders shall 1668145b7b3cSmrgdnl not be used in advertising or otherwise to promote the sale, use or 1669145b7b3cSmrgdnl other dealings in this Software without prior written authorization 1670145b7b3cSmrgdnl from the copyright holders. 1671145b7b3cSmrgdnl 1672145b7b3cSmrg 1673145b7b3cSmrg# XTRANS_TCP_FLAGS() 1674145b7b3cSmrg# ------------------ 1675145b7b3cSmrg# Find needed libraries for TCP sockets, and check for IPv6 support 1676145b7b3cSmrgAC_DEFUN([XTRANS_TCP_FLAGS],[ 1677145b7b3cSmrg # SVR4 hides these in libraries other than libc 1678145b7b3cSmrg AC_SEARCH_LIBS(socket, [socket]) 1679145b7b3cSmrg AC_SEARCH_LIBS(gethostbyname, [nsl]) 1680578741aaSmrg AC_HAVE_LIBRARY([ws2_32]) 1681145b7b3cSmrg 1682145b7b3cSmrg # Needs to come after above checks for libsocket & libnsl for SVR4 systems 1683145b7b3cSmrg AC_ARG_ENABLE(ipv6, 1684578741aaSmrg AC_HELP_STRING([--enable-ipv6],[Enable IPv6 support]), 1685145b7b3cSmrg [IPV6CONN=$enableval], 1686145b7b3cSmrg [AC_CHECK_FUNC(getaddrinfo,[IPV6CONN=yes],[IPV6CONN=no])]) 1687145b7b3cSmrg AC_MSG_CHECKING([if IPv6 support should be built]) 1688145b7b3cSmrg if test "$IPV6CONN" = "yes"; then 1689145b7b3cSmrg AC_DEFINE(IPv6,1,[Support IPv6 for TCP connections]) 1690145b7b3cSmrg fi 1691145b7b3cSmrg AC_MSG_RESULT($IPV6CONN) 1692145b7b3cSmrg 1693145b7b3cSmrg # 4.3BSD-Reno added a new member to struct sockaddr_in 1694145b7b3cSmrg AC_CHECK_MEMBER([struct sockaddr_in.sin_len], 1695145b7b3cSmrg AC_DEFINE([BSD44SOCKETS],1, 1696145b7b3cSmrg [Define to 1 if `struct sockaddr_in' has a `sin_len' member]), [], [ 1697145b7b3cSmrg#include <sys/types.h> 1698145b7b3cSmrg#include <sys/socket.h> 1699145b7b3cSmrg#include <netinet/in.h> 1700145b7b3cSmrg ]) 1701578741aaSmrg 1702578741aaSmrg # POSIX.1g changed the type of pointer passed to getsockname/getpeername/etc. 1703578741aaSmrg AC_CHECK_TYPES([socklen_t], [], [], [ 1704578741aaSmrgAC_INCLUDES_DEFAULT 1705578741aaSmrg#include <sys/socket.h>]) 1706578741aaSmrg 1707145b7b3cSmrg]) # XTRANS_TCP_FLAGS 1708145b7b3cSmrg 1709145b7b3cSmrg# XTRANS_CONNECTION_FLAGS() 1710145b7b3cSmrg# ------------------------- 1711145b7b3cSmrg# Standard checks for which Xtrans transports to use by the Xorg packages 1712145b7b3cSmrg# that use Xtrans functions 1713145b7b3cSmrgAC_DEFUN([XTRANS_CONNECTION_FLAGS],[ 1714145b7b3cSmrg AC_REQUIRE([AC_CANONICAL_HOST]) 1715145b7b3cSmrg AC_REQUIRE([AC_TYPE_SIGNAL]) 1716578741aaSmrg [case $host_os in 1717578741aaSmrg mingw*) unixdef="no" ;; 1718578741aaSmrg *) unixdef="yes" ;; 1719578741aaSmrg esac] 1720145b7b3cSmrg AC_ARG_ENABLE(unix-transport, 1721145b7b3cSmrg AC_HELP_STRING([--enable-unix-transport],[Enable UNIX domain socket transport]), 1722578741aaSmrg [UNIXCONN=$enableval], [UNIXCONN=$unixdef]) 1723145b7b3cSmrg AC_MSG_CHECKING([if Xtrans should support UNIX socket connections]) 1724145b7b3cSmrg if test "$UNIXCONN" = "yes"; then 1725145b7b3cSmrg AC_DEFINE(UNIXCONN,1,[Support UNIX socket connections]) 1726145b7b3cSmrg fi 1727145b7b3cSmrg AC_MSG_RESULT($UNIXCONN) 1728578741aaSmrg AC_ARG_ENABLE(tcp-transport, 1729578741aaSmrg AC_HELP_STRING([--enable-tcp-transport],[Enable TCP socket transport]), 1730578741aaSmrg [TCPCONN=$enableval], [TCPCONN=yes]) 1731145b7b3cSmrg AC_MSG_CHECKING([if Xtrans should support TCP socket connections]) 1732145b7b3cSmrg AC_MSG_RESULT($TCPCONN) 1733145b7b3cSmrg if test "$TCPCONN" = "yes"; then 1734145b7b3cSmrg AC_DEFINE(TCPCONN,1,[Support TCP socket connections]) 1735145b7b3cSmrg XTRANS_TCP_FLAGS 1736145b7b3cSmrg fi 1737145b7b3cSmrg [case $host_os in 1738145b7b3cSmrg solaris*|sco*|sysv4*) localdef="yes" ;; 1739145b7b3cSmrg *) localdef="no" ;; 1740145b7b3cSmrg esac] 1741145b7b3cSmrg AC_ARG_ENABLE(local-transport, 1742145b7b3cSmrg AC_HELP_STRING([--enable-local-transport],[Enable os-specific local transport]), 1743145b7b3cSmrg [LOCALCONN=$enableval], [LOCALCONN=$localdef]) 1744145b7b3cSmrg AC_MSG_CHECKING([if Xtrans should support os-specific local connections]) 1745145b7b3cSmrg AC_MSG_RESULT($LOCALCONN) 1746145b7b3cSmrg if test "$LOCALCONN" = "yes"; then 1747145b7b3cSmrg AC_DEFINE(LOCALCONN,1,[Support os-specific local connections]) 1748145b7b3cSmrg fi 1749145b7b3cSmrg 1750145b7b3cSmrg]) # XTRANS_CONNECTION_FLAGS 1751145b7b3cSmrg 1752145b7b3cSmrg 1753145b7b3cSmrg# XTRANS_SECURE_RPC_FLAGS() 1754145b7b3cSmrg# ------------------------- 1755145b7b3cSmrg# Check for Secure RPC functions - must come after XTRANS_TCP_FLAGS 1756145b7b3cSmrg# so that any necessary networking libraries are already found 1757145b7b3cSmrgAC_DEFUN([XTRANS_SECURE_RPC_FLAGS], 1758145b7b3cSmrg[AC_REQUIRE([XTRANS_TCP_FLAGS]) 1759145b7b3cSmrg AC_ARG_ENABLE(secure-rpc, 1760145b7b3cSmrg AC_HELP_STRING([--enable-secure-rpc],[Enable Secure RPC]), 1761145b7b3cSmrg [SECURE_RPC=$enableval], [SECURE_RPC="try"]) 1762145b7b3cSmrg 1763145b7b3cSmrg if test "x$SECURE_RPC" = "xyes" -o "x$SECURE_RPC" = "xtry" ; then 1764145b7b3cSmrg FOUND_SECURE_RPC="no" 1765145b7b3cSmrg AC_CHECK_FUNCS([authdes_seccreate authdes_create], 1766145b7b3cSmrg [FOUND_SECURE_RPC="yes"]) 1767145b7b3cSmrg if test "x$FOUND_SECURE_RPC" = "xno" ; then 1768145b7b3cSmrg if test "x$SECURE_RPC" = "xyes" ; then 1769145b7b3cSmrg AC_MSG_ERROR([Secure RPC requested, but required functions not found]) 1770145b7b3cSmrg fi 1771145b7b3cSmrg SECURE_RPC="no" 1772145b7b3cSmrg else 1773145b7b3cSmrg dnl FreeBSD keeps getsecretkey in librpcsvc 1774145b7b3cSmrg AC_SEARCH_LIBS(getsecretkey, [rpcsvc]) 1775145b7b3cSmrg SECURE_RPC="yes" 1776145b7b3cSmrg fi 1777145b7b3cSmrg fi 1778145b7b3cSmrg AC_MSG_CHECKING([if Secure RPC authentication ("SUN-DES-1") should be supported]) 1779145b7b3cSmrg if test "x$SECURE_RPC" = "xyes" ; then 1780145b7b3cSmrg AC_DEFINE(SECURE_RPC, 1, [Support Secure RPC ("SUN-DES-1") authentication for X11 clients]) 1781145b7b3cSmrg fi 1782145b7b3cSmrg AC_MSG_RESULT($SECURE_RPC) 1783145b7b3cSmrg]) # XTRANS_SECURE_RPC_FLAGS 1784145b7b3cSmrg 1785145b7b3cSmrg 1786145b7b3cSmrg# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*- 1787145b7b3cSmrg 1788578741aaSmrg# serial 52 AC_PROG_LIBTOOL 1789145b7b3cSmrg 1790145b7b3cSmrg 1791145b7b3cSmrg# AC_PROVIDE_IFELSE(MACRO-NAME, IF-PROVIDED, IF-NOT-PROVIDED) 1792145b7b3cSmrg# ----------------------------------------------------------- 1793145b7b3cSmrg# If this macro is not defined by Autoconf, define it here. 1794145b7b3cSmrgm4_ifdef([AC_PROVIDE_IFELSE], 1795145b7b3cSmrg [], 1796145b7b3cSmrg [m4_define([AC_PROVIDE_IFELSE], 1797145b7b3cSmrg [m4_ifdef([AC_PROVIDE_$1], 1798145b7b3cSmrg [$2], [$3])])]) 1799145b7b3cSmrg 1800145b7b3cSmrg 1801145b7b3cSmrg# AC_PROG_LIBTOOL 1802145b7b3cSmrg# --------------- 1803145b7b3cSmrgAC_DEFUN([AC_PROG_LIBTOOL], 1804145b7b3cSmrg[AC_REQUIRE([_AC_PROG_LIBTOOL])dnl 1805145b7b3cSmrgdnl If AC_PROG_CXX has already been expanded, run AC_LIBTOOL_CXX 1806145b7b3cSmrgdnl immediately, otherwise, hook it in at the end of AC_PROG_CXX. 1807145b7b3cSmrg AC_PROVIDE_IFELSE([AC_PROG_CXX], 1808145b7b3cSmrg [AC_LIBTOOL_CXX], 1809145b7b3cSmrg [define([AC_PROG_CXX], defn([AC_PROG_CXX])[AC_LIBTOOL_CXX 1810145b7b3cSmrg ])]) 1811145b7b3cSmrgdnl And a similar setup for Fortran 77 support 1812145b7b3cSmrg AC_PROVIDE_IFELSE([AC_PROG_F77], 1813145b7b3cSmrg [AC_LIBTOOL_F77], 1814145b7b3cSmrg [define([AC_PROG_F77], defn([AC_PROG_F77])[AC_LIBTOOL_F77 1815145b7b3cSmrg])]) 1816145b7b3cSmrg 1817145b7b3cSmrgdnl Quote A][M_PROG_GCJ so that aclocal doesn't bring it in needlessly. 1818145b7b3cSmrgdnl If either AC_PROG_GCJ or A][M_PROG_GCJ have already been expanded, run 1819145b7b3cSmrgdnl AC_LIBTOOL_GCJ immediately, otherwise, hook it in at the end of both. 1820145b7b3cSmrg AC_PROVIDE_IFELSE([AC_PROG_GCJ], 1821145b7b3cSmrg [AC_LIBTOOL_GCJ], 1822145b7b3cSmrg [AC_PROVIDE_IFELSE([A][M_PROG_GCJ], 1823145b7b3cSmrg [AC_LIBTOOL_GCJ], 1824145b7b3cSmrg [AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ], 1825145b7b3cSmrg [AC_LIBTOOL_GCJ], 1826145b7b3cSmrg [ifdef([AC_PROG_GCJ], 1827145b7b3cSmrg [define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[AC_LIBTOOL_GCJ])]) 1828145b7b3cSmrg ifdef([A][M_PROG_GCJ], 1829145b7b3cSmrg [define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[AC_LIBTOOL_GCJ])]) 1830145b7b3cSmrg ifdef([LT_AC_PROG_GCJ], 1831145b7b3cSmrg [define([LT_AC_PROG_GCJ], 1832145b7b3cSmrg defn([LT_AC_PROG_GCJ])[AC_LIBTOOL_GCJ])])])]) 1833145b7b3cSmrg])])# AC_PROG_LIBTOOL 1834145b7b3cSmrg 1835145b7b3cSmrg 1836145b7b3cSmrg# _AC_PROG_LIBTOOL 1837145b7b3cSmrg# ---------------- 1838145b7b3cSmrgAC_DEFUN([_AC_PROG_LIBTOOL], 1839145b7b3cSmrg[AC_REQUIRE([AC_LIBTOOL_SETUP])dnl 1840145b7b3cSmrgAC_BEFORE([$0],[AC_LIBTOOL_CXX])dnl 1841145b7b3cSmrgAC_BEFORE([$0],[AC_LIBTOOL_F77])dnl 1842145b7b3cSmrgAC_BEFORE([$0],[AC_LIBTOOL_GCJ])dnl 1843145b7b3cSmrg 1844145b7b3cSmrg# This can be used to rebuild libtool when needed 1845145b7b3cSmrgLIBTOOL_DEPS="$ac_aux_dir/ltmain.sh" 1846145b7b3cSmrg 1847145b7b3cSmrg# Always use our own libtool. 1848145b7b3cSmrgLIBTOOL='$(SHELL) $(top_builddir)/libtool' 1849145b7b3cSmrgAC_SUBST(LIBTOOL)dnl 1850145b7b3cSmrg 1851145b7b3cSmrg# Prevent multiple expansion 1852145b7b3cSmrgdefine([AC_PROG_LIBTOOL], []) 1853145b7b3cSmrg])# _AC_PROG_LIBTOOL 1854145b7b3cSmrg 1855145b7b3cSmrg 1856145b7b3cSmrg# AC_LIBTOOL_SETUP 1857145b7b3cSmrg# ---------------- 1858145b7b3cSmrgAC_DEFUN([AC_LIBTOOL_SETUP], 1859145b7b3cSmrg[AC_PREREQ(2.50)dnl 1860145b7b3cSmrgAC_REQUIRE([AC_ENABLE_SHARED])dnl 1861145b7b3cSmrgAC_REQUIRE([AC_ENABLE_STATIC])dnl 1862145b7b3cSmrgAC_REQUIRE([AC_ENABLE_FAST_INSTALL])dnl 1863145b7b3cSmrgAC_REQUIRE([AC_CANONICAL_HOST])dnl 1864145b7b3cSmrgAC_REQUIRE([AC_CANONICAL_BUILD])dnl 1865145b7b3cSmrgAC_REQUIRE([AC_PROG_CC])dnl 1866145b7b3cSmrgAC_REQUIRE([AC_PROG_LD])dnl 1867145b7b3cSmrgAC_REQUIRE([AC_PROG_LD_RELOAD_FLAG])dnl 1868145b7b3cSmrgAC_REQUIRE([AC_PROG_NM])dnl 1869145b7b3cSmrg 1870145b7b3cSmrgAC_REQUIRE([AC_PROG_LN_S])dnl 1871145b7b3cSmrgAC_REQUIRE([AC_DEPLIBS_CHECK_METHOD])dnl 1872145b7b3cSmrg# Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers! 1873145b7b3cSmrgAC_REQUIRE([AC_OBJEXT])dnl 1874145b7b3cSmrgAC_REQUIRE([AC_EXEEXT])dnl 1875145b7b3cSmrgdnl 1876145b7b3cSmrgAC_LIBTOOL_SYS_MAX_CMD_LEN 1877145b7b3cSmrgAC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE 1878145b7b3cSmrgAC_LIBTOOL_OBJDIR 1879145b7b3cSmrg 1880145b7b3cSmrgAC_REQUIRE([_LT_AC_SYS_COMPILER])dnl 1881145b7b3cSmrg_LT_AC_PROG_ECHO_BACKSLASH 1882145b7b3cSmrg 1883145b7b3cSmrgcase $host_os in 1884145b7b3cSmrgaix3*) 1885145b7b3cSmrg # AIX sometimes has problems with the GCC collect2 program. For some 1886145b7b3cSmrg # reason, if we set the COLLECT_NAMES environment variable, the problems 1887145b7b3cSmrg # vanish in a puff of smoke. 1888145b7b3cSmrg if test "X${COLLECT_NAMES+set}" != Xset; then 1889145b7b3cSmrg COLLECT_NAMES= 1890145b7b3cSmrg export COLLECT_NAMES 1891145b7b3cSmrg fi 1892145b7b3cSmrg ;; 1893145b7b3cSmrgesac 1894145b7b3cSmrg 1895145b7b3cSmrg# Sed substitution that helps us do robust quoting. It backslashifies 1896145b7b3cSmrg# metacharacters that are still active within double-quoted strings. 1897145b7b3cSmrgXsed='sed -e 1s/^X//' 1898145b7b3cSmrg[sed_quote_subst='s/\([\\"\\`$\\\\]\)/\\\1/g'] 1899145b7b3cSmrg 1900145b7b3cSmrg# Same as above, but do not quote variable references. 1901145b7b3cSmrg[double_quote_subst='s/\([\\"\\`\\\\]\)/\\\1/g'] 1902145b7b3cSmrg 1903145b7b3cSmrg# Sed substitution to delay expansion of an escaped shell variable in a 1904145b7b3cSmrg# double_quote_subst'ed string. 1905145b7b3cSmrgdelay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' 1906145b7b3cSmrg 1907145b7b3cSmrg# Sed substitution to avoid accidental globbing in evaled expressions 1908145b7b3cSmrgno_glob_subst='s/\*/\\\*/g' 1909145b7b3cSmrg 1910145b7b3cSmrg# Constants: 1911145b7b3cSmrgrm="rm -f" 1912145b7b3cSmrg 1913145b7b3cSmrg# Global variables: 1914145b7b3cSmrgdefault_ofile=libtool 1915145b7b3cSmrgcan_build_shared=yes 1916145b7b3cSmrg 1917145b7b3cSmrg# All known linkers require a `.a' archive for static linking (except MSVC, 1918145b7b3cSmrg# which needs '.lib'). 1919145b7b3cSmrglibext=a 1920145b7b3cSmrgltmain="$ac_aux_dir/ltmain.sh" 1921145b7b3cSmrgofile="$default_ofile" 1922145b7b3cSmrgwith_gnu_ld="$lt_cv_prog_gnu_ld" 1923145b7b3cSmrg 1924145b7b3cSmrgAC_CHECK_TOOL(AR, ar, false) 1925145b7b3cSmrgAC_CHECK_TOOL(RANLIB, ranlib, :) 1926145b7b3cSmrgAC_CHECK_TOOL(STRIP, strip, :) 1927145b7b3cSmrg 1928145b7b3cSmrgold_CC="$CC" 1929145b7b3cSmrgold_CFLAGS="$CFLAGS" 1930145b7b3cSmrg 1931145b7b3cSmrg# Set sane defaults for various variables 1932145b7b3cSmrgtest -z "$AR" && AR=ar 1933145b7b3cSmrgtest -z "$AR_FLAGS" && AR_FLAGS=cru 1934145b7b3cSmrgtest -z "$AS" && AS=as 1935145b7b3cSmrgtest -z "$CC" && CC=cc 1936145b7b3cSmrgtest -z "$LTCC" && LTCC=$CC 1937145b7b3cSmrgtest -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS 1938145b7b3cSmrgtest -z "$DLLTOOL" && DLLTOOL=dlltool 1939145b7b3cSmrgtest -z "$LD" && LD=ld 1940145b7b3cSmrgtest -z "$LN_S" && LN_S="ln -s" 1941145b7b3cSmrgtest -z "$MAGIC_CMD" && MAGIC_CMD=file 1942145b7b3cSmrgtest -z "$NM" && NM=nm 1943145b7b3cSmrgtest -z "$SED" && SED=sed 1944145b7b3cSmrgtest -z "$OBJDUMP" && OBJDUMP=objdump 1945145b7b3cSmrgtest -z "$RANLIB" && RANLIB=: 1946145b7b3cSmrgtest -z "$STRIP" && STRIP=: 1947145b7b3cSmrgtest -z "$ac_objext" && ac_objext=o 1948145b7b3cSmrg 1949145b7b3cSmrg# Determine commands to create old-style static archives. 1950578741aaSmrgold_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' 1951145b7b3cSmrgold_postinstall_cmds='chmod 644 $oldlib' 1952145b7b3cSmrgold_postuninstall_cmds= 1953145b7b3cSmrg 1954145b7b3cSmrgif test -n "$RANLIB"; then 1955145b7b3cSmrg case $host_os in 1956145b7b3cSmrg openbsd*) 1957145b7b3cSmrg old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib" 1958145b7b3cSmrg ;; 1959145b7b3cSmrg *) 1960145b7b3cSmrg old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib" 1961145b7b3cSmrg ;; 1962145b7b3cSmrg esac 1963145b7b3cSmrg old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib" 1964145b7b3cSmrgfi 1965145b7b3cSmrg 1966145b7b3cSmrg_LT_CC_BASENAME([$compiler]) 1967145b7b3cSmrg 1968145b7b3cSmrg# Only perform the check for file, if the check method requires it 1969145b7b3cSmrgcase $deplibs_check_method in 1970145b7b3cSmrgfile_magic*) 1971145b7b3cSmrg if test "$file_magic_cmd" = '$MAGIC_CMD'; then 1972145b7b3cSmrg AC_PATH_MAGIC 1973145b7b3cSmrg fi 1974145b7b3cSmrg ;; 1975145b7b3cSmrgesac 1976145b7b3cSmrg 1977578741aaSmrg_LT_REQUIRED_DARWIN_CHECKS 1978578741aaSmrg 1979145b7b3cSmrgAC_PROVIDE_IFELSE([AC_LIBTOOL_DLOPEN], enable_dlopen=yes, enable_dlopen=no) 1980145b7b3cSmrgAC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL], 1981145b7b3cSmrgenable_win32_dll=yes, enable_win32_dll=no) 1982145b7b3cSmrg 1983145b7b3cSmrgAC_ARG_ENABLE([libtool-lock], 1984145b7b3cSmrg [AC_HELP_STRING([--disable-libtool-lock], 1985145b7b3cSmrg [avoid locking (might break parallel builds)])]) 1986145b7b3cSmrgtest "x$enable_libtool_lock" != xno && enable_libtool_lock=yes 1987145b7b3cSmrg 1988145b7b3cSmrgAC_ARG_WITH([pic], 1989145b7b3cSmrg [AC_HELP_STRING([--with-pic], 1990145b7b3cSmrg [try to use only PIC/non-PIC objects @<:@default=use both@:>@])], 1991145b7b3cSmrg [pic_mode="$withval"], 1992145b7b3cSmrg [pic_mode=default]) 1993145b7b3cSmrgtest -z "$pic_mode" && pic_mode=default 1994145b7b3cSmrg 1995145b7b3cSmrg# Use C for the default configuration in the libtool script 1996145b7b3cSmrgtagname= 1997145b7b3cSmrgAC_LIBTOOL_LANG_C_CONFIG 1998145b7b3cSmrg_LT_AC_TAGCONFIG 1999145b7b3cSmrg])# AC_LIBTOOL_SETUP 2000145b7b3cSmrg 2001145b7b3cSmrg 2002145b7b3cSmrg# _LT_AC_SYS_COMPILER 2003145b7b3cSmrg# ------------------- 2004145b7b3cSmrgAC_DEFUN([_LT_AC_SYS_COMPILER], 2005145b7b3cSmrg[AC_REQUIRE([AC_PROG_CC])dnl 2006145b7b3cSmrg 2007145b7b3cSmrg# If no C compiler was specified, use CC. 2008145b7b3cSmrgLTCC=${LTCC-"$CC"} 2009145b7b3cSmrg 2010145b7b3cSmrg# If no C compiler flags were specified, use CFLAGS. 2011145b7b3cSmrgLTCFLAGS=${LTCFLAGS-"$CFLAGS"} 2012145b7b3cSmrg 2013145b7b3cSmrg# Allow CC to be a program name with arguments. 2014145b7b3cSmrgcompiler=$CC 2015145b7b3cSmrg])# _LT_AC_SYS_COMPILER 2016145b7b3cSmrg 2017145b7b3cSmrg 2018145b7b3cSmrg# _LT_CC_BASENAME(CC) 2019145b7b3cSmrg# ------------------- 2020145b7b3cSmrg# Calculate cc_basename. Skip known compiler wrappers and cross-prefix. 2021145b7b3cSmrgAC_DEFUN([_LT_CC_BASENAME], 2022145b7b3cSmrg[for cc_temp in $1""; do 2023145b7b3cSmrg case $cc_temp in 2024145b7b3cSmrg compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;; 2025145b7b3cSmrg distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;; 2026145b7b3cSmrg \-*) ;; 2027145b7b3cSmrg *) break;; 2028145b7b3cSmrg esac 2029145b7b3cSmrgdone 2030145b7b3cSmrgcc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` 2031145b7b3cSmrg]) 2032145b7b3cSmrg 2033145b7b3cSmrg 2034145b7b3cSmrg# _LT_COMPILER_BOILERPLATE 2035145b7b3cSmrg# ------------------------ 2036145b7b3cSmrg# Check for compiler boilerplate output or warnings with 2037145b7b3cSmrg# the simple compiler test code. 2038145b7b3cSmrgAC_DEFUN([_LT_COMPILER_BOILERPLATE], 2039578741aaSmrg[AC_REQUIRE([LT_AC_PROG_SED])dnl 2040578741aaSmrgac_outfile=conftest.$ac_objext 2041578741aaSmrgecho "$lt_simple_compile_test_code" >conftest.$ac_ext 2042145b7b3cSmrgeval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err 2043145b7b3cSmrg_lt_compiler_boilerplate=`cat conftest.err` 2044145b7b3cSmrg$rm conftest* 2045145b7b3cSmrg])# _LT_COMPILER_BOILERPLATE 2046145b7b3cSmrg 2047145b7b3cSmrg 2048145b7b3cSmrg# _LT_LINKER_BOILERPLATE 2049145b7b3cSmrg# ---------------------- 2050145b7b3cSmrg# Check for linker boilerplate output or warnings with 2051145b7b3cSmrg# the simple link test code. 2052145b7b3cSmrgAC_DEFUN([_LT_LINKER_BOILERPLATE], 2053578741aaSmrg[AC_REQUIRE([LT_AC_PROG_SED])dnl 2054578741aaSmrgac_outfile=conftest.$ac_objext 2055578741aaSmrgecho "$lt_simple_link_test_code" >conftest.$ac_ext 2056145b7b3cSmrgeval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err 2057145b7b3cSmrg_lt_linker_boilerplate=`cat conftest.err` 2058578741aaSmrg$rm -r conftest* 2059145b7b3cSmrg])# _LT_LINKER_BOILERPLATE 2060145b7b3cSmrg 2061578741aaSmrg# _LT_REQUIRED_DARWIN_CHECKS 2062578741aaSmrg# -------------------------- 2063578741aaSmrg# Check for some things on darwin 2064578741aaSmrgAC_DEFUN([_LT_REQUIRED_DARWIN_CHECKS],[ 2065578741aaSmrg case $host_os in 2066578741aaSmrg rhapsody* | darwin*) 2067578741aaSmrg AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:]) 2068578741aaSmrg AC_CHECK_TOOL([NMEDIT], [nmedit], [:]) 2069578741aaSmrg 2070578741aaSmrg AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod], 2071578741aaSmrg [lt_cv_apple_cc_single_mod=no 2072578741aaSmrg if test -z "${LT_MULTI_MODULE}"; then 2073578741aaSmrg # By default we will add the -single_module flag. You can override 2074578741aaSmrg # by either setting the environment variable LT_MULTI_MODULE 2075578741aaSmrg # non-empty at configure time, or by adding -multi_module to the 2076578741aaSmrg # link flags. 2077578741aaSmrg echo "int foo(void){return 1;}" > conftest.c 2078578741aaSmrg $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ 2079578741aaSmrg -dynamiclib ${wl}-single_module conftest.c 2080578741aaSmrg if test -f libconftest.dylib; then 2081578741aaSmrg lt_cv_apple_cc_single_mod=yes 2082578741aaSmrg rm -rf libconftest.dylib* 2083578741aaSmrg fi 2084578741aaSmrg rm conftest.c 2085578741aaSmrg fi]) 2086578741aaSmrg AC_CACHE_CHECK([for -exported_symbols_list linker flag], 2087578741aaSmrg [lt_cv_ld_exported_symbols_list], 2088578741aaSmrg [lt_cv_ld_exported_symbols_list=no 2089578741aaSmrg save_LDFLAGS=$LDFLAGS 2090578741aaSmrg echo "_main" > conftest.sym 2091578741aaSmrg LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" 2092578741aaSmrg AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], 2093578741aaSmrg [lt_cv_ld_exported_symbols_list=yes], 2094578741aaSmrg [lt_cv_ld_exported_symbols_list=no]) 2095578741aaSmrg LDFLAGS="$save_LDFLAGS" 2096578741aaSmrg ]) 2097578741aaSmrg case $host_os in 2098578741aaSmrg rhapsody* | darwin1.[[0123]]) 2099578741aaSmrg _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;; 2100578741aaSmrg darwin1.*) 2101578741aaSmrg _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; 2102578741aaSmrg darwin*) 2103578741aaSmrg # if running on 10.5 or later, the deployment target defaults 2104578741aaSmrg # to the OS version, if on x86, and 10.4, the deployment 2105578741aaSmrg # target defaults to 10.4. Don't you love it? 2106578741aaSmrg case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in 2107578741aaSmrg 10.0,*86*-darwin8*|10.0,*-darwin[[91]]*) 2108578741aaSmrg _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; 2109578741aaSmrg 10.[[012]]*) 2110578741aaSmrg _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; 2111578741aaSmrg 10.*) 2112578741aaSmrg _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; 2113578741aaSmrg esac 2114578741aaSmrg ;; 2115578741aaSmrg esac 2116578741aaSmrg if test "$lt_cv_apple_cc_single_mod" = "yes"; then 2117578741aaSmrg _lt_dar_single_mod='$single_module' 2118578741aaSmrg fi 2119578741aaSmrg if test "$lt_cv_ld_exported_symbols_list" = "yes"; then 2120578741aaSmrg _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym' 2121578741aaSmrg else 2122578741aaSmrg _lt_dar_export_syms="~$NMEDIT -s \$output_objdir/\${libname}-symbols.expsym \${lib}" 2123578741aaSmrg fi 2124578741aaSmrg if test "$DSYMUTIL" != ":"; then 2125578741aaSmrg _lt_dsymutil="~$DSYMUTIL \$lib || :" 2126578741aaSmrg else 2127578741aaSmrg _lt_dsymutil= 2128578741aaSmrg fi 2129578741aaSmrg ;; 2130578741aaSmrg esac 2131578741aaSmrg]) 2132145b7b3cSmrg 2133145b7b3cSmrg# _LT_AC_SYS_LIBPATH_AIX 2134145b7b3cSmrg# ---------------------- 2135145b7b3cSmrg# Links a minimal program and checks the executable 2136145b7b3cSmrg# for the system default hardcoded library path. In most cases, 2137145b7b3cSmrg# this is /usr/lib:/lib, but when the MPI compilers are used 2138145b7b3cSmrg# the location of the communication and MPI libs are included too. 2139145b7b3cSmrg# If we don't find anything, use the default library path according 2140145b7b3cSmrg# to the aix ld manual. 2141145b7b3cSmrgAC_DEFUN([_LT_AC_SYS_LIBPATH_AIX], 2142578741aaSmrg[AC_REQUIRE([LT_AC_PROG_SED])dnl 2143578741aaSmrgAC_LINK_IFELSE(AC_LANG_PROGRAM,[ 2144578741aaSmrglt_aix_libpath_sed=' 2145578741aaSmrg /Import File Strings/,/^$/ { 2146578741aaSmrg /^0/ { 2147578741aaSmrg s/^0 *\(.*\)$/\1/ 2148578741aaSmrg p 2149578741aaSmrg } 2150578741aaSmrg }' 2151578741aaSmrgaix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` 2152145b7b3cSmrg# Check for a 64-bit object if we didn't find anything. 2153578741aaSmrgif test -z "$aix_libpath"; then 2154578741aaSmrg aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` 2155578741aaSmrgfi],[]) 2156145b7b3cSmrgif test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi 2157145b7b3cSmrg])# _LT_AC_SYS_LIBPATH_AIX 2158145b7b3cSmrg 2159145b7b3cSmrg 2160145b7b3cSmrg# _LT_AC_SHELL_INIT(ARG) 2161145b7b3cSmrg# ---------------------- 2162145b7b3cSmrgAC_DEFUN([_LT_AC_SHELL_INIT], 2163145b7b3cSmrg[ifdef([AC_DIVERSION_NOTICE], 2164145b7b3cSmrg [AC_DIVERT_PUSH(AC_DIVERSION_NOTICE)], 2165145b7b3cSmrg [AC_DIVERT_PUSH(NOTICE)]) 2166145b7b3cSmrg$1 2167145b7b3cSmrgAC_DIVERT_POP 2168145b7b3cSmrg])# _LT_AC_SHELL_INIT 2169145b7b3cSmrg 2170145b7b3cSmrg 2171145b7b3cSmrg# _LT_AC_PROG_ECHO_BACKSLASH 2172145b7b3cSmrg# -------------------------- 2173145b7b3cSmrg# Add some code to the start of the generated configure script which 2174145b7b3cSmrg# will find an echo command which doesn't interpret backslashes. 2175145b7b3cSmrgAC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH], 2176145b7b3cSmrg[_LT_AC_SHELL_INIT([ 2177145b7b3cSmrg# Check that we are running under the correct shell. 2178145b7b3cSmrgSHELL=${CONFIG_SHELL-/bin/sh} 2179145b7b3cSmrg 2180145b7b3cSmrgcase X$ECHO in 2181145b7b3cSmrgX*--fallback-echo) 2182145b7b3cSmrg # Remove one level of quotation (which was required for Make). 2183145b7b3cSmrg ECHO=`echo "$ECHO" | sed 's,\\\\\[$]\\[$]0,'[$]0','` 2184145b7b3cSmrg ;; 2185145b7b3cSmrgesac 2186145b7b3cSmrg 2187145b7b3cSmrgecho=${ECHO-echo} 2188145b7b3cSmrgif test "X[$]1" = X--no-reexec; then 2189145b7b3cSmrg # Discard the --no-reexec flag, and continue. 2190145b7b3cSmrg shift 2191145b7b3cSmrgelif test "X[$]1" = X--fallback-echo; then 2192145b7b3cSmrg # Avoid inline document here, it may be left over 2193145b7b3cSmrg : 2194145b7b3cSmrgelif test "X`($echo '\t') 2>/dev/null`" = 'X\t' ; then 2195145b7b3cSmrg # Yippee, $echo works! 2196145b7b3cSmrg : 2197145b7b3cSmrgelse 2198145b7b3cSmrg # Restart under the correct shell. 2199145b7b3cSmrg exec $SHELL "[$]0" --no-reexec ${1+"[$]@"} 2200145b7b3cSmrgfi 2201145b7b3cSmrg 2202145b7b3cSmrgif test "X[$]1" = X--fallback-echo; then 2203145b7b3cSmrg # used as fallback echo 2204145b7b3cSmrg shift 2205145b7b3cSmrg cat <<EOF 2206145b7b3cSmrg[$]* 2207145b7b3cSmrgEOF 2208145b7b3cSmrg exit 0 2209145b7b3cSmrgfi 2210145b7b3cSmrg 2211145b7b3cSmrg# The HP-UX ksh and POSIX shell print the target directory to stdout 2212145b7b3cSmrg# if CDPATH is set. 2213145b7b3cSmrg(unset CDPATH) >/dev/null 2>&1 && unset CDPATH 2214145b7b3cSmrg 2215145b7b3cSmrgif test -z "$ECHO"; then 2216145b7b3cSmrgif test "X${echo_test_string+set}" != Xset; then 2217145b7b3cSmrg# find a string as large as possible, as long as the shell can cope with it 2218145b7b3cSmrg for cmd in 'sed 50q "[$]0"' 'sed 20q "[$]0"' 'sed 10q "[$]0"' 'sed 2q "[$]0"' 'echo test'; do 2219145b7b3cSmrg # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ... 2220145b7b3cSmrg if (echo_test_string=`eval $cmd`) 2>/dev/null && 2221145b7b3cSmrg echo_test_string=`eval $cmd` && 2222145b7b3cSmrg (test "X$echo_test_string" = "X$echo_test_string") 2>/dev/null 2223145b7b3cSmrg then 2224145b7b3cSmrg break 2225145b7b3cSmrg fi 2226145b7b3cSmrg done 2227145b7b3cSmrgfi 2228145b7b3cSmrg 2229145b7b3cSmrgif test "X`($echo '\t') 2>/dev/null`" = 'X\t' && 2230145b7b3cSmrg echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` && 2231145b7b3cSmrg test "X$echo_testing_string" = "X$echo_test_string"; then 2232145b7b3cSmrg : 2233145b7b3cSmrgelse 2234145b7b3cSmrg # The Solaris, AIX, and Digital Unix default echo programs unquote 2235145b7b3cSmrg # backslashes. This makes it impossible to quote backslashes using 2236145b7b3cSmrg # echo "$something" | sed 's/\\/\\\\/g' 2237145b7b3cSmrg # 2238145b7b3cSmrg # So, first we look for a working echo in the user's PATH. 2239145b7b3cSmrg 2240145b7b3cSmrg lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR 2241145b7b3cSmrg for dir in $PATH /usr/ucb; do 2242145b7b3cSmrg IFS="$lt_save_ifs" 2243145b7b3cSmrg if (test -f $dir/echo || test -f $dir/echo$ac_exeext) && 2244145b7b3cSmrg test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' && 2245145b7b3cSmrg echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` && 2246145b7b3cSmrg test "X$echo_testing_string" = "X$echo_test_string"; then 2247145b7b3cSmrg echo="$dir/echo" 2248145b7b3cSmrg break 2249145b7b3cSmrg fi 2250145b7b3cSmrg done 2251145b7b3cSmrg IFS="$lt_save_ifs" 2252145b7b3cSmrg 2253145b7b3cSmrg if test "X$echo" = Xecho; then 2254145b7b3cSmrg # We didn't find a better echo, so look for alternatives. 2255145b7b3cSmrg if test "X`(print -r '\t') 2>/dev/null`" = 'X\t' && 2256145b7b3cSmrg echo_testing_string=`(print -r "$echo_test_string") 2>/dev/null` && 2257145b7b3cSmrg test "X$echo_testing_string" = "X$echo_test_string"; then 2258145b7b3cSmrg # This shell has a builtin print -r that does the trick. 2259145b7b3cSmrg echo='print -r' 2260145b7b3cSmrg elif (test -f /bin/ksh || test -f /bin/ksh$ac_exeext) && 2261145b7b3cSmrg test "X$CONFIG_SHELL" != X/bin/ksh; then 2262145b7b3cSmrg # If we have ksh, try running configure again with it. 2263145b7b3cSmrg ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh} 2264145b7b3cSmrg export ORIGINAL_CONFIG_SHELL 2265145b7b3cSmrg CONFIG_SHELL=/bin/ksh 2266145b7b3cSmrg export CONFIG_SHELL 2267145b7b3cSmrg exec $CONFIG_SHELL "[$]0" --no-reexec ${1+"[$]@"} 2268145b7b3cSmrg else 2269145b7b3cSmrg # Try using printf. 2270145b7b3cSmrg echo='printf %s\n' 2271145b7b3cSmrg if test "X`($echo '\t') 2>/dev/null`" = 'X\t' && 2272145b7b3cSmrg echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` && 2273145b7b3cSmrg test "X$echo_testing_string" = "X$echo_test_string"; then 2274145b7b3cSmrg # Cool, printf works 2275145b7b3cSmrg : 2276145b7b3cSmrg elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` && 2277145b7b3cSmrg test "X$echo_testing_string" = 'X\t' && 2278145b7b3cSmrg echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` && 2279145b7b3cSmrg test "X$echo_testing_string" = "X$echo_test_string"; then 2280145b7b3cSmrg CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL 2281145b7b3cSmrg export CONFIG_SHELL 2282145b7b3cSmrg SHELL="$CONFIG_SHELL" 2283145b7b3cSmrg export SHELL 2284145b7b3cSmrg echo="$CONFIG_SHELL [$]0 --fallback-echo" 2285145b7b3cSmrg elif echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` && 2286145b7b3cSmrg test "X$echo_testing_string" = 'X\t' && 2287145b7b3cSmrg echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` && 2288145b7b3cSmrg test "X$echo_testing_string" = "X$echo_test_string"; then 2289145b7b3cSmrg echo="$CONFIG_SHELL [$]0 --fallback-echo" 2290145b7b3cSmrg else 2291145b7b3cSmrg # maybe with a smaller string... 2292145b7b3cSmrg prev=: 2293145b7b3cSmrg 2294145b7b3cSmrg for cmd in 'echo test' 'sed 2q "[$]0"' 'sed 10q "[$]0"' 'sed 20q "[$]0"' 'sed 50q "[$]0"'; do 2295145b7b3cSmrg if (test "X$echo_test_string" = "X`eval $cmd`") 2>/dev/null 2296145b7b3cSmrg then 2297145b7b3cSmrg break 2298145b7b3cSmrg fi 2299145b7b3cSmrg prev="$cmd" 2300145b7b3cSmrg done 2301145b7b3cSmrg 2302145b7b3cSmrg if test "$prev" != 'sed 50q "[$]0"'; then 2303145b7b3cSmrg echo_test_string=`eval $prev` 2304145b7b3cSmrg export echo_test_string 2305145b7b3cSmrg exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "[$]0" ${1+"[$]@"} 2306145b7b3cSmrg else 2307145b7b3cSmrg # Oops. We lost completely, so just stick with echo. 2308145b7b3cSmrg echo=echo 2309145b7b3cSmrg fi 2310145b7b3cSmrg fi 2311145b7b3cSmrg fi 2312145b7b3cSmrg fi 2313145b7b3cSmrgfi 2314145b7b3cSmrgfi 2315145b7b3cSmrg 2316145b7b3cSmrg# Copy echo and quote the copy suitably for passing to libtool from 2317145b7b3cSmrg# the Makefile, instead of quoting the original, which is used later. 2318145b7b3cSmrgECHO=$echo 2319145b7b3cSmrgif test "X$ECHO" = "X$CONFIG_SHELL [$]0 --fallback-echo"; then 2320145b7b3cSmrg ECHO="$CONFIG_SHELL \\\$\[$]0 --fallback-echo" 2321145b7b3cSmrgfi 2322145b7b3cSmrg 2323145b7b3cSmrgAC_SUBST(ECHO) 2324145b7b3cSmrg])])# _LT_AC_PROG_ECHO_BACKSLASH 2325145b7b3cSmrg 2326145b7b3cSmrg 2327145b7b3cSmrg# _LT_AC_LOCK 2328145b7b3cSmrg# ----------- 2329145b7b3cSmrgAC_DEFUN([_LT_AC_LOCK], 2330145b7b3cSmrg[AC_ARG_ENABLE([libtool-lock], 2331145b7b3cSmrg [AC_HELP_STRING([--disable-libtool-lock], 2332145b7b3cSmrg [avoid locking (might break parallel builds)])]) 2333145b7b3cSmrgtest "x$enable_libtool_lock" != xno && enable_libtool_lock=yes 2334145b7b3cSmrg 2335145b7b3cSmrg# Some flags need to be propagated to the compiler or linker for good 2336145b7b3cSmrg# libtool support. 2337145b7b3cSmrgcase $host in 2338145b7b3cSmrgia64-*-hpux*) 2339145b7b3cSmrg # Find out which ABI we are using. 2340145b7b3cSmrg echo 'int i;' > conftest.$ac_ext 2341145b7b3cSmrg if AC_TRY_EVAL(ac_compile); then 2342145b7b3cSmrg case `/usr/bin/file conftest.$ac_objext` in 2343145b7b3cSmrg *ELF-32*) 2344145b7b3cSmrg HPUX_IA64_MODE="32" 2345145b7b3cSmrg ;; 2346145b7b3cSmrg *ELF-64*) 2347145b7b3cSmrg HPUX_IA64_MODE="64" 2348145b7b3cSmrg ;; 2349145b7b3cSmrg esac 2350145b7b3cSmrg fi 2351145b7b3cSmrg rm -rf conftest* 2352145b7b3cSmrg ;; 2353145b7b3cSmrg*-*-irix6*) 2354145b7b3cSmrg # Find out which ABI we are using. 2355145b7b3cSmrg echo '[#]line __oline__ "configure"' > conftest.$ac_ext 2356145b7b3cSmrg if AC_TRY_EVAL(ac_compile); then 2357145b7b3cSmrg if test "$lt_cv_prog_gnu_ld" = yes; then 2358145b7b3cSmrg case `/usr/bin/file conftest.$ac_objext` in 2359145b7b3cSmrg *32-bit*) 2360145b7b3cSmrg LD="${LD-ld} -melf32bsmip" 2361145b7b3cSmrg ;; 2362145b7b3cSmrg *N32*) 2363145b7b3cSmrg LD="${LD-ld} -melf32bmipn32" 2364145b7b3cSmrg ;; 2365145b7b3cSmrg *64-bit*) 2366145b7b3cSmrg LD="${LD-ld} -melf64bmip" 2367145b7b3cSmrg ;; 2368145b7b3cSmrg esac 2369145b7b3cSmrg else 2370145b7b3cSmrg case `/usr/bin/file conftest.$ac_objext` in 2371145b7b3cSmrg *32-bit*) 2372145b7b3cSmrg LD="${LD-ld} -32" 2373145b7b3cSmrg ;; 2374145b7b3cSmrg *N32*) 2375145b7b3cSmrg LD="${LD-ld} -n32" 2376145b7b3cSmrg ;; 2377145b7b3cSmrg *64-bit*) 2378145b7b3cSmrg LD="${LD-ld} -64" 2379145b7b3cSmrg ;; 2380145b7b3cSmrg esac 2381145b7b3cSmrg fi 2382145b7b3cSmrg fi 2383145b7b3cSmrg rm -rf conftest* 2384145b7b3cSmrg ;; 2385145b7b3cSmrg 2386578741aaSmrgx86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \ 2387578741aaSmrgs390*-*linux*|sparc*-*linux*) 2388145b7b3cSmrg # Find out which ABI we are using. 2389145b7b3cSmrg echo 'int i;' > conftest.$ac_ext 2390145b7b3cSmrg if AC_TRY_EVAL(ac_compile); then 2391145b7b3cSmrg case `/usr/bin/file conftest.o` in 2392145b7b3cSmrg *32-bit*) 2393145b7b3cSmrg case $host in 2394578741aaSmrg x86_64-*kfreebsd*-gnu) 2395578741aaSmrg LD="${LD-ld} -m elf_i386_fbsd" 2396578741aaSmrg ;; 2397145b7b3cSmrg x86_64-*linux*) 2398145b7b3cSmrg LD="${LD-ld} -m elf_i386" 2399145b7b3cSmrg ;; 2400145b7b3cSmrg ppc64-*linux*|powerpc64-*linux*) 2401145b7b3cSmrg LD="${LD-ld} -m elf32ppclinux" 2402145b7b3cSmrg ;; 2403145b7b3cSmrg s390x-*linux*) 2404145b7b3cSmrg LD="${LD-ld} -m elf_s390" 2405145b7b3cSmrg ;; 2406145b7b3cSmrg sparc64-*linux*) 2407145b7b3cSmrg LD="${LD-ld} -m elf32_sparc" 2408145b7b3cSmrg ;; 2409145b7b3cSmrg esac 2410145b7b3cSmrg ;; 2411145b7b3cSmrg *64-bit*) 2412145b7b3cSmrg case $host in 2413578741aaSmrg x86_64-*kfreebsd*-gnu) 2414578741aaSmrg LD="${LD-ld} -m elf_x86_64_fbsd" 2415578741aaSmrg ;; 2416145b7b3cSmrg x86_64-*linux*) 2417145b7b3cSmrg LD="${LD-ld} -m elf_x86_64" 2418145b7b3cSmrg ;; 2419145b7b3cSmrg ppc*-*linux*|powerpc*-*linux*) 2420145b7b3cSmrg LD="${LD-ld} -m elf64ppc" 2421145b7b3cSmrg ;; 2422145b7b3cSmrg s390*-*linux*) 2423145b7b3cSmrg LD="${LD-ld} -m elf64_s390" 2424145b7b3cSmrg ;; 2425145b7b3cSmrg sparc*-*linux*) 2426145b7b3cSmrg LD="${LD-ld} -m elf64_sparc" 2427145b7b3cSmrg ;; 2428145b7b3cSmrg esac 2429145b7b3cSmrg ;; 2430145b7b3cSmrg esac 2431145b7b3cSmrg fi 2432145b7b3cSmrg rm -rf conftest* 2433145b7b3cSmrg ;; 2434145b7b3cSmrg 2435145b7b3cSmrg*-*-sco3.2v5*) 2436145b7b3cSmrg # On SCO OpenServer 5, we need -belf to get full-featured binaries. 2437145b7b3cSmrg SAVE_CFLAGS="$CFLAGS" 2438145b7b3cSmrg CFLAGS="$CFLAGS -belf" 2439145b7b3cSmrg AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf, 2440145b7b3cSmrg [AC_LANG_PUSH(C) 2441145b7b3cSmrg AC_TRY_LINK([],[],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no]) 2442145b7b3cSmrg AC_LANG_POP]) 2443145b7b3cSmrg if test x"$lt_cv_cc_needs_belf" != x"yes"; then 2444145b7b3cSmrg # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf 2445145b7b3cSmrg CFLAGS="$SAVE_CFLAGS" 2446145b7b3cSmrg fi 2447145b7b3cSmrg ;; 2448145b7b3cSmrgsparc*-*solaris*) 2449145b7b3cSmrg # Find out which ABI we are using. 2450145b7b3cSmrg echo 'int i;' > conftest.$ac_ext 2451145b7b3cSmrg if AC_TRY_EVAL(ac_compile); then 2452145b7b3cSmrg case `/usr/bin/file conftest.o` in 2453145b7b3cSmrg *64-bit*) 2454145b7b3cSmrg case $lt_cv_prog_gnu_ld in 2455145b7b3cSmrg yes*) LD="${LD-ld} -m elf64_sparc" ;; 2456578741aaSmrg *) 2457578741aaSmrg if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then 2458578741aaSmrg LD="${LD-ld} -64" 2459578741aaSmrg fi 2460578741aaSmrg ;; 2461145b7b3cSmrg esac 2462145b7b3cSmrg ;; 2463145b7b3cSmrg esac 2464145b7b3cSmrg fi 2465145b7b3cSmrg rm -rf conftest* 2466145b7b3cSmrg ;; 2467145b7b3cSmrg 2468145b7b3cSmrgAC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL], 2469145b7b3cSmrg[*-*-cygwin* | *-*-mingw* | *-*-pw32*) 2470145b7b3cSmrg AC_CHECK_TOOL(DLLTOOL, dlltool, false) 2471145b7b3cSmrg AC_CHECK_TOOL(AS, as, false) 2472145b7b3cSmrg AC_CHECK_TOOL(OBJDUMP, objdump, false) 2473145b7b3cSmrg ;; 2474145b7b3cSmrg ]) 2475145b7b3cSmrgesac 2476145b7b3cSmrg 2477145b7b3cSmrgneed_locks="$enable_libtool_lock" 2478145b7b3cSmrg 2479145b7b3cSmrg])# _LT_AC_LOCK 2480145b7b3cSmrg 2481145b7b3cSmrg 2482145b7b3cSmrg# AC_LIBTOOL_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, 2483145b7b3cSmrg# [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE]) 2484145b7b3cSmrg# ---------------------------------------------------------------- 2485145b7b3cSmrg# Check whether the given compiler option works 2486145b7b3cSmrgAC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], 2487145b7b3cSmrg[AC_REQUIRE([LT_AC_PROG_SED]) 2488145b7b3cSmrgAC_CACHE_CHECK([$1], [$2], 2489145b7b3cSmrg [$2=no 2490145b7b3cSmrg ifelse([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4]) 2491578741aaSmrg echo "$lt_simple_compile_test_code" > conftest.$ac_ext 2492145b7b3cSmrg lt_compiler_flag="$3" 2493145b7b3cSmrg # Insert the option either (1) after the last *FLAGS variable, or 2494145b7b3cSmrg # (2) before a word containing "conftest.", or (3) at the end. 2495145b7b3cSmrg # Note that $ac_compile itself does not contain backslashes and begins 2496145b7b3cSmrg # with a dollar sign (not a hyphen), so the echo should work correctly. 2497145b7b3cSmrg # The option is referenced via a variable to avoid confusing sed. 2498145b7b3cSmrg lt_compile=`echo "$ac_compile" | $SED \ 2499145b7b3cSmrg -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ 2500145b7b3cSmrg -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ 2501145b7b3cSmrg -e 's:$: $lt_compiler_flag:'` 2502145b7b3cSmrg (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD) 2503145b7b3cSmrg (eval "$lt_compile" 2>conftest.err) 2504145b7b3cSmrg ac_status=$? 2505145b7b3cSmrg cat conftest.err >&AS_MESSAGE_LOG_FD 2506145b7b3cSmrg echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD 2507145b7b3cSmrg if (exit $ac_status) && test -s "$ac_outfile"; then 2508145b7b3cSmrg # The compiler can only warn and ignore the option if not recognized 2509145b7b3cSmrg # So say no if there are warnings other than the usual output. 2510145b7b3cSmrg $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp 2511145b7b3cSmrg $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 2512145b7b3cSmrg if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then 2513145b7b3cSmrg $2=yes 2514145b7b3cSmrg fi 2515145b7b3cSmrg fi 2516145b7b3cSmrg $rm conftest* 2517145b7b3cSmrg]) 2518145b7b3cSmrg 2519145b7b3cSmrgif test x"[$]$2" = xyes; then 2520145b7b3cSmrg ifelse([$5], , :, [$5]) 2521145b7b3cSmrgelse 2522145b7b3cSmrg ifelse([$6], , :, [$6]) 2523145b7b3cSmrgfi 2524145b7b3cSmrg])# AC_LIBTOOL_COMPILER_OPTION 2525145b7b3cSmrg 2526145b7b3cSmrg 2527145b7b3cSmrg# AC_LIBTOOL_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, 2528145b7b3cSmrg# [ACTION-SUCCESS], [ACTION-FAILURE]) 2529145b7b3cSmrg# ------------------------------------------------------------ 2530145b7b3cSmrg# Check whether the given compiler option works 2531145b7b3cSmrgAC_DEFUN([AC_LIBTOOL_LINKER_OPTION], 2532578741aaSmrg[AC_REQUIRE([LT_AC_PROG_SED])dnl 2533578741aaSmrgAC_CACHE_CHECK([$1], [$2], 2534145b7b3cSmrg [$2=no 2535145b7b3cSmrg save_LDFLAGS="$LDFLAGS" 2536145b7b3cSmrg LDFLAGS="$LDFLAGS $3" 2537578741aaSmrg echo "$lt_simple_link_test_code" > conftest.$ac_ext 2538145b7b3cSmrg if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then 2539145b7b3cSmrg # The linker can only warn and ignore the option if not recognized 2540145b7b3cSmrg # So say no if there are warnings 2541145b7b3cSmrg if test -s conftest.err; then 2542145b7b3cSmrg # Append any errors to the config.log. 2543145b7b3cSmrg cat conftest.err 1>&AS_MESSAGE_LOG_FD 2544145b7b3cSmrg $echo "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp 2545145b7b3cSmrg $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 2546145b7b3cSmrg if diff conftest.exp conftest.er2 >/dev/null; then 2547145b7b3cSmrg $2=yes 2548145b7b3cSmrg fi 2549145b7b3cSmrg else 2550145b7b3cSmrg $2=yes 2551145b7b3cSmrg fi 2552145b7b3cSmrg fi 2553578741aaSmrg $rm -r conftest* 2554145b7b3cSmrg LDFLAGS="$save_LDFLAGS" 2555145b7b3cSmrg]) 2556145b7b3cSmrg 2557145b7b3cSmrgif test x"[$]$2" = xyes; then 2558145b7b3cSmrg ifelse([$4], , :, [$4]) 2559145b7b3cSmrgelse 2560145b7b3cSmrg ifelse([$5], , :, [$5]) 2561145b7b3cSmrgfi 2562145b7b3cSmrg])# AC_LIBTOOL_LINKER_OPTION 2563145b7b3cSmrg 2564145b7b3cSmrg 2565145b7b3cSmrg# AC_LIBTOOL_SYS_MAX_CMD_LEN 2566145b7b3cSmrg# -------------------------- 2567145b7b3cSmrgAC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], 2568145b7b3cSmrg[# find the maximum length of command line arguments 2569145b7b3cSmrgAC_MSG_CHECKING([the maximum length of command line arguments]) 2570145b7b3cSmrgAC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl 2571145b7b3cSmrg i=0 2572145b7b3cSmrg teststring="ABCD" 2573145b7b3cSmrg 2574145b7b3cSmrg case $build_os in 2575145b7b3cSmrg msdosdjgpp*) 2576145b7b3cSmrg # On DJGPP, this test can blow up pretty badly due to problems in libc 2577145b7b3cSmrg # (any single argument exceeding 2000 bytes causes a buffer overrun 2578145b7b3cSmrg # during glob expansion). Even if it were fixed, the result of this 2579145b7b3cSmrg # check would be larger than it should be. 2580145b7b3cSmrg lt_cv_sys_max_cmd_len=12288; # 12K is about right 2581145b7b3cSmrg ;; 2582145b7b3cSmrg 2583145b7b3cSmrg gnu*) 2584145b7b3cSmrg # Under GNU Hurd, this test is not required because there is 2585145b7b3cSmrg # no limit to the length of command line arguments. 2586145b7b3cSmrg # Libtool will interpret -1 as no limit whatsoever 2587145b7b3cSmrg lt_cv_sys_max_cmd_len=-1; 2588145b7b3cSmrg ;; 2589145b7b3cSmrg 2590145b7b3cSmrg cygwin* | mingw*) 2591145b7b3cSmrg # On Win9x/ME, this test blows up -- it succeeds, but takes 2592145b7b3cSmrg # about 5 minutes as the teststring grows exponentially. 2593145b7b3cSmrg # Worse, since 9x/ME are not pre-emptively multitasking, 2594145b7b3cSmrg # you end up with a "frozen" computer, even though with patience 2595145b7b3cSmrg # the test eventually succeeds (with a max line length of 256k). 2596145b7b3cSmrg # Instead, let's just punt: use the minimum linelength reported by 2597145b7b3cSmrg # all of the supported platforms: 8192 (on NT/2K/XP). 2598145b7b3cSmrg lt_cv_sys_max_cmd_len=8192; 2599145b7b3cSmrg ;; 2600145b7b3cSmrg 2601145b7b3cSmrg amigaos*) 2602145b7b3cSmrg # On AmigaOS with pdksh, this test takes hours, literally. 2603145b7b3cSmrg # So we just punt and use a minimum line length of 8192. 2604145b7b3cSmrg lt_cv_sys_max_cmd_len=8192; 2605145b7b3cSmrg ;; 2606145b7b3cSmrg 2607145b7b3cSmrg netbsd* | freebsd* | openbsd* | darwin* | dragonfly*) 2608145b7b3cSmrg # This has been around since 386BSD, at least. Likely further. 2609145b7b3cSmrg if test -x /sbin/sysctl; then 2610145b7b3cSmrg lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` 2611145b7b3cSmrg elif test -x /usr/sbin/sysctl; then 2612145b7b3cSmrg lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` 2613145b7b3cSmrg else 2614145b7b3cSmrg lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs 2615145b7b3cSmrg fi 2616145b7b3cSmrg # And add a safety zone 2617145b7b3cSmrg lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` 2618145b7b3cSmrg lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` 2619145b7b3cSmrg ;; 2620145b7b3cSmrg 2621145b7b3cSmrg interix*) 2622145b7b3cSmrg # We know the value 262144 and hardcode it with a safety zone (like BSD) 2623145b7b3cSmrg lt_cv_sys_max_cmd_len=196608 2624145b7b3cSmrg ;; 2625145b7b3cSmrg 2626145b7b3cSmrg osf*) 2627145b7b3cSmrg # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure 2628145b7b3cSmrg # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not 2629145b7b3cSmrg # nice to cause kernel panics so lets avoid the loop below. 2630145b7b3cSmrg # First set a reasonable default. 2631145b7b3cSmrg lt_cv_sys_max_cmd_len=16384 2632145b7b3cSmrg # 2633145b7b3cSmrg if test -x /sbin/sysconfig; then 2634145b7b3cSmrg case `/sbin/sysconfig -q proc exec_disable_arg_limit` in 2635145b7b3cSmrg *1*) lt_cv_sys_max_cmd_len=-1 ;; 2636145b7b3cSmrg esac 2637145b7b3cSmrg fi 2638145b7b3cSmrg ;; 2639145b7b3cSmrg sco3.2v5*) 2640145b7b3cSmrg lt_cv_sys_max_cmd_len=102400 2641145b7b3cSmrg ;; 2642145b7b3cSmrg sysv5* | sco5v6* | sysv4.2uw2*) 2643145b7b3cSmrg kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` 2644145b7b3cSmrg if test -n "$kargmax"; then 2645145b7b3cSmrg lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'` 2646145b7b3cSmrg else 2647145b7b3cSmrg lt_cv_sys_max_cmd_len=32768 2648145b7b3cSmrg fi 2649145b7b3cSmrg ;; 2650145b7b3cSmrg *) 2651578741aaSmrg lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` 2652578741aaSmrg if test -n "$lt_cv_sys_max_cmd_len"; then 2653578741aaSmrg lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` 2654578741aaSmrg lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` 2655578741aaSmrg else 2656578741aaSmrg SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} 2657578741aaSmrg while (test "X"`$SHELL [$]0 --fallback-echo "X$teststring" 2>/dev/null` \ 2658145b7b3cSmrg = "XX$teststring") >/dev/null 2>&1 && 2659578741aaSmrg new_result=`expr "X$teststring" : ".*" 2>&1` && 2660578741aaSmrg lt_cv_sys_max_cmd_len=$new_result && 2661578741aaSmrg test $i != 17 # 1/2 MB should be enough 2662578741aaSmrg do 2663578741aaSmrg i=`expr $i + 1` 2664578741aaSmrg teststring=$teststring$teststring 2665578741aaSmrg done 2666578741aaSmrg teststring= 2667578741aaSmrg # Add a significant safety factor because C++ compilers can tack on massive 2668578741aaSmrg # amounts of additional arguments before passing them to the linker. 2669578741aaSmrg # It appears as though 1/2 is a usable value. 2670578741aaSmrg lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` 2671578741aaSmrg fi 2672145b7b3cSmrg ;; 2673145b7b3cSmrg esac 2674145b7b3cSmrg]) 2675145b7b3cSmrgif test -n $lt_cv_sys_max_cmd_len ; then 2676145b7b3cSmrg AC_MSG_RESULT($lt_cv_sys_max_cmd_len) 2677145b7b3cSmrgelse 2678145b7b3cSmrg AC_MSG_RESULT(none) 2679145b7b3cSmrgfi 2680145b7b3cSmrg])# AC_LIBTOOL_SYS_MAX_CMD_LEN 2681145b7b3cSmrg 2682145b7b3cSmrg 2683145b7b3cSmrg# _LT_AC_CHECK_DLFCN 2684145b7b3cSmrg# ------------------ 2685145b7b3cSmrgAC_DEFUN([_LT_AC_CHECK_DLFCN], 2686145b7b3cSmrg[AC_CHECK_HEADERS(dlfcn.h)dnl 2687145b7b3cSmrg])# _LT_AC_CHECK_DLFCN 2688145b7b3cSmrg 2689145b7b3cSmrg 2690145b7b3cSmrg# _LT_AC_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE, 2691145b7b3cSmrg# ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING) 2692145b7b3cSmrg# --------------------------------------------------------------------- 2693145b7b3cSmrgAC_DEFUN([_LT_AC_TRY_DLOPEN_SELF], 2694145b7b3cSmrg[AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl 2695145b7b3cSmrgif test "$cross_compiling" = yes; then : 2696145b7b3cSmrg [$4] 2697145b7b3cSmrgelse 2698145b7b3cSmrg lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 2699145b7b3cSmrg lt_status=$lt_dlunknown 2700145b7b3cSmrg cat > conftest.$ac_ext <<EOF 2701145b7b3cSmrg[#line __oline__ "configure" 2702145b7b3cSmrg#include "confdefs.h" 2703145b7b3cSmrg 2704145b7b3cSmrg#if HAVE_DLFCN_H 2705145b7b3cSmrg#include <dlfcn.h> 2706145b7b3cSmrg#endif 2707145b7b3cSmrg 2708145b7b3cSmrg#include <stdio.h> 2709145b7b3cSmrg 2710145b7b3cSmrg#ifdef RTLD_GLOBAL 2711145b7b3cSmrg# define LT_DLGLOBAL RTLD_GLOBAL 2712145b7b3cSmrg#else 2713145b7b3cSmrg# ifdef DL_GLOBAL 2714145b7b3cSmrg# define LT_DLGLOBAL DL_GLOBAL 2715145b7b3cSmrg# else 2716145b7b3cSmrg# define LT_DLGLOBAL 0 2717145b7b3cSmrg# endif 2718145b7b3cSmrg#endif 2719145b7b3cSmrg 2720145b7b3cSmrg/* We may have to define LT_DLLAZY_OR_NOW in the command line if we 2721145b7b3cSmrg find out it does not work in some platform. */ 2722145b7b3cSmrg#ifndef LT_DLLAZY_OR_NOW 2723145b7b3cSmrg# ifdef RTLD_LAZY 2724145b7b3cSmrg# define LT_DLLAZY_OR_NOW RTLD_LAZY 2725145b7b3cSmrg# else 2726145b7b3cSmrg# ifdef DL_LAZY 2727145b7b3cSmrg# define LT_DLLAZY_OR_NOW DL_LAZY 2728145b7b3cSmrg# else 2729145b7b3cSmrg# ifdef RTLD_NOW 2730145b7b3cSmrg# define LT_DLLAZY_OR_NOW RTLD_NOW 2731145b7b3cSmrg# else 2732145b7b3cSmrg# ifdef DL_NOW 2733145b7b3cSmrg# define LT_DLLAZY_OR_NOW DL_NOW 2734145b7b3cSmrg# else 2735145b7b3cSmrg# define LT_DLLAZY_OR_NOW 0 2736145b7b3cSmrg# endif 2737145b7b3cSmrg# endif 2738145b7b3cSmrg# endif 2739145b7b3cSmrg# endif 2740145b7b3cSmrg#endif 2741145b7b3cSmrg 2742145b7b3cSmrg#ifdef __cplusplus 2743145b7b3cSmrgextern "C" void exit (int); 2744145b7b3cSmrg#endif 2745145b7b3cSmrg 2746145b7b3cSmrgvoid fnord() { int i=42;} 2747145b7b3cSmrgint main () 2748145b7b3cSmrg{ 2749145b7b3cSmrg void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); 2750145b7b3cSmrg int status = $lt_dlunknown; 2751145b7b3cSmrg 2752145b7b3cSmrg if (self) 2753145b7b3cSmrg { 2754145b7b3cSmrg if (dlsym (self,"fnord")) status = $lt_dlno_uscore; 2755145b7b3cSmrg else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; 2756145b7b3cSmrg /* dlclose (self); */ 2757145b7b3cSmrg } 2758145b7b3cSmrg else 2759145b7b3cSmrg puts (dlerror ()); 2760145b7b3cSmrg 2761145b7b3cSmrg exit (status); 2762145b7b3cSmrg}] 2763145b7b3cSmrgEOF 2764145b7b3cSmrg if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then 2765145b7b3cSmrg (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null 2766145b7b3cSmrg lt_status=$? 2767145b7b3cSmrg case x$lt_status in 2768145b7b3cSmrg x$lt_dlno_uscore) $1 ;; 2769145b7b3cSmrg x$lt_dlneed_uscore) $2 ;; 2770145b7b3cSmrg x$lt_dlunknown|x*) $3 ;; 2771145b7b3cSmrg esac 2772145b7b3cSmrg else : 2773145b7b3cSmrg # compilation failed 2774145b7b3cSmrg $3 2775145b7b3cSmrg fi 2776145b7b3cSmrgfi 2777145b7b3cSmrgrm -fr conftest* 2778145b7b3cSmrg])# _LT_AC_TRY_DLOPEN_SELF 2779145b7b3cSmrg 2780145b7b3cSmrg 2781145b7b3cSmrg# AC_LIBTOOL_DLOPEN_SELF 2782145b7b3cSmrg# ---------------------- 2783145b7b3cSmrgAC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], 2784145b7b3cSmrg[AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl 2785145b7b3cSmrgif test "x$enable_dlopen" != xyes; then 2786145b7b3cSmrg enable_dlopen=unknown 2787145b7b3cSmrg enable_dlopen_self=unknown 2788145b7b3cSmrg enable_dlopen_self_static=unknown 2789145b7b3cSmrgelse 2790145b7b3cSmrg lt_cv_dlopen=no 2791145b7b3cSmrg lt_cv_dlopen_libs= 2792145b7b3cSmrg 2793145b7b3cSmrg case $host_os in 2794145b7b3cSmrg beos*) 2795145b7b3cSmrg lt_cv_dlopen="load_add_on" 2796145b7b3cSmrg lt_cv_dlopen_libs= 2797145b7b3cSmrg lt_cv_dlopen_self=yes 2798145b7b3cSmrg ;; 2799145b7b3cSmrg 2800145b7b3cSmrg mingw* | pw32*) 2801145b7b3cSmrg lt_cv_dlopen="LoadLibrary" 2802145b7b3cSmrg lt_cv_dlopen_libs= 2803145b7b3cSmrg ;; 2804145b7b3cSmrg 2805145b7b3cSmrg cygwin*) 2806145b7b3cSmrg lt_cv_dlopen="dlopen" 2807145b7b3cSmrg lt_cv_dlopen_libs= 2808145b7b3cSmrg ;; 2809145b7b3cSmrg 2810145b7b3cSmrg darwin*) 2811145b7b3cSmrg # if libdl is installed we need to link against it 2812145b7b3cSmrg AC_CHECK_LIB([dl], [dlopen], 2813145b7b3cSmrg [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[ 2814145b7b3cSmrg lt_cv_dlopen="dyld" 2815145b7b3cSmrg lt_cv_dlopen_libs= 2816145b7b3cSmrg lt_cv_dlopen_self=yes 2817145b7b3cSmrg ]) 2818145b7b3cSmrg ;; 2819145b7b3cSmrg 2820145b7b3cSmrg *) 2821145b7b3cSmrg AC_CHECK_FUNC([shl_load], 2822145b7b3cSmrg [lt_cv_dlopen="shl_load"], 2823145b7b3cSmrg [AC_CHECK_LIB([dld], [shl_load], 2824578741aaSmrg [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"], 2825145b7b3cSmrg [AC_CHECK_FUNC([dlopen], 2826145b7b3cSmrg [lt_cv_dlopen="dlopen"], 2827145b7b3cSmrg [AC_CHECK_LIB([dl], [dlopen], 2828145b7b3cSmrg [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"], 2829145b7b3cSmrg [AC_CHECK_LIB([svld], [dlopen], 2830145b7b3cSmrg [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"], 2831145b7b3cSmrg [AC_CHECK_LIB([dld], [dld_link], 2832578741aaSmrg [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"]) 2833145b7b3cSmrg ]) 2834145b7b3cSmrg ]) 2835145b7b3cSmrg ]) 2836145b7b3cSmrg ]) 2837145b7b3cSmrg ]) 2838145b7b3cSmrg ;; 2839145b7b3cSmrg esac 2840145b7b3cSmrg 2841145b7b3cSmrg if test "x$lt_cv_dlopen" != xno; then 2842145b7b3cSmrg enable_dlopen=yes 2843145b7b3cSmrg else 2844145b7b3cSmrg enable_dlopen=no 2845145b7b3cSmrg fi 2846145b7b3cSmrg 2847145b7b3cSmrg case $lt_cv_dlopen in 2848145b7b3cSmrg dlopen) 2849145b7b3cSmrg save_CPPFLAGS="$CPPFLAGS" 2850145b7b3cSmrg test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" 2851145b7b3cSmrg 2852145b7b3cSmrg save_LDFLAGS="$LDFLAGS" 2853145b7b3cSmrg wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" 2854145b7b3cSmrg 2855145b7b3cSmrg save_LIBS="$LIBS" 2856145b7b3cSmrg LIBS="$lt_cv_dlopen_libs $LIBS" 2857145b7b3cSmrg 2858145b7b3cSmrg AC_CACHE_CHECK([whether a program can dlopen itself], 2859145b7b3cSmrg lt_cv_dlopen_self, [dnl 2860145b7b3cSmrg _LT_AC_TRY_DLOPEN_SELF( 2861145b7b3cSmrg lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes, 2862145b7b3cSmrg lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross) 2863145b7b3cSmrg ]) 2864145b7b3cSmrg 2865145b7b3cSmrg if test "x$lt_cv_dlopen_self" = xyes; then 2866145b7b3cSmrg wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" 2867145b7b3cSmrg AC_CACHE_CHECK([whether a statically linked program can dlopen itself], 2868145b7b3cSmrg lt_cv_dlopen_self_static, [dnl 2869145b7b3cSmrg _LT_AC_TRY_DLOPEN_SELF( 2870145b7b3cSmrg lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes, 2871145b7b3cSmrg lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross) 2872145b7b3cSmrg ]) 2873145b7b3cSmrg fi 2874145b7b3cSmrg 2875145b7b3cSmrg CPPFLAGS="$save_CPPFLAGS" 2876145b7b3cSmrg LDFLAGS="$save_LDFLAGS" 2877145b7b3cSmrg LIBS="$save_LIBS" 2878145b7b3cSmrg ;; 2879145b7b3cSmrg esac 2880145b7b3cSmrg 2881145b7b3cSmrg case $lt_cv_dlopen_self in 2882145b7b3cSmrg yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; 2883145b7b3cSmrg *) enable_dlopen_self=unknown ;; 2884145b7b3cSmrg esac 2885145b7b3cSmrg 2886145b7b3cSmrg case $lt_cv_dlopen_self_static in 2887145b7b3cSmrg yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; 2888145b7b3cSmrg *) enable_dlopen_self_static=unknown ;; 2889145b7b3cSmrg esac 2890145b7b3cSmrgfi 2891145b7b3cSmrg])# AC_LIBTOOL_DLOPEN_SELF 2892145b7b3cSmrg 2893145b7b3cSmrg 2894145b7b3cSmrg# AC_LIBTOOL_PROG_CC_C_O([TAGNAME]) 2895145b7b3cSmrg# --------------------------------- 2896145b7b3cSmrg# Check to see if options -c and -o are simultaneously supported by compiler 2897145b7b3cSmrgAC_DEFUN([AC_LIBTOOL_PROG_CC_C_O], 2898578741aaSmrg[AC_REQUIRE([LT_AC_PROG_SED])dnl 2899578741aaSmrgAC_REQUIRE([_LT_AC_SYS_COMPILER])dnl 2900145b7b3cSmrgAC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext], 2901145b7b3cSmrg [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)], 2902145b7b3cSmrg [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no 2903145b7b3cSmrg $rm -r conftest 2>/dev/null 2904145b7b3cSmrg mkdir conftest 2905145b7b3cSmrg cd conftest 2906145b7b3cSmrg mkdir out 2907578741aaSmrg echo "$lt_simple_compile_test_code" > conftest.$ac_ext 2908145b7b3cSmrg 2909145b7b3cSmrg lt_compiler_flag="-o out/conftest2.$ac_objext" 2910145b7b3cSmrg # Insert the option either (1) after the last *FLAGS variable, or 2911145b7b3cSmrg # (2) before a word containing "conftest.", or (3) at the end. 2912145b7b3cSmrg # Note that $ac_compile itself does not contain backslashes and begins 2913145b7b3cSmrg # with a dollar sign (not a hyphen), so the echo should work correctly. 2914145b7b3cSmrg lt_compile=`echo "$ac_compile" | $SED \ 2915145b7b3cSmrg -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ 2916145b7b3cSmrg -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ 2917145b7b3cSmrg -e 's:$: $lt_compiler_flag:'` 2918145b7b3cSmrg (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD) 2919145b7b3cSmrg (eval "$lt_compile" 2>out/conftest.err) 2920145b7b3cSmrg ac_status=$? 2921145b7b3cSmrg cat out/conftest.err >&AS_MESSAGE_LOG_FD 2922145b7b3cSmrg echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD 2923145b7b3cSmrg if (exit $ac_status) && test -s out/conftest2.$ac_objext 2924145b7b3cSmrg then 2925145b7b3cSmrg # The compiler can only warn and ignore the option if not recognized 2926145b7b3cSmrg # So say no if there are warnings 2927145b7b3cSmrg $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp 2928145b7b3cSmrg $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 2929145b7b3cSmrg if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then 2930145b7b3cSmrg _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes 2931145b7b3cSmrg fi 2932145b7b3cSmrg fi 2933145b7b3cSmrg chmod u+w . 2>&AS_MESSAGE_LOG_FD 2934145b7b3cSmrg $rm conftest* 2935145b7b3cSmrg # SGI C++ compiler will create directory out/ii_files/ for 2936145b7b3cSmrg # template instantiation 2937145b7b3cSmrg test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files 2938145b7b3cSmrg $rm out/* && rmdir out 2939145b7b3cSmrg cd .. 2940145b7b3cSmrg rmdir conftest 2941145b7b3cSmrg $rm conftest* 2942145b7b3cSmrg]) 2943145b7b3cSmrg])# AC_LIBTOOL_PROG_CC_C_O 2944145b7b3cSmrg 2945145b7b3cSmrg 2946145b7b3cSmrg# AC_LIBTOOL_SYS_HARD_LINK_LOCKS([TAGNAME]) 2947145b7b3cSmrg# ----------------------------------------- 2948145b7b3cSmrg# Check to see if we can do hard links to lock some files if needed 2949145b7b3cSmrgAC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], 2950145b7b3cSmrg[AC_REQUIRE([_LT_AC_LOCK])dnl 2951145b7b3cSmrg 2952145b7b3cSmrghard_links="nottested" 2953145b7b3cSmrgif test "$_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then 2954145b7b3cSmrg # do not overwrite the value of need_locks provided by the user 2955145b7b3cSmrg AC_MSG_CHECKING([if we can lock with hard links]) 2956145b7b3cSmrg hard_links=yes 2957145b7b3cSmrg $rm conftest* 2958145b7b3cSmrg ln conftest.a conftest.b 2>/dev/null && hard_links=no 2959145b7b3cSmrg touch conftest.a 2960145b7b3cSmrg ln conftest.a conftest.b 2>&5 || hard_links=no 2961145b7b3cSmrg ln conftest.a conftest.b 2>/dev/null && hard_links=no 2962145b7b3cSmrg AC_MSG_RESULT([$hard_links]) 2963145b7b3cSmrg if test "$hard_links" = no; then 2964145b7b3cSmrg AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe]) 2965145b7b3cSmrg need_locks=warn 2966145b7b3cSmrg fi 2967145b7b3cSmrgelse 2968145b7b3cSmrg need_locks=no 2969145b7b3cSmrgfi 2970145b7b3cSmrg])# AC_LIBTOOL_SYS_HARD_LINK_LOCKS 2971145b7b3cSmrg 2972145b7b3cSmrg 2973145b7b3cSmrg# AC_LIBTOOL_OBJDIR 2974145b7b3cSmrg# ----------------- 2975145b7b3cSmrgAC_DEFUN([AC_LIBTOOL_OBJDIR], 2976145b7b3cSmrg[AC_CACHE_CHECK([for objdir], [lt_cv_objdir], 2977145b7b3cSmrg[rm -f .libs 2>/dev/null 2978145b7b3cSmrgmkdir .libs 2>/dev/null 2979145b7b3cSmrgif test -d .libs; then 2980145b7b3cSmrg lt_cv_objdir=.libs 2981145b7b3cSmrgelse 2982145b7b3cSmrg # MS-DOS does not allow filenames that begin with a dot. 2983145b7b3cSmrg lt_cv_objdir=_libs 2984145b7b3cSmrgfi 2985145b7b3cSmrgrmdir .libs 2>/dev/null]) 2986145b7b3cSmrgobjdir=$lt_cv_objdir 2987145b7b3cSmrg])# AC_LIBTOOL_OBJDIR 2988145b7b3cSmrg 2989145b7b3cSmrg 2990145b7b3cSmrg# AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH([TAGNAME]) 2991145b7b3cSmrg# ---------------------------------------------- 2992145b7b3cSmrg# Check hardcoding attributes. 2993145b7b3cSmrgAC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], 2994145b7b3cSmrg[AC_MSG_CHECKING([how to hardcode library paths into programs]) 2995145b7b3cSmrg_LT_AC_TAGVAR(hardcode_action, $1)= 2996145b7b3cSmrgif test -n "$_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)" || \ 2997145b7b3cSmrg test -n "$_LT_AC_TAGVAR(runpath_var, $1)" || \ 2998145b7b3cSmrg test "X$_LT_AC_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then 2999145b7b3cSmrg 3000145b7b3cSmrg # We can hardcode non-existant directories. 3001145b7b3cSmrg if test "$_LT_AC_TAGVAR(hardcode_direct, $1)" != no && 3002145b7b3cSmrg # If the only mechanism to avoid hardcoding is shlibpath_var, we 3003145b7b3cSmrg # have to relink, otherwise we might link with an installed library 3004145b7b3cSmrg # when we should be linking with a yet-to-be-installed one 3005145b7b3cSmrg ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)" != no && 3006145b7b3cSmrg test "$_LT_AC_TAGVAR(hardcode_minus_L, $1)" != no; then 3007145b7b3cSmrg # Linking always hardcodes the temporary library directory. 3008145b7b3cSmrg _LT_AC_TAGVAR(hardcode_action, $1)=relink 3009145b7b3cSmrg else 3010145b7b3cSmrg # We can link without hardcoding, and we can hardcode nonexisting dirs. 3011145b7b3cSmrg _LT_AC_TAGVAR(hardcode_action, $1)=immediate 3012145b7b3cSmrg fi 3013145b7b3cSmrgelse 3014145b7b3cSmrg # We cannot hardcode anything, or else we can only hardcode existing 3015145b7b3cSmrg # directories. 3016145b7b3cSmrg _LT_AC_TAGVAR(hardcode_action, $1)=unsupported 3017145b7b3cSmrgfi 3018145b7b3cSmrgAC_MSG_RESULT([$_LT_AC_TAGVAR(hardcode_action, $1)]) 3019145b7b3cSmrg 3020145b7b3cSmrgif test "$_LT_AC_TAGVAR(hardcode_action, $1)" = relink; then 3021145b7b3cSmrg # Fast installation is not supported 3022145b7b3cSmrg enable_fast_install=no 3023145b7b3cSmrgelif test "$shlibpath_overrides_runpath" = yes || 3024145b7b3cSmrg test "$enable_shared" = no; then 3025145b7b3cSmrg # Fast installation is not necessary 3026145b7b3cSmrg enable_fast_install=needless 3027145b7b3cSmrgfi 3028145b7b3cSmrg])# AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH 3029145b7b3cSmrg 3030145b7b3cSmrg 3031145b7b3cSmrg# AC_LIBTOOL_SYS_LIB_STRIP 3032145b7b3cSmrg# ------------------------ 3033145b7b3cSmrgAC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP], 3034145b7b3cSmrg[striplib= 3035145b7b3cSmrgold_striplib= 3036145b7b3cSmrgAC_MSG_CHECKING([whether stripping libraries is possible]) 3037145b7b3cSmrgif test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then 3038145b7b3cSmrg test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" 3039145b7b3cSmrg test -z "$striplib" && striplib="$STRIP --strip-unneeded" 3040145b7b3cSmrg AC_MSG_RESULT([yes]) 3041145b7b3cSmrgelse 3042145b7b3cSmrg# FIXME - insert some real tests, host_os isn't really good enough 3043145b7b3cSmrg case $host_os in 3044145b7b3cSmrg darwin*) 3045145b7b3cSmrg if test -n "$STRIP" ; then 3046145b7b3cSmrg striplib="$STRIP -x" 3047578741aaSmrg old_striplib="$STRIP -S" 3048145b7b3cSmrg AC_MSG_RESULT([yes]) 3049145b7b3cSmrg else 3050145b7b3cSmrg AC_MSG_RESULT([no]) 3051145b7b3cSmrgfi 3052145b7b3cSmrg ;; 3053145b7b3cSmrg *) 3054145b7b3cSmrg AC_MSG_RESULT([no]) 3055145b7b3cSmrg ;; 3056145b7b3cSmrg esac 3057145b7b3cSmrgfi 3058145b7b3cSmrg])# AC_LIBTOOL_SYS_LIB_STRIP 3059145b7b3cSmrg 3060145b7b3cSmrg 3061145b7b3cSmrg# AC_LIBTOOL_SYS_DYNAMIC_LINKER 3062145b7b3cSmrg# ----------------------------- 3063145b7b3cSmrg# PORTME Fill in your ld.so characteristics 3064145b7b3cSmrgAC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER], 3065578741aaSmrg[AC_REQUIRE([LT_AC_PROG_SED])dnl 3066578741aaSmrgAC_MSG_CHECKING([dynamic linker characteristics]) 3067145b7b3cSmrglibrary_names_spec= 3068145b7b3cSmrglibname_spec='lib$name' 3069145b7b3cSmrgsoname_spec= 3070145b7b3cSmrgshrext_cmds=".so" 3071145b7b3cSmrgpostinstall_cmds= 3072145b7b3cSmrgpostuninstall_cmds= 3073145b7b3cSmrgfinish_cmds= 3074145b7b3cSmrgfinish_eval= 3075145b7b3cSmrgshlibpath_var= 3076145b7b3cSmrgshlibpath_overrides_runpath=unknown 3077145b7b3cSmrgversion_type=none 3078145b7b3cSmrgdynamic_linker="$host_os ld.so" 3079145b7b3cSmrgsys_lib_dlsearch_path_spec="/lib /usr/lib" 3080578741aaSmrgm4_if($1,[],[ 3081145b7b3cSmrgif test "$GCC" = yes; then 3082578741aaSmrg case $host_os in 3083578741aaSmrg darwin*) lt_awk_arg="/^libraries:/,/LR/" ;; 3084578741aaSmrg *) lt_awk_arg="/^libraries:/" ;; 3085578741aaSmrg esac 3086578741aaSmrg lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e "s,=/,/,g"` 3087578741aaSmrg if echo "$lt_search_path_spec" | grep ';' >/dev/null ; then 3088145b7b3cSmrg # if the path contains ";" then we assume it to be the separator 3089145b7b3cSmrg # otherwise default to the standard path separator (i.e. ":") - it is 3090145b7b3cSmrg # assumed that no part of a normal pathname contains ";" but that should 3091145b7b3cSmrg # okay in the real world where ";" in dirpaths is itself problematic. 3092578741aaSmrg lt_search_path_spec=`echo "$lt_search_path_spec" | $SED -e 's/;/ /g'` 3093145b7b3cSmrg else 3094578741aaSmrg lt_search_path_spec=`echo "$lt_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` 3095145b7b3cSmrg fi 3096578741aaSmrg # Ok, now we have the path, separated by spaces, we can step through it 3097578741aaSmrg # and add multilib dir if necessary. 3098578741aaSmrg lt_tmp_lt_search_path_spec= 3099578741aaSmrg lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` 3100578741aaSmrg for lt_sys_path in $lt_search_path_spec; do 3101578741aaSmrg if test -d "$lt_sys_path/$lt_multi_os_dir"; then 3102578741aaSmrg lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir" 3103578741aaSmrg else 3104578741aaSmrg test -d "$lt_sys_path" && \ 3105578741aaSmrg lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" 3106578741aaSmrg fi 3107578741aaSmrg done 3108578741aaSmrg lt_search_path_spec=`echo $lt_tmp_lt_search_path_spec | awk ' 3109578741aaSmrgBEGIN {RS=" "; FS="/|\n";} { 3110578741aaSmrg lt_foo=""; 3111578741aaSmrg lt_count=0; 3112578741aaSmrg for (lt_i = NF; lt_i > 0; lt_i--) { 3113578741aaSmrg if ($lt_i != "" && $lt_i != ".") { 3114578741aaSmrg if ($lt_i == "..") { 3115578741aaSmrg lt_count++; 3116578741aaSmrg } else { 3117578741aaSmrg if (lt_count == 0) { 3118578741aaSmrg lt_foo="/" $lt_i lt_foo; 3119578741aaSmrg } else { 3120578741aaSmrg lt_count--; 3121578741aaSmrg } 3122578741aaSmrg } 3123578741aaSmrg } 3124578741aaSmrg } 3125578741aaSmrg if (lt_foo != "") { lt_freq[[lt_foo]]++; } 3126578741aaSmrg if (lt_freq[[lt_foo]] == 1) { print lt_foo; } 3127578741aaSmrg}'` 3128578741aaSmrg sys_lib_search_path_spec=`echo $lt_search_path_spec` 3129145b7b3cSmrgelse 3130145b7b3cSmrg sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" 3131578741aaSmrgfi]) 3132145b7b3cSmrgneed_lib_prefix=unknown 3133145b7b3cSmrghardcode_into_libs=no 3134145b7b3cSmrg 3135145b7b3cSmrg# when you set need_version to no, make sure it does not cause -set_version 3136145b7b3cSmrg# flags to be left without arguments 3137145b7b3cSmrgneed_version=unknown 3138145b7b3cSmrg 3139145b7b3cSmrgcase $host_os in 3140145b7b3cSmrgaix3*) 3141145b7b3cSmrg version_type=linux 3142145b7b3cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' 3143145b7b3cSmrg shlibpath_var=LIBPATH 3144145b7b3cSmrg 3145145b7b3cSmrg # AIX 3 has no versioning support, so we append a major version to the name. 3146145b7b3cSmrg soname_spec='${libname}${release}${shared_ext}$major' 3147145b7b3cSmrg ;; 3148145b7b3cSmrg 3149578741aaSmrgaix[[4-9]]*) 3150145b7b3cSmrg version_type=linux 3151145b7b3cSmrg need_lib_prefix=no 3152145b7b3cSmrg need_version=no 3153145b7b3cSmrg hardcode_into_libs=yes 3154145b7b3cSmrg if test "$host_cpu" = ia64; then 3155145b7b3cSmrg # AIX 5 supports IA64 3156145b7b3cSmrg library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' 3157145b7b3cSmrg shlibpath_var=LD_LIBRARY_PATH 3158145b7b3cSmrg else 3159145b7b3cSmrg # With GCC up to 2.95.x, collect2 would create an import file 3160145b7b3cSmrg # for dependence libraries. The import file would start with 3161145b7b3cSmrg # the line `#! .'. This would cause the generated library to 3162145b7b3cSmrg # depend on `.', always an invalid library. This was fixed in 3163145b7b3cSmrg # development snapshots of GCC prior to 3.0. 3164145b7b3cSmrg case $host_os in 3165145b7b3cSmrg aix4 | aix4.[[01]] | aix4.[[01]].*) 3166145b7b3cSmrg if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' 3167145b7b3cSmrg echo ' yes ' 3168145b7b3cSmrg echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then 3169145b7b3cSmrg : 3170145b7b3cSmrg else 3171145b7b3cSmrg can_build_shared=no 3172145b7b3cSmrg fi 3173145b7b3cSmrg ;; 3174145b7b3cSmrg esac 3175145b7b3cSmrg # AIX (on Power*) has no versioning support, so currently we can not hardcode correct 3176145b7b3cSmrg # soname into executable. Probably we can add versioning support to 3177145b7b3cSmrg # collect2, so additional links can be useful in future. 3178145b7b3cSmrg if test "$aix_use_runtimelinking" = yes; then 3179145b7b3cSmrg # If using run time linking (on AIX 4.2 or later) use lib<name>.so 3180145b7b3cSmrg # instead of lib<name>.a to let people know that these are not 3181145b7b3cSmrg # typical AIX shared libraries. 3182145b7b3cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 3183145b7b3cSmrg else 3184145b7b3cSmrg # We preserve .a as extension for shared libraries through AIX4.2 3185145b7b3cSmrg # and later when we are not doing run time linking. 3186145b7b3cSmrg library_names_spec='${libname}${release}.a $libname.a' 3187145b7b3cSmrg soname_spec='${libname}${release}${shared_ext}$major' 3188145b7b3cSmrg fi 3189145b7b3cSmrg shlibpath_var=LIBPATH 3190145b7b3cSmrg fi 3191145b7b3cSmrg ;; 3192145b7b3cSmrg 3193145b7b3cSmrgamigaos*) 3194145b7b3cSmrg library_names_spec='$libname.ixlibrary $libname.a' 3195145b7b3cSmrg # Create ${libname}_ixlibrary.a entries in /sys/libs. 3196145b7b3cSmrg finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' 3197145b7b3cSmrg ;; 3198145b7b3cSmrg 3199145b7b3cSmrgbeos*) 3200145b7b3cSmrg library_names_spec='${libname}${shared_ext}' 3201145b7b3cSmrg dynamic_linker="$host_os ld.so" 3202145b7b3cSmrg shlibpath_var=LIBRARY_PATH 3203145b7b3cSmrg ;; 3204145b7b3cSmrg 3205145b7b3cSmrgbsdi[[45]]*) 3206145b7b3cSmrg version_type=linux 3207145b7b3cSmrg need_version=no 3208145b7b3cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 3209145b7b3cSmrg soname_spec='${libname}${release}${shared_ext}$major' 3210145b7b3cSmrg finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' 3211145b7b3cSmrg shlibpath_var=LD_LIBRARY_PATH 3212145b7b3cSmrg sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" 3213145b7b3cSmrg sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" 3214145b7b3cSmrg # the default ld.so.conf also contains /usr/contrib/lib and 3215145b7b3cSmrg # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow 3216145b7b3cSmrg # libtool to hard-code these into programs 3217145b7b3cSmrg ;; 3218145b7b3cSmrg 3219145b7b3cSmrgcygwin* | mingw* | pw32*) 3220145b7b3cSmrg version_type=windows 3221145b7b3cSmrg shrext_cmds=".dll" 3222145b7b3cSmrg need_version=no 3223145b7b3cSmrg need_lib_prefix=no 3224145b7b3cSmrg 3225145b7b3cSmrg case $GCC,$host_os in 3226145b7b3cSmrg yes,cygwin* | yes,mingw* | yes,pw32*) 3227145b7b3cSmrg library_names_spec='$libname.dll.a' 3228145b7b3cSmrg # DLL is installed to $(libdir)/../bin by postinstall_cmds 3229145b7b3cSmrg postinstall_cmds='base_file=`basename \${file}`~ 3230145b7b3cSmrg dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~ 3231145b7b3cSmrg dldir=$destdir/`dirname \$dlpath`~ 3232145b7b3cSmrg test -d \$dldir || mkdir -p \$dldir~ 3233145b7b3cSmrg $install_prog $dir/$dlname \$dldir/$dlname~ 3234145b7b3cSmrg chmod a+x \$dldir/$dlname' 3235145b7b3cSmrg postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ 3236145b7b3cSmrg dlpath=$dir/\$dldll~ 3237145b7b3cSmrg $rm \$dlpath' 3238145b7b3cSmrg shlibpath_overrides_runpath=yes 3239145b7b3cSmrg 3240145b7b3cSmrg case $host_os in 3241145b7b3cSmrg cygwin*) 3242145b7b3cSmrg # Cygwin DLLs use 'cyg' prefix rather than 'lib' 3243145b7b3cSmrg soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' 3244145b7b3cSmrg sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib" 3245145b7b3cSmrg ;; 3246145b7b3cSmrg mingw*) 3247145b7b3cSmrg # MinGW DLLs use traditional 'lib' prefix 3248145b7b3cSmrg soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' 3249145b7b3cSmrg sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` 3250145b7b3cSmrg if echo "$sys_lib_search_path_spec" | [grep ';[c-zC-Z]:/' >/dev/null]; then 3251145b7b3cSmrg # It is most probably a Windows format PATH printed by 3252145b7b3cSmrg # mingw gcc, but we are running on Cygwin. Gcc prints its search 3253145b7b3cSmrg # path with ; separators, and with drive letters. We can handle the 3254145b7b3cSmrg # drive letters (cygwin fileutils understands them), so leave them, 3255145b7b3cSmrg # especially as we might pass files found there to a mingw objdump, 3256145b7b3cSmrg # which wouldn't understand a cygwinified path. Ahh. 3257145b7b3cSmrg sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` 3258145b7b3cSmrg else 3259145b7b3cSmrg sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` 3260145b7b3cSmrg fi 3261145b7b3cSmrg ;; 3262145b7b3cSmrg pw32*) 3263145b7b3cSmrg # pw32 DLLs use 'pw' prefix rather than 'lib' 3264145b7b3cSmrg library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' 3265145b7b3cSmrg ;; 3266145b7b3cSmrg esac 3267145b7b3cSmrg ;; 3268145b7b3cSmrg 3269145b7b3cSmrg *) 3270145b7b3cSmrg library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib' 3271145b7b3cSmrg ;; 3272145b7b3cSmrg esac 3273145b7b3cSmrg dynamic_linker='Win32 ld.exe' 3274145b7b3cSmrg # FIXME: first we should search . and the directory the executable is in 3275145b7b3cSmrg shlibpath_var=PATH 3276145b7b3cSmrg ;; 3277145b7b3cSmrg 3278145b7b3cSmrgdarwin* | rhapsody*) 3279145b7b3cSmrg dynamic_linker="$host_os dyld" 3280145b7b3cSmrg version_type=darwin 3281145b7b3cSmrg need_lib_prefix=no 3282145b7b3cSmrg need_version=no 3283145b7b3cSmrg library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext' 3284145b7b3cSmrg soname_spec='${libname}${release}${major}$shared_ext' 3285145b7b3cSmrg shlibpath_overrides_runpath=yes 3286145b7b3cSmrg shlibpath_var=DYLD_LIBRARY_PATH 3287145b7b3cSmrg shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' 3288578741aaSmrg m4_if([$1], [],[ 3289578741aaSmrg sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"]) 3290145b7b3cSmrg sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' 3291145b7b3cSmrg ;; 3292145b7b3cSmrg 3293145b7b3cSmrgdgux*) 3294145b7b3cSmrg version_type=linux 3295145b7b3cSmrg need_lib_prefix=no 3296145b7b3cSmrg need_version=no 3297145b7b3cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' 3298145b7b3cSmrg soname_spec='${libname}${release}${shared_ext}$major' 3299145b7b3cSmrg shlibpath_var=LD_LIBRARY_PATH 3300145b7b3cSmrg ;; 3301145b7b3cSmrg 3302145b7b3cSmrgfreebsd1*) 3303145b7b3cSmrg dynamic_linker=no 3304145b7b3cSmrg ;; 3305145b7b3cSmrg 3306145b7b3cSmrgfreebsd* | dragonfly*) 3307145b7b3cSmrg # DragonFly does not have aout. When/if they implement a new 3308145b7b3cSmrg # versioning mechanism, adjust this. 3309145b7b3cSmrg if test -x /usr/bin/objformat; then 3310145b7b3cSmrg objformat=`/usr/bin/objformat` 3311145b7b3cSmrg else 3312145b7b3cSmrg case $host_os in 3313145b7b3cSmrg freebsd[[123]]*) objformat=aout ;; 3314145b7b3cSmrg *) objformat=elf ;; 3315145b7b3cSmrg esac 3316145b7b3cSmrg fi 3317145b7b3cSmrg version_type=freebsd-$objformat 3318145b7b3cSmrg case $version_type in 3319145b7b3cSmrg freebsd-elf*) 3320145b7b3cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' 3321145b7b3cSmrg need_version=no 3322145b7b3cSmrg need_lib_prefix=no 3323145b7b3cSmrg ;; 3324145b7b3cSmrg freebsd-*) 3325145b7b3cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' 3326145b7b3cSmrg need_version=yes 3327145b7b3cSmrg ;; 3328145b7b3cSmrg esac 3329145b7b3cSmrg shlibpath_var=LD_LIBRARY_PATH 3330145b7b3cSmrg case $host_os in 3331145b7b3cSmrg freebsd2*) 3332145b7b3cSmrg shlibpath_overrides_runpath=yes 3333145b7b3cSmrg ;; 3334145b7b3cSmrg freebsd3.[[01]]* | freebsdelf3.[[01]]*) 3335145b7b3cSmrg shlibpath_overrides_runpath=yes 3336145b7b3cSmrg hardcode_into_libs=yes 3337145b7b3cSmrg ;; 3338145b7b3cSmrg freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \ 3339145b7b3cSmrg freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1) 3340145b7b3cSmrg shlibpath_overrides_runpath=no 3341145b7b3cSmrg hardcode_into_libs=yes 3342145b7b3cSmrg ;; 3343578741aaSmrg *) # from 4.6 on, and DragonFly 3344145b7b3cSmrg shlibpath_overrides_runpath=yes 3345145b7b3cSmrg hardcode_into_libs=yes 3346145b7b3cSmrg ;; 3347145b7b3cSmrg esac 3348145b7b3cSmrg ;; 3349145b7b3cSmrg 3350145b7b3cSmrggnu*) 3351145b7b3cSmrg version_type=linux 3352145b7b3cSmrg need_lib_prefix=no 3353145b7b3cSmrg need_version=no 3354145b7b3cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' 3355145b7b3cSmrg soname_spec='${libname}${release}${shared_ext}$major' 3356145b7b3cSmrg shlibpath_var=LD_LIBRARY_PATH 3357145b7b3cSmrg hardcode_into_libs=yes 3358145b7b3cSmrg ;; 3359145b7b3cSmrg 3360145b7b3cSmrghpux9* | hpux10* | hpux11*) 3361145b7b3cSmrg # Give a soname corresponding to the major version so that dld.sl refuses to 3362145b7b3cSmrg # link against other versions. 3363145b7b3cSmrg version_type=sunos 3364145b7b3cSmrg need_lib_prefix=no 3365145b7b3cSmrg need_version=no 3366145b7b3cSmrg case $host_cpu in 3367145b7b3cSmrg ia64*) 3368145b7b3cSmrg shrext_cmds='.so' 3369145b7b3cSmrg hardcode_into_libs=yes 3370145b7b3cSmrg dynamic_linker="$host_os dld.so" 3371145b7b3cSmrg shlibpath_var=LD_LIBRARY_PATH 3372145b7b3cSmrg shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. 3373145b7b3cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 3374145b7b3cSmrg soname_spec='${libname}${release}${shared_ext}$major' 3375145b7b3cSmrg if test "X$HPUX_IA64_MODE" = X32; then 3376145b7b3cSmrg sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" 3377145b7b3cSmrg else 3378145b7b3cSmrg sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" 3379145b7b3cSmrg fi 3380145b7b3cSmrg sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec 3381145b7b3cSmrg ;; 3382145b7b3cSmrg hppa*64*) 3383145b7b3cSmrg shrext_cmds='.sl' 3384145b7b3cSmrg hardcode_into_libs=yes 3385145b7b3cSmrg dynamic_linker="$host_os dld.sl" 3386145b7b3cSmrg shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH 3387145b7b3cSmrg shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. 3388145b7b3cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 3389145b7b3cSmrg soname_spec='${libname}${release}${shared_ext}$major' 3390145b7b3cSmrg sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" 3391145b7b3cSmrg sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec 3392145b7b3cSmrg ;; 3393145b7b3cSmrg *) 3394145b7b3cSmrg shrext_cmds='.sl' 3395145b7b3cSmrg dynamic_linker="$host_os dld.sl" 3396145b7b3cSmrg shlibpath_var=SHLIB_PATH 3397145b7b3cSmrg shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH 3398145b7b3cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 3399145b7b3cSmrg soname_spec='${libname}${release}${shared_ext}$major' 3400145b7b3cSmrg ;; 3401145b7b3cSmrg esac 3402145b7b3cSmrg # HP-UX runs *really* slowly unless shared libraries are mode 555. 3403145b7b3cSmrg postinstall_cmds='chmod 555 $lib' 3404145b7b3cSmrg ;; 3405145b7b3cSmrg 3406578741aaSmrginterix[[3-9]]*) 3407145b7b3cSmrg version_type=linux 3408145b7b3cSmrg need_lib_prefix=no 3409145b7b3cSmrg need_version=no 3410145b7b3cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' 3411145b7b3cSmrg soname_spec='${libname}${release}${shared_ext}$major' 3412145b7b3cSmrg dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' 3413145b7b3cSmrg shlibpath_var=LD_LIBRARY_PATH 3414145b7b3cSmrg shlibpath_overrides_runpath=no 3415145b7b3cSmrg hardcode_into_libs=yes 3416145b7b3cSmrg ;; 3417145b7b3cSmrg 3418145b7b3cSmrgirix5* | irix6* | nonstopux*) 3419145b7b3cSmrg case $host_os in 3420145b7b3cSmrg nonstopux*) version_type=nonstopux ;; 3421145b7b3cSmrg *) 3422145b7b3cSmrg if test "$lt_cv_prog_gnu_ld" = yes; then 3423145b7b3cSmrg version_type=linux 3424145b7b3cSmrg else 3425145b7b3cSmrg version_type=irix 3426145b7b3cSmrg fi ;; 3427145b7b3cSmrg esac 3428145b7b3cSmrg need_lib_prefix=no 3429145b7b3cSmrg need_version=no 3430145b7b3cSmrg soname_spec='${libname}${release}${shared_ext}$major' 3431145b7b3cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' 3432145b7b3cSmrg case $host_os in 3433145b7b3cSmrg irix5* | nonstopux*) 3434145b7b3cSmrg libsuff= shlibsuff= 3435145b7b3cSmrg ;; 3436145b7b3cSmrg *) 3437145b7b3cSmrg case $LD in # libtool.m4 will add one of these switches to LD 3438145b7b3cSmrg *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") 3439145b7b3cSmrg libsuff= shlibsuff= libmagic=32-bit;; 3440145b7b3cSmrg *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") 3441145b7b3cSmrg libsuff=32 shlibsuff=N32 libmagic=N32;; 3442145b7b3cSmrg *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") 3443145b7b3cSmrg libsuff=64 shlibsuff=64 libmagic=64-bit;; 3444145b7b3cSmrg *) libsuff= shlibsuff= libmagic=never-match;; 3445145b7b3cSmrg esac 3446145b7b3cSmrg ;; 3447145b7b3cSmrg esac 3448145b7b3cSmrg shlibpath_var=LD_LIBRARY${shlibsuff}_PATH 3449145b7b3cSmrg shlibpath_overrides_runpath=no 3450145b7b3cSmrg sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" 3451145b7b3cSmrg sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" 3452145b7b3cSmrg hardcode_into_libs=yes 3453145b7b3cSmrg ;; 3454145b7b3cSmrg 3455145b7b3cSmrg# No shared lib support for Linux oldld, aout, or coff. 3456145b7b3cSmrglinux*oldld* | linux*aout* | linux*coff*) 3457145b7b3cSmrg dynamic_linker=no 3458145b7b3cSmrg ;; 3459145b7b3cSmrg 3460145b7b3cSmrg# This must be Linux ELF. 3461578741aaSmrglinux* | k*bsd*-gnu) 3462145b7b3cSmrg version_type=linux 3463145b7b3cSmrg need_lib_prefix=no 3464145b7b3cSmrg need_version=no 3465145b7b3cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 3466145b7b3cSmrg soname_spec='${libname}${release}${shared_ext}$major' 3467145b7b3cSmrg finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' 3468145b7b3cSmrg shlibpath_var=LD_LIBRARY_PATH 3469145b7b3cSmrg shlibpath_overrides_runpath=no 3470145b7b3cSmrg # This implies no fast_install, which is unacceptable. 3471145b7b3cSmrg # Some rework will be needed to allow for fast_install 3472145b7b3cSmrg # before this can be enabled. 3473145b7b3cSmrg hardcode_into_libs=yes 3474145b7b3cSmrg 3475145b7b3cSmrg # Append ld.so.conf contents to the search path 3476145b7b3cSmrg if test -f /etc/ld.so.conf; then 3477578741aaSmrg lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '` 3478145b7b3cSmrg sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" 3479145b7b3cSmrg fi 3480145b7b3cSmrg 3481145b7b3cSmrg # We used to test for /lib/ld.so.1 and disable shared libraries on 3482145b7b3cSmrg # powerpc, because MkLinux only supported shared libraries with the 3483145b7b3cSmrg # GNU dynamic linker. Since this was broken with cross compilers, 3484145b7b3cSmrg # most powerpc-linux boxes support dynamic linking these days and 3485145b7b3cSmrg # people can always --disable-shared, the test was removed, and we 3486145b7b3cSmrg # assume the GNU/Linux dynamic linker is in use. 3487145b7b3cSmrg dynamic_linker='GNU/Linux ld.so' 3488145b7b3cSmrg ;; 3489145b7b3cSmrg 3490145b7b3cSmrgnetbsd*) 3491145b7b3cSmrg version_type=sunos 3492145b7b3cSmrg need_lib_prefix=no 3493145b7b3cSmrg need_version=no 3494145b7b3cSmrg if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then 3495145b7b3cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' 3496145b7b3cSmrg finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' 3497145b7b3cSmrg dynamic_linker='NetBSD (a.out) ld.so' 3498145b7b3cSmrg else 3499145b7b3cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' 3500145b7b3cSmrg soname_spec='${libname}${release}${shared_ext}$major' 3501145b7b3cSmrg dynamic_linker='NetBSD ld.elf_so' 3502145b7b3cSmrg fi 3503145b7b3cSmrg shlibpath_var=LD_LIBRARY_PATH 3504145b7b3cSmrg shlibpath_overrides_runpath=yes 3505145b7b3cSmrg hardcode_into_libs=yes 3506145b7b3cSmrg ;; 3507145b7b3cSmrg 3508145b7b3cSmrgnewsos6) 3509145b7b3cSmrg version_type=linux 3510145b7b3cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 3511145b7b3cSmrg shlibpath_var=LD_LIBRARY_PATH 3512145b7b3cSmrg shlibpath_overrides_runpath=yes 3513145b7b3cSmrg ;; 3514145b7b3cSmrg 3515145b7b3cSmrgnto-qnx*) 3516145b7b3cSmrg version_type=linux 3517145b7b3cSmrg need_lib_prefix=no 3518145b7b3cSmrg need_version=no 3519145b7b3cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 3520145b7b3cSmrg soname_spec='${libname}${release}${shared_ext}$major' 3521145b7b3cSmrg shlibpath_var=LD_LIBRARY_PATH 3522145b7b3cSmrg shlibpath_overrides_runpath=yes 3523145b7b3cSmrg ;; 3524145b7b3cSmrg 3525145b7b3cSmrgopenbsd*) 3526145b7b3cSmrg version_type=sunos 3527145b7b3cSmrg sys_lib_dlsearch_path_spec="/usr/lib" 3528145b7b3cSmrg need_lib_prefix=no 3529145b7b3cSmrg # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. 3530145b7b3cSmrg case $host_os in 3531145b7b3cSmrg openbsd3.3 | openbsd3.3.*) need_version=yes ;; 3532145b7b3cSmrg *) need_version=no ;; 3533145b7b3cSmrg esac 3534145b7b3cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' 3535145b7b3cSmrg finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' 3536145b7b3cSmrg shlibpath_var=LD_LIBRARY_PATH 3537145b7b3cSmrg if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then 3538145b7b3cSmrg case $host_os in 3539145b7b3cSmrg openbsd2.[[89]] | openbsd2.[[89]].*) 3540145b7b3cSmrg shlibpath_overrides_runpath=no 3541145b7b3cSmrg ;; 3542145b7b3cSmrg *) 3543145b7b3cSmrg shlibpath_overrides_runpath=yes 3544145b7b3cSmrg ;; 3545145b7b3cSmrg esac 3546145b7b3cSmrg else 3547145b7b3cSmrg shlibpath_overrides_runpath=yes 3548145b7b3cSmrg fi 3549145b7b3cSmrg ;; 3550145b7b3cSmrg 3551145b7b3cSmrgos2*) 3552145b7b3cSmrg libname_spec='$name' 3553145b7b3cSmrg shrext_cmds=".dll" 3554145b7b3cSmrg need_lib_prefix=no 3555145b7b3cSmrg library_names_spec='$libname${shared_ext} $libname.a' 3556145b7b3cSmrg dynamic_linker='OS/2 ld.exe' 3557145b7b3cSmrg shlibpath_var=LIBPATH 3558145b7b3cSmrg ;; 3559145b7b3cSmrg 3560145b7b3cSmrgosf3* | osf4* | osf5*) 3561145b7b3cSmrg version_type=osf 3562145b7b3cSmrg need_lib_prefix=no 3563145b7b3cSmrg need_version=no 3564145b7b3cSmrg soname_spec='${libname}${release}${shared_ext}$major' 3565145b7b3cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 3566145b7b3cSmrg shlibpath_var=LD_LIBRARY_PATH 3567145b7b3cSmrg sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" 3568145b7b3cSmrg sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" 3569145b7b3cSmrg ;; 3570145b7b3cSmrg 3571578741aaSmrgrdos*) 3572578741aaSmrg dynamic_linker=no 3573578741aaSmrg ;; 3574578741aaSmrg 3575145b7b3cSmrgsolaris*) 3576145b7b3cSmrg version_type=linux 3577145b7b3cSmrg need_lib_prefix=no 3578145b7b3cSmrg need_version=no 3579145b7b3cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 3580145b7b3cSmrg soname_spec='${libname}${release}${shared_ext}$major' 3581145b7b3cSmrg shlibpath_var=LD_LIBRARY_PATH 3582145b7b3cSmrg shlibpath_overrides_runpath=yes 3583145b7b3cSmrg hardcode_into_libs=yes 3584145b7b3cSmrg # ldd complains unless libraries are executable 3585145b7b3cSmrg postinstall_cmds='chmod +x $lib' 3586145b7b3cSmrg ;; 3587145b7b3cSmrg 3588145b7b3cSmrgsunos4*) 3589145b7b3cSmrg version_type=sunos 3590145b7b3cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' 3591145b7b3cSmrg finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' 3592145b7b3cSmrg shlibpath_var=LD_LIBRARY_PATH 3593145b7b3cSmrg shlibpath_overrides_runpath=yes 3594145b7b3cSmrg if test "$with_gnu_ld" = yes; then 3595145b7b3cSmrg need_lib_prefix=no 3596145b7b3cSmrg fi 3597145b7b3cSmrg need_version=yes 3598145b7b3cSmrg ;; 3599145b7b3cSmrg 3600145b7b3cSmrgsysv4 | sysv4.3*) 3601145b7b3cSmrg version_type=linux 3602145b7b3cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 3603145b7b3cSmrg soname_spec='${libname}${release}${shared_ext}$major' 3604145b7b3cSmrg shlibpath_var=LD_LIBRARY_PATH 3605145b7b3cSmrg case $host_vendor in 3606145b7b3cSmrg sni) 3607145b7b3cSmrg shlibpath_overrides_runpath=no 3608145b7b3cSmrg need_lib_prefix=no 3609145b7b3cSmrg export_dynamic_flag_spec='${wl}-Blargedynsym' 3610145b7b3cSmrg runpath_var=LD_RUN_PATH 3611145b7b3cSmrg ;; 3612145b7b3cSmrg siemens) 3613145b7b3cSmrg need_lib_prefix=no 3614145b7b3cSmrg ;; 3615145b7b3cSmrg motorola) 3616145b7b3cSmrg need_lib_prefix=no 3617145b7b3cSmrg need_version=no 3618145b7b3cSmrg shlibpath_overrides_runpath=no 3619145b7b3cSmrg sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' 3620145b7b3cSmrg ;; 3621145b7b3cSmrg esac 3622145b7b3cSmrg ;; 3623145b7b3cSmrg 3624145b7b3cSmrgsysv4*MP*) 3625145b7b3cSmrg if test -d /usr/nec ;then 3626145b7b3cSmrg version_type=linux 3627145b7b3cSmrg library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' 3628145b7b3cSmrg soname_spec='$libname${shared_ext}.$major' 3629145b7b3cSmrg shlibpath_var=LD_LIBRARY_PATH 3630145b7b3cSmrg fi 3631145b7b3cSmrg ;; 3632145b7b3cSmrg 3633145b7b3cSmrgsysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) 3634145b7b3cSmrg version_type=freebsd-elf 3635145b7b3cSmrg need_lib_prefix=no 3636145b7b3cSmrg need_version=no 3637145b7b3cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' 3638145b7b3cSmrg soname_spec='${libname}${release}${shared_ext}$major' 3639145b7b3cSmrg shlibpath_var=LD_LIBRARY_PATH 3640145b7b3cSmrg hardcode_into_libs=yes 3641145b7b3cSmrg if test "$with_gnu_ld" = yes; then 3642145b7b3cSmrg sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' 3643145b7b3cSmrg shlibpath_overrides_runpath=no 3644145b7b3cSmrg else 3645145b7b3cSmrg sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' 3646145b7b3cSmrg shlibpath_overrides_runpath=yes 3647145b7b3cSmrg case $host_os in 3648145b7b3cSmrg sco3.2v5*) 3649145b7b3cSmrg sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" 3650145b7b3cSmrg ;; 3651145b7b3cSmrg esac 3652145b7b3cSmrg fi 3653145b7b3cSmrg sys_lib_dlsearch_path_spec='/usr/lib' 3654145b7b3cSmrg ;; 3655145b7b3cSmrg 3656145b7b3cSmrguts4*) 3657145b7b3cSmrg version_type=linux 3658145b7b3cSmrg library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' 3659145b7b3cSmrg soname_spec='${libname}${release}${shared_ext}$major' 3660145b7b3cSmrg shlibpath_var=LD_LIBRARY_PATH 3661145b7b3cSmrg ;; 3662145b7b3cSmrg 3663145b7b3cSmrg*) 3664145b7b3cSmrg dynamic_linker=no 3665145b7b3cSmrg ;; 3666145b7b3cSmrgesac 3667145b7b3cSmrgAC_MSG_RESULT([$dynamic_linker]) 3668145b7b3cSmrgtest "$dynamic_linker" = no && can_build_shared=no 3669145b7b3cSmrg 3670578741aaSmrgAC_CACHE_VAL([lt_cv_sys_lib_search_path_spec], 3671578741aaSmrg[lt_cv_sys_lib_search_path_spec="$sys_lib_search_path_spec"]) 3672578741aaSmrgsys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" 3673578741aaSmrgAC_CACHE_VAL([lt_cv_sys_lib_dlsearch_path_spec], 3674578741aaSmrg[lt_cv_sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec"]) 3675578741aaSmrgsys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" 3676578741aaSmrg 3677145b7b3cSmrgvariables_saved_for_relink="PATH $shlibpath_var $runpath_var" 3678145b7b3cSmrgif test "$GCC" = yes; then 3679145b7b3cSmrg variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" 3680145b7b3cSmrgfi 3681145b7b3cSmrg])# AC_LIBTOOL_SYS_DYNAMIC_LINKER 3682145b7b3cSmrg 3683145b7b3cSmrg 3684145b7b3cSmrg# _LT_AC_TAGCONFIG 3685145b7b3cSmrg# ---------------- 3686145b7b3cSmrgAC_DEFUN([_LT_AC_TAGCONFIG], 3687578741aaSmrg[AC_REQUIRE([LT_AC_PROG_SED])dnl 3688578741aaSmrgAC_ARG_WITH([tags], 3689145b7b3cSmrg [AC_HELP_STRING([--with-tags@<:@=TAGS@:>@], 3690145b7b3cSmrg [include additional configurations @<:@automatic@:>@])], 3691145b7b3cSmrg [tagnames="$withval"]) 3692145b7b3cSmrg 3693145b7b3cSmrgif test -f "$ltmain" && test -n "$tagnames"; then 3694145b7b3cSmrg if test ! -f "${ofile}"; then 3695145b7b3cSmrg AC_MSG_WARN([output file `$ofile' does not exist]) 3696145b7b3cSmrg fi 3697145b7b3cSmrg 3698145b7b3cSmrg if test -z "$LTCC"; then 3699145b7b3cSmrg eval "`$SHELL ${ofile} --config | grep '^LTCC='`" 3700145b7b3cSmrg if test -z "$LTCC"; then 3701145b7b3cSmrg AC_MSG_WARN([output file `$ofile' does not look like a libtool script]) 3702145b7b3cSmrg else 3703145b7b3cSmrg AC_MSG_WARN([using `LTCC=$LTCC', extracted from `$ofile']) 3704145b7b3cSmrg fi 3705145b7b3cSmrg fi 3706145b7b3cSmrg if test -z "$LTCFLAGS"; then 3707145b7b3cSmrg eval "`$SHELL ${ofile} --config | grep '^LTCFLAGS='`" 3708145b7b3cSmrg fi 3709145b7b3cSmrg 3710145b7b3cSmrg # Extract list of available tagged configurations in $ofile. 3711145b7b3cSmrg # Note that this assumes the entire list is on one line. 3712145b7b3cSmrg available_tags=`grep "^available_tags=" "${ofile}" | $SED -e 's/available_tags=\(.*$\)/\1/' -e 's/\"//g'` 3713145b7b3cSmrg 3714145b7b3cSmrg lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," 3715145b7b3cSmrg for tagname in $tagnames; do 3716145b7b3cSmrg IFS="$lt_save_ifs" 3717145b7b3cSmrg # Check whether tagname contains only valid characters 3718145b7b3cSmrg case `$echo "X$tagname" | $Xsed -e 's:[[-_ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890,/]]::g'` in 3719145b7b3cSmrg "") ;; 3720145b7b3cSmrg *) AC_MSG_ERROR([invalid tag name: $tagname]) 3721145b7b3cSmrg ;; 3722145b7b3cSmrg esac 3723145b7b3cSmrg 3724145b7b3cSmrg if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$" < "${ofile}" > /dev/null 3725145b7b3cSmrg then 3726145b7b3cSmrg AC_MSG_ERROR([tag name \"$tagname\" already exists]) 3727145b7b3cSmrg fi 3728145b7b3cSmrg 3729145b7b3cSmrg # Update the list of available tags. 3730145b7b3cSmrg if test -n "$tagname"; then 3731145b7b3cSmrg echo appending configuration tag \"$tagname\" to $ofile 3732145b7b3cSmrg 3733145b7b3cSmrg case $tagname in 3734145b7b3cSmrg CXX) 3735145b7b3cSmrg if test -n "$CXX" && ( test "X$CXX" != "Xno" && 3736145b7b3cSmrg ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || 3737145b7b3cSmrg (test "X$CXX" != "Xg++"))) ; then 3738145b7b3cSmrg AC_LIBTOOL_LANG_CXX_CONFIG 3739145b7b3cSmrg else 3740145b7b3cSmrg tagname="" 3741145b7b3cSmrg fi 3742145b7b3cSmrg ;; 3743145b7b3cSmrg 3744145b7b3cSmrg F77) 3745145b7b3cSmrg if test -n "$F77" && test "X$F77" != "Xno"; then 3746145b7b3cSmrg AC_LIBTOOL_LANG_F77_CONFIG 3747145b7b3cSmrg else 3748145b7b3cSmrg tagname="" 3749145b7b3cSmrg fi 3750145b7b3cSmrg ;; 3751145b7b3cSmrg 3752145b7b3cSmrg GCJ) 3753145b7b3cSmrg if test -n "$GCJ" && test "X$GCJ" != "Xno"; then 3754145b7b3cSmrg AC_LIBTOOL_LANG_GCJ_CONFIG 3755145b7b3cSmrg else 3756145b7b3cSmrg tagname="" 3757145b7b3cSmrg fi 3758145b7b3cSmrg ;; 3759145b7b3cSmrg 3760145b7b3cSmrg RC) 3761145b7b3cSmrg AC_LIBTOOL_LANG_RC_CONFIG 3762145b7b3cSmrg ;; 3763145b7b3cSmrg 3764145b7b3cSmrg *) 3765145b7b3cSmrg AC_MSG_ERROR([Unsupported tag name: $tagname]) 3766145b7b3cSmrg ;; 3767145b7b3cSmrg esac 3768145b7b3cSmrg 3769145b7b3cSmrg # Append the new tag name to the list of available tags. 3770145b7b3cSmrg if test -n "$tagname" ; then 3771145b7b3cSmrg available_tags="$available_tags $tagname" 3772145b7b3cSmrg fi 3773145b7b3cSmrg fi 3774145b7b3cSmrg done 3775145b7b3cSmrg IFS="$lt_save_ifs" 3776145b7b3cSmrg 3777145b7b3cSmrg # Now substitute the updated list of available tags. 3778145b7b3cSmrg if eval "sed -e 's/^available_tags=.*\$/available_tags=\"$available_tags\"/' \"$ofile\" > \"${ofile}T\""; then 3779145b7b3cSmrg mv "${ofile}T" "$ofile" 3780145b7b3cSmrg chmod +x "$ofile" 3781145b7b3cSmrg else 3782145b7b3cSmrg rm -f "${ofile}T" 3783145b7b3cSmrg AC_MSG_ERROR([unable to update list of available tagged configurations.]) 3784145b7b3cSmrg fi 3785145b7b3cSmrgfi 3786145b7b3cSmrg])# _LT_AC_TAGCONFIG 3787145b7b3cSmrg 3788145b7b3cSmrg 3789145b7b3cSmrg# AC_LIBTOOL_DLOPEN 3790145b7b3cSmrg# ----------------- 3791145b7b3cSmrg# enable checks for dlopen support 3792145b7b3cSmrgAC_DEFUN([AC_LIBTOOL_DLOPEN], 3793145b7b3cSmrg [AC_BEFORE([$0],[AC_LIBTOOL_SETUP]) 3794145b7b3cSmrg])# AC_LIBTOOL_DLOPEN 3795145b7b3cSmrg 3796145b7b3cSmrg 3797145b7b3cSmrg# AC_LIBTOOL_WIN32_DLL 3798145b7b3cSmrg# -------------------- 3799145b7b3cSmrg# declare package support for building win32 DLLs 3800145b7b3cSmrgAC_DEFUN([AC_LIBTOOL_WIN32_DLL], 3801145b7b3cSmrg[AC_BEFORE([$0], [AC_LIBTOOL_SETUP]) 3802145b7b3cSmrg])# AC_LIBTOOL_WIN32_DLL 3803145b7b3cSmrg 3804145b7b3cSmrg 3805145b7b3cSmrg# AC_ENABLE_SHARED([DEFAULT]) 3806145b7b3cSmrg# --------------------------- 3807145b7b3cSmrg# implement the --enable-shared flag 3808145b7b3cSmrg# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. 3809145b7b3cSmrgAC_DEFUN([AC_ENABLE_SHARED], 3810145b7b3cSmrg[define([AC_ENABLE_SHARED_DEFAULT], ifelse($1, no, no, yes))dnl 3811145b7b3cSmrgAC_ARG_ENABLE([shared], 3812145b7b3cSmrg [AC_HELP_STRING([--enable-shared@<:@=PKGS@:>@], 3813145b7b3cSmrg [build shared libraries @<:@default=]AC_ENABLE_SHARED_DEFAULT[@:>@])], 3814145b7b3cSmrg [p=${PACKAGE-default} 3815145b7b3cSmrg case $enableval in 3816145b7b3cSmrg yes) enable_shared=yes ;; 3817145b7b3cSmrg no) enable_shared=no ;; 3818145b7b3cSmrg *) 3819145b7b3cSmrg enable_shared=no 3820145b7b3cSmrg # Look at the argument we got. We use all the common list separators. 3821145b7b3cSmrg lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," 3822145b7b3cSmrg for pkg in $enableval; do 3823145b7b3cSmrg IFS="$lt_save_ifs" 3824145b7b3cSmrg if test "X$pkg" = "X$p"; then 3825145b7b3cSmrg enable_shared=yes 3826145b7b3cSmrg fi 3827145b7b3cSmrg done 3828145b7b3cSmrg IFS="$lt_save_ifs" 3829145b7b3cSmrg ;; 3830145b7b3cSmrg esac], 3831145b7b3cSmrg [enable_shared=]AC_ENABLE_SHARED_DEFAULT) 3832145b7b3cSmrg])# AC_ENABLE_SHARED 3833145b7b3cSmrg 3834145b7b3cSmrg 3835145b7b3cSmrg# AC_DISABLE_SHARED 3836145b7b3cSmrg# ----------------- 3837145b7b3cSmrg# set the default shared flag to --disable-shared 3838145b7b3cSmrgAC_DEFUN([AC_DISABLE_SHARED], 3839145b7b3cSmrg[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl 3840145b7b3cSmrgAC_ENABLE_SHARED(no) 3841145b7b3cSmrg])# AC_DISABLE_SHARED 3842145b7b3cSmrg 3843145b7b3cSmrg 3844145b7b3cSmrg# AC_ENABLE_STATIC([DEFAULT]) 3845145b7b3cSmrg# --------------------------- 3846145b7b3cSmrg# implement the --enable-static flag 3847145b7b3cSmrg# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. 3848145b7b3cSmrgAC_DEFUN([AC_ENABLE_STATIC], 3849145b7b3cSmrg[define([AC_ENABLE_STATIC_DEFAULT], ifelse($1, no, no, yes))dnl 3850145b7b3cSmrgAC_ARG_ENABLE([static], 3851145b7b3cSmrg [AC_HELP_STRING([--enable-static@<:@=PKGS@:>@], 3852145b7b3cSmrg [build static libraries @<:@default=]AC_ENABLE_STATIC_DEFAULT[@:>@])], 3853145b7b3cSmrg [p=${PACKAGE-default} 3854145b7b3cSmrg case $enableval in 3855145b7b3cSmrg yes) enable_static=yes ;; 3856145b7b3cSmrg no) enable_static=no ;; 3857145b7b3cSmrg *) 3858145b7b3cSmrg enable_static=no 3859145b7b3cSmrg # Look at the argument we got. We use all the common list separators. 3860145b7b3cSmrg lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," 3861145b7b3cSmrg for pkg in $enableval; do 3862145b7b3cSmrg IFS="$lt_save_ifs" 3863145b7b3cSmrg if test "X$pkg" = "X$p"; then 3864145b7b3cSmrg enable_static=yes 3865145b7b3cSmrg fi 3866145b7b3cSmrg done 3867145b7b3cSmrg IFS="$lt_save_ifs" 3868145b7b3cSmrg ;; 3869145b7b3cSmrg esac], 3870145b7b3cSmrg [enable_static=]AC_ENABLE_STATIC_DEFAULT) 3871145b7b3cSmrg])# AC_ENABLE_STATIC 3872145b7b3cSmrg 3873145b7b3cSmrg 3874145b7b3cSmrg# AC_DISABLE_STATIC 3875145b7b3cSmrg# ----------------- 3876145b7b3cSmrg# set the default static flag to --disable-static 3877145b7b3cSmrgAC_DEFUN([AC_DISABLE_STATIC], 3878145b7b3cSmrg[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl 3879145b7b3cSmrgAC_ENABLE_STATIC(no) 3880145b7b3cSmrg])# AC_DISABLE_STATIC 3881145b7b3cSmrg 3882145b7b3cSmrg 3883145b7b3cSmrg# AC_ENABLE_FAST_INSTALL([DEFAULT]) 3884145b7b3cSmrg# --------------------------------- 3885145b7b3cSmrg# implement the --enable-fast-install flag 3886145b7b3cSmrg# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. 3887145b7b3cSmrgAC_DEFUN([AC_ENABLE_FAST_INSTALL], 3888145b7b3cSmrg[define([AC_ENABLE_FAST_INSTALL_DEFAULT], ifelse($1, no, no, yes))dnl 3889145b7b3cSmrgAC_ARG_ENABLE([fast-install], 3890145b7b3cSmrg [AC_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@], 3891145b7b3cSmrg [optimize for fast installation @<:@default=]AC_ENABLE_FAST_INSTALL_DEFAULT[@:>@])], 3892145b7b3cSmrg [p=${PACKAGE-default} 3893145b7b3cSmrg case $enableval in 3894145b7b3cSmrg yes) enable_fast_install=yes ;; 3895145b7b3cSmrg no) enable_fast_install=no ;; 3896145b7b3cSmrg *) 3897145b7b3cSmrg enable_fast_install=no 3898145b7b3cSmrg # Look at the argument we got. We use all the common list separators. 3899145b7b3cSmrg lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," 3900145b7b3cSmrg for pkg in $enableval; do 3901145b7b3cSmrg IFS="$lt_save_ifs" 3902145b7b3cSmrg if test "X$pkg" = "X$p"; then 3903145b7b3cSmrg enable_fast_install=yes 3904145b7b3cSmrg fi 3905145b7b3cSmrg done 3906145b7b3cSmrg IFS="$lt_save_ifs" 3907145b7b3cSmrg ;; 3908145b7b3cSmrg esac], 3909145b7b3cSmrg [enable_fast_install=]AC_ENABLE_FAST_INSTALL_DEFAULT) 3910145b7b3cSmrg])# AC_ENABLE_FAST_INSTALL 3911145b7b3cSmrg 3912145b7b3cSmrg 3913145b7b3cSmrg# AC_DISABLE_FAST_INSTALL 3914145b7b3cSmrg# ----------------------- 3915145b7b3cSmrg# set the default to --disable-fast-install 3916145b7b3cSmrgAC_DEFUN([AC_DISABLE_FAST_INSTALL], 3917145b7b3cSmrg[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl 3918145b7b3cSmrgAC_ENABLE_FAST_INSTALL(no) 3919145b7b3cSmrg])# AC_DISABLE_FAST_INSTALL 3920145b7b3cSmrg 3921145b7b3cSmrg 3922145b7b3cSmrg# AC_LIBTOOL_PICMODE([MODE]) 3923145b7b3cSmrg# -------------------------- 3924145b7b3cSmrg# implement the --with-pic flag 3925145b7b3cSmrg# MODE is either `yes' or `no'. If omitted, it defaults to `both'. 3926145b7b3cSmrgAC_DEFUN([AC_LIBTOOL_PICMODE], 3927145b7b3cSmrg[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl 3928145b7b3cSmrgpic_mode=ifelse($#,1,$1,default) 3929145b7b3cSmrg])# AC_LIBTOOL_PICMODE 3930145b7b3cSmrg 3931145b7b3cSmrg 3932145b7b3cSmrg# AC_PROG_EGREP 3933145b7b3cSmrg# ------------- 3934145b7b3cSmrg# This is predefined starting with Autoconf 2.54, so this conditional 3935145b7b3cSmrg# definition can be removed once we require Autoconf 2.54 or later. 3936145b7b3cSmrgm4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP], 3937145b7b3cSmrg[AC_CACHE_CHECK([for egrep], [ac_cv_prog_egrep], 3938145b7b3cSmrg [if echo a | (grep -E '(a|b)') >/dev/null 2>&1 3939145b7b3cSmrg then ac_cv_prog_egrep='grep -E' 3940145b7b3cSmrg else ac_cv_prog_egrep='egrep' 3941145b7b3cSmrg fi]) 3942145b7b3cSmrg EGREP=$ac_cv_prog_egrep 3943145b7b3cSmrg AC_SUBST([EGREP]) 3944145b7b3cSmrg])]) 3945145b7b3cSmrg 3946145b7b3cSmrg 3947145b7b3cSmrg# AC_PATH_TOOL_PREFIX 3948145b7b3cSmrg# ------------------- 3949578741aaSmrg# find a file program which can recognize shared library 3950145b7b3cSmrgAC_DEFUN([AC_PATH_TOOL_PREFIX], 3951145b7b3cSmrg[AC_REQUIRE([AC_PROG_EGREP])dnl 3952145b7b3cSmrgAC_MSG_CHECKING([for $1]) 3953145b7b3cSmrgAC_CACHE_VAL(lt_cv_path_MAGIC_CMD, 3954145b7b3cSmrg[case $MAGIC_CMD in 3955145b7b3cSmrg[[\\/*] | ?:[\\/]*]) 3956145b7b3cSmrg lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. 3957145b7b3cSmrg ;; 3958145b7b3cSmrg*) 3959145b7b3cSmrg lt_save_MAGIC_CMD="$MAGIC_CMD" 3960145b7b3cSmrg lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR 3961145b7b3cSmrgdnl $ac_dummy forces splitting on constant user-supplied paths. 3962145b7b3cSmrgdnl POSIX.2 word splitting is done only on the output of word expansions, 3963145b7b3cSmrgdnl not every word. This closes a longstanding sh security hole. 3964145b7b3cSmrg ac_dummy="ifelse([$2], , $PATH, [$2])" 3965145b7b3cSmrg for ac_dir in $ac_dummy; do 3966145b7b3cSmrg IFS="$lt_save_ifs" 3967145b7b3cSmrg test -z "$ac_dir" && ac_dir=. 3968145b7b3cSmrg if test -f $ac_dir/$1; then 3969145b7b3cSmrg lt_cv_path_MAGIC_CMD="$ac_dir/$1" 3970145b7b3cSmrg if test -n "$file_magic_test_file"; then 3971145b7b3cSmrg case $deplibs_check_method in 3972145b7b3cSmrg "file_magic "*) 3973145b7b3cSmrg file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` 3974145b7b3cSmrg MAGIC_CMD="$lt_cv_path_MAGIC_CMD" 3975145b7b3cSmrg if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | 3976145b7b3cSmrg $EGREP "$file_magic_regex" > /dev/null; then 3977145b7b3cSmrg : 3978145b7b3cSmrg else 3979145b7b3cSmrg cat <<EOF 1>&2 3980145b7b3cSmrg 3981145b7b3cSmrg*** Warning: the command libtool uses to detect shared libraries, 3982145b7b3cSmrg*** $file_magic_cmd, produces output that libtool cannot recognize. 3983145b7b3cSmrg*** The result is that libtool may fail to recognize shared libraries 3984145b7b3cSmrg*** as such. This will affect the creation of libtool libraries that 3985145b7b3cSmrg*** depend on shared libraries, but programs linked with such libtool 3986145b7b3cSmrg*** libraries will work regardless of this problem. Nevertheless, you 3987145b7b3cSmrg*** may want to report the problem to your system manager and/or to 3988145b7b3cSmrg*** bug-libtool@gnu.org 3989145b7b3cSmrg 3990145b7b3cSmrgEOF 3991145b7b3cSmrg fi ;; 3992145b7b3cSmrg esac 3993145b7b3cSmrg fi 3994145b7b3cSmrg break 3995145b7b3cSmrg fi 3996145b7b3cSmrg done 3997145b7b3cSmrg IFS="$lt_save_ifs" 3998145b7b3cSmrg MAGIC_CMD="$lt_save_MAGIC_CMD" 3999145b7b3cSmrg ;; 4000145b7b3cSmrgesac]) 4001145b7b3cSmrgMAGIC_CMD="$lt_cv_path_MAGIC_CMD" 4002145b7b3cSmrgif test -n "$MAGIC_CMD"; then 4003145b7b3cSmrg AC_MSG_RESULT($MAGIC_CMD) 4004145b7b3cSmrgelse 4005145b7b3cSmrg AC_MSG_RESULT(no) 4006145b7b3cSmrgfi 4007145b7b3cSmrg])# AC_PATH_TOOL_PREFIX 4008145b7b3cSmrg 4009145b7b3cSmrg 4010145b7b3cSmrg# AC_PATH_MAGIC 4011145b7b3cSmrg# ------------- 4012578741aaSmrg# find a file program which can recognize a shared library 4013145b7b3cSmrgAC_DEFUN([AC_PATH_MAGIC], 4014145b7b3cSmrg[AC_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH) 4015145b7b3cSmrgif test -z "$lt_cv_path_MAGIC_CMD"; then 4016145b7b3cSmrg if test -n "$ac_tool_prefix"; then 4017145b7b3cSmrg AC_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH) 4018145b7b3cSmrg else 4019145b7b3cSmrg MAGIC_CMD=: 4020145b7b3cSmrg fi 4021145b7b3cSmrgfi 4022145b7b3cSmrg])# AC_PATH_MAGIC 4023145b7b3cSmrg 4024145b7b3cSmrg 4025145b7b3cSmrg# AC_PROG_LD 4026145b7b3cSmrg# ---------- 4027145b7b3cSmrg# find the pathname to the GNU or non-GNU linker 4028145b7b3cSmrgAC_DEFUN([AC_PROG_LD], 4029145b7b3cSmrg[AC_ARG_WITH([gnu-ld], 4030145b7b3cSmrg [AC_HELP_STRING([--with-gnu-ld], 4031145b7b3cSmrg [assume the C compiler uses GNU ld @<:@default=no@:>@])], 4032145b7b3cSmrg [test "$withval" = no || with_gnu_ld=yes], 4033145b7b3cSmrg [with_gnu_ld=no]) 4034145b7b3cSmrgAC_REQUIRE([LT_AC_PROG_SED])dnl 4035145b7b3cSmrgAC_REQUIRE([AC_PROG_CC])dnl 4036145b7b3cSmrgAC_REQUIRE([AC_CANONICAL_HOST])dnl 4037145b7b3cSmrgAC_REQUIRE([AC_CANONICAL_BUILD])dnl 4038145b7b3cSmrgac_prog=ld 4039145b7b3cSmrgif test "$GCC" = yes; then 4040145b7b3cSmrg # Check if gcc -print-prog-name=ld gives a path. 4041145b7b3cSmrg AC_MSG_CHECKING([for ld used by $CC]) 4042145b7b3cSmrg case $host in 4043145b7b3cSmrg *-*-mingw*) 4044145b7b3cSmrg # gcc leaves a trailing carriage return which upsets mingw 4045145b7b3cSmrg ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; 4046145b7b3cSmrg *) 4047145b7b3cSmrg ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; 4048145b7b3cSmrg esac 4049145b7b3cSmrg case $ac_prog in 4050145b7b3cSmrg # Accept absolute paths. 4051145b7b3cSmrg [[\\/]]* | ?:[[\\/]]*) 4052145b7b3cSmrg re_direlt='/[[^/]][[^/]]*/\.\./' 4053145b7b3cSmrg # Canonicalize the pathname of ld 4054145b7b3cSmrg ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'` 4055145b7b3cSmrg while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do 4056145b7b3cSmrg ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"` 4057145b7b3cSmrg done 4058145b7b3cSmrg test -z "$LD" && LD="$ac_prog" 4059145b7b3cSmrg ;; 4060145b7b3cSmrg "") 4061145b7b3cSmrg # If it fails, then pretend we aren't using GCC. 4062145b7b3cSmrg ac_prog=ld 4063145b7b3cSmrg ;; 4064145b7b3cSmrg *) 4065145b7b3cSmrg # If it is relative, then search for the first ld in PATH. 4066145b7b3cSmrg with_gnu_ld=unknown 4067145b7b3cSmrg ;; 4068145b7b3cSmrg esac 4069145b7b3cSmrgelif test "$with_gnu_ld" = yes; then 4070145b7b3cSmrg AC_MSG_CHECKING([for GNU ld]) 4071145b7b3cSmrgelse 4072145b7b3cSmrg AC_MSG_CHECKING([for non-GNU ld]) 4073145b7b3cSmrgfi 4074145b7b3cSmrgAC_CACHE_VAL(lt_cv_path_LD, 4075145b7b3cSmrg[if test -z "$LD"; then 4076145b7b3cSmrg lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR 4077145b7b3cSmrg for ac_dir in $PATH; do 4078145b7b3cSmrg IFS="$lt_save_ifs" 4079145b7b3cSmrg test -z "$ac_dir" && ac_dir=. 4080145b7b3cSmrg if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then 4081145b7b3cSmrg lt_cv_path_LD="$ac_dir/$ac_prog" 4082145b7b3cSmrg # Check to see if the program is GNU ld. I'd rather use --version, 4083145b7b3cSmrg # but apparently some variants of GNU ld only accept -v. 4084145b7b3cSmrg # Break only if it was the GNU/non-GNU ld that we prefer. 4085145b7b3cSmrg case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in 4086145b7b3cSmrg *GNU* | *'with BFD'*) 4087145b7b3cSmrg test "$with_gnu_ld" != no && break 4088145b7b3cSmrg ;; 4089145b7b3cSmrg *) 4090145b7b3cSmrg test "$with_gnu_ld" != yes && break 4091145b7b3cSmrg ;; 4092145b7b3cSmrg esac 4093145b7b3cSmrg fi 4094145b7b3cSmrg done 4095145b7b3cSmrg IFS="$lt_save_ifs" 4096145b7b3cSmrgelse 4097145b7b3cSmrg lt_cv_path_LD="$LD" # Let the user override the test with a path. 4098145b7b3cSmrgfi]) 4099145b7b3cSmrgLD="$lt_cv_path_LD" 4100145b7b3cSmrgif test -n "$LD"; then 4101145b7b3cSmrg AC_MSG_RESULT($LD) 4102145b7b3cSmrgelse 4103145b7b3cSmrg AC_MSG_RESULT(no) 4104145b7b3cSmrgfi 4105145b7b3cSmrgtest -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH]) 4106145b7b3cSmrgAC_PROG_LD_GNU 4107145b7b3cSmrg])# AC_PROG_LD 4108145b7b3cSmrg 4109145b7b3cSmrg 4110145b7b3cSmrg# AC_PROG_LD_GNU 4111145b7b3cSmrg# -------------- 4112145b7b3cSmrgAC_DEFUN([AC_PROG_LD_GNU], 4113145b7b3cSmrg[AC_REQUIRE([AC_PROG_EGREP])dnl 4114145b7b3cSmrgAC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld, 4115145b7b3cSmrg[# I'd rather use --version here, but apparently some GNU lds only accept -v. 4116145b7b3cSmrgcase `$LD -v 2>&1 </dev/null` in 4117145b7b3cSmrg*GNU* | *'with BFD'*) 4118145b7b3cSmrg lt_cv_prog_gnu_ld=yes 4119145b7b3cSmrg ;; 4120145b7b3cSmrg*) 4121145b7b3cSmrg lt_cv_prog_gnu_ld=no 4122145b7b3cSmrg ;; 4123145b7b3cSmrgesac]) 4124145b7b3cSmrgwith_gnu_ld=$lt_cv_prog_gnu_ld 4125145b7b3cSmrg])# AC_PROG_LD_GNU 4126145b7b3cSmrg 4127145b7b3cSmrg 4128145b7b3cSmrg# AC_PROG_LD_RELOAD_FLAG 4129145b7b3cSmrg# ---------------------- 4130145b7b3cSmrg# find reload flag for linker 4131145b7b3cSmrg# -- PORTME Some linkers may need a different reload flag. 4132145b7b3cSmrgAC_DEFUN([AC_PROG_LD_RELOAD_FLAG], 4133145b7b3cSmrg[AC_CACHE_CHECK([for $LD option to reload object files], 4134145b7b3cSmrg lt_cv_ld_reload_flag, 4135145b7b3cSmrg [lt_cv_ld_reload_flag='-r']) 4136145b7b3cSmrgreload_flag=$lt_cv_ld_reload_flag 4137145b7b3cSmrgcase $reload_flag in 4138145b7b3cSmrg"" | " "*) ;; 4139145b7b3cSmrg*) reload_flag=" $reload_flag" ;; 4140145b7b3cSmrgesac 4141145b7b3cSmrgreload_cmds='$LD$reload_flag -o $output$reload_objs' 4142145b7b3cSmrgcase $host_os in 4143145b7b3cSmrg darwin*) 4144145b7b3cSmrg if test "$GCC" = yes; then 4145145b7b3cSmrg reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs' 4146145b7b3cSmrg else 4147145b7b3cSmrg reload_cmds='$LD$reload_flag -o $output$reload_objs' 4148145b7b3cSmrg fi 4149145b7b3cSmrg ;; 4150145b7b3cSmrgesac 4151145b7b3cSmrg])# AC_PROG_LD_RELOAD_FLAG 4152145b7b3cSmrg 4153145b7b3cSmrg 4154145b7b3cSmrg# AC_DEPLIBS_CHECK_METHOD 4155145b7b3cSmrg# ----------------------- 4156145b7b3cSmrg# how to check for library dependencies 4157145b7b3cSmrg# -- PORTME fill in with the dynamic library characteristics 4158145b7b3cSmrgAC_DEFUN([AC_DEPLIBS_CHECK_METHOD], 4159578741aaSmrg[AC_CACHE_CHECK([how to recognize dependent libraries], 4160145b7b3cSmrglt_cv_deplibs_check_method, 4161145b7b3cSmrg[lt_cv_file_magic_cmd='$MAGIC_CMD' 4162145b7b3cSmrglt_cv_file_magic_test_file= 4163145b7b3cSmrglt_cv_deplibs_check_method='unknown' 4164145b7b3cSmrg# Need to set the preceding variable on all platforms that support 4165145b7b3cSmrg# interlibrary dependencies. 4166145b7b3cSmrg# 'none' -- dependencies not supported. 4167145b7b3cSmrg# `unknown' -- same as none, but documents that we really don't know. 4168145b7b3cSmrg# 'pass_all' -- all dependencies passed with no checks. 4169145b7b3cSmrg# 'test_compile' -- check by making test program. 4170145b7b3cSmrg# 'file_magic [[regex]]' -- check by looking for files in library path 4171145b7b3cSmrg# which responds to the $file_magic_cmd with a given extended regex. 4172145b7b3cSmrg# If you have `file' or equivalent on your system and you're not sure 4173145b7b3cSmrg# whether `pass_all' will *always* work, you probably want this one. 4174145b7b3cSmrg 4175145b7b3cSmrgcase $host_os in 4176578741aaSmrgaix[[4-9]]*) 4177145b7b3cSmrg lt_cv_deplibs_check_method=pass_all 4178145b7b3cSmrg ;; 4179145b7b3cSmrg 4180145b7b3cSmrgbeos*) 4181145b7b3cSmrg lt_cv_deplibs_check_method=pass_all 4182145b7b3cSmrg ;; 4183145b7b3cSmrg 4184145b7b3cSmrgbsdi[[45]]*) 4185145b7b3cSmrg lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)' 4186145b7b3cSmrg lt_cv_file_magic_cmd='/usr/bin/file -L' 4187145b7b3cSmrg lt_cv_file_magic_test_file=/shlib/libc.so 4188145b7b3cSmrg ;; 4189145b7b3cSmrg 4190145b7b3cSmrgcygwin*) 4191145b7b3cSmrg # func_win32_libid is a shell function defined in ltmain.sh 4192145b7b3cSmrg lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' 4193145b7b3cSmrg lt_cv_file_magic_cmd='func_win32_libid' 4194145b7b3cSmrg ;; 4195145b7b3cSmrg 4196145b7b3cSmrgmingw* | pw32*) 4197145b7b3cSmrg # Base MSYS/MinGW do not provide the 'file' command needed by 4198578741aaSmrg # func_win32_libid shell function, so use a weaker test based on 'objdump', 4199578741aaSmrg # unless we find 'file', for example because we are cross-compiling. 4200578741aaSmrg if ( file / ) >/dev/null 2>&1; then 4201578741aaSmrg lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' 4202578741aaSmrg lt_cv_file_magic_cmd='func_win32_libid' 4203578741aaSmrg else 4204578741aaSmrg lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?' 4205578741aaSmrg lt_cv_file_magic_cmd='$OBJDUMP -f' 4206578741aaSmrg fi 4207145b7b3cSmrg ;; 4208145b7b3cSmrg 4209145b7b3cSmrgdarwin* | rhapsody*) 4210145b7b3cSmrg lt_cv_deplibs_check_method=pass_all 4211145b7b3cSmrg ;; 4212145b7b3cSmrg 4213578741aaSmrgfreebsd* | dragonfly*) 4214145b7b3cSmrg if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then 4215145b7b3cSmrg case $host_cpu in 4216145b7b3cSmrg i*86 ) 4217145b7b3cSmrg # Not sure whether the presence of OpenBSD here was a mistake. 4218145b7b3cSmrg # Let's accept both of them until this is cleared up. 4219145b7b3cSmrg lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library' 4220145b7b3cSmrg lt_cv_file_magic_cmd=/usr/bin/file 4221145b7b3cSmrg lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` 4222145b7b3cSmrg ;; 4223145b7b3cSmrg esac 4224145b7b3cSmrg else 4225145b7b3cSmrg lt_cv_deplibs_check_method=pass_all 4226145b7b3cSmrg fi 4227145b7b3cSmrg ;; 4228145b7b3cSmrg 4229145b7b3cSmrggnu*) 4230145b7b3cSmrg lt_cv_deplibs_check_method=pass_all 4231145b7b3cSmrg ;; 4232145b7b3cSmrg 4233145b7b3cSmrghpux10.20* | hpux11*) 4234145b7b3cSmrg lt_cv_file_magic_cmd=/usr/bin/file 4235145b7b3cSmrg case $host_cpu in 4236145b7b3cSmrg ia64*) 4237145b7b3cSmrg lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64' 4238145b7b3cSmrg lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so 4239145b7b3cSmrg ;; 4240145b7b3cSmrg hppa*64*) 4241145b7b3cSmrg [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - PA-RISC [0-9].[0-9]'] 4242145b7b3cSmrg lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl 4243145b7b3cSmrg ;; 4244145b7b3cSmrg *) 4245145b7b3cSmrg lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]].[[0-9]]) shared library' 4246145b7b3cSmrg lt_cv_file_magic_test_file=/usr/lib/libc.sl 4247145b7b3cSmrg ;; 4248145b7b3cSmrg esac 4249145b7b3cSmrg ;; 4250145b7b3cSmrg 4251578741aaSmrginterix[[3-9]]*) 4252145b7b3cSmrg # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here 4253145b7b3cSmrg lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$' 4254145b7b3cSmrg ;; 4255145b7b3cSmrg 4256145b7b3cSmrgirix5* | irix6* | nonstopux*) 4257145b7b3cSmrg case $LD in 4258145b7b3cSmrg *-32|*"-32 ") libmagic=32-bit;; 4259145b7b3cSmrg *-n32|*"-n32 ") libmagic=N32;; 4260145b7b3cSmrg *-64|*"-64 ") libmagic=64-bit;; 4261145b7b3cSmrg *) libmagic=never-match;; 4262145b7b3cSmrg esac 4263145b7b3cSmrg lt_cv_deplibs_check_method=pass_all 4264145b7b3cSmrg ;; 4265145b7b3cSmrg 4266145b7b3cSmrg# This must be Linux ELF. 4267578741aaSmrglinux* | k*bsd*-gnu) 4268145b7b3cSmrg lt_cv_deplibs_check_method=pass_all 4269145b7b3cSmrg ;; 4270145b7b3cSmrg 4271145b7b3cSmrgnetbsd*) 4272145b7b3cSmrg if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then 4273145b7b3cSmrg lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' 4274145b7b3cSmrg else 4275145b7b3cSmrg lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$' 4276145b7b3cSmrg fi 4277145b7b3cSmrg ;; 4278145b7b3cSmrg 4279145b7b3cSmrgnewos6*) 4280145b7b3cSmrg lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)' 4281145b7b3cSmrg lt_cv_file_magic_cmd=/usr/bin/file 4282145b7b3cSmrg lt_cv_file_magic_test_file=/usr/lib/libnls.so 4283145b7b3cSmrg ;; 4284145b7b3cSmrg 4285145b7b3cSmrgnto-qnx*) 4286145b7b3cSmrg lt_cv_deplibs_check_method=unknown 4287145b7b3cSmrg ;; 4288145b7b3cSmrg 4289145b7b3cSmrgopenbsd*) 4290145b7b3cSmrg if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then 4291145b7b3cSmrg lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$' 4292145b7b3cSmrg else 4293145b7b3cSmrg lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' 4294145b7b3cSmrg fi 4295145b7b3cSmrg ;; 4296145b7b3cSmrg 4297145b7b3cSmrgosf3* | osf4* | osf5*) 4298145b7b3cSmrg lt_cv_deplibs_check_method=pass_all 4299145b7b3cSmrg ;; 4300145b7b3cSmrg 4301578741aaSmrgrdos*) 4302578741aaSmrg lt_cv_deplibs_check_method=pass_all 4303578741aaSmrg ;; 4304578741aaSmrg 4305145b7b3cSmrgsolaris*) 4306145b7b3cSmrg lt_cv_deplibs_check_method=pass_all 4307145b7b3cSmrg ;; 4308145b7b3cSmrg 4309145b7b3cSmrgsysv4 | sysv4.3*) 4310145b7b3cSmrg case $host_vendor in 4311145b7b3cSmrg motorola) 4312145b7b3cSmrg 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]]' 4313145b7b3cSmrg lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` 4314145b7b3cSmrg ;; 4315145b7b3cSmrg ncr) 4316145b7b3cSmrg lt_cv_deplibs_check_method=pass_all 4317145b7b3cSmrg ;; 4318145b7b3cSmrg sequent) 4319145b7b3cSmrg lt_cv_file_magic_cmd='/bin/file' 4320145b7b3cSmrg lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )' 4321145b7b3cSmrg ;; 4322145b7b3cSmrg sni) 4323145b7b3cSmrg lt_cv_file_magic_cmd='/bin/file' 4324145b7b3cSmrg lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib" 4325145b7b3cSmrg lt_cv_file_magic_test_file=/lib/libc.so 4326145b7b3cSmrg ;; 4327145b7b3cSmrg siemens) 4328145b7b3cSmrg lt_cv_deplibs_check_method=pass_all 4329145b7b3cSmrg ;; 4330145b7b3cSmrg pc) 4331145b7b3cSmrg lt_cv_deplibs_check_method=pass_all 4332145b7b3cSmrg ;; 4333145b7b3cSmrg esac 4334145b7b3cSmrg ;; 4335145b7b3cSmrg 4336145b7b3cSmrgsysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) 4337145b7b3cSmrg lt_cv_deplibs_check_method=pass_all 4338145b7b3cSmrg ;; 4339145b7b3cSmrgesac 4340145b7b3cSmrg]) 4341145b7b3cSmrgfile_magic_cmd=$lt_cv_file_magic_cmd 4342145b7b3cSmrgdeplibs_check_method=$lt_cv_deplibs_check_method 4343145b7b3cSmrgtest -z "$deplibs_check_method" && deplibs_check_method=unknown 4344145b7b3cSmrg])# AC_DEPLIBS_CHECK_METHOD 4345145b7b3cSmrg 4346145b7b3cSmrg 4347145b7b3cSmrg# AC_PROG_NM 4348145b7b3cSmrg# ---------- 4349145b7b3cSmrg# find the pathname to a BSD-compatible name lister 4350145b7b3cSmrgAC_DEFUN([AC_PROG_NM], 4351145b7b3cSmrg[AC_CACHE_CHECK([for BSD-compatible nm], lt_cv_path_NM, 4352145b7b3cSmrg[if test -n "$NM"; then 4353145b7b3cSmrg # Let the user override the test. 4354145b7b3cSmrg lt_cv_path_NM="$NM" 4355145b7b3cSmrgelse 4356145b7b3cSmrg lt_nm_to_check="${ac_tool_prefix}nm" 4357578741aaSmrg if test -n "$ac_tool_prefix" && test "$build" = "$host"; then 4358145b7b3cSmrg lt_nm_to_check="$lt_nm_to_check nm" 4359145b7b3cSmrg fi 4360145b7b3cSmrg for lt_tmp_nm in $lt_nm_to_check; do 4361145b7b3cSmrg lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR 4362145b7b3cSmrg for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do 4363145b7b3cSmrg IFS="$lt_save_ifs" 4364145b7b3cSmrg test -z "$ac_dir" && ac_dir=. 4365145b7b3cSmrg tmp_nm="$ac_dir/$lt_tmp_nm" 4366145b7b3cSmrg if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then 4367145b7b3cSmrg # Check to see if the nm accepts a BSD-compat flag. 4368145b7b3cSmrg # Adding the `sed 1q' prevents false positives on HP-UX, which says: 4369145b7b3cSmrg # nm: unknown option "B" ignored 4370145b7b3cSmrg # Tru64's nm complains that /dev/null is an invalid object file 4371145b7b3cSmrg case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in 4372145b7b3cSmrg */dev/null* | *'Invalid file or object type'*) 4373145b7b3cSmrg lt_cv_path_NM="$tmp_nm -B" 4374145b7b3cSmrg break 4375145b7b3cSmrg ;; 4376145b7b3cSmrg *) 4377145b7b3cSmrg case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in 4378145b7b3cSmrg */dev/null*) 4379145b7b3cSmrg lt_cv_path_NM="$tmp_nm -p" 4380145b7b3cSmrg break 4381145b7b3cSmrg ;; 4382145b7b3cSmrg *) 4383145b7b3cSmrg lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but 4384145b7b3cSmrg continue # so that we can try to find one that supports BSD flags 4385145b7b3cSmrg ;; 4386145b7b3cSmrg esac 4387145b7b3cSmrg ;; 4388145b7b3cSmrg esac 4389145b7b3cSmrg fi 4390145b7b3cSmrg done 4391145b7b3cSmrg IFS="$lt_save_ifs" 4392145b7b3cSmrg done 4393145b7b3cSmrg test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm 4394145b7b3cSmrgfi]) 4395145b7b3cSmrgNM="$lt_cv_path_NM" 4396145b7b3cSmrg])# AC_PROG_NM 4397145b7b3cSmrg 4398145b7b3cSmrg 4399145b7b3cSmrg# AC_CHECK_LIBM 4400145b7b3cSmrg# ------------- 4401145b7b3cSmrg# check for math library 4402145b7b3cSmrgAC_DEFUN([AC_CHECK_LIBM], 4403145b7b3cSmrg[AC_REQUIRE([AC_CANONICAL_HOST])dnl 4404145b7b3cSmrgLIBM= 4405145b7b3cSmrgcase $host in 4406145b7b3cSmrg*-*-beos* | *-*-cygwin* | *-*-pw32* | *-*-darwin*) 4407145b7b3cSmrg # These system don't have libm, or don't need it 4408145b7b3cSmrg ;; 4409145b7b3cSmrg*-ncr-sysv4.3*) 4410145b7b3cSmrg AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw") 4411145b7b3cSmrg AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm") 4412145b7b3cSmrg ;; 4413145b7b3cSmrg*) 4414145b7b3cSmrg AC_CHECK_LIB(m, cos, LIBM="-lm") 4415145b7b3cSmrg ;; 4416145b7b3cSmrgesac 4417145b7b3cSmrg])# AC_CHECK_LIBM 4418145b7b3cSmrg 4419145b7b3cSmrg 4420145b7b3cSmrg# AC_LIBLTDL_CONVENIENCE([DIRECTORY]) 4421145b7b3cSmrg# ----------------------------------- 4422145b7b3cSmrg# sets LIBLTDL to the link flags for the libltdl convenience library and 4423145b7b3cSmrg# LTDLINCL to the include flags for the libltdl header and adds 4424145b7b3cSmrg# --enable-ltdl-convenience to the configure arguments. Note that 4425145b7b3cSmrg# AC_CONFIG_SUBDIRS is not called here. If DIRECTORY is not provided, 4426145b7b3cSmrg# it is assumed to be `libltdl'. LIBLTDL will be prefixed with 4427145b7b3cSmrg# '${top_builddir}/' and LTDLINCL will be prefixed with '${top_srcdir}/' 4428145b7b3cSmrg# (note the single quotes!). If your package is not flat and you're not 4429145b7b3cSmrg# using automake, define top_builddir and top_srcdir appropriately in 4430145b7b3cSmrg# the Makefiles. 4431145b7b3cSmrgAC_DEFUN([AC_LIBLTDL_CONVENIENCE], 4432145b7b3cSmrg[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl 4433145b7b3cSmrg case $enable_ltdl_convenience in 4434145b7b3cSmrg no) AC_MSG_ERROR([this package needs a convenience libltdl]) ;; 4435145b7b3cSmrg "") enable_ltdl_convenience=yes 4436145b7b3cSmrg ac_configure_args="$ac_configure_args --enable-ltdl-convenience" ;; 4437145b7b3cSmrg esac 4438145b7b3cSmrg LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdlc.la 4439145b7b3cSmrg LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl']) 4440145b7b3cSmrg # For backwards non-gettext consistent compatibility... 4441145b7b3cSmrg INCLTDL="$LTDLINCL" 4442145b7b3cSmrg])# AC_LIBLTDL_CONVENIENCE 4443145b7b3cSmrg 4444145b7b3cSmrg 4445145b7b3cSmrg# AC_LIBLTDL_INSTALLABLE([DIRECTORY]) 4446145b7b3cSmrg# ----------------------------------- 4447145b7b3cSmrg# sets LIBLTDL to the link flags for the libltdl installable library and 4448145b7b3cSmrg# LTDLINCL to the include flags for the libltdl header and adds 4449145b7b3cSmrg# --enable-ltdl-install to the configure arguments. Note that 4450145b7b3cSmrg# AC_CONFIG_SUBDIRS is not called here. If DIRECTORY is not provided, 4451145b7b3cSmrg# and an installed libltdl is not found, it is assumed to be `libltdl'. 4452145b7b3cSmrg# LIBLTDL will be prefixed with '${top_builddir}/'# and LTDLINCL with 4453145b7b3cSmrg# '${top_srcdir}/' (note the single quotes!). If your package is not 4454145b7b3cSmrg# flat and you're not using automake, define top_builddir and top_srcdir 4455145b7b3cSmrg# appropriately in the Makefiles. 4456145b7b3cSmrg# In the future, this macro may have to be called after AC_PROG_LIBTOOL. 4457145b7b3cSmrgAC_DEFUN([AC_LIBLTDL_INSTALLABLE], 4458145b7b3cSmrg[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl 4459145b7b3cSmrg AC_CHECK_LIB(ltdl, lt_dlinit, 4460145b7b3cSmrg [test x"$enable_ltdl_install" != xyes && enable_ltdl_install=no], 4461145b7b3cSmrg [if test x"$enable_ltdl_install" = xno; then 4462145b7b3cSmrg AC_MSG_WARN([libltdl not installed, but installation disabled]) 4463145b7b3cSmrg else 4464145b7b3cSmrg enable_ltdl_install=yes 4465145b7b3cSmrg fi 4466145b7b3cSmrg ]) 4467145b7b3cSmrg if test x"$enable_ltdl_install" = x"yes"; then 4468145b7b3cSmrg ac_configure_args="$ac_configure_args --enable-ltdl-install" 4469145b7b3cSmrg LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdl.la 4470145b7b3cSmrg LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl']) 4471145b7b3cSmrg else 4472145b7b3cSmrg ac_configure_args="$ac_configure_args --enable-ltdl-install=no" 4473145b7b3cSmrg LIBLTDL="-lltdl" 4474145b7b3cSmrg LTDLINCL= 4475145b7b3cSmrg fi 4476145b7b3cSmrg # For backwards non-gettext consistent compatibility... 4477145b7b3cSmrg INCLTDL="$LTDLINCL" 4478145b7b3cSmrg])# AC_LIBLTDL_INSTALLABLE 4479145b7b3cSmrg 4480145b7b3cSmrg 4481145b7b3cSmrg# AC_LIBTOOL_CXX 4482145b7b3cSmrg# -------------- 4483145b7b3cSmrg# enable support for C++ libraries 4484145b7b3cSmrgAC_DEFUN([AC_LIBTOOL_CXX], 4485145b7b3cSmrg[AC_REQUIRE([_LT_AC_LANG_CXX]) 4486145b7b3cSmrg])# AC_LIBTOOL_CXX 4487145b7b3cSmrg 4488145b7b3cSmrg 4489145b7b3cSmrg# _LT_AC_LANG_CXX 4490145b7b3cSmrg# --------------- 4491145b7b3cSmrgAC_DEFUN([_LT_AC_LANG_CXX], 4492145b7b3cSmrg[AC_REQUIRE([AC_PROG_CXX]) 4493145b7b3cSmrgAC_REQUIRE([_LT_AC_PROG_CXXCPP]) 4494145b7b3cSmrg_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}CXX]) 4495145b7b3cSmrg])# _LT_AC_LANG_CXX 4496145b7b3cSmrg 4497145b7b3cSmrg# _LT_AC_PROG_CXXCPP 4498145b7b3cSmrg# ------------------ 4499145b7b3cSmrgAC_DEFUN([_LT_AC_PROG_CXXCPP], 4500145b7b3cSmrg[ 4501145b7b3cSmrgAC_REQUIRE([AC_PROG_CXX]) 4502145b7b3cSmrgif test -n "$CXX" && ( test "X$CXX" != "Xno" && 4503145b7b3cSmrg ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || 4504145b7b3cSmrg (test "X$CXX" != "Xg++"))) ; then 4505145b7b3cSmrg AC_PROG_CXXCPP 4506145b7b3cSmrgfi 4507145b7b3cSmrg])# _LT_AC_PROG_CXXCPP 4508145b7b3cSmrg 4509145b7b3cSmrg# AC_LIBTOOL_F77 4510145b7b3cSmrg# -------------- 4511145b7b3cSmrg# enable support for Fortran 77 libraries 4512145b7b3cSmrgAC_DEFUN([AC_LIBTOOL_F77], 4513145b7b3cSmrg[AC_REQUIRE([_LT_AC_LANG_F77]) 4514145b7b3cSmrg])# AC_LIBTOOL_F77 4515145b7b3cSmrg 4516145b7b3cSmrg 4517145b7b3cSmrg# _LT_AC_LANG_F77 4518145b7b3cSmrg# --------------- 4519145b7b3cSmrgAC_DEFUN([_LT_AC_LANG_F77], 4520145b7b3cSmrg[AC_REQUIRE([AC_PROG_F77]) 4521145b7b3cSmrg_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}F77]) 4522145b7b3cSmrg])# _LT_AC_LANG_F77 4523145b7b3cSmrg 4524145b7b3cSmrg 4525145b7b3cSmrg# AC_LIBTOOL_GCJ 4526145b7b3cSmrg# -------------- 4527145b7b3cSmrg# enable support for GCJ libraries 4528145b7b3cSmrgAC_DEFUN([AC_LIBTOOL_GCJ], 4529145b7b3cSmrg[AC_REQUIRE([_LT_AC_LANG_GCJ]) 4530145b7b3cSmrg])# AC_LIBTOOL_GCJ 4531145b7b3cSmrg 4532145b7b3cSmrg 4533145b7b3cSmrg# _LT_AC_LANG_GCJ 4534145b7b3cSmrg# --------------- 4535145b7b3cSmrgAC_DEFUN([_LT_AC_LANG_GCJ], 4536145b7b3cSmrg[AC_PROVIDE_IFELSE([AC_PROG_GCJ],[], 4537145b7b3cSmrg [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],[], 4538145b7b3cSmrg [AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ],[], 4539145b7b3cSmrg [ifdef([AC_PROG_GCJ],[AC_REQUIRE([AC_PROG_GCJ])], 4540145b7b3cSmrg [ifdef([A][M_PROG_GCJ],[AC_REQUIRE([A][M_PROG_GCJ])], 4541145b7b3cSmrg [AC_REQUIRE([A][C_PROG_GCJ_OR_A][M_PROG_GCJ])])])])])]) 4542145b7b3cSmrg_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}GCJ]) 4543145b7b3cSmrg])# _LT_AC_LANG_GCJ 4544145b7b3cSmrg 4545145b7b3cSmrg 4546145b7b3cSmrg# AC_LIBTOOL_RC 4547145b7b3cSmrg# ------------- 4548145b7b3cSmrg# enable support for Windows resource files 4549145b7b3cSmrgAC_DEFUN([AC_LIBTOOL_RC], 4550145b7b3cSmrg[AC_REQUIRE([LT_AC_PROG_RC]) 4551145b7b3cSmrg_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}RC]) 4552145b7b3cSmrg])# AC_LIBTOOL_RC 4553145b7b3cSmrg 4554145b7b3cSmrg 4555145b7b3cSmrg# AC_LIBTOOL_LANG_C_CONFIG 4556145b7b3cSmrg# ------------------------ 4557145b7b3cSmrg# Ensure that the configuration vars for the C compiler are 4558145b7b3cSmrg# suitably defined. Those variables are subsequently used by 4559145b7b3cSmrg# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'. 4560145b7b3cSmrgAC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG], [_LT_AC_LANG_C_CONFIG]) 4561145b7b3cSmrgAC_DEFUN([_LT_AC_LANG_C_CONFIG], 4562145b7b3cSmrg[lt_save_CC="$CC" 4563145b7b3cSmrgAC_LANG_PUSH(C) 4564145b7b3cSmrg 4565145b7b3cSmrg# Source file extension for C test sources. 4566145b7b3cSmrgac_ext=c 4567145b7b3cSmrg 4568145b7b3cSmrg# Object file extension for compiled C test sources. 4569145b7b3cSmrgobjext=o 4570145b7b3cSmrg_LT_AC_TAGVAR(objext, $1)=$objext 4571145b7b3cSmrg 4572145b7b3cSmrg# Code to be used in simple compile tests 4573578741aaSmrglt_simple_compile_test_code="int some_variable = 0;" 4574145b7b3cSmrg 4575145b7b3cSmrg# Code to be used in simple link tests 4576578741aaSmrglt_simple_link_test_code='int main(){return(0);}' 4577145b7b3cSmrg 4578145b7b3cSmrg_LT_AC_SYS_COMPILER 4579145b7b3cSmrg 4580145b7b3cSmrg# save warnings/boilerplate of simple test code 4581145b7b3cSmrg_LT_COMPILER_BOILERPLATE 4582145b7b3cSmrg_LT_LINKER_BOILERPLATE 4583145b7b3cSmrg 4584145b7b3cSmrgAC_LIBTOOL_PROG_COMPILER_NO_RTTI($1) 4585145b7b3cSmrgAC_LIBTOOL_PROG_COMPILER_PIC($1) 4586145b7b3cSmrgAC_LIBTOOL_PROG_CC_C_O($1) 4587145b7b3cSmrgAC_LIBTOOL_SYS_HARD_LINK_LOCKS($1) 4588145b7b3cSmrgAC_LIBTOOL_PROG_LD_SHLIBS($1) 4589145b7b3cSmrgAC_LIBTOOL_SYS_DYNAMIC_LINKER($1) 4590145b7b3cSmrgAC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1) 4591145b7b3cSmrgAC_LIBTOOL_SYS_LIB_STRIP 4592145b7b3cSmrgAC_LIBTOOL_DLOPEN_SELF 4593145b7b3cSmrg 4594145b7b3cSmrg# Report which library types will actually be built 4595145b7b3cSmrgAC_MSG_CHECKING([if libtool supports shared libraries]) 4596145b7b3cSmrgAC_MSG_RESULT([$can_build_shared]) 4597145b7b3cSmrg 4598145b7b3cSmrgAC_MSG_CHECKING([whether to build shared libraries]) 4599145b7b3cSmrgtest "$can_build_shared" = "no" && enable_shared=no 4600145b7b3cSmrg 4601145b7b3cSmrg# On AIX, shared libraries and static libraries use the same namespace, and 4602145b7b3cSmrg# are all built from PIC. 4603145b7b3cSmrgcase $host_os in 4604145b7b3cSmrgaix3*) 4605145b7b3cSmrg test "$enable_shared" = yes && enable_static=no 4606145b7b3cSmrg if test -n "$RANLIB"; then 4607145b7b3cSmrg archive_cmds="$archive_cmds~\$RANLIB \$lib" 4608145b7b3cSmrg postinstall_cmds='$RANLIB $lib' 4609145b7b3cSmrg fi 4610145b7b3cSmrg ;; 4611145b7b3cSmrg 4612578741aaSmrgaix[[4-9]]*) 4613145b7b3cSmrg if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then 4614145b7b3cSmrg test "$enable_shared" = yes && enable_static=no 4615145b7b3cSmrg fi 4616145b7b3cSmrg ;; 4617145b7b3cSmrgesac 4618145b7b3cSmrgAC_MSG_RESULT([$enable_shared]) 4619145b7b3cSmrg 4620145b7b3cSmrgAC_MSG_CHECKING([whether to build static libraries]) 4621145b7b3cSmrg# Make sure either enable_shared or enable_static is yes. 4622145b7b3cSmrgtest "$enable_shared" = yes || enable_static=yes 4623145b7b3cSmrgAC_MSG_RESULT([$enable_static]) 4624145b7b3cSmrg 4625145b7b3cSmrgAC_LIBTOOL_CONFIG($1) 4626145b7b3cSmrg 4627145b7b3cSmrgAC_LANG_POP 4628145b7b3cSmrgCC="$lt_save_CC" 4629145b7b3cSmrg])# AC_LIBTOOL_LANG_C_CONFIG 4630145b7b3cSmrg 4631145b7b3cSmrg 4632145b7b3cSmrg# AC_LIBTOOL_LANG_CXX_CONFIG 4633145b7b3cSmrg# -------------------------- 4634145b7b3cSmrg# Ensure that the configuration vars for the C compiler are 4635145b7b3cSmrg# suitably defined. Those variables are subsequently used by 4636145b7b3cSmrg# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'. 4637145b7b3cSmrgAC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG], [_LT_AC_LANG_CXX_CONFIG(CXX)]) 4638145b7b3cSmrgAC_DEFUN([_LT_AC_LANG_CXX_CONFIG], 4639145b7b3cSmrg[AC_LANG_PUSH(C++) 4640145b7b3cSmrgAC_REQUIRE([AC_PROG_CXX]) 4641145b7b3cSmrgAC_REQUIRE([_LT_AC_PROG_CXXCPP]) 4642145b7b3cSmrg 4643145b7b3cSmrg_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no 4644145b7b3cSmrg_LT_AC_TAGVAR(allow_undefined_flag, $1)= 4645145b7b3cSmrg_LT_AC_TAGVAR(always_export_symbols, $1)=no 4646145b7b3cSmrg_LT_AC_TAGVAR(archive_expsym_cmds, $1)= 4647145b7b3cSmrg_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)= 4648145b7b3cSmrg_LT_AC_TAGVAR(hardcode_direct, $1)=no 4649145b7b3cSmrg_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)= 4650145b7b3cSmrg_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= 4651145b7b3cSmrg_LT_AC_TAGVAR(hardcode_libdir_separator, $1)= 4652145b7b3cSmrg_LT_AC_TAGVAR(hardcode_minus_L, $1)=no 4653145b7b3cSmrg_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported 4654145b7b3cSmrg_LT_AC_TAGVAR(hardcode_automatic, $1)=no 4655145b7b3cSmrg_LT_AC_TAGVAR(module_cmds, $1)= 4656145b7b3cSmrg_LT_AC_TAGVAR(module_expsym_cmds, $1)= 4657145b7b3cSmrg_LT_AC_TAGVAR(link_all_deplibs, $1)=unknown 4658145b7b3cSmrg_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 4659145b7b3cSmrg_LT_AC_TAGVAR(no_undefined_flag, $1)= 4660145b7b3cSmrg_LT_AC_TAGVAR(whole_archive_flag_spec, $1)= 4661145b7b3cSmrg_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no 4662145b7b3cSmrg 4663145b7b3cSmrg# Dependencies to place before and after the object being linked: 4664145b7b3cSmrg_LT_AC_TAGVAR(predep_objects, $1)= 4665145b7b3cSmrg_LT_AC_TAGVAR(postdep_objects, $1)= 4666145b7b3cSmrg_LT_AC_TAGVAR(predeps, $1)= 4667145b7b3cSmrg_LT_AC_TAGVAR(postdeps, $1)= 4668145b7b3cSmrg_LT_AC_TAGVAR(compiler_lib_search_path, $1)= 4669578741aaSmrg_LT_AC_TAGVAR(compiler_lib_search_dirs, $1)= 4670145b7b3cSmrg 4671145b7b3cSmrg# Source file extension for C++ test sources. 4672145b7b3cSmrgac_ext=cpp 4673145b7b3cSmrg 4674145b7b3cSmrg# Object file extension for compiled C++ test sources. 4675145b7b3cSmrgobjext=o 4676145b7b3cSmrg_LT_AC_TAGVAR(objext, $1)=$objext 4677145b7b3cSmrg 4678145b7b3cSmrg# Code to be used in simple compile tests 4679578741aaSmrglt_simple_compile_test_code="int some_variable = 0;" 4680145b7b3cSmrg 4681145b7b3cSmrg# Code to be used in simple link tests 4682578741aaSmrglt_simple_link_test_code='int main(int, char *[[]]) { return(0); }' 4683145b7b3cSmrg 4684145b7b3cSmrg# ltmain only uses $CC for tagged configurations so make sure $CC is set. 4685145b7b3cSmrg_LT_AC_SYS_COMPILER 4686145b7b3cSmrg 4687145b7b3cSmrg# save warnings/boilerplate of simple test code 4688145b7b3cSmrg_LT_COMPILER_BOILERPLATE 4689145b7b3cSmrg_LT_LINKER_BOILERPLATE 4690145b7b3cSmrg 4691145b7b3cSmrg# Allow CC to be a program name with arguments. 4692145b7b3cSmrglt_save_CC=$CC 4693145b7b3cSmrglt_save_LD=$LD 4694145b7b3cSmrglt_save_GCC=$GCC 4695145b7b3cSmrgGCC=$GXX 4696145b7b3cSmrglt_save_with_gnu_ld=$with_gnu_ld 4697145b7b3cSmrglt_save_path_LD=$lt_cv_path_LD 4698145b7b3cSmrgif test -n "${lt_cv_prog_gnu_ldcxx+set}"; then 4699145b7b3cSmrg lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx 4700145b7b3cSmrgelse 4701145b7b3cSmrg $as_unset lt_cv_prog_gnu_ld 4702145b7b3cSmrgfi 4703145b7b3cSmrgif test -n "${lt_cv_path_LDCXX+set}"; then 4704145b7b3cSmrg lt_cv_path_LD=$lt_cv_path_LDCXX 4705145b7b3cSmrgelse 4706145b7b3cSmrg $as_unset lt_cv_path_LD 4707145b7b3cSmrgfi 4708145b7b3cSmrgtest -z "${LDCXX+set}" || LD=$LDCXX 4709145b7b3cSmrgCC=${CXX-"c++"} 4710145b7b3cSmrgcompiler=$CC 4711145b7b3cSmrg_LT_AC_TAGVAR(compiler, $1)=$CC 4712145b7b3cSmrg_LT_CC_BASENAME([$compiler]) 4713145b7b3cSmrg 4714145b7b3cSmrg# We don't want -fno-exception wen compiling C++ code, so set the 4715145b7b3cSmrg# no_builtin_flag separately 4716145b7b3cSmrgif test "$GXX" = yes; then 4717145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' 4718145b7b3cSmrgelse 4719145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= 4720145b7b3cSmrgfi 4721145b7b3cSmrg 4722145b7b3cSmrgif test "$GXX" = yes; then 4723145b7b3cSmrg # Set up default GNU C++ configuration 4724145b7b3cSmrg 4725145b7b3cSmrg AC_PROG_LD 4726145b7b3cSmrg 4727145b7b3cSmrg # Check if GNU C++ uses GNU ld as the underlying linker, since the 4728145b7b3cSmrg # archiving commands below assume that GNU ld is being used. 4729145b7b3cSmrg if test "$with_gnu_ld" = yes; then 4730145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' 4731145b7b3cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' 4732145b7b3cSmrg 4733145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir' 4734145b7b3cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 4735145b7b3cSmrg 4736145b7b3cSmrg # If archive_cmds runs LD, not CC, wlarc should be empty 4737145b7b3cSmrg # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to 4738145b7b3cSmrg # investigate it a little bit more. (MM) 4739145b7b3cSmrg wlarc='${wl}' 4740145b7b3cSmrg 4741145b7b3cSmrg # ancient GNU ld didn't support --whole-archive et. al. 4742145b7b3cSmrg if eval "`$CC -print-prog-name=ld` --help 2>&1" | \ 4743145b7b3cSmrg grep 'no-whole-archive' > /dev/null; then 4744145b7b3cSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' 4745145b7b3cSmrg else 4746145b7b3cSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)= 4747145b7b3cSmrg fi 4748145b7b3cSmrg else 4749145b7b3cSmrg with_gnu_ld=no 4750145b7b3cSmrg wlarc= 4751145b7b3cSmrg 4752145b7b3cSmrg # A generic and very simple default shared library creation 4753145b7b3cSmrg # command for GNU C++ for the case where it uses the native 4754145b7b3cSmrg # linker, instead of GNU ld. If possible, this setting should 4755145b7b3cSmrg # overridden to take advantage of the native linker features on 4756145b7b3cSmrg # the platform it is being used on. 4757145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' 4758145b7b3cSmrg fi 4759145b7b3cSmrg 4760145b7b3cSmrg # Commands to make compiler produce verbose output that lists 4761145b7b3cSmrg # what "hidden" libraries, object files and flags are used when 4762145b7b3cSmrg # linking a shared library. 4763145b7b3cSmrg output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"' 4764145b7b3cSmrg 4765145b7b3cSmrgelse 4766145b7b3cSmrg GXX=no 4767145b7b3cSmrg with_gnu_ld=no 4768145b7b3cSmrg wlarc= 4769145b7b3cSmrgfi 4770145b7b3cSmrg 4771145b7b3cSmrg# PORTME: fill in a description of your system's C++ link characteristics 4772145b7b3cSmrgAC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) 4773145b7b3cSmrg_LT_AC_TAGVAR(ld_shlibs, $1)=yes 4774145b7b3cSmrgcase $host_os in 4775145b7b3cSmrg aix3*) 4776145b7b3cSmrg # FIXME: insert proper C++ library support 4777145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 4778145b7b3cSmrg ;; 4779578741aaSmrg aix[[4-9]]*) 4780145b7b3cSmrg if test "$host_cpu" = ia64; then 4781145b7b3cSmrg # On IA64, the linker does run time linking by default, so we don't 4782145b7b3cSmrg # have to do anything special. 4783145b7b3cSmrg aix_use_runtimelinking=no 4784145b7b3cSmrg exp_sym_flag='-Bexport' 4785145b7b3cSmrg no_entry_flag="" 4786145b7b3cSmrg else 4787145b7b3cSmrg aix_use_runtimelinking=no 4788145b7b3cSmrg 4789145b7b3cSmrg # Test if we are trying to use run time linking or normal 4790145b7b3cSmrg # AIX style linking. If -brtl is somewhere in LDFLAGS, we 4791145b7b3cSmrg # need to do runtime linking. 4792578741aaSmrg case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) 4793145b7b3cSmrg for ld_flag in $LDFLAGS; do 4794145b7b3cSmrg case $ld_flag in 4795145b7b3cSmrg *-brtl*) 4796145b7b3cSmrg aix_use_runtimelinking=yes 4797145b7b3cSmrg break 4798145b7b3cSmrg ;; 4799145b7b3cSmrg esac 4800145b7b3cSmrg done 4801145b7b3cSmrg ;; 4802145b7b3cSmrg esac 4803145b7b3cSmrg 4804145b7b3cSmrg exp_sym_flag='-bexport' 4805145b7b3cSmrg no_entry_flag='-bnoentry' 4806145b7b3cSmrg fi 4807145b7b3cSmrg 4808145b7b3cSmrg # When large executables or shared objects are built, AIX ld can 4809145b7b3cSmrg # have problems creating the table of contents. If linking a library 4810145b7b3cSmrg # or program results in "error TOC overflow" add -mminimal-toc to 4811145b7b3cSmrg # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not 4812145b7b3cSmrg # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. 4813145b7b3cSmrg 4814145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='' 4815145b7b3cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=yes 4816145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':' 4817145b7b3cSmrg _LT_AC_TAGVAR(link_all_deplibs, $1)=yes 4818145b7b3cSmrg 4819145b7b3cSmrg if test "$GXX" = yes; then 4820145b7b3cSmrg case $host_os in aix4.[[012]]|aix4.[[012]].*) 4821145b7b3cSmrg # We only want to do this on AIX 4.2 and lower, the check 4822145b7b3cSmrg # below for broken collect2 doesn't work under 4.3+ 4823145b7b3cSmrg collect2name=`${CC} -print-prog-name=collect2` 4824145b7b3cSmrg if test -f "$collect2name" && \ 4825145b7b3cSmrg strings "$collect2name" | grep resolve_lib_name >/dev/null 4826145b7b3cSmrg then 4827145b7b3cSmrg # We have reworked collect2 4828578741aaSmrg : 4829145b7b3cSmrg else 4830145b7b3cSmrg # We have old collect2 4831145b7b3cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported 4832145b7b3cSmrg # It fails to find uninstalled libraries when the uninstalled 4833145b7b3cSmrg # path is not listed in the libpath. Setting hardcode_minus_L 4834145b7b3cSmrg # to unsupported forces relinking 4835145b7b3cSmrg _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes 4836145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 4837145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)= 4838145b7b3cSmrg fi 4839145b7b3cSmrg ;; 4840145b7b3cSmrg esac 4841145b7b3cSmrg shared_flag='-shared' 4842145b7b3cSmrg if test "$aix_use_runtimelinking" = yes; then 4843145b7b3cSmrg shared_flag="$shared_flag "'${wl}-G' 4844145b7b3cSmrg fi 4845145b7b3cSmrg else 4846145b7b3cSmrg # not using gcc 4847145b7b3cSmrg if test "$host_cpu" = ia64; then 4848145b7b3cSmrg # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release 4849145b7b3cSmrg # chokes on -Wl,-G. The following line is correct: 4850145b7b3cSmrg shared_flag='-G' 4851145b7b3cSmrg else 4852145b7b3cSmrg if test "$aix_use_runtimelinking" = yes; then 4853145b7b3cSmrg shared_flag='${wl}-G' 4854145b7b3cSmrg else 4855145b7b3cSmrg shared_flag='${wl}-bM:SRE' 4856145b7b3cSmrg fi 4857145b7b3cSmrg fi 4858145b7b3cSmrg fi 4859145b7b3cSmrg 4860145b7b3cSmrg # It seems that -bexpall does not export symbols beginning with 4861145b7b3cSmrg # underscore (_), so it is better to generate a list of symbols to export. 4862145b7b3cSmrg _LT_AC_TAGVAR(always_export_symbols, $1)=yes 4863145b7b3cSmrg if test "$aix_use_runtimelinking" = yes; then 4864145b7b3cSmrg # Warning - without using the other runtime loading flags (-brtl), 4865145b7b3cSmrg # -berok will link without error, but may produce a broken library. 4866145b7b3cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok' 4867145b7b3cSmrg # Determine the default libpath from the value encoded in an empty executable. 4868145b7b3cSmrg _LT_AC_SYS_LIBPATH_AIX 4869145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" 4870145b7b3cSmrg 4871145b7b3cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" 4872145b7b3cSmrg else 4873145b7b3cSmrg if test "$host_cpu" = ia64; then 4874145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' 4875145b7b3cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs" 4876145b7b3cSmrg _LT_AC_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" 4877145b7b3cSmrg else 4878145b7b3cSmrg # Determine the default libpath from the value encoded in an empty executable. 4879145b7b3cSmrg _LT_AC_SYS_LIBPATH_AIX 4880145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" 4881145b7b3cSmrg # Warning - without using the other run time loading flags, 4882145b7b3cSmrg # -berok will link without error, but may produce a broken library. 4883145b7b3cSmrg _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' 4884145b7b3cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' 4885145b7b3cSmrg # Exported symbols can be pulled into shared objects from archives 4886145b7b3cSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='$convenience' 4887145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes 4888145b7b3cSmrg # This is similar to how AIX traditionally builds its shared libraries. 4889145b7b3cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' 4890145b7b3cSmrg fi 4891145b7b3cSmrg fi 4892145b7b3cSmrg ;; 4893145b7b3cSmrg 4894145b7b3cSmrg beos*) 4895145b7b3cSmrg if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then 4896145b7b3cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported 4897145b7b3cSmrg # Joseph Beckenbach <jrb3@best.com> says some releases of gcc 4898145b7b3cSmrg # support --undefined. This deserves some investigation. FIXME 4899145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 4900145b7b3cSmrg else 4901145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 4902145b7b3cSmrg fi 4903145b7b3cSmrg ;; 4904145b7b3cSmrg 4905145b7b3cSmrg chorus*) 4906145b7b3cSmrg case $cc_basename in 4907145b7b3cSmrg *) 4908145b7b3cSmrg # FIXME: insert proper C++ library support 4909145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 4910145b7b3cSmrg ;; 4911145b7b3cSmrg esac 4912145b7b3cSmrg ;; 4913145b7b3cSmrg 4914145b7b3cSmrg cygwin* | mingw* | pw32*) 4915145b7b3cSmrg # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, 4916145b7b3cSmrg # as there is no search path for DLLs. 4917145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 4918145b7b3cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported 4919145b7b3cSmrg _LT_AC_TAGVAR(always_export_symbols, $1)=no 4920145b7b3cSmrg _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 4921145b7b3cSmrg 4922145b7b3cSmrg if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then 4923145b7b3cSmrg _LT_AC_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' 4924145b7b3cSmrg # If the export-symbols file already is a .def file (1st line 4925145b7b3cSmrg # is EXPORTS), use it as is; otherwise, prepend... 4926145b7b3cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then 4927145b7b3cSmrg cp $export_symbols $output_objdir/$soname.def; 4928145b7b3cSmrg else 4929145b7b3cSmrg echo EXPORTS > $output_objdir/$soname.def; 4930145b7b3cSmrg cat $export_symbols >> $output_objdir/$soname.def; 4931145b7b3cSmrg fi~ 4932145b7b3cSmrg $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' 4933145b7b3cSmrg else 4934145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 4935145b7b3cSmrg fi 4936145b7b3cSmrg ;; 4937145b7b3cSmrg darwin* | rhapsody*) 4938145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no 4939145b7b3cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=no 4940145b7b3cSmrg _LT_AC_TAGVAR(hardcode_automatic, $1)=yes 4941145b7b3cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported 4942145b7b3cSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='' 4943145b7b3cSmrg _LT_AC_TAGVAR(link_all_deplibs, $1)=yes 4944578741aaSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined" 4945578741aaSmrg if test "$GXX" = yes ; then 4946145b7b3cSmrg output_verbose_link_cmd='echo' 4947578741aaSmrg _LT_AC_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}" 4948578741aaSmrg _LT_AC_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" 4949578741aaSmrg _LT_AC_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}" 4950578741aaSmrg _LT_AC_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}" 4951578741aaSmrg if test "$lt_cv_apple_cc_single_mod" != "yes"; then 4952578741aaSmrg _LT_AC_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}" 4953578741aaSmrg _LT_AC_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}" 4954145b7b3cSmrg fi 4955145b7b3cSmrg else 4956145b7b3cSmrg case $cc_basename in 4957145b7b3cSmrg xlc*) 4958145b7b3cSmrg output_verbose_link_cmd='echo' 4959578741aaSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring' 4960145b7b3cSmrg _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' 4961145b7b3cSmrg # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds 4962578741aaSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' 4963145b7b3cSmrg _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' 4964145b7b3cSmrg ;; 4965145b7b3cSmrg *) 4966145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 4967145b7b3cSmrg ;; 4968145b7b3cSmrg esac 4969145b7b3cSmrg fi 4970145b7b3cSmrg ;; 4971145b7b3cSmrg 4972145b7b3cSmrg dgux*) 4973145b7b3cSmrg case $cc_basename in 4974145b7b3cSmrg ec++*) 4975145b7b3cSmrg # FIXME: insert proper C++ library support 4976145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 4977145b7b3cSmrg ;; 4978145b7b3cSmrg ghcx*) 4979145b7b3cSmrg # Green Hills C++ Compiler 4980145b7b3cSmrg # FIXME: insert proper C++ library support 4981145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 4982145b7b3cSmrg ;; 4983145b7b3cSmrg *) 4984145b7b3cSmrg # FIXME: insert proper C++ library support 4985145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 4986145b7b3cSmrg ;; 4987145b7b3cSmrg esac 4988145b7b3cSmrg ;; 4989145b7b3cSmrg freebsd[[12]]*) 4990145b7b3cSmrg # C++ shared libraries reported to be fairly broken before switch to ELF 4991145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 4992145b7b3cSmrg ;; 4993145b7b3cSmrg freebsd-elf*) 4994145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no 4995145b7b3cSmrg ;; 4996578741aaSmrg freebsd* | dragonfly*) 4997145b7b3cSmrg # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF 4998145b7b3cSmrg # conventions 4999145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=yes 5000145b7b3cSmrg ;; 5001145b7b3cSmrg gnu*) 5002145b7b3cSmrg ;; 5003145b7b3cSmrg hpux9*) 5004145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 5005145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 5006145b7b3cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 5007145b7b3cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=yes 5008145b7b3cSmrg _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, 5009145b7b3cSmrg # but as the default 5010145b7b3cSmrg # location of the library. 5011145b7b3cSmrg 5012145b7b3cSmrg case $cc_basename in 5013145b7b3cSmrg CC*) 5014145b7b3cSmrg # FIXME: insert proper C++ library support 5015145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 5016145b7b3cSmrg ;; 5017145b7b3cSmrg aCC*) 5018145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' 5019145b7b3cSmrg # Commands to make compiler produce verbose output that lists 5020145b7b3cSmrg # what "hidden" libraries, object files and flags are used when 5021145b7b3cSmrg # linking a shared library. 5022145b7b3cSmrg # 5023145b7b3cSmrg # There doesn't appear to be a way to prevent this compiler from 5024145b7b3cSmrg # explicitly linking system object files so we need to strip them 5025145b7b3cSmrg # from the output so that they don't get included in the library 5026145b7b3cSmrg # dependencies. 5027145b7b3cSmrg output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | grep "[[-]]L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' 5028145b7b3cSmrg ;; 5029145b7b3cSmrg *) 5030145b7b3cSmrg if test "$GXX" = yes; then 5031145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$CC -shared -nostdlib -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' 5032145b7b3cSmrg else 5033145b7b3cSmrg # FIXME: insert proper C++ library support 5034145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 5035145b7b3cSmrg fi 5036145b7b3cSmrg ;; 5037145b7b3cSmrg esac 5038145b7b3cSmrg ;; 5039145b7b3cSmrg hpux10*|hpux11*) 5040145b7b3cSmrg if test $with_gnu_ld = no; then 5041145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 5042145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 5043145b7b3cSmrg 5044145b7b3cSmrg case $host_cpu in 5045578741aaSmrg hppa*64*|ia64*) ;; 5046145b7b3cSmrg *) 5047145b7b3cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 5048145b7b3cSmrg ;; 5049145b7b3cSmrg esac 5050145b7b3cSmrg fi 5051145b7b3cSmrg case $host_cpu in 5052145b7b3cSmrg hppa*64*|ia64*) 5053145b7b3cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=no 5054145b7b3cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 5055145b7b3cSmrg ;; 5056145b7b3cSmrg *) 5057145b7b3cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=yes 5058145b7b3cSmrg _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, 5059145b7b3cSmrg # but as the default 5060145b7b3cSmrg # location of the library. 5061145b7b3cSmrg ;; 5062145b7b3cSmrg esac 5063145b7b3cSmrg 5064145b7b3cSmrg case $cc_basename in 5065145b7b3cSmrg CC*) 5066145b7b3cSmrg # FIXME: insert proper C++ library support 5067145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 5068145b7b3cSmrg ;; 5069145b7b3cSmrg aCC*) 5070145b7b3cSmrg case $host_cpu in 5071145b7b3cSmrg hppa*64*) 5072145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 5073145b7b3cSmrg ;; 5074145b7b3cSmrg ia64*) 5075145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 5076145b7b3cSmrg ;; 5077145b7b3cSmrg *) 5078145b7b3cSmrg _LT_AC_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' 5079145b7b3cSmrg ;; 5080145b7b3cSmrg esac 5081145b7b3cSmrg # Commands to make compiler produce verbose output that lists 5082145b7b3cSmrg # what "hidden" libraries, object files and flags are used when 5083145b7b3cSmrg # linking a shared library. 5084145b7b3cSmrg # 5085145b7b3cSmrg # There doesn't appear to be a way to prevent this compiler from 5086145b7b3cSmrg # explicitly linking system object files so we need to strip them 5087145b7b3cSmrg # from the output so that they don't get included in the library 5088145b7b3cSmrg # dependencies. 5089145b7b3cSmrg output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | grep "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' 5090145b7b3cSmrg ;; 5091145b7b3cSmrg *) 5092145b7b3cSmrg if test "$GXX" = yes; then 5093145b7b3cSmrg if test $with_gnu_ld = no; then 5094145b7b3cSmrg case $host_cpu in 5095145b7b3cSmrg hppa*64*) 5096145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 5097145b7b3cSmrg ;; 5098145b7b3cSmrg ia64*) 5099145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 5100145b7b3cSmrg ;; 5101145b7b3cSmrg *) 5102145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 5103145b7b3cSmrg ;; 5104145b7b3cSmrg esac 5105145b7b3cSmrg fi 5106145b7b3cSmrg else 5107145b7b3cSmrg # FIXME: insert proper C++ library support 5108145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 5109145b7b3cSmrg fi 5110145b7b3cSmrg ;; 5111145b7b3cSmrg esac 5112145b7b3cSmrg ;; 5113578741aaSmrg interix[[3-9]]*) 5114145b7b3cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=no 5115145b7b3cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 5116145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 5117145b7b3cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 5118145b7b3cSmrg # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. 5119145b7b3cSmrg # Instead, shared libraries are loaded at an image base (0x10000000 by 5120145b7b3cSmrg # default) and relocated if they conflict, which is a slow very memory 5121145b7b3cSmrg # consuming and fragmenting process. To avoid this, we pick a random, 5122145b7b3cSmrg # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link 5123145b7b3cSmrg # time. Moving up from 0x10000000 also allows more sbrk(2) space. 5124145b7b3cSmrg _LT_AC_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' 5125145b7b3cSmrg _LT_AC_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' 5126145b7b3cSmrg ;; 5127145b7b3cSmrg irix5* | irix6*) 5128145b7b3cSmrg case $cc_basename in 5129145b7b3cSmrg CC*) 5130145b7b3cSmrg # SGI C++ 5131145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' 5132145b7b3cSmrg 5133145b7b3cSmrg # Archives containing C++ object files must be created using 5134145b7b3cSmrg # "CC -ar", where "CC" is the IRIX C++ compiler. This is 5135145b7b3cSmrg # necessary to make sure instantiated templates are included 5136145b7b3cSmrg # in the archive. 5137145b7b3cSmrg _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs' 5138145b7b3cSmrg ;; 5139145b7b3cSmrg *) 5140145b7b3cSmrg if test "$GXX" = yes; then 5141145b7b3cSmrg if test "$with_gnu_ld" = no; then 5142145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' 5143145b7b3cSmrg else 5144145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` -o $lib' 5145145b7b3cSmrg fi 5146145b7b3cSmrg fi 5147145b7b3cSmrg _LT_AC_TAGVAR(link_all_deplibs, $1)=yes 5148145b7b3cSmrg ;; 5149145b7b3cSmrg esac 5150145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 5151145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 5152145b7b3cSmrg ;; 5153578741aaSmrg linux* | k*bsd*-gnu) 5154145b7b3cSmrg case $cc_basename in 5155145b7b3cSmrg KCC*) 5156145b7b3cSmrg # Kuck and Associates, Inc. (KAI) C++ Compiler 5157145b7b3cSmrg 5158145b7b3cSmrg # KCC will only create a shared library if the output file 5159145b7b3cSmrg # ends with ".so" (or ".sl" for HP-UX), so rename the library 5160145b7b3cSmrg # to its proper name (with version) after linking. 5161145b7b3cSmrg _LT_AC_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' 5162145b7b3cSmrg _LT_AC_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' 5163145b7b3cSmrg # Commands to make compiler produce verbose output that lists 5164145b7b3cSmrg # what "hidden" libraries, object files and flags are used when 5165145b7b3cSmrg # linking a shared library. 5166145b7b3cSmrg # 5167145b7b3cSmrg # There doesn't appear to be a way to prevent this compiler from 5168145b7b3cSmrg # explicitly linking system object files so we need to strip them 5169145b7b3cSmrg # from the output so that they don't get included in the library 5170145b7b3cSmrg # dependencies. 5171145b7b3cSmrg output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | grep "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' 5172145b7b3cSmrg 5173145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath,$libdir' 5174145b7b3cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 5175145b7b3cSmrg 5176145b7b3cSmrg # Archives containing C++ object files must be created using 5177145b7b3cSmrg # "CC -Bstatic", where "CC" is the KAI C++ compiler. 5178145b7b3cSmrg _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' 5179145b7b3cSmrg ;; 5180145b7b3cSmrg icpc*) 5181145b7b3cSmrg # Intel C++ 5182145b7b3cSmrg with_gnu_ld=yes 5183145b7b3cSmrg # version 8.0 and above of icpc choke on multiply defined symbols 5184145b7b3cSmrg # if we add $predep_objects and $postdep_objects, however 7.1 and 5185145b7b3cSmrg # earlier do not add the objects themselves. 5186145b7b3cSmrg case `$CC -V 2>&1` in 5187145b7b3cSmrg *"Version 7."*) 5188145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' 5189145b7b3cSmrg _LT_AC_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' 5190145b7b3cSmrg ;; 5191145b7b3cSmrg *) # Version 8.0 or newer 5192145b7b3cSmrg tmp_idyn= 5193145b7b3cSmrg case $host_cpu in 5194145b7b3cSmrg ia64*) tmp_idyn=' -i_dynamic';; 5195145b7b3cSmrg esac 5196145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 5197145b7b3cSmrg _LT_AC_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' 5198145b7b3cSmrg ;; 5199145b7b3cSmrg esac 5200145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no 5201145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 5202145b7b3cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 5203145b7b3cSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' 5204145b7b3cSmrg ;; 5205578741aaSmrg pgCC* | pgcpp*) 5206145b7b3cSmrg # Portland Group C++ compiler 5207145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' 5208145b7b3cSmrg _LT_AC_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' 5209145b7b3cSmrg 5210145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir' 5211145b7b3cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 5212145b7b3cSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' 5213145b7b3cSmrg ;; 5214145b7b3cSmrg cxx*) 5215145b7b3cSmrg # Compaq C++ 5216145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' 5217145b7b3cSmrg _LT_AC_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' 5218145b7b3cSmrg 5219145b7b3cSmrg runpath_var=LD_RUN_PATH 5220145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' 5221145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 5222145b7b3cSmrg 5223145b7b3cSmrg # Commands to make compiler produce verbose output that lists 5224145b7b3cSmrg # what "hidden" libraries, object files and flags are used when 5225145b7b3cSmrg # linking a shared library. 5226145b7b3cSmrg # 5227145b7b3cSmrg # There doesn't appear to be a way to prevent this compiler from 5228145b7b3cSmrg # explicitly linking system object files so we need to strip them 5229145b7b3cSmrg # from the output so that they don't get included in the library 5230145b7b3cSmrg # dependencies. 5231145b7b3cSmrg output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld"`; templist=`echo $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; echo $list' 5232145b7b3cSmrg ;; 5233578741aaSmrg *) 5234578741aaSmrg case `$CC -V 2>&1 | sed 5q` in 5235578741aaSmrg *Sun\ C*) 5236578741aaSmrg # Sun C++ 5.9 5237578741aaSmrg _LT_AC_TAGVAR(no_undefined_flag, $1)=' -zdefs' 5238578741aaSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 5239578741aaSmrg _LT_AC_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' 5240578741aaSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 5241578741aaSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' 5242578741aaSmrg 5243578741aaSmrg # Not sure whether something based on 5244578741aaSmrg # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 5245578741aaSmrg # would be better. 5246578741aaSmrg output_verbose_link_cmd='echo' 5247578741aaSmrg 5248578741aaSmrg # Archives containing C++ object files must be created using 5249578741aaSmrg # "CC -xar", where "CC" is the Sun C++ compiler. This is 5250578741aaSmrg # necessary to make sure instantiated templates are included 5251578741aaSmrg # in the archive. 5252578741aaSmrg _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' 5253578741aaSmrg ;; 5254578741aaSmrg esac 5255578741aaSmrg ;; 5256145b7b3cSmrg esac 5257145b7b3cSmrg ;; 5258145b7b3cSmrg lynxos*) 5259145b7b3cSmrg # FIXME: insert proper C++ library support 5260145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 5261145b7b3cSmrg ;; 5262145b7b3cSmrg m88k*) 5263145b7b3cSmrg # FIXME: insert proper C++ library support 5264145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 5265145b7b3cSmrg ;; 5266145b7b3cSmrg mvs*) 5267145b7b3cSmrg case $cc_basename in 5268145b7b3cSmrg cxx*) 5269145b7b3cSmrg # FIXME: insert proper C++ library support 5270145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 5271145b7b3cSmrg ;; 5272145b7b3cSmrg *) 5273145b7b3cSmrg # FIXME: insert proper C++ library support 5274145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 5275145b7b3cSmrg ;; 5276145b7b3cSmrg esac 5277145b7b3cSmrg ;; 5278145b7b3cSmrg netbsd*) 5279145b7b3cSmrg if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then 5280145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' 5281145b7b3cSmrg wlarc= 5282145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 5283145b7b3cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=yes 5284145b7b3cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 5285145b7b3cSmrg fi 5286145b7b3cSmrg # Workaround some broken pre-1.5 toolchains 5287145b7b3cSmrg output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' 5288145b7b3cSmrg ;; 5289145b7b3cSmrg openbsd2*) 5290145b7b3cSmrg # C++ shared libraries are fairly broken 5291145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 5292145b7b3cSmrg ;; 5293145b7b3cSmrg openbsd*) 5294578741aaSmrg if test -f /usr/libexec/ld.so; then 5295578741aaSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=yes 5296578741aaSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 5297578741aaSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' 5298578741aaSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 5299578741aaSmrg if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then 5300578741aaSmrg _LT_AC_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' 5301578741aaSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 5302578741aaSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' 5303578741aaSmrg fi 5304578741aaSmrg output_verbose_link_cmd='echo' 5305578741aaSmrg else 5306578741aaSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 5307145b7b3cSmrg fi 5308145b7b3cSmrg ;; 5309145b7b3cSmrg osf3*) 5310145b7b3cSmrg case $cc_basename in 5311145b7b3cSmrg KCC*) 5312145b7b3cSmrg # Kuck and Associates, Inc. (KAI) C++ Compiler 5313145b7b3cSmrg 5314145b7b3cSmrg # KCC will only create a shared library if the output file 5315145b7b3cSmrg # ends with ".so" (or ".sl" for HP-UX), so rename the library 5316145b7b3cSmrg # to its proper name (with version) after linking. 5317145b7b3cSmrg _LT_AC_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' 5318145b7b3cSmrg 5319145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 5320145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 5321145b7b3cSmrg 5322145b7b3cSmrg # Archives containing C++ object files must be created using 5323145b7b3cSmrg # "CC -Bstatic", where "CC" is the KAI C++ compiler. 5324145b7b3cSmrg _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' 5325145b7b3cSmrg 5326145b7b3cSmrg ;; 5327145b7b3cSmrg RCC*) 5328145b7b3cSmrg # Rational C++ 2.4.1 5329145b7b3cSmrg # FIXME: insert proper C++ library support 5330145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 5331145b7b3cSmrg ;; 5332145b7b3cSmrg cxx*) 5333145b7b3cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' 5334145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && echo ${wl}-set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' 5335145b7b3cSmrg 5336145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 5337145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 5338145b7b3cSmrg 5339145b7b3cSmrg # Commands to make compiler produce verbose output that lists 5340145b7b3cSmrg # what "hidden" libraries, object files and flags are used when 5341145b7b3cSmrg # linking a shared library. 5342145b7b3cSmrg # 5343145b7b3cSmrg # There doesn't appear to be a way to prevent this compiler from 5344145b7b3cSmrg # explicitly linking system object files so we need to strip them 5345145b7b3cSmrg # from the output so that they don't get included in the library 5346145b7b3cSmrg # dependencies. 5347145b7b3cSmrg output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld" | grep -v "ld:"`; templist=`echo $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; echo $list' 5348145b7b3cSmrg ;; 5349145b7b3cSmrg *) 5350145b7b3cSmrg if test "$GXX" = yes && test "$with_gnu_ld" = no; then 5351145b7b3cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' 5352145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' 5353145b7b3cSmrg 5354145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 5355145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 5356145b7b3cSmrg 5357145b7b3cSmrg # Commands to make compiler produce verbose output that lists 5358145b7b3cSmrg # what "hidden" libraries, object files and flags are used when 5359145b7b3cSmrg # linking a shared library. 5360145b7b3cSmrg output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"' 5361145b7b3cSmrg 5362145b7b3cSmrg else 5363145b7b3cSmrg # FIXME: insert proper C++ library support 5364145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 5365145b7b3cSmrg fi 5366145b7b3cSmrg ;; 5367145b7b3cSmrg esac 5368145b7b3cSmrg ;; 5369145b7b3cSmrg osf4* | osf5*) 5370145b7b3cSmrg case $cc_basename in 5371145b7b3cSmrg KCC*) 5372145b7b3cSmrg # Kuck and Associates, Inc. (KAI) C++ Compiler 5373145b7b3cSmrg 5374145b7b3cSmrg # KCC will only create a shared library if the output file 5375145b7b3cSmrg # ends with ".so" (or ".sl" for HP-UX), so rename the library 5376145b7b3cSmrg # to its proper name (with version) after linking. 5377145b7b3cSmrg _LT_AC_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' 5378145b7b3cSmrg 5379145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 5380145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 5381145b7b3cSmrg 5382145b7b3cSmrg # Archives containing C++ object files must be created using 5383145b7b3cSmrg # the KAI C++ compiler. 5384145b7b3cSmrg _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' 5385145b7b3cSmrg ;; 5386145b7b3cSmrg RCC*) 5387145b7b3cSmrg # Rational C++ 2.4.1 5388145b7b3cSmrg # FIXME: insert proper C++ library support 5389145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 5390145b7b3cSmrg ;; 5391145b7b3cSmrg cxx*) 5392145b7b3cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' 5393145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' 5394145b7b3cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ 5395145b7b3cSmrg echo "-hidden">> $lib.exp~ 5396145b7b3cSmrg $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~ 5397145b7b3cSmrg $rm $lib.exp' 5398145b7b3cSmrg 5399145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' 5400145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 5401145b7b3cSmrg 5402145b7b3cSmrg # Commands to make compiler produce verbose output that lists 5403145b7b3cSmrg # what "hidden" libraries, object files and flags are used when 5404145b7b3cSmrg # linking a shared library. 5405145b7b3cSmrg # 5406145b7b3cSmrg # There doesn't appear to be a way to prevent this compiler from 5407145b7b3cSmrg # explicitly linking system object files so we need to strip them 5408145b7b3cSmrg # from the output so that they don't get included in the library 5409145b7b3cSmrg # dependencies. 5410145b7b3cSmrg output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld" | grep -v "ld:"`; templist=`echo $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; echo $list' 5411145b7b3cSmrg ;; 5412145b7b3cSmrg *) 5413145b7b3cSmrg if test "$GXX" = yes && test "$with_gnu_ld" = no; then 5414145b7b3cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' 5415145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' 5416145b7b3cSmrg 5417145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 5418145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 5419145b7b3cSmrg 5420145b7b3cSmrg # Commands to make compiler produce verbose output that lists 5421145b7b3cSmrg # what "hidden" libraries, object files and flags are used when 5422145b7b3cSmrg # linking a shared library. 5423145b7b3cSmrg output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"' 5424145b7b3cSmrg 5425145b7b3cSmrg else 5426145b7b3cSmrg # FIXME: insert proper C++ library support 5427145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 5428145b7b3cSmrg fi 5429145b7b3cSmrg ;; 5430145b7b3cSmrg esac 5431145b7b3cSmrg ;; 5432145b7b3cSmrg psos*) 5433145b7b3cSmrg # FIXME: insert proper C++ library support 5434145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 5435145b7b3cSmrg ;; 5436145b7b3cSmrg sunos4*) 5437145b7b3cSmrg case $cc_basename in 5438145b7b3cSmrg CC*) 5439145b7b3cSmrg # Sun C++ 4.x 5440145b7b3cSmrg # FIXME: insert proper C++ library support 5441145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 5442145b7b3cSmrg ;; 5443145b7b3cSmrg lcc*) 5444145b7b3cSmrg # Lucid 5445145b7b3cSmrg # FIXME: insert proper C++ library support 5446145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 5447145b7b3cSmrg ;; 5448145b7b3cSmrg *) 5449145b7b3cSmrg # FIXME: insert proper C++ library support 5450145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 5451145b7b3cSmrg ;; 5452145b7b3cSmrg esac 5453145b7b3cSmrg ;; 5454145b7b3cSmrg solaris*) 5455145b7b3cSmrg case $cc_basename in 5456145b7b3cSmrg CC*) 5457145b7b3cSmrg # Sun C++ 4.2, 5.x and Centerline C++ 5458145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds_need_lc,$1)=yes 5459145b7b3cSmrg _LT_AC_TAGVAR(no_undefined_flag, $1)=' -zdefs' 5460145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' 5461145b7b3cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ 5462145b7b3cSmrg $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' 5463145b7b3cSmrg 5464145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 5465145b7b3cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 5466145b7b3cSmrg case $host_os in 5467145b7b3cSmrg solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; 5468145b7b3cSmrg *) 5469578741aaSmrg # The compiler driver will combine and reorder linker options, 5470578741aaSmrg # but understands `-z linker_flag'. 5471145b7b3cSmrg # Supported since Solaris 2.6 (maybe 2.5.1?) 5472578741aaSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' 5473145b7b3cSmrg ;; 5474145b7b3cSmrg esac 5475145b7b3cSmrg _LT_AC_TAGVAR(link_all_deplibs, $1)=yes 5476145b7b3cSmrg 5477145b7b3cSmrg output_verbose_link_cmd='echo' 5478145b7b3cSmrg 5479145b7b3cSmrg # Archives containing C++ object files must be created using 5480145b7b3cSmrg # "CC -xar", where "CC" is the Sun C++ compiler. This is 5481145b7b3cSmrg # necessary to make sure instantiated templates are included 5482145b7b3cSmrg # in the archive. 5483145b7b3cSmrg _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' 5484145b7b3cSmrg ;; 5485145b7b3cSmrg gcx*) 5486145b7b3cSmrg # Green Hills C++ Compiler 5487145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' 5488145b7b3cSmrg 5489145b7b3cSmrg # The C++ compiler must be used to create the archive. 5490145b7b3cSmrg _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs' 5491145b7b3cSmrg ;; 5492145b7b3cSmrg *) 5493145b7b3cSmrg # GNU C++ compiler with Solaris linker 5494145b7b3cSmrg if test "$GXX" = yes && test "$with_gnu_ld" = no; then 5495145b7b3cSmrg _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs' 5496145b7b3cSmrg if $CC --version | grep -v '^2\.7' > /dev/null; then 5497145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' 5498145b7b3cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ 5499145b7b3cSmrg $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp' 5500145b7b3cSmrg 5501145b7b3cSmrg # Commands to make compiler produce verbose output that lists 5502145b7b3cSmrg # what "hidden" libraries, object files and flags are used when 5503145b7b3cSmrg # linking a shared library. 5504145b7b3cSmrg output_verbose_link_cmd="$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\"" 5505145b7b3cSmrg else 5506145b7b3cSmrg # g++ 2.7 appears to require `-G' NOT `-shared' on this 5507145b7b3cSmrg # platform. 5508145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' 5509145b7b3cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ 5510145b7b3cSmrg $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp' 5511145b7b3cSmrg 5512145b7b3cSmrg # Commands to make compiler produce verbose output that lists 5513145b7b3cSmrg # what "hidden" libraries, object files and flags are used when 5514145b7b3cSmrg # linking a shared library. 5515145b7b3cSmrg output_verbose_link_cmd="$CC -G $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\"" 5516145b7b3cSmrg fi 5517145b7b3cSmrg 5518145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir' 5519578741aaSmrg case $host_os in 5520578741aaSmrg solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; 5521578741aaSmrg *) 5522578741aaSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' 5523578741aaSmrg ;; 5524578741aaSmrg esac 5525145b7b3cSmrg fi 5526145b7b3cSmrg ;; 5527145b7b3cSmrg esac 5528145b7b3cSmrg ;; 5529145b7b3cSmrg sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) 5530145b7b3cSmrg _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' 5531145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no 5532145b7b3cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 5533145b7b3cSmrg runpath_var='LD_RUN_PATH' 5534145b7b3cSmrg 5535145b7b3cSmrg case $cc_basename in 5536145b7b3cSmrg CC*) 5537145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 5538145b7b3cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 5539145b7b3cSmrg ;; 5540145b7b3cSmrg *) 5541145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 5542145b7b3cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 5543145b7b3cSmrg ;; 5544145b7b3cSmrg esac 5545145b7b3cSmrg ;; 5546145b7b3cSmrg sysv5* | sco3.2v5* | sco5v6*) 5547145b7b3cSmrg # Note: We can NOT use -z defs as we might desire, because we do not 5548145b7b3cSmrg # link with -lc, and that would cause any symbols used from libc to 5549145b7b3cSmrg # always be unresolved, which means just about no library would 5550145b7b3cSmrg # ever link correctly. If we're not using GNU ld we use -z text 5551145b7b3cSmrg # though, which does catch some bad symbols but isn't as heavy-handed 5552145b7b3cSmrg # as -z defs. 5553145b7b3cSmrg # For security reasons, it is highly recommended that you always 5554145b7b3cSmrg # use absolute paths for naming shared libraries, and exclude the 5555145b7b3cSmrg # DT_RUNPATH tag from executables and libraries. But doing so 5556145b7b3cSmrg # requires that you compile everything twice, which is a pain. 5557145b7b3cSmrg # So that behaviour is only enabled if SCOABSPATH is set to a 5558145b7b3cSmrg # non-empty value in the environment. Most likely only useful for 5559145b7b3cSmrg # creating official distributions of packages. 5560145b7b3cSmrg # This is a hack until libtool officially supports absolute path 5561145b7b3cSmrg # names for shared libraries. 5562145b7b3cSmrg _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' 5563145b7b3cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs' 5564145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no 5565145b7b3cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 5566145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`' 5567145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':' 5568145b7b3cSmrg _LT_AC_TAGVAR(link_all_deplibs, $1)=yes 5569145b7b3cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' 5570145b7b3cSmrg runpath_var='LD_RUN_PATH' 5571145b7b3cSmrg 5572145b7b3cSmrg case $cc_basename in 5573145b7b3cSmrg CC*) 5574145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' 5575145b7b3cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' 5576145b7b3cSmrg ;; 5577145b7b3cSmrg *) 5578145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' 5579145b7b3cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' 5580145b7b3cSmrg ;; 5581145b7b3cSmrg esac 5582145b7b3cSmrg ;; 5583145b7b3cSmrg tandem*) 5584145b7b3cSmrg case $cc_basename in 5585145b7b3cSmrg NCC*) 5586145b7b3cSmrg # NonStop-UX NCC 3.20 5587145b7b3cSmrg # FIXME: insert proper C++ library support 5588145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 5589145b7b3cSmrg ;; 5590145b7b3cSmrg *) 5591145b7b3cSmrg # FIXME: insert proper C++ library support 5592145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 5593145b7b3cSmrg ;; 5594145b7b3cSmrg esac 5595145b7b3cSmrg ;; 5596145b7b3cSmrg vxworks*) 5597145b7b3cSmrg # FIXME: insert proper C++ library support 5598145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 5599145b7b3cSmrg ;; 5600145b7b3cSmrg *) 5601145b7b3cSmrg # FIXME: insert proper C++ library support 5602145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 5603145b7b3cSmrg ;; 5604145b7b3cSmrgesac 5605145b7b3cSmrgAC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)]) 5606145b7b3cSmrgtest "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no 5607145b7b3cSmrg 5608145b7b3cSmrg_LT_AC_TAGVAR(GCC, $1)="$GXX" 5609145b7b3cSmrg_LT_AC_TAGVAR(LD, $1)="$LD" 5610145b7b3cSmrg 5611145b7b3cSmrgAC_LIBTOOL_POSTDEP_PREDEP($1) 5612145b7b3cSmrgAC_LIBTOOL_PROG_COMPILER_PIC($1) 5613145b7b3cSmrgAC_LIBTOOL_PROG_CC_C_O($1) 5614145b7b3cSmrgAC_LIBTOOL_SYS_HARD_LINK_LOCKS($1) 5615145b7b3cSmrgAC_LIBTOOL_PROG_LD_SHLIBS($1) 5616145b7b3cSmrgAC_LIBTOOL_SYS_DYNAMIC_LINKER($1) 5617145b7b3cSmrgAC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1) 5618145b7b3cSmrg 5619145b7b3cSmrgAC_LIBTOOL_CONFIG($1) 5620145b7b3cSmrg 5621145b7b3cSmrgAC_LANG_POP 5622145b7b3cSmrgCC=$lt_save_CC 5623145b7b3cSmrgLDCXX=$LD 5624145b7b3cSmrgLD=$lt_save_LD 5625145b7b3cSmrgGCC=$lt_save_GCC 5626145b7b3cSmrgwith_gnu_ldcxx=$with_gnu_ld 5627145b7b3cSmrgwith_gnu_ld=$lt_save_with_gnu_ld 5628145b7b3cSmrglt_cv_path_LDCXX=$lt_cv_path_LD 5629145b7b3cSmrglt_cv_path_LD=$lt_save_path_LD 5630145b7b3cSmrglt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld 5631145b7b3cSmrglt_cv_prog_gnu_ld=$lt_save_with_gnu_ld 5632145b7b3cSmrg])# AC_LIBTOOL_LANG_CXX_CONFIG 5633145b7b3cSmrg 5634145b7b3cSmrg# AC_LIBTOOL_POSTDEP_PREDEP([TAGNAME]) 5635145b7b3cSmrg# ------------------------------------ 5636145b7b3cSmrg# Figure out "hidden" library dependencies from verbose 5637145b7b3cSmrg# compiler output when linking a shared library. 5638145b7b3cSmrg# Parse the compiler output and extract the necessary 5639145b7b3cSmrg# objects, libraries and library flags. 5640578741aaSmrgAC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP], 5641578741aaSmrg[AC_REQUIRE([LT_AC_PROG_SED])dnl 5642145b7b3cSmrgdnl we can't use the lt_simple_compile_test_code here, 5643145b7b3cSmrgdnl because it contains code intended for an executable, 5644145b7b3cSmrgdnl not a library. It's possible we should let each 5645145b7b3cSmrgdnl tag define a new lt_????_link_test_code variable, 5646145b7b3cSmrgdnl but it's only used here... 5647145b7b3cSmrgifelse([$1],[],[cat > conftest.$ac_ext <<EOF 5648145b7b3cSmrgint a; 5649145b7b3cSmrgvoid foo (void) { a = 0; } 5650145b7b3cSmrgEOF 5651145b7b3cSmrg],[$1],[CXX],[cat > conftest.$ac_ext <<EOF 5652145b7b3cSmrgclass Foo 5653145b7b3cSmrg{ 5654145b7b3cSmrgpublic: 5655145b7b3cSmrg Foo (void) { a = 0; } 5656145b7b3cSmrgprivate: 5657145b7b3cSmrg int a; 5658145b7b3cSmrg}; 5659145b7b3cSmrgEOF 5660145b7b3cSmrg],[$1],[F77],[cat > conftest.$ac_ext <<EOF 5661145b7b3cSmrg subroutine foo 5662145b7b3cSmrg implicit none 5663145b7b3cSmrg integer*4 a 5664145b7b3cSmrg a=0 5665145b7b3cSmrg return 5666145b7b3cSmrg end 5667145b7b3cSmrgEOF 5668145b7b3cSmrg],[$1],[GCJ],[cat > conftest.$ac_ext <<EOF 5669145b7b3cSmrgpublic class foo { 5670145b7b3cSmrg private int a; 5671145b7b3cSmrg public void bar (void) { 5672145b7b3cSmrg a = 0; 5673145b7b3cSmrg } 5674145b7b3cSmrg}; 5675145b7b3cSmrgEOF 5676145b7b3cSmrg]) 5677145b7b3cSmrgdnl Parse the compiler output and extract the necessary 5678145b7b3cSmrgdnl objects, libraries and library flags. 5679145b7b3cSmrgif AC_TRY_EVAL(ac_compile); then 5680145b7b3cSmrg # Parse the compiler output and extract the necessary 5681145b7b3cSmrg # objects, libraries and library flags. 5682145b7b3cSmrg 5683145b7b3cSmrg # Sentinel used to keep track of whether or not we are before 5684145b7b3cSmrg # the conftest object file. 5685145b7b3cSmrg pre_test_object_deps_done=no 5686145b7b3cSmrg 5687145b7b3cSmrg # The `*' in the case matches for architectures that use `case' in 5688145b7b3cSmrg # $output_verbose_cmd can trigger glob expansion during the loop 5689145b7b3cSmrg # eval without this substitution. 5690145b7b3cSmrg output_verbose_link_cmd=`$echo "X$output_verbose_link_cmd" | $Xsed -e "$no_glob_subst"` 5691145b7b3cSmrg 5692145b7b3cSmrg for p in `eval $output_verbose_link_cmd`; do 5693145b7b3cSmrg case $p in 5694145b7b3cSmrg 5695145b7b3cSmrg -L* | -R* | -l*) 5696145b7b3cSmrg # Some compilers place space between "-{L,R}" and the path. 5697145b7b3cSmrg # Remove the space. 5698145b7b3cSmrg if test $p = "-L" \ 5699145b7b3cSmrg || test $p = "-R"; then 5700145b7b3cSmrg prev=$p 5701145b7b3cSmrg continue 5702145b7b3cSmrg else 5703145b7b3cSmrg prev= 5704145b7b3cSmrg fi 5705145b7b3cSmrg 5706145b7b3cSmrg if test "$pre_test_object_deps_done" = no; then 5707145b7b3cSmrg case $p in 5708145b7b3cSmrg -L* | -R*) 5709145b7b3cSmrg # Internal compiler library paths should come after those 5710145b7b3cSmrg # provided the user. The postdeps already come after the 5711145b7b3cSmrg # user supplied libs so there is no need to process them. 5712145b7b3cSmrg if test -z "$_LT_AC_TAGVAR(compiler_lib_search_path, $1)"; then 5713145b7b3cSmrg _LT_AC_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}" 5714145b7b3cSmrg else 5715145b7b3cSmrg _LT_AC_TAGVAR(compiler_lib_search_path, $1)="${_LT_AC_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}" 5716145b7b3cSmrg fi 5717145b7b3cSmrg ;; 5718145b7b3cSmrg # The "-l" case would never come before the object being 5719145b7b3cSmrg # linked, so don't bother handling this case. 5720145b7b3cSmrg esac 5721145b7b3cSmrg else 5722145b7b3cSmrg if test -z "$_LT_AC_TAGVAR(postdeps, $1)"; then 5723145b7b3cSmrg _LT_AC_TAGVAR(postdeps, $1)="${prev}${p}" 5724145b7b3cSmrg else 5725145b7b3cSmrg _LT_AC_TAGVAR(postdeps, $1)="${_LT_AC_TAGVAR(postdeps, $1)} ${prev}${p}" 5726145b7b3cSmrg fi 5727145b7b3cSmrg fi 5728145b7b3cSmrg ;; 5729145b7b3cSmrg 5730145b7b3cSmrg *.$objext) 5731145b7b3cSmrg # This assumes that the test object file only shows up 5732145b7b3cSmrg # once in the compiler output. 5733145b7b3cSmrg if test "$p" = "conftest.$objext"; then 5734145b7b3cSmrg pre_test_object_deps_done=yes 5735145b7b3cSmrg continue 5736145b7b3cSmrg fi 5737145b7b3cSmrg 5738145b7b3cSmrg if test "$pre_test_object_deps_done" = no; then 5739145b7b3cSmrg if test -z "$_LT_AC_TAGVAR(predep_objects, $1)"; then 5740145b7b3cSmrg _LT_AC_TAGVAR(predep_objects, $1)="$p" 5741145b7b3cSmrg else 5742145b7b3cSmrg _LT_AC_TAGVAR(predep_objects, $1)="$_LT_AC_TAGVAR(predep_objects, $1) $p" 5743145b7b3cSmrg fi 5744145b7b3cSmrg else 5745145b7b3cSmrg if test -z "$_LT_AC_TAGVAR(postdep_objects, $1)"; then 5746145b7b3cSmrg _LT_AC_TAGVAR(postdep_objects, $1)="$p" 5747145b7b3cSmrg else 5748145b7b3cSmrg _LT_AC_TAGVAR(postdep_objects, $1)="$_LT_AC_TAGVAR(postdep_objects, $1) $p" 5749145b7b3cSmrg fi 5750145b7b3cSmrg fi 5751145b7b3cSmrg ;; 5752145b7b3cSmrg 5753145b7b3cSmrg *) ;; # Ignore the rest. 5754145b7b3cSmrg 5755145b7b3cSmrg esac 5756145b7b3cSmrg done 5757145b7b3cSmrg 5758145b7b3cSmrg # Clean up. 5759145b7b3cSmrg rm -f a.out a.exe 5760145b7b3cSmrgelse 5761145b7b3cSmrg echo "libtool.m4: error: problem compiling $1 test program" 5762145b7b3cSmrgfi 5763145b7b3cSmrg 5764145b7b3cSmrg$rm -f confest.$objext 5765145b7b3cSmrg 5766578741aaSmrg_LT_AC_TAGVAR(compiler_lib_search_dirs, $1)= 5767578741aaSmrgif test -n "$_LT_AC_TAGVAR(compiler_lib_search_path, $1)"; then 5768578741aaSmrg _LT_AC_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_AC_TAGVAR(compiler_lib_search_path, $1)}" | ${SED} -e 's! -L! !g' -e 's!^ !!'` 5769578741aaSmrgfi 5770578741aaSmrg 5771145b7b3cSmrg# PORTME: override above test on systems where it is broken 5772145b7b3cSmrgifelse([$1],[CXX], 5773145b7b3cSmrg[case $host_os in 5774578741aaSmrginterix[[3-9]]*) 5775145b7b3cSmrg # Interix 3.5 installs completely hosed .la files for C++, so rather than 5776145b7b3cSmrg # hack all around it, let's just trust "g++" to DTRT. 5777145b7b3cSmrg _LT_AC_TAGVAR(predep_objects,$1)= 5778145b7b3cSmrg _LT_AC_TAGVAR(postdep_objects,$1)= 5779145b7b3cSmrg _LT_AC_TAGVAR(postdeps,$1)= 5780145b7b3cSmrg ;; 5781145b7b3cSmrg 5782578741aaSmrglinux*) 5783578741aaSmrg case `$CC -V 2>&1 | sed 5q` in 5784578741aaSmrg *Sun\ C*) 5785578741aaSmrg # Sun C++ 5.9 5786578741aaSmrg # 5787578741aaSmrg # The more standards-conforming stlport4 library is 5788578741aaSmrg # incompatible with the Cstd library. Avoid specifying 5789578741aaSmrg # it if it's in CXXFLAGS. Ignore libCrun as 5790578741aaSmrg # -library=stlport4 depends on it. 5791578741aaSmrg case " $CXX $CXXFLAGS " in 5792578741aaSmrg *" -library=stlport4 "*) 5793578741aaSmrg solaris_use_stlport4=yes 5794578741aaSmrg ;; 5795578741aaSmrg esac 5796578741aaSmrg if test "$solaris_use_stlport4" != yes; then 5797578741aaSmrg _LT_AC_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun' 5798578741aaSmrg fi 5799578741aaSmrg ;; 5800578741aaSmrg esac 5801578741aaSmrg ;; 5802578741aaSmrg 5803145b7b3cSmrgsolaris*) 5804145b7b3cSmrg case $cc_basename in 5805145b7b3cSmrg CC*) 5806578741aaSmrg # The more standards-conforming stlport4 library is 5807578741aaSmrg # incompatible with the Cstd library. Avoid specifying 5808578741aaSmrg # it if it's in CXXFLAGS. Ignore libCrun as 5809578741aaSmrg # -library=stlport4 depends on it. 5810578741aaSmrg case " $CXX $CXXFLAGS " in 5811578741aaSmrg *" -library=stlport4 "*) 5812578741aaSmrg solaris_use_stlport4=yes 5813578741aaSmrg ;; 5814578741aaSmrg esac 5815578741aaSmrg 5816145b7b3cSmrg # Adding this requires a known-good setup of shared libraries for 5817145b7b3cSmrg # Sun compiler versions before 5.6, else PIC objects from an old 5818145b7b3cSmrg # archive will be linked into the output, leading to subtle bugs. 5819578741aaSmrg if test "$solaris_use_stlport4" != yes; then 5820578741aaSmrg _LT_AC_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun' 5821578741aaSmrg fi 5822145b7b3cSmrg ;; 5823145b7b3cSmrg esac 5824145b7b3cSmrg ;; 5825145b7b3cSmrgesac 5826145b7b3cSmrg]) 5827145b7b3cSmrgcase " $_LT_AC_TAGVAR(postdeps, $1) " in 5828145b7b3cSmrg*" -lc "*) _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no ;; 5829145b7b3cSmrgesac 5830145b7b3cSmrg])# AC_LIBTOOL_POSTDEP_PREDEP 5831145b7b3cSmrg 5832145b7b3cSmrg# AC_LIBTOOL_LANG_F77_CONFIG 5833145b7b3cSmrg# -------------------------- 5834145b7b3cSmrg# Ensure that the configuration vars for the C compiler are 5835145b7b3cSmrg# suitably defined. Those variables are subsequently used by 5836145b7b3cSmrg# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'. 5837145b7b3cSmrgAC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG], [_LT_AC_LANG_F77_CONFIG(F77)]) 5838145b7b3cSmrgAC_DEFUN([_LT_AC_LANG_F77_CONFIG], 5839145b7b3cSmrg[AC_REQUIRE([AC_PROG_F77]) 5840145b7b3cSmrgAC_LANG_PUSH(Fortran 77) 5841145b7b3cSmrg 5842145b7b3cSmrg_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no 5843145b7b3cSmrg_LT_AC_TAGVAR(allow_undefined_flag, $1)= 5844145b7b3cSmrg_LT_AC_TAGVAR(always_export_symbols, $1)=no 5845145b7b3cSmrg_LT_AC_TAGVAR(archive_expsym_cmds, $1)= 5846145b7b3cSmrg_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)= 5847145b7b3cSmrg_LT_AC_TAGVAR(hardcode_direct, $1)=no 5848145b7b3cSmrg_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)= 5849145b7b3cSmrg_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= 5850145b7b3cSmrg_LT_AC_TAGVAR(hardcode_libdir_separator, $1)= 5851145b7b3cSmrg_LT_AC_TAGVAR(hardcode_minus_L, $1)=no 5852145b7b3cSmrg_LT_AC_TAGVAR(hardcode_automatic, $1)=no 5853145b7b3cSmrg_LT_AC_TAGVAR(module_cmds, $1)= 5854145b7b3cSmrg_LT_AC_TAGVAR(module_expsym_cmds, $1)= 5855145b7b3cSmrg_LT_AC_TAGVAR(link_all_deplibs, $1)=unknown 5856145b7b3cSmrg_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 5857145b7b3cSmrg_LT_AC_TAGVAR(no_undefined_flag, $1)= 5858145b7b3cSmrg_LT_AC_TAGVAR(whole_archive_flag_spec, $1)= 5859145b7b3cSmrg_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no 5860145b7b3cSmrg 5861145b7b3cSmrg# Source file extension for f77 test sources. 5862145b7b3cSmrgac_ext=f 5863145b7b3cSmrg 5864145b7b3cSmrg# Object file extension for compiled f77 test sources. 5865145b7b3cSmrgobjext=o 5866145b7b3cSmrg_LT_AC_TAGVAR(objext, $1)=$objext 5867145b7b3cSmrg 5868145b7b3cSmrg# Code to be used in simple compile tests 5869578741aaSmrglt_simple_compile_test_code="\ 5870578741aaSmrg subroutine t 5871578741aaSmrg return 5872578741aaSmrg end 5873578741aaSmrg" 5874145b7b3cSmrg 5875145b7b3cSmrg# Code to be used in simple link tests 5876578741aaSmrglt_simple_link_test_code="\ 5877578741aaSmrg program t 5878578741aaSmrg end 5879578741aaSmrg" 5880145b7b3cSmrg 5881145b7b3cSmrg# ltmain only uses $CC for tagged configurations so make sure $CC is set. 5882145b7b3cSmrg_LT_AC_SYS_COMPILER 5883145b7b3cSmrg 5884145b7b3cSmrg# save warnings/boilerplate of simple test code 5885145b7b3cSmrg_LT_COMPILER_BOILERPLATE 5886145b7b3cSmrg_LT_LINKER_BOILERPLATE 5887145b7b3cSmrg 5888145b7b3cSmrg# Allow CC to be a program name with arguments. 5889145b7b3cSmrglt_save_CC="$CC" 5890145b7b3cSmrgCC=${F77-"f77"} 5891145b7b3cSmrgcompiler=$CC 5892145b7b3cSmrg_LT_AC_TAGVAR(compiler, $1)=$CC 5893145b7b3cSmrg_LT_CC_BASENAME([$compiler]) 5894145b7b3cSmrg 5895145b7b3cSmrgAC_MSG_CHECKING([if libtool supports shared libraries]) 5896145b7b3cSmrgAC_MSG_RESULT([$can_build_shared]) 5897145b7b3cSmrg 5898145b7b3cSmrgAC_MSG_CHECKING([whether to build shared libraries]) 5899145b7b3cSmrgtest "$can_build_shared" = "no" && enable_shared=no 5900145b7b3cSmrg 5901145b7b3cSmrg# On AIX, shared libraries and static libraries use the same namespace, and 5902145b7b3cSmrg# are all built from PIC. 5903145b7b3cSmrgcase $host_os in 5904145b7b3cSmrgaix3*) 5905145b7b3cSmrg test "$enable_shared" = yes && enable_static=no 5906145b7b3cSmrg if test -n "$RANLIB"; then 5907145b7b3cSmrg archive_cmds="$archive_cmds~\$RANLIB \$lib" 5908145b7b3cSmrg postinstall_cmds='$RANLIB $lib' 5909145b7b3cSmrg fi 5910145b7b3cSmrg ;; 5911578741aaSmrgaix[[4-9]]*) 5912145b7b3cSmrg if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then 5913145b7b3cSmrg test "$enable_shared" = yes && enable_static=no 5914145b7b3cSmrg fi 5915145b7b3cSmrg ;; 5916145b7b3cSmrgesac 5917145b7b3cSmrgAC_MSG_RESULT([$enable_shared]) 5918145b7b3cSmrg 5919145b7b3cSmrgAC_MSG_CHECKING([whether to build static libraries]) 5920145b7b3cSmrg# Make sure either enable_shared or enable_static is yes. 5921145b7b3cSmrgtest "$enable_shared" = yes || enable_static=yes 5922145b7b3cSmrgAC_MSG_RESULT([$enable_static]) 5923145b7b3cSmrg 5924145b7b3cSmrg_LT_AC_TAGVAR(GCC, $1)="$G77" 5925145b7b3cSmrg_LT_AC_TAGVAR(LD, $1)="$LD" 5926145b7b3cSmrg 5927145b7b3cSmrgAC_LIBTOOL_PROG_COMPILER_PIC($1) 5928145b7b3cSmrgAC_LIBTOOL_PROG_CC_C_O($1) 5929145b7b3cSmrgAC_LIBTOOL_SYS_HARD_LINK_LOCKS($1) 5930145b7b3cSmrgAC_LIBTOOL_PROG_LD_SHLIBS($1) 5931145b7b3cSmrgAC_LIBTOOL_SYS_DYNAMIC_LINKER($1) 5932145b7b3cSmrgAC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1) 5933145b7b3cSmrg 5934145b7b3cSmrgAC_LIBTOOL_CONFIG($1) 5935145b7b3cSmrg 5936145b7b3cSmrgAC_LANG_POP 5937145b7b3cSmrgCC="$lt_save_CC" 5938145b7b3cSmrg])# AC_LIBTOOL_LANG_F77_CONFIG 5939145b7b3cSmrg 5940145b7b3cSmrg 5941145b7b3cSmrg# AC_LIBTOOL_LANG_GCJ_CONFIG 5942145b7b3cSmrg# -------------------------- 5943145b7b3cSmrg# Ensure that the configuration vars for the C compiler are 5944145b7b3cSmrg# suitably defined. Those variables are subsequently used by 5945145b7b3cSmrg# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'. 5946145b7b3cSmrgAC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG], [_LT_AC_LANG_GCJ_CONFIG(GCJ)]) 5947145b7b3cSmrgAC_DEFUN([_LT_AC_LANG_GCJ_CONFIG], 5948145b7b3cSmrg[AC_LANG_SAVE 5949145b7b3cSmrg 5950145b7b3cSmrg# Source file extension for Java test sources. 5951145b7b3cSmrgac_ext=java 5952145b7b3cSmrg 5953145b7b3cSmrg# Object file extension for compiled Java test sources. 5954145b7b3cSmrgobjext=o 5955145b7b3cSmrg_LT_AC_TAGVAR(objext, $1)=$objext 5956145b7b3cSmrg 5957145b7b3cSmrg# Code to be used in simple compile tests 5958578741aaSmrglt_simple_compile_test_code="class foo {}" 5959145b7b3cSmrg 5960145b7b3cSmrg# Code to be used in simple link tests 5961578741aaSmrglt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }' 5962145b7b3cSmrg 5963145b7b3cSmrg# ltmain only uses $CC for tagged configurations so make sure $CC is set. 5964145b7b3cSmrg_LT_AC_SYS_COMPILER 5965145b7b3cSmrg 5966145b7b3cSmrg# save warnings/boilerplate of simple test code 5967145b7b3cSmrg_LT_COMPILER_BOILERPLATE 5968145b7b3cSmrg_LT_LINKER_BOILERPLATE 5969145b7b3cSmrg 5970145b7b3cSmrg# Allow CC to be a program name with arguments. 5971145b7b3cSmrglt_save_CC="$CC" 5972145b7b3cSmrgCC=${GCJ-"gcj"} 5973145b7b3cSmrgcompiler=$CC 5974145b7b3cSmrg_LT_AC_TAGVAR(compiler, $1)=$CC 5975145b7b3cSmrg_LT_CC_BASENAME([$compiler]) 5976145b7b3cSmrg 5977145b7b3cSmrg# GCJ did not exist at the time GCC didn't implicitly link libc in. 5978145b7b3cSmrg_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no 5979145b7b3cSmrg 5980145b7b3cSmrg_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds 5981145b7b3cSmrg 5982145b7b3cSmrgAC_LIBTOOL_PROG_COMPILER_NO_RTTI($1) 5983145b7b3cSmrgAC_LIBTOOL_PROG_COMPILER_PIC($1) 5984145b7b3cSmrgAC_LIBTOOL_PROG_CC_C_O($1) 5985145b7b3cSmrgAC_LIBTOOL_SYS_HARD_LINK_LOCKS($1) 5986145b7b3cSmrgAC_LIBTOOL_PROG_LD_SHLIBS($1) 5987145b7b3cSmrgAC_LIBTOOL_SYS_DYNAMIC_LINKER($1) 5988145b7b3cSmrgAC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1) 5989145b7b3cSmrg 5990145b7b3cSmrgAC_LIBTOOL_CONFIG($1) 5991145b7b3cSmrg 5992145b7b3cSmrgAC_LANG_RESTORE 5993145b7b3cSmrgCC="$lt_save_CC" 5994145b7b3cSmrg])# AC_LIBTOOL_LANG_GCJ_CONFIG 5995145b7b3cSmrg 5996145b7b3cSmrg 5997145b7b3cSmrg# AC_LIBTOOL_LANG_RC_CONFIG 5998145b7b3cSmrg# ------------------------- 5999145b7b3cSmrg# Ensure that the configuration vars for the Windows resource compiler are 6000145b7b3cSmrg# suitably defined. Those variables are subsequently used by 6001145b7b3cSmrg# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'. 6002145b7b3cSmrgAC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG], [_LT_AC_LANG_RC_CONFIG(RC)]) 6003145b7b3cSmrgAC_DEFUN([_LT_AC_LANG_RC_CONFIG], 6004145b7b3cSmrg[AC_LANG_SAVE 6005145b7b3cSmrg 6006145b7b3cSmrg# Source file extension for RC test sources. 6007145b7b3cSmrgac_ext=rc 6008145b7b3cSmrg 6009145b7b3cSmrg# Object file extension for compiled RC test sources. 6010145b7b3cSmrgobjext=o 6011145b7b3cSmrg_LT_AC_TAGVAR(objext, $1)=$objext 6012145b7b3cSmrg 6013145b7b3cSmrg# Code to be used in simple compile tests 6014578741aaSmrglt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }' 6015145b7b3cSmrg 6016145b7b3cSmrg# Code to be used in simple link tests 6017145b7b3cSmrglt_simple_link_test_code="$lt_simple_compile_test_code" 6018145b7b3cSmrg 6019145b7b3cSmrg# ltmain only uses $CC for tagged configurations so make sure $CC is set. 6020145b7b3cSmrg_LT_AC_SYS_COMPILER 6021145b7b3cSmrg 6022145b7b3cSmrg# save warnings/boilerplate of simple test code 6023145b7b3cSmrg_LT_COMPILER_BOILERPLATE 6024145b7b3cSmrg_LT_LINKER_BOILERPLATE 6025145b7b3cSmrg 6026145b7b3cSmrg# Allow CC to be a program name with arguments. 6027145b7b3cSmrglt_save_CC="$CC" 6028145b7b3cSmrgCC=${RC-"windres"} 6029145b7b3cSmrgcompiler=$CC 6030145b7b3cSmrg_LT_AC_TAGVAR(compiler, $1)=$CC 6031145b7b3cSmrg_LT_CC_BASENAME([$compiler]) 6032145b7b3cSmrg_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes 6033145b7b3cSmrg 6034145b7b3cSmrgAC_LIBTOOL_CONFIG($1) 6035145b7b3cSmrg 6036145b7b3cSmrgAC_LANG_RESTORE 6037145b7b3cSmrgCC="$lt_save_CC" 6038145b7b3cSmrg])# AC_LIBTOOL_LANG_RC_CONFIG 6039145b7b3cSmrg 6040145b7b3cSmrg 6041145b7b3cSmrg# AC_LIBTOOL_CONFIG([TAGNAME]) 6042145b7b3cSmrg# ---------------------------- 6043145b7b3cSmrg# If TAGNAME is not passed, then create an initial libtool script 6044145b7b3cSmrg# with a default configuration from the untagged config vars. Otherwise 6045145b7b3cSmrg# add code to config.status for appending the configuration named by 6046145b7b3cSmrg# TAGNAME from the matching tagged config vars. 6047145b7b3cSmrgAC_DEFUN([AC_LIBTOOL_CONFIG], 6048145b7b3cSmrg[# The else clause should only fire when bootstrapping the 6049145b7b3cSmrg# libtool distribution, otherwise you forgot to ship ltmain.sh 6050145b7b3cSmrg# with your package, and you will get complaints that there are 6051145b7b3cSmrg# no rules to generate ltmain.sh. 6052145b7b3cSmrgif test -f "$ltmain"; then 6053145b7b3cSmrg # See if we are running on zsh, and set the options which allow our commands through 6054145b7b3cSmrg # without removal of \ escapes. 6055145b7b3cSmrg if test -n "${ZSH_VERSION+set}" ; then 6056145b7b3cSmrg setopt NO_GLOB_SUBST 6057145b7b3cSmrg fi 6058145b7b3cSmrg # Now quote all the things that may contain metacharacters while being 6059145b7b3cSmrg # careful not to overquote the AC_SUBSTed values. We take copies of the 6060145b7b3cSmrg # variables and quote the copies for generation of the libtool script. 6061145b7b3cSmrg for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC LTCFLAGS NM \ 6062145b7b3cSmrg SED SHELL STRIP \ 6063145b7b3cSmrg libname_spec library_names_spec soname_spec extract_expsyms_cmds \ 6064145b7b3cSmrg old_striplib striplib file_magic_cmd finish_cmds finish_eval \ 6065145b7b3cSmrg deplibs_check_method reload_flag reload_cmds need_locks \ 6066145b7b3cSmrg lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \ 6067145b7b3cSmrg lt_cv_sys_global_symbol_to_c_name_address \ 6068145b7b3cSmrg sys_lib_search_path_spec sys_lib_dlsearch_path_spec \ 6069145b7b3cSmrg old_postinstall_cmds old_postuninstall_cmds \ 6070145b7b3cSmrg _LT_AC_TAGVAR(compiler, $1) \ 6071145b7b3cSmrg _LT_AC_TAGVAR(CC, $1) \ 6072145b7b3cSmrg _LT_AC_TAGVAR(LD, $1) \ 6073145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1) \ 6074145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1) \ 6075145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1) \ 6076145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) \ 6077145b7b3cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1) \ 6078145b7b3cSmrg _LT_AC_TAGVAR(thread_safe_flag_spec, $1) \ 6079145b7b3cSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1) \ 6080145b7b3cSmrg _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1) \ 6081145b7b3cSmrg _LT_AC_TAGVAR(old_archive_cmds, $1) \ 6082145b7b3cSmrg _LT_AC_TAGVAR(old_archive_from_new_cmds, $1) \ 6083145b7b3cSmrg _LT_AC_TAGVAR(predep_objects, $1) \ 6084145b7b3cSmrg _LT_AC_TAGVAR(postdep_objects, $1) \ 6085145b7b3cSmrg _LT_AC_TAGVAR(predeps, $1) \ 6086145b7b3cSmrg _LT_AC_TAGVAR(postdeps, $1) \ 6087145b7b3cSmrg _LT_AC_TAGVAR(compiler_lib_search_path, $1) \ 6088578741aaSmrg _LT_AC_TAGVAR(compiler_lib_search_dirs, $1) \ 6089145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1) \ 6090145b7b3cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1) \ 6091145b7b3cSmrg _LT_AC_TAGVAR(postinstall_cmds, $1) \ 6092145b7b3cSmrg _LT_AC_TAGVAR(postuninstall_cmds, $1) \ 6093145b7b3cSmrg _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) \ 6094145b7b3cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1) \ 6095145b7b3cSmrg _LT_AC_TAGVAR(no_undefined_flag, $1) \ 6096145b7b3cSmrg _LT_AC_TAGVAR(export_symbols_cmds, $1) \ 6097145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) \ 6098145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1) \ 6099145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1) \ 6100145b7b3cSmrg _LT_AC_TAGVAR(hardcode_automatic, $1) \ 6101145b7b3cSmrg _LT_AC_TAGVAR(module_cmds, $1) \ 6102145b7b3cSmrg _LT_AC_TAGVAR(module_expsym_cmds, $1) \ 6103145b7b3cSmrg _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1) \ 6104578741aaSmrg _LT_AC_TAGVAR(fix_srcfile_path, $1) \ 6105145b7b3cSmrg _LT_AC_TAGVAR(exclude_expsyms, $1) \ 6106145b7b3cSmrg _LT_AC_TAGVAR(include_expsyms, $1); do 6107145b7b3cSmrg 6108145b7b3cSmrg case $var in 6109145b7b3cSmrg _LT_AC_TAGVAR(old_archive_cmds, $1) | \ 6110145b7b3cSmrg _LT_AC_TAGVAR(old_archive_from_new_cmds, $1) | \ 6111145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1) | \ 6112145b7b3cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1) | \ 6113145b7b3cSmrg _LT_AC_TAGVAR(module_cmds, $1) | \ 6114145b7b3cSmrg _LT_AC_TAGVAR(module_expsym_cmds, $1) | \ 6115145b7b3cSmrg _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) | \ 6116145b7b3cSmrg _LT_AC_TAGVAR(export_symbols_cmds, $1) | \ 6117145b7b3cSmrg extract_expsyms_cmds | reload_cmds | finish_cmds | \ 6118145b7b3cSmrg postinstall_cmds | postuninstall_cmds | \ 6119145b7b3cSmrg old_postinstall_cmds | old_postuninstall_cmds | \ 6120145b7b3cSmrg sys_lib_search_path_spec | sys_lib_dlsearch_path_spec) 6121145b7b3cSmrg # Double-quote double-evaled strings. 6122145b7b3cSmrg eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\"" 6123145b7b3cSmrg ;; 6124145b7b3cSmrg *) 6125145b7b3cSmrg eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\"" 6126145b7b3cSmrg ;; 6127145b7b3cSmrg esac 6128145b7b3cSmrg done 6129145b7b3cSmrg 6130145b7b3cSmrg case $lt_echo in 6131145b7b3cSmrg *'\[$]0 --fallback-echo"') 6132145b7b3cSmrg lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\[$]0 --fallback-echo"[$]/[$]0 --fallback-echo"/'` 6133145b7b3cSmrg ;; 6134145b7b3cSmrg esac 6135145b7b3cSmrg 6136145b7b3cSmrgifelse([$1], [], 6137145b7b3cSmrg [cfgfile="${ofile}T" 6138145b7b3cSmrg trap "$rm \"$cfgfile\"; exit 1" 1 2 15 6139145b7b3cSmrg $rm -f "$cfgfile" 6140145b7b3cSmrg AC_MSG_NOTICE([creating $ofile])], 6141145b7b3cSmrg [cfgfile="$ofile"]) 6142145b7b3cSmrg 6143145b7b3cSmrg cat <<__EOF__ >> "$cfgfile" 6144145b7b3cSmrgifelse([$1], [], 6145145b7b3cSmrg[#! $SHELL 6146145b7b3cSmrg 6147145b7b3cSmrg# `$echo "$cfgfile" | sed 's%^.*/%%'` - Provide generalized library-building support services. 6148145b7b3cSmrg# Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP) 6149145b7b3cSmrg# NOTE: Changes made to this file will be lost: look at ltmain.sh. 6150145b7b3cSmrg# 6151578741aaSmrg# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 6152145b7b3cSmrg# Free Software Foundation, Inc. 6153145b7b3cSmrg# 6154145b7b3cSmrg# This file is part of GNU Libtool: 6155145b7b3cSmrg# Originally by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996 6156145b7b3cSmrg# 6157145b7b3cSmrg# This program is free software; you can redistribute it and/or modify 6158145b7b3cSmrg# it under the terms of the GNU General Public License as published by 6159145b7b3cSmrg# the Free Software Foundation; either version 2 of the License, or 6160145b7b3cSmrg# (at your option) any later version. 6161145b7b3cSmrg# 6162145b7b3cSmrg# This program is distributed in the hope that it will be useful, but 6163145b7b3cSmrg# WITHOUT ANY WARRANTY; without even the implied warranty of 6164145b7b3cSmrg# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 6165145b7b3cSmrg# General Public License for more details. 6166145b7b3cSmrg# 6167145b7b3cSmrg# You should have received a copy of the GNU General Public License 6168145b7b3cSmrg# along with this program; if not, write to the Free Software 6169145b7b3cSmrg# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 6170145b7b3cSmrg# 6171145b7b3cSmrg# As a special exception to the GNU General Public License, if you 6172145b7b3cSmrg# distribute this file as part of a program that contains a 6173145b7b3cSmrg# configuration script generated by Autoconf, you may include it under 6174145b7b3cSmrg# the same distribution terms that you use for the rest of that program. 6175145b7b3cSmrg 6176145b7b3cSmrg# A sed program that does not truncate output. 6177145b7b3cSmrgSED=$lt_SED 6178145b7b3cSmrg 6179145b7b3cSmrg# Sed that helps us avoid accidentally triggering echo(1) options like -n. 6180145b7b3cSmrgXsed="$SED -e 1s/^X//" 6181145b7b3cSmrg 6182145b7b3cSmrg# The HP-UX ksh and POSIX shell print the target directory to stdout 6183145b7b3cSmrg# if CDPATH is set. 6184145b7b3cSmrg(unset CDPATH) >/dev/null 2>&1 && unset CDPATH 6185145b7b3cSmrg 6186145b7b3cSmrg# The names of the tagged configurations supported by this script. 6187145b7b3cSmrgavailable_tags= 6188145b7b3cSmrg 6189145b7b3cSmrg# ### BEGIN LIBTOOL CONFIG], 6190145b7b3cSmrg[# ### BEGIN LIBTOOL TAG CONFIG: $tagname]) 6191145b7b3cSmrg 6192145b7b3cSmrg# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: 6193145b7b3cSmrg 6194145b7b3cSmrg# Shell to use when invoking shell scripts. 6195145b7b3cSmrgSHELL=$lt_SHELL 6196145b7b3cSmrg 6197145b7b3cSmrg# Whether or not to build shared libraries. 6198145b7b3cSmrgbuild_libtool_libs=$enable_shared 6199145b7b3cSmrg 6200145b7b3cSmrg# Whether or not to build static libraries. 6201145b7b3cSmrgbuild_old_libs=$enable_static 6202145b7b3cSmrg 6203145b7b3cSmrg# Whether or not to add -lc for building shared libraries. 6204145b7b3cSmrgbuild_libtool_need_lc=$_LT_AC_TAGVAR(archive_cmds_need_lc, $1) 6205145b7b3cSmrg 6206145b7b3cSmrg# Whether or not to disallow shared libs when runtime libs are static 6207145b7b3cSmrgallow_libtool_libs_with_static_runtimes=$_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1) 6208145b7b3cSmrg 6209145b7b3cSmrg# Whether or not to optimize for fast installation. 6210145b7b3cSmrgfast_install=$enable_fast_install 6211145b7b3cSmrg 6212145b7b3cSmrg# The host system. 6213145b7b3cSmrghost_alias=$host_alias 6214145b7b3cSmrghost=$host 6215145b7b3cSmrghost_os=$host_os 6216145b7b3cSmrg 6217145b7b3cSmrg# The build system. 6218145b7b3cSmrgbuild_alias=$build_alias 6219145b7b3cSmrgbuild=$build 6220145b7b3cSmrgbuild_os=$build_os 6221145b7b3cSmrg 6222145b7b3cSmrg# An echo program that does not interpret backslashes. 6223145b7b3cSmrgecho=$lt_echo 6224145b7b3cSmrg 6225145b7b3cSmrg# The archiver. 6226145b7b3cSmrgAR=$lt_AR 6227145b7b3cSmrgAR_FLAGS=$lt_AR_FLAGS 6228145b7b3cSmrg 6229145b7b3cSmrg# A C compiler. 6230145b7b3cSmrgLTCC=$lt_LTCC 6231145b7b3cSmrg 6232145b7b3cSmrg# LTCC compiler flags. 6233145b7b3cSmrgLTCFLAGS=$lt_LTCFLAGS 6234145b7b3cSmrg 6235145b7b3cSmrg# A language-specific compiler. 6236145b7b3cSmrgCC=$lt_[]_LT_AC_TAGVAR(compiler, $1) 6237145b7b3cSmrg 6238145b7b3cSmrg# Is the compiler the GNU C compiler? 6239145b7b3cSmrgwith_gcc=$_LT_AC_TAGVAR(GCC, $1) 6240145b7b3cSmrg 6241145b7b3cSmrg# An ERE matcher. 6242145b7b3cSmrgEGREP=$lt_EGREP 6243145b7b3cSmrg 6244145b7b3cSmrg# The linker used to build libraries. 6245145b7b3cSmrgLD=$lt_[]_LT_AC_TAGVAR(LD, $1) 6246145b7b3cSmrg 6247145b7b3cSmrg# Whether we need hard or soft links. 6248145b7b3cSmrgLN_S=$lt_LN_S 6249145b7b3cSmrg 6250145b7b3cSmrg# A BSD-compatible nm program. 6251145b7b3cSmrgNM=$lt_NM 6252145b7b3cSmrg 6253145b7b3cSmrg# A symbol stripping program 6254145b7b3cSmrgSTRIP=$lt_STRIP 6255145b7b3cSmrg 6256145b7b3cSmrg# Used to examine libraries when file_magic_cmd begins "file" 6257145b7b3cSmrgMAGIC_CMD=$MAGIC_CMD 6258145b7b3cSmrg 6259145b7b3cSmrg# Used on cygwin: DLL creation program. 6260145b7b3cSmrgDLLTOOL="$DLLTOOL" 6261145b7b3cSmrg 6262145b7b3cSmrg# Used on cygwin: object dumper. 6263145b7b3cSmrgOBJDUMP="$OBJDUMP" 6264145b7b3cSmrg 6265145b7b3cSmrg# Used on cygwin: assembler. 6266145b7b3cSmrgAS="$AS" 6267145b7b3cSmrg 6268145b7b3cSmrg# The name of the directory that contains temporary libtool files. 6269145b7b3cSmrgobjdir=$objdir 6270145b7b3cSmrg 6271145b7b3cSmrg# How to create reloadable object files. 6272145b7b3cSmrgreload_flag=$lt_reload_flag 6273145b7b3cSmrgreload_cmds=$lt_reload_cmds 6274145b7b3cSmrg 6275145b7b3cSmrg# How to pass a linker flag through the compiler. 6276145b7b3cSmrgwl=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_wl, $1) 6277145b7b3cSmrg 6278145b7b3cSmrg# Object file suffix (normally "o"). 6279145b7b3cSmrgobjext="$ac_objext" 6280145b7b3cSmrg 6281145b7b3cSmrg# Old archive suffix (normally "a"). 6282145b7b3cSmrglibext="$libext" 6283145b7b3cSmrg 6284145b7b3cSmrg# Shared library suffix (normally ".so"). 6285145b7b3cSmrgshrext_cmds='$shrext_cmds' 6286145b7b3cSmrg 6287145b7b3cSmrg# Executable file suffix (normally ""). 6288145b7b3cSmrgexeext="$exeext" 6289145b7b3cSmrg 6290145b7b3cSmrg# Additional compiler flags for building library objects. 6291145b7b3cSmrgpic_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) 6292145b7b3cSmrgpic_mode=$pic_mode 6293145b7b3cSmrg 6294145b7b3cSmrg# What is the maximum length of a command? 6295145b7b3cSmrgmax_cmd_len=$lt_cv_sys_max_cmd_len 6296145b7b3cSmrg 6297145b7b3cSmrg# Does compiler simultaneously support -c and -o options? 6298145b7b3cSmrgcompiler_c_o=$lt_[]_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1) 6299145b7b3cSmrg 6300145b7b3cSmrg# Must we lock files when doing compilation? 6301145b7b3cSmrgneed_locks=$lt_need_locks 6302145b7b3cSmrg 6303145b7b3cSmrg# Do we need the lib prefix for modules? 6304145b7b3cSmrgneed_lib_prefix=$need_lib_prefix 6305145b7b3cSmrg 6306145b7b3cSmrg# Do we need a version for libraries? 6307145b7b3cSmrgneed_version=$need_version 6308145b7b3cSmrg 6309145b7b3cSmrg# Whether dlopen is supported. 6310145b7b3cSmrgdlopen_support=$enable_dlopen 6311145b7b3cSmrg 6312145b7b3cSmrg# Whether dlopen of programs is supported. 6313145b7b3cSmrgdlopen_self=$enable_dlopen_self 6314145b7b3cSmrg 6315145b7b3cSmrg# Whether dlopen of statically linked programs is supported. 6316145b7b3cSmrgdlopen_self_static=$enable_dlopen_self_static 6317145b7b3cSmrg 6318145b7b3cSmrg# Compiler flag to prevent dynamic linking. 6319145b7b3cSmrglink_static_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_static, $1) 6320145b7b3cSmrg 6321145b7b3cSmrg# Compiler flag to turn off builtin functions. 6322145b7b3cSmrgno_builtin_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) 6323145b7b3cSmrg 6324145b7b3cSmrg# Compiler flag to allow reflexive dlopens. 6325145b7b3cSmrgexport_dynamic_flag_spec=$lt_[]_LT_AC_TAGVAR(export_dynamic_flag_spec, $1) 6326145b7b3cSmrg 6327145b7b3cSmrg# Compiler flag to generate shared objects directly from archives. 6328145b7b3cSmrgwhole_archive_flag_spec=$lt_[]_LT_AC_TAGVAR(whole_archive_flag_spec, $1) 6329145b7b3cSmrg 6330145b7b3cSmrg# Compiler flag to generate thread-safe objects. 6331145b7b3cSmrgthread_safe_flag_spec=$lt_[]_LT_AC_TAGVAR(thread_safe_flag_spec, $1) 6332145b7b3cSmrg 6333145b7b3cSmrg# Library versioning type. 6334145b7b3cSmrgversion_type=$version_type 6335145b7b3cSmrg 6336145b7b3cSmrg# Format of library name prefix. 6337145b7b3cSmrglibname_spec=$lt_libname_spec 6338145b7b3cSmrg 6339145b7b3cSmrg# List of archive names. First name is the real one, the rest are links. 6340145b7b3cSmrg# The last name is the one that the linker finds with -lNAME. 6341145b7b3cSmrglibrary_names_spec=$lt_library_names_spec 6342145b7b3cSmrg 6343145b7b3cSmrg# The coded name of the library, if different from the real name. 6344145b7b3cSmrgsoname_spec=$lt_soname_spec 6345145b7b3cSmrg 6346145b7b3cSmrg# Commands used to build and install an old-style archive. 6347145b7b3cSmrgRANLIB=$lt_RANLIB 6348145b7b3cSmrgold_archive_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_cmds, $1) 6349145b7b3cSmrgold_postinstall_cmds=$lt_old_postinstall_cmds 6350145b7b3cSmrgold_postuninstall_cmds=$lt_old_postuninstall_cmds 6351145b7b3cSmrg 6352145b7b3cSmrg# Create an old-style archive from a shared archive. 6353145b7b3cSmrgold_archive_from_new_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_from_new_cmds, $1) 6354145b7b3cSmrg 6355145b7b3cSmrg# Create a temporary old-style archive to link instead of a shared archive. 6356145b7b3cSmrgold_archive_from_expsyms_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) 6357145b7b3cSmrg 6358145b7b3cSmrg# Commands used to build and install a shared archive. 6359145b7b3cSmrgarchive_cmds=$lt_[]_LT_AC_TAGVAR(archive_cmds, $1) 6360145b7b3cSmrgarchive_expsym_cmds=$lt_[]_LT_AC_TAGVAR(archive_expsym_cmds, $1) 6361145b7b3cSmrgpostinstall_cmds=$lt_postinstall_cmds 6362145b7b3cSmrgpostuninstall_cmds=$lt_postuninstall_cmds 6363145b7b3cSmrg 6364145b7b3cSmrg# Commands used to build a loadable module (assumed same as above if empty) 6365145b7b3cSmrgmodule_cmds=$lt_[]_LT_AC_TAGVAR(module_cmds, $1) 6366145b7b3cSmrgmodule_expsym_cmds=$lt_[]_LT_AC_TAGVAR(module_expsym_cmds, $1) 6367145b7b3cSmrg 6368145b7b3cSmrg# Commands to strip libraries. 6369145b7b3cSmrgold_striplib=$lt_old_striplib 6370145b7b3cSmrgstriplib=$lt_striplib 6371145b7b3cSmrg 6372145b7b3cSmrg# Dependencies to place before the objects being linked to create a 6373145b7b3cSmrg# shared library. 6374145b7b3cSmrgpredep_objects=$lt_[]_LT_AC_TAGVAR(predep_objects, $1) 6375145b7b3cSmrg 6376145b7b3cSmrg# Dependencies to place after the objects being linked to create a 6377145b7b3cSmrg# shared library. 6378145b7b3cSmrgpostdep_objects=$lt_[]_LT_AC_TAGVAR(postdep_objects, $1) 6379145b7b3cSmrg 6380145b7b3cSmrg# Dependencies to place before the objects being linked to create a 6381145b7b3cSmrg# shared library. 6382145b7b3cSmrgpredeps=$lt_[]_LT_AC_TAGVAR(predeps, $1) 6383145b7b3cSmrg 6384145b7b3cSmrg# Dependencies to place after the objects being linked to create a 6385145b7b3cSmrg# shared library. 6386145b7b3cSmrgpostdeps=$lt_[]_LT_AC_TAGVAR(postdeps, $1) 6387145b7b3cSmrg 6388578741aaSmrg# The directories searched by this compiler when creating a shared 6389578741aaSmrg# library 6390578741aaSmrgcompiler_lib_search_dirs=$lt_[]_LT_AC_TAGVAR(compiler_lib_search_dirs, $1) 6391578741aaSmrg 6392145b7b3cSmrg# The library search path used internally by the compiler when linking 6393145b7b3cSmrg# a shared library. 6394145b7b3cSmrgcompiler_lib_search_path=$lt_[]_LT_AC_TAGVAR(compiler_lib_search_path, $1) 6395145b7b3cSmrg 6396145b7b3cSmrg# Method to check whether dependent libraries are shared objects. 6397145b7b3cSmrgdeplibs_check_method=$lt_deplibs_check_method 6398145b7b3cSmrg 6399145b7b3cSmrg# Command to use when deplibs_check_method == file_magic. 6400145b7b3cSmrgfile_magic_cmd=$lt_file_magic_cmd 6401145b7b3cSmrg 6402145b7b3cSmrg# Flag that allows shared libraries with undefined symbols to be built. 6403145b7b3cSmrgallow_undefined_flag=$lt_[]_LT_AC_TAGVAR(allow_undefined_flag, $1) 6404145b7b3cSmrg 6405145b7b3cSmrg# Flag that forces no undefined symbols. 6406145b7b3cSmrgno_undefined_flag=$lt_[]_LT_AC_TAGVAR(no_undefined_flag, $1) 6407145b7b3cSmrg 6408145b7b3cSmrg# Commands used to finish a libtool library installation in a directory. 6409145b7b3cSmrgfinish_cmds=$lt_finish_cmds 6410145b7b3cSmrg 6411145b7b3cSmrg# Same as above, but a single script fragment to be evaled but not shown. 6412145b7b3cSmrgfinish_eval=$lt_finish_eval 6413145b7b3cSmrg 6414145b7b3cSmrg# Take the output of nm and produce a listing of raw symbols and C names. 6415145b7b3cSmrgglobal_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe 6416145b7b3cSmrg 6417145b7b3cSmrg# Transform the output of nm in a proper C declaration 6418145b7b3cSmrgglobal_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl 6419145b7b3cSmrg 6420145b7b3cSmrg# Transform the output of nm in a C name address pair 6421145b7b3cSmrgglobal_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address 6422145b7b3cSmrg 6423145b7b3cSmrg# This is the shared library runtime path variable. 6424145b7b3cSmrgrunpath_var=$runpath_var 6425145b7b3cSmrg 6426145b7b3cSmrg# This is the shared library path variable. 6427145b7b3cSmrgshlibpath_var=$shlibpath_var 6428145b7b3cSmrg 6429145b7b3cSmrg# Is shlibpath searched before the hard-coded library search path? 6430145b7b3cSmrgshlibpath_overrides_runpath=$shlibpath_overrides_runpath 6431145b7b3cSmrg 6432145b7b3cSmrg# How to hardcode a shared library path into an executable. 6433145b7b3cSmrghardcode_action=$_LT_AC_TAGVAR(hardcode_action, $1) 6434145b7b3cSmrg 6435145b7b3cSmrg# Whether we should hardcode library paths into libraries. 6436145b7b3cSmrghardcode_into_libs=$hardcode_into_libs 6437145b7b3cSmrg 6438145b7b3cSmrg# Flag to hardcode \$libdir into a binary during linking. 6439145b7b3cSmrg# This must work even if \$libdir does not exist. 6440145b7b3cSmrghardcode_libdir_flag_spec=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) 6441145b7b3cSmrg 6442145b7b3cSmrg# If ld is used when linking, flag to hardcode \$libdir into 6443145b7b3cSmrg# a binary during linking. This must work even if \$libdir does 6444145b7b3cSmrg# not exist. 6445145b7b3cSmrghardcode_libdir_flag_spec_ld=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1) 6446145b7b3cSmrg 6447145b7b3cSmrg# Whether we need a single -rpath flag with a separated argument. 6448145b7b3cSmrghardcode_libdir_separator=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_separator, $1) 6449145b7b3cSmrg 6450145b7b3cSmrg# Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the 6451145b7b3cSmrg# resulting binary. 6452145b7b3cSmrghardcode_direct=$_LT_AC_TAGVAR(hardcode_direct, $1) 6453145b7b3cSmrg 6454145b7b3cSmrg# Set to yes if using the -LDIR flag during linking hardcodes DIR into the 6455145b7b3cSmrg# resulting binary. 6456145b7b3cSmrghardcode_minus_L=$_LT_AC_TAGVAR(hardcode_minus_L, $1) 6457145b7b3cSmrg 6458145b7b3cSmrg# Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into 6459145b7b3cSmrg# the resulting binary. 6460145b7b3cSmrghardcode_shlibpath_var=$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1) 6461145b7b3cSmrg 6462145b7b3cSmrg# Set to yes if building a shared library automatically hardcodes DIR into the library 6463145b7b3cSmrg# and all subsequent libraries and executables linked against it. 6464145b7b3cSmrghardcode_automatic=$_LT_AC_TAGVAR(hardcode_automatic, $1) 6465145b7b3cSmrg 6466145b7b3cSmrg# Variables whose values should be saved in libtool wrapper scripts and 6467145b7b3cSmrg# restored at relink time. 6468145b7b3cSmrgvariables_saved_for_relink="$variables_saved_for_relink" 6469145b7b3cSmrg 6470145b7b3cSmrg# Whether libtool must link a program against all its dependency libraries. 6471145b7b3cSmrglink_all_deplibs=$_LT_AC_TAGVAR(link_all_deplibs, $1) 6472145b7b3cSmrg 6473145b7b3cSmrg# Compile-time system search path for libraries 6474145b7b3cSmrgsys_lib_search_path_spec=$lt_sys_lib_search_path_spec 6475145b7b3cSmrg 6476145b7b3cSmrg# Run-time system search path for libraries 6477145b7b3cSmrgsys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec 6478145b7b3cSmrg 6479145b7b3cSmrg# Fix the shell variable \$srcfile for the compiler. 6480578741aaSmrgfix_srcfile_path=$lt_fix_srcfile_path 6481145b7b3cSmrg 6482145b7b3cSmrg# Set to yes if exported symbols are required. 6483145b7b3cSmrgalways_export_symbols=$_LT_AC_TAGVAR(always_export_symbols, $1) 6484145b7b3cSmrg 6485145b7b3cSmrg# The commands to list exported symbols. 6486145b7b3cSmrgexport_symbols_cmds=$lt_[]_LT_AC_TAGVAR(export_symbols_cmds, $1) 6487145b7b3cSmrg 6488145b7b3cSmrg# The commands to extract the exported symbol list from a shared archive. 6489145b7b3cSmrgextract_expsyms_cmds=$lt_extract_expsyms_cmds 6490145b7b3cSmrg 6491145b7b3cSmrg# Symbols that should not be listed in the preloaded symbols. 6492145b7b3cSmrgexclude_expsyms=$lt_[]_LT_AC_TAGVAR(exclude_expsyms, $1) 6493145b7b3cSmrg 6494145b7b3cSmrg# Symbols that must always be exported. 6495145b7b3cSmrginclude_expsyms=$lt_[]_LT_AC_TAGVAR(include_expsyms, $1) 6496145b7b3cSmrg 6497145b7b3cSmrgifelse([$1],[], 6498145b7b3cSmrg[# ### END LIBTOOL CONFIG], 6499145b7b3cSmrg[# ### END LIBTOOL TAG CONFIG: $tagname]) 6500145b7b3cSmrg 6501145b7b3cSmrg__EOF__ 6502145b7b3cSmrg 6503145b7b3cSmrgifelse([$1],[], [ 6504145b7b3cSmrg case $host_os in 6505145b7b3cSmrg aix3*) 6506145b7b3cSmrg cat <<\EOF >> "$cfgfile" 6507145b7b3cSmrg 6508145b7b3cSmrg# AIX sometimes has problems with the GCC collect2 program. For some 6509145b7b3cSmrg# reason, if we set the COLLECT_NAMES environment variable, the problems 6510145b7b3cSmrg# vanish in a puff of smoke. 6511145b7b3cSmrgif test "X${COLLECT_NAMES+set}" != Xset; then 6512145b7b3cSmrg COLLECT_NAMES= 6513145b7b3cSmrg export COLLECT_NAMES 6514145b7b3cSmrgfi 6515145b7b3cSmrgEOF 6516145b7b3cSmrg ;; 6517145b7b3cSmrg esac 6518145b7b3cSmrg 6519145b7b3cSmrg # We use sed instead of cat because bash on DJGPP gets confused if 6520145b7b3cSmrg # if finds mixed CR/LF and LF-only lines. Since sed operates in 6521145b7b3cSmrg # text mode, it properly converts lines to CR/LF. This bash problem 6522145b7b3cSmrg # is reportedly fixed, but why not run on old versions too? 6523145b7b3cSmrg sed '$q' "$ltmain" >> "$cfgfile" || (rm -f "$cfgfile"; exit 1) 6524145b7b3cSmrg 6525145b7b3cSmrg mv -f "$cfgfile" "$ofile" || \ 6526145b7b3cSmrg (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") 6527145b7b3cSmrg chmod +x "$ofile" 6528145b7b3cSmrg]) 6529145b7b3cSmrgelse 6530145b7b3cSmrg # If there is no Makefile yet, we rely on a make rule to execute 6531145b7b3cSmrg # `config.status --recheck' to rerun these tests and create the 6532145b7b3cSmrg # libtool script then. 6533145b7b3cSmrg ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'` 6534145b7b3cSmrg if test -f "$ltmain_in"; then 6535145b7b3cSmrg test -f Makefile && make "$ltmain" 6536145b7b3cSmrg fi 6537145b7b3cSmrgfi 6538145b7b3cSmrg])# AC_LIBTOOL_CONFIG 6539145b7b3cSmrg 6540145b7b3cSmrg 6541145b7b3cSmrg# AC_LIBTOOL_PROG_COMPILER_NO_RTTI([TAGNAME]) 6542145b7b3cSmrg# ------------------------------------------- 6543145b7b3cSmrgAC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], 6544145b7b3cSmrg[AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl 6545145b7b3cSmrg 6546145b7b3cSmrg_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= 6547145b7b3cSmrg 6548145b7b3cSmrgif test "$GCC" = yes; then 6549145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' 6550145b7b3cSmrg 6551145b7b3cSmrg AC_LIBTOOL_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions], 6552145b7b3cSmrg lt_cv_prog_compiler_rtti_exceptions, 6553145b7b3cSmrg [-fno-rtti -fno-exceptions], [], 6554145b7b3cSmrg [_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"]) 6555145b7b3cSmrgfi 6556145b7b3cSmrg])# AC_LIBTOOL_PROG_COMPILER_NO_RTTI 6557145b7b3cSmrg 6558145b7b3cSmrg 6559145b7b3cSmrg# AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE 6560145b7b3cSmrg# --------------------------------- 6561145b7b3cSmrgAC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], 6562145b7b3cSmrg[AC_REQUIRE([AC_CANONICAL_HOST]) 6563578741aaSmrgAC_REQUIRE([LT_AC_PROG_SED]) 6564145b7b3cSmrgAC_REQUIRE([AC_PROG_NM]) 6565145b7b3cSmrgAC_REQUIRE([AC_OBJEXT]) 6566145b7b3cSmrg# Check for command to grab the raw symbol name followed by C symbol from nm. 6567145b7b3cSmrgAC_MSG_CHECKING([command to parse $NM output from $compiler object]) 6568145b7b3cSmrgAC_CACHE_VAL([lt_cv_sys_global_symbol_pipe], 6569145b7b3cSmrg[ 6570145b7b3cSmrg# These are sane defaults that work on at least a few old systems. 6571145b7b3cSmrg# [They come from Ultrix. What could be older than Ultrix?!! ;)] 6572145b7b3cSmrg 6573145b7b3cSmrg# Character class describing NM global symbol codes. 6574145b7b3cSmrgsymcode='[[BCDEGRST]]' 6575145b7b3cSmrg 6576145b7b3cSmrg# Regexp to match symbols that can be accessed directly from C. 6577145b7b3cSmrgsympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)' 6578145b7b3cSmrg 6579145b7b3cSmrg# Transform an extracted symbol line into a proper C declaration 6580145b7b3cSmrglt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern int \1;/p'" 6581145b7b3cSmrg 6582145b7b3cSmrg# Transform an extracted symbol line into symbol name and symbol address 6583145b7b3cSmrglt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" 6584145b7b3cSmrg 6585145b7b3cSmrg# Define system-specific variables. 6586145b7b3cSmrgcase $host_os in 6587145b7b3cSmrgaix*) 6588145b7b3cSmrg symcode='[[BCDT]]' 6589145b7b3cSmrg ;; 6590145b7b3cSmrgcygwin* | mingw* | pw32*) 6591145b7b3cSmrg symcode='[[ABCDGISTW]]' 6592145b7b3cSmrg ;; 6593145b7b3cSmrghpux*) # Its linker distinguishes data from code symbols 6594145b7b3cSmrg if test "$host_cpu" = ia64; then 6595145b7b3cSmrg symcode='[[ABCDEGRST]]' 6596145b7b3cSmrg fi 6597145b7b3cSmrg lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" 6598145b7b3cSmrg lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" 6599145b7b3cSmrg ;; 6600578741aaSmrglinux* | k*bsd*-gnu) 6601145b7b3cSmrg if test "$host_cpu" = ia64; then 6602145b7b3cSmrg symcode='[[ABCDGIRSTW]]' 6603145b7b3cSmrg lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" 6604145b7b3cSmrg lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" 6605145b7b3cSmrg fi 6606145b7b3cSmrg ;; 6607145b7b3cSmrgirix* | nonstopux*) 6608145b7b3cSmrg symcode='[[BCDEGRST]]' 6609145b7b3cSmrg ;; 6610145b7b3cSmrgosf*) 6611145b7b3cSmrg symcode='[[BCDEGQRST]]' 6612145b7b3cSmrg ;; 6613145b7b3cSmrgsolaris*) 6614145b7b3cSmrg symcode='[[BDRT]]' 6615145b7b3cSmrg ;; 6616145b7b3cSmrgsco3.2v5*) 6617145b7b3cSmrg symcode='[[DT]]' 6618145b7b3cSmrg ;; 6619145b7b3cSmrgsysv4.2uw2*) 6620145b7b3cSmrg symcode='[[DT]]' 6621145b7b3cSmrg ;; 6622145b7b3cSmrgsysv5* | sco5v6* | unixware* | OpenUNIX*) 6623145b7b3cSmrg symcode='[[ABDT]]' 6624145b7b3cSmrg ;; 6625145b7b3cSmrgsysv4) 6626145b7b3cSmrg symcode='[[DFNSTU]]' 6627145b7b3cSmrg ;; 6628145b7b3cSmrgesac 6629145b7b3cSmrg 6630145b7b3cSmrg# Handle CRLF in mingw tool chain 6631145b7b3cSmrgopt_cr= 6632145b7b3cSmrgcase $build_os in 6633145b7b3cSmrgmingw*) 6634145b7b3cSmrg opt_cr=`echo 'x\{0,1\}' | tr x '\015'` # option cr in regexp 6635145b7b3cSmrg ;; 6636145b7b3cSmrgesac 6637145b7b3cSmrg 6638145b7b3cSmrg# If we're using GNU nm, then use its standard symbol codes. 6639145b7b3cSmrgcase `$NM -V 2>&1` in 6640145b7b3cSmrg*GNU* | *'with BFD'*) 6641145b7b3cSmrg symcode='[[ABCDGIRSTW]]' ;; 6642145b7b3cSmrgesac 6643145b7b3cSmrg 6644145b7b3cSmrg# Try without a prefix undercore, then with it. 6645145b7b3cSmrgfor ac_symprfx in "" "_"; do 6646145b7b3cSmrg 6647145b7b3cSmrg # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. 6648145b7b3cSmrg symxfrm="\\1 $ac_symprfx\\2 \\2" 6649145b7b3cSmrg 6650145b7b3cSmrg # Write the raw and C identifiers. 6651145b7b3cSmrg lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" 6652145b7b3cSmrg 6653145b7b3cSmrg # Check to see that the pipe works correctly. 6654145b7b3cSmrg pipe_works=no 6655145b7b3cSmrg 6656145b7b3cSmrg rm -f conftest* 6657145b7b3cSmrg cat > conftest.$ac_ext <<EOF 6658145b7b3cSmrg#ifdef __cplusplus 6659145b7b3cSmrgextern "C" { 6660145b7b3cSmrg#endif 6661145b7b3cSmrgchar nm_test_var; 6662145b7b3cSmrgvoid nm_test_func(){} 6663145b7b3cSmrg#ifdef __cplusplus 6664145b7b3cSmrg} 6665145b7b3cSmrg#endif 6666145b7b3cSmrgint main(){nm_test_var='a';nm_test_func();return(0);} 6667145b7b3cSmrgEOF 6668145b7b3cSmrg 6669145b7b3cSmrg if AC_TRY_EVAL(ac_compile); then 6670145b7b3cSmrg # Now try to grab the symbols. 6671145b7b3cSmrg nlist=conftest.nm 6672145b7b3cSmrg if AC_TRY_EVAL(NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) && test -s "$nlist"; then 6673145b7b3cSmrg # Try sorting and uniquifying the output. 6674145b7b3cSmrg if sort "$nlist" | uniq > "$nlist"T; then 6675145b7b3cSmrg mv -f "$nlist"T "$nlist" 6676145b7b3cSmrg else 6677145b7b3cSmrg rm -f "$nlist"T 6678145b7b3cSmrg fi 6679145b7b3cSmrg 6680145b7b3cSmrg # Make sure that we snagged all the symbols we need. 6681145b7b3cSmrg if grep ' nm_test_var$' "$nlist" >/dev/null; then 6682145b7b3cSmrg if grep ' nm_test_func$' "$nlist" >/dev/null; then 6683145b7b3cSmrg cat <<EOF > conftest.$ac_ext 6684145b7b3cSmrg#ifdef __cplusplus 6685145b7b3cSmrgextern "C" { 6686145b7b3cSmrg#endif 6687145b7b3cSmrg 6688145b7b3cSmrgEOF 6689145b7b3cSmrg # Now generate the symbol file. 6690145b7b3cSmrg eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | grep -v main >> conftest.$ac_ext' 6691145b7b3cSmrg 6692145b7b3cSmrg cat <<EOF >> conftest.$ac_ext 6693145b7b3cSmrg#if defined (__STDC__) && __STDC__ 6694145b7b3cSmrg# define lt_ptr_t void * 6695145b7b3cSmrg#else 6696145b7b3cSmrg# define lt_ptr_t char * 6697145b7b3cSmrg# define const 6698145b7b3cSmrg#endif 6699145b7b3cSmrg 6700145b7b3cSmrg/* The mapping between symbol names and symbols. */ 6701145b7b3cSmrgconst struct { 6702145b7b3cSmrg const char *name; 6703145b7b3cSmrg lt_ptr_t address; 6704145b7b3cSmrg} 6705145b7b3cSmrglt_preloaded_symbols[[]] = 6706145b7b3cSmrg{ 6707145b7b3cSmrgEOF 6708145b7b3cSmrg $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (lt_ptr_t) \&\2},/" < "$nlist" | grep -v main >> conftest.$ac_ext 6709145b7b3cSmrg cat <<\EOF >> conftest.$ac_ext 6710145b7b3cSmrg {0, (lt_ptr_t) 0} 6711145b7b3cSmrg}; 6712145b7b3cSmrg 6713145b7b3cSmrg#ifdef __cplusplus 6714145b7b3cSmrg} 6715145b7b3cSmrg#endif 6716145b7b3cSmrgEOF 6717145b7b3cSmrg # Now try linking the two files. 6718145b7b3cSmrg mv conftest.$ac_objext conftstm.$ac_objext 6719145b7b3cSmrg lt_save_LIBS="$LIBS" 6720145b7b3cSmrg lt_save_CFLAGS="$CFLAGS" 6721145b7b3cSmrg LIBS="conftstm.$ac_objext" 6722145b7b3cSmrg CFLAGS="$CFLAGS$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)" 6723145b7b3cSmrg if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then 6724145b7b3cSmrg pipe_works=yes 6725145b7b3cSmrg fi 6726145b7b3cSmrg LIBS="$lt_save_LIBS" 6727145b7b3cSmrg CFLAGS="$lt_save_CFLAGS" 6728145b7b3cSmrg else 6729145b7b3cSmrg echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD 6730145b7b3cSmrg fi 6731145b7b3cSmrg else 6732145b7b3cSmrg echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD 6733145b7b3cSmrg fi 6734145b7b3cSmrg else 6735145b7b3cSmrg echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD 6736145b7b3cSmrg fi 6737145b7b3cSmrg else 6738145b7b3cSmrg echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD 6739145b7b3cSmrg cat conftest.$ac_ext >&5 6740145b7b3cSmrg fi 6741578741aaSmrg rm -rf conftest* conftst* 6742145b7b3cSmrg 6743145b7b3cSmrg # Do not use the global_symbol_pipe unless it works. 6744145b7b3cSmrg if test "$pipe_works" = yes; then 6745145b7b3cSmrg break 6746145b7b3cSmrg else 6747145b7b3cSmrg lt_cv_sys_global_symbol_pipe= 6748145b7b3cSmrg fi 6749145b7b3cSmrgdone 6750145b7b3cSmrg]) 6751145b7b3cSmrgif test -z "$lt_cv_sys_global_symbol_pipe"; then 6752145b7b3cSmrg lt_cv_sys_global_symbol_to_cdecl= 6753145b7b3cSmrgfi 6754145b7b3cSmrgif test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then 6755145b7b3cSmrg AC_MSG_RESULT(failed) 6756145b7b3cSmrgelse 6757145b7b3cSmrg AC_MSG_RESULT(ok) 6758145b7b3cSmrgfi 6759145b7b3cSmrg]) # AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE 6760145b7b3cSmrg 6761145b7b3cSmrg 6762145b7b3cSmrg# AC_LIBTOOL_PROG_COMPILER_PIC([TAGNAME]) 6763145b7b3cSmrg# --------------------------------------- 6764145b7b3cSmrgAC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC], 6765145b7b3cSmrg[_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)= 6766145b7b3cSmrg_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= 6767145b7b3cSmrg_LT_AC_TAGVAR(lt_prog_compiler_static, $1)= 6768145b7b3cSmrg 6769145b7b3cSmrgAC_MSG_CHECKING([for $compiler option to produce PIC]) 6770145b7b3cSmrg ifelse([$1],[CXX],[ 6771145b7b3cSmrg # C++ specific cases for pic, static, wl, etc. 6772145b7b3cSmrg if test "$GXX" = yes; then 6773145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6774145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static' 6775145b7b3cSmrg 6776145b7b3cSmrg case $host_os in 6777145b7b3cSmrg aix*) 6778145b7b3cSmrg # All AIX code is PIC. 6779145b7b3cSmrg if test "$host_cpu" = ia64; then 6780145b7b3cSmrg # AIX 5 now supports IA64 processor 6781145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6782145b7b3cSmrg fi 6783145b7b3cSmrg ;; 6784145b7b3cSmrg amigaos*) 6785145b7b3cSmrg # FIXME: we need at least 68020 code to build shared libraries, but 6786145b7b3cSmrg # adding the `-m68020' flag to GCC prevents building anything better, 6787145b7b3cSmrg # like `-m68040'. 6788145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' 6789145b7b3cSmrg ;; 6790578741aaSmrg beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) 6791145b7b3cSmrg # PIC is the default for these OSes. 6792145b7b3cSmrg ;; 6793578741aaSmrg mingw* | cygwin* | os2* | pw32*) 6794145b7b3cSmrg # This hack is so that the source file can tell whether it is being 6795145b7b3cSmrg # built for inclusion in a dll (and should export symbols for example). 6796578741aaSmrg # Although the cygwin gcc ignores -fPIC, still need this for old-style 6797578741aaSmrg # (--disable-auto-import) libraries 6798578741aaSmrg m4_if([$1], [GCJ], [], 6799578741aaSmrg [_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) 6800145b7b3cSmrg ;; 6801145b7b3cSmrg darwin* | rhapsody*) 6802145b7b3cSmrg # PIC is the default on this platform 6803145b7b3cSmrg # Common symbols not allowed in MH_DYLIB files 6804145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' 6805145b7b3cSmrg ;; 6806145b7b3cSmrg *djgpp*) 6807145b7b3cSmrg # DJGPP does not support shared libraries at all 6808145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= 6809145b7b3cSmrg ;; 6810578741aaSmrg interix[[3-9]]*) 6811145b7b3cSmrg # Interix 3.x gcc -fpic/-fPIC options generate broken code. 6812145b7b3cSmrg # Instead, we relocate shared libraries at runtime. 6813145b7b3cSmrg ;; 6814145b7b3cSmrg sysv4*MP*) 6815145b7b3cSmrg if test -d /usr/nec; then 6816145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic 6817145b7b3cSmrg fi 6818145b7b3cSmrg ;; 6819145b7b3cSmrg hpux*) 6820145b7b3cSmrg # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but 6821145b7b3cSmrg # not for PA HP-UX. 6822145b7b3cSmrg case $host_cpu in 6823145b7b3cSmrg hppa*64*|ia64*) 6824145b7b3cSmrg ;; 6825145b7b3cSmrg *) 6826145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 6827145b7b3cSmrg ;; 6828145b7b3cSmrg esac 6829145b7b3cSmrg ;; 6830145b7b3cSmrg *) 6831145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 6832145b7b3cSmrg ;; 6833145b7b3cSmrg esac 6834145b7b3cSmrg else 6835145b7b3cSmrg case $host_os in 6836578741aaSmrg aix[[4-9]]*) 6837145b7b3cSmrg # All AIX code is PIC. 6838145b7b3cSmrg if test "$host_cpu" = ia64; then 6839145b7b3cSmrg # AIX 5 now supports IA64 processor 6840145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6841145b7b3cSmrg else 6842145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' 6843145b7b3cSmrg fi 6844145b7b3cSmrg ;; 6845145b7b3cSmrg chorus*) 6846145b7b3cSmrg case $cc_basename in 6847145b7b3cSmrg cxch68*) 6848145b7b3cSmrg # Green Hills C++ Compiler 6849145b7b3cSmrg # _LT_AC_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" 6850145b7b3cSmrg ;; 6851145b7b3cSmrg esac 6852145b7b3cSmrg ;; 6853145b7b3cSmrg darwin*) 6854145b7b3cSmrg # PIC is the default on this platform 6855145b7b3cSmrg # Common symbols not allowed in MH_DYLIB files 6856145b7b3cSmrg case $cc_basename in 6857145b7b3cSmrg xlc*) 6858145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-qnocommon' 6859145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6860145b7b3cSmrg ;; 6861145b7b3cSmrg esac 6862145b7b3cSmrg ;; 6863145b7b3cSmrg dgux*) 6864145b7b3cSmrg case $cc_basename in 6865145b7b3cSmrg ec++*) 6866145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6867145b7b3cSmrg ;; 6868145b7b3cSmrg ghcx*) 6869145b7b3cSmrg # Green Hills C++ Compiler 6870145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 6871145b7b3cSmrg ;; 6872145b7b3cSmrg *) 6873145b7b3cSmrg ;; 6874145b7b3cSmrg esac 6875145b7b3cSmrg ;; 6876578741aaSmrg freebsd* | dragonfly*) 6877145b7b3cSmrg # FreeBSD uses GNU C++ 6878145b7b3cSmrg ;; 6879145b7b3cSmrg hpux9* | hpux10* | hpux11*) 6880145b7b3cSmrg case $cc_basename in 6881145b7b3cSmrg CC*) 6882145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6883145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' 6884145b7b3cSmrg if test "$host_cpu" != ia64; then 6885145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z' 6886145b7b3cSmrg fi 6887145b7b3cSmrg ;; 6888145b7b3cSmrg aCC*) 6889145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6890145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' 6891145b7b3cSmrg case $host_cpu in 6892145b7b3cSmrg hppa*64*|ia64*) 6893145b7b3cSmrg # +Z the default 6894145b7b3cSmrg ;; 6895145b7b3cSmrg *) 6896145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z' 6897145b7b3cSmrg ;; 6898145b7b3cSmrg esac 6899145b7b3cSmrg ;; 6900145b7b3cSmrg *) 6901145b7b3cSmrg ;; 6902145b7b3cSmrg esac 6903145b7b3cSmrg ;; 6904145b7b3cSmrg interix*) 6905145b7b3cSmrg # This is c89, which is MS Visual C++ (no shared libs) 6906145b7b3cSmrg # Anyone wants to do a port? 6907145b7b3cSmrg ;; 6908145b7b3cSmrg irix5* | irix6* | nonstopux*) 6909145b7b3cSmrg case $cc_basename in 6910145b7b3cSmrg CC*) 6911145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6912145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 6913145b7b3cSmrg # CC pic flag -KPIC is the default. 6914145b7b3cSmrg ;; 6915145b7b3cSmrg *) 6916145b7b3cSmrg ;; 6917145b7b3cSmrg esac 6918145b7b3cSmrg ;; 6919578741aaSmrg linux* | k*bsd*-gnu) 6920145b7b3cSmrg case $cc_basename in 6921145b7b3cSmrg KCC*) 6922145b7b3cSmrg # KAI C++ Compiler 6923145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' 6924145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 6925145b7b3cSmrg ;; 6926145b7b3cSmrg icpc* | ecpc*) 6927145b7b3cSmrg # Intel C++ 6928145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6929145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6930145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static' 6931145b7b3cSmrg ;; 6932578741aaSmrg pgCC* | pgcpp*) 6933145b7b3cSmrg # Portland Group C++ compiler. 6934145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6935145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' 6936145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6937145b7b3cSmrg ;; 6938145b7b3cSmrg cxx*) 6939145b7b3cSmrg # Compaq C++ 6940145b7b3cSmrg # Make sure the PIC flag is empty. It appears that all Alpha 6941145b7b3cSmrg # Linux and Compaq Tru64 Unix objects are PIC. 6942145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= 6943145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 6944145b7b3cSmrg ;; 6945145b7b3cSmrg *) 6946578741aaSmrg case `$CC -V 2>&1 | sed 5q` in 6947578741aaSmrg *Sun\ C*) 6948578741aaSmrg # Sun C++ 5.9 6949578741aaSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 6950578741aaSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 6951578741aaSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' 6952578741aaSmrg ;; 6953578741aaSmrg esac 6954145b7b3cSmrg ;; 6955145b7b3cSmrg esac 6956145b7b3cSmrg ;; 6957145b7b3cSmrg lynxos*) 6958145b7b3cSmrg ;; 6959145b7b3cSmrg m88k*) 6960145b7b3cSmrg ;; 6961145b7b3cSmrg mvs*) 6962145b7b3cSmrg case $cc_basename in 6963145b7b3cSmrg cxx*) 6964145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall' 6965145b7b3cSmrg ;; 6966145b7b3cSmrg *) 6967145b7b3cSmrg ;; 6968145b7b3cSmrg esac 6969145b7b3cSmrg ;; 6970145b7b3cSmrg netbsd*) 6971145b7b3cSmrg ;; 6972145b7b3cSmrg osf3* | osf4* | osf5*) 6973145b7b3cSmrg case $cc_basename in 6974145b7b3cSmrg KCC*) 6975145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' 6976145b7b3cSmrg ;; 6977145b7b3cSmrg RCC*) 6978145b7b3cSmrg # Rational C++ 2.4.1 6979145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 6980145b7b3cSmrg ;; 6981145b7b3cSmrg cxx*) 6982145b7b3cSmrg # Digital/Compaq C++ 6983145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 6984145b7b3cSmrg # Make sure the PIC flag is empty. It appears that all Alpha 6985145b7b3cSmrg # Linux and Compaq Tru64 Unix objects are PIC. 6986145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= 6987145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 6988145b7b3cSmrg ;; 6989145b7b3cSmrg *) 6990145b7b3cSmrg ;; 6991145b7b3cSmrg esac 6992145b7b3cSmrg ;; 6993145b7b3cSmrg psos*) 6994145b7b3cSmrg ;; 6995145b7b3cSmrg solaris*) 6996145b7b3cSmrg case $cc_basename in 6997145b7b3cSmrg CC*) 6998145b7b3cSmrg # Sun C++ 4.2, 5.x and Centerline C++ 6999145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 7000145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 7001145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' 7002145b7b3cSmrg ;; 7003145b7b3cSmrg gcx*) 7004145b7b3cSmrg # Green Hills C++ Compiler 7005145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' 7006145b7b3cSmrg ;; 7007145b7b3cSmrg *) 7008145b7b3cSmrg ;; 7009145b7b3cSmrg esac 7010145b7b3cSmrg ;; 7011145b7b3cSmrg sunos4*) 7012145b7b3cSmrg case $cc_basename in 7013145b7b3cSmrg CC*) 7014145b7b3cSmrg # Sun C++ 4.x 7015145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 7016145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 7017145b7b3cSmrg ;; 7018145b7b3cSmrg lcc*) 7019145b7b3cSmrg # Lucid 7020145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 7021145b7b3cSmrg ;; 7022145b7b3cSmrg *) 7023145b7b3cSmrg ;; 7024145b7b3cSmrg esac 7025145b7b3cSmrg ;; 7026145b7b3cSmrg tandem*) 7027145b7b3cSmrg case $cc_basename in 7028145b7b3cSmrg NCC*) 7029145b7b3cSmrg # NonStop-UX NCC 3.20 7030145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 7031145b7b3cSmrg ;; 7032145b7b3cSmrg *) 7033145b7b3cSmrg ;; 7034145b7b3cSmrg esac 7035145b7b3cSmrg ;; 7036145b7b3cSmrg sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) 7037145b7b3cSmrg case $cc_basename in 7038145b7b3cSmrg CC*) 7039145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 7040145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 7041145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 7042145b7b3cSmrg ;; 7043145b7b3cSmrg esac 7044145b7b3cSmrg ;; 7045145b7b3cSmrg vxworks*) 7046145b7b3cSmrg ;; 7047145b7b3cSmrg *) 7048145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 7049145b7b3cSmrg ;; 7050145b7b3cSmrg esac 7051145b7b3cSmrg fi 7052145b7b3cSmrg], 7053145b7b3cSmrg[ 7054145b7b3cSmrg if test "$GCC" = yes; then 7055145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 7056145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static' 7057145b7b3cSmrg 7058145b7b3cSmrg case $host_os in 7059145b7b3cSmrg aix*) 7060145b7b3cSmrg # All AIX code is PIC. 7061145b7b3cSmrg if test "$host_cpu" = ia64; then 7062145b7b3cSmrg # AIX 5 now supports IA64 processor 7063145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 7064145b7b3cSmrg fi 7065145b7b3cSmrg ;; 7066145b7b3cSmrg 7067145b7b3cSmrg amigaos*) 7068145b7b3cSmrg # FIXME: we need at least 68020 code to build shared libraries, but 7069145b7b3cSmrg # adding the `-m68020' flag to GCC prevents building anything better, 7070145b7b3cSmrg # like `-m68040'. 7071145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' 7072145b7b3cSmrg ;; 7073145b7b3cSmrg 7074578741aaSmrg beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) 7075145b7b3cSmrg # PIC is the default for these OSes. 7076145b7b3cSmrg ;; 7077145b7b3cSmrg 7078578741aaSmrg mingw* | cygwin* | pw32* | os2*) 7079145b7b3cSmrg # This hack is so that the source file can tell whether it is being 7080145b7b3cSmrg # built for inclusion in a dll (and should export symbols for example). 7081578741aaSmrg # Although the cygwin gcc ignores -fPIC, still need this for old-style 7082578741aaSmrg # (--disable-auto-import) libraries 7083578741aaSmrg m4_if([$1], [GCJ], [], 7084578741aaSmrg [_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) 7085145b7b3cSmrg ;; 7086145b7b3cSmrg 7087145b7b3cSmrg darwin* | rhapsody*) 7088145b7b3cSmrg # PIC is the default on this platform 7089145b7b3cSmrg # Common symbols not allowed in MH_DYLIB files 7090145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' 7091145b7b3cSmrg ;; 7092145b7b3cSmrg 7093578741aaSmrg interix[[3-9]]*) 7094145b7b3cSmrg # Interix 3.x gcc -fpic/-fPIC options generate broken code. 7095145b7b3cSmrg # Instead, we relocate shared libraries at runtime. 7096145b7b3cSmrg ;; 7097145b7b3cSmrg 7098145b7b3cSmrg msdosdjgpp*) 7099145b7b3cSmrg # Just because we use GCC doesn't mean we suddenly get shared libraries 7100145b7b3cSmrg # on systems that don't support them. 7101145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 7102145b7b3cSmrg enable_shared=no 7103145b7b3cSmrg ;; 7104145b7b3cSmrg 7105145b7b3cSmrg sysv4*MP*) 7106145b7b3cSmrg if test -d /usr/nec; then 7107145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic 7108145b7b3cSmrg fi 7109145b7b3cSmrg ;; 7110145b7b3cSmrg 7111145b7b3cSmrg hpux*) 7112145b7b3cSmrg # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but 7113145b7b3cSmrg # not for PA HP-UX. 7114145b7b3cSmrg case $host_cpu in 7115145b7b3cSmrg hppa*64*|ia64*) 7116145b7b3cSmrg # +Z the default 7117145b7b3cSmrg ;; 7118145b7b3cSmrg *) 7119145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 7120145b7b3cSmrg ;; 7121145b7b3cSmrg esac 7122145b7b3cSmrg ;; 7123145b7b3cSmrg 7124145b7b3cSmrg *) 7125145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' 7126145b7b3cSmrg ;; 7127145b7b3cSmrg esac 7128145b7b3cSmrg else 7129145b7b3cSmrg # PORTME Check for flag to pass linker flags through the system compiler. 7130145b7b3cSmrg case $host_os in 7131145b7b3cSmrg aix*) 7132145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 7133145b7b3cSmrg if test "$host_cpu" = ia64; then 7134145b7b3cSmrg # AIX 5 now supports IA64 processor 7135145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 7136145b7b3cSmrg else 7137145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' 7138145b7b3cSmrg fi 7139145b7b3cSmrg ;; 7140145b7b3cSmrg darwin*) 7141145b7b3cSmrg # PIC is the default on this platform 7142145b7b3cSmrg # Common symbols not allowed in MH_DYLIB files 7143145b7b3cSmrg case $cc_basename in 7144145b7b3cSmrg xlc*) 7145145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-qnocommon' 7146145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 7147145b7b3cSmrg ;; 7148145b7b3cSmrg esac 7149145b7b3cSmrg ;; 7150145b7b3cSmrg 7151578741aaSmrg mingw* | cygwin* | pw32* | os2*) 7152145b7b3cSmrg # This hack is so that the source file can tell whether it is being 7153145b7b3cSmrg # built for inclusion in a dll (and should export symbols for example). 7154578741aaSmrg m4_if([$1], [GCJ], [], 7155578741aaSmrg [_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) 7156145b7b3cSmrg ;; 7157145b7b3cSmrg 7158145b7b3cSmrg hpux9* | hpux10* | hpux11*) 7159145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 7160145b7b3cSmrg # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but 7161145b7b3cSmrg # not for PA HP-UX. 7162145b7b3cSmrg case $host_cpu in 7163145b7b3cSmrg hppa*64*|ia64*) 7164145b7b3cSmrg # +Z the default 7165145b7b3cSmrg ;; 7166145b7b3cSmrg *) 7167145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z' 7168145b7b3cSmrg ;; 7169145b7b3cSmrg esac 7170145b7b3cSmrg # Is there a better lt_prog_compiler_static that works with the bundled CC? 7171145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' 7172145b7b3cSmrg ;; 7173145b7b3cSmrg 7174145b7b3cSmrg irix5* | irix6* | nonstopux*) 7175145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 7176145b7b3cSmrg # PIC (with -KPIC) is the default. 7177145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 7178145b7b3cSmrg ;; 7179145b7b3cSmrg 7180145b7b3cSmrg newsos6) 7181145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 7182145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 7183145b7b3cSmrg ;; 7184145b7b3cSmrg 7185578741aaSmrg linux* | k*bsd*-gnu) 7186145b7b3cSmrg case $cc_basename in 7187145b7b3cSmrg icc* | ecc*) 7188145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 7189145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 7190145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static' 7191145b7b3cSmrg ;; 7192145b7b3cSmrg pgcc* | pgf77* | pgf90* | pgf95*) 7193145b7b3cSmrg # Portland Group compilers (*not* the Pentium gcc compiler, 7194145b7b3cSmrg # which looks to be a dead project) 7195145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 7196145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' 7197145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 7198145b7b3cSmrg ;; 7199145b7b3cSmrg ccc*) 7200145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 7201145b7b3cSmrg # All Alpha code is PIC. 7202145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 7203145b7b3cSmrg ;; 7204578741aaSmrg *) 7205578741aaSmrg case `$CC -V 2>&1 | sed 5q` in 7206578741aaSmrg *Sun\ C*) 7207578741aaSmrg # Sun C 5.9 7208578741aaSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 7209578741aaSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 7210578741aaSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 7211578741aaSmrg ;; 7212578741aaSmrg *Sun\ F*) 7213578741aaSmrg # Sun Fortran 8.3 passes all unrecognized flags to the linker 7214578741aaSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 7215578741aaSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 7216578741aaSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='' 7217578741aaSmrg ;; 7218578741aaSmrg esac 7219578741aaSmrg ;; 7220145b7b3cSmrg esac 7221145b7b3cSmrg ;; 7222145b7b3cSmrg 7223145b7b3cSmrg osf3* | osf4* | osf5*) 7224145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 7225145b7b3cSmrg # All OSF/1 code is PIC. 7226145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 7227145b7b3cSmrg ;; 7228145b7b3cSmrg 7229578741aaSmrg rdos*) 7230578741aaSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' 7231578741aaSmrg ;; 7232578741aaSmrg 7233145b7b3cSmrg solaris*) 7234145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 7235145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 7236145b7b3cSmrg case $cc_basename in 7237145b7b3cSmrg f77* | f90* | f95*) 7238145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';; 7239145b7b3cSmrg *) 7240145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';; 7241145b7b3cSmrg esac 7242145b7b3cSmrg ;; 7243145b7b3cSmrg 7244145b7b3cSmrg sunos4*) 7245145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' 7246145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' 7247145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 7248145b7b3cSmrg ;; 7249145b7b3cSmrg 7250145b7b3cSmrg sysv4 | sysv4.2uw2* | sysv4.3*) 7251145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 7252145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 7253145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 7254145b7b3cSmrg ;; 7255145b7b3cSmrg 7256145b7b3cSmrg sysv4*MP*) 7257145b7b3cSmrg if test -d /usr/nec ;then 7258145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic' 7259145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 7260145b7b3cSmrg fi 7261145b7b3cSmrg ;; 7262145b7b3cSmrg 7263145b7b3cSmrg sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) 7264145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 7265145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' 7266145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 7267145b7b3cSmrg ;; 7268145b7b3cSmrg 7269145b7b3cSmrg unicos*) 7270145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' 7271145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 7272145b7b3cSmrg ;; 7273145b7b3cSmrg 7274145b7b3cSmrg uts4*) 7275145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' 7276145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' 7277145b7b3cSmrg ;; 7278145b7b3cSmrg 7279145b7b3cSmrg *) 7280145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no 7281145b7b3cSmrg ;; 7282145b7b3cSmrg esac 7283145b7b3cSmrg fi 7284145b7b3cSmrg]) 7285145b7b3cSmrgAC_MSG_RESULT([$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)]) 7286145b7b3cSmrg 7287145b7b3cSmrg# 7288145b7b3cSmrg# Check to make sure the PIC flag actually works. 7289145b7b3cSmrg# 7290145b7b3cSmrgif test -n "$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)"; then 7291145b7b3cSmrg AC_LIBTOOL_COMPILER_OPTION([if $compiler PIC flag $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) works], 7292578741aaSmrg _LT_AC_TAGVAR(lt_cv_prog_compiler_pic_works, $1), 7293145b7b3cSmrg [$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])], [], 7294145b7b3cSmrg [case $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) in 7295145b7b3cSmrg "" | " "*) ;; 7296145b7b3cSmrg *) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)" ;; 7297145b7b3cSmrg esac], 7298145b7b3cSmrg [_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= 7299145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no]) 7300145b7b3cSmrgfi 7301145b7b3cSmrgcase $host_os in 7302145b7b3cSmrg # For platforms which do not support PIC, -DPIC is meaningless: 7303145b7b3cSmrg *djgpp*) 7304145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= 7305145b7b3cSmrg ;; 7306145b7b3cSmrg *) 7307145b7b3cSmrg _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])" 7308145b7b3cSmrg ;; 7309145b7b3cSmrgesac 7310145b7b3cSmrg 7311145b7b3cSmrg# 7312145b7b3cSmrg# Check to make sure the static flag actually works. 7313145b7b3cSmrg# 7314145b7b3cSmrgwl=$_LT_AC_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_AC_TAGVAR(lt_prog_compiler_static, $1)\" 7315145b7b3cSmrgAC_LIBTOOL_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works], 7316578741aaSmrg _LT_AC_TAGVAR(lt_cv_prog_compiler_static_works, $1), 7317145b7b3cSmrg $lt_tmp_static_flag, 7318145b7b3cSmrg [], 7319145b7b3cSmrg [_LT_AC_TAGVAR(lt_prog_compiler_static, $1)=]) 7320145b7b3cSmrg]) 7321145b7b3cSmrg 7322145b7b3cSmrg 7323145b7b3cSmrg# AC_LIBTOOL_PROG_LD_SHLIBS([TAGNAME]) 7324145b7b3cSmrg# ------------------------------------ 7325145b7b3cSmrg# See if the linker supports building shared libraries. 7326145b7b3cSmrgAC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS], 7327578741aaSmrg[AC_REQUIRE([LT_AC_PROG_SED])dnl 7328578741aaSmrgAC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) 7329145b7b3cSmrgifelse([$1],[CXX],[ 7330145b7b3cSmrg _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' 7331145b7b3cSmrg case $host_os in 7332578741aaSmrg aix[[4-9]]*) 7333145b7b3cSmrg # If we're using GNU nm, then we don't want the "-C" option. 7334145b7b3cSmrg # -C means demangle to AIX nm, but means don't demangle with GNU nm 7335145b7b3cSmrg if $NM -V 2>&1 | grep 'GNU' > /dev/null; then 7336145b7b3cSmrg _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols' 7337145b7b3cSmrg else 7338145b7b3cSmrg _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols' 7339145b7b3cSmrg fi 7340145b7b3cSmrg ;; 7341145b7b3cSmrg pw32*) 7342145b7b3cSmrg _LT_AC_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds" 7343145b7b3cSmrg ;; 7344145b7b3cSmrg cygwin* | mingw*) 7345578741aaSmrg _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;/^.*[[ ]]__nm__/s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols' 7346145b7b3cSmrg ;; 7347145b7b3cSmrg *) 7348145b7b3cSmrg _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' 7349145b7b3cSmrg ;; 7350145b7b3cSmrg esac 7351578741aaSmrg _LT_AC_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] 7352145b7b3cSmrg],[ 7353145b7b3cSmrg runpath_var= 7354145b7b3cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)= 7355145b7b3cSmrg _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no 7356145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)= 7357145b7b3cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)= 7358145b7b3cSmrg _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)= 7359145b7b3cSmrg _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1)= 7360145b7b3cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)= 7361145b7b3cSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)= 7362145b7b3cSmrg _LT_AC_TAGVAR(thread_safe_flag_spec, $1)= 7363145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)= 7364145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= 7365145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)= 7366145b7b3cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=no 7367145b7b3cSmrg _LT_AC_TAGVAR(hardcode_minus_L, $1)=no 7368145b7b3cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported 7369145b7b3cSmrg _LT_AC_TAGVAR(link_all_deplibs, $1)=unknown 7370145b7b3cSmrg _LT_AC_TAGVAR(hardcode_automatic, $1)=no 7371145b7b3cSmrg _LT_AC_TAGVAR(module_cmds, $1)= 7372145b7b3cSmrg _LT_AC_TAGVAR(module_expsym_cmds, $1)= 7373145b7b3cSmrg _LT_AC_TAGVAR(always_export_symbols, $1)=no 7374145b7b3cSmrg _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' 7375145b7b3cSmrg # include_expsyms should be a list of space-separated symbols to be *always* 7376145b7b3cSmrg # included in the symbol list 7377145b7b3cSmrg _LT_AC_TAGVAR(include_expsyms, $1)= 7378145b7b3cSmrg # exclude_expsyms can be an extended regexp of symbols to exclude 7379145b7b3cSmrg # it will be wrapped by ` (' and `)$', so one must not match beginning or 7380145b7b3cSmrg # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', 7381145b7b3cSmrg # as well as any symbol that contains `d'. 7382578741aaSmrg _LT_AC_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] 7383145b7b3cSmrg # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out 7384145b7b3cSmrg # platforms (ab)use it in PIC code, but their linkers get confused if 7385145b7b3cSmrg # the symbol is explicitly referenced. Since portable code cannot 7386145b7b3cSmrg # rely on this symbol name, it's probably fine to never include it in 7387145b7b3cSmrg # preloaded symbol tables. 7388578741aaSmrg # Exclude shared library initialization/finalization symbols. 7389578741aaSmrgdnl Note also adjust exclude_expsyms for C++ above. 7390145b7b3cSmrg extract_expsyms_cmds= 7391145b7b3cSmrg # Just being paranoid about ensuring that cc_basename is set. 7392145b7b3cSmrg _LT_CC_BASENAME([$compiler]) 7393145b7b3cSmrg case $host_os in 7394145b7b3cSmrg cygwin* | mingw* | pw32*) 7395145b7b3cSmrg # FIXME: the MSVC++ port hasn't been tested in a loooong time 7396145b7b3cSmrg # When not using gcc, we currently assume that we are using 7397145b7b3cSmrg # Microsoft Visual C++. 7398145b7b3cSmrg if test "$GCC" != yes; then 7399145b7b3cSmrg with_gnu_ld=no 7400145b7b3cSmrg fi 7401145b7b3cSmrg ;; 7402145b7b3cSmrg interix*) 7403145b7b3cSmrg # we just hope/assume this is gcc and not c89 (= MSVC++) 7404145b7b3cSmrg with_gnu_ld=yes 7405145b7b3cSmrg ;; 7406145b7b3cSmrg openbsd*) 7407145b7b3cSmrg with_gnu_ld=no 7408145b7b3cSmrg ;; 7409145b7b3cSmrg esac 7410145b7b3cSmrg 7411145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=yes 7412145b7b3cSmrg if test "$with_gnu_ld" = yes; then 7413145b7b3cSmrg # If archive_cmds runs LD, not CC, wlarc should be empty 7414145b7b3cSmrg wlarc='${wl}' 7415145b7b3cSmrg 7416145b7b3cSmrg # Set some defaults for GNU ld with shared library support. These 7417145b7b3cSmrg # are reset later if shared libraries are not supported. Putting them 7418145b7b3cSmrg # here allows them to be overridden if necessary. 7419145b7b3cSmrg runpath_var=LD_RUN_PATH 7420145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir' 7421145b7b3cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' 7422145b7b3cSmrg # ancient GNU ld didn't support --whole-archive et. al. 7423145b7b3cSmrg if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then 7424145b7b3cSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' 7425145b7b3cSmrg else 7426145b7b3cSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)= 7427145b7b3cSmrg fi 7428145b7b3cSmrg supports_anon_versioning=no 7429145b7b3cSmrg case `$LD -v 2>/dev/null` in 7430145b7b3cSmrg *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11 7431145b7b3cSmrg *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... 7432145b7b3cSmrg *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... 7433145b7b3cSmrg *\ 2.11.*) ;; # other 2.11 versions 7434145b7b3cSmrg *) supports_anon_versioning=yes ;; 7435145b7b3cSmrg esac 7436145b7b3cSmrg 7437145b7b3cSmrg # See if GNU ld supports shared libraries. 7438145b7b3cSmrg case $host_os in 7439578741aaSmrg aix[[3-9]]*) 7440145b7b3cSmrg # On AIX/PPC, the GNU linker is very broken 7441145b7b3cSmrg if test "$host_cpu" != ia64; then 7442145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 7443145b7b3cSmrg cat <<EOF 1>&2 7444145b7b3cSmrg 7445145b7b3cSmrg*** Warning: the GNU linker, at least up to release 2.9.1, is reported 7446145b7b3cSmrg*** to be unable to reliably create shared libraries on AIX. 7447145b7b3cSmrg*** Therefore, libtool is disabling shared libraries support. If you 7448145b7b3cSmrg*** really care for shared libraries, you may want to modify your PATH 7449145b7b3cSmrg*** so that a non-GNU linker is found, and then restart. 7450145b7b3cSmrg 7451145b7b3cSmrgEOF 7452145b7b3cSmrg fi 7453145b7b3cSmrg ;; 7454145b7b3cSmrg 7455145b7b3cSmrg amigaos*) 7456145b7b3cSmrg _LT_AC_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)' 7457145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 7458145b7b3cSmrg _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes 7459145b7b3cSmrg 7460145b7b3cSmrg # Samuel A. Falvo II <kc5tja@dolphin.openprojects.net> reports 7461145b7b3cSmrg # that the semantics of dynamic libraries on AmigaOS, at least up 7462145b7b3cSmrg # to version 4, is to share data among multiple programs linked 7463145b7b3cSmrg # with the same dynamic library. Since this doesn't match the 7464145b7b3cSmrg # behavior of shared libraries on other platforms, we can't use 7465145b7b3cSmrg # them. 7466145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 7467145b7b3cSmrg ;; 7468145b7b3cSmrg 7469145b7b3cSmrg beos*) 7470145b7b3cSmrg if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then 7471145b7b3cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported 7472145b7b3cSmrg # Joseph Beckenbach <jrb3@best.com> says some releases of gcc 7473145b7b3cSmrg # support --undefined. This deserves some investigation. FIXME 7474145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 7475145b7b3cSmrg else 7476145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 7477145b7b3cSmrg fi 7478145b7b3cSmrg ;; 7479145b7b3cSmrg 7480145b7b3cSmrg cygwin* | mingw* | pw32*) 7481145b7b3cSmrg # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, 7482145b7b3cSmrg # as there is no search path for DLLs. 7483145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 7484145b7b3cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported 7485145b7b3cSmrg _LT_AC_TAGVAR(always_export_symbols, $1)=no 7486145b7b3cSmrg _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 7487578741aaSmrg _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/'\'' -e '\''/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols' 7488145b7b3cSmrg 7489145b7b3cSmrg if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then 7490145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' 7491145b7b3cSmrg # If the export-symbols file already is a .def file (1st line 7492145b7b3cSmrg # is EXPORTS), use it as is; otherwise, prepend... 7493145b7b3cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then 7494145b7b3cSmrg cp $export_symbols $output_objdir/$soname.def; 7495145b7b3cSmrg else 7496145b7b3cSmrg echo EXPORTS > $output_objdir/$soname.def; 7497145b7b3cSmrg cat $export_symbols >> $output_objdir/$soname.def; 7498145b7b3cSmrg fi~ 7499145b7b3cSmrg $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' 7500145b7b3cSmrg else 7501145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 7502145b7b3cSmrg fi 7503145b7b3cSmrg ;; 7504145b7b3cSmrg 7505578741aaSmrg interix[[3-9]]*) 7506145b7b3cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=no 7507145b7b3cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 7508145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 7509145b7b3cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 7510145b7b3cSmrg # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. 7511145b7b3cSmrg # Instead, shared libraries are loaded at an image base (0x10000000 by 7512145b7b3cSmrg # default) and relocated if they conflict, which is a slow very memory 7513145b7b3cSmrg # consuming and fragmenting process. To avoid this, we pick a random, 7514145b7b3cSmrg # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link 7515145b7b3cSmrg # time. Moving up from 0x10000000 also allows more sbrk(2) space. 7516145b7b3cSmrg _LT_AC_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' 7517145b7b3cSmrg _LT_AC_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' 7518145b7b3cSmrg ;; 7519145b7b3cSmrg 7520578741aaSmrg gnu* | linux* | k*bsd*-gnu) 7521145b7b3cSmrg if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then 7522145b7b3cSmrg tmp_addflag= 7523145b7b3cSmrg case $cc_basename,$host_cpu in 7524145b7b3cSmrg pgcc*) # Portland Group C compiler 7525145b7b3cSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' 7526145b7b3cSmrg tmp_addflag=' $pic_flag' 7527145b7b3cSmrg ;; 7528145b7b3cSmrg pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers 7529145b7b3cSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' 7530145b7b3cSmrg tmp_addflag=' $pic_flag -Mnomain' ;; 7531145b7b3cSmrg ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 7532145b7b3cSmrg tmp_addflag=' -i_dynamic' ;; 7533145b7b3cSmrg efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 7534145b7b3cSmrg tmp_addflag=' -i_dynamic -nofor_main' ;; 7535145b7b3cSmrg ifc* | ifort*) # Intel Fortran compiler 7536145b7b3cSmrg tmp_addflag=' -nofor_main' ;; 7537145b7b3cSmrg esac 7538578741aaSmrg case `$CC -V 2>&1 | sed 5q` in 7539578741aaSmrg *Sun\ C*) # Sun C 5.9 7540578741aaSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' 7541578741aaSmrg tmp_sharedflag='-G' ;; 7542578741aaSmrg *Sun\ F*) # Sun Fortran 8.3 7543578741aaSmrg tmp_sharedflag='-G' ;; 7544578741aaSmrg *) 7545578741aaSmrg tmp_sharedflag='-shared' ;; 7546578741aaSmrg esac 7547578741aaSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 7548145b7b3cSmrg 7549145b7b3cSmrg if test $supports_anon_versioning = yes; then 7550145b7b3cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $output_objdir/$libname.ver~ 7551145b7b3cSmrg cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ 7552145b7b3cSmrg $echo "local: *; };" >> $output_objdir/$libname.ver~ 7553578741aaSmrg $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' 7554145b7b3cSmrg fi 7555145b7b3cSmrg else 7556145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 7557145b7b3cSmrg fi 7558145b7b3cSmrg ;; 7559145b7b3cSmrg 7560145b7b3cSmrg netbsd*) 7561145b7b3cSmrg if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then 7562145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' 7563145b7b3cSmrg wlarc= 7564145b7b3cSmrg else 7565145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 7566145b7b3cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' 7567145b7b3cSmrg fi 7568145b7b3cSmrg ;; 7569145b7b3cSmrg 7570145b7b3cSmrg solaris*) 7571145b7b3cSmrg if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then 7572145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 7573145b7b3cSmrg cat <<EOF 1>&2 7574145b7b3cSmrg 7575145b7b3cSmrg*** Warning: The releases 2.8.* of the GNU linker cannot reliably 7576145b7b3cSmrg*** create shared libraries on Solaris systems. Therefore, libtool 7577145b7b3cSmrg*** is disabling shared libraries support. We urge you to upgrade GNU 7578145b7b3cSmrg*** binutils to release 2.9.1 or newer. Another option is to modify 7579145b7b3cSmrg*** your PATH or compiler configuration so that the native linker is 7580145b7b3cSmrg*** used, and then restart. 7581145b7b3cSmrg 7582145b7b3cSmrgEOF 7583145b7b3cSmrg elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then 7584145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 7585145b7b3cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' 7586145b7b3cSmrg else 7587145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 7588145b7b3cSmrg fi 7589145b7b3cSmrg ;; 7590145b7b3cSmrg 7591145b7b3cSmrg sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) 7592145b7b3cSmrg case `$LD -v 2>&1` in 7593578741aaSmrg *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*) 7594145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 7595145b7b3cSmrg cat <<_LT_EOF 1>&2 7596145b7b3cSmrg 7597145b7b3cSmrg*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not 7598145b7b3cSmrg*** reliably create shared libraries on SCO systems. Therefore, libtool 7599145b7b3cSmrg*** is disabling shared libraries support. We urge you to upgrade GNU 7600145b7b3cSmrg*** binutils to release 2.16.91.0.3 or newer. Another option is to modify 7601145b7b3cSmrg*** your PATH or compiler configuration so that the native linker is 7602145b7b3cSmrg*** used, and then restart. 7603145b7b3cSmrg 7604145b7b3cSmrg_LT_EOF 7605145b7b3cSmrg ;; 7606145b7b3cSmrg *) 7607145b7b3cSmrg if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then 7608145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-rpath,$libdir`' 7609145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib' 7610145b7b3cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname,-retain-symbols-file,$export_symbols -o $lib' 7611145b7b3cSmrg else 7612145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 7613145b7b3cSmrg fi 7614145b7b3cSmrg ;; 7615145b7b3cSmrg esac 7616145b7b3cSmrg ;; 7617145b7b3cSmrg 7618145b7b3cSmrg sunos4*) 7619145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' 7620145b7b3cSmrg wlarc= 7621145b7b3cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=yes 7622145b7b3cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 7623145b7b3cSmrg ;; 7624145b7b3cSmrg 7625145b7b3cSmrg *) 7626145b7b3cSmrg if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then 7627145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' 7628145b7b3cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' 7629145b7b3cSmrg else 7630145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 7631145b7b3cSmrg fi 7632145b7b3cSmrg ;; 7633145b7b3cSmrg esac 7634145b7b3cSmrg 7635145b7b3cSmrg if test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no; then 7636145b7b3cSmrg runpath_var= 7637145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)= 7638145b7b3cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)= 7639145b7b3cSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)= 7640145b7b3cSmrg fi 7641145b7b3cSmrg else 7642145b7b3cSmrg # PORTME fill in a description of your system's linker (not GNU ld) 7643145b7b3cSmrg case $host_os in 7644145b7b3cSmrg aix3*) 7645145b7b3cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported 7646145b7b3cSmrg _LT_AC_TAGVAR(always_export_symbols, $1)=yes 7647145b7b3cSmrg _LT_AC_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' 7648145b7b3cSmrg # Note: this linker hardcodes the directories in LIBPATH if there 7649145b7b3cSmrg # are no directories specified by -L. 7650145b7b3cSmrg _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes 7651145b7b3cSmrg if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then 7652145b7b3cSmrg # Neither direct hardcoding nor static linking is supported with a 7653145b7b3cSmrg # broken collect2. 7654145b7b3cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported 7655145b7b3cSmrg fi 7656145b7b3cSmrg ;; 7657145b7b3cSmrg 7658578741aaSmrg aix[[4-9]]*) 7659145b7b3cSmrg if test "$host_cpu" = ia64; then 7660145b7b3cSmrg # On IA64, the linker does run time linking by default, so we don't 7661145b7b3cSmrg # have to do anything special. 7662145b7b3cSmrg aix_use_runtimelinking=no 7663145b7b3cSmrg exp_sym_flag='-Bexport' 7664145b7b3cSmrg no_entry_flag="" 7665145b7b3cSmrg else 7666145b7b3cSmrg # If we're using GNU nm, then we don't want the "-C" option. 7667145b7b3cSmrg # -C means demangle to AIX nm, but means don't demangle with GNU nm 7668145b7b3cSmrg if $NM -V 2>&1 | grep 'GNU' > /dev/null; then 7669145b7b3cSmrg _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols' 7670145b7b3cSmrg else 7671145b7b3cSmrg _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols' 7672145b7b3cSmrg fi 7673145b7b3cSmrg aix_use_runtimelinking=no 7674145b7b3cSmrg 7675145b7b3cSmrg # Test if we are trying to use run time linking or normal 7676145b7b3cSmrg # AIX style linking. If -brtl is somewhere in LDFLAGS, we 7677145b7b3cSmrg # need to do runtime linking. 7678578741aaSmrg case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) 7679145b7b3cSmrg for ld_flag in $LDFLAGS; do 7680145b7b3cSmrg if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then 7681145b7b3cSmrg aix_use_runtimelinking=yes 7682145b7b3cSmrg break 7683145b7b3cSmrg fi 7684145b7b3cSmrg done 7685145b7b3cSmrg ;; 7686145b7b3cSmrg esac 7687145b7b3cSmrg 7688145b7b3cSmrg exp_sym_flag='-bexport' 7689145b7b3cSmrg no_entry_flag='-bnoentry' 7690145b7b3cSmrg fi 7691145b7b3cSmrg 7692145b7b3cSmrg # When large executables or shared objects are built, AIX ld can 7693145b7b3cSmrg # have problems creating the table of contents. If linking a library 7694145b7b3cSmrg # or program results in "error TOC overflow" add -mminimal-toc to 7695145b7b3cSmrg # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not 7696145b7b3cSmrg # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. 7697145b7b3cSmrg 7698145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='' 7699145b7b3cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=yes 7700145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':' 7701145b7b3cSmrg _LT_AC_TAGVAR(link_all_deplibs, $1)=yes 7702145b7b3cSmrg 7703145b7b3cSmrg if test "$GCC" = yes; then 7704145b7b3cSmrg case $host_os in aix4.[[012]]|aix4.[[012]].*) 7705145b7b3cSmrg # We only want to do this on AIX 4.2 and lower, the check 7706145b7b3cSmrg # below for broken collect2 doesn't work under 4.3+ 7707145b7b3cSmrg collect2name=`${CC} -print-prog-name=collect2` 7708145b7b3cSmrg if test -f "$collect2name" && \ 7709145b7b3cSmrg strings "$collect2name" | grep resolve_lib_name >/dev/null 7710145b7b3cSmrg then 7711145b7b3cSmrg # We have reworked collect2 7712578741aaSmrg : 7713145b7b3cSmrg else 7714145b7b3cSmrg # We have old collect2 7715145b7b3cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported 7716145b7b3cSmrg # It fails to find uninstalled libraries when the uninstalled 7717145b7b3cSmrg # path is not listed in the libpath. Setting hardcode_minus_L 7718145b7b3cSmrg # to unsupported forces relinking 7719145b7b3cSmrg _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes 7720145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 7721145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)= 7722145b7b3cSmrg fi 7723145b7b3cSmrg ;; 7724145b7b3cSmrg esac 7725145b7b3cSmrg shared_flag='-shared' 7726145b7b3cSmrg if test "$aix_use_runtimelinking" = yes; then 7727145b7b3cSmrg shared_flag="$shared_flag "'${wl}-G' 7728145b7b3cSmrg fi 7729145b7b3cSmrg else 7730145b7b3cSmrg # not using gcc 7731145b7b3cSmrg if test "$host_cpu" = ia64; then 7732145b7b3cSmrg # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release 7733145b7b3cSmrg # chokes on -Wl,-G. The following line is correct: 7734145b7b3cSmrg shared_flag='-G' 7735145b7b3cSmrg else 7736145b7b3cSmrg if test "$aix_use_runtimelinking" = yes; then 7737145b7b3cSmrg shared_flag='${wl}-G' 7738145b7b3cSmrg else 7739145b7b3cSmrg shared_flag='${wl}-bM:SRE' 7740145b7b3cSmrg fi 7741145b7b3cSmrg fi 7742145b7b3cSmrg fi 7743145b7b3cSmrg 7744145b7b3cSmrg # It seems that -bexpall does not export symbols beginning with 7745145b7b3cSmrg # underscore (_), so it is better to generate a list of symbols to export. 7746145b7b3cSmrg _LT_AC_TAGVAR(always_export_symbols, $1)=yes 7747145b7b3cSmrg if test "$aix_use_runtimelinking" = yes; then 7748145b7b3cSmrg # Warning - without using the other runtime loading flags (-brtl), 7749145b7b3cSmrg # -berok will link without error, but may produce a broken library. 7750145b7b3cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok' 7751145b7b3cSmrg # Determine the default libpath from the value encoded in an empty executable. 7752145b7b3cSmrg _LT_AC_SYS_LIBPATH_AIX 7753145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" 7754145b7b3cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" 7755145b7b3cSmrg else 7756145b7b3cSmrg if test "$host_cpu" = ia64; then 7757145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' 7758145b7b3cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs" 7759145b7b3cSmrg _LT_AC_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" 7760145b7b3cSmrg else 7761145b7b3cSmrg # Determine the default libpath from the value encoded in an empty executable. 7762145b7b3cSmrg _LT_AC_SYS_LIBPATH_AIX 7763145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" 7764145b7b3cSmrg # Warning - without using the other run time loading flags, 7765145b7b3cSmrg # -berok will link without error, but may produce a broken library. 7766145b7b3cSmrg _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' 7767145b7b3cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' 7768145b7b3cSmrg # Exported symbols can be pulled into shared objects from archives 7769145b7b3cSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='$convenience' 7770145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes 7771145b7b3cSmrg # This is similar to how AIX traditionally builds its shared libraries. 7772145b7b3cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' 7773145b7b3cSmrg fi 7774145b7b3cSmrg fi 7775145b7b3cSmrg ;; 7776145b7b3cSmrg 7777145b7b3cSmrg amigaos*) 7778145b7b3cSmrg _LT_AC_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)' 7779145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 7780145b7b3cSmrg _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes 7781145b7b3cSmrg # see comment about different semantics on the GNU ld section 7782145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 7783145b7b3cSmrg ;; 7784145b7b3cSmrg 7785145b7b3cSmrg bsdi[[45]]*) 7786145b7b3cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic 7787145b7b3cSmrg ;; 7788145b7b3cSmrg 7789145b7b3cSmrg cygwin* | mingw* | pw32*) 7790145b7b3cSmrg # When not using gcc, we currently assume that we are using 7791145b7b3cSmrg # Microsoft Visual C++. 7792145b7b3cSmrg # hardcode_libdir_flag_spec is actually meaningless, as there is 7793145b7b3cSmrg # no search path for DLLs. 7794145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' 7795145b7b3cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported 7796145b7b3cSmrg # Tell ltmain to make .lib files, not .a files. 7797145b7b3cSmrg libext=lib 7798145b7b3cSmrg # Tell ltmain to make .dll files, not .so files. 7799145b7b3cSmrg shrext_cmds=".dll" 7800145b7b3cSmrg # FIXME: Setting linknames here is a bad hack. 7801145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames=' 7802145b7b3cSmrg # The linker will automatically build a .lib file if we build a DLL. 7803145b7b3cSmrg _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='true' 7804145b7b3cSmrg # FIXME: Should let the user specify the lib program. 7805578741aaSmrg _LT_AC_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs' 7806145b7b3cSmrg _LT_AC_TAGVAR(fix_srcfile_path, $1)='`cygpath -w "$srcfile"`' 7807145b7b3cSmrg _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes 7808145b7b3cSmrg ;; 7809145b7b3cSmrg 7810145b7b3cSmrg darwin* | rhapsody*) 7811145b7b3cSmrg case $host_os in 7812145b7b3cSmrg rhapsody* | darwin1.[[012]]) 7813145b7b3cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}suppress' 7814145b7b3cSmrg ;; 7815145b7b3cSmrg *) # Darwin 1.3 on 7816145b7b3cSmrg if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then 7817145b7b3cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' 7818145b7b3cSmrg else 7819145b7b3cSmrg case ${MACOSX_DEPLOYMENT_TARGET} in 7820145b7b3cSmrg 10.[[012]]) 7821145b7b3cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' 7822145b7b3cSmrg ;; 7823145b7b3cSmrg 10.*) 7824145b7b3cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}dynamic_lookup' 7825145b7b3cSmrg ;; 7826145b7b3cSmrg esac 7827145b7b3cSmrg fi 7828145b7b3cSmrg ;; 7829145b7b3cSmrg esac 7830145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no 7831145b7b3cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=no 7832145b7b3cSmrg _LT_AC_TAGVAR(hardcode_automatic, $1)=yes 7833145b7b3cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported 7834145b7b3cSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='' 7835145b7b3cSmrg _LT_AC_TAGVAR(link_all_deplibs, $1)=yes 7836145b7b3cSmrg if test "$GCC" = yes ; then 7837145b7b3cSmrg output_verbose_link_cmd='echo' 7838578741aaSmrg _LT_AC_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}" 7839578741aaSmrg _LT_AC_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" 7840578741aaSmrg _LT_AC_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}" 7841578741aaSmrg _LT_AC_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}" 7842145b7b3cSmrg else 7843145b7b3cSmrg case $cc_basename in 7844145b7b3cSmrg xlc*) 7845145b7b3cSmrg output_verbose_link_cmd='echo' 7846578741aaSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring' 7847145b7b3cSmrg _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' 7848145b7b3cSmrg # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds 7849578741aaSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' 7850145b7b3cSmrg _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' 7851145b7b3cSmrg ;; 7852145b7b3cSmrg *) 7853145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 7854145b7b3cSmrg ;; 7855145b7b3cSmrg esac 7856145b7b3cSmrg fi 7857145b7b3cSmrg ;; 7858145b7b3cSmrg 7859145b7b3cSmrg dgux*) 7860145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 7861145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 7862145b7b3cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 7863145b7b3cSmrg ;; 7864145b7b3cSmrg 7865145b7b3cSmrg freebsd1*) 7866145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 7867145b7b3cSmrg ;; 7868145b7b3cSmrg 7869145b7b3cSmrg # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor 7870145b7b3cSmrg # support. Future versions do this automatically, but an explicit c++rt0.o 7871145b7b3cSmrg # does not break anything, and helps significantly (at the cost of a little 7872145b7b3cSmrg # extra space). 7873145b7b3cSmrg freebsd2.2*) 7874145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' 7875145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 7876145b7b3cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=yes 7877145b7b3cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 7878145b7b3cSmrg ;; 7879145b7b3cSmrg 7880145b7b3cSmrg # Unfortunately, older versions of FreeBSD 2 do not have this feature. 7881145b7b3cSmrg freebsd2*) 7882145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' 7883145b7b3cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=yes 7884145b7b3cSmrg _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes 7885145b7b3cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 7886145b7b3cSmrg ;; 7887145b7b3cSmrg 7888145b7b3cSmrg # FreeBSD 3 and greater uses gcc -shared to do shared libraries. 7889578741aaSmrg freebsd* | dragonfly*) 7890145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' 7891145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 7892145b7b3cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=yes 7893145b7b3cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 7894145b7b3cSmrg ;; 7895145b7b3cSmrg 7896145b7b3cSmrg hpux9*) 7897145b7b3cSmrg if test "$GCC" = yes; then 7898145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' 7899145b7b3cSmrg else 7900145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' 7901145b7b3cSmrg fi 7902145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 7903145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 7904145b7b3cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=yes 7905145b7b3cSmrg 7906145b7b3cSmrg # hardcode_minus_L: Not really in the search PATH, 7907145b7b3cSmrg # but as the default location of the library. 7908145b7b3cSmrg _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes 7909145b7b3cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 7910145b7b3cSmrg ;; 7911145b7b3cSmrg 7912145b7b3cSmrg hpux10*) 7913145b7b3cSmrg if test "$GCC" = yes -a "$with_gnu_ld" = no; then 7914145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' 7915145b7b3cSmrg else 7916145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' 7917145b7b3cSmrg fi 7918145b7b3cSmrg if test "$with_gnu_ld" = no; then 7919145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 7920145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 7921145b7b3cSmrg 7922145b7b3cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=yes 7923145b7b3cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 7924145b7b3cSmrg 7925145b7b3cSmrg # hardcode_minus_L: Not really in the search PATH, 7926145b7b3cSmrg # but as the default location of the library. 7927145b7b3cSmrg _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes 7928145b7b3cSmrg fi 7929145b7b3cSmrg ;; 7930145b7b3cSmrg 7931145b7b3cSmrg hpux11*) 7932145b7b3cSmrg if test "$GCC" = yes -a "$with_gnu_ld" = no; then 7933145b7b3cSmrg case $host_cpu in 7934145b7b3cSmrg hppa*64*) 7935145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' 7936145b7b3cSmrg ;; 7937145b7b3cSmrg ia64*) 7938145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' 7939145b7b3cSmrg ;; 7940145b7b3cSmrg *) 7941145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' 7942145b7b3cSmrg ;; 7943145b7b3cSmrg esac 7944145b7b3cSmrg else 7945145b7b3cSmrg case $host_cpu in 7946145b7b3cSmrg hppa*64*) 7947145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' 7948145b7b3cSmrg ;; 7949145b7b3cSmrg ia64*) 7950145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' 7951145b7b3cSmrg ;; 7952145b7b3cSmrg *) 7953145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' 7954145b7b3cSmrg ;; 7955145b7b3cSmrg esac 7956145b7b3cSmrg fi 7957145b7b3cSmrg if test "$with_gnu_ld" = no; then 7958145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' 7959145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 7960145b7b3cSmrg 7961145b7b3cSmrg case $host_cpu in 7962145b7b3cSmrg hppa*64*|ia64*) 7963145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir' 7964145b7b3cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=no 7965145b7b3cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 7966145b7b3cSmrg ;; 7967145b7b3cSmrg *) 7968145b7b3cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=yes 7969145b7b3cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 7970145b7b3cSmrg 7971145b7b3cSmrg # hardcode_minus_L: Not really in the search PATH, 7972145b7b3cSmrg # but as the default location of the library. 7973145b7b3cSmrg _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes 7974145b7b3cSmrg ;; 7975145b7b3cSmrg esac 7976145b7b3cSmrg fi 7977145b7b3cSmrg ;; 7978145b7b3cSmrg 7979145b7b3cSmrg irix5* | irix6* | nonstopux*) 7980145b7b3cSmrg if test "$GCC" = yes; then 7981145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' 7982145b7b3cSmrg else 7983145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' 7984145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='-rpath $libdir' 7985145b7b3cSmrg fi 7986145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 7987145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 7988145b7b3cSmrg _LT_AC_TAGVAR(link_all_deplibs, $1)=yes 7989145b7b3cSmrg ;; 7990145b7b3cSmrg 7991145b7b3cSmrg netbsd*) 7992145b7b3cSmrg if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then 7993145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out 7994145b7b3cSmrg else 7995145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF 7996145b7b3cSmrg fi 7997145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 7998145b7b3cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=yes 7999145b7b3cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 8000145b7b3cSmrg ;; 8001145b7b3cSmrg 8002145b7b3cSmrg newsos6) 8003145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 8004145b7b3cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=yes 8005145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 8006145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 8007145b7b3cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 8008145b7b3cSmrg ;; 8009145b7b3cSmrg 8010145b7b3cSmrg openbsd*) 8011578741aaSmrg if test -f /usr/libexec/ld.so; then 8012578741aaSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=yes 8013578741aaSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 8014578741aaSmrg if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then 8015578741aaSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' 8016578741aaSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' 8017578741aaSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 8018578741aaSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' 8019578741aaSmrg else 8020578741aaSmrg case $host_os in 8021578741aaSmrg openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*) 8022578741aaSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' 8023578741aaSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 8024578741aaSmrg ;; 8025578741aaSmrg *) 8026578741aaSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' 8027578741aaSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' 8028578741aaSmrg ;; 8029578741aaSmrg esac 8030578741aaSmrg fi 8031145b7b3cSmrg else 8032578741aaSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 8033145b7b3cSmrg fi 8034145b7b3cSmrg ;; 8035145b7b3cSmrg 8036145b7b3cSmrg os2*) 8037145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 8038145b7b3cSmrg _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes 8039145b7b3cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported 8040145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$echo "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$echo "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$echo DATA >> $output_objdir/$libname.def~$echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~$echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def' 8041145b7b3cSmrg _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' 8042145b7b3cSmrg ;; 8043145b7b3cSmrg 8044145b7b3cSmrg osf3*) 8045145b7b3cSmrg if test "$GCC" = yes; then 8046145b7b3cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' 8047145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' 8048145b7b3cSmrg else 8049145b7b3cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' 8050145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' 8051145b7b3cSmrg fi 8052145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 8053145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 8054145b7b3cSmrg ;; 8055145b7b3cSmrg 8056145b7b3cSmrg osf4* | osf5*) # as osf3* with the addition of -msym flag 8057145b7b3cSmrg if test "$GCC" = yes; then 8058145b7b3cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' 8059145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' 8060145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' 8061145b7b3cSmrg else 8062145b7b3cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' 8063145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' 8064145b7b3cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~ 8065145b7b3cSmrg $LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~$rm $lib.exp' 8066145b7b3cSmrg 8067145b7b3cSmrg # Both c and cxx compiler support -rpath directly 8068145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' 8069145b7b3cSmrg fi 8070145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: 8071145b7b3cSmrg ;; 8072145b7b3cSmrg 8073145b7b3cSmrg solaris*) 8074145b7b3cSmrg _LT_AC_TAGVAR(no_undefined_flag, $1)=' -z text' 8075145b7b3cSmrg if test "$GCC" = yes; then 8076145b7b3cSmrg wlarc='${wl}' 8077145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' 8078145b7b3cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ 8079145b7b3cSmrg $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp' 8080145b7b3cSmrg else 8081145b7b3cSmrg wlarc='' 8082145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' 8083145b7b3cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ 8084145b7b3cSmrg $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp' 8085145b7b3cSmrg fi 8086145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' 8087145b7b3cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 8088145b7b3cSmrg case $host_os in 8089145b7b3cSmrg solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; 8090145b7b3cSmrg *) 8091578741aaSmrg # The compiler driver will combine and reorder linker options, 8092578741aaSmrg # but understands `-z linker_flag'. GCC discards it without `$wl', 8093578741aaSmrg # but is careful enough not to reorder. 8094145b7b3cSmrg # Supported since Solaris 2.6 (maybe 2.5.1?) 8095578741aaSmrg if test "$GCC" = yes; then 8096578741aaSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' 8097578741aaSmrg else 8098578741aaSmrg _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' 8099578741aaSmrg fi 8100578741aaSmrg ;; 8101145b7b3cSmrg esac 8102145b7b3cSmrg _LT_AC_TAGVAR(link_all_deplibs, $1)=yes 8103145b7b3cSmrg ;; 8104145b7b3cSmrg 8105145b7b3cSmrg sunos4*) 8106145b7b3cSmrg if test "x$host_vendor" = xsequent; then 8107145b7b3cSmrg # Use $CC to link under sequent, because it throws in some extra .o 8108145b7b3cSmrg # files that make .init and .fini sections work. 8109145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' 8110145b7b3cSmrg else 8111145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' 8112145b7b3cSmrg fi 8113145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 8114145b7b3cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=yes 8115145b7b3cSmrg _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes 8116145b7b3cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 8117145b7b3cSmrg ;; 8118145b7b3cSmrg 8119145b7b3cSmrg sysv4) 8120145b7b3cSmrg case $host_vendor in 8121145b7b3cSmrg sni) 8122145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 8123145b7b3cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=yes # is this really true??? 8124145b7b3cSmrg ;; 8125145b7b3cSmrg siemens) 8126145b7b3cSmrg ## LD is ld it makes a PLAMLIB 8127145b7b3cSmrg ## CC just makes a GrossModule. 8128145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags' 8129145b7b3cSmrg _LT_AC_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs' 8130145b7b3cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=no 8131145b7b3cSmrg ;; 8132145b7b3cSmrg motorola) 8133145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 8134145b7b3cSmrg _LT_AC_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie 8135145b7b3cSmrg ;; 8136145b7b3cSmrg esac 8137145b7b3cSmrg runpath_var='LD_RUN_PATH' 8138145b7b3cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 8139145b7b3cSmrg ;; 8140145b7b3cSmrg 8141145b7b3cSmrg sysv4.3*) 8142145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 8143145b7b3cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 8144145b7b3cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport' 8145145b7b3cSmrg ;; 8146145b7b3cSmrg 8147145b7b3cSmrg sysv4*MP*) 8148145b7b3cSmrg if test -d /usr/nec; then 8149145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 8150145b7b3cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 8151145b7b3cSmrg runpath_var=LD_RUN_PATH 8152145b7b3cSmrg hardcode_runpath_var=yes 8153145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=yes 8154145b7b3cSmrg fi 8155145b7b3cSmrg ;; 8156145b7b3cSmrg 8157578741aaSmrg sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) 8158145b7b3cSmrg _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' 8159145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no 8160145b7b3cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 8161145b7b3cSmrg runpath_var='LD_RUN_PATH' 8162145b7b3cSmrg 8163145b7b3cSmrg if test "$GCC" = yes; then 8164145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 8165145b7b3cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 8166145b7b3cSmrg else 8167145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 8168145b7b3cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' 8169145b7b3cSmrg fi 8170145b7b3cSmrg ;; 8171145b7b3cSmrg 8172145b7b3cSmrg sysv5* | sco3.2v5* | sco5v6*) 8173145b7b3cSmrg # Note: We can NOT use -z defs as we might desire, because we do not 8174145b7b3cSmrg # link with -lc, and that would cause any symbols used from libc to 8175145b7b3cSmrg # always be unresolved, which means just about no library would 8176145b7b3cSmrg # ever link correctly. If we're not using GNU ld we use -z text 8177145b7b3cSmrg # though, which does catch some bad symbols but isn't as heavy-handed 8178145b7b3cSmrg # as -z defs. 8179145b7b3cSmrg _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' 8180145b7b3cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs' 8181145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no 8182145b7b3cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 8183145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`' 8184145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':' 8185145b7b3cSmrg _LT_AC_TAGVAR(link_all_deplibs, $1)=yes 8186145b7b3cSmrg _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' 8187145b7b3cSmrg runpath_var='LD_RUN_PATH' 8188145b7b3cSmrg 8189145b7b3cSmrg if test "$GCC" = yes; then 8190145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' 8191145b7b3cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' 8192145b7b3cSmrg else 8193145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' 8194145b7b3cSmrg _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' 8195145b7b3cSmrg fi 8196145b7b3cSmrg ;; 8197145b7b3cSmrg 8198145b7b3cSmrg uts4*) 8199145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' 8200145b7b3cSmrg _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' 8201145b7b3cSmrg _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no 8202145b7b3cSmrg ;; 8203145b7b3cSmrg 8204145b7b3cSmrg *) 8205145b7b3cSmrg _LT_AC_TAGVAR(ld_shlibs, $1)=no 8206145b7b3cSmrg ;; 8207145b7b3cSmrg esac 8208145b7b3cSmrg fi 8209145b7b3cSmrg]) 8210145b7b3cSmrgAC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)]) 8211145b7b3cSmrgtest "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no 8212145b7b3cSmrg 8213145b7b3cSmrg# 8214145b7b3cSmrg# Do we need to explicitly link libc? 8215145b7b3cSmrg# 8216145b7b3cSmrgcase "x$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)" in 8217145b7b3cSmrgx|xyes) 8218145b7b3cSmrg # Assume -lc should be added 8219145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes 8220145b7b3cSmrg 8221145b7b3cSmrg if test "$enable_shared" = yes && test "$GCC" = yes; then 8222145b7b3cSmrg case $_LT_AC_TAGVAR(archive_cmds, $1) in 8223145b7b3cSmrg *'~'*) 8224145b7b3cSmrg # FIXME: we may have to deal with multi-command sequences. 8225145b7b3cSmrg ;; 8226145b7b3cSmrg '$CC '*) 8227145b7b3cSmrg # Test whether the compiler implicitly links with -lc since on some 8228145b7b3cSmrg # systems, -lgcc has to come before -lc. If gcc already passes -lc 8229145b7b3cSmrg # to ld, don't add -lc before -lgcc. 8230145b7b3cSmrg AC_MSG_CHECKING([whether -lc should be explicitly linked in]) 8231145b7b3cSmrg $rm conftest* 8232578741aaSmrg echo "$lt_simple_compile_test_code" > conftest.$ac_ext 8233145b7b3cSmrg 8234145b7b3cSmrg if AC_TRY_EVAL(ac_compile) 2>conftest.err; then 8235145b7b3cSmrg soname=conftest 8236145b7b3cSmrg lib=conftest 8237145b7b3cSmrg libobjs=conftest.$ac_objext 8238145b7b3cSmrg deplibs= 8239145b7b3cSmrg wl=$_LT_AC_TAGVAR(lt_prog_compiler_wl, $1) 8240145b7b3cSmrg pic_flag=$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) 8241145b7b3cSmrg compiler_flags=-v 8242145b7b3cSmrg linker_flags=-v 8243145b7b3cSmrg verstring= 8244145b7b3cSmrg output_objdir=. 8245145b7b3cSmrg libname=conftest 8246145b7b3cSmrg lt_save_allow_undefined_flag=$_LT_AC_TAGVAR(allow_undefined_flag, $1) 8247145b7b3cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)= 8248145b7b3cSmrg if AC_TRY_EVAL(_LT_AC_TAGVAR(archive_cmds, $1) 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 8249145b7b3cSmrg then 8250145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no 8251145b7b3cSmrg else 8252145b7b3cSmrg _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes 8253145b7b3cSmrg fi 8254145b7b3cSmrg _LT_AC_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag 8255145b7b3cSmrg else 8256145b7b3cSmrg cat conftest.err 1>&5 8257145b7b3cSmrg fi 8258145b7b3cSmrg $rm conftest* 8259145b7b3cSmrg AC_MSG_RESULT([$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)]) 8260145b7b3cSmrg ;; 8261145b7b3cSmrg esac 8262145b7b3cSmrg fi 8263145b7b3cSmrg ;; 8264145b7b3cSmrgesac 8265145b7b3cSmrg])# AC_LIBTOOL_PROG_LD_SHLIBS 8266145b7b3cSmrg 8267145b7b3cSmrg 8268145b7b3cSmrg# _LT_AC_FILE_LTDLL_C 8269145b7b3cSmrg# ------------------- 8270145b7b3cSmrg# Be careful that the start marker always follows a newline. 8271145b7b3cSmrgAC_DEFUN([_LT_AC_FILE_LTDLL_C], [ 8272145b7b3cSmrg# /* ltdll.c starts here */ 8273145b7b3cSmrg# #define WIN32_LEAN_AND_MEAN 8274145b7b3cSmrg# #include <windows.h> 8275145b7b3cSmrg# #undef WIN32_LEAN_AND_MEAN 8276145b7b3cSmrg# #include <stdio.h> 8277145b7b3cSmrg# 8278145b7b3cSmrg# #ifndef __CYGWIN__ 8279145b7b3cSmrg# # ifdef __CYGWIN32__ 8280145b7b3cSmrg# # define __CYGWIN__ __CYGWIN32__ 8281145b7b3cSmrg# # endif 8282145b7b3cSmrg# #endif 8283145b7b3cSmrg# 8284145b7b3cSmrg# #ifdef __cplusplus 8285145b7b3cSmrg# extern "C" { 8286145b7b3cSmrg# #endif 8287145b7b3cSmrg# BOOL APIENTRY DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved); 8288145b7b3cSmrg# #ifdef __cplusplus 8289145b7b3cSmrg# } 8290145b7b3cSmrg# #endif 8291145b7b3cSmrg# 8292145b7b3cSmrg# #ifdef __CYGWIN__ 8293145b7b3cSmrg# #include <cygwin/cygwin_dll.h> 8294145b7b3cSmrg# DECLARE_CYGWIN_DLL( DllMain ); 8295145b7b3cSmrg# #endif 8296145b7b3cSmrg# HINSTANCE __hDllInstance_base; 8297145b7b3cSmrg# 8298145b7b3cSmrg# BOOL APIENTRY 8299145b7b3cSmrg# DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved) 8300145b7b3cSmrg# { 8301145b7b3cSmrg# __hDllInstance_base = hInst; 8302145b7b3cSmrg# return TRUE; 8303145b7b3cSmrg# } 8304145b7b3cSmrg# /* ltdll.c ends here */ 8305145b7b3cSmrg])# _LT_AC_FILE_LTDLL_C 8306145b7b3cSmrg 8307145b7b3cSmrg 8308145b7b3cSmrg# _LT_AC_TAGVAR(VARNAME, [TAGNAME]) 8309145b7b3cSmrg# --------------------------------- 8310145b7b3cSmrgAC_DEFUN([_LT_AC_TAGVAR], [ifelse([$2], [], [$1], [$1_$2])]) 8311145b7b3cSmrg 8312145b7b3cSmrg 8313145b7b3cSmrg# old names 8314145b7b3cSmrgAC_DEFUN([AM_PROG_LIBTOOL], [AC_PROG_LIBTOOL]) 8315145b7b3cSmrgAC_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)]) 8316145b7b3cSmrgAC_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)]) 8317145b7b3cSmrgAC_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)]) 8318145b7b3cSmrgAC_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)]) 8319145b7b3cSmrgAC_DEFUN([AM_PROG_LD], [AC_PROG_LD]) 8320145b7b3cSmrgAC_DEFUN([AM_PROG_NM], [AC_PROG_NM]) 8321145b7b3cSmrg 8322145b7b3cSmrg# This is just to silence aclocal about the macro not being used 8323145b7b3cSmrgifelse([AC_DISABLE_FAST_INSTALL]) 8324145b7b3cSmrg 8325145b7b3cSmrgAC_DEFUN([LT_AC_PROG_GCJ], 8326145b7b3cSmrg[AC_CHECK_TOOL(GCJ, gcj, no) 8327145b7b3cSmrg test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2" 8328145b7b3cSmrg AC_SUBST(GCJFLAGS) 8329145b7b3cSmrg]) 8330145b7b3cSmrg 8331145b7b3cSmrgAC_DEFUN([LT_AC_PROG_RC], 8332145b7b3cSmrg[AC_CHECK_TOOL(RC, windres, no) 8333145b7b3cSmrg]) 8334145b7b3cSmrg 8335578741aaSmrg 8336578741aaSmrg# Cheap backport of AS_EXECUTABLE_P and required macros 8337578741aaSmrg# from Autoconf 2.59; we should not use $as_executable_p directly. 8338578741aaSmrg 8339578741aaSmrg# _AS_TEST_PREPARE 8340578741aaSmrg# ---------------- 8341578741aaSmrgm4_ifndef([_AS_TEST_PREPARE], 8342578741aaSmrg[m4_defun([_AS_TEST_PREPARE], 8343578741aaSmrg[if test -x / >/dev/null 2>&1; then 8344578741aaSmrg as_executable_p='test -x' 8345578741aaSmrgelse 8346578741aaSmrg as_executable_p='test -f' 8347578741aaSmrgfi 8348578741aaSmrg])])# _AS_TEST_PREPARE 8349578741aaSmrg 8350578741aaSmrg# AS_EXECUTABLE_P 8351578741aaSmrg# --------------- 8352578741aaSmrg# Check whether a file is executable. 8353578741aaSmrgm4_ifndef([AS_EXECUTABLE_P], 8354578741aaSmrg[m4_defun([AS_EXECUTABLE_P], 8355578741aaSmrg[AS_REQUIRE([_AS_TEST_PREPARE])dnl 8356578741aaSmrg$as_executable_p $1[]dnl 8357578741aaSmrg])])# AS_EXECUTABLE_P 8358578741aaSmrg 8359145b7b3cSmrg# NOTE: This macro has been submitted for inclusion into # 8360145b7b3cSmrg# GNU Autoconf as AC_PROG_SED. When it is available in # 8361145b7b3cSmrg# a released version of Autoconf we should remove this # 8362145b7b3cSmrg# macro and use it instead. # 8363145b7b3cSmrg# LT_AC_PROG_SED 8364145b7b3cSmrg# -------------- 8365145b7b3cSmrg# Check for a fully-functional sed program, that truncates 8366145b7b3cSmrg# as few characters as possible. Prefer GNU sed if found. 8367145b7b3cSmrgAC_DEFUN([LT_AC_PROG_SED], 8368145b7b3cSmrg[AC_MSG_CHECKING([for a sed that does not truncate output]) 8369145b7b3cSmrgAC_CACHE_VAL(lt_cv_path_SED, 8370145b7b3cSmrg[# Loop through the user's path and test for sed and gsed. 8371145b7b3cSmrg# Then use that list of sed's as ones to test for truncation. 8372145b7b3cSmrgas_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8373145b7b3cSmrgfor as_dir in $PATH 8374145b7b3cSmrgdo 8375145b7b3cSmrg IFS=$as_save_IFS 8376145b7b3cSmrg test -z "$as_dir" && as_dir=. 8377145b7b3cSmrg for lt_ac_prog in sed gsed; do 8378145b7b3cSmrg for ac_exec_ext in '' $ac_executable_extensions; do 8379578741aaSmrg if AS_EXECUTABLE_P(["$as_dir/$lt_ac_prog$ac_exec_ext"]); then 8380145b7b3cSmrg lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext" 8381145b7b3cSmrg fi 8382145b7b3cSmrg done 8383145b7b3cSmrg done 8384145b7b3cSmrgdone 8385578741aaSmrgIFS=$as_save_IFS 8386145b7b3cSmrglt_ac_max=0 8387145b7b3cSmrglt_ac_count=0 8388145b7b3cSmrg# Add /usr/xpg4/bin/sed as it is typically found on Solaris 8389145b7b3cSmrg# along with /bin/sed that truncates output. 8390145b7b3cSmrgfor lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do 8391145b7b3cSmrg test ! -f $lt_ac_sed && continue 8392145b7b3cSmrg cat /dev/null > conftest.in 8393145b7b3cSmrg lt_ac_count=0 8394145b7b3cSmrg echo $ECHO_N "0123456789$ECHO_C" >conftest.in 8395145b7b3cSmrg # Check for GNU sed and select it if it is found. 8396145b7b3cSmrg if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then 8397145b7b3cSmrg lt_cv_path_SED=$lt_ac_sed 8398145b7b3cSmrg break 8399145b7b3cSmrg fi 8400145b7b3cSmrg while true; do 8401145b7b3cSmrg cat conftest.in conftest.in >conftest.tmp 8402145b7b3cSmrg mv conftest.tmp conftest.in 8403145b7b3cSmrg cp conftest.in conftest.nl 8404145b7b3cSmrg echo >>conftest.nl 8405145b7b3cSmrg $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break 8406145b7b3cSmrg cmp -s conftest.out conftest.nl || break 8407145b7b3cSmrg # 10000 chars as input seems more than enough 8408145b7b3cSmrg test $lt_ac_count -gt 10 && break 8409145b7b3cSmrg lt_ac_count=`expr $lt_ac_count + 1` 8410145b7b3cSmrg if test $lt_ac_count -gt $lt_ac_max; then 8411145b7b3cSmrg lt_ac_max=$lt_ac_count 8412145b7b3cSmrg lt_cv_path_SED=$lt_ac_sed 8413145b7b3cSmrg fi 8414145b7b3cSmrg done 8415145b7b3cSmrgdone 8416145b7b3cSmrg]) 8417145b7b3cSmrgSED=$lt_cv_path_SED 8418578741aaSmrgAC_SUBST([SED]) 8419145b7b3cSmrgAC_MSG_RESULT([$SED]) 8420145b7b3cSmrg]) 8421145b7b3cSmrg 8422145b7b3cSmrg# pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*- 8423145b7b3cSmrg# 8424145b7b3cSmrg# Copyright © 2004 Scott James Remnant <scott@netsplit.com>. 8425145b7b3cSmrg# 8426145b7b3cSmrg# This program is free software; you can redistribute it and/or modify 8427145b7b3cSmrg# it under the terms of the GNU General Public License as published by 8428145b7b3cSmrg# the Free Software Foundation; either version 2 of the License, or 8429145b7b3cSmrg# (at your option) any later version. 8430145b7b3cSmrg# 8431145b7b3cSmrg# This program is distributed in the hope that it will be useful, but 8432145b7b3cSmrg# WITHOUT ANY WARRANTY; without even the implied warranty of 8433145b7b3cSmrg# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 8434145b7b3cSmrg# General Public License for more details. 8435145b7b3cSmrg# 8436145b7b3cSmrg# You should have received a copy of the GNU General Public License 8437145b7b3cSmrg# along with this program; if not, write to the Free Software 8438145b7b3cSmrg# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 8439145b7b3cSmrg# 8440145b7b3cSmrg# As a special exception to the GNU General Public License, if you 8441145b7b3cSmrg# distribute this file as part of a program that contains a 8442145b7b3cSmrg# configuration script generated by Autoconf, you may include it under 8443145b7b3cSmrg# the same distribution terms that you use for the rest of that program. 8444145b7b3cSmrg 8445145b7b3cSmrg# PKG_PROG_PKG_CONFIG([MIN-VERSION]) 8446145b7b3cSmrg# ---------------------------------- 8447145b7b3cSmrgAC_DEFUN([PKG_PROG_PKG_CONFIG], 8448145b7b3cSmrg[m4_pattern_forbid([^_?PKG_[A-Z_]+$]) 8449145b7b3cSmrgm4_pattern_allow([^PKG_CONFIG(_PATH)?$]) 8450145b7b3cSmrgAC_ARG_VAR([PKG_CONFIG], [path to pkg-config utility])dnl 8451145b7b3cSmrgif test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then 8452145b7b3cSmrg AC_PATH_TOOL([PKG_CONFIG], [pkg-config]) 8453145b7b3cSmrgfi 8454145b7b3cSmrgif test -n "$PKG_CONFIG"; then 8455578741aaSmrg _pkg_min_version=m4_default([$1], [0.9.0]) 8456145b7b3cSmrg AC_MSG_CHECKING([pkg-config is at least version $_pkg_min_version]) 8457145b7b3cSmrg if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then 8458145b7b3cSmrg AC_MSG_RESULT([yes]) 8459145b7b3cSmrg else 8460145b7b3cSmrg AC_MSG_RESULT([no]) 8461145b7b3cSmrg PKG_CONFIG="" 8462145b7b3cSmrg fi 8463145b7b3cSmrg 8464145b7b3cSmrgfi[]dnl 8465145b7b3cSmrg])# PKG_PROG_PKG_CONFIG 8466145b7b3cSmrg 8467145b7b3cSmrg# PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) 8468145b7b3cSmrg# 8469145b7b3cSmrg# Check to see whether a particular set of modules exists. Similar 8470145b7b3cSmrg# to PKG_CHECK_MODULES(), but does not set variables or print errors. 8471145b7b3cSmrg# 8472145b7b3cSmrg# 8473145b7b3cSmrg# Similar to PKG_CHECK_MODULES, make sure that the first instance of 8474145b7b3cSmrg# this or PKG_CHECK_MODULES is called, or make sure to call 8475145b7b3cSmrg# PKG_CHECK_EXISTS manually 8476145b7b3cSmrg# -------------------------------------------------------------- 8477145b7b3cSmrgAC_DEFUN([PKG_CHECK_EXISTS], 8478145b7b3cSmrg[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl 8479145b7b3cSmrgif test -n "$PKG_CONFIG" && \ 8480145b7b3cSmrg AC_RUN_LOG([$PKG_CONFIG --exists --print-errors "$1"]); then 8481145b7b3cSmrg m4_ifval([$2], [$2], [:]) 8482145b7b3cSmrgm4_ifvaln([$3], [else 8483145b7b3cSmrg $3])dnl 8484145b7b3cSmrgfi]) 8485145b7b3cSmrg 8486145b7b3cSmrg 8487145b7b3cSmrg# _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES]) 8488145b7b3cSmrg# --------------------------------------------- 8489145b7b3cSmrgm4_define([_PKG_CONFIG], 8490578741aaSmrg[if test -n "$$1"; then 8491578741aaSmrg pkg_cv_[]$1="$$1" 8492578741aaSmrg elif test -n "$PKG_CONFIG"; then 8493578741aaSmrg PKG_CHECK_EXISTS([$3], 8494578741aaSmrg [pkg_cv_[]$1=`$PKG_CONFIG --[]$2 "$3" 2>/dev/null`], 8495578741aaSmrg [pkg_failed=yes]) 8496578741aaSmrg else 8497578741aaSmrg pkg_failed=untried 8498145b7b3cSmrgfi[]dnl 8499145b7b3cSmrg])# _PKG_CONFIG 8500145b7b3cSmrg 8501578741aaSmrg# _PKG_SHORT_ERRORS_SUPPORTED 8502578741aaSmrg# ----------------------------- 8503578741aaSmrgAC_DEFUN([_PKG_SHORT_ERRORS_SUPPORTED], 8504578741aaSmrg[AC_REQUIRE([PKG_PROG_PKG_CONFIG]) 8505578741aaSmrgif $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 8506578741aaSmrg _pkg_short_errors_supported=yes 8507578741aaSmrgelse 8508578741aaSmrg _pkg_short_errors_supported=no 8509578741aaSmrgfi[]dnl 8510578741aaSmrg])# _PKG_SHORT_ERRORS_SUPPORTED 8511578741aaSmrg 8512578741aaSmrg 8513145b7b3cSmrg# PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND], 8514145b7b3cSmrg# [ACTION-IF-NOT-FOUND]) 8515145b7b3cSmrg# 8516145b7b3cSmrg# 8517145b7b3cSmrg# Note that if there is a possibility the first call to 8518145b7b3cSmrg# PKG_CHECK_MODULES might not happen, you should be sure to include an 8519145b7b3cSmrg# explicit call to PKG_PROG_PKG_CONFIG in your configure.ac 8520145b7b3cSmrg# 8521145b7b3cSmrg# 8522145b7b3cSmrg# -------------------------------------------------------------- 8523145b7b3cSmrgAC_DEFUN([PKG_CHECK_MODULES], 8524145b7b3cSmrg[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl 8525145b7b3cSmrgAC_ARG_VAR([$1][_CFLAGS], [C compiler flags for $1, overriding pkg-config])dnl 8526145b7b3cSmrgAC_ARG_VAR([$1][_LIBS], [linker flags for $1, overriding pkg-config])dnl 8527145b7b3cSmrg 8528145b7b3cSmrgpkg_failed=no 8529145b7b3cSmrgAC_MSG_CHECKING([for $1]) 8530145b7b3cSmrg 8531145b7b3cSmrg_PKG_CONFIG([$1][_CFLAGS], [cflags], [$2]) 8532145b7b3cSmrg_PKG_CONFIG([$1][_LIBS], [libs], [$2]) 8533145b7b3cSmrg 8534578741aaSmrgm4_define([_PKG_TEXT], [Alternatively, you may set the environment variables $1[]_CFLAGS 8535578741aaSmrgand $1[]_LIBS to avoid the need to call pkg-config. 8536578741aaSmrgSee the pkg-config man page for more details.]) 8537578741aaSmrg 8538145b7b3cSmrgif test $pkg_failed = yes; then 8539578741aaSmrg _PKG_SHORT_ERRORS_SUPPORTED 8540578741aaSmrg if test $_pkg_short_errors_supported = yes; then 8541578741aaSmrg $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "$2" 2>&1` 8542578741aaSmrg else 8543578741aaSmrg $1[]_PKG_ERRORS=`$PKG_CONFIG --print-errors "$2" 2>&1` 8544578741aaSmrg fi 8545145b7b3cSmrg # Put the nasty error message in config.log where it belongs 8546578741aaSmrg echo "$$1[]_PKG_ERRORS" >&AS_MESSAGE_LOG_FD 8547145b7b3cSmrg 8548145b7b3cSmrg ifelse([$4], , [AC_MSG_ERROR(dnl 8549578741aaSmrg[Package requirements ($2) were not met: 8550578741aaSmrg 8551578741aaSmrg$$1_PKG_ERRORS 8552578741aaSmrg 8553145b7b3cSmrgConsider adjusting the PKG_CONFIG_PATH environment variable if you 8554145b7b3cSmrginstalled software in a non-standard prefix. 8555145b7b3cSmrg 8556578741aaSmrg_PKG_TEXT 8557578741aaSmrg])], 8558578741aaSmrg [AC_MSG_RESULT([no]) 8559578741aaSmrg $4]) 8560145b7b3cSmrgelif test $pkg_failed = untried; then 8561145b7b3cSmrg ifelse([$4], , [AC_MSG_FAILURE(dnl 8562145b7b3cSmrg[The pkg-config script could not be found or is too old. Make sure it 8563145b7b3cSmrgis in your PATH or set the PKG_CONFIG environment variable to the full 8564145b7b3cSmrgpath to pkg-config. 8565145b7b3cSmrg 8566578741aaSmrg_PKG_TEXT 8567145b7b3cSmrg 8568578741aaSmrgTo get pkg-config, see <http://pkg-config.freedesktop.org/>.])], 8569145b7b3cSmrg [$4]) 8570145b7b3cSmrgelse 8571145b7b3cSmrg $1[]_CFLAGS=$pkg_cv_[]$1[]_CFLAGS 8572145b7b3cSmrg $1[]_LIBS=$pkg_cv_[]$1[]_LIBS 8573145b7b3cSmrg AC_MSG_RESULT([yes]) 8574145b7b3cSmrg ifelse([$3], , :, [$3]) 8575145b7b3cSmrgfi[]dnl 8576145b7b3cSmrg])# PKG_CHECK_MODULES 8577145b7b3cSmrg 8578145b7b3cSmrgm4_include([acinclude.m4]) 8579