11
11
# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
12
12
# PARTICULAR PURPOSE.
14
m4_ifndef([AC_AUTOCONF_VERSION],
15
[m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
16
m4_if(AC_AUTOCONF_VERSION, [2.61],,
17
[m4_warning([this file was generated for autoconf 2.61.
18
You have another version of autoconf. It may work, but is not guaranteed to.
19
If you have problems, you may need to regenerate the build system entirely.
20
To do so, use the procedure documented by the package, typically `autoreconf'.])])
14
m4_if(m4_PACKAGE_VERSION, [2.61],,
15
[m4_fatal([this file was generated for autoconf 2.61.
16
You have another version of autoconf. If you want to use that,
17
you should regenerate the build system entirely.], [63])])
19
# Copyright (C) 2002, 2003, 2005, 2006 Free Software Foundation, Inc.
21
# This file is free software; the Free Software Foundation
22
# gives unlimited permission to copy and/or distribute it,
23
# with or without modifications, as long as this notice is preserved.
25
# AM_AUTOMAKE_VERSION(VERSION)
26
# ----------------------------
27
# Automake X.Y traces this macro to ensure aclocal.m4 has been
28
# generated from the m4 files accompanying Automake X.Y.
29
# (This private macro should not be called outside this file.)
30
AC_DEFUN([AM_AUTOMAKE_VERSION],
31
[am__api_version='1.10'
32
dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to
33
dnl require some minimum version. Point them to the right macro.
34
m4_if([$1], [1.10], [],
35
[AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl
38
# _AM_AUTOCONF_VERSION(VERSION)
39
# -----------------------------
40
# aclocal traces this macro to find the Autoconf version.
41
# This is a private macro too. Using m4_define simplifies
42
# the logic in aclocal, which can simply ignore this definition.
43
m4_define([_AM_AUTOCONF_VERSION], [])
45
# AM_SET_CURRENT_AUTOMAKE_VERSION
46
# -------------------------------
47
# Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced.
48
# This function is AC_REQUIREd by AC_INIT_AUTOMAKE.
49
AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
50
[AM_AUTOMAKE_VERSION([1.10])dnl
51
_AM_AUTOCONF_VERSION(m4_PACKAGE_VERSION)])
53
# AM_AUX_DIR_EXPAND -*- Autoconf -*-
55
# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc.
57
# This file is free software; the Free Software Foundation
58
# gives unlimited permission to copy and/or distribute it,
59
# with or without modifications, as long as this notice is preserved.
61
# For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets
62
# $ac_aux_dir to `$srcdir/foo'. In other projects, it is set to
63
# `$srcdir', `$srcdir/..', or `$srcdir/../..'.
65
# Of course, Automake must honor this variable whenever it calls a
66
# tool from the auxiliary directory. The problem is that $srcdir (and
67
# therefore $ac_aux_dir as well) can be either absolute or relative,
68
# depending on how configure is run. This is pretty annoying, since
69
# it makes $ac_aux_dir quite unusable in subdirectories: in the top
70
# source directory, any form will work fine, but in subdirectories a
71
# relative path needs to be adjusted first.
74
# fails when called from a subdirectory if $ac_aux_dir is relative
75
# $top_srcdir/$ac_aux_dir/missing
76
# fails if $ac_aux_dir is absolute,
77
# fails when called from a subdirectory in a VPATH build with
78
# a relative $ac_aux_dir
80
# The reason of the latter failure is that $top_srcdir and $ac_aux_dir
81
# are both prefixed by $srcdir. In an in-source build this is usually
82
# harmless because $srcdir is `.', but things will broke when you
83
# start a VPATH build or use an absolute $srcdir.
85
# So we could use something similar to $top_srcdir/$ac_aux_dir/missing,
86
# iff we strip the leading $srcdir from $ac_aux_dir. That would be:
87
# am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"`
88
# and then we would define $MISSING as
89
# MISSING="\${SHELL} $am_aux_dir/missing"
90
# This will work as long as MISSING is not called from configure, because
91
# unfortunately $(top_srcdir) has no meaning in configure.
92
# However there are other variables, like CC, which are often used in
93
# configure, and could therefore not use this "fixed" $ac_aux_dir.
95
# Another solution, used here, is to always expand $ac_aux_dir to an
96
# absolute PATH. The drawback is that using absolute paths prevent a
97
# configured tree to be moved without reconfiguration.
99
AC_DEFUN([AM_AUX_DIR_EXPAND],
100
[dnl Rely on autoconf to set up CDPATH properly.
102
# expand $ac_aux_dir to an absolute path
103
am_aux_dir=`cd $ac_aux_dir && pwd`
106
# AM_CONDITIONAL -*- Autoconf -*-
108
# Copyright (C) 1997, 2000, 2001, 2003, 2004, 2005, 2006
109
# Free Software Foundation, Inc.
111
# This file is free software; the Free Software Foundation
112
# gives unlimited permission to copy and/or distribute it,
113
# with or without modifications, as long as this notice is preserved.
117
# AM_CONDITIONAL(NAME, SHELL-CONDITION)
118
# -------------------------------------
119
# Define a conditional.
120
AC_DEFUN([AM_CONDITIONAL],
122
ifelse([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])],
123
[$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl
124
AC_SUBST([$1_TRUE])dnl
125
AC_SUBST([$1_FALSE])dnl
126
_AM_SUBST_NOTMAKE([$1_TRUE])dnl
127
_AM_SUBST_NOTMAKE([$1_FALSE])dnl
135
AC_CONFIG_COMMANDS_PRE(
136
[if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then
137
AC_MSG_ERROR([[conditional "$1" was never defined.
138
Usually this means the macro was only invoked conditionally.]])
141
# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006
142
# Free Software Foundation, Inc.
144
# This file is free software; the Free Software Foundation
145
# gives unlimited permission to copy and/or distribute it,
146
# with or without modifications, as long as this notice is preserved.
150
# There are a few dirty hacks below to avoid letting `AC_PROG_CC' be
151
# written in clear, in which case automake, when reading aclocal.m4,
152
# will think it sees a *use*, and therefore will trigger all it's
153
# C support machinery. Also note that it means that autoscan, seeing
154
# CC etc. in the Makefile, will ask for an AC_PROG_CC use...
157
# _AM_DEPENDENCIES(NAME)
158
# ----------------------
159
# See how the compiler implements dependency checking.
160
# NAME is "CC", "CXX", "GCJ", or "OBJC".
161
# We try a few techniques and use that to set a single cache variable.
163
# We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was
164
# modified to invoke _AM_DEPENDENCIES(CC); we would have a circular
165
# dependency, and given that the user is not expected to run this macro,
166
# just rely on AC_PROG_CC.
167
AC_DEFUN([_AM_DEPENDENCIES],
168
[AC_REQUIRE([AM_SET_DEPDIR])dnl
169
AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl
170
AC_REQUIRE([AM_MAKE_INCLUDE])dnl
171
AC_REQUIRE([AM_DEP_TRACK])dnl
173
ifelse([$1], CC, [depcc="$CC" am_compiler_list=],
174
[$1], CXX, [depcc="$CXX" am_compiler_list=],
175
[$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc'],
176
[$1], UPC, [depcc="$UPC" am_compiler_list=],
177
[$1], GCJ, [depcc="$GCJ" am_compiler_list='gcc3 gcc'],
178
[depcc="$$1" am_compiler_list=])
180
AC_CACHE_CHECK([dependency style of $depcc],
181
[am_cv_$1_dependencies_compiler_type],
182
[if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
183
# We make a subdir and do the tests there. Otherwise we can end up
184
# making bogus files that we don't know about and never remove. For
185
# instance it was reported that on HP-UX the gcc test will end up
186
# making a dummy file named `D' -- because `-MD' means `put the output
189
# Copy depcomp to subdir because otherwise we won't find it if we're
190
# using a relative directory.
191
cp "$am_depcomp" conftest.dir
193
# We will build objects and dependencies in a subdirectory because
194
# it helps to detect inapplicable dependency modes. For instance
195
# both Tru64's cc and ICC support -MD to output dependencies as a
196
# side effect of compilation, but ICC will put the dependencies in
197
# the current directory while Tru64 will put them in the object
201
am_cv_$1_dependencies_compiler_type=none
202
if test "$am_compiler_list" = ""; then
203
am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp`
205
for depmode in $am_compiler_list; do
206
# Setup a source with many dependencies, because some compilers
207
# like to wrap large dependency lists on column 80 (with \), and
208
# we should not choose a depcomp mode which is confused by this.
210
# We need to recreate these files for each test, as the compiler may
211
# overwrite some of them when testing with obscure command lines.
212
# This happens at least with the AIX C compiler.
214
for i in 1 2 3 4 5 6; do
215
echo '#include "conftst'$i'.h"' >> sub/conftest.c
216
# Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
217
# Solaris 8's {/usr,}/bin/sh.
218
touch sub/conftst$i.h
220
echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
224
# after this tag, mechanisms are not by side-effect, so they'll
225
# only be used when explicitly requested
226
if test "x$enable_dependency_tracking" = xyes; then
234
# We check with `-c' and `-o' for the sake of the "dashmstdout"
235
# mode. It turns out that the SunPro C++ compiler does not properly
236
# handle `-M -o', and we need to detect this.
237
if depmode=$depmode \
238
source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \
239
depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
240
$SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \
241
>/dev/null 2>conftest.err &&
242
grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
243
grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
244
grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 &&
245
${MAKE-make} -s -f confmf > /dev/null 2>&1; then
246
# icc doesn't choke on unknown options, it will just issue warnings
247
# or remarks (even with -Werror). So we grep stderr for any message
248
# that says an option was ignored or not supported.
249
# When given -MP, icc 7.0 and 7.1 complain thusly:
250
# icc: Command line warning: ignoring option '-M'; no argument required
251
# The diagnosis changed in icc 8.0:
252
# icc: Command line remark: option '-MP' not supported
253
if (grep 'ignoring option' conftest.err ||
254
grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
255
am_cv_$1_dependencies_compiler_type=$depmode
264
am_cv_$1_dependencies_compiler_type=none
267
AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type])
268
AM_CONDITIONAL([am__fastdep$1], [
269
test "x$enable_dependency_tracking" != xno \
270
&& test "$am_cv_$1_dependencies_compiler_type" = gcc3])
276
# Choose a directory name for dependency files.
277
# This macro is AC_REQUIREd in _AM_DEPENDENCIES
278
AC_DEFUN([AM_SET_DEPDIR],
279
[AC_REQUIRE([AM_SET_LEADING_DOT])dnl
280
AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl
286
AC_DEFUN([AM_DEP_TRACK],
287
[AC_ARG_ENABLE(dependency-tracking,
288
[ --disable-dependency-tracking speeds up one-time build
289
--enable-dependency-tracking do not reject slow dependency extractors])
290
if test "x$enable_dependency_tracking" != xno; then
291
am_depcomp="$ac_aux_dir/depcomp"
294
AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno])
295
AC_SUBST([AMDEPBACKSLASH])dnl
296
_AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl
299
# Generate code to set up dependency tracking. -*- Autoconf -*-
301
# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005
302
# Free Software Foundation, Inc.
304
# This file is free software; the Free Software Foundation
305
# gives unlimited permission to copy and/or distribute it,
306
# with or without modifications, as long as this notice is preserved.
310
# _AM_OUTPUT_DEPENDENCY_COMMANDS
311
# ------------------------------
312
AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
313
[for mf in $CONFIG_FILES; do
314
# Strip MF so we end up with the name of the file.
315
mf=`echo "$mf" | sed -e 's/:.*$//'`
316
# Check whether this is an Automake generated Makefile or not.
317
# We used to match only the files named `Makefile.in', but
318
# some people rename them; so instead we look at the file content.
319
# Grep'ing the first line is not enough: some people post-process
320
# each Makefile.in and add a new line on top of each file to say so.
321
# Grep'ing the whole file is not good either: AIX grep has a line
322
# limit of 2048, but all sed's we know have understand at least 4000.
323
if sed 10q "$mf" | grep '^#.*generated by automake' > /dev/null 2>&1; then
324
dirpart=`AS_DIRNAME("$mf")`
328
# Extract the definition of DEPDIR, am__include, and am__quote
329
# from the Makefile without running `make'.
330
DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
331
test -z "$DEPDIR" && continue
332
am__include=`sed -n 's/^am__include = //p' < "$mf"`
333
test -z "am__include" && continue
334
am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
335
# When using ansi2knr, U may be empty or an underscore; expand it
336
U=`sed -n 's/^U = //p' < "$mf"`
337
# Find all dependency output files, they are included files with
338
# $(DEPDIR) in their names. We invoke sed twice because it is the
339
# simplest approach to changing $(DEPDIR) to its actual value in the
341
for file in `sed -n "
342
s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
343
sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
344
# Make sure the directory exists.
345
test -f "$dirpart/$file" && continue
346
fdir=`AS_DIRNAME(["$file"])`
347
AS_MKDIR_P([$dirpart/$fdir])
348
# echo "creating $dirpart/$file"
349
echo '# dummy' > "$dirpart/$file"
352
])# _AM_OUTPUT_DEPENDENCY_COMMANDS
355
# AM_OUTPUT_DEPENDENCY_COMMANDS
356
# -----------------------------
357
# This macro should only be invoked once -- use via AC_REQUIRE.
359
# This code is only required when automatic dependency tracking
360
# is enabled. FIXME. This creates each `.P' file that we will
361
# need in order to bootstrap the dependency handling code.
362
AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
363
[AC_CONFIG_COMMANDS([depfiles],
364
[test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS],
365
[AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"])
368
# Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005
369
# Free Software Foundation, Inc.
371
# This file is free software; the Free Software Foundation
372
# gives unlimited permission to copy and/or distribute it,
373
# with or without modifications, as long as this notice is preserved.
377
# AM_CONFIG_HEADER is obsolete. It has been replaced by AC_CONFIG_HEADERS.
378
AU_DEFUN([AM_CONFIG_HEADER], [AC_CONFIG_HEADERS($@)])
380
# Do all the work for Automake. -*- Autoconf -*-
382
# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
383
# 2005, 2006 Free Software Foundation, Inc.
385
# This file is free software; the Free Software Foundation
386
# gives unlimited permission to copy and/or distribute it,
387
# with or without modifications, as long as this notice is preserved.
391
# This macro actually does too much. Some checks are only needed if
392
# your package does certain things. But this isn't really a big deal.
394
# AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE])
395
# AM_INIT_AUTOMAKE([OPTIONS])
396
# -----------------------------------------------
397
# The call with PACKAGE and VERSION arguments is the old style
398
# call (pre autoconf-2.50), which is being phased out. PACKAGE
399
# and VERSION should now be passed to AC_INIT and removed from
400
# the call to AM_INIT_AUTOMAKE.
401
# We support both call styles for the transition. After
402
# the next Automake release, Autoconf can make the AC_INIT
403
# arguments mandatory, and then we can depend on a new Autoconf
404
# release and drop the old call support.
405
AC_DEFUN([AM_INIT_AUTOMAKE],
406
[AC_PREREQ([2.60])dnl
407
dnl Autoconf wants to disallow AM_ names. We explicitly allow
408
dnl the ones we care about.
409
m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
410
AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl
411
AC_REQUIRE([AC_PROG_INSTALL])dnl
412
if test "`cd $srcdir && pwd`" != "`pwd`"; then
413
# Use -I$(srcdir) only when $(srcdir) != ., so that make's output
414
# is not polluted with repeated "-I."
415
AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl
416
# test to see if srcdir already configured
417
if test -f $srcdir/config.status; then
418
AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
422
# test whether we have cygpath
423
if test -z "$CYGPATH_W"; then
424
if (cygpath --version) >/dev/null 2>/dev/null; then
425
CYGPATH_W='cygpath -w'
430
AC_SUBST([CYGPATH_W])
432
# Define the identity of the package.
433
dnl Distinguish between old-style and new-style calls.
435
[m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl
436
AC_SUBST([PACKAGE], [$1])dnl
437
AC_SUBST([VERSION], [$2])],
438
[_AM_SET_OPTIONS([$1])dnl
439
dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT.
440
m4_if(m4_ifdef([AC_PACKAGE_NAME], 1)m4_ifdef([AC_PACKAGE_VERSION], 1), 11,,
441
[m4_fatal([AC_INIT should be called with package and version arguments])])dnl
442
AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl
443
AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl
445
_AM_IF_OPTION([no-define],,
446
[AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
447
AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl
449
# Some tools Automake needs.
450
AC_REQUIRE([AM_SANITY_CHECK])dnl
451
AC_REQUIRE([AC_ARG_PROGRAM])dnl
452
AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version})
453
AM_MISSING_PROG(AUTOCONF, autoconf)
454
AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version})
455
AM_MISSING_PROG(AUTOHEADER, autoheader)
456
AM_MISSING_PROG(MAKEINFO, makeinfo)
458
AM_PROG_INSTALL_STRIP
459
AC_REQUIRE([AM_PROG_MKDIR_P])dnl
460
# We need awk for the "check" target. The system "awk" is bad on
462
AC_REQUIRE([AC_PROG_AWK])dnl
463
AC_REQUIRE([AC_PROG_MAKE_SET])dnl
464
AC_REQUIRE([AM_SET_LEADING_DOT])dnl
465
_AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])],
466
[_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])],
467
[_AM_PROG_TAR([v7])])])
468
_AM_IF_OPTION([no-dependencies],,
469
[AC_PROVIDE_IFELSE([AC_PROG_CC],
470
[_AM_DEPENDENCIES(CC)],
471
[define([AC_PROG_CC],
472
defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl
473
AC_PROVIDE_IFELSE([AC_PROG_CXX],
474
[_AM_DEPENDENCIES(CXX)],
475
[define([AC_PROG_CXX],
476
defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl
477
AC_PROVIDE_IFELSE([AC_PROG_OBJC],
478
[_AM_DEPENDENCIES(OBJC)],
479
[define([AC_PROG_OBJC],
480
defn([AC_PROG_OBJC])[_AM_DEPENDENCIES(OBJC)])])dnl
485
# When config.status generates a header, we must update the stamp-h file.
486
# This file resides in the same directory as the config header
487
# that is generated. The stamp files are numbered to have different names.
489
# Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the
490
# loop where config.status creates the headers, so we can generate
491
# our stamp files there.
492
AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK],
493
[# Compute $1's index in $config_headers.
495
for _am_header in $config_headers :; do
500
_am_stamp_count=`expr $_am_stamp_count + 1` ;;
503
echo "timestamp for $1" >`AS_DIRNAME([$1])`/stamp-h[]$_am_stamp_count])
505
# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc.
507
# This file is free software; the Free Software Foundation
508
# gives unlimited permission to copy and/or distribute it,
509
# with or without modifications, as long as this notice is preserved.
513
# Define $install_sh.
514
AC_DEFUN([AM_PROG_INSTALL_SH],
515
[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
516
install_sh=${install_sh-"\$(SHELL) $am_aux_dir/install-sh"}
517
AC_SUBST(install_sh)])
519
# Copyright (C) 2003, 2005 Free Software Foundation, Inc.
521
# This file is free software; the Free Software Foundation
522
# gives unlimited permission to copy and/or distribute it,
523
# with or without modifications, as long as this notice is preserved.
527
# Check whether the underlying file-system supports filenames
528
# with a leading dot. For instance MS-DOS doesn't.
529
AC_DEFUN([AM_SET_LEADING_DOT],
530
[rm -rf .tst 2>/dev/null
531
mkdir .tst 2>/dev/null
532
if test -d .tst; then
537
rmdir .tst 2>/dev/null
538
AC_SUBST([am__leading_dot])])
540
# Add --enable-maintainer-mode option to configure. -*- Autoconf -*-
543
# Copyright (C) 1996, 1998, 2000, 2001, 2002, 2003, 2004, 2005
544
# Free Software Foundation, Inc.
546
# This file is free software; the Free Software Foundation
547
# gives unlimited permission to copy and/or distribute it,
548
# with or without modifications, as long as this notice is preserved.
552
AC_DEFUN([AM_MAINTAINER_MODE],
553
[AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles])
554
dnl maintainer-mode is disabled by default
555
AC_ARG_ENABLE(maintainer-mode,
556
[ --enable-maintainer-mode enable make rules and dependencies not useful
557
(and sometimes confusing) to the casual installer],
558
USE_MAINTAINER_MODE=$enableval,
559
USE_MAINTAINER_MODE=no)
560
AC_MSG_RESULT([$USE_MAINTAINER_MODE])
561
AM_CONDITIONAL(MAINTAINER_MODE, [test $USE_MAINTAINER_MODE = yes])
562
MAINT=$MAINTAINER_MODE_TRUE
567
AU_DEFUN([jm_MAINTAINER_MODE], [AM_MAINTAINER_MODE])
569
# Check to see how 'make' treats includes. -*- Autoconf -*-
571
# Copyright (C) 2001, 2002, 2003, 2005 Free Software Foundation, Inc.
573
# This file is free software; the Free Software Foundation
574
# gives unlimited permission to copy and/or distribute it,
575
# with or without modifications, as long as this notice is preserved.
581
# Check to see how make treats includes.
582
AC_DEFUN([AM_MAKE_INCLUDE],
583
[am_make=${MAKE-make}
584
cat > confinc << 'END'
589
# If we don't find an include directive, just comment out the code.
590
AC_MSG_CHECKING([for style of include used by $am_make])
594
# First try GNU make style include.
595
echo "include confinc" > confmf
596
# We grep out `Entering directory' and `Leaving directory'
597
# messages which can occur if `w' ends up in MAKEFLAGS.
598
# In particular we don't look at `^make:' because GNU make might
599
# be invoked under some other name (usually "gmake"), in which
600
# case it prints its new name instead of `make'.
601
if test "`$am_make -s -f confmf 2> /dev/null | grep -v 'ing directory'`" = "done"; then
606
# Now try BSD make style include.
607
if test "$am__include" = "#"; then
608
echo '.include "confinc"' > confmf
609
if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then
615
AC_SUBST([am__include])
616
AC_SUBST([am__quote])
617
AC_MSG_RESULT([$_am_result])
621
# Fake the existence of programs that GNU maintainers use. -*- Autoconf -*-
623
# Copyright (C) 1997, 1999, 2000, 2001, 2003, 2004, 2005
624
# Free Software Foundation, Inc.
626
# This file is free software; the Free Software Foundation
627
# gives unlimited permission to copy and/or distribute it,
628
# with or without modifications, as long as this notice is preserved.
632
# AM_MISSING_PROG(NAME, PROGRAM)
633
# ------------------------------
634
AC_DEFUN([AM_MISSING_PROG],
635
[AC_REQUIRE([AM_MISSING_HAS_RUN])
636
$1=${$1-"${am_missing_run}$2"}
642
# Define MISSING if not defined so far and test if it supports --run.
643
# If it does, set am_missing_run to use it, otherwise, to nothing.
644
AC_DEFUN([AM_MISSING_HAS_RUN],
645
[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
646
AC_REQUIRE_AUX_FILE([missing])dnl
647
test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing"
648
# Use eval to expand $SHELL
649
if eval "$MISSING --run true"; then
650
am_missing_run="$MISSING --run "
653
AC_MSG_WARN([`missing' script is too old or missing])
657
# Copyright (C) 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
659
# This file is free software; the Free Software Foundation
660
# gives unlimited permission to copy and/or distribute it,
661
# with or without modifications, as long as this notice is preserved.
665
# Check for `mkdir -p'.
666
AC_DEFUN([AM_PROG_MKDIR_P],
667
[AC_PREREQ([2.60])dnl
668
AC_REQUIRE([AC_PROG_MKDIR_P])dnl
669
dnl Automake 1.8 to 1.9.6 used to define mkdir_p. We now use MKDIR_P,
670
dnl while keeping a definition of mkdir_p for backward compatibility.
671
dnl @MKDIR_P@ is magic: AC_OUTPUT adjusts its value for each Makefile.
672
dnl However we cannot define mkdir_p as $(MKDIR_P) for the sake of
673
dnl Makefile.ins that do not define MKDIR_P, so we do our own
674
dnl adjustment using top_builddir (which is defined more often than
676
AC_SUBST([mkdir_p], ["$MKDIR_P"])dnl
678
[[\\/$]]* | ?:[[\\/]]*) ;;
679
*/*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
683
# Helper functions for option handling. -*- Autoconf -*-
685
# Copyright (C) 2001, 2002, 2003, 2005 Free Software Foundation, Inc.
687
# This file is free software; the Free Software Foundation
688
# gives unlimited permission to copy and/or distribute it,
689
# with or without modifications, as long as this notice is preserved.
693
# _AM_MANGLE_OPTION(NAME)
694
# -----------------------
695
AC_DEFUN([_AM_MANGLE_OPTION],
696
[[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])])
698
# _AM_SET_OPTION(NAME)
699
# ------------------------------
700
# Set option NAME. Presently that only means defining a flag for this option.
701
AC_DEFUN([_AM_SET_OPTION],
702
[m4_define(_AM_MANGLE_OPTION([$1]), 1)])
704
# _AM_SET_OPTIONS(OPTIONS)
705
# ----------------------------------
706
# OPTIONS is a space-separated list of Automake options.
707
AC_DEFUN([_AM_SET_OPTIONS],
708
[AC_FOREACH([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])])
710
# _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET])
711
# -------------------------------------------
712
# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
713
AC_DEFUN([_AM_IF_OPTION],
714
[m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
716
# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005
717
# Free Software Foundation, Inc.
719
# This file is free software; the Free Software Foundation
720
# gives unlimited permission to copy and/or distribute it,
721
# with or without modifications, as long as this notice is preserved.
723
# AM_PATH_PYTHON([MINIMUM-VERSION], [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
724
# ---------------------------------------------------------------------------
725
# Adds support for distributing Python modules and packages. To
726
# install modules, copy them to $(pythondir), using the python_PYTHON
727
# automake variable. To install a package with the same name as the
728
# automake package, install to $(pkgpythondir), or use the
729
# pkgpython_PYTHON automake variable.
731
# The variables $(pyexecdir) and $(pkgpyexecdir) are provided as
732
# locations to install python extension modules (shared libraries).
733
# Another macro is required to find the appropriate flags to compile
736
# If your package is configured with a different prefix to python,
737
# users will have to add the install directory to the PYTHONPATH
738
# environment variable, or create a .pth file (see the python
739
# documentation for details).
741
# If the MINIMUM-VERSION argument is passed, AM_PATH_PYTHON will
742
# cause an error if the version of python installed on the system
743
# doesn't meet the requirement. MINIMUM-VERSION should consist of
744
# numbers and dots only.
745
AC_DEFUN([AM_PATH_PYTHON],
747
dnl Find a Python interpreter. Python versions prior to 1.5 are not
748
dnl supported because the default installation locations changed from
749
dnl $prefix/lib/site-python in 1.4 to $prefix/lib/python1.5/site-packages
751
m4_define_default([_AM_PYTHON_INTERPRETER_LIST],
752
[python python2 python2.5 python2.4 python2.3 python2.2 dnl
753
python2.1 python2.0 python1.6 python1.5])
756
dnl No version check is needed.
757
# Find any Python interpreter.
758
if test -z "$PYTHON"; then
759
AC_PATH_PROGS([PYTHON], _AM_PYTHON_INTERPRETER_LIST, :)
761
am_display_PYTHON=python
763
dnl A version check is needed.
764
if test -n "$PYTHON"; then
765
# If the user set $PYTHON, use it and don't search something else.
766
AC_MSG_CHECKING([whether $PYTHON version >= $1])
767
AM_PYTHON_CHECK_VERSION([$PYTHON], [$1],
768
[AC_MSG_RESULT(yes)],
769
[AC_MSG_ERROR(too old)])
770
am_display_PYTHON=$PYTHON
772
# Otherwise, try each interpreter until we find one that satisfies
774
AC_CACHE_CHECK([for a Python interpreter with version >= $1],
775
[am_cv_pathless_PYTHON],[
776
for am_cv_pathless_PYTHON in _AM_PYTHON_INTERPRETER_LIST none; do
777
test "$am_cv_pathless_PYTHON" = none && break
778
AM_PYTHON_CHECK_VERSION([$am_cv_pathless_PYTHON], [$1], [break])
780
# Set $PYTHON to the absolute path of $am_cv_pathless_PYTHON.
781
if test "$am_cv_pathless_PYTHON" = none; then
784
AC_PATH_PROG([PYTHON], [$am_cv_pathless_PYTHON])
786
am_display_PYTHON=$am_cv_pathless_PYTHON
790
if test "$PYTHON" = :; then
791
dnl Run any user-specified action, or abort.
792
m4_default([$3], [AC_MSG_ERROR([no suitable Python interpreter found])])
795
dnl Query Python for its version number. Getting [:3] seems to be
796
dnl the best way to do this; it's what "site.py" does in the standard
799
AC_CACHE_CHECK([for $am_display_PYTHON version], [am_cv_python_version],
800
[am_cv_python_version=`$PYTHON -c "import sys; print sys.version[[:3]]"`])
801
AC_SUBST([PYTHON_VERSION], [$am_cv_python_version])
803
dnl Use the values of $prefix and $exec_prefix for the corresponding
804
dnl values of PYTHON_PREFIX and PYTHON_EXEC_PREFIX. These are made
805
dnl distinct variables so they can be overridden if need be. However,
806
dnl general consensus is that you shouldn't need this ability.
808
AC_SUBST([PYTHON_PREFIX], ['${prefix}'])
809
AC_SUBST([PYTHON_EXEC_PREFIX], ['${exec_prefix}'])
811
dnl At times (like when building shared libraries) you may want
812
dnl to know which OS platform Python thinks this is.
814
AC_CACHE_CHECK([for $am_display_PYTHON platform], [am_cv_python_platform],
815
[am_cv_python_platform=`$PYTHON -c "import sys; print sys.platform"`])
816
AC_SUBST([PYTHON_PLATFORM], [$am_cv_python_platform])
819
dnl Set up 4 directories:
821
dnl pythondir -- where to install python scripts. This is the
822
dnl site-packages directory, not the python standard library
823
dnl directory like in previous automake betas. This behavior
824
dnl is more consistent with lispdir.m4 for example.
825
dnl Query distutils for this directory. distutils does not exist in
826
dnl Python 1.5, so we fall back to the hardcoded directory if it
828
AC_CACHE_CHECK([for $am_display_PYTHON script directory],
829
[am_cv_python_pythondir],
830
[am_cv_python_pythondir=`$PYTHON -c "from distutils import sysconfig; print sysconfig.get_python_lib(0,0,prefix='$PYTHON_PREFIX')" 2>/dev/null ||
831
echo "$PYTHON_PREFIX/lib/python$PYTHON_VERSION/site-packages"`])
832
AC_SUBST([pythondir], [$am_cv_python_pythondir])
834
dnl pkgpythondir -- $PACKAGE directory under pythondir. Was
835
dnl PYTHON_SITE_PACKAGE in previous betas, but this naming is
836
dnl more consistent with the rest of automake.
838
AC_SUBST([pkgpythondir], [\${pythondir}/$PACKAGE])
840
dnl pyexecdir -- directory for installing python extension modules
841
dnl (shared libraries)
842
dnl Query distutils for this directory. distutils does not exist in
843
dnl Python 1.5, so we fall back to the hardcoded directory if it
845
AC_CACHE_CHECK([for $am_display_PYTHON extension module directory],
846
[am_cv_python_pyexecdir],
847
[am_cv_python_pyexecdir=`$PYTHON -c "from distutils import sysconfig; print sysconfig.get_python_lib(1,0,prefix='$PYTHON_EXEC_PREFIX')" 2>/dev/null ||
848
echo "${PYTHON_EXEC_PREFIX}/lib/python${PYTHON_VERSION}/site-packages"`])
849
AC_SUBST([pyexecdir], [$am_cv_python_pyexecdir])
851
dnl pkgpyexecdir -- $(pyexecdir)/$(PACKAGE)
853
AC_SUBST([pkgpyexecdir], [\${pyexecdir}/$PACKAGE])
855
dnl Run any user-specified action.
862
# AM_PYTHON_CHECK_VERSION(PROG, VERSION, [ACTION-IF-TRUE], [ACTION-IF-FALSE])
863
# ---------------------------------------------------------------------------
864
# Run ACTION-IF-TRUE if the Python interpreter PROG has version >= VERSION.
865
# Run ACTION-IF-FALSE otherwise.
866
# This test uses sys.hexversion instead of the string equivalent (first
867
# word of sys.version), in order to cope with versions such as 2.2c1.
868
# hexversion has been introduced in Python 1.5.2; it's probably not
869
# worth to support older versions (1.5.1 was released on October 31, 1998).
870
AC_DEFUN([AM_PYTHON_CHECK_VERSION],
871
[prog="import sys, string
872
# split strings by '.' and convert to numeric. Append some zeros
873
# because we need at least 4 digits for the hex conversion.
874
minver = map(int, string.split('$2', '.')) + [[0, 0, 0]]
876
for i in xrange(0, 4): minverhex = (minverhex << 8) + minver[[i]]
877
sys.exit(sys.hexversion < minverhex)"
878
AS_IF([AM_RUN_LOG([$1 -c "$prog"])], [$3], [$4])])
880
# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc.
882
# This file is free software; the Free Software Foundation
883
# gives unlimited permission to copy and/or distribute it,
884
# with or without modifications, as long as this notice is preserved.
886
# AM_RUN_LOG(COMMAND)
887
# -------------------
888
# Run COMMAND, save the exit status in ac_status, and log it.
889
# (This has been adapted from Autoconf's _AC_RUN_LOG macro.)
890
AC_DEFUN([AM_RUN_LOG],
891
[{ echo "$as_me:$LINENO: $1" >&AS_MESSAGE_LOG_FD
892
($1) >&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD
894
echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
895
(exit $ac_status); }])
897
# Check to make sure that the build environment is sane. -*- Autoconf -*-
899
# Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005
900
# Free Software Foundation, Inc.
902
# This file is free software; the Free Software Foundation
903
# gives unlimited permission to copy and/or distribute it,
904
# with or without modifications, as long as this notice is preserved.
910
AC_DEFUN([AM_SANITY_CHECK],
911
[AC_MSG_CHECKING([whether build environment is sane])
914
echo timestamp > conftest.file
915
# Do `set' in a subshell so we don't clobber the current shell's
916
# arguments. Must try -L first in case configure is actually a
917
# symlink; some systems play weird games with the mod time of symlinks
918
# (eg FreeBSD returns the mod time of the symlink's containing
921
set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null`
922
if test "$[*]" = "X"; then
924
set X `ls -t $srcdir/configure conftest.file`
927
if test "$[*]" != "X $srcdir/configure conftest.file" \
928
&& test "$[*]" != "X conftest.file $srcdir/configure"; then
930
# If neither matched, then we have a broken ls. This can happen
931
# if, for instance, CONFIG_SHELL is bash and it inherits a
932
# broken ls alias from the environment. This has actually
933
# happened. Such a system could not be considered "sane".
934
AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken
935
alias in your environment])
938
test "$[2]" = conftest.file
944
AC_MSG_ERROR([newly created file is older than distributed files!
945
Check your system clock])
949
# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc.
951
# This file is free software; the Free Software Foundation
952
# gives unlimited permission to copy and/or distribute it,
953
# with or without modifications, as long as this notice is preserved.
955
# AM_PROG_INSTALL_STRIP
956
# ---------------------
957
# One issue with vendor `install' (even GNU) is that you can't
958
# specify the program used to strip binaries. This is especially
959
# annoying in cross-compiling environments, where the build's strip
960
# is unlikely to handle the host's binaries.
961
# Fortunately install-sh will honor a STRIPPROG variable, so we
962
# always use install-sh in `make install-strip', and initialize
963
# STRIPPROG with the value of the STRIP variable (set by the user).
964
AC_DEFUN([AM_PROG_INSTALL_STRIP],
965
[AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
966
# Installed binaries are usually stripped using `strip' when the user
967
# run `make install-strip'. However `strip' might not be the right
968
# tool to use in cross-compilation environments, therefore Automake
969
# will honor the `STRIP' environment variable to overrule this program.
970
dnl Don't test for $cross_compiling = yes, because it might be `maybe'.
971
if test "$cross_compiling" != no; then
972
AC_CHECK_TOOL([STRIP], [strip], :)
974
INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
975
AC_SUBST([INSTALL_STRIP_PROGRAM])])
977
# Copyright (C) 2006 Free Software Foundation, Inc.
979
# This file is free software; the Free Software Foundation
980
# gives unlimited permission to copy and/or distribute it,
981
# with or without modifications, as long as this notice is preserved.
983
# _AM_SUBST_NOTMAKE(VARIABLE)
984
# ---------------------------
985
# Prevent Automake from outputing VARIABLE = @VARIABLE@ in Makefile.in.
986
# This macro is traced by Automake.
987
AC_DEFUN([_AM_SUBST_NOTMAKE])
989
# Check how to create a tarball. -*- Autoconf -*-
991
# Copyright (C) 2004, 2005 Free Software Foundation, Inc.
993
# This file is free software; the Free Software Foundation
994
# gives unlimited permission to copy and/or distribute it,
995
# with or without modifications, as long as this notice is preserved.
999
# _AM_PROG_TAR(FORMAT)
1000
# --------------------
1001
# Check how to create a tarball in format FORMAT.
1002
# FORMAT should be one of `v7', `ustar', or `pax'.
1004
# Substitute a variable $(am__tar) that is a command
1005
# writing to stdout a FORMAT-tarball containing the directory
1007
# tardir=directory && $(am__tar) > result.tar
1009
# Substitute a variable $(am__untar) that extract such
1010
# a tarball read from stdin.
1011
# $(am__untar) < result.tar
1012
AC_DEFUN([_AM_PROG_TAR],
1013
[# Always define AMTAR for backward compatibility.
1014
AM_MISSING_PROG([AMTAR], [tar])
1016
[am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'],
1017
[m4_case([$1], [ustar],, [pax],,
1018
[m4_fatal([Unknown tar format])])
1019
AC_MSG_CHECKING([how to create a $1 tar archive])
1020
# Loop over all known methods to create a tar archive until one works.
1021
_am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none'
1022
_am_tools=${am_cv_prog_tar_$1-$_am_tools}
1023
# Do not fold the above two line into one, because Tru64 sh and
1024
# Solaris sh will not grok spaces in the rhs of `-'.
1025
for _am_tool in $_am_tools
1029
for _am_tar in tar gnutar gtar;
1031
AM_RUN_LOG([$_am_tar --version]) && break
1033
am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"'
1034
am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"'
1035
am__untar="$_am_tar -xf -"
1038
# Must skip GNU tar: if it does not support --format= it doesn't create
1039
# ustar tarball either.
1040
(tar --version) >/dev/null 2>&1 && continue
1041
am__tar='tar chf - "$$tardir"'
1042
am__tar_='tar chf - "$tardir"'
1043
am__untar='tar xf -'
1046
am__tar='pax -L -x $1 -w "$$tardir"'
1047
am__tar_='pax -L -x $1 -w "$tardir"'
1051
am__tar='find "$$tardir" -print | cpio -o -H $1 -L'
1052
am__tar_='find "$tardir" -print | cpio -o -H $1 -L'
1053
am__untar='cpio -i -H $1 -d'
1062
# If the value was cached, stop now. We just wanted to have am__tar
1063
# and am__untar set.
1064
test -n "${am_cv_prog_tar_$1}" && break
1066
# tar/untar a dummy directory, and stop if the command works
1069
echo GrepMe > conftest.dir/file
1070
AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar])
1072
if test -s conftest.tar; then
1073
AM_RUN_LOG([$am__untar <conftest.tar])
1074
grep GrepMe conftest.dir/file >/dev/null 2>&1 && break
1079
AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool])
1080
AC_MSG_RESULT([$am_cv_prog_tar_$1])])
1082
AC_SUBST([am__untar])
22
1085
# Copyright (C) 1995-2002 Free Software Foundation, Inc.
23
1086
# Copyright (C) 2001-2003,2004 Red Hat, Inc.
7549
8422
])# PKG_CHECK_MODULES
7551
# Copyright (C) 2002, 2003, 2005, 2006, 2007 Free Software Foundation, Inc.
7553
# This file is free software; the Free Software Foundation
7554
# gives unlimited permission to copy and/or distribute it,
7555
# with or without modifications, as long as this notice is preserved.
7557
# AM_AUTOMAKE_VERSION(VERSION)
7558
# ----------------------------
7559
# Automake X.Y traces this macro to ensure aclocal.m4 has been
7560
# generated from the m4 files accompanying Automake X.Y.
7561
# (This private macro should not be called outside this file.)
7562
AC_DEFUN([AM_AUTOMAKE_VERSION],
7563
[am__api_version='1.10'
7564
dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to
7565
dnl require some minimum version. Point them to the right macro.
7566
m4_if([$1], [1.10.1], [],
7567
[AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl
7570
# _AM_AUTOCONF_VERSION(VERSION)
7571
# -----------------------------
7572
# aclocal traces this macro to find the Autoconf version.
7573
# This is a private macro too. Using m4_define simplifies
7574
# the logic in aclocal, which can simply ignore this definition.
7575
m4_define([_AM_AUTOCONF_VERSION], [])
7577
# AM_SET_CURRENT_AUTOMAKE_VERSION
7578
# -------------------------------
7579
# Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced.
7580
# This function is AC_REQUIREd by AC_INIT_AUTOMAKE.
7581
AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
7582
[AM_AUTOMAKE_VERSION([1.10.1])dnl
7583
m4_ifndef([AC_AUTOCONF_VERSION],
7584
[m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
7585
_AM_AUTOCONF_VERSION(AC_AUTOCONF_VERSION)])
7587
# AM_AUX_DIR_EXPAND -*- Autoconf -*-
7589
# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc.
7591
# This file is free software; the Free Software Foundation
7592
# gives unlimited permission to copy and/or distribute it,
7593
# with or without modifications, as long as this notice is preserved.
7595
# For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets
7596
# $ac_aux_dir to `$srcdir/foo'. In other projects, it is set to
7597
# `$srcdir', `$srcdir/..', or `$srcdir/../..'.
7599
# Of course, Automake must honor this variable whenever it calls a
7600
# tool from the auxiliary directory. The problem is that $srcdir (and
7601
# therefore $ac_aux_dir as well) can be either absolute or relative,
7602
# depending on how configure is run. This is pretty annoying, since
7603
# it makes $ac_aux_dir quite unusable in subdirectories: in the top
7604
# source directory, any form will work fine, but in subdirectories a
7605
# relative path needs to be adjusted first.
7607
# $ac_aux_dir/missing
7608
# fails when called from a subdirectory if $ac_aux_dir is relative
7609
# $top_srcdir/$ac_aux_dir/missing
7610
# fails if $ac_aux_dir is absolute,
7611
# fails when called from a subdirectory in a VPATH build with
7612
# a relative $ac_aux_dir
7614
# The reason of the latter failure is that $top_srcdir and $ac_aux_dir
7615
# are both prefixed by $srcdir. In an in-source build this is usually
7616
# harmless because $srcdir is `.', but things will broke when you
7617
# start a VPATH build or use an absolute $srcdir.
7619
# So we could use something similar to $top_srcdir/$ac_aux_dir/missing,
7620
# iff we strip the leading $srcdir from $ac_aux_dir. That would be:
7621
# am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"`
7622
# and then we would define $MISSING as
7623
# MISSING="\${SHELL} $am_aux_dir/missing"
7624
# This will work as long as MISSING is not called from configure, because
7625
# unfortunately $(top_srcdir) has no meaning in configure.
7626
# However there are other variables, like CC, which are often used in
7627
# configure, and could therefore not use this "fixed" $ac_aux_dir.
7629
# Another solution, used here, is to always expand $ac_aux_dir to an
7630
# absolute PATH. The drawback is that using absolute paths prevent a
7631
# configured tree to be moved without reconfiguration.
7633
AC_DEFUN([AM_AUX_DIR_EXPAND],
7634
[dnl Rely on autoconf to set up CDPATH properly.
7635
AC_PREREQ([2.50])dnl
7636
# expand $ac_aux_dir to an absolute path
7637
am_aux_dir=`cd $ac_aux_dir && pwd`
7640
# AM_CONDITIONAL -*- Autoconf -*-
7642
# Copyright (C) 1997, 2000, 2001, 2003, 2004, 2005, 2006
7643
# Free Software Foundation, Inc.
7645
# This file is free software; the Free Software Foundation
7646
# gives unlimited permission to copy and/or distribute it,
7647
# with or without modifications, as long as this notice is preserved.
7651
# AM_CONDITIONAL(NAME, SHELL-CONDITION)
7652
# -------------------------------------
7653
# Define a conditional.
7654
AC_DEFUN([AM_CONDITIONAL],
7656
ifelse([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])],
7657
[$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl
7658
AC_SUBST([$1_TRUE])dnl
7659
AC_SUBST([$1_FALSE])dnl
7660
_AM_SUBST_NOTMAKE([$1_TRUE])dnl
7661
_AM_SUBST_NOTMAKE([$1_FALSE])dnl
7669
AC_CONFIG_COMMANDS_PRE(
7670
[if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then
7671
AC_MSG_ERROR([[conditional "$1" was never defined.
7672
Usually this means the macro was only invoked conditionally.]])
7675
# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006
7676
# Free Software Foundation, Inc.
7678
# This file is free software; the Free Software Foundation
7679
# gives unlimited permission to copy and/or distribute it,
7680
# with or without modifications, as long as this notice is preserved.
7684
# There are a few dirty hacks below to avoid letting `AC_PROG_CC' be
7685
# written in clear, in which case automake, when reading aclocal.m4,
7686
# will think it sees a *use*, and therefore will trigger all it's
7687
# C support machinery. Also note that it means that autoscan, seeing
7688
# CC etc. in the Makefile, will ask for an AC_PROG_CC use...
7691
# _AM_DEPENDENCIES(NAME)
7692
# ----------------------
7693
# See how the compiler implements dependency checking.
7694
# NAME is "CC", "CXX", "GCJ", or "OBJC".
7695
# We try a few techniques and use that to set a single cache variable.
7697
# We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was
7698
# modified to invoke _AM_DEPENDENCIES(CC); we would have a circular
7699
# dependency, and given that the user is not expected to run this macro,
7700
# just rely on AC_PROG_CC.
7701
AC_DEFUN([_AM_DEPENDENCIES],
7702
[AC_REQUIRE([AM_SET_DEPDIR])dnl
7703
AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl
7704
AC_REQUIRE([AM_MAKE_INCLUDE])dnl
7705
AC_REQUIRE([AM_DEP_TRACK])dnl
7707
ifelse([$1], CC, [depcc="$CC" am_compiler_list=],
7708
[$1], CXX, [depcc="$CXX" am_compiler_list=],
7709
[$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc'],
7710
[$1], UPC, [depcc="$UPC" am_compiler_list=],
7711
[$1], GCJ, [depcc="$GCJ" am_compiler_list='gcc3 gcc'],
7712
[depcc="$$1" am_compiler_list=])
7714
AC_CACHE_CHECK([dependency style of $depcc],
7715
[am_cv_$1_dependencies_compiler_type],
7716
[if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
7717
# We make a subdir and do the tests there. Otherwise we can end up
7718
# making bogus files that we don't know about and never remove. For
7719
# instance it was reported that on HP-UX the gcc test will end up
7720
# making a dummy file named `D' -- because `-MD' means `put the output
7723
# Copy depcomp to subdir because otherwise we won't find it if we're
7724
# using a relative directory.
7725
cp "$am_depcomp" conftest.dir
7727
# We will build objects and dependencies in a subdirectory because
7728
# it helps to detect inapplicable dependency modes. For instance
7729
# both Tru64's cc and ICC support -MD to output dependencies as a
7730
# side effect of compilation, but ICC will put the dependencies in
7731
# the current directory while Tru64 will put them in the object
7735
am_cv_$1_dependencies_compiler_type=none
7736
if test "$am_compiler_list" = ""; then
7737
am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp`
7739
for depmode in $am_compiler_list; do
7740
# Setup a source with many dependencies, because some compilers
7741
# like to wrap large dependency lists on column 80 (with \), and
7742
# we should not choose a depcomp mode which is confused by this.
7744
# We need to recreate these files for each test, as the compiler may
7745
# overwrite some of them when testing with obscure command lines.
7746
# This happens at least with the AIX C compiler.
7748
for i in 1 2 3 4 5 6; do
7749
echo '#include "conftst'$i'.h"' >> sub/conftest.c
7750
# Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
7751
# Solaris 8's {/usr,}/bin/sh.
7752
touch sub/conftst$i.h
7754
echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
7758
# after this tag, mechanisms are not by side-effect, so they'll
7759
# only be used when explicitly requested
7760
if test "x$enable_dependency_tracking" = xyes; then
7768
# We check with `-c' and `-o' for the sake of the "dashmstdout"
7769
# mode. It turns out that the SunPro C++ compiler does not properly
7770
# handle `-M -o', and we need to detect this.
7771
if depmode=$depmode \
7772
source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \
7773
depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
7774
$SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \
7775
>/dev/null 2>conftest.err &&
7776
grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
7777
grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
7778
grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 &&
7779
${MAKE-make} -s -f confmf > /dev/null 2>&1; then
7780
# icc doesn't choke on unknown options, it will just issue warnings
7781
# or remarks (even with -Werror). So we grep stderr for any message
7782
# that says an option was ignored or not supported.
7783
# When given -MP, icc 7.0 and 7.1 complain thusly:
7784
# icc: Command line warning: ignoring option '-M'; no argument required
7785
# The diagnosis changed in icc 8.0:
7786
# icc: Command line remark: option '-MP' not supported
7787
if (grep 'ignoring option' conftest.err ||
7788
grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
7789
am_cv_$1_dependencies_compiler_type=$depmode
7798
am_cv_$1_dependencies_compiler_type=none
7801
AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type])
7802
AM_CONDITIONAL([am__fastdep$1], [
7803
test "x$enable_dependency_tracking" != xno \
7804
&& test "$am_cv_$1_dependencies_compiler_type" = gcc3])
7810
# Choose a directory name for dependency files.
7811
# This macro is AC_REQUIREd in _AM_DEPENDENCIES
7812
AC_DEFUN([AM_SET_DEPDIR],
7813
[AC_REQUIRE([AM_SET_LEADING_DOT])dnl
7814
AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl
7820
AC_DEFUN([AM_DEP_TRACK],
7821
[AC_ARG_ENABLE(dependency-tracking,
7822
[ --disable-dependency-tracking speeds up one-time build
7823
--enable-dependency-tracking do not reject slow dependency extractors])
7824
if test "x$enable_dependency_tracking" != xno; then
7825
am_depcomp="$ac_aux_dir/depcomp"
7828
AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno])
7829
AC_SUBST([AMDEPBACKSLASH])dnl
7830
_AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl
7833
# Generate code to set up dependency tracking. -*- Autoconf -*-
7835
# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005
7836
# Free Software Foundation, Inc.
7838
# This file is free software; the Free Software Foundation
7839
# gives unlimited permission to copy and/or distribute it,
7840
# with or without modifications, as long as this notice is preserved.
7844
# _AM_OUTPUT_DEPENDENCY_COMMANDS
7845
# ------------------------------
7846
AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
7847
[for mf in $CONFIG_FILES; do
7848
# Strip MF so we end up with the name of the file.
7849
mf=`echo "$mf" | sed -e 's/:.*$//'`
7850
# Check whether this is an Automake generated Makefile or not.
7851
# We used to match only the files named `Makefile.in', but
7852
# some people rename them; so instead we look at the file content.
7853
# Grep'ing the first line is not enough: some people post-process
7854
# each Makefile.in and add a new line on top of each file to say so.
7855
# Grep'ing the whole file is not good either: AIX grep has a line
7856
# limit of 2048, but all sed's we know have understand at least 4000.
7857
if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
7858
dirpart=`AS_DIRNAME("$mf")`
7862
# Extract the definition of DEPDIR, am__include, and am__quote
7863
# from the Makefile without running `make'.
7864
DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
7865
test -z "$DEPDIR" && continue
7866
am__include=`sed -n 's/^am__include = //p' < "$mf"`
7867
test -z "am__include" && continue
7868
am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
7869
# When using ansi2knr, U may be empty or an underscore; expand it
7870
U=`sed -n 's/^U = //p' < "$mf"`
7871
# Find all dependency output files, they are included files with
7872
# $(DEPDIR) in their names. We invoke sed twice because it is the
7873
# simplest approach to changing $(DEPDIR) to its actual value in the
7875
for file in `sed -n "
7876
s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
7877
sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
7878
# Make sure the directory exists.
7879
test -f "$dirpart/$file" && continue
7880
fdir=`AS_DIRNAME(["$file"])`
7881
AS_MKDIR_P([$dirpart/$fdir])
7882
# echo "creating $dirpart/$file"
7883
echo '# dummy' > "$dirpart/$file"
7886
])# _AM_OUTPUT_DEPENDENCY_COMMANDS
7889
# AM_OUTPUT_DEPENDENCY_COMMANDS
7890
# -----------------------------
7891
# This macro should only be invoked once -- use via AC_REQUIRE.
7893
# This code is only required when automatic dependency tracking
7894
# is enabled. FIXME. This creates each `.P' file that we will
7895
# need in order to bootstrap the dependency handling code.
7896
AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
7897
[AC_CONFIG_COMMANDS([depfiles],
7898
[test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS],
7899
[AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"])
7902
# Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005
7903
# Free Software Foundation, Inc.
7905
# This file is free software; the Free Software Foundation
7906
# gives unlimited permission to copy and/or distribute it,
7907
# with or without modifications, as long as this notice is preserved.
7911
# AM_CONFIG_HEADER is obsolete. It has been replaced by AC_CONFIG_HEADERS.
7912
AU_DEFUN([AM_CONFIG_HEADER], [AC_CONFIG_HEADERS($@)])
7914
# Do all the work for Automake. -*- Autoconf -*-
7916
# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
7917
# 2005, 2006, 2008 Free Software Foundation, Inc.
7919
# This file is free software; the Free Software Foundation
7920
# gives unlimited permission to copy and/or distribute it,
7921
# with or without modifications, as long as this notice is preserved.
7925
# This macro actually does too much. Some checks are only needed if
7926
# your package does certain things. But this isn't really a big deal.
7928
# AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE])
7929
# AM_INIT_AUTOMAKE([OPTIONS])
7930
# -----------------------------------------------
7931
# The call with PACKAGE and VERSION arguments is the old style
7932
# call (pre autoconf-2.50), which is being phased out. PACKAGE
7933
# and VERSION should now be passed to AC_INIT and removed from
7934
# the call to AM_INIT_AUTOMAKE.
7935
# We support both call styles for the transition. After
7936
# the next Automake release, Autoconf can make the AC_INIT
7937
# arguments mandatory, and then we can depend on a new Autoconf
7938
# release and drop the old call support.
7939
AC_DEFUN([AM_INIT_AUTOMAKE],
7940
[AC_PREREQ([2.60])dnl
7941
dnl Autoconf wants to disallow AM_ names. We explicitly allow
7942
dnl the ones we care about.
7943
m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
7944
AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl
7945
AC_REQUIRE([AC_PROG_INSTALL])dnl
7946
if test "`cd $srcdir && pwd`" != "`pwd`"; then
7947
# Use -I$(srcdir) only when $(srcdir) != ., so that make's output
7948
# is not polluted with repeated "-I."
7949
AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl
7950
# test to see if srcdir already configured
7951
if test -f $srcdir/config.status; then
7952
AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
7956
# test whether we have cygpath
7957
if test -z "$CYGPATH_W"; then
7958
if (cygpath --version) >/dev/null 2>/dev/null; then
7959
CYGPATH_W='cygpath -w'
7964
AC_SUBST([CYGPATH_W])
7966
# Define the identity of the package.
7967
dnl Distinguish between old-style and new-style calls.
7969
[m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl
7970
AC_SUBST([PACKAGE], [$1])dnl
7971
AC_SUBST([VERSION], [$2])],
7972
[_AM_SET_OPTIONS([$1])dnl
7973
dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT.
7974
m4_if(m4_ifdef([AC_PACKAGE_NAME], 1)m4_ifdef([AC_PACKAGE_VERSION], 1), 11,,
7975
[m4_fatal([AC_INIT should be called with package and version arguments])])dnl
7976
AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl
7977
AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl
7979
_AM_IF_OPTION([no-define],,
7980
[AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
7981
AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl
7983
# Some tools Automake needs.
7984
AC_REQUIRE([AM_SANITY_CHECK])dnl
7985
AC_REQUIRE([AC_ARG_PROGRAM])dnl
7986
AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version})
7987
AM_MISSING_PROG(AUTOCONF, autoconf)
7988
AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version})
7989
AM_MISSING_PROG(AUTOHEADER, autoheader)
7990
AM_MISSING_PROG(MAKEINFO, makeinfo)
7992
AM_PROG_INSTALL_STRIP
7993
AC_REQUIRE([AM_PROG_MKDIR_P])dnl
7994
# We need awk for the "check" target. The system "awk" is bad on
7996
AC_REQUIRE([AC_PROG_AWK])dnl
7997
AC_REQUIRE([AC_PROG_MAKE_SET])dnl
7998
AC_REQUIRE([AM_SET_LEADING_DOT])dnl
7999
_AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])],
8000
[_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])],
8001
[_AM_PROG_TAR([v7])])])
8002
_AM_IF_OPTION([no-dependencies],,
8003
[AC_PROVIDE_IFELSE([AC_PROG_CC],
8004
[_AM_DEPENDENCIES(CC)],
8005
[define([AC_PROG_CC],
8006
defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl
8007
AC_PROVIDE_IFELSE([AC_PROG_CXX],
8008
[_AM_DEPENDENCIES(CXX)],
8009
[define([AC_PROG_CXX],
8010
defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl
8011
AC_PROVIDE_IFELSE([AC_PROG_OBJC],
8012
[_AM_DEPENDENCIES(OBJC)],
8013
[define([AC_PROG_OBJC],
8014
defn([AC_PROG_OBJC])[_AM_DEPENDENCIES(OBJC)])])dnl
8019
# When config.status generates a header, we must update the stamp-h file.
8020
# This file resides in the same directory as the config header
8021
# that is generated. The stamp files are numbered to have different names.
8023
# Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the
8024
# loop where config.status creates the headers, so we can generate
8025
# our stamp files there.
8026
AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK],
8027
[# Compute $1's index in $config_headers.
8030
for _am_header in $config_headers :; do
8032
$_am_arg | $_am_arg:* )
8035
_am_stamp_count=`expr $_am_stamp_count + 1` ;;
8038
echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count])
8040
# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc.
8042
# This file is free software; the Free Software Foundation
8043
# gives unlimited permission to copy and/or distribute it,
8044
# with or without modifications, as long as this notice is preserved.
8046
# AM_PROG_INSTALL_SH
8047
# ------------------
8048
# Define $install_sh.
8049
AC_DEFUN([AM_PROG_INSTALL_SH],
8050
[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
8051
install_sh=${install_sh-"\$(SHELL) $am_aux_dir/install-sh"}
8052
AC_SUBST(install_sh)])
8054
# Copyright (C) 2003, 2005 Free Software Foundation, Inc.
8056
# This file is free software; the Free Software Foundation
8057
# gives unlimited permission to copy and/or distribute it,
8058
# with or without modifications, as long as this notice is preserved.
8062
# Check whether the underlying file-system supports filenames
8063
# with a leading dot. For instance MS-DOS doesn't.
8064
AC_DEFUN([AM_SET_LEADING_DOT],
8065
[rm -rf .tst 2>/dev/null
8066
mkdir .tst 2>/dev/null
8067
if test -d .tst; then
8072
rmdir .tst 2>/dev/null
8073
AC_SUBST([am__leading_dot])])
8075
# Add --enable-maintainer-mode option to configure. -*- Autoconf -*-
8078
# Copyright (C) 1996, 1998, 2000, 2001, 2002, 2003, 2004, 2005
8079
# Free Software Foundation, Inc.
8081
# This file is free software; the Free Software Foundation
8082
# gives unlimited permission to copy and/or distribute it,
8083
# with or without modifications, as long as this notice is preserved.
8087
AC_DEFUN([AM_MAINTAINER_MODE],
8088
[AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles])
8089
dnl maintainer-mode is disabled by default
8090
AC_ARG_ENABLE(maintainer-mode,
8091
[ --enable-maintainer-mode enable make rules and dependencies not useful
8092
(and sometimes confusing) to the casual installer],
8093
USE_MAINTAINER_MODE=$enableval,
8094
USE_MAINTAINER_MODE=no)
8095
AC_MSG_RESULT([$USE_MAINTAINER_MODE])
8096
AM_CONDITIONAL(MAINTAINER_MODE, [test $USE_MAINTAINER_MODE = yes])
8097
MAINT=$MAINTAINER_MODE_TRUE
8102
AU_DEFUN([jm_MAINTAINER_MODE], [AM_MAINTAINER_MODE])
8104
# Check to see how 'make' treats includes. -*- Autoconf -*-
8106
# Copyright (C) 2001, 2002, 2003, 2005 Free Software Foundation, Inc.
8108
# This file is free software; the Free Software Foundation
8109
# gives unlimited permission to copy and/or distribute it,
8110
# with or without modifications, as long as this notice is preserved.
8116
# Check to see how make treats includes.
8117
AC_DEFUN([AM_MAKE_INCLUDE],
8118
[am_make=${MAKE-make}
8119
cat > confinc << 'END'
8124
# If we don't find an include directive, just comment out the code.
8125
AC_MSG_CHECKING([for style of include used by $am_make])
8129
# First try GNU make style include.
8130
echo "include confinc" > confmf
8131
# We grep out `Entering directory' and `Leaving directory'
8132
# messages which can occur if `w' ends up in MAKEFLAGS.
8133
# In particular we don't look at `^make:' because GNU make might
8134
# be invoked under some other name (usually "gmake"), in which
8135
# case it prints its new name instead of `make'.
8136
if test "`$am_make -s -f confmf 2> /dev/null | grep -v 'ing directory'`" = "done"; then
8141
# Now try BSD make style include.
8142
if test "$am__include" = "#"; then
8143
echo '.include "confinc"' > confmf
8144
if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then
8145
am__include=.include
8150
AC_SUBST([am__include])
8151
AC_SUBST([am__quote])
8152
AC_MSG_RESULT([$_am_result])
8153
rm -f confinc confmf
8156
# Fake the existence of programs that GNU maintainers use. -*- Autoconf -*-
8158
# Copyright (C) 1997, 1999, 2000, 2001, 2003, 2004, 2005
8159
# Free Software Foundation, Inc.
8161
# This file is free software; the Free Software Foundation
8162
# gives unlimited permission to copy and/or distribute it,
8163
# with or without modifications, as long as this notice is preserved.
8167
# AM_MISSING_PROG(NAME, PROGRAM)
8168
# ------------------------------
8169
AC_DEFUN([AM_MISSING_PROG],
8170
[AC_REQUIRE([AM_MISSING_HAS_RUN])
8171
$1=${$1-"${am_missing_run}$2"}
8175
# AM_MISSING_HAS_RUN
8176
# ------------------
8177
# Define MISSING if not defined so far and test if it supports --run.
8178
# If it does, set am_missing_run to use it, otherwise, to nothing.
8179
AC_DEFUN([AM_MISSING_HAS_RUN],
8180
[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
8181
AC_REQUIRE_AUX_FILE([missing])dnl
8182
test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing"
8183
# Use eval to expand $SHELL
8184
if eval "$MISSING --run true"; then
8185
am_missing_run="$MISSING --run "
8188
AC_MSG_WARN([`missing' script is too old or missing])
8192
# Copyright (C) 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
8194
# This file is free software; the Free Software Foundation
8195
# gives unlimited permission to copy and/or distribute it,
8196
# with or without modifications, as long as this notice is preserved.
8200
# Check for `mkdir -p'.
8201
AC_DEFUN([AM_PROG_MKDIR_P],
8202
[AC_PREREQ([2.60])dnl
8203
AC_REQUIRE([AC_PROG_MKDIR_P])dnl
8204
dnl Automake 1.8 to 1.9.6 used to define mkdir_p. We now use MKDIR_P,
8205
dnl while keeping a definition of mkdir_p for backward compatibility.
8206
dnl @MKDIR_P@ is magic: AC_OUTPUT adjusts its value for each Makefile.
8207
dnl However we cannot define mkdir_p as $(MKDIR_P) for the sake of
8208
dnl Makefile.ins that do not define MKDIR_P, so we do our own
8209
dnl adjustment using top_builddir (which is defined more often than
8211
AC_SUBST([mkdir_p], ["$MKDIR_P"])dnl
8213
[[\\/$]]* | ?:[[\\/]]*) ;;
8214
*/*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
8218
# Helper functions for option handling. -*- Autoconf -*-
8220
# Copyright (C) 2001, 2002, 2003, 2005 Free Software Foundation, Inc.
8222
# This file is free software; the Free Software Foundation
8223
# gives unlimited permission to copy and/or distribute it,
8224
# with or without modifications, as long as this notice is preserved.
8228
# _AM_MANGLE_OPTION(NAME)
8229
# -----------------------
8230
AC_DEFUN([_AM_MANGLE_OPTION],
8231
[[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])])
8233
# _AM_SET_OPTION(NAME)
8234
# ------------------------------
8235
# Set option NAME. Presently that only means defining a flag for this option.
8236
AC_DEFUN([_AM_SET_OPTION],
8237
[m4_define(_AM_MANGLE_OPTION([$1]), 1)])
8239
# _AM_SET_OPTIONS(OPTIONS)
8240
# ----------------------------------
8241
# OPTIONS is a space-separated list of Automake options.
8242
AC_DEFUN([_AM_SET_OPTIONS],
8243
[AC_FOREACH([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])])
8245
# _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET])
8246
# -------------------------------------------
8247
# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
8248
AC_DEFUN([_AM_IF_OPTION],
8249
[m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
8251
# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005
8252
# Free Software Foundation, Inc.
8254
# This file is free software; the Free Software Foundation
8255
# gives unlimited permission to copy and/or distribute it,
8256
# with or without modifications, as long as this notice is preserved.
8258
# AM_PATH_PYTHON([MINIMUM-VERSION], [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
8259
# ---------------------------------------------------------------------------
8260
# Adds support for distributing Python modules and packages. To
8261
# install modules, copy them to $(pythondir), using the python_PYTHON
8262
# automake variable. To install a package with the same name as the
8263
# automake package, install to $(pkgpythondir), or use the
8264
# pkgpython_PYTHON automake variable.
8266
# The variables $(pyexecdir) and $(pkgpyexecdir) are provided as
8267
# locations to install python extension modules (shared libraries).
8268
# Another macro is required to find the appropriate flags to compile
8269
# extension modules.
8271
# If your package is configured with a different prefix to python,
8272
# users will have to add the install directory to the PYTHONPATH
8273
# environment variable, or create a .pth file (see the python
8274
# documentation for details).
8276
# If the MINIMUM-VERSION argument is passed, AM_PATH_PYTHON will
8277
# cause an error if the version of python installed on the system
8278
# doesn't meet the requirement. MINIMUM-VERSION should consist of
8279
# numbers and dots only.
8280
AC_DEFUN([AM_PATH_PYTHON],
8282
dnl Find a Python interpreter. Python versions prior to 1.5 are not
8283
dnl supported because the default installation locations changed from
8284
dnl $prefix/lib/site-python in 1.4 to $prefix/lib/python1.5/site-packages
8286
m4_define_default([_AM_PYTHON_INTERPRETER_LIST],
8287
[python python2 python2.5 python2.4 python2.3 python2.2 dnl
8288
python2.1 python2.0 python1.6 python1.5])
8291
dnl No version check is needed.
8292
# Find any Python interpreter.
8293
if test -z "$PYTHON"; then
8294
AC_PATH_PROGS([PYTHON], _AM_PYTHON_INTERPRETER_LIST, :)
8296
am_display_PYTHON=python
8298
dnl A version check is needed.
8299
if test -n "$PYTHON"; then
8300
# If the user set $PYTHON, use it and don't search something else.
8301
AC_MSG_CHECKING([whether $PYTHON version >= $1])
8302
AM_PYTHON_CHECK_VERSION([$PYTHON], [$1],
8303
[AC_MSG_RESULT(yes)],
8304
[AC_MSG_ERROR(too old)])
8305
am_display_PYTHON=$PYTHON
8307
# Otherwise, try each interpreter until we find one that satisfies
8309
AC_CACHE_CHECK([for a Python interpreter with version >= $1],
8310
[am_cv_pathless_PYTHON],[
8311
for am_cv_pathless_PYTHON in _AM_PYTHON_INTERPRETER_LIST none; do
8312
test "$am_cv_pathless_PYTHON" = none && break
8313
AM_PYTHON_CHECK_VERSION([$am_cv_pathless_PYTHON], [$1], [break])
8315
# Set $PYTHON to the absolute path of $am_cv_pathless_PYTHON.
8316
if test "$am_cv_pathless_PYTHON" = none; then
8319
AC_PATH_PROG([PYTHON], [$am_cv_pathless_PYTHON])
8321
am_display_PYTHON=$am_cv_pathless_PYTHON
8325
if test "$PYTHON" = :; then
8326
dnl Run any user-specified action, or abort.
8327
m4_default([$3], [AC_MSG_ERROR([no suitable Python interpreter found])])
8330
dnl Query Python for its version number. Getting [:3] seems to be
8331
dnl the best way to do this; it's what "site.py" does in the standard
8334
AC_CACHE_CHECK([for $am_display_PYTHON version], [am_cv_python_version],
8335
[am_cv_python_version=`$PYTHON -c "import sys; print sys.version[[:3]]"`])
8336
AC_SUBST([PYTHON_VERSION], [$am_cv_python_version])
8338
dnl Use the values of $prefix and $exec_prefix for the corresponding
8339
dnl values of PYTHON_PREFIX and PYTHON_EXEC_PREFIX. These are made
8340
dnl distinct variables so they can be overridden if need be. However,
8341
dnl general consensus is that you shouldn't need this ability.
8343
AC_SUBST([PYTHON_PREFIX], ['${prefix}'])
8344
AC_SUBST([PYTHON_EXEC_PREFIX], ['${exec_prefix}'])
8346
dnl At times (like when building shared libraries) you may want
8347
dnl to know which OS platform Python thinks this is.
8349
AC_CACHE_CHECK([for $am_display_PYTHON platform], [am_cv_python_platform],
8350
[am_cv_python_platform=`$PYTHON -c "import sys; print sys.platform"`])
8351
AC_SUBST([PYTHON_PLATFORM], [$am_cv_python_platform])
8354
dnl Set up 4 directories:
8356
dnl pythondir -- where to install python scripts. This is the
8357
dnl site-packages directory, not the python standard library
8358
dnl directory like in previous automake betas. This behavior
8359
dnl is more consistent with lispdir.m4 for example.
8360
dnl Query distutils for this directory. distutils does not exist in
8361
dnl Python 1.5, so we fall back to the hardcoded directory if it
8363
AC_CACHE_CHECK([for $am_display_PYTHON script directory],
8364
[am_cv_python_pythondir],
8365
[am_cv_python_pythondir=`$PYTHON -c "from distutils import sysconfig; print sysconfig.get_python_lib(0,0,prefix='$PYTHON_PREFIX')" 2>/dev/null ||
8366
echo "$PYTHON_PREFIX/lib/python$PYTHON_VERSION/site-packages"`])
8367
AC_SUBST([pythondir], [$am_cv_python_pythondir])
8369
dnl pkgpythondir -- $PACKAGE directory under pythondir. Was
8370
dnl PYTHON_SITE_PACKAGE in previous betas, but this naming is
8371
dnl more consistent with the rest of automake.
8373
AC_SUBST([pkgpythondir], [\${pythondir}/$PACKAGE])
8375
dnl pyexecdir -- directory for installing python extension modules
8376
dnl (shared libraries)
8377
dnl Query distutils for this directory. distutils does not exist in
8378
dnl Python 1.5, so we fall back to the hardcoded directory if it
8380
AC_CACHE_CHECK([for $am_display_PYTHON extension module directory],
8381
[am_cv_python_pyexecdir],
8382
[am_cv_python_pyexecdir=`$PYTHON -c "from distutils import sysconfig; print sysconfig.get_python_lib(1,0,prefix='$PYTHON_EXEC_PREFIX')" 2>/dev/null ||
8383
echo "${PYTHON_EXEC_PREFIX}/lib/python${PYTHON_VERSION}/site-packages"`])
8384
AC_SUBST([pyexecdir], [$am_cv_python_pyexecdir])
8386
dnl pkgpyexecdir -- $(pyexecdir)/$(PACKAGE)
8388
AC_SUBST([pkgpyexecdir], [\${pyexecdir}/$PACKAGE])
8390
dnl Run any user-specified action.
8397
# AM_PYTHON_CHECK_VERSION(PROG, VERSION, [ACTION-IF-TRUE], [ACTION-IF-FALSE])
8398
# ---------------------------------------------------------------------------
8399
# Run ACTION-IF-TRUE if the Python interpreter PROG has version >= VERSION.
8400
# Run ACTION-IF-FALSE otherwise.
8401
# This test uses sys.hexversion instead of the string equivalent (first
8402
# word of sys.version), in order to cope with versions such as 2.2c1.
8403
# hexversion has been introduced in Python 1.5.2; it's probably not
8404
# worth to support older versions (1.5.1 was released on October 31, 1998).
8405
AC_DEFUN([AM_PYTHON_CHECK_VERSION],
8406
[prog="import sys, string
8407
# split strings by '.' and convert to numeric. Append some zeros
8408
# because we need at least 4 digits for the hex conversion.
8409
minver = map(int, string.split('$2', '.')) + [[0, 0, 0]]
8411
for i in xrange(0, 4): minverhex = (minverhex << 8) + minver[[i]]
8412
sys.exit(sys.hexversion < minverhex)"
8413
AS_IF([AM_RUN_LOG([$1 -c "$prog"])], [$3], [$4])])
8415
# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc.
8417
# This file is free software; the Free Software Foundation
8418
# gives unlimited permission to copy and/or distribute it,
8419
# with or without modifications, as long as this notice is preserved.
8421
# AM_RUN_LOG(COMMAND)
8422
# -------------------
8423
# Run COMMAND, save the exit status in ac_status, and log it.
8424
# (This has been adapted from Autoconf's _AC_RUN_LOG macro.)
8425
AC_DEFUN([AM_RUN_LOG],
8426
[{ echo "$as_me:$LINENO: $1" >&AS_MESSAGE_LOG_FD
8427
($1) >&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD
8429
echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
8430
(exit $ac_status); }])
8432
# Check to make sure that the build environment is sane. -*- Autoconf -*-
8434
# Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005
8435
# Free Software Foundation, Inc.
8437
# This file is free software; the Free Software Foundation
8438
# gives unlimited permission to copy and/or distribute it,
8439
# with or without modifications, as long as this notice is preserved.
8445
AC_DEFUN([AM_SANITY_CHECK],
8446
[AC_MSG_CHECKING([whether build environment is sane])
8449
echo timestamp > conftest.file
8450
# Do `set' in a subshell so we don't clobber the current shell's
8451
# arguments. Must try -L first in case configure is actually a
8452
# symlink; some systems play weird games with the mod time of symlinks
8453
# (eg FreeBSD returns the mod time of the symlink's containing
8456
set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null`
8457
if test "$[*]" = "X"; then
8459
set X `ls -t $srcdir/configure conftest.file`
8462
if test "$[*]" != "X $srcdir/configure conftest.file" \
8463
&& test "$[*]" != "X conftest.file $srcdir/configure"; then
8465
# If neither matched, then we have a broken ls. This can happen
8466
# if, for instance, CONFIG_SHELL is bash and it inherits a
8467
# broken ls alias from the environment. This has actually
8468
# happened. Such a system could not be considered "sane".
8469
AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken
8470
alias in your environment])
8473
test "$[2]" = conftest.file
8479
AC_MSG_ERROR([newly created file is older than distributed files!
8480
Check your system clock])
8482
AC_MSG_RESULT(yes)])
8484
# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc.
8486
# This file is free software; the Free Software Foundation
8487
# gives unlimited permission to copy and/or distribute it,
8488
# with or without modifications, as long as this notice is preserved.
8490
# AM_PROG_INSTALL_STRIP
8491
# ---------------------
8492
# One issue with vendor `install' (even GNU) is that you can't
8493
# specify the program used to strip binaries. This is especially
8494
# annoying in cross-compiling environments, where the build's strip
8495
# is unlikely to handle the host's binaries.
8496
# Fortunately install-sh will honor a STRIPPROG variable, so we
8497
# always use install-sh in `make install-strip', and initialize
8498
# STRIPPROG with the value of the STRIP variable (set by the user).
8499
AC_DEFUN([AM_PROG_INSTALL_STRIP],
8500
[AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
8501
# Installed binaries are usually stripped using `strip' when the user
8502
# run `make install-strip'. However `strip' might not be the right
8503
# tool to use in cross-compilation environments, therefore Automake
8504
# will honor the `STRIP' environment variable to overrule this program.
8505
dnl Don't test for $cross_compiling = yes, because it might be `maybe'.
8506
if test "$cross_compiling" != no; then
8507
AC_CHECK_TOOL([STRIP], [strip], :)
8509
INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
8510
AC_SUBST([INSTALL_STRIP_PROGRAM])])
8512
# Copyright (C) 2006 Free Software Foundation, Inc.
8514
# This file is free software; the Free Software Foundation
8515
# gives unlimited permission to copy and/or distribute it,
8516
# with or without modifications, as long as this notice is preserved.
8518
# _AM_SUBST_NOTMAKE(VARIABLE)
8519
# ---------------------------
8520
# Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in.
8521
# This macro is traced by Automake.
8522
AC_DEFUN([_AM_SUBST_NOTMAKE])
8524
# Check how to create a tarball. -*- Autoconf -*-
8526
# Copyright (C) 2004, 2005 Free Software Foundation, Inc.
8528
# This file is free software; the Free Software Foundation
8529
# gives unlimited permission to copy and/or distribute it,
8530
# with or without modifications, as long as this notice is preserved.
8534
# _AM_PROG_TAR(FORMAT)
8535
# --------------------
8536
# Check how to create a tarball in format FORMAT.
8537
# FORMAT should be one of `v7', `ustar', or `pax'.
8539
# Substitute a variable $(am__tar) that is a command
8540
# writing to stdout a FORMAT-tarball containing the directory
8542
# tardir=directory && $(am__tar) > result.tar
8544
# Substitute a variable $(am__untar) that extract such
8545
# a tarball read from stdin.
8546
# $(am__untar) < result.tar
8547
AC_DEFUN([_AM_PROG_TAR],
8548
[# Always define AMTAR for backward compatibility.
8549
AM_MISSING_PROG([AMTAR], [tar])
8551
[am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'],
8552
[m4_case([$1], [ustar],, [pax],,
8553
[m4_fatal([Unknown tar format])])
8554
AC_MSG_CHECKING([how to create a $1 tar archive])
8555
# Loop over all known methods to create a tar archive until one works.
8556
_am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none'
8557
_am_tools=${am_cv_prog_tar_$1-$_am_tools}
8558
# Do not fold the above two line into one, because Tru64 sh and
8559
# Solaris sh will not grok spaces in the rhs of `-'.
8560
for _am_tool in $_am_tools
8564
for _am_tar in tar gnutar gtar;
8566
AM_RUN_LOG([$_am_tar --version]) && break
8568
am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"'
8569
am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"'
8570
am__untar="$_am_tar -xf -"
8573
# Must skip GNU tar: if it does not support --format= it doesn't create
8574
# ustar tarball either.
8575
(tar --version) >/dev/null 2>&1 && continue
8576
am__tar='tar chf - "$$tardir"'
8577
am__tar_='tar chf - "$tardir"'
8578
am__untar='tar xf -'
8581
am__tar='pax -L -x $1 -w "$$tardir"'
8582
am__tar_='pax -L -x $1 -w "$tardir"'
8586
am__tar='find "$$tardir" -print | cpio -o -H $1 -L'
8587
am__tar_='find "$tardir" -print | cpio -o -H $1 -L'
8588
am__untar='cpio -i -H $1 -d'
8597
# If the value was cached, stop now. We just wanted to have am__tar
8598
# and am__untar set.
8599
test -n "${am_cv_prog_tar_$1}" && break
8601
# tar/untar a dummy directory, and stop if the command works
8604
echo GrepMe > conftest.dir/file
8605
AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar])
8607
if test -s conftest.tar; then
8608
AM_RUN_LOG([$am__untar <conftest.tar])
8609
grep GrepMe conftest.dir/file >/dev/null 2>&1 && break
8614
AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool])
8615
AC_MSG_RESULT([$am_cv_prog_tar_$1])])
8617
AC_SUBST([am__untar])
8620
8424
m4_include([acinclude.m4])