annotate aclocal.m4 @ 1536:cbacd38d4ec2

Remove commented-out code
author Adam Chlipala <adam@chlipala.net>
date Sun, 14 Aug 2011 09:31:53 -0400
parents 7770ef82c463
children e283ca05c829
rev   line source
adamc@1141 1 # generated automatically by aclocal 1.11.1 -*- Autoconf -*-
adamc@1141 2
adamc@1141 3 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
adamc@1141 4 # 2005, 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
adamc@1141 5 # This file is free software; the Free Software Foundation
adamc@1141 6 # gives unlimited permission to copy and/or distribute it,
adamc@1141 7 # with or without modifications, as long as this notice is preserved.
adamc@1141 8
adamc@1141 9 # This program is distributed in the hope that it will be useful,
adamc@1141 10 # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
adamc@1141 11 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
adamc@1141 12 # PARTICULAR PURPOSE.
adamc@1141 13
adamc@1141 14 m4_ifndef([AC_AUTOCONF_VERSION],
adamc@1141 15 [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
adam@1459 16 m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.68],,
adam@1459 17 [m4_warning([this file was generated for autoconf 2.68.
adamc@1141 18 You have another version of autoconf. It may work, but is not guaranteed to.
adamc@1141 19 If you have problems, you may need to regenerate the build system entirely.
adamc@1141 20 To do so, use the procedure documented by the package, typically `autoreconf'.])])
adamc@1141 21
adamc@1141 22 # Copyright (C) 2002, 2003, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
adamc@1141 23 #
adamc@1141 24 # This file is free software; the Free Software Foundation
adamc@1141 25 # gives unlimited permission to copy and/or distribute it,
adamc@1141 26 # with or without modifications, as long as this notice is preserved.
adamc@1141 27
adamc@1141 28 # AM_AUTOMAKE_VERSION(VERSION)
adamc@1141 29 # ----------------------------
adamc@1141 30 # Automake X.Y traces this macro to ensure aclocal.m4 has been
adamc@1141 31 # generated from the m4 files accompanying Automake X.Y.
adamc@1141 32 # (This private macro should not be called outside this file.)
adamc@1141 33 AC_DEFUN([AM_AUTOMAKE_VERSION],
adamc@1141 34 [am__api_version='1.11'
adamc@1141 35 dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to
adamc@1141 36 dnl require some minimum version. Point them to the right macro.
adamc@1141 37 m4_if([$1], [1.11.1], [],
adamc@1141 38 [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl
adamc@1141 39 ])
adamc@1141 40
adamc@1141 41 # _AM_AUTOCONF_VERSION(VERSION)
adamc@1141 42 # -----------------------------
adamc@1141 43 # aclocal traces this macro to find the Autoconf version.
adamc@1141 44 # This is a private macro too. Using m4_define simplifies
adamc@1141 45 # the logic in aclocal, which can simply ignore this definition.
adamc@1141 46 m4_define([_AM_AUTOCONF_VERSION], [])
adamc@1141 47
adamc@1141 48 # AM_SET_CURRENT_AUTOMAKE_VERSION
adamc@1141 49 # -------------------------------
adamc@1141 50 # Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced.
adamc@1141 51 # This function is AC_REQUIREd by AM_INIT_AUTOMAKE.
adamc@1141 52 AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
adamc@1141 53 [AM_AUTOMAKE_VERSION([1.11.1])dnl
adamc@1141 54 m4_ifndef([AC_AUTOCONF_VERSION],
adamc@1141 55 [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
adamc@1141 56 _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))])
adamc@1141 57
adamc@1141 58 # AM_AUX_DIR_EXPAND -*- Autoconf -*-
adamc@1141 59
adamc@1141 60 # Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc.
adamc@1141 61 #
adamc@1141 62 # This file is free software; the Free Software Foundation
adamc@1141 63 # gives unlimited permission to copy and/or distribute it,
adamc@1141 64 # with or without modifications, as long as this notice is preserved.
adamc@1141 65
adamc@1141 66 # For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets
adamc@1141 67 # $ac_aux_dir to `$srcdir/foo'. In other projects, it is set to
adamc@1141 68 # `$srcdir', `$srcdir/..', or `$srcdir/../..'.
adamc@1141 69 #
adamc@1141 70 # Of course, Automake must honor this variable whenever it calls a
adamc@1141 71 # tool from the auxiliary directory. The problem is that $srcdir (and
adamc@1141 72 # therefore $ac_aux_dir as well) can be either absolute or relative,
adamc@1141 73 # depending on how configure is run. This is pretty annoying, since
adamc@1141 74 # it makes $ac_aux_dir quite unusable in subdirectories: in the top
adamc@1141 75 # source directory, any form will work fine, but in subdirectories a
adamc@1141 76 # relative path needs to be adjusted first.
adamc@1141 77 #
adamc@1141 78 # $ac_aux_dir/missing
adamc@1141 79 # fails when called from a subdirectory if $ac_aux_dir is relative
adamc@1141 80 # $top_srcdir/$ac_aux_dir/missing
adamc@1141 81 # fails if $ac_aux_dir is absolute,
adamc@1141 82 # fails when called from a subdirectory in a VPATH build with
adamc@1141 83 # a relative $ac_aux_dir
adamc@1141 84 #
adamc@1141 85 # The reason of the latter failure is that $top_srcdir and $ac_aux_dir
adamc@1141 86 # are both prefixed by $srcdir. In an in-source build this is usually
adamc@1141 87 # harmless because $srcdir is `.', but things will broke when you
adamc@1141 88 # start a VPATH build or use an absolute $srcdir.
adamc@1141 89 #
adamc@1141 90 # So we could use something similar to $top_srcdir/$ac_aux_dir/missing,
adamc@1141 91 # iff we strip the leading $srcdir from $ac_aux_dir. That would be:
adamc@1141 92 # am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"`
adamc@1141 93 # and then we would define $MISSING as
adamc@1141 94 # MISSING="\${SHELL} $am_aux_dir/missing"
adamc@1141 95 # This will work as long as MISSING is not called from configure, because
adamc@1141 96 # unfortunately $(top_srcdir) has no meaning in configure.
adamc@1141 97 # However there are other variables, like CC, which are often used in
adamc@1141 98 # configure, and could therefore not use this "fixed" $ac_aux_dir.
adamc@1141 99 #
adamc@1141 100 # Another solution, used here, is to always expand $ac_aux_dir to an
adamc@1141 101 # absolute PATH. The drawback is that using absolute paths prevent a
adamc@1141 102 # configured tree to be moved without reconfiguration.
adamc@1141 103
adamc@1141 104 AC_DEFUN([AM_AUX_DIR_EXPAND],
adamc@1141 105 [dnl Rely on autoconf to set up CDPATH properly.
adamc@1141 106 AC_PREREQ([2.50])dnl
adamc@1141 107 # expand $ac_aux_dir to an absolute path
adamc@1141 108 am_aux_dir=`cd $ac_aux_dir && pwd`
adamc@1141 109 ])
adamc@1141 110
adamc@1141 111 # AM_CONDITIONAL -*- Autoconf -*-
adamc@1141 112
adamc@1141 113 # Copyright (C) 1997, 2000, 2001, 2003, 2004, 2005, 2006, 2008
adamc@1141 114 # Free Software Foundation, Inc.
adamc@1141 115 #
adamc@1141 116 # This file is free software; the Free Software Foundation
adamc@1141 117 # gives unlimited permission to copy and/or distribute it,
adamc@1141 118 # with or without modifications, as long as this notice is preserved.
adamc@1141 119
adamc@1141 120 # serial 9
adamc@1141 121
adamc@1141 122 # AM_CONDITIONAL(NAME, SHELL-CONDITION)
adamc@1141 123 # -------------------------------------
adamc@1141 124 # Define a conditional.
adamc@1141 125 AC_DEFUN([AM_CONDITIONAL],
adamc@1141 126 [AC_PREREQ(2.52)dnl
adamc@1141 127 ifelse([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])],
adamc@1141 128 [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl
adamc@1141 129 AC_SUBST([$1_TRUE])dnl
adamc@1141 130 AC_SUBST([$1_FALSE])dnl
adamc@1141 131 _AM_SUBST_NOTMAKE([$1_TRUE])dnl
adamc@1141 132 _AM_SUBST_NOTMAKE([$1_FALSE])dnl
adamc@1141 133 m4_define([_AM_COND_VALUE_$1], [$2])dnl
adamc@1141 134 if $2; then
adamc@1141 135 $1_TRUE=
adamc@1141 136 $1_FALSE='#'
adamc@1141 137 else
adamc@1141 138 $1_TRUE='#'
adamc@1141 139 $1_FALSE=
adamc@1141 140 fi
adamc@1141 141 AC_CONFIG_COMMANDS_PRE(
adamc@1141 142 [if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then
adamc@1141 143 AC_MSG_ERROR([[conditional "$1" was never defined.
adamc@1141 144 Usually this means the macro was only invoked conditionally.]])
adamc@1141 145 fi])])
adamc@1141 146
adamc@1141 147 # Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2009
adamc@1141 148 # Free Software Foundation, Inc.
adamc@1141 149 #
adamc@1141 150 # This file is free software; the Free Software Foundation
adamc@1141 151 # gives unlimited permission to copy and/or distribute it,
adamc@1141 152 # with or without modifications, as long as this notice is preserved.
adamc@1141 153
adamc@1141 154 # serial 10
adamc@1141 155
adamc@1141 156 # There are a few dirty hacks below to avoid letting `AC_PROG_CC' be
adamc@1141 157 # written in clear, in which case automake, when reading aclocal.m4,
adamc@1141 158 # will think it sees a *use*, and therefore will trigger all it's
adamc@1141 159 # C support machinery. Also note that it means that autoscan, seeing
adamc@1141 160 # CC etc. in the Makefile, will ask for an AC_PROG_CC use...
adamc@1141 161
adamc@1141 162
adamc@1141 163 # _AM_DEPENDENCIES(NAME)
adamc@1141 164 # ----------------------
adamc@1141 165 # See how the compiler implements dependency checking.
adamc@1141 166 # NAME is "CC", "CXX", "GCJ", or "OBJC".
adamc@1141 167 # We try a few techniques and use that to set a single cache variable.
adamc@1141 168 #
adamc@1141 169 # We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was
adamc@1141 170 # modified to invoke _AM_DEPENDENCIES(CC); we would have a circular
adamc@1141 171 # dependency, and given that the user is not expected to run this macro,
adamc@1141 172 # just rely on AC_PROG_CC.
adamc@1141 173 AC_DEFUN([_AM_DEPENDENCIES],
adamc@1141 174 [AC_REQUIRE([AM_SET_DEPDIR])dnl
adamc@1141 175 AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl
adamc@1141 176 AC_REQUIRE([AM_MAKE_INCLUDE])dnl
adamc@1141 177 AC_REQUIRE([AM_DEP_TRACK])dnl
adamc@1141 178
adamc@1141 179 ifelse([$1], CC, [depcc="$CC" am_compiler_list=],
adamc@1141 180 [$1], CXX, [depcc="$CXX" am_compiler_list=],
adamc@1141 181 [$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc'],
adamc@1141 182 [$1], UPC, [depcc="$UPC" am_compiler_list=],
adamc@1141 183 [$1], GCJ, [depcc="$GCJ" am_compiler_list='gcc3 gcc'],
adamc@1141 184 [depcc="$$1" am_compiler_list=])
adamc@1141 185
adamc@1141 186 AC_CACHE_CHECK([dependency style of $depcc],
adamc@1141 187 [am_cv_$1_dependencies_compiler_type],
adamc@1141 188 [if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
adamc@1141 189 # We make a subdir and do the tests there. Otherwise we can end up
adamc@1141 190 # making bogus files that we don't know about and never remove. For
adamc@1141 191 # instance it was reported that on HP-UX the gcc test will end up
adamc@1141 192 # making a dummy file named `D' -- because `-MD' means `put the output
adamc@1141 193 # in D'.
adamc@1141 194 mkdir conftest.dir
adamc@1141 195 # Copy depcomp to subdir because otherwise we won't find it if we're
adamc@1141 196 # using a relative directory.
adamc@1141 197 cp "$am_depcomp" conftest.dir
adamc@1141 198 cd conftest.dir
adamc@1141 199 # We will build objects and dependencies in a subdirectory because
adamc@1141 200 # it helps to detect inapplicable dependency modes. For instance
adamc@1141 201 # both Tru64's cc and ICC support -MD to output dependencies as a
adamc@1141 202 # side effect of compilation, but ICC will put the dependencies in
adamc@1141 203 # the current directory while Tru64 will put them in the object
adamc@1141 204 # directory.
adamc@1141 205 mkdir sub
adamc@1141 206
adamc@1141 207 am_cv_$1_dependencies_compiler_type=none
adamc@1141 208 if test "$am_compiler_list" = ""; then
adamc@1141 209 am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp`
adamc@1141 210 fi
adamc@1141 211 am__universal=false
adamc@1141 212 m4_case([$1], [CC],
adamc@1141 213 [case " $depcc " in #(
adamc@1141 214 *\ -arch\ *\ -arch\ *) am__universal=true ;;
adamc@1141 215 esac],
adamc@1141 216 [CXX],
adamc@1141 217 [case " $depcc " in #(
adamc@1141 218 *\ -arch\ *\ -arch\ *) am__universal=true ;;
adamc@1141 219 esac])
adamc@1141 220
adamc@1141 221 for depmode in $am_compiler_list; do
adamc@1141 222 # Setup a source with many dependencies, because some compilers
adamc@1141 223 # like to wrap large dependency lists on column 80 (with \), and
adamc@1141 224 # we should not choose a depcomp mode which is confused by this.
adamc@1141 225 #
adamc@1141 226 # We need to recreate these files for each test, as the compiler may
adamc@1141 227 # overwrite some of them when testing with obscure command lines.
adamc@1141 228 # This happens at least with the AIX C compiler.
adamc@1141 229 : > sub/conftest.c
adamc@1141 230 for i in 1 2 3 4 5 6; do
adamc@1141 231 echo '#include "conftst'$i'.h"' >> sub/conftest.c
adamc@1141 232 # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
adamc@1141 233 # Solaris 8's {/usr,}/bin/sh.
adamc@1141 234 touch sub/conftst$i.h
adamc@1141 235 done
adamc@1141 236 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
adamc@1141 237
adamc@1141 238 # We check with `-c' and `-o' for the sake of the "dashmstdout"
adamc@1141 239 # mode. It turns out that the SunPro C++ compiler does not properly
adamc@1141 240 # handle `-M -o', and we need to detect this. Also, some Intel
adamc@1141 241 # versions had trouble with output in subdirs
adamc@1141 242 am__obj=sub/conftest.${OBJEXT-o}
adamc@1141 243 am__minus_obj="-o $am__obj"
adamc@1141 244 case $depmode in
adamc@1141 245 gcc)
adamc@1141 246 # This depmode causes a compiler race in universal mode.
adamc@1141 247 test "$am__universal" = false || continue
adamc@1141 248 ;;
adamc@1141 249 nosideeffect)
adamc@1141 250 # after this tag, mechanisms are not by side-effect, so they'll
adamc@1141 251 # only be used when explicitly requested
adamc@1141 252 if test "x$enable_dependency_tracking" = xyes; then
adamc@1141 253 continue
adamc@1141 254 else
adamc@1141 255 break
adamc@1141 256 fi
adamc@1141 257 ;;
adamc@1141 258 msvisualcpp | msvcmsys)
adamc@1141 259 # This compiler won't grok `-c -o', but also, the minuso test has
adamc@1141 260 # not run yet. These depmodes are late enough in the game, and
adamc@1141 261 # so weak that their functioning should not be impacted.
adamc@1141 262 am__obj=conftest.${OBJEXT-o}
adamc@1141 263 am__minus_obj=
adamc@1141 264 ;;
adamc@1141 265 none) break ;;
adamc@1141 266 esac
adamc@1141 267 if depmode=$depmode \
adamc@1141 268 source=sub/conftest.c object=$am__obj \
adamc@1141 269 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
adamc@1141 270 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
adamc@1141 271 >/dev/null 2>conftest.err &&
adamc@1141 272 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
adamc@1141 273 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
adamc@1141 274 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
adamc@1141 275 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
adamc@1141 276 # icc doesn't choke on unknown options, it will just issue warnings
adamc@1141 277 # or remarks (even with -Werror). So we grep stderr for any message
adamc@1141 278 # that says an option was ignored or not supported.
adamc@1141 279 # When given -MP, icc 7.0 and 7.1 complain thusly:
adamc@1141 280 # icc: Command line warning: ignoring option '-M'; no argument required
adamc@1141 281 # The diagnosis changed in icc 8.0:
adamc@1141 282 # icc: Command line remark: option '-MP' not supported
adamc@1141 283 if (grep 'ignoring option' conftest.err ||
adamc@1141 284 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
adamc@1141 285 am_cv_$1_dependencies_compiler_type=$depmode
adamc@1141 286 break
adamc@1141 287 fi
adamc@1141 288 fi
adamc@1141 289 done
adamc@1141 290
adamc@1141 291 cd ..
adamc@1141 292 rm -rf conftest.dir
adamc@1141 293 else
adamc@1141 294 am_cv_$1_dependencies_compiler_type=none
adamc@1141 295 fi
adamc@1141 296 ])
adamc@1141 297 AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type])
adamc@1141 298 AM_CONDITIONAL([am__fastdep$1], [
adamc@1141 299 test "x$enable_dependency_tracking" != xno \
adamc@1141 300 && test "$am_cv_$1_dependencies_compiler_type" = gcc3])
adamc@1141 301 ])
adamc@1141 302
adamc@1141 303
adamc@1141 304 # AM_SET_DEPDIR
adamc@1141 305 # -------------
adamc@1141 306 # Choose a directory name for dependency files.
adamc@1141 307 # This macro is AC_REQUIREd in _AM_DEPENDENCIES
adamc@1141 308 AC_DEFUN([AM_SET_DEPDIR],
adamc@1141 309 [AC_REQUIRE([AM_SET_LEADING_DOT])dnl
adamc@1141 310 AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl
adamc@1141 311 ])
adamc@1141 312
adamc@1141 313
adamc@1141 314 # AM_DEP_TRACK
adamc@1141 315 # ------------
adamc@1141 316 AC_DEFUN([AM_DEP_TRACK],
adamc@1141 317 [AC_ARG_ENABLE(dependency-tracking,
adamc@1141 318 [ --disable-dependency-tracking speeds up one-time build
adamc@1141 319 --enable-dependency-tracking do not reject slow dependency extractors])
adamc@1141 320 if test "x$enable_dependency_tracking" != xno; then
adamc@1141 321 am_depcomp="$ac_aux_dir/depcomp"
adamc@1141 322 AMDEPBACKSLASH='\'
adamc@1141 323 fi
adamc@1141 324 AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno])
adamc@1141 325 AC_SUBST([AMDEPBACKSLASH])dnl
adamc@1141 326 _AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl
adamc@1141 327 ])
adamc@1141 328
adamc@1141 329 # Generate code to set up dependency tracking. -*- Autoconf -*-
adamc@1141 330
adamc@1141 331 # Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2008
adamc@1141 332 # Free Software Foundation, Inc.
adamc@1141 333 #
adamc@1141 334 # This file is free software; the Free Software Foundation
adamc@1141 335 # gives unlimited permission to copy and/or distribute it,
adamc@1141 336 # with or without modifications, as long as this notice is preserved.
adamc@1141 337
adamc@1141 338 #serial 5
adamc@1141 339
adamc@1141 340 # _AM_OUTPUT_DEPENDENCY_COMMANDS
adamc@1141 341 # ------------------------------
adamc@1141 342 AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
adamc@1141 343 [{
adamc@1141 344 # Autoconf 2.62 quotes --file arguments for eval, but not when files
adamc@1141 345 # are listed without --file. Let's play safe and only enable the eval
adamc@1141 346 # if we detect the quoting.
adamc@1141 347 case $CONFIG_FILES in
adamc@1141 348 *\'*) eval set x "$CONFIG_FILES" ;;
adamc@1141 349 *) set x $CONFIG_FILES ;;
adamc@1141 350 esac
adamc@1141 351 shift
adamc@1141 352 for mf
adamc@1141 353 do
adamc@1141 354 # Strip MF so we end up with the name of the file.
adamc@1141 355 mf=`echo "$mf" | sed -e 's/:.*$//'`
adamc@1141 356 # Check whether this is an Automake generated Makefile or not.
adamc@1141 357 # We used to match only the files named `Makefile.in', but
adamc@1141 358 # some people rename them; so instead we look at the file content.
adamc@1141 359 # Grep'ing the first line is not enough: some people post-process
adamc@1141 360 # each Makefile.in and add a new line on top of each file to say so.
adamc@1141 361 # Grep'ing the whole file is not good either: AIX grep has a line
adamc@1141 362 # limit of 2048, but all sed's we know have understand at least 4000.
adamc@1141 363 if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
adamc@1141 364 dirpart=`AS_DIRNAME("$mf")`
adamc@1141 365 else
adamc@1141 366 continue
adamc@1141 367 fi
adamc@1141 368 # Extract the definition of DEPDIR, am__include, and am__quote
adamc@1141 369 # from the Makefile without running `make'.
adamc@1141 370 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
adamc@1141 371 test -z "$DEPDIR" && continue
adamc@1141 372 am__include=`sed -n 's/^am__include = //p' < "$mf"`
adamc@1141 373 test -z "am__include" && continue
adamc@1141 374 am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
adamc@1141 375 # When using ansi2knr, U may be empty or an underscore; expand it
adamc@1141 376 U=`sed -n 's/^U = //p' < "$mf"`
adamc@1141 377 # Find all dependency output files, they are included files with
adamc@1141 378 # $(DEPDIR) in their names. We invoke sed twice because it is the
adamc@1141 379 # simplest approach to changing $(DEPDIR) to its actual value in the
adamc@1141 380 # expansion.
adamc@1141 381 for file in `sed -n "
adamc@1141 382 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
adamc@1141 383 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
adamc@1141 384 # Make sure the directory exists.
adamc@1141 385 test -f "$dirpart/$file" && continue
adamc@1141 386 fdir=`AS_DIRNAME(["$file"])`
adamc@1141 387 AS_MKDIR_P([$dirpart/$fdir])
adamc@1141 388 # echo "creating $dirpart/$file"
adamc@1141 389 echo '# dummy' > "$dirpart/$file"
adamc@1141 390 done
adamc@1141 391 done
adamc@1141 392 }
adamc@1141 393 ])# _AM_OUTPUT_DEPENDENCY_COMMANDS
adamc@1141 394
adamc@1141 395
adamc@1141 396 # AM_OUTPUT_DEPENDENCY_COMMANDS
adamc@1141 397 # -----------------------------
adamc@1141 398 # This macro should only be invoked once -- use via AC_REQUIRE.
adamc@1141 399 #
adamc@1141 400 # This code is only required when automatic dependency tracking
adamc@1141 401 # is enabled. FIXME. This creates each `.P' file that we will
adamc@1141 402 # need in order to bootstrap the dependency handling code.
adamc@1141 403 AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
adamc@1141 404 [AC_CONFIG_COMMANDS([depfiles],
adamc@1141 405 [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS],
adamc@1141 406 [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"])
adamc@1141 407 ])
adamc@1141 408
adamc@1141 409 # Do all the work for Automake. -*- Autoconf -*-
adamc@1141 410
adamc@1141 411 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
adamc@1141 412 # 2005, 2006, 2008, 2009 Free Software Foundation, Inc.
adamc@1141 413 #
adamc@1141 414 # This file is free software; the Free Software Foundation
adamc@1141 415 # gives unlimited permission to copy and/or distribute it,
adamc@1141 416 # with or without modifications, as long as this notice is preserved.
adamc@1141 417
adamc@1141 418 # serial 16
adamc@1141 419
adamc@1141 420 # This macro actually does too much. Some checks are only needed if
adamc@1141 421 # your package does certain things. But this isn't really a big deal.
adamc@1141 422
adamc@1141 423 # AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE])
adamc@1141 424 # AM_INIT_AUTOMAKE([OPTIONS])
adamc@1141 425 # -----------------------------------------------
adamc@1141 426 # The call with PACKAGE and VERSION arguments is the old style
adamc@1141 427 # call (pre autoconf-2.50), which is being phased out. PACKAGE
adamc@1141 428 # and VERSION should now be passed to AC_INIT and removed from
adamc@1141 429 # the call to AM_INIT_AUTOMAKE.
adamc@1141 430 # We support both call styles for the transition. After
adamc@1141 431 # the next Automake release, Autoconf can make the AC_INIT
adamc@1141 432 # arguments mandatory, and then we can depend on a new Autoconf
adamc@1141 433 # release and drop the old call support.
adamc@1141 434 AC_DEFUN([AM_INIT_AUTOMAKE],
adamc@1141 435 [AC_PREREQ([2.62])dnl
adamc@1141 436 dnl Autoconf wants to disallow AM_ names. We explicitly allow
adamc@1141 437 dnl the ones we care about.
adamc@1141 438 m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
adamc@1141 439 AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl
adamc@1141 440 AC_REQUIRE([AC_PROG_INSTALL])dnl
adamc@1141 441 if test "`cd $srcdir && pwd`" != "`pwd`"; then
adamc@1141 442 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
adamc@1141 443 # is not polluted with repeated "-I."
adamc@1141 444 AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl
adamc@1141 445 # test to see if srcdir already configured
adamc@1141 446 if test -f $srcdir/config.status; then
adamc@1141 447 AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
adamc@1141 448 fi
adamc@1141 449 fi
adamc@1141 450
adamc@1141 451 # test whether we have cygpath
adamc@1141 452 if test -z "$CYGPATH_W"; then
adamc@1141 453 if (cygpath --version) >/dev/null 2>/dev/null; then
adamc@1141 454 CYGPATH_W='cygpath -w'
adamc@1141 455 else
adamc@1141 456 CYGPATH_W=echo
adamc@1141 457 fi
adamc@1141 458 fi
adamc@1141 459 AC_SUBST([CYGPATH_W])
adamc@1141 460
adamc@1141 461 # Define the identity of the package.
adamc@1141 462 dnl Distinguish between old-style and new-style calls.
adamc@1141 463 m4_ifval([$2],
adamc@1141 464 [m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl
adamc@1141 465 AC_SUBST([PACKAGE], [$1])dnl
adamc@1141 466 AC_SUBST([VERSION], [$2])],
adamc@1141 467 [_AM_SET_OPTIONS([$1])dnl
adamc@1141 468 dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT.
adamc@1141 469 m4_if(m4_ifdef([AC_PACKAGE_NAME], 1)m4_ifdef([AC_PACKAGE_VERSION], 1), 11,,
adamc@1141 470 [m4_fatal([AC_INIT should be called with package and version arguments])])dnl
adamc@1141 471 AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl
adamc@1141 472 AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl
adamc@1141 473
adamc@1141 474 _AM_IF_OPTION([no-define],,
adamc@1141 475 [AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
adamc@1141 476 AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl
adamc@1141 477
adamc@1141 478 # Some tools Automake needs.
adamc@1141 479 AC_REQUIRE([AM_SANITY_CHECK])dnl
adamc@1141 480 AC_REQUIRE([AC_ARG_PROGRAM])dnl
adamc@1141 481 AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version})
adamc@1141 482 AM_MISSING_PROG(AUTOCONF, autoconf)
adamc@1141 483 AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version})
adamc@1141 484 AM_MISSING_PROG(AUTOHEADER, autoheader)
adamc@1141 485 AM_MISSING_PROG(MAKEINFO, makeinfo)
adamc@1141 486 AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
adamc@1141 487 AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl
adamc@1141 488 AC_REQUIRE([AM_PROG_MKDIR_P])dnl
adamc@1141 489 # We need awk for the "check" target. The system "awk" is bad on
adamc@1141 490 # some platforms.
adamc@1141 491 AC_REQUIRE([AC_PROG_AWK])dnl
adamc@1141 492 AC_REQUIRE([AC_PROG_MAKE_SET])dnl
adamc@1141 493 AC_REQUIRE([AM_SET_LEADING_DOT])dnl
adamc@1141 494 _AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])],
adamc@1141 495 [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])],
adamc@1141 496 [_AM_PROG_TAR([v7])])])
adamc@1141 497 _AM_IF_OPTION([no-dependencies],,
adamc@1141 498 [AC_PROVIDE_IFELSE([AC_PROG_CC],
adamc@1141 499 [_AM_DEPENDENCIES(CC)],
adamc@1141 500 [define([AC_PROG_CC],
adamc@1141 501 defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl
adamc@1141 502 AC_PROVIDE_IFELSE([AC_PROG_CXX],
adamc@1141 503 [_AM_DEPENDENCIES(CXX)],
adamc@1141 504 [define([AC_PROG_CXX],
adamc@1141 505 defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl
adamc@1141 506 AC_PROVIDE_IFELSE([AC_PROG_OBJC],
adamc@1141 507 [_AM_DEPENDENCIES(OBJC)],
adamc@1141 508 [define([AC_PROG_OBJC],
adamc@1141 509 defn([AC_PROG_OBJC])[_AM_DEPENDENCIES(OBJC)])])dnl
adamc@1141 510 ])
adamc@1141 511 _AM_IF_OPTION([silent-rules], [AC_REQUIRE([AM_SILENT_RULES])])dnl
adamc@1141 512 dnl The `parallel-tests' driver may need to know about EXEEXT, so add the
adamc@1141 513 dnl `am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This macro
adamc@1141 514 dnl is hooked onto _AC_COMPILER_EXEEXT early, see below.
adamc@1141 515 AC_CONFIG_COMMANDS_PRE(dnl
adamc@1141 516 [m4_provide_if([_AM_COMPILER_EXEEXT],
adamc@1141 517 [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl
adamc@1141 518 ])
adamc@1141 519
adamc@1141 520 dnl Hook into `_AC_COMPILER_EXEEXT' early to learn its expansion. Do not
adamc@1141 521 dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further
adamc@1141 522 dnl mangled by Autoconf and run in a shell conditional statement.
adamc@1141 523 m4_define([_AC_COMPILER_EXEEXT],
adamc@1141 524 m4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])])
adamc@1141 525
adamc@1141 526
adamc@1141 527 # When config.status generates a header, we must update the stamp-h file.
adamc@1141 528 # This file resides in the same directory as the config header
adamc@1141 529 # that is generated. The stamp files are numbered to have different names.
adamc@1141 530
adamc@1141 531 # Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the
adamc@1141 532 # loop where config.status creates the headers, so we can generate
adamc@1141 533 # our stamp files there.
adamc@1141 534 AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK],
adamc@1141 535 [# Compute $1's index in $config_headers.
adamc@1141 536 _am_arg=$1
adamc@1141 537 _am_stamp_count=1
adamc@1141 538 for _am_header in $config_headers :; do
adamc@1141 539 case $_am_header in
adamc@1141 540 $_am_arg | $_am_arg:* )
adamc@1141 541 break ;;
adamc@1141 542 * )
adamc@1141 543 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
adamc@1141 544 esac
adamc@1141 545 done
adamc@1141 546 echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count])
adamc@1141 547
adamc@1141 548 # Copyright (C) 2001, 2003, 2005, 2008 Free Software Foundation, Inc.
adamc@1141 549 #
adamc@1141 550 # This file is free software; the Free Software Foundation
adamc@1141 551 # gives unlimited permission to copy and/or distribute it,
adamc@1141 552 # with or without modifications, as long as this notice is preserved.
adamc@1141 553
adamc@1141 554 # AM_PROG_INSTALL_SH
adamc@1141 555 # ------------------
adamc@1141 556 # Define $install_sh.
adamc@1141 557 AC_DEFUN([AM_PROG_INSTALL_SH],
adamc@1141 558 [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
adamc@1141 559 if test x"${install_sh}" != xset; then
adamc@1141 560 case $am_aux_dir in
adamc@1141 561 *\ * | *\ *)
adamc@1141 562 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
adamc@1141 563 *)
adamc@1141 564 install_sh="\${SHELL} $am_aux_dir/install-sh"
adamc@1141 565 esac
adamc@1141 566 fi
adamc@1141 567 AC_SUBST(install_sh)])
adamc@1141 568
adamc@1141 569 # Copyright (C) 2003, 2005 Free Software Foundation, Inc.
adamc@1141 570 #
adamc@1141 571 # This file is free software; the Free Software Foundation
adamc@1141 572 # gives unlimited permission to copy and/or distribute it,
adamc@1141 573 # with or without modifications, as long as this notice is preserved.
adamc@1141 574
adamc@1141 575 # serial 2
adamc@1141 576
adamc@1141 577 # Check whether the underlying file-system supports filenames
adamc@1141 578 # with a leading dot. For instance MS-DOS doesn't.
adamc@1141 579 AC_DEFUN([AM_SET_LEADING_DOT],
adamc@1141 580 [rm -rf .tst 2>/dev/null
adamc@1141 581 mkdir .tst 2>/dev/null
adamc@1141 582 if test -d .tst; then
adamc@1141 583 am__leading_dot=.
adamc@1141 584 else
adamc@1141 585 am__leading_dot=_
adamc@1141 586 fi
adamc@1141 587 rmdir .tst 2>/dev/null
adamc@1141 588 AC_SUBST([am__leading_dot])])
adamc@1141 589
adamc@1141 590 # Check to see how 'make' treats includes. -*- Autoconf -*-
adamc@1141 591
adamc@1141 592 # Copyright (C) 2001, 2002, 2003, 2005, 2009 Free Software Foundation, Inc.
adamc@1141 593 #
adamc@1141 594 # This file is free software; the Free Software Foundation
adamc@1141 595 # gives unlimited permission to copy and/or distribute it,
adamc@1141 596 # with or without modifications, as long as this notice is preserved.
adamc@1141 597
adamc@1141 598 # serial 4
adamc@1141 599
adamc@1141 600 # AM_MAKE_INCLUDE()
adamc@1141 601 # -----------------
adamc@1141 602 # Check to see how make treats includes.
adamc@1141 603 AC_DEFUN([AM_MAKE_INCLUDE],
adamc@1141 604 [am_make=${MAKE-make}
adamc@1141 605 cat > confinc << 'END'
adamc@1141 606 am__doit:
adamc@1141 607 @echo this is the am__doit target
adamc@1141 608 .PHONY: am__doit
adamc@1141 609 END
adamc@1141 610 # If we don't find an include directive, just comment out the code.
adamc@1141 611 AC_MSG_CHECKING([for style of include used by $am_make])
adamc@1141 612 am__include="#"
adamc@1141 613 am__quote=
adamc@1141 614 _am_result=none
adamc@1141 615 # First try GNU make style include.
adamc@1141 616 echo "include confinc" > confmf
adamc@1141 617 # Ignore all kinds of additional output from `make'.
adamc@1141 618 case `$am_make -s -f confmf 2> /dev/null` in #(
adamc@1141 619 *the\ am__doit\ target*)
adamc@1141 620 am__include=include
adamc@1141 621 am__quote=
adamc@1141 622 _am_result=GNU
adamc@1141 623 ;;
adamc@1141 624 esac
adamc@1141 625 # Now try BSD make style include.
adamc@1141 626 if test "$am__include" = "#"; then
adamc@1141 627 echo '.include "confinc"' > confmf
adamc@1141 628 case `$am_make -s -f confmf 2> /dev/null` in #(
adamc@1141 629 *the\ am__doit\ target*)
adamc@1141 630 am__include=.include
adamc@1141 631 am__quote="\""
adamc@1141 632 _am_result=BSD
adamc@1141 633 ;;
adamc@1141 634 esac
adamc@1141 635 fi
adamc@1141 636 AC_SUBST([am__include])
adamc@1141 637 AC_SUBST([am__quote])
adamc@1141 638 AC_MSG_RESULT([$_am_result])
adamc@1141 639 rm -f confinc confmf
adamc@1141 640 ])
adamc@1141 641
adamc@1141 642 # Fake the existence of programs that GNU maintainers use. -*- Autoconf -*-
adamc@1141 643
adamc@1141 644 # Copyright (C) 1997, 1999, 2000, 2001, 2003, 2004, 2005, 2008
adamc@1141 645 # Free Software Foundation, Inc.
adamc@1141 646 #
adamc@1141 647 # This file is free software; the Free Software Foundation
adamc@1141 648 # gives unlimited permission to copy and/or distribute it,
adamc@1141 649 # with or without modifications, as long as this notice is preserved.
adamc@1141 650
adamc@1141 651 # serial 6
adamc@1141 652
adamc@1141 653 # AM_MISSING_PROG(NAME, PROGRAM)
adamc@1141 654 # ------------------------------
adamc@1141 655 AC_DEFUN([AM_MISSING_PROG],
adamc@1141 656 [AC_REQUIRE([AM_MISSING_HAS_RUN])
adamc@1141 657 $1=${$1-"${am_missing_run}$2"}
adamc@1141 658 AC_SUBST($1)])
adamc@1141 659
adamc@1141 660
adamc@1141 661 # AM_MISSING_HAS_RUN
adamc@1141 662 # ------------------
adamc@1141 663 # Define MISSING if not defined so far and test if it supports --run.
adamc@1141 664 # If it does, set am_missing_run to use it, otherwise, to nothing.
adamc@1141 665 AC_DEFUN([AM_MISSING_HAS_RUN],
adamc@1141 666 [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
adamc@1141 667 AC_REQUIRE_AUX_FILE([missing])dnl
adamc@1141 668 if test x"${MISSING+set}" != xset; then
adamc@1141 669 case $am_aux_dir in
adamc@1141 670 *\ * | *\ *)
adamc@1141 671 MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
adamc@1141 672 *)
adamc@1141 673 MISSING="\${SHELL} $am_aux_dir/missing" ;;
adamc@1141 674 esac
adamc@1141 675 fi
adamc@1141 676 # Use eval to expand $SHELL
adamc@1141 677 if eval "$MISSING --run true"; then
adamc@1141 678 am_missing_run="$MISSING --run "
adamc@1141 679 else
adamc@1141 680 am_missing_run=
adamc@1141 681 AC_MSG_WARN([`missing' script is too old or missing])
adamc@1141 682 fi
adamc@1141 683 ])
adamc@1141 684
adamc@1141 685 # Copyright (C) 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
adamc@1141 686 #
adamc@1141 687 # This file is free software; the Free Software Foundation
adamc@1141 688 # gives unlimited permission to copy and/or distribute it,
adamc@1141 689 # with or without modifications, as long as this notice is preserved.
adamc@1141 690
adamc@1141 691 # AM_PROG_MKDIR_P
adamc@1141 692 # ---------------
adamc@1141 693 # Check for `mkdir -p'.
adamc@1141 694 AC_DEFUN([AM_PROG_MKDIR_P],
adamc@1141 695 [AC_PREREQ([2.60])dnl
adamc@1141 696 AC_REQUIRE([AC_PROG_MKDIR_P])dnl
adamc@1141 697 dnl Automake 1.8 to 1.9.6 used to define mkdir_p. We now use MKDIR_P,
adamc@1141 698 dnl while keeping a definition of mkdir_p for backward compatibility.
adamc@1141 699 dnl @MKDIR_P@ is magic: AC_OUTPUT adjusts its value for each Makefile.
adamc@1141 700 dnl However we cannot define mkdir_p as $(MKDIR_P) for the sake of
adamc@1141 701 dnl Makefile.ins that do not define MKDIR_P, so we do our own
adamc@1141 702 dnl adjustment using top_builddir (which is defined more often than
adamc@1141 703 dnl MKDIR_P).
adamc@1141 704 AC_SUBST([mkdir_p], ["$MKDIR_P"])dnl
adamc@1141 705 case $mkdir_p in
adamc@1141 706 [[\\/$]]* | ?:[[\\/]]*) ;;
adamc@1141 707 */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
adamc@1141 708 esac
adamc@1141 709 ])
adamc@1141 710
adamc@1141 711 # Helper functions for option handling. -*- Autoconf -*-
adamc@1141 712
adamc@1141 713 # Copyright (C) 2001, 2002, 2003, 2005, 2008 Free Software Foundation, Inc.
adamc@1141 714 #
adamc@1141 715 # This file is free software; the Free Software Foundation
adamc@1141 716 # gives unlimited permission to copy and/or distribute it,
adamc@1141 717 # with or without modifications, as long as this notice is preserved.
adamc@1141 718
adamc@1141 719 # serial 4
adamc@1141 720
adamc@1141 721 # _AM_MANGLE_OPTION(NAME)
adamc@1141 722 # -----------------------
adamc@1141 723 AC_DEFUN([_AM_MANGLE_OPTION],
adamc@1141 724 [[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])])
adamc@1141 725
adamc@1141 726 # _AM_SET_OPTION(NAME)
adamc@1141 727 # ------------------------------
adamc@1141 728 # Set option NAME. Presently that only means defining a flag for this option.
adamc@1141 729 AC_DEFUN([_AM_SET_OPTION],
adamc@1141 730 [m4_define(_AM_MANGLE_OPTION([$1]), 1)])
adamc@1141 731
adamc@1141 732 # _AM_SET_OPTIONS(OPTIONS)
adamc@1141 733 # ----------------------------------
adamc@1141 734 # OPTIONS is a space-separated list of Automake options.
adamc@1141 735 AC_DEFUN([_AM_SET_OPTIONS],
adamc@1141 736 [m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])])
adamc@1141 737
adamc@1141 738 # _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET])
adamc@1141 739 # -------------------------------------------
adamc@1141 740 # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
adamc@1141 741 AC_DEFUN([_AM_IF_OPTION],
adamc@1141 742 [m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
adamc@1141 743
adamc@1141 744 # Check to make sure that the build environment is sane. -*- Autoconf -*-
adamc@1141 745
adamc@1141 746 # Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005, 2008
adamc@1141 747 # Free Software Foundation, Inc.
adamc@1141 748 #
adamc@1141 749 # This file is free software; the Free Software Foundation
adamc@1141 750 # gives unlimited permission to copy and/or distribute it,
adamc@1141 751 # with or without modifications, as long as this notice is preserved.
adamc@1141 752
adamc@1141 753 # serial 5
adamc@1141 754
adamc@1141 755 # AM_SANITY_CHECK
adamc@1141 756 # ---------------
adamc@1141 757 AC_DEFUN([AM_SANITY_CHECK],
adamc@1141 758 [AC_MSG_CHECKING([whether build environment is sane])
adamc@1141 759 # Just in case
adamc@1141 760 sleep 1
adamc@1141 761 echo timestamp > conftest.file
adamc@1141 762 # Reject unsafe characters in $srcdir or the absolute working directory
adamc@1141 763 # name. Accept space and tab only in the latter.
adamc@1141 764 am_lf='
adamc@1141 765 '
adamc@1141 766 case `pwd` in
adamc@1141 767 *[[\\\"\#\$\&\'\`$am_lf]]*)
adamc@1141 768 AC_MSG_ERROR([unsafe absolute working directory name]);;
adamc@1141 769 esac
adamc@1141 770 case $srcdir in
adamc@1141 771 *[[\\\"\#\$\&\'\`$am_lf\ \ ]]*)
adamc@1141 772 AC_MSG_ERROR([unsafe srcdir value: `$srcdir']);;
adamc@1141 773 esac
adamc@1141 774
adamc@1141 775 # Do `set' in a subshell so we don't clobber the current shell's
adamc@1141 776 # arguments. Must try -L first in case configure is actually a
adamc@1141 777 # symlink; some systems play weird games with the mod time of symlinks
adamc@1141 778 # (eg FreeBSD returns the mod time of the symlink's containing
adamc@1141 779 # directory).
adamc@1141 780 if (
adamc@1141 781 set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
adamc@1141 782 if test "$[*]" = "X"; then
adamc@1141 783 # -L didn't work.
adamc@1141 784 set X `ls -t "$srcdir/configure" conftest.file`
adamc@1141 785 fi
adamc@1141 786 rm -f conftest.file
adamc@1141 787 if test "$[*]" != "X $srcdir/configure conftest.file" \
adamc@1141 788 && test "$[*]" != "X conftest.file $srcdir/configure"; then
adamc@1141 789
adamc@1141 790 # If neither matched, then we have a broken ls. This can happen
adamc@1141 791 # if, for instance, CONFIG_SHELL is bash and it inherits a
adamc@1141 792 # broken ls alias from the environment. This has actually
adamc@1141 793 # happened. Such a system could not be considered "sane".
adamc@1141 794 AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken
adamc@1141 795 alias in your environment])
adamc@1141 796 fi
adamc@1141 797
adamc@1141 798 test "$[2]" = conftest.file
adamc@1141 799 )
adamc@1141 800 then
adamc@1141 801 # Ok.
adamc@1141 802 :
adamc@1141 803 else
adamc@1141 804 AC_MSG_ERROR([newly created file is older than distributed files!
adamc@1141 805 Check your system clock])
adamc@1141 806 fi
adamc@1141 807 AC_MSG_RESULT(yes)])
adamc@1141 808
adamc@1141 809 # Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc.
adamc@1141 810 #
adamc@1141 811 # This file is free software; the Free Software Foundation
adamc@1141 812 # gives unlimited permission to copy and/or distribute it,
adamc@1141 813 # with or without modifications, as long as this notice is preserved.
adamc@1141 814
adamc@1141 815 # AM_PROG_INSTALL_STRIP
adamc@1141 816 # ---------------------
adamc@1141 817 # One issue with vendor `install' (even GNU) is that you can't
adamc@1141 818 # specify the program used to strip binaries. This is especially
adamc@1141 819 # annoying in cross-compiling environments, where the build's strip
adamc@1141 820 # is unlikely to handle the host's binaries.
adamc@1141 821 # Fortunately install-sh will honor a STRIPPROG variable, so we
adamc@1141 822 # always use install-sh in `make install-strip', and initialize
adamc@1141 823 # STRIPPROG with the value of the STRIP variable (set by the user).
adamc@1141 824 AC_DEFUN([AM_PROG_INSTALL_STRIP],
adamc@1141 825 [AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
adamc@1141 826 # Installed binaries are usually stripped using `strip' when the user
adamc@1141 827 # run `make install-strip'. However `strip' might not be the right
adamc@1141 828 # tool to use in cross-compilation environments, therefore Automake
adamc@1141 829 # will honor the `STRIP' environment variable to overrule this program.
adamc@1141 830 dnl Don't test for $cross_compiling = yes, because it might be `maybe'.
adamc@1141 831 if test "$cross_compiling" != no; then
adamc@1141 832 AC_CHECK_TOOL([STRIP], [strip], :)
adamc@1141 833 fi
adamc@1141 834 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
adamc@1141 835 AC_SUBST([INSTALL_STRIP_PROGRAM])])
adamc@1141 836
adamc@1141 837 # Copyright (C) 2006, 2008 Free Software Foundation, Inc.
adamc@1141 838 #
adamc@1141 839 # This file is free software; the Free Software Foundation
adamc@1141 840 # gives unlimited permission to copy and/or distribute it,
adamc@1141 841 # with or without modifications, as long as this notice is preserved.
adamc@1141 842
adamc@1141 843 # serial 2
adamc@1141 844
adamc@1141 845 # _AM_SUBST_NOTMAKE(VARIABLE)
adamc@1141 846 # ---------------------------
adamc@1141 847 # Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in.
adamc@1141 848 # This macro is traced by Automake.
adamc@1141 849 AC_DEFUN([_AM_SUBST_NOTMAKE])
adamc@1141 850
adamc@1141 851 # AM_SUBST_NOTMAKE(VARIABLE)
adamc@1141 852 # ---------------------------
adamc@1141 853 # Public sister of _AM_SUBST_NOTMAKE.
adamc@1141 854 AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)])
adamc@1141 855
adamc@1141 856 # Check how to create a tarball. -*- Autoconf -*-
adamc@1141 857
adamc@1141 858 # Copyright (C) 2004, 2005 Free Software Foundation, Inc.
adamc@1141 859 #
adamc@1141 860 # This file is free software; the Free Software Foundation
adamc@1141 861 # gives unlimited permission to copy and/or distribute it,
adamc@1141 862 # with or without modifications, as long as this notice is preserved.
adamc@1141 863
adamc@1141 864 # serial 2
adamc@1141 865
adamc@1141 866 # _AM_PROG_TAR(FORMAT)
adamc@1141 867 # --------------------
adamc@1141 868 # Check how to create a tarball in format FORMAT.
adamc@1141 869 # FORMAT should be one of `v7', `ustar', or `pax'.
adamc@1141 870 #
adamc@1141 871 # Substitute a variable $(am__tar) that is a command
adamc@1141 872 # writing to stdout a FORMAT-tarball containing the directory
adamc@1141 873 # $tardir.
adamc@1141 874 # tardir=directory && $(am__tar) > result.tar
adamc@1141 875 #
adamc@1141 876 # Substitute a variable $(am__untar) that extract such
adamc@1141 877 # a tarball read from stdin.
adamc@1141 878 # $(am__untar) < result.tar
adamc@1141 879 AC_DEFUN([_AM_PROG_TAR],
adamc@1141 880 [# Always define AMTAR for backward compatibility.
adamc@1141 881 AM_MISSING_PROG([AMTAR], [tar])
adamc@1141 882 m4_if([$1], [v7],
adamc@1141 883 [am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'],
adamc@1141 884 [m4_case([$1], [ustar],, [pax],,
adamc@1141 885 [m4_fatal([Unknown tar format])])
adamc@1141 886 AC_MSG_CHECKING([how to create a $1 tar archive])
adamc@1141 887 # Loop over all known methods to create a tar archive until one works.
adamc@1141 888 _am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none'
adamc@1141 889 _am_tools=${am_cv_prog_tar_$1-$_am_tools}
adamc@1141 890 # Do not fold the above two line into one, because Tru64 sh and
adamc@1141 891 # Solaris sh will not grok spaces in the rhs of `-'.
adamc@1141 892 for _am_tool in $_am_tools
adamc@1141 893 do
adamc@1141 894 case $_am_tool in
adamc@1141 895 gnutar)
adamc@1141 896 for _am_tar in tar gnutar gtar;
adamc@1141 897 do
adamc@1141 898 AM_RUN_LOG([$_am_tar --version]) && break
adamc@1141 899 done
adamc@1141 900 am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"'
adamc@1141 901 am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"'
adamc@1141 902 am__untar="$_am_tar -xf -"
adamc@1141 903 ;;
adamc@1141 904 plaintar)
adamc@1141 905 # Must skip GNU tar: if it does not support --format= it doesn't create
adamc@1141 906 # ustar tarball either.
adamc@1141 907 (tar --version) >/dev/null 2>&1 && continue
adamc@1141 908 am__tar='tar chf - "$$tardir"'
adamc@1141 909 am__tar_='tar chf - "$tardir"'
adamc@1141 910 am__untar='tar xf -'
adamc@1141 911 ;;
adamc@1141 912 pax)
adamc@1141 913 am__tar='pax -L -x $1 -w "$$tardir"'
adamc@1141 914 am__tar_='pax -L -x $1 -w "$tardir"'
adamc@1141 915 am__untar='pax -r'
adamc@1141 916 ;;
adamc@1141 917 cpio)
adamc@1141 918 am__tar='find "$$tardir" -print | cpio -o -H $1 -L'
adamc@1141 919 am__tar_='find "$tardir" -print | cpio -o -H $1 -L'
adamc@1141 920 am__untar='cpio -i -H $1 -d'
adamc@1141 921 ;;
adamc@1141 922 none)
adamc@1141 923 am__tar=false
adamc@1141 924 am__tar_=false
adamc@1141 925 am__untar=false
adamc@1141 926 ;;
adamc@1141 927 esac
adamc@1141 928
adamc@1141 929 # If the value was cached, stop now. We just wanted to have am__tar
adamc@1141 930 # and am__untar set.
adamc@1141 931 test -n "${am_cv_prog_tar_$1}" && break
adamc@1141 932
adamc@1141 933 # tar/untar a dummy directory, and stop if the command works
adamc@1141 934 rm -rf conftest.dir
adamc@1141 935 mkdir conftest.dir
adamc@1141 936 echo GrepMe > conftest.dir/file
adamc@1141 937 AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar])
adamc@1141 938 rm -rf conftest.dir
adamc@1141 939 if test -s conftest.tar; then
adamc@1141 940 AM_RUN_LOG([$am__untar <conftest.tar])
adamc@1141 941 grep GrepMe conftest.dir/file >/dev/null 2>&1 && break
adamc@1141 942 fi
adamc@1141 943 done
adamc@1141 944 rm -rf conftest.dir
adamc@1141 945
adamc@1141 946 AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool])
adamc@1141 947 AC_MSG_RESULT([$am_cv_prog_tar_$1])])
adamc@1141 948 AC_SUBST([am__tar])
adamc@1141 949 AC_SUBST([am__untar])
adamc@1141 950 ]) # _AM_PROG_TAR
adamc@1141 951
adam@1368 952 m4_include([m4/ax_check_openssl.m4])
adamc@1141 953 m4_include([m4/libtool.m4])
adamc@1141 954 m4_include([m4/ltoptions.m4])
adamc@1141 955 m4_include([m4/ltsugar.m4])
adamc@1141 956 m4_include([m4/ltversion.m4])
adamc@1141 957 m4_include([m4/lt~obsolete.m4])
adam@1528 958 m4_include([m4/m4_ax_pthread.m4])