1268515Sdelphij# generated automatically by aclocal 1.14 -*- Autoconf -*- 268349Sobrien 3268515Sdelphij# Copyright (C) 1996-2013 Free Software Foundation, Inc. 4268515Sdelphij 5133359Sobrien# This file is free software; the Free Software Foundation 6133359Sobrien# gives unlimited permission to copy and/or distribute it, 7133359Sobrien# with or without modifications, as long as this notice is preserved. 868349Sobrien 9133359Sobrien# This program is distributed in the hope that it will be useful, 10133359Sobrien# but WITHOUT ANY WARRANTY, to the extent permitted by law; without 11133359Sobrien# even the implied warranty of MERCHANTABILITY or FITNESS FOR A 12133359Sobrien# PARTICULAR PURPOSE. 1368349Sobrien 14268515Sdelphijm4_ifndef([AC_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])]) 15234449Sobrienm4_ifndef([AC_AUTOCONF_VERSION], 16234449Sobrien [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl 17268515Sdelphijm4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.69],, 18268515Sdelphij[m4_warning([this file was generated for autoconf 2.69. 19234449SobrienYou have another version of autoconf. It may work, but is not guaranteed to. 20234449SobrienIf you have problems, you may need to regenerate the build system entirely. 21268515SdelphijTo do so, use the procedure documented by the package, typically 'autoreconf'.])]) 22175296Sobrien 23268515Sdelphij# visibility.m4 serial 5 (gettext-0.18.2) 24268515Sdelphijdnl Copyright (C) 2005, 2008, 2010-2013 Free Software Foundation, Inc. 25268515Sdelphijdnl This file is free software; the Free Software Foundation 26268515Sdelphijdnl gives unlimited permission to copy and/or distribute it, 27268515Sdelphijdnl with or without modifications, as long as this notice is preserved. 28268515Sdelphij 29268515Sdelphijdnl From Bruno Haible. 30268515Sdelphij 31268515Sdelphijdnl Tests whether the compiler supports the command-line option 32268515Sdelphijdnl -fvisibility=hidden and the function and variable attributes 33268515Sdelphijdnl __attribute__((__visibility__("hidden"))) and 34268515Sdelphijdnl __attribute__((__visibility__("default"))). 35268515Sdelphijdnl Does *not* test for __visibility__("protected") - which has tricky 36268515Sdelphijdnl semantics (see the 'vismain' test in glibc) and does not exist e.g. on 37268515Sdelphijdnl Mac OS X. 38268515Sdelphijdnl Does *not* test for __visibility__("internal") - which has processor 39268515Sdelphijdnl dependent semantics. 40268515Sdelphijdnl Does *not* test for #pragma GCC visibility push(hidden) - which is 41268515Sdelphijdnl "really only recommended for legacy code". 42268515Sdelphijdnl Set the variable CFLAG_VISIBILITY. 43268515Sdelphijdnl Defines and sets the variable HAVE_VISIBILITY. 44268515Sdelphij 45268515SdelphijAC_DEFUN([gl_VISIBILITY], 46268515Sdelphij[ 47268515Sdelphij AC_REQUIRE([AC_PROG_CC]) 48268515Sdelphij CFLAG_VISIBILITY= 49268515Sdelphij HAVE_VISIBILITY=0 50268515Sdelphij if test -n "$GCC"; then 51268515Sdelphij dnl First, check whether -Werror can be added to the command line, or 52268515Sdelphij dnl whether it leads to an error because of some other option that the 53268515Sdelphij dnl user has put into $CC $CFLAGS $CPPFLAGS. 54268515Sdelphij AC_MSG_CHECKING([whether the -Werror option is usable]) 55268515Sdelphij AC_CACHE_VAL([gl_cv_cc_vis_werror], [ 56268515Sdelphij gl_save_CFLAGS="$CFLAGS" 57268515Sdelphij CFLAGS="$CFLAGS -Werror" 58268515Sdelphij AC_COMPILE_IFELSE( 59268515Sdelphij [AC_LANG_PROGRAM([[]], [[]])], 60268515Sdelphij [gl_cv_cc_vis_werror=yes], 61268515Sdelphij [gl_cv_cc_vis_werror=no]) 62268515Sdelphij CFLAGS="$gl_save_CFLAGS"]) 63268515Sdelphij AC_MSG_RESULT([$gl_cv_cc_vis_werror]) 64268515Sdelphij dnl Now check whether visibility declarations are supported. 65268515Sdelphij AC_MSG_CHECKING([for simple visibility declarations]) 66268515Sdelphij AC_CACHE_VAL([gl_cv_cc_visibility], [ 67268515Sdelphij gl_save_CFLAGS="$CFLAGS" 68268515Sdelphij CFLAGS="$CFLAGS -fvisibility=hidden" 69268515Sdelphij dnl We use the option -Werror and a function dummyfunc, because on some 70268515Sdelphij dnl platforms (Cygwin 1.7) the use of -fvisibility triggers a warning 71268515Sdelphij dnl "visibility attribute not supported in this configuration; ignored" 72268515Sdelphij dnl at the first function definition in every compilation unit, and we 73268515Sdelphij dnl don't want to use the option in this case. 74268515Sdelphij if test $gl_cv_cc_vis_werror = yes; then 75268515Sdelphij CFLAGS="$CFLAGS -Werror" 76268515Sdelphij fi 77268515Sdelphij AC_COMPILE_IFELSE( 78268515Sdelphij [AC_LANG_PROGRAM( 79268515Sdelphij [[extern __attribute__((__visibility__("hidden"))) int hiddenvar; 80268515Sdelphij extern __attribute__((__visibility__("default"))) int exportedvar; 81268515Sdelphij extern __attribute__((__visibility__("hidden"))) int hiddenfunc (void); 82268515Sdelphij extern __attribute__((__visibility__("default"))) int exportedfunc (void); 83268515Sdelphij void dummyfunc (void) {} 84268515Sdelphij ]], 85268515Sdelphij [[]])], 86268515Sdelphij [gl_cv_cc_visibility=yes], 87268515Sdelphij [gl_cv_cc_visibility=no]) 88268515Sdelphij CFLAGS="$gl_save_CFLAGS"]) 89268515Sdelphij AC_MSG_RESULT([$gl_cv_cc_visibility]) 90268515Sdelphij if test $gl_cv_cc_visibility = yes; then 91268515Sdelphij CFLAG_VISIBILITY="-fvisibility=hidden" 92268515Sdelphij HAVE_VISIBILITY=1 93268515Sdelphij fi 94268515Sdelphij fi 95268515Sdelphij AC_SUBST([CFLAG_VISIBILITY]) 96268515Sdelphij AC_SUBST([HAVE_VISIBILITY]) 97268515Sdelphij AC_DEFINE_UNQUOTED([HAVE_VISIBILITY], [$HAVE_VISIBILITY], 98268515Sdelphij [Define to 1 or 0, depending whether the compiler supports simple visibility declarations.]) 99268515Sdelphij]) 100268515Sdelphij 101268515Sdelphij# Copyright (C) 2002-2013 Free Software Foundation, Inc. 102139368Sobrien# 103159764Sobrien# This file is free software; the Free Software Foundation 104159764Sobrien# gives unlimited permission to copy and/or distribute it, 105159764Sobrien# with or without modifications, as long as this notice is preserved. 106159764Sobrien 107159764Sobrien# AM_AUTOMAKE_VERSION(VERSION) 108159764Sobrien# ---------------------------- 109159764Sobrien# Automake X.Y traces this macro to ensure aclocal.m4 has been 110159764Sobrien# generated from the m4 files accompanying Automake X.Y. 111175296Sobrien# (This private macro should not be called outside this file.) 112175296SobrienAC_DEFUN([AM_AUTOMAKE_VERSION], 113268515Sdelphij[am__api_version='1.14' 114175296Sobriendnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to 115175296Sobriendnl require some minimum version. Point them to the right macro. 116268515Sdelphijm4_if([$1], [1.14], [], 117175296Sobrien [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl 118175296Sobrien]) 119159764Sobrien 120175296Sobrien# _AM_AUTOCONF_VERSION(VERSION) 121175296Sobrien# ----------------------------- 122175296Sobrien# aclocal traces this macro to find the Autoconf version. 123175296Sobrien# This is a private macro too. Using m4_define simplifies 124175296Sobrien# the logic in aclocal, which can simply ignore this definition. 125175296Sobrienm4_define([_AM_AUTOCONF_VERSION], []) 126175296Sobrien 127159764Sobrien# AM_SET_CURRENT_AUTOMAKE_VERSION 128159764Sobrien# ------------------------------- 129175296Sobrien# Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced. 130234449Sobrien# This function is AC_REQUIREd by AM_INIT_AUTOMAKE. 131159764SobrienAC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION], 132268515Sdelphij[AM_AUTOMAKE_VERSION([1.14])dnl 133234449Sobrienm4_ifndef([AC_AUTOCONF_VERSION], 134234449Sobrien [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl 135234449Sobrien_AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))]) 136159764Sobrien 137159764Sobrien# AM_AUX_DIR_EXPAND -*- Autoconf -*- 138159764Sobrien 139268515Sdelphij# Copyright (C) 2001-2013 Free Software Foundation, Inc. 140139368Sobrien# 141159764Sobrien# This file is free software; the Free Software Foundation 142159764Sobrien# gives unlimited permission to copy and/or distribute it, 143159764Sobrien# with or without modifications, as long as this notice is preserved. 144159764Sobrien 145159764Sobrien# For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets 146268515Sdelphij# $ac_aux_dir to '$srcdir/foo'. In other projects, it is set to 147268515Sdelphij# '$srcdir', '$srcdir/..', or '$srcdir/../..'. 148139368Sobrien# 149159764Sobrien# Of course, Automake must honor this variable whenever it calls a 150159764Sobrien# tool from the auxiliary directory. The problem is that $srcdir (and 151159764Sobrien# therefore $ac_aux_dir as well) can be either absolute or relative, 152159764Sobrien# depending on how configure is run. This is pretty annoying, since 153159764Sobrien# it makes $ac_aux_dir quite unusable in subdirectories: in the top 154159764Sobrien# source directory, any form will work fine, but in subdirectories a 155159764Sobrien# relative path needs to be adjusted first. 156139368Sobrien# 157159764Sobrien# $ac_aux_dir/missing 158159764Sobrien# fails when called from a subdirectory if $ac_aux_dir is relative 159159764Sobrien# $top_srcdir/$ac_aux_dir/missing 160159764Sobrien# fails if $ac_aux_dir is absolute, 161159764Sobrien# fails when called from a subdirectory in a VPATH build with 162159764Sobrien# a relative $ac_aux_dir 163139368Sobrien# 164159764Sobrien# The reason of the latter failure is that $top_srcdir and $ac_aux_dir 165159764Sobrien# are both prefixed by $srcdir. In an in-source build this is usually 166268515Sdelphij# harmless because $srcdir is '.', but things will broke when you 167159764Sobrien# start a VPATH build or use an absolute $srcdir. 168139368Sobrien# 169159764Sobrien# So we could use something similar to $top_srcdir/$ac_aux_dir/missing, 170159764Sobrien# iff we strip the leading $srcdir from $ac_aux_dir. That would be: 171159764Sobrien# am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"` 172159764Sobrien# and then we would define $MISSING as 173159764Sobrien# MISSING="\${SHELL} $am_aux_dir/missing" 174159764Sobrien# This will work as long as MISSING is not called from configure, because 175159764Sobrien# unfortunately $(top_srcdir) has no meaning in configure. 176159764Sobrien# However there are other variables, like CC, which are often used in 177159764Sobrien# configure, and could therefore not use this "fixed" $ac_aux_dir. 178139368Sobrien# 179159764Sobrien# Another solution, used here, is to always expand $ac_aux_dir to an 180159764Sobrien# absolute PATH. The drawback is that using absolute paths prevent a 181159764Sobrien# configured tree to be moved without reconfiguration. 182159764Sobrien 183159764SobrienAC_DEFUN([AM_AUX_DIR_EXPAND], 184159764Sobrien[dnl Rely on autoconf to set up CDPATH properly. 185159764SobrienAC_PREREQ([2.50])dnl 186159764Sobrien# expand $ac_aux_dir to an absolute path 187159764Sobrienam_aux_dir=`cd $ac_aux_dir && pwd` 188159764Sobrien]) 189159764Sobrien 190159764Sobrien# AM_CONDITIONAL -*- Autoconf -*- 191159764Sobrien 192268515Sdelphij# Copyright (C) 1997-2013 Free Software Foundation, Inc. 193139368Sobrien# 194159764Sobrien# This file is free software; the Free Software Foundation 195159764Sobrien# gives unlimited permission to copy and/or distribute it, 196159764Sobrien# with or without modifications, as long as this notice is preserved. 197159764Sobrien 198159764Sobrien# AM_CONDITIONAL(NAME, SHELL-CONDITION) 199159764Sobrien# ------------------------------------- 200159764Sobrien# Define a conditional. 201159764SobrienAC_DEFUN([AM_CONDITIONAL], 202268515Sdelphij[AC_PREREQ([2.52])dnl 203268515Sdelphij m4_if([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])], 204268515Sdelphij [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl 205175296SobrienAC_SUBST([$1_TRUE])dnl 206175296SobrienAC_SUBST([$1_FALSE])dnl 207175296Sobrien_AM_SUBST_NOTMAKE([$1_TRUE])dnl 208175296Sobrien_AM_SUBST_NOTMAKE([$1_FALSE])dnl 209234449Sobrienm4_define([_AM_COND_VALUE_$1], [$2])dnl 210159764Sobrienif $2; then 211159764Sobrien $1_TRUE= 212159764Sobrien $1_FALSE='#' 213159764Sobrienelse 214159764Sobrien $1_TRUE='#' 215159764Sobrien $1_FALSE= 216159764Sobrienfi 217159764SobrienAC_CONFIG_COMMANDS_PRE( 218159764Sobrien[if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then 219159764Sobrien AC_MSG_ERROR([[conditional "$1" was never defined. 220159764SobrienUsually this means the macro was only invoked conditionally.]]) 221159764Sobrienfi])]) 222159764Sobrien 223268515Sdelphij# Copyright (C) 1999-2013 Free Software Foundation, Inc. 224139368Sobrien# 225159764Sobrien# This file is free software; the Free Software Foundation 226159764Sobrien# gives unlimited permission to copy and/or distribute it, 227159764Sobrien# with or without modifications, as long as this notice is preserved. 228139368Sobrien 229139368Sobrien 230268515Sdelphij# There are a few dirty hacks below to avoid letting 'AC_PROG_CC' be 231159764Sobrien# written in clear, in which case automake, when reading aclocal.m4, 232159764Sobrien# will think it sees a *use*, and therefore will trigger all it's 233159764Sobrien# C support machinery. Also note that it means that autoscan, seeing 234159764Sobrien# CC etc. in the Makefile, will ask for an AC_PROG_CC use... 235139368Sobrien 236139368Sobrien 237159764Sobrien# _AM_DEPENDENCIES(NAME) 238159764Sobrien# ---------------------- 239159764Sobrien# See how the compiler implements dependency checking. 240268515Sdelphij# NAME is "CC", "CXX", "OBJC", "OBJCXX", "UPC", or "GJC". 241159764Sobrien# We try a few techniques and use that to set a single cache variable. 242159764Sobrien# 243159764Sobrien# We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was 244159764Sobrien# modified to invoke _AM_DEPENDENCIES(CC); we would have a circular 245159764Sobrien# dependency, and given that the user is not expected to run this macro, 246159764Sobrien# just rely on AC_PROG_CC. 247159764SobrienAC_DEFUN([_AM_DEPENDENCIES], 248159764Sobrien[AC_REQUIRE([AM_SET_DEPDIR])dnl 249159764SobrienAC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl 250159764SobrienAC_REQUIRE([AM_MAKE_INCLUDE])dnl 251159764SobrienAC_REQUIRE([AM_DEP_TRACK])dnl 252139368Sobrien 253268515Sdelphijm4_if([$1], [CC], [depcc="$CC" am_compiler_list=], 254268515Sdelphij [$1], [CXX], [depcc="$CXX" am_compiler_list=], 255268515Sdelphij [$1], [OBJC], [depcc="$OBJC" am_compiler_list='gcc3 gcc'], 256268515Sdelphij [$1], [OBJCXX], [depcc="$OBJCXX" am_compiler_list='gcc3 gcc'], 257268515Sdelphij [$1], [UPC], [depcc="$UPC" am_compiler_list=], 258268515Sdelphij [$1], [GCJ], [depcc="$GCJ" am_compiler_list='gcc3 gcc'], 259268515Sdelphij [depcc="$$1" am_compiler_list=]) 260133359Sobrien 261159764SobrienAC_CACHE_CHECK([dependency style of $depcc], 262159764Sobrien [am_cv_$1_dependencies_compiler_type], 263159764Sobrien[if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then 264159764Sobrien # We make a subdir and do the tests there. Otherwise we can end up 265159764Sobrien # making bogus files that we don't know about and never remove. For 266159764Sobrien # instance it was reported that on HP-UX the gcc test will end up 267268515Sdelphij # making a dummy file named 'D' -- because '-MD' means "put the output 268268515Sdelphij # in D". 269268515Sdelphij rm -rf conftest.dir 270159764Sobrien mkdir conftest.dir 271159764Sobrien # Copy depcomp to subdir because otherwise we won't find it if we're 272159764Sobrien # using a relative directory. 273159764Sobrien cp "$am_depcomp" conftest.dir 274159764Sobrien cd conftest.dir 275159764Sobrien # We will build objects and dependencies in a subdirectory because 276159764Sobrien # it helps to detect inapplicable dependency modes. For instance 277159764Sobrien # both Tru64's cc and ICC support -MD to output dependencies as a 278159764Sobrien # side effect of compilation, but ICC will put the dependencies in 279159764Sobrien # the current directory while Tru64 will put them in the object 280159764Sobrien # directory. 281159764Sobrien mkdir sub 282133359Sobrien 283159764Sobrien am_cv_$1_dependencies_compiler_type=none 284159764Sobrien if test "$am_compiler_list" = ""; then 285159764Sobrien am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp` 286159764Sobrien fi 287234449Sobrien am__universal=false 288234449Sobrien m4_case([$1], [CC], 289234449Sobrien [case " $depcc " in #( 290234449Sobrien *\ -arch\ *\ -arch\ *) am__universal=true ;; 291234449Sobrien esac], 292234449Sobrien [CXX], 293234449Sobrien [case " $depcc " in #( 294234449Sobrien *\ -arch\ *\ -arch\ *) am__universal=true ;; 295234449Sobrien esac]) 296234449Sobrien 297159764Sobrien for depmode in $am_compiler_list; do 298159764Sobrien # Setup a source with many dependencies, because some compilers 299159764Sobrien # like to wrap large dependency lists on column 80 (with \), and 300159764Sobrien # we should not choose a depcomp mode which is confused by this. 301159764Sobrien # 302159764Sobrien # We need to recreate these files for each test, as the compiler may 303159764Sobrien # overwrite some of them when testing with obscure command lines. 304159764Sobrien # This happens at least with the AIX C compiler. 305159764Sobrien : > sub/conftest.c 306159764Sobrien for i in 1 2 3 4 5 6; do 307159764Sobrien echo '#include "conftst'$i'.h"' >> sub/conftest.c 308268515Sdelphij # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with 309268515Sdelphij # Solaris 10 /bin/sh. 310268515Sdelphij echo '/* dummy */' > sub/conftst$i.h 311159764Sobrien done 312159764Sobrien echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf 313159764Sobrien 314268515Sdelphij # We check with '-c' and '-o' for the sake of the "dashmstdout" 315234449Sobrien # mode. It turns out that the SunPro C++ compiler does not properly 316268515Sdelphij # handle '-M -o', and we need to detect this. Also, some Intel 317268515Sdelphij # versions had trouble with output in subdirs. 318234449Sobrien am__obj=sub/conftest.${OBJEXT-o} 319234449Sobrien am__minus_obj="-o $am__obj" 320159764Sobrien case $depmode in 321234449Sobrien gcc) 322234449Sobrien # This depmode causes a compiler race in universal mode. 323234449Sobrien test "$am__universal" = false || continue 324234449Sobrien ;; 325159764Sobrien nosideeffect) 326268515Sdelphij # After this tag, mechanisms are not by side-effect, so they'll 327268515Sdelphij # only be used when explicitly requested. 328159764Sobrien if test "x$enable_dependency_tracking" = xyes; then 329159764Sobrien continue 330159764Sobrien else 331159764Sobrien break 332159764Sobrien fi 333159764Sobrien ;; 334268515Sdelphij msvc7 | msvc7msys | msvisualcpp | msvcmsys) 335268515Sdelphij # This compiler won't grok '-c -o', but also, the minuso test has 336234449Sobrien # not run yet. These depmodes are late enough in the game, and 337234449Sobrien # so weak that their functioning should not be impacted. 338234449Sobrien am__obj=conftest.${OBJEXT-o} 339234449Sobrien am__minus_obj= 340234449Sobrien ;; 341159764Sobrien none) break ;; 342159764Sobrien esac 343159764Sobrien if depmode=$depmode \ 344234449Sobrien source=sub/conftest.c object=$am__obj \ 345159764Sobrien depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ 346234449Sobrien $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ 347159764Sobrien >/dev/null 2>conftest.err && 348175296Sobrien grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && 349159764Sobrien grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && 350234449Sobrien grep $am__obj sub/conftest.Po > /dev/null 2>&1 && 351159764Sobrien ${MAKE-make} -s -f confmf > /dev/null 2>&1; then 352159764Sobrien # icc doesn't choke on unknown options, it will just issue warnings 353159764Sobrien # or remarks (even with -Werror). So we grep stderr for any message 354159764Sobrien # that says an option was ignored or not supported. 355159764Sobrien # When given -MP, icc 7.0 and 7.1 complain thusly: 356159764Sobrien # icc: Command line warning: ignoring option '-M'; no argument required 357159764Sobrien # The diagnosis changed in icc 8.0: 358159764Sobrien # icc: Command line remark: option '-MP' not supported 359159764Sobrien if (grep 'ignoring option' conftest.err || 360159764Sobrien grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else 361159764Sobrien am_cv_$1_dependencies_compiler_type=$depmode 362159764Sobrien break 363159764Sobrien fi 364133359Sobrien fi 365133359Sobrien done 366159764Sobrien 367159764Sobrien cd .. 368159764Sobrien rm -rf conftest.dir 369159764Sobrienelse 370159764Sobrien am_cv_$1_dependencies_compiler_type=none 371159764Sobrienfi 372133359Sobrien]) 373159764SobrienAC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type]) 374159764SobrienAM_CONDITIONAL([am__fastdep$1], [ 375159764Sobrien test "x$enable_dependency_tracking" != xno \ 376159764Sobrien && test "$am_cv_$1_dependencies_compiler_type" = gcc3]) 377159764Sobrien]) 378133359Sobrien 379133359Sobrien 380159764Sobrien# AM_SET_DEPDIR 381159764Sobrien# ------------- 382159764Sobrien# Choose a directory name for dependency files. 383268515Sdelphij# This macro is AC_REQUIREd in _AM_DEPENDENCIES. 384159764SobrienAC_DEFUN([AM_SET_DEPDIR], 385159764Sobrien[AC_REQUIRE([AM_SET_LEADING_DOT])dnl 386159764SobrienAC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl 387133359Sobrien]) 388133359Sobrien 389133359Sobrien 390159764Sobrien# AM_DEP_TRACK 391159764Sobrien# ------------ 392159764SobrienAC_DEFUN([AM_DEP_TRACK], 393268515Sdelphij[AC_ARG_ENABLE([dependency-tracking], [dnl 394268515SdelphijAS_HELP_STRING( 395268515Sdelphij [--enable-dependency-tracking], 396268515Sdelphij [do not reject slow dependency extractors]) 397268515SdelphijAS_HELP_STRING( 398268515Sdelphij [--disable-dependency-tracking], 399268515Sdelphij [speeds up one-time build])]) 400159764Sobrienif test "x$enable_dependency_tracking" != xno; then 401159764Sobrien am_depcomp="$ac_aux_dir/depcomp" 402159764Sobrien AMDEPBACKSLASH='\' 403268515Sdelphij am__nodep='_no' 404159764Sobrienfi 405159764SobrienAM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno]) 406175296SobrienAC_SUBST([AMDEPBACKSLASH])dnl 407175296Sobrien_AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl 408268515SdelphijAC_SUBST([am__nodep])dnl 409268515Sdelphij_AM_SUBST_NOTMAKE([am__nodep])dnl 410159764Sobrien]) 411133359Sobrien 412159764Sobrien# Generate code to set up dependency tracking. -*- Autoconf -*- 413159764Sobrien 414268515Sdelphij# Copyright (C) 1999-2013 Free Software Foundation, Inc. 415159764Sobrien# 416159764Sobrien# This file is free software; the Free Software Foundation 417159764Sobrien# gives unlimited permission to copy and/or distribute it, 418159764Sobrien# with or without modifications, as long as this notice is preserved. 419159764Sobrien 420159764Sobrien 421159764Sobrien# _AM_OUTPUT_DEPENDENCY_COMMANDS 422159764Sobrien# ------------------------------ 423159764SobrienAC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], 424234449Sobrien[{ 425268515Sdelphij # Older Autoconf quotes --file arguments for eval, but not when files 426234449Sobrien # are listed without --file. Let's play safe and only enable the eval 427234449Sobrien # if we detect the quoting. 428234449Sobrien case $CONFIG_FILES in 429234449Sobrien *\'*) eval set x "$CONFIG_FILES" ;; 430234449Sobrien *) set x $CONFIG_FILES ;; 431234449Sobrien esac 432234449Sobrien shift 433234449Sobrien for mf 434234449Sobrien do 435234449Sobrien # Strip MF so we end up with the name of the file. 436234449Sobrien mf=`echo "$mf" | sed -e 's/:.*$//'` 437234449Sobrien # Check whether this is an Automake generated Makefile or not. 438268515Sdelphij # We used to match only the files named 'Makefile.in', but 439234449Sobrien # some people rename them; so instead we look at the file content. 440234449Sobrien # Grep'ing the first line is not enough: some people post-process 441234449Sobrien # each Makefile.in and add a new line on top of each file to say so. 442234449Sobrien # Grep'ing the whole file is not good either: AIX grep has a line 443234449Sobrien # limit of 2048, but all sed's we know have understand at least 4000. 444234449Sobrien if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then 445234449Sobrien dirpart=`AS_DIRNAME("$mf")` 446234449Sobrien else 447234449Sobrien continue 448234449Sobrien fi 449234449Sobrien # Extract the definition of DEPDIR, am__include, and am__quote 450268515Sdelphij # from the Makefile without running 'make'. 451234449Sobrien DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` 452234449Sobrien test -z "$DEPDIR" && continue 453234449Sobrien am__include=`sed -n 's/^am__include = //p' < "$mf"` 454268515Sdelphij test -z "$am__include" && continue 455234449Sobrien am__quote=`sed -n 's/^am__quote = //p' < "$mf"` 456234449Sobrien # Find all dependency output files, they are included files with 457234449Sobrien # $(DEPDIR) in their names. We invoke sed twice because it is the 458234449Sobrien # simplest approach to changing $(DEPDIR) to its actual value in the 459234449Sobrien # expansion. 460234449Sobrien for file in `sed -n " 461234449Sobrien s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ 462268515Sdelphij sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do 463234449Sobrien # Make sure the directory exists. 464234449Sobrien test -f "$dirpart/$file" && continue 465234449Sobrien fdir=`AS_DIRNAME(["$file"])` 466234449Sobrien AS_MKDIR_P([$dirpart/$fdir]) 467234449Sobrien # echo "creating $dirpart/$file" 468234449Sobrien echo '# dummy' > "$dirpart/$file" 469234449Sobrien done 470133359Sobrien done 471234449Sobrien} 472159764Sobrien])# _AM_OUTPUT_DEPENDENCY_COMMANDS 473159764Sobrien 474159764Sobrien 475159764Sobrien# AM_OUTPUT_DEPENDENCY_COMMANDS 476159764Sobrien# ----------------------------- 477159764Sobrien# This macro should only be invoked once -- use via AC_REQUIRE. 478159764Sobrien# 479159764Sobrien# This code is only required when automatic dependency tracking 480268515Sdelphij# is enabled. FIXME. This creates each '.P' file that we will 481159764Sobrien# need in order to bootstrap the dependency handling code. 482159764SobrienAC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS], 483159764Sobrien[AC_CONFIG_COMMANDS([depfiles], 484159764Sobrien [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS], 485159764Sobrien [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"]) 486133359Sobrien]) 487133359Sobrien 488159764Sobrien# Do all the work for Automake. -*- Autoconf -*- 489133359Sobrien 490268515Sdelphij# Copyright (C) 1996-2013 Free Software Foundation, Inc. 491159764Sobrien# 492159764Sobrien# This file is free software; the Free Software Foundation 493159764Sobrien# gives unlimited permission to copy and/or distribute it, 494159764Sobrien# with or without modifications, as long as this notice is preserved. 495133359Sobrien 496159764Sobrien# This macro actually does too much. Some checks are only needed if 497159764Sobrien# your package does certain things. But this isn't really a big deal. 498159764Sobrien 499268515Sdelphijdnl Redefine AC_PROG_CC to automatically invoke _AM_PROG_CC_C_O. 500268515Sdelphijm4_define([AC_PROG_CC], 501268515Sdelphijm4_defn([AC_PROG_CC]) 502268515Sdelphij[_AM_PROG_CC_C_O 503268515Sdelphij]) 504268515Sdelphij 505159764Sobrien# AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE]) 506159764Sobrien# AM_INIT_AUTOMAKE([OPTIONS]) 507159764Sobrien# ----------------------------------------------- 508159764Sobrien# The call with PACKAGE and VERSION arguments is the old style 509159764Sobrien# call (pre autoconf-2.50), which is being phased out. PACKAGE 510159764Sobrien# and VERSION should now be passed to AC_INIT and removed from 511159764Sobrien# the call to AM_INIT_AUTOMAKE. 512159764Sobrien# We support both call styles for the transition. After 513159764Sobrien# the next Automake release, Autoconf can make the AC_INIT 514159764Sobrien# arguments mandatory, and then we can depend on a new Autoconf 515159764Sobrien# release and drop the old call support. 516159764SobrienAC_DEFUN([AM_INIT_AUTOMAKE], 517268515Sdelphij[AC_PREREQ([2.65])dnl 518159764Sobriendnl Autoconf wants to disallow AM_ names. We explicitly allow 519159764Sobriendnl the ones we care about. 520159764Sobrienm4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl 521159764SobrienAC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl 522159764SobrienAC_REQUIRE([AC_PROG_INSTALL])dnl 523175296Sobrienif test "`cd $srcdir && pwd`" != "`pwd`"; then 524175296Sobrien # Use -I$(srcdir) only when $(srcdir) != ., so that make's output 525175296Sobrien # is not polluted with repeated "-I." 526175296Sobrien AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl 527175296Sobrien # test to see if srcdir already configured 528175296Sobrien if test -f $srcdir/config.status; then 529175296Sobrien AC_MSG_ERROR([source directory already configured; run "make distclean" there first]) 530175296Sobrien fi 531133359Sobrienfi 532133359Sobrien 533159764Sobrien# test whether we have cygpath 534159764Sobrienif test -z "$CYGPATH_W"; then 535159764Sobrien if (cygpath --version) >/dev/null 2>/dev/null; then 536159764Sobrien CYGPATH_W='cygpath -w' 537133359Sobrien else 538159764Sobrien CYGPATH_W=echo 539133359Sobrien fi 540133359Sobrienfi 541159764SobrienAC_SUBST([CYGPATH_W]) 542159764Sobrien 543159764Sobrien# Define the identity of the package. 544159764Sobriendnl Distinguish between old-style and new-style calls. 545159764Sobrienm4_ifval([$2], 546268515Sdelphij[AC_DIAGNOSE([obsolete], 547268515Sdelphij [$0: two- and three-arguments forms are deprecated.]) 548268515Sdelphijm4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl 549159764Sobrien AC_SUBST([PACKAGE], [$1])dnl 550159764Sobrien AC_SUBST([VERSION], [$2])], 551159764Sobrien[_AM_SET_OPTIONS([$1])dnl 552175296Sobriendnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT. 553268515Sdelphijm4_if( 554268515Sdelphij m4_ifdef([AC_PACKAGE_NAME], [ok]):m4_ifdef([AC_PACKAGE_VERSION], [ok]), 555268515Sdelphij [ok:ok],, 556175296Sobrien [m4_fatal([AC_INIT should be called with package and version arguments])])dnl 557159764Sobrien AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl 558159764Sobrien AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl 559159764Sobrien 560159764Sobrien_AM_IF_OPTION([no-define],, 561268515Sdelphij[AC_DEFINE_UNQUOTED([PACKAGE], ["$PACKAGE"], [Name of package]) 562268515Sdelphij AC_DEFINE_UNQUOTED([VERSION], ["$VERSION"], [Version number of package])])dnl 563159764Sobrien 564159764Sobrien# Some tools Automake needs. 565159764SobrienAC_REQUIRE([AM_SANITY_CHECK])dnl 566159764SobrienAC_REQUIRE([AC_ARG_PROGRAM])dnl 567268515SdelphijAM_MISSING_PROG([ACLOCAL], [aclocal-${am__api_version}]) 568268515SdelphijAM_MISSING_PROG([AUTOCONF], [autoconf]) 569268515SdelphijAM_MISSING_PROG([AUTOMAKE], [automake-${am__api_version}]) 570268515SdelphijAM_MISSING_PROG([AUTOHEADER], [autoheader]) 571268515SdelphijAM_MISSING_PROG([MAKEINFO], [makeinfo]) 572234449SobrienAC_REQUIRE([AM_PROG_INSTALL_SH])dnl 573234449SobrienAC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl 574268515SdelphijAC_REQUIRE([AC_PROG_MKDIR_P])dnl 575268515Sdelphij# For better backward compatibility. To be removed once Automake 1.9.x 576268515Sdelphij# dies out for good. For more background, see: 577268515Sdelphij# <http://lists.gnu.org/archive/html/automake/2012-07/msg00001.html> 578268515Sdelphij# <http://lists.gnu.org/archive/html/automake/2012-07/msg00014.html> 579268515SdelphijAC_SUBST([mkdir_p], ['$(MKDIR_P)']) 580159764Sobrien# We need awk for the "check" target. The system "awk" is bad on 581159764Sobrien# some platforms. 582159764SobrienAC_REQUIRE([AC_PROG_AWK])dnl 583159764SobrienAC_REQUIRE([AC_PROG_MAKE_SET])dnl 584159764SobrienAC_REQUIRE([AM_SET_LEADING_DOT])dnl 585159764Sobrien_AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])], 586234449Sobrien [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])], 587234449Sobrien [_AM_PROG_TAR([v7])])]) 588159764Sobrien_AM_IF_OPTION([no-dependencies],, 589159764Sobrien[AC_PROVIDE_IFELSE([AC_PROG_CC], 590268515Sdelphij [_AM_DEPENDENCIES([CC])], 591268515Sdelphij [m4_define([AC_PROG_CC], 592268515Sdelphij m4_defn([AC_PROG_CC])[_AM_DEPENDENCIES([CC])])])dnl 593159764SobrienAC_PROVIDE_IFELSE([AC_PROG_CXX], 594268515Sdelphij [_AM_DEPENDENCIES([CXX])], 595268515Sdelphij [m4_define([AC_PROG_CXX], 596268515Sdelphij m4_defn([AC_PROG_CXX])[_AM_DEPENDENCIES([CXX])])])dnl 597175296SobrienAC_PROVIDE_IFELSE([AC_PROG_OBJC], 598268515Sdelphij [_AM_DEPENDENCIES([OBJC])], 599268515Sdelphij [m4_define([AC_PROG_OBJC], 600268515Sdelphij m4_defn([AC_PROG_OBJC])[_AM_DEPENDENCIES([OBJC])])])dnl 601268515SdelphijAC_PROVIDE_IFELSE([AC_PROG_OBJCXX], 602268515Sdelphij [_AM_DEPENDENCIES([OBJCXX])], 603268515Sdelphij [m4_define([AC_PROG_OBJCXX], 604268515Sdelphij m4_defn([AC_PROG_OBJCXX])[_AM_DEPENDENCIES([OBJCXX])])])dnl 605133359Sobrien]) 606268515SdelphijAC_REQUIRE([AM_SILENT_RULES])dnl 607268515Sdelphijdnl The testsuite driver may need to know about EXEEXT, so add the 608268515Sdelphijdnl 'am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This 609268515Sdelphijdnl macro is hooked onto _AC_COMPILER_EXEEXT early, see below. 610234449SobrienAC_CONFIG_COMMANDS_PRE(dnl 611234449Sobrien[m4_provide_if([_AM_COMPILER_EXEEXT], 612234449Sobrien [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl 613133359Sobrien 614268515Sdelphij# POSIX will say in a future version that running "rm -f" with no argument 615268515Sdelphij# is OK; and we want to be able to make that assumption in our Makefile 616268515Sdelphij# recipes. So use an aggressive probe to check that the usage we want is 617268515Sdelphij# actually supported "in the wild" to an acceptable degree. 618268515Sdelphij# See automake bug#10828. 619268515Sdelphij# To make any issue more visible, cause the running configure to be aborted 620268515Sdelphij# by default if the 'rm' program in use doesn't match our expectations; the 621268515Sdelphij# user can still override this though. 622268515Sdelphijif rm -f && rm -fr && rm -rf; then : OK; else 623268515Sdelphij cat >&2 <<'END' 624268515SdelphijOops! 625268515Sdelphij 626268515SdelphijYour 'rm' program seems unable to run without file operands specified 627268515Sdelphijon the command line, even when the '-f' option is present. This is contrary 628268515Sdelphijto the behaviour of most rm programs out there, and not conforming with 629268515Sdelphijthe upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542> 630268515Sdelphij 631268515SdelphijPlease tell bug-automake@gnu.org about your system, including the value 632268515Sdelphijof your $PATH and any error possibly output before this message. This 633268515Sdelphijcan help us improve future automake versions. 634268515Sdelphij 635268515SdelphijEND 636268515Sdelphij if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then 637268515Sdelphij echo 'Configuration will proceed anyway, since you have set the' >&2 638268515Sdelphij echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2 639268515Sdelphij echo >&2 640268515Sdelphij else 641268515Sdelphij cat >&2 <<'END' 642268515SdelphijAborting the configuration process, to ensure you take notice of the issue. 643268515Sdelphij 644268515SdelphijYou can download and install GNU coreutils to get an 'rm' implementation 645268515Sdelphijthat behaves properly: <http://www.gnu.org/software/coreutils/>. 646268515Sdelphij 647268515SdelphijIf you want to complete the configuration process using your problematic 648268515Sdelphij'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM 649268515Sdelphijto "yes", and re-run configure. 650268515Sdelphij 651268515SdelphijEND 652268515Sdelphij AC_MSG_ERROR([Your 'rm' program is bad, sorry.]) 653268515Sdelphij fi 654268515Sdelphijfi]) 655268515Sdelphij 656268515Sdelphijdnl Hook into '_AC_COMPILER_EXEEXT' early to learn its expansion. Do not 657234449Sobriendnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further 658234449Sobriendnl mangled by Autoconf and run in a shell conditional statement. 659234449Sobrienm4_define([_AC_COMPILER_EXEEXT], 660234449Sobrienm4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])]) 661133359Sobrien 662159764Sobrien# When config.status generates a header, we must update the stamp-h file. 663159764Sobrien# This file resides in the same directory as the config header 664159764Sobrien# that is generated. The stamp files are numbered to have different names. 665159764Sobrien 666159764Sobrien# Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the 667159764Sobrien# loop where config.status creates the headers, so we can generate 668159764Sobrien# our stamp files there. 669159764SobrienAC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK], 670159764Sobrien[# Compute $1's index in $config_headers. 671234449Sobrien_am_arg=$1 672159764Sobrien_am_stamp_count=1 673159764Sobrienfor _am_header in $config_headers :; do 674159764Sobrien case $_am_header in 675234449Sobrien $_am_arg | $_am_arg:* ) 676159764Sobrien break ;; 677159764Sobrien * ) 678159764Sobrien _am_stamp_count=`expr $_am_stamp_count + 1` ;; 679133359Sobrien esac 680159764Sobriendone 681234449Sobrienecho "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count]) 682159764Sobrien 683268515Sdelphij# Copyright (C) 2001-2013 Free Software Foundation, Inc. 684159764Sobrien# 685159764Sobrien# This file is free software; the Free Software Foundation 686159764Sobrien# gives unlimited permission to copy and/or distribute it, 687159764Sobrien# with or without modifications, as long as this notice is preserved. 688159764Sobrien 689159764Sobrien# AM_PROG_INSTALL_SH 690159764Sobrien# ------------------ 691159764Sobrien# Define $install_sh. 692159764SobrienAC_DEFUN([AM_PROG_INSTALL_SH], 693159764Sobrien[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl 694234449Sobrienif test x"${install_sh}" != xset; then 695234449Sobrien case $am_aux_dir in 696234449Sobrien *\ * | *\ *) 697234449Sobrien install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;; 698234449Sobrien *) 699234449Sobrien install_sh="\${SHELL} $am_aux_dir/install-sh" 700234449Sobrien esac 701234449Sobrienfi 702268515SdelphijAC_SUBST([install_sh])]) 703159764Sobrien 704268515Sdelphij# Copyright (C) 2003-2013 Free Software Foundation, Inc. 705159764Sobrien# 706159764Sobrien# This file is free software; the Free Software Foundation 707159764Sobrien# gives unlimited permission to copy and/or distribute it, 708159764Sobrien# with or without modifications, as long as this notice is preserved. 709159764Sobrien 710159764Sobrien# Check whether the underlying file-system supports filenames 711159764Sobrien# with a leading dot. For instance MS-DOS doesn't. 712159764SobrienAC_DEFUN([AM_SET_LEADING_DOT], 713159764Sobrien[rm -rf .tst 2>/dev/null 714159764Sobrienmkdir .tst 2>/dev/null 715159764Sobrienif test -d .tst; then 716159764Sobrien am__leading_dot=. 717133359Sobrienelse 718159764Sobrien am__leading_dot=_ 719133359Sobrienfi 720159764Sobrienrmdir .tst 2>/dev/null 721159764SobrienAC_SUBST([am__leading_dot])]) 722159764Sobrien 723159764Sobrien# Check to see how 'make' treats includes. -*- Autoconf -*- 724159764Sobrien 725268515Sdelphij# Copyright (C) 2001-2013 Free Software Foundation, Inc. 726159764Sobrien# 727159764Sobrien# This file is free software; the Free Software Foundation 728159764Sobrien# gives unlimited permission to copy and/or distribute it, 729159764Sobrien# with or without modifications, as long as this notice is preserved. 730159764Sobrien 731159764Sobrien# AM_MAKE_INCLUDE() 732159764Sobrien# ----------------- 733159764Sobrien# Check to see how make treats includes. 734159764SobrienAC_DEFUN([AM_MAKE_INCLUDE], 735159764Sobrien[am_make=${MAKE-make} 736159764Sobriencat > confinc << 'END' 737159764Sobrienam__doit: 738234449Sobrien @echo this is the am__doit target 739159764Sobrien.PHONY: am__doit 740159764SobrienEND 741159764Sobrien# If we don't find an include directive, just comment out the code. 742159764SobrienAC_MSG_CHECKING([for style of include used by $am_make]) 743159764Sobrienam__include="#" 744159764Sobrienam__quote= 745159764Sobrien_am_result=none 746159764Sobrien# First try GNU make style include. 747159764Sobrienecho "include confinc" > confmf 748268515Sdelphij# Ignore all kinds of additional output from 'make'. 749234449Sobriencase `$am_make -s -f confmf 2> /dev/null` in #( 750234449Sobrien*the\ am__doit\ target*) 751234449Sobrien am__include=include 752234449Sobrien am__quote= 753234449Sobrien _am_result=GNU 754234449Sobrien ;; 755234449Sobrienesac 756159764Sobrien# Now try BSD make style include. 757159764Sobrienif test "$am__include" = "#"; then 758159764Sobrien echo '.include "confinc"' > confmf 759234449Sobrien case `$am_make -s -f confmf 2> /dev/null` in #( 760234449Sobrien *the\ am__doit\ target*) 761234449Sobrien am__include=.include 762234449Sobrien am__quote="\"" 763234449Sobrien _am_result=BSD 764234449Sobrien ;; 765234449Sobrien esac 766159764Sobrienfi 767159764SobrienAC_SUBST([am__include]) 768159764SobrienAC_SUBST([am__quote]) 769159764SobrienAC_MSG_RESULT([$_am_result]) 770159764Sobrienrm -f confinc confmf 771133359Sobrien]) 77280588Sobrien 773159764Sobrien# Fake the existence of programs that GNU maintainers use. -*- Autoconf -*- 774159764Sobrien 775268515Sdelphij# Copyright (C) 1997-2013 Free Software Foundation, Inc. 776159764Sobrien# 777159764Sobrien# This file is free software; the Free Software Foundation 778159764Sobrien# gives unlimited permission to copy and/or distribute it, 779159764Sobrien# with or without modifications, as long as this notice is preserved. 780159764Sobrien 781159764Sobrien# AM_MISSING_PROG(NAME, PROGRAM) 782159764Sobrien# ------------------------------ 783159764SobrienAC_DEFUN([AM_MISSING_PROG], 784159764Sobrien[AC_REQUIRE([AM_MISSING_HAS_RUN]) 785159764Sobrien$1=${$1-"${am_missing_run}$2"} 786159764SobrienAC_SUBST($1)]) 787159764Sobrien 788159764Sobrien# AM_MISSING_HAS_RUN 789159764Sobrien# ------------------ 790268515Sdelphij# Define MISSING if not defined so far and test if it is modern enough. 791268515Sdelphij# If it is, set am_missing_run to use it, otherwise, to nothing. 792159764SobrienAC_DEFUN([AM_MISSING_HAS_RUN], 793159764Sobrien[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl 794175296SobrienAC_REQUIRE_AUX_FILE([missing])dnl 795234449Sobrienif test x"${MISSING+set}" != xset; then 796234449Sobrien case $am_aux_dir in 797234449Sobrien *\ * | *\ *) 798234449Sobrien MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;; 799234449Sobrien *) 800234449Sobrien MISSING="\${SHELL} $am_aux_dir/missing" ;; 801234449Sobrien esac 802234449Sobrienfi 803159764Sobrien# Use eval to expand $SHELL 804268515Sdelphijif eval "$MISSING --is-lightweight"; then 805268515Sdelphij am_missing_run="$MISSING " 806133359Sobrienelse 807159764Sobrien am_missing_run= 808268515Sdelphij AC_MSG_WARN(['missing' script is too old or missing]) 809159764Sobrienfi 810133359Sobrien]) 811133359Sobrien 812159764Sobrien# Helper functions for option handling. -*- Autoconf -*- 813133359Sobrien 814268515Sdelphij# Copyright (C) 2001-2013 Free Software Foundation, Inc. 815159764Sobrien# 816159764Sobrien# This file is free software; the Free Software Foundation 817159764Sobrien# gives unlimited permission to copy and/or distribute it, 818159764Sobrien# with or without modifications, as long as this notice is preserved. 819133359Sobrien 820159764Sobrien# _AM_MANGLE_OPTION(NAME) 821159764Sobrien# ----------------------- 822159764SobrienAC_DEFUN([_AM_MANGLE_OPTION], 823159764Sobrien[[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])]) 824133359Sobrien 825159764Sobrien# _AM_SET_OPTION(NAME) 826268515Sdelphij# -------------------- 827159764Sobrien# Set option NAME. Presently that only means defining a flag for this option. 828159764SobrienAC_DEFUN([_AM_SET_OPTION], 829268515Sdelphij[m4_define(_AM_MANGLE_OPTION([$1]), [1])]) 830133359Sobrien 831159764Sobrien# _AM_SET_OPTIONS(OPTIONS) 832268515Sdelphij# ------------------------ 833159764Sobrien# OPTIONS is a space-separated list of Automake options. 834159764SobrienAC_DEFUN([_AM_SET_OPTIONS], 835234449Sobrien[m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])]) 836133359Sobrien 837159764Sobrien# _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET]) 838159764Sobrien# ------------------------------------------- 839159764Sobrien# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. 840159764SobrienAC_DEFUN([_AM_IF_OPTION], 841159764Sobrien[m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])]) 842133359Sobrien 843268515Sdelphij# Copyright (C) 1999-2013 Free Software Foundation, Inc. 844268515Sdelphij# 845268515Sdelphij# This file is free software; the Free Software Foundation 846268515Sdelphij# gives unlimited permission to copy and/or distribute it, 847268515Sdelphij# with or without modifications, as long as this notice is preserved. 848268515Sdelphij 849268515Sdelphij# _AM_PROG_CC_C_O 850268515Sdelphij# --------------- 851268515Sdelphij# Like AC_PROG_CC_C_O, but changed for automake. We rewrite AC_PROG_CC 852268515Sdelphij# to automatically call this. 853268515SdelphijAC_DEFUN([_AM_PROG_CC_C_O], 854268515Sdelphij[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl 855268515SdelphijAC_REQUIRE_AUX_FILE([compile])dnl 856268515SdelphijAC_LANG_PUSH([C])dnl 857268515SdelphijAC_CACHE_CHECK( 858268515Sdelphij [whether $CC understands -c and -o together], 859268515Sdelphij [am_cv_prog_cc_c_o], 860268515Sdelphij [AC_LANG_CONFTEST([AC_LANG_PROGRAM([])]) 861268515Sdelphij # Make sure it works both with $CC and with simple cc. 862268515Sdelphij # Following AC_PROG_CC_C_O, we do the test twice because some 863268515Sdelphij # compilers refuse to overwrite an existing .o file with -o, 864268515Sdelphij # though they will create one. 865268515Sdelphij am_cv_prog_cc_c_o=yes 866268515Sdelphij for am_i in 1 2; do 867268515Sdelphij if AM_RUN_LOG([$CC -c conftest.$ac_ext -o conftest2.$ac_objext]) \ 868268515Sdelphij && test -f conftest2.$ac_objext; then 869268515Sdelphij : OK 870268515Sdelphij else 871268515Sdelphij am_cv_prog_cc_c_o=no 872268515Sdelphij break 873268515Sdelphij fi 874268515Sdelphij done 875268515Sdelphij rm -f core conftest* 876268515Sdelphij unset am_i]) 877268515Sdelphijif test "$am_cv_prog_cc_c_o" != yes; then 878268515Sdelphij # Losing compiler, so override with the script. 879268515Sdelphij # FIXME: It is wrong to rewrite CC. 880268515Sdelphij # But if we don't then we get into trouble of one sort or another. 881268515Sdelphij # A longer-term fix would be to have automake use am__CC in this case, 882268515Sdelphij # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)" 883268515Sdelphij CC="$am_aux_dir/compile $CC" 884268515Sdelphijfi 885268515SdelphijAC_LANG_POP([C])]) 886268515Sdelphij 887268515Sdelphij# For backward compatibility. 888268515SdelphijAC_DEFUN_ONCE([AM_PROG_CC_C_O], [AC_REQUIRE([AC_PROG_CC])]) 889268515Sdelphij 890268515Sdelphij# Copyright (C) 2001-2013 Free Software Foundation, Inc. 891268515Sdelphij# 892268515Sdelphij# This file is free software; the Free Software Foundation 893268515Sdelphij# gives unlimited permission to copy and/or distribute it, 894268515Sdelphij# with or without modifications, as long as this notice is preserved. 895268515Sdelphij 896268515Sdelphij# AM_RUN_LOG(COMMAND) 897268515Sdelphij# ------------------- 898268515Sdelphij# Run COMMAND, save the exit status in ac_status, and log it. 899268515Sdelphij# (This has been adapted from Autoconf's _AC_RUN_LOG macro.) 900268515SdelphijAC_DEFUN([AM_RUN_LOG], 901268515Sdelphij[{ echo "$as_me:$LINENO: $1" >&AS_MESSAGE_LOG_FD 902268515Sdelphij ($1) >&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD 903268515Sdelphij ac_status=$? 904268515Sdelphij echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD 905268515Sdelphij (exit $ac_status); }]) 906268515Sdelphij 907159764Sobrien# Check to make sure that the build environment is sane. -*- Autoconf -*- 908133359Sobrien 909268515Sdelphij# Copyright (C) 1996-2013 Free Software Foundation, Inc. 910159764Sobrien# 911159764Sobrien# This file is free software; the Free Software Foundation 912159764Sobrien# gives unlimited permission to copy and/or distribute it, 913159764Sobrien# with or without modifications, as long as this notice is preserved. 914133359Sobrien 915159764Sobrien# AM_SANITY_CHECK 916159764Sobrien# --------------- 917159764SobrienAC_DEFUN([AM_SANITY_CHECK], 918159764Sobrien[AC_MSG_CHECKING([whether build environment is sane]) 919234449Sobrien# Reject unsafe characters in $srcdir or the absolute working directory 920234449Sobrien# name. Accept space and tab only in the latter. 921234449Sobrienam_lf=' 922234449Sobrien' 923234449Sobriencase `pwd` in 924234449Sobrien *[[\\\"\#\$\&\'\`$am_lf]]*) 925234449Sobrien AC_MSG_ERROR([unsafe absolute working directory name]);; 926234449Sobrienesac 927234449Sobriencase $srcdir in 928234449Sobrien *[[\\\"\#\$\&\'\`$am_lf\ \ ]]*) 929268515Sdelphij AC_MSG_ERROR([unsafe srcdir value: '$srcdir']);; 930234449Sobrienesac 931234449Sobrien 932268515Sdelphij# Do 'set' in a subshell so we don't clobber the current shell's 933159764Sobrien# arguments. Must try -L first in case configure is actually a 934159764Sobrien# symlink; some systems play weird games with the mod time of symlinks 935159764Sobrien# (eg FreeBSD returns the mod time of the symlink's containing 936159764Sobrien# directory). 937159764Sobrienif ( 938268515Sdelphij am_has_slept=no 939268515Sdelphij for am_try in 1 2; do 940268515Sdelphij echo "timestamp, slept: $am_has_slept" > conftest.file 941268515Sdelphij set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` 942268515Sdelphij if test "$[*]" = "X"; then 943268515Sdelphij # -L didn't work. 944268515Sdelphij set X `ls -t "$srcdir/configure" conftest.file` 945268515Sdelphij fi 946268515Sdelphij if test "$[*]" != "X $srcdir/configure conftest.file" \ 947268515Sdelphij && test "$[*]" != "X conftest.file $srcdir/configure"; then 948133359Sobrien 949268515Sdelphij # If neither matched, then we have a broken ls. This can happen 950268515Sdelphij # if, for instance, CONFIG_SHELL is bash and it inherits a 951268515Sdelphij # broken ls alias from the environment. This has actually 952268515Sdelphij # happened. Such a system could not be considered "sane". 953268515Sdelphij AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken 954268515Sdelphij alias in your environment]) 955268515Sdelphij fi 956268515Sdelphij if test "$[2]" = conftest.file || test $am_try -eq 2; then 957268515Sdelphij break 958268515Sdelphij fi 959268515Sdelphij # Just in case. 960268515Sdelphij sleep 1 961268515Sdelphij am_has_slept=yes 962268515Sdelphij done 963159764Sobrien test "$[2]" = conftest.file 964159764Sobrien ) 965159764Sobrienthen 966159764Sobrien # Ok. 967159764Sobrien : 968159764Sobrienelse 969159764Sobrien AC_MSG_ERROR([newly created file is older than distributed files! 970159764SobrienCheck your system clock]) 971159764Sobrienfi 972268515SdelphijAC_MSG_RESULT([yes]) 973268515Sdelphij# If we didn't sleep, we still need to ensure time stamps of config.status and 974268515Sdelphij# generated files are strictly newer. 975268515Sdelphijam_sleep_pid= 976268515Sdelphijif grep 'slept: no' conftest.file >/dev/null 2>&1; then 977268515Sdelphij ( sleep 1 ) & 978268515Sdelphij am_sleep_pid=$! 979268515Sdelphijfi 980268515SdelphijAC_CONFIG_COMMANDS_PRE( 981268515Sdelphij [AC_MSG_CHECKING([that generated files are newer than configure]) 982268515Sdelphij if test -n "$am_sleep_pid"; then 983268515Sdelphij # Hide warnings about reused PIDs. 984268515Sdelphij wait $am_sleep_pid 2>/dev/null 985268515Sdelphij fi 986268515Sdelphij AC_MSG_RESULT([done])]) 987268515Sdelphijrm -f conftest.file 988268515Sdelphij]) 989139368Sobrien 990268515Sdelphij# Copyright (C) 2009-2013 Free Software Foundation, Inc. 991234449Sobrien# 992234449Sobrien# This file is free software; the Free Software Foundation 993234449Sobrien# gives unlimited permission to copy and/or distribute it, 994234449Sobrien# with or without modifications, as long as this notice is preserved. 995234449Sobrien 996234449Sobrien# AM_SILENT_RULES([DEFAULT]) 997234449Sobrien# -------------------------- 998234449Sobrien# Enable less verbose build rules; with the default set to DEFAULT 999268515Sdelphij# ("yes" being less verbose, "no" or empty being verbose). 1000234449SobrienAC_DEFUN([AM_SILENT_RULES], 1001268515Sdelphij[AC_ARG_ENABLE([silent-rules], [dnl 1002268515SdelphijAS_HELP_STRING( 1003268515Sdelphij [--enable-silent-rules], 1004268515Sdelphij [less verbose build output (undo: "make V=1")]) 1005268515SdelphijAS_HELP_STRING( 1006268515Sdelphij [--disable-silent-rules], 1007268515Sdelphij [verbose build output (undo: "make V=0")])dnl 1008268515Sdelphij]) 1009268515Sdelphijcase $enable_silent_rules in @%:@ ((( 1010268515Sdelphij yes) AM_DEFAULT_VERBOSITY=0;; 1011268515Sdelphij no) AM_DEFAULT_VERBOSITY=1;; 1012268515Sdelphij *) AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);; 1013234449Sobrienesac 1014268515Sdelphijdnl 1015268515Sdelphijdnl A few 'make' implementations (e.g., NonStop OS and NextStep) 1016268515Sdelphijdnl do not support nested variable expansions. 1017268515Sdelphijdnl See automake bug#9928 and bug#10237. 1018268515Sdelphijam_make=${MAKE-make} 1019268515SdelphijAC_CACHE_CHECK([whether $am_make supports nested variables], 1020268515Sdelphij [am_cv_make_support_nested_variables], 1021268515Sdelphij [if AS_ECHO([['TRUE=$(BAR$(V)) 1022268515SdelphijBAR0=false 1023268515SdelphijBAR1=true 1024268515SdelphijV=1 1025268515Sdelphijam__doit: 1026268515Sdelphij @$(TRUE) 1027268515Sdelphij.PHONY: am__doit']]) | $am_make -f - >/dev/null 2>&1; then 1028268515Sdelphij am_cv_make_support_nested_variables=yes 1029268515Sdelphijelse 1030268515Sdelphij am_cv_make_support_nested_variables=no 1031268515Sdelphijfi]) 1032268515Sdelphijif test $am_cv_make_support_nested_variables = yes; then 1033268515Sdelphij dnl Using '$V' instead of '$(V)' breaks IRIX make. 1034268515Sdelphij AM_V='$(V)' 1035268515Sdelphij AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)' 1036268515Sdelphijelse 1037268515Sdelphij AM_V=$AM_DEFAULT_VERBOSITY 1038268515Sdelphij AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY 1039268515Sdelphijfi 1040268515SdelphijAC_SUBST([AM_V])dnl 1041268515SdelphijAM_SUBST_NOTMAKE([AM_V])dnl 1042268515SdelphijAC_SUBST([AM_DEFAULT_V])dnl 1043268515SdelphijAM_SUBST_NOTMAKE([AM_DEFAULT_V])dnl 1044234449SobrienAC_SUBST([AM_DEFAULT_VERBOSITY])dnl 1045234449SobrienAM_BACKSLASH='\' 1046234449SobrienAC_SUBST([AM_BACKSLASH])dnl 1047234449Sobrien_AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl 1048234449Sobrien]) 1049234449Sobrien 1050268515Sdelphij# Copyright (C) 2001-2013 Free Software Foundation, Inc. 1051159764Sobrien# 1052159764Sobrien# This file is free software; the Free Software Foundation 1053159764Sobrien# gives unlimited permission to copy and/or distribute it, 1054159764Sobrien# with or without modifications, as long as this notice is preserved. 1055133359Sobrien 1056159764Sobrien# AM_PROG_INSTALL_STRIP 1057159764Sobrien# --------------------- 1058268515Sdelphij# One issue with vendor 'install' (even GNU) is that you can't 1059159764Sobrien# specify the program used to strip binaries. This is especially 1060159764Sobrien# annoying in cross-compiling environments, where the build's strip 1061159764Sobrien# is unlikely to handle the host's binaries. 1062159764Sobrien# Fortunately install-sh will honor a STRIPPROG variable, so we 1063268515Sdelphij# always use install-sh in "make install-strip", and initialize 1064159764Sobrien# STRIPPROG with the value of the STRIP variable (set by the user). 1065159764SobrienAC_DEFUN([AM_PROG_INSTALL_STRIP], 1066159764Sobrien[AC_REQUIRE([AM_PROG_INSTALL_SH])dnl 1067268515Sdelphij# Installed binaries are usually stripped using 'strip' when the user 1068268515Sdelphij# run "make install-strip". However 'strip' might not be the right 1069159764Sobrien# tool to use in cross-compilation environments, therefore Automake 1070268515Sdelphij# will honor the 'STRIP' environment variable to overrule this program. 1071268515Sdelphijdnl Don't test for $cross_compiling = yes, because it might be 'maybe'. 1072159764Sobrienif test "$cross_compiling" != no; then 1073159764Sobrien AC_CHECK_TOOL([STRIP], [strip], :) 1074159764Sobrienfi 1075175296SobrienINSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" 1076159764SobrienAC_SUBST([INSTALL_STRIP_PROGRAM])]) 1077133359Sobrien 1078268515Sdelphij# Copyright (C) 2006-2013 Free Software Foundation, Inc. 1079175296Sobrien# 1080175296Sobrien# This file is free software; the Free Software Foundation 1081175296Sobrien# gives unlimited permission to copy and/or distribute it, 1082175296Sobrien# with or without modifications, as long as this notice is preserved. 1083175296Sobrien 1084175296Sobrien# _AM_SUBST_NOTMAKE(VARIABLE) 1085175296Sobrien# --------------------------- 1086234449Sobrien# Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in. 1087175296Sobrien# This macro is traced by Automake. 1088175296SobrienAC_DEFUN([_AM_SUBST_NOTMAKE]) 1089175296Sobrien 1090234449Sobrien# AM_SUBST_NOTMAKE(VARIABLE) 1091268515Sdelphij# -------------------------- 1092234449Sobrien# Public sister of _AM_SUBST_NOTMAKE. 1093234449SobrienAC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)]) 1094234449Sobrien 1095159764Sobrien# Check how to create a tarball. -*- Autoconf -*- 1096133359Sobrien 1097268515Sdelphij# Copyright (C) 2004-2013 Free Software Foundation, Inc. 1098159764Sobrien# 1099159764Sobrien# This file is free software; the Free Software Foundation 1100159764Sobrien# gives unlimited permission to copy and/or distribute it, 1101159764Sobrien# with or without modifications, as long as this notice is preserved. 1102133359Sobrien 1103159764Sobrien# _AM_PROG_TAR(FORMAT) 1104159764Sobrien# -------------------- 1105159764Sobrien# Check how to create a tarball in format FORMAT. 1106268515Sdelphij# FORMAT should be one of 'v7', 'ustar', or 'pax'. 1107159764Sobrien# 1108159764Sobrien# Substitute a variable $(am__tar) that is a command 1109159764Sobrien# writing to stdout a FORMAT-tarball containing the directory 1110159764Sobrien# $tardir. 1111159764Sobrien# tardir=directory && $(am__tar) > result.tar 1112159764Sobrien# 1113159764Sobrien# Substitute a variable $(am__untar) that extract such 1114159764Sobrien# a tarball read from stdin. 1115159764Sobrien# $(am__untar) < result.tar 1116268515Sdelphij# 1117159764SobrienAC_DEFUN([_AM_PROG_TAR], 1118268515Sdelphij[# Always define AMTAR for backward compatibility. Yes, it's still used 1119268515Sdelphij# in the wild :-( We should find a proper way to deprecate it ... 1120268515SdelphijAC_SUBST([AMTAR], ['$${TAR-tar}']) 1121268515Sdelphij 1122268515Sdelphij# We'll loop over all known methods to create a tar archive until one works. 1123159764Sobrien_am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none' 1124133359Sobrien 1125268515Sdelphijm4_if([$1], [v7], 1126268515Sdelphij [am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'], 1127133359Sobrien 1128268515Sdelphij [m4_case([$1], 1129268515Sdelphij [ustar], 1130268515Sdelphij [# The POSIX 1988 'ustar' format is defined with fixed-size fields. 1131268515Sdelphij # There is notably a 21 bits limit for the UID and the GID. In fact, 1132268515Sdelphij # the 'pax' utility can hang on bigger UID/GID (see automake bug#8343 1133268515Sdelphij # and bug#13588). 1134268515Sdelphij am_max_uid=2097151 # 2^21 - 1 1135268515Sdelphij am_max_gid=$am_max_uid 1136268515Sdelphij # The $UID and $GID variables are not portable, so we need to resort 1137268515Sdelphij # to the POSIX-mandated id(1) utility. Errors in the 'id' calls 1138268515Sdelphij # below are definitely unexpected, so allow the users to see them 1139268515Sdelphij # (that is, avoid stderr redirection). 1140268515Sdelphij am_uid=`id -u || echo unknown` 1141268515Sdelphij am_gid=`id -g || echo unknown` 1142268515Sdelphij AC_MSG_CHECKING([whether UID '$am_uid' is supported by ustar format]) 1143268515Sdelphij if test $am_uid -le $am_max_uid; then 1144268515Sdelphij AC_MSG_RESULT([yes]) 1145268515Sdelphij else 1146268515Sdelphij AC_MSG_RESULT([no]) 1147268515Sdelphij _am_tools=none 1148268515Sdelphij fi 1149268515Sdelphij AC_MSG_CHECKING([whether GID '$am_gid' is supported by ustar format]) 1150268515Sdelphij if test $am_gid -le $am_max_gid; then 1151268515Sdelphij AC_MSG_RESULT([yes]) 1152268515Sdelphij else 1153268515Sdelphij AC_MSG_RESULT([no]) 1154268515Sdelphij _am_tools=none 1155268515Sdelphij fi], 1156268515Sdelphij 1157268515Sdelphij [pax], 1158268515Sdelphij [], 1159268515Sdelphij 1160268515Sdelphij [m4_fatal([Unknown tar format])]) 1161268515Sdelphij 1162268515Sdelphij AC_MSG_CHECKING([how to create a $1 tar archive]) 1163268515Sdelphij 1164268515Sdelphij # Go ahead even if we have the value already cached. We do so because we 1165268515Sdelphij # need to set the values for the 'am__tar' and 'am__untar' variables. 1166268515Sdelphij _am_tools=${am_cv_prog_tar_$1-$_am_tools} 1167268515Sdelphij 1168268515Sdelphij for _am_tool in $_am_tools; do 1169268515Sdelphij case $_am_tool in 1170268515Sdelphij gnutar) 1171268515Sdelphij for _am_tar in tar gnutar gtar; do 1172268515Sdelphij AM_RUN_LOG([$_am_tar --version]) && break 1173268515Sdelphij done 1174268515Sdelphij am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"' 1175268515Sdelphij am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"' 1176268515Sdelphij am__untar="$_am_tar -xf -" 1177268515Sdelphij ;; 1178268515Sdelphij plaintar) 1179268515Sdelphij # Must skip GNU tar: if it does not support --format= it doesn't create 1180268515Sdelphij # ustar tarball either. 1181268515Sdelphij (tar --version) >/dev/null 2>&1 && continue 1182268515Sdelphij am__tar='tar chf - "$$tardir"' 1183268515Sdelphij am__tar_='tar chf - "$tardir"' 1184268515Sdelphij am__untar='tar xf -' 1185268515Sdelphij ;; 1186268515Sdelphij pax) 1187268515Sdelphij am__tar='pax -L -x $1 -w "$$tardir"' 1188268515Sdelphij am__tar_='pax -L -x $1 -w "$tardir"' 1189268515Sdelphij am__untar='pax -r' 1190268515Sdelphij ;; 1191268515Sdelphij cpio) 1192268515Sdelphij am__tar='find "$$tardir" -print | cpio -o -H $1 -L' 1193268515Sdelphij am__tar_='find "$tardir" -print | cpio -o -H $1 -L' 1194268515Sdelphij am__untar='cpio -i -H $1 -d' 1195268515Sdelphij ;; 1196268515Sdelphij none) 1197268515Sdelphij am__tar=false 1198268515Sdelphij am__tar_=false 1199268515Sdelphij am__untar=false 1200268515Sdelphij ;; 1201268515Sdelphij esac 1202268515Sdelphij 1203268515Sdelphij # If the value was cached, stop now. We just wanted to have am__tar 1204268515Sdelphij # and am__untar set. 1205268515Sdelphij test -n "${am_cv_prog_tar_$1}" && break 1206268515Sdelphij 1207268515Sdelphij # tar/untar a dummy directory, and stop if the command works. 1208268515Sdelphij rm -rf conftest.dir 1209268515Sdelphij mkdir conftest.dir 1210268515Sdelphij echo GrepMe > conftest.dir/file 1211268515Sdelphij AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar]) 1212268515Sdelphij rm -rf conftest.dir 1213268515Sdelphij if test -s conftest.tar; then 1214268515Sdelphij AM_RUN_LOG([$am__untar <conftest.tar]) 1215268515Sdelphij AM_RUN_LOG([cat conftest.dir/file]) 1216268515Sdelphij grep GrepMe conftest.dir/file >/dev/null 2>&1 && break 1217268515Sdelphij fi 1218268515Sdelphij done 1219159764Sobrien rm -rf conftest.dir 1220133359Sobrien 1221268515Sdelphij AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool]) 1222268515Sdelphij AC_MSG_RESULT([$am_cv_prog_tar_$1])]) 1223268515Sdelphij 1224159764SobrienAC_SUBST([am__tar]) 1225159764SobrienAC_SUBST([am__untar]) 1226159764Sobrien]) # _AM_PROG_TAR 1227133359Sobrien 1228234449Sobrienm4_include([m4/libtool.m4]) 1229234449Sobrienm4_include([m4/ltoptions.m4]) 1230234449Sobrienm4_include([m4/ltsugar.m4]) 1231234449Sobrienm4_include([m4/ltversion.m4]) 1232234449Sobrienm4_include([m4/lt~obsolete.m4]) 1233159764Sobrienm4_include([acinclude.m4]) 1234