1 # generated automatically by aclocal 1.12.2 -*- Autoconf -*-
3 # Copyright (C) 1996-2012 Free Software Foundation, Inc.
5 # This file is free software; the Free Software Foundation
6 # gives unlimited permission to copy and/or distribute it,
7 # with or without modifications, as long as this notice is preserved.
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
11 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
14 m4_ifndef([AC_AUTOCONF_VERSION],
15 [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
16 m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.69],,
17 [m4_warning([this file was generated for autoconf 2.69.
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'.])])
22 dnl Configure Paths for Alsa
23 dnl Some modifications by Richard Boulton <richard-alsa@tartarus.org>
24 dnl Christopher Lansdown <lansdoct@cs.alfred.edu>
25 dnl Jaroslav Kysela <perex@perex.cz>
26 dnl Last modification: $Id: alsa.m4,v 1.24 2004/09/15 18:48:07 tiwai Exp $
27 dnl AM_PATH_ALSA([MINIMUM-VERSION [, ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND]]])
28 dnl Test for libasound, and define ALSA_CFLAGS and ALSA_LIBS as appropriate.
29 dnl enables arguments --with-alsa-prefix=
30 dnl --with-alsa-enc-prefix=
31 dnl --disable-alsatest
33 dnl For backwards compatibility, if ACTION_IF_NOT_FOUND is not specified,
34 dnl and the alsa libraries are not found, a fatal AC_MSG_ERROR() will result.
36 AC_DEFUN([AM_PATH_ALSA],
37 [dnl Save the original CFLAGS, LDFLAGS, and LIBS
38 alsa_save_CFLAGS="$CFLAGS"
39 alsa_save_LDFLAGS="$LDFLAGS"
40 alsa_save_LIBS="$LIBS"
44 dnl Get the cflags and libraries for alsa
46 AC_ARG_WITH(alsa-prefix,
47 [ --with-alsa-prefix=PFX Prefix where Alsa library is installed(optional)],
48 [alsa_prefix="$withval"], [alsa_prefix=""])
50 AC_ARG_WITH(alsa-inc-prefix,
51 [ --with-alsa-inc-prefix=PFX Prefix where include libraries are (optional)],
52 [alsa_inc_prefix="$withval"], [alsa_inc_prefix=""])
54 dnl FIXME: this is not yet implemented
55 AC_ARG_ENABLE(alsatest,
56 [ --disable-alsatest Do not try to compile and run a test Alsa program],
57 [enable_alsatest="$enableval"],
58 [enable_alsatest=yes])
60 dnl Add any special include directories
61 AC_MSG_CHECKING(for ALSA CFLAGS)
62 if test "$alsa_inc_prefix" != "" ; then
63 ALSA_CFLAGS="$ALSA_CFLAGS -I$alsa_inc_prefix"
64 CFLAGS="$CFLAGS -I$alsa_inc_prefix"
66 AC_MSG_RESULT($ALSA_CFLAGS)
68 dnl add any special lib dirs
69 AC_MSG_CHECKING(for ALSA LDFLAGS)
70 if test "$alsa_prefix" != "" ; then
71 ALSA_LIBS="$ALSA_LIBS -L$alsa_prefix"
72 LDFLAGS="$LDFLAGS $ALSA_LIBS"
75 dnl add the alsa library
76 ALSA_LIBS="$ALSA_LIBS -lasound -lm -ldl -lpthread"
77 LIBS="$ALSA_LIBS $LIBS"
78 AC_MSG_RESULT($ALSA_LIBS)
80 dnl Check for a working version of libasound that is of the right version.
81 if test "x$enable_alsatest" = "xyes"; then
82 min_alsa_version=ifelse([$1], ,0.1.1,$1)
83 AC_MSG_CHECKING(for libasound headers version >= $min_alsa_version)
85 alsa_min_major_version=`echo $min_alsa_version | \
86 sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\1/'`
87 alsa_min_minor_version=`echo $min_alsa_version | \
88 sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\2/'`
89 alsa_min_micro_version=`echo $min_alsa_version | \
90 sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\3/'`
95 #include <alsa/asoundlib.h>
97 /* ensure backward compatibility */
98 #if !defined(SND_LIB_MAJOR) && defined(SOUNDLIB_VERSION_MAJOR)
99 #define SND_LIB_MAJOR SOUNDLIB_VERSION_MAJOR
101 #if !defined(SND_LIB_MINOR) && defined(SOUNDLIB_VERSION_MINOR)
102 #define SND_LIB_MINOR SOUNDLIB_VERSION_MINOR
104 #if !defined(SND_LIB_SUBMINOR) && defined(SOUNDLIB_VERSION_SUBMINOR)
105 #define SND_LIB_SUBMINOR SOUNDLIB_VERSION_SUBMINOR
108 # if(SND_LIB_MAJOR > $alsa_min_major_version)
111 # if(SND_LIB_MAJOR < $alsa_min_major_version)
115 # if(SND_LIB_MINOR > $alsa_min_minor_version)
118 # if(SND_LIB_MINOR < $alsa_min_minor_version)
122 # if(SND_LIB_SUBMINOR < $alsa_min_micro_version)
129 [AC_MSG_RESULT(found.)],
130 [AC_MSG_RESULT(not present.)
131 ifelse([$3], , [AC_MSG_ERROR(Sufficiently new version of libasound not found.)])
137 dnl Now that we know that we have the right version, let's see if we have the library and not just the headers.
138 if test "x$enable_alsatest" = "xyes"; then
139 AC_CHECK_LIB([asound], [snd_ctl_open],,
140 [ifelse([$3], , [AC_MSG_ERROR(No linkable libasound was found.)])
145 if test "x$alsa_found" = "xyes" ; then
146 ifelse([$2], , :, [$2])
147 LIBS=`echo $LIBS | sed 's/-lasound//g'`
148 LIBS=`echo $LIBS | sed 's/ //'`
149 LIBS="-lasound $LIBS"
151 if test "x$alsa_found" = "xno" ; then
152 ifelse([$3], , :, [$3])
153 CFLAGS="$alsa_save_CFLAGS"
154 LDFLAGS="$alsa_save_LDFLAGS"
155 LIBS="$alsa_save_LIBS"
160 dnl That should be it. Now just export out symbols:
161 AC_SUBST(ALSA_CFLAGS)
166 # intlmacosx.m4 serial 3 (gettext-0.18)
167 dnl Copyright (C) 2004-2010 Free Software Foundation, Inc.
168 dnl This file is free software; the Free Software Foundation
169 dnl gives unlimited permission to copy and/or distribute it,
170 dnl with or without modifications, as long as this notice is preserved.
172 dnl This file can can be used in projects which are not available under
173 dnl the GNU General Public License or the GNU Library General Public
174 dnl License but which still want to provide support for the GNU gettext
176 dnl Please note that the actual code of the GNU gettext library is covered
177 dnl by the GNU Library General Public License, and the rest of the GNU
178 dnl gettext package package is covered by the GNU General Public License.
179 dnl They are *not* in the public domain.
181 dnl Checks for special options needed on MacOS X.
182 dnl Defines INTL_MACOSX_LIBS.
183 AC_DEFUN([gt_INTL_MACOSX],
185 dnl Check for API introduced in MacOS X 10.2.
186 AC_CACHE_CHECK([for CFPreferencesCopyAppValue],
187 [gt_cv_func_CFPreferencesCopyAppValue],
188 [gt_save_LIBS="$LIBS"
189 LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
190 AC_TRY_LINK([#include <CoreFoundation/CFPreferences.h>],
191 [CFPreferencesCopyAppValue(NULL, NULL)],
192 [gt_cv_func_CFPreferencesCopyAppValue=yes],
193 [gt_cv_func_CFPreferencesCopyAppValue=no])
194 LIBS="$gt_save_LIBS"])
195 if test $gt_cv_func_CFPreferencesCopyAppValue = yes; then
196 AC_DEFINE([HAVE_CFPREFERENCESCOPYAPPVALUE], [1],
197 [Define to 1 if you have the MacOS X function CFPreferencesCopyAppValue in the CoreFoundation framework.])
199 dnl Check for API introduced in MacOS X 10.3.
200 AC_CACHE_CHECK([for CFLocaleCopyCurrent], [gt_cv_func_CFLocaleCopyCurrent],
201 [gt_save_LIBS="$LIBS"
202 LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
203 AC_TRY_LINK([#include <CoreFoundation/CFLocale.h>], [CFLocaleCopyCurrent();],
204 [gt_cv_func_CFLocaleCopyCurrent=yes],
205 [gt_cv_func_CFLocaleCopyCurrent=no])
206 LIBS="$gt_save_LIBS"])
207 if test $gt_cv_func_CFLocaleCopyCurrent = yes; then
208 AC_DEFINE([HAVE_CFLOCALECOPYCURRENT], [1],
209 [Define to 1 if you have the MacOS X function CFLocaleCopyCurrent in the CoreFoundation framework.])
212 if test $gt_cv_func_CFPreferencesCopyAppValue = yes || test $gt_cv_func_CFLocaleCopyCurrent = yes; then
213 INTL_MACOSX_LIBS="-Wl,-framework -Wl,CoreFoundation"
215 AC_SUBST([INTL_MACOSX_LIBS])
218 # pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*-
219 # serial 1 (pkg-config-0.24)
221 # Copyright © 2004 Scott James Remnant <scott@netsplit.com>.
223 # This program is free software; you can redistribute it and/or modify
224 # it under the terms of the GNU General Public License as published by
225 # the Free Software Foundation; either version 2 of the License, or
226 # (at your option) any later version.
228 # This program is distributed in the hope that it will be useful, but
229 # WITHOUT ANY WARRANTY; without even the implied warranty of
230 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
231 # General Public License for more details.
233 # You should have received a copy of the GNU General Public License
234 # along with this program; if not, write to the Free Software
235 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
237 # As a special exception to the GNU General Public License, if you
238 # distribute this file as part of a program that contains a
239 # configuration script generated by Autoconf, you may include it under
240 # the same distribution terms that you use for the rest of that program.
242 # PKG_PROG_PKG_CONFIG([MIN-VERSION])
243 # ----------------------------------
244 AC_DEFUN([PKG_PROG_PKG_CONFIG],
245 [m4_pattern_forbid([^_?PKG_[A-Z_]+$])
246 m4_pattern_allow([^PKG_CONFIG(_PATH)?$])
247 AC_ARG_VAR([PKG_CONFIG], [path to pkg-config utility])
248 AC_ARG_VAR([PKG_CONFIG_PATH], [directories to add to pkg-config's search path])
249 AC_ARG_VAR([PKG_CONFIG_LIBDIR], [path overriding pkg-config's built-in search path])
251 if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
252 AC_PATH_TOOL([PKG_CONFIG], [pkg-config])
254 if test -n "$PKG_CONFIG"; then
255 _pkg_min_version=m4_default([$1], [0.9.0])
256 AC_MSG_CHECKING([pkg-config is at least version $_pkg_min_version])
257 if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
264 ])# PKG_PROG_PKG_CONFIG
266 # PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
268 # Check to see whether a particular set of modules exists. Similar
269 # to PKG_CHECK_MODULES(), but does not set variables or print errors.
271 # Please remember that m4 expands AC_REQUIRE([PKG_PROG_PKG_CONFIG])
272 # only at the first occurence in configure.ac, so if the first place
273 # it's called might be skipped (such as if it is within an "if", you
274 # have to call PKG_CHECK_EXISTS manually
275 # --------------------------------------------------------------
276 AC_DEFUN([PKG_CHECK_EXISTS],
277 [AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl
278 if test -n "$PKG_CONFIG" && \
279 AC_RUN_LOG([$PKG_CONFIG --exists --print-errors "$1"]); then
280 m4_default([$2], [:])
281 m4_ifvaln([$3], [else
285 # _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES])
286 # ---------------------------------------------
287 m4_define([_PKG_CONFIG],
288 [if test -n "$$1"; then
290 elif test -n "$PKG_CONFIG"; then
291 PKG_CHECK_EXISTS([$3],
292 [pkg_cv_[]$1=`$PKG_CONFIG --[]$2 "$3" 2>/dev/null`],
299 # _PKG_SHORT_ERRORS_SUPPORTED
300 # -----------------------------
301 AC_DEFUN([_PKG_SHORT_ERRORS_SUPPORTED],
302 [AC_REQUIRE([PKG_PROG_PKG_CONFIG])
303 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
304 _pkg_short_errors_supported=yes
306 _pkg_short_errors_supported=no
308 ])# _PKG_SHORT_ERRORS_SUPPORTED
311 # PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND],
312 # [ACTION-IF-NOT-FOUND])
315 # Note that if there is a possibility the first call to
316 # PKG_CHECK_MODULES might not happen, you should be sure to include an
317 # explicit call to PKG_PROG_PKG_CONFIG in your configure.ac
320 # --------------------------------------------------------------
321 AC_DEFUN([PKG_CHECK_MODULES],
322 [AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl
323 AC_ARG_VAR([$1][_CFLAGS], [C compiler flags for $1, overriding pkg-config])dnl
324 AC_ARG_VAR([$1][_LIBS], [linker flags for $1, overriding pkg-config])dnl
327 AC_MSG_CHECKING([for $1])
329 _PKG_CONFIG([$1][_CFLAGS], [cflags], [$2])
330 _PKG_CONFIG([$1][_LIBS], [libs], [$2])
332 m4_define([_PKG_TEXT], [Alternatively, you may set the environment variables $1[]_CFLAGS
333 and $1[]_LIBS to avoid the need to call pkg-config.
334 See the pkg-config man page for more details.])
336 if test $pkg_failed = yes; then
338 _PKG_SHORT_ERRORS_SUPPORTED
339 if test $_pkg_short_errors_supported = yes; then
340 $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "$2" 2>&1`
342 $1[]_PKG_ERRORS=`$PKG_CONFIG --print-errors "$2" 2>&1`
344 # Put the nasty error message in config.log where it belongs
345 echo "$$1[]_PKG_ERRORS" >&AS_MESSAGE_LOG_FD
347 m4_default([$4], [AC_MSG_ERROR(
348 [Package requirements ($2) were not met:
352 Consider adjusting the PKG_CONFIG_PATH environment variable if you
353 installed software in a non-standard prefix.
357 elif test $pkg_failed = untried; then
359 m4_default([$4], [AC_MSG_FAILURE(
360 [The pkg-config script could not be found or is too old. Make sure it
361 is in your PATH or set the PKG_CONFIG environment variable to the full
366 To get pkg-config, see <http://pkg-config.freedesktop.org/>.])
369 $1[]_CFLAGS=$pkg_cv_[]$1[]_CFLAGS
370 $1[]_LIBS=$pkg_cv_[]$1[]_LIBS
374 ])# PKG_CHECK_MODULES
376 # Copyright (C) 2002-2012 Free Software Foundation, Inc.
378 # This file is free software; the Free Software Foundation
379 # gives unlimited permission to copy and/or distribute it,
380 # with or without modifications, as long as this notice is preserved.
384 # AM_AUTOMAKE_VERSION(VERSION)
385 # ----------------------------
386 # Automake X.Y traces this macro to ensure aclocal.m4 has been
387 # generated from the m4 files accompanying Automake X.Y.
388 # (This private macro should not be called outside this file.)
389 AC_DEFUN([AM_AUTOMAKE_VERSION],
390 [am__api_version='1.12'
391 dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to
392 dnl require some minimum version. Point them to the right macro.
393 m4_if([$1], [1.12.2], [],
394 [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl
397 # _AM_AUTOCONF_VERSION(VERSION)
398 # -----------------------------
399 # aclocal traces this macro to find the Autoconf version.
400 # This is a private macro too. Using m4_define simplifies
401 # the logic in aclocal, which can simply ignore this definition.
402 m4_define([_AM_AUTOCONF_VERSION], [])
404 # AM_SET_CURRENT_AUTOMAKE_VERSION
405 # -------------------------------
406 # Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced.
407 # This function is AC_REQUIREd by AM_INIT_AUTOMAKE.
408 AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
409 [AM_AUTOMAKE_VERSION([1.12.2])dnl
410 m4_ifndef([AC_AUTOCONF_VERSION],
411 [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
412 _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))])
414 # AM_AUX_DIR_EXPAND -*- Autoconf -*-
416 # Copyright (C) 2001-2012 Free Software Foundation, Inc.
418 # This file is free software; the Free Software Foundation
419 # gives unlimited permission to copy and/or distribute it,
420 # with or without modifications, as long as this notice is preserved.
424 # For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets
425 # $ac_aux_dir to '$srcdir/foo'. In other projects, it is set to
426 # '$srcdir', '$srcdir/..', or '$srcdir/../..'.
428 # Of course, Automake must honor this variable whenever it calls a
429 # tool from the auxiliary directory. The problem is that $srcdir (and
430 # therefore $ac_aux_dir as well) can be either absolute or relative,
431 # depending on how configure is run. This is pretty annoying, since
432 # it makes $ac_aux_dir quite unusable in subdirectories: in the top
433 # source directory, any form will work fine, but in subdirectories a
434 # relative path needs to be adjusted first.
436 # $ac_aux_dir/missing
437 # fails when called from a subdirectory if $ac_aux_dir is relative
438 # $top_srcdir/$ac_aux_dir/missing
439 # fails if $ac_aux_dir is absolute,
440 # fails when called from a subdirectory in a VPATH build with
441 # a relative $ac_aux_dir
443 # The reason of the latter failure is that $top_srcdir and $ac_aux_dir
444 # are both prefixed by $srcdir. In an in-source build this is usually
445 # harmless because $srcdir is '.', but things will broke when you
446 # start a VPATH build or use an absolute $srcdir.
448 # So we could use something similar to $top_srcdir/$ac_aux_dir/missing,
449 # iff we strip the leading $srcdir from $ac_aux_dir. That would be:
450 # am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"`
451 # and then we would define $MISSING as
452 # MISSING="\${SHELL} $am_aux_dir/missing"
453 # This will work as long as MISSING is not called from configure, because
454 # unfortunately $(top_srcdir) has no meaning in configure.
455 # However there are other variables, like CC, which are often used in
456 # configure, and could therefore not use this "fixed" $ac_aux_dir.
458 # Another solution, used here, is to always expand $ac_aux_dir to an
459 # absolute PATH. The drawback is that using absolute paths prevent a
460 # configured tree to be moved without reconfiguration.
462 AC_DEFUN([AM_AUX_DIR_EXPAND],
463 [dnl Rely on autoconf to set up CDPATH properly.
465 # expand $ac_aux_dir to an absolute path
466 am_aux_dir=`cd $ac_aux_dir && pwd`
469 # AM_CONDITIONAL -*- Autoconf -*-
471 # Copyright (C) 1997-2012 Free Software Foundation, Inc.
473 # This file is free software; the Free Software Foundation
474 # gives unlimited permission to copy and/or distribute it,
475 # with or without modifications, as long as this notice is preserved.
479 # AM_CONDITIONAL(NAME, SHELL-CONDITION)
480 # -------------------------------------
481 # Define a conditional.
482 AC_DEFUN([AM_CONDITIONAL],
483 [AC_PREREQ([2.52])dnl
484 m4_if([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])],
485 [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl
486 AC_SUBST([$1_TRUE])dnl
487 AC_SUBST([$1_FALSE])dnl
488 _AM_SUBST_NOTMAKE([$1_TRUE])dnl
489 _AM_SUBST_NOTMAKE([$1_FALSE])dnl
490 m4_define([_AM_COND_VALUE_$1], [$2])dnl
498 AC_CONFIG_COMMANDS_PRE(
499 [if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then
500 AC_MSG_ERROR([[conditional "$1" was never defined.
501 Usually this means the macro was only invoked conditionally.]])
504 # Copyright (C) 1999-2012 Free Software Foundation, Inc.
506 # This file is free software; the Free Software Foundation
507 # gives unlimited permission to copy and/or distribute it,
508 # with or without modifications, as long as this notice is preserved.
512 # There are a few dirty hacks below to avoid letting 'AC_PROG_CC' be
513 # written in clear, in which case automake, when reading aclocal.m4,
514 # will think it sees a *use*, and therefore will trigger all it's
515 # C support machinery. Also note that it means that autoscan, seeing
516 # CC etc. in the Makefile, will ask for an AC_PROG_CC use...
519 # _AM_DEPENDENCIES(NAME)
520 # ----------------------
521 # See how the compiler implements dependency checking.
522 # NAME is "CC", "CXX", "OBJC", "OBJCXX", "UPC", or "GJC".
523 # We try a few techniques and use that to set a single cache variable.
525 # We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was
526 # modified to invoke _AM_DEPENDENCIES(CC); we would have a circular
527 # dependency, and given that the user is not expected to run this macro,
528 # just rely on AC_PROG_CC.
529 AC_DEFUN([_AM_DEPENDENCIES],
530 [AC_REQUIRE([AM_SET_DEPDIR])dnl
531 AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl
532 AC_REQUIRE([AM_MAKE_INCLUDE])dnl
533 AC_REQUIRE([AM_DEP_TRACK])dnl
535 m4_if([$1], [CC], [depcc="$CC" am_compiler_list=],
536 [$1], [CXX], [depcc="$CXX" am_compiler_list=],
537 [$1], [OBJC], [depcc="$OBJC" am_compiler_list='gcc3 gcc'],
538 [$1], [OBJCXX], [depcc="$OBJCXX" am_compiler_list='gcc3 gcc'],
539 [$1], [UPC], [depcc="$UPC" am_compiler_list=],
540 [$1], [GCJ], [depcc="$GCJ" am_compiler_list='gcc3 gcc'],
541 [depcc="$$1" am_compiler_list=])
543 AC_CACHE_CHECK([dependency style of $depcc],
544 [am_cv_$1_dependencies_compiler_type],
545 [if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
546 # We make a subdir and do the tests there. Otherwise we can end up
547 # making bogus files that we don't know about and never remove. For
548 # instance it was reported that on HP-UX the gcc test will end up
549 # making a dummy file named 'D' -- because '-MD' means "put the output
553 # Copy depcomp to subdir because otherwise we won't find it if we're
554 # using a relative directory.
555 cp "$am_depcomp" conftest.dir
557 # We will build objects and dependencies in a subdirectory because
558 # it helps to detect inapplicable dependency modes. For instance
559 # both Tru64's cc and ICC support -MD to output dependencies as a
560 # side effect of compilation, but ICC will put the dependencies in
561 # the current directory while Tru64 will put them in the object
565 am_cv_$1_dependencies_compiler_type=none
566 if test "$am_compiler_list" = ""; then
567 am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp`
571 [case " $depcc " in #(
572 *\ -arch\ *\ -arch\ *) am__universal=true ;;
575 [case " $depcc " in #(
576 *\ -arch\ *\ -arch\ *) am__universal=true ;;
579 for depmode in $am_compiler_list; do
580 # Setup a source with many dependencies, because some compilers
581 # like to wrap large dependency lists on column 80 (with \), and
582 # we should not choose a depcomp mode which is confused by this.
584 # We need to recreate these files for each test, as the compiler may
585 # overwrite some of them when testing with obscure command lines.
586 # This happens at least with the AIX C compiler.
588 for i in 1 2 3 4 5 6; do
589 echo '#include "conftst'$i'.h"' >> sub/conftest.c
590 # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
591 # Solaris 10 /bin/sh.
592 echo '/* dummy */' > sub/conftst$i.h
594 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
596 # We check with '-c' and '-o' for the sake of the "dashmstdout"
597 # mode. It turns out that the SunPro C++ compiler does not properly
598 # handle '-M -o', and we need to detect this. Also, some Intel
599 # versions had trouble with output in subdirs.
600 am__obj=sub/conftest.${OBJEXT-o}
601 am__minus_obj="-o $am__obj"
604 # This depmode causes a compiler race in universal mode.
605 test "$am__universal" = false || continue
608 # After this tag, mechanisms are not by side-effect, so they'll
609 # only be used when explicitly requested.
610 if test "x$enable_dependency_tracking" = xyes; then
616 msvc7 | msvc7msys | msvisualcpp | msvcmsys)
617 # This compiler won't grok '-c -o', but also, the minuso test has
618 # not run yet. These depmodes are late enough in the game, and
619 # so weak that their functioning should not be impacted.
620 am__obj=conftest.${OBJEXT-o}
625 if depmode=$depmode \
626 source=sub/conftest.c object=$am__obj \
627 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
628 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
629 >/dev/null 2>conftest.err &&
630 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
631 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
632 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
633 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
634 # icc doesn't choke on unknown options, it will just issue warnings
635 # or remarks (even with -Werror). So we grep stderr for any message
636 # that says an option was ignored or not supported.
637 # When given -MP, icc 7.0 and 7.1 complain thusly:
638 # icc: Command line warning: ignoring option '-M'; no argument required
639 # The diagnosis changed in icc 8.0:
640 # icc: Command line remark: option '-MP' not supported
641 if (grep 'ignoring option' conftest.err ||
642 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
643 am_cv_$1_dependencies_compiler_type=$depmode
652 am_cv_$1_dependencies_compiler_type=none
655 AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type])
656 AM_CONDITIONAL([am__fastdep$1], [
657 test "x$enable_dependency_tracking" != xno \
658 && test "$am_cv_$1_dependencies_compiler_type" = gcc3])
664 # Choose a directory name for dependency files.
665 # This macro is AC_REQUIREd in _AM_DEPENDENCIES.
666 AC_DEFUN([AM_SET_DEPDIR],
667 [AC_REQUIRE([AM_SET_LEADING_DOT])dnl
668 AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl
674 AC_DEFUN([AM_DEP_TRACK],
675 [AC_ARG_ENABLE([dependency-tracking], [dnl
677 [--enable-dependency-tracking],
678 [do not reject slow dependency extractors])
680 [--disable-dependency-tracking],
681 [speeds up one-time build])])
682 if test "x$enable_dependency_tracking" != xno; then
683 am_depcomp="$ac_aux_dir/depcomp"
687 AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno])
688 AC_SUBST([AMDEPBACKSLASH])dnl
689 _AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl
690 AC_SUBST([am__nodep])dnl
691 _AM_SUBST_NOTMAKE([am__nodep])dnl
694 # Generate code to set up dependency tracking. -*- Autoconf -*-
696 # Copyright (C) 1999-2012 Free Software Foundation, Inc.
698 # This file is free software; the Free Software Foundation
699 # gives unlimited permission to copy and/or distribute it,
700 # with or without modifications, as long as this notice is preserved.
704 # _AM_OUTPUT_DEPENDENCY_COMMANDS
705 # ------------------------------
706 AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
708 # Autoconf 2.62 quotes --file arguments for eval, but not when files
709 # are listed without --file. Let's play safe and only enable the eval
710 # if we detect the quoting.
711 case $CONFIG_FILES in
712 *\'*) eval set x "$CONFIG_FILES" ;;
713 *) set x $CONFIG_FILES ;;
718 # Strip MF so we end up with the name of the file.
719 mf=`echo "$mf" | sed -e 's/:.*$//'`
720 # Check whether this is an Automake generated Makefile or not.
721 # We used to match only the files named 'Makefile.in', but
722 # some people rename them; so instead we look at the file content.
723 # Grep'ing the first line is not enough: some people post-process
724 # each Makefile.in and add a new line on top of each file to say so.
725 # Grep'ing the whole file is not good either: AIX grep has a line
726 # limit of 2048, but all sed's we know have understand at least 4000.
727 if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
728 dirpart=`AS_DIRNAME("$mf")`
732 # Extract the definition of DEPDIR, am__include, and am__quote
733 # from the Makefile without running 'make'.
734 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
735 test -z "$DEPDIR" && continue
736 am__include=`sed -n 's/^am__include = //p' < "$mf"`
737 test -z "am__include" && continue
738 am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
739 # Find all dependency output files, they are included files with
740 # $(DEPDIR) in their names. We invoke sed twice because it is the
741 # simplest approach to changing $(DEPDIR) to its actual value in the
743 for file in `sed -n "
744 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
745 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do
746 # Make sure the directory exists.
747 test -f "$dirpart/$file" && continue
748 fdir=`AS_DIRNAME(["$file"])`
749 AS_MKDIR_P([$dirpart/$fdir])
750 # echo "creating $dirpart/$file"
751 echo '# dummy' > "$dirpart/$file"
755 ])# _AM_OUTPUT_DEPENDENCY_COMMANDS
758 # AM_OUTPUT_DEPENDENCY_COMMANDS
759 # -----------------------------
760 # This macro should only be invoked once -- use via AC_REQUIRE.
762 # This code is only required when automatic dependency tracking
763 # is enabled. FIXME. This creates each '.P' file that we will
764 # need in order to bootstrap the dependency handling code.
765 AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
766 [AC_CONFIG_COMMANDS([depfiles],
767 [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS],
768 [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"])
771 # Do all the work for Automake. -*- Autoconf -*-
773 # Copyright (C) 1996-2012 Free Software Foundation, Inc.
775 # This file is free software; the Free Software Foundation
776 # gives unlimited permission to copy and/or distribute it,
777 # with or without modifications, as long as this notice is preserved.
781 # This macro actually does too much. Some checks are only needed if
782 # your package does certain things. But this isn't really a big deal.
784 # AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE])
785 # AM_INIT_AUTOMAKE([OPTIONS])
786 # -----------------------------------------------
787 # The call with PACKAGE and VERSION arguments is the old style
788 # call (pre autoconf-2.50), which is being phased out. PACKAGE
789 # and VERSION should now be passed to AC_INIT and removed from
790 # the call to AM_INIT_AUTOMAKE.
791 # We support both call styles for the transition. After
792 # the next Automake release, Autoconf can make the AC_INIT
793 # arguments mandatory, and then we can depend on a new Autoconf
794 # release and drop the old call support.
795 AC_DEFUN([AM_INIT_AUTOMAKE],
796 [AC_PREREQ([2.62])dnl
797 dnl Autoconf wants to disallow AM_ names. We explicitly allow
798 dnl the ones we care about.
799 m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
800 AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl
801 AC_REQUIRE([AC_PROG_INSTALL])dnl
802 if test "`cd $srcdir && pwd`" != "`pwd`"; then
803 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
804 # is not polluted with repeated "-I."
805 AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl
806 # test to see if srcdir already configured
807 if test -f $srcdir/config.status; then
808 AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
812 # test whether we have cygpath
813 if test -z "$CYGPATH_W"; then
814 if (cygpath --version) >/dev/null 2>/dev/null; then
815 CYGPATH_W='cygpath -w'
820 AC_SUBST([CYGPATH_W])
822 # Define the identity of the package.
823 dnl Distinguish between old-style and new-style calls.
825 [AC_DIAGNOSE([obsolete],
826 [$0: two- and three-arguments forms are deprecated. For more info, see:
827 http://www.gnu.org/software/automake/manual/automake.html#Modernize-AM_INIT_AUTOMAKE-invocation])
828 m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl
829 AC_SUBST([PACKAGE], [$1])dnl
830 AC_SUBST([VERSION], [$2])],
831 [_AM_SET_OPTIONS([$1])dnl
832 dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT.
834 m4_ifdef([AC_PACKAGE_NAME], [ok]):m4_ifdef([AC_PACKAGE_VERSION], [ok]),
836 [m4_fatal([AC_INIT should be called with package and version arguments])])dnl
837 AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl
838 AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl
840 _AM_IF_OPTION([no-define],,
841 [AC_DEFINE_UNQUOTED([PACKAGE], ["$PACKAGE"], [Name of package])
842 AC_DEFINE_UNQUOTED([VERSION], ["$VERSION"], [Version number of package])])dnl
844 # Some tools Automake needs.
845 AC_REQUIRE([AM_SANITY_CHECK])dnl
846 AC_REQUIRE([AC_ARG_PROGRAM])dnl
847 AM_MISSING_PROG([ACLOCAL], [aclocal-${am__api_version}])
848 AM_MISSING_PROG([AUTOCONF], [autoconf])
849 AM_MISSING_PROG([AUTOMAKE], [automake-${am__api_version}])
850 AM_MISSING_PROG([AUTOHEADER], [autoheader])
851 AM_MISSING_PROG([MAKEINFO], [makeinfo])
852 AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
853 AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl
854 AC_REQUIRE([AC_PROG_MKDIR_P])dnl
855 # For better backward compatibility. To be removed once Automake 1.9.x
856 # dies out for good. For more background, see:
857 # <http://lists.gnu.org/archive/html/automake/2012-07/msg00001.html>
858 # <http://lists.gnu.org/archive/html/automake/2012-07/msg00014.html>
859 AC_SUBST([mkdir_p], ['$(MKDIR_P)'])
860 # We need awk for the "check" target. The system "awk" is bad on
862 AC_REQUIRE([AC_PROG_AWK])dnl
863 AC_REQUIRE([AC_PROG_MAKE_SET])dnl
864 AC_REQUIRE([AM_SET_LEADING_DOT])dnl
865 _AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])],
866 [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])],
867 [_AM_PROG_TAR([v7])])])
868 _AM_IF_OPTION([no-dependencies],,
869 [AC_PROVIDE_IFELSE([AC_PROG_CC],
870 [_AM_DEPENDENCIES([CC])],
871 [m4_define([AC_PROG_CC],
872 m4_defn([AC_PROG_CC])[_AM_DEPENDENCIES([CC])])])dnl
873 AC_PROVIDE_IFELSE([AC_PROG_CXX],
874 [_AM_DEPENDENCIES([CXX])],
875 [m4_define([AC_PROG_CXX],
876 m4_defn([AC_PROG_CXX])[_AM_DEPENDENCIES([CXX])])])dnl
877 AC_PROVIDE_IFELSE([AC_PROG_OBJC],
878 [_AM_DEPENDENCIES([OBJC])],
879 [m4_define([AC_PROG_OBJC],
880 m4_defn([AC_PROG_OBJC])[_AM_DEPENDENCIES([OBJC])])])dnl
881 dnl Support for Objective C++ was only introduced in Autoconf 2.65,
882 dnl but we still cater to Autoconf 2.62.
883 m4_ifdef([AC_PROG_OBJCXX],
884 [AC_PROVIDE_IFELSE([AC_PROG_OBJCXX],
885 [_AM_DEPENDENCIES([OBJCXX])],
886 [m4_define([AC_PROG_OBJCXX],
887 m4_defn([AC_PROG_OBJCXX])[_AM_DEPENDENCIES([OBJCXX])])])])dnl
889 _AM_IF_OPTION([silent-rules], [AC_REQUIRE([AM_SILENT_RULES])])dnl
890 dnl The 'parallel-tests' driver may need to know about EXEEXT, so add the
891 dnl 'am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This macro
892 dnl is hooked onto _AC_COMPILER_EXEEXT early, see below.
893 AC_CONFIG_COMMANDS_PRE(dnl
894 [m4_provide_if([_AM_COMPILER_EXEEXT],
895 [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl
898 dnl Hook into '_AC_COMPILER_EXEEXT' early to learn its expansion. Do not
899 dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further
900 dnl mangled by Autoconf and run in a shell conditional statement.
901 m4_define([_AC_COMPILER_EXEEXT],
902 m4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])])
905 # When config.status generates a header, we must update the stamp-h file.
906 # This file resides in the same directory as the config header
907 # that is generated. The stamp files are numbered to have different names.
909 # Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the
910 # loop where config.status creates the headers, so we can generate
911 # our stamp files there.
912 AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK],
913 [# Compute $1's index in $config_headers.
916 for _am_header in $config_headers :; do
918 $_am_arg | $_am_arg:* )
921 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
924 echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count])
926 # Copyright (C) 2001-2012 Free Software Foundation, Inc.
928 # This file is free software; the Free Software Foundation
929 # gives unlimited permission to copy and/or distribute it,
930 # with or without modifications, as long as this notice is preserved.
936 # Define $install_sh.
937 AC_DEFUN([AM_PROG_INSTALL_SH],
938 [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
939 if test x"${install_sh}" != xset; then
942 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
944 install_sh="\${SHELL} $am_aux_dir/install-sh"
947 AC_SUBST([install_sh])])
949 # Copyright (C) 2003-2012 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.
957 # Check whether the underlying file-system supports filenames
958 # with a leading dot. For instance MS-DOS doesn't.
959 AC_DEFUN([AM_SET_LEADING_DOT],
960 [rm -rf .tst 2>/dev/null
961 mkdir .tst 2>/dev/null
962 if test -d .tst; then
967 rmdir .tst 2>/dev/null
968 AC_SUBST([am__leading_dot])])
970 # Add --enable-maintainer-mode option to configure. -*- Autoconf -*-
973 # Copyright (C) 1996-2012 Free Software Foundation, Inc.
975 # This file is free software; the Free Software Foundation
976 # gives unlimited permission to copy and/or distribute it,
977 # with or without modifications, as long as this notice is preserved.
981 # AM_MAINTAINER_MODE([DEFAULT-MODE])
982 # ----------------------------------
983 # Control maintainer-specific portions of Makefiles.
984 # Default is to disable them, unless 'enable' is passed literally.
985 # For symmetry, 'disable' may be passed as well. Anyway, the user
986 # can override the default with the --enable/--disable switch.
987 AC_DEFUN([AM_MAINTAINER_MODE],
988 [m4_case(m4_default([$1], [disable]),
989 [enable], [m4_define([am_maintainer_other], [disable])],
990 [disable], [m4_define([am_maintainer_other], [enable])],
991 [m4_define([am_maintainer_other], [enable])
992 m4_warn([syntax], [unexpected argument to AM@&t@_MAINTAINER_MODE: $1])])
993 AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles])
994 dnl maintainer-mode's default is 'disable' unless 'enable' is passed
995 AC_ARG_ENABLE([maintainer-mode],
996 [AS_HELP_STRING([--]am_maintainer_other[-maintainer-mode],
997 am_maintainer_other[ make rules and dependencies not useful
998 (and sometimes confusing) to the casual installer])],
999 [USE_MAINTAINER_MODE=$enableval],
1000 [USE_MAINTAINER_MODE=]m4_if(am_maintainer_other, [enable], [no], [yes]))
1001 AC_MSG_RESULT([$USE_MAINTAINER_MODE])
1002 AM_CONDITIONAL([MAINTAINER_MODE], [test $USE_MAINTAINER_MODE = yes])
1003 MAINT=$MAINTAINER_MODE_TRUE
1004 AC_SUBST([MAINT])dnl
1008 AU_DEFUN([jm_MAINTAINER_MODE], [AM_MAINTAINER_MODE])
1010 # Check to see how 'make' treats includes. -*- Autoconf -*-
1012 # Copyright (C) 2001-2012 Free Software Foundation, Inc.
1014 # This file is free software; the Free Software Foundation
1015 # gives unlimited permission to copy and/or distribute it,
1016 # with or without modifications, as long as this notice is preserved.
1022 # Check to see how make treats includes.
1023 AC_DEFUN([AM_MAKE_INCLUDE],
1024 [am_make=${MAKE-make}
1025 cat > confinc << 'END'
1027 @echo this is the am__doit target
1030 # If we don't find an include directive, just comment out the code.
1031 AC_MSG_CHECKING([for style of include used by $am_make])
1035 # First try GNU make style include.
1036 echo "include confinc" > confmf
1037 # Ignore all kinds of additional output from 'make'.
1038 case `$am_make -s -f confmf 2> /dev/null` in #(
1039 *the\ am__doit\ target*)
1045 # Now try BSD make style include.
1046 if test "$am__include" = "#"; then
1047 echo '.include "confinc"' > confmf
1048 case `$am_make -s -f confmf 2> /dev/null` in #(
1049 *the\ am__doit\ target*)
1050 am__include=.include
1056 AC_SUBST([am__include])
1057 AC_SUBST([am__quote])
1058 AC_MSG_RESULT([$_am_result])
1059 rm -f confinc confmf
1062 # Fake the existence of programs that GNU maintainers use. -*- Autoconf -*-
1064 # Copyright (C) 1997-2012 Free Software Foundation, Inc.
1066 # This file is free software; the Free Software Foundation
1067 # gives unlimited permission to copy and/or distribute it,
1068 # with or without modifications, as long as this notice is preserved.
1072 # AM_MISSING_PROG(NAME, PROGRAM)
1073 # ------------------------------
1074 AC_DEFUN([AM_MISSING_PROG],
1075 [AC_REQUIRE([AM_MISSING_HAS_RUN])
1076 $1=${$1-"${am_missing_run}$2"}
1080 # AM_MISSING_HAS_RUN
1081 # ------------------
1082 # Define MISSING if not defined so far and test if it supports --run.
1083 # If it does, set am_missing_run to use it, otherwise, to nothing.
1084 AC_DEFUN([AM_MISSING_HAS_RUN],
1085 [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
1086 AC_REQUIRE_AUX_FILE([missing])dnl
1087 if test x"${MISSING+set}" != xset; then
1090 MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
1092 MISSING="\${SHELL} $am_aux_dir/missing" ;;
1095 # Use eval to expand $SHELL
1096 if eval "$MISSING --run true"; then
1097 am_missing_run="$MISSING --run "
1100 AC_MSG_WARN(['missing' script is too old or missing])
1104 # Copyright (C) 2003-2012 Free Software Foundation, Inc.
1106 # This file is free software; the Free Software Foundation
1107 # gives unlimited permission to copy and/or distribute it,
1108 # with or without modifications, as long as this notice is preserved.
1114 # Check for 'mkdir -p'.
1115 AC_DEFUN([AM_PROG_MKDIR_P],
1116 [AC_PREREQ([2.60])dnl
1117 AC_REQUIRE([AC_PROG_MKDIR_P])dnl
1118 dnl FIXME to be removed in Automake 1.13.
1119 AC_DIAGNOSE([obsolete],
1120 [$0: this macro is deprecated, and will soon be removed.
1121 You should use the Autoconf-provided 'AC][_PROG_MKDIR_P' macro instead,
1122 and use '$(MKDIR_P)' instead of '$(mkdir_p)'in your Makefile.am files.])
1123 dnl Automake 1.8 to 1.9.6 used to define mkdir_p. We now use MKDIR_P,
1124 dnl while keeping a definition of mkdir_p for backward compatibility.
1125 dnl @MKDIR_P@ is magic: AC_OUTPUT adjusts its value for each Makefile.
1126 dnl However we cannot define mkdir_p as $(MKDIR_P) for the sake of
1127 dnl Makefile.ins that do not define MKDIR_P, so we do our own
1128 dnl adjustment using top_builddir (which is defined more often than
1130 AC_SUBST([mkdir_p], ["$MKDIR_P"])dnl
1132 [[\\/$]]* | ?:[[\\/]]*) ;;
1133 */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
1137 # Helper functions for option handling. -*- Autoconf -*-
1139 # Copyright (C) 2001-2012 Free Software Foundation, Inc.
1141 # This file is free software; the Free Software Foundation
1142 # gives unlimited permission to copy and/or distribute it,
1143 # with or without modifications, as long as this notice is preserved.
1147 # _AM_MANGLE_OPTION(NAME)
1148 # -----------------------
1149 AC_DEFUN([_AM_MANGLE_OPTION],
1150 [[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])])
1152 # _AM_SET_OPTION(NAME)
1153 # --------------------
1154 # Set option NAME. Presently that only means defining a flag for this option.
1155 AC_DEFUN([_AM_SET_OPTION],
1156 [m4_define(_AM_MANGLE_OPTION([$1]), [1])])
1158 # _AM_SET_OPTIONS(OPTIONS)
1159 # ------------------------
1160 # OPTIONS is a space-separated list of Automake options.
1161 AC_DEFUN([_AM_SET_OPTIONS],
1162 [m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])])
1164 # _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET])
1165 # -------------------------------------------
1166 # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
1167 AC_DEFUN([_AM_IF_OPTION],
1168 [m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
1170 # Check to make sure that the build environment is sane. -*- Autoconf -*-
1172 # Copyright (C) 1996-2012 Free Software Foundation, Inc.
1174 # This file is free software; the Free Software Foundation
1175 # gives unlimited permission to copy and/or distribute it,
1176 # with or without modifications, as long as this notice is preserved.
1182 AC_DEFUN([AM_SANITY_CHECK],
1183 [AC_MSG_CHECKING([whether build environment is sane])
1184 # Reject unsafe characters in $srcdir or the absolute working directory
1185 # name. Accept space and tab only in the latter.
1189 *[[\\\"\#\$\&\'\`$am_lf]]*)
1190 AC_MSG_ERROR([unsafe absolute working directory name]);;
1193 *[[\\\"\#\$\&\'\`$am_lf\ \ ]]*)
1194 AC_MSG_ERROR([unsafe srcdir value: '$srcdir']);;
1197 # Do 'set' in a subshell so we don't clobber the current shell's
1198 # arguments. Must try -L first in case configure is actually a
1199 # symlink; some systems play weird games with the mod time of symlinks
1200 # (eg FreeBSD returns the mod time of the symlink's containing
1204 for am_try in 1 2; do
1205 echo "timestamp, slept: $am_has_slept" > conftest.file
1206 set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
1207 if test "$[*]" = "X"; then
1209 set X `ls -t "$srcdir/configure" conftest.file`
1211 if test "$[*]" != "X $srcdir/configure conftest.file" \
1212 && test "$[*]" != "X conftest.file $srcdir/configure"; then
1214 # If neither matched, then we have a broken ls. This can happen
1215 # if, for instance, CONFIG_SHELL is bash and it inherits a
1216 # broken ls alias from the environment. This has actually
1217 # happened. Such a system could not be considered "sane".
1218 AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken
1219 alias in your environment])
1221 if test "$[2]" = conftest.file || test $am_try -eq 2; then
1228 test "$[2]" = conftest.file
1234 AC_MSG_ERROR([newly created file is older than distributed files!
1235 Check your system clock])
1237 AC_MSG_RESULT([yes])
1238 # If we didn't sleep, we still need to ensure time stamps of config.status and
1239 # generated files are strictly newer.
1241 if grep 'slept: no' conftest.file >/dev/null 2>&1; then
1245 AC_CONFIG_COMMANDS_PRE(
1246 [AC_MSG_CHECKING([that generated files are newer than configure])
1247 if test -n "$am_sleep_pid"; then
1248 # Hide warnings about reused PIDs.
1249 wait $am_sleep_pid 2>/dev/null
1251 AC_MSG_RESULT([done])])
1255 # Copyright (C) 2001-2012 Free Software Foundation, Inc.
1257 # This file is free software; the Free Software Foundation
1258 # gives unlimited permission to copy and/or distribute it,
1259 # with or without modifications, as long as this notice is preserved.
1263 # AM_PROG_INSTALL_STRIP
1264 # ---------------------
1265 # One issue with vendor 'install' (even GNU) is that you can't
1266 # specify the program used to strip binaries. This is especially
1267 # annoying in cross-compiling environments, where the build's strip
1268 # is unlikely to handle the host's binaries.
1269 # Fortunately install-sh will honor a STRIPPROG variable, so we
1270 # always use install-sh in "make install-strip", and initialize
1271 # STRIPPROG with the value of the STRIP variable (set by the user).
1272 AC_DEFUN([AM_PROG_INSTALL_STRIP],
1273 [AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
1274 # Installed binaries are usually stripped using 'strip' when the user
1275 # run "make install-strip". However 'strip' might not be the right
1276 # tool to use in cross-compilation environments, therefore Automake
1277 # will honor the 'STRIP' environment variable to overrule this program.
1278 dnl Don't test for $cross_compiling = yes, because it might be 'maybe'.
1279 if test "$cross_compiling" != no; then
1280 AC_CHECK_TOOL([STRIP], [strip], :)
1282 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
1283 AC_SUBST([INSTALL_STRIP_PROGRAM])])
1285 # Copyright (C) 2006-2012 Free Software Foundation, Inc.
1287 # This file is free software; the Free Software Foundation
1288 # gives unlimited permission to copy and/or distribute it,
1289 # with or without modifications, as long as this notice is preserved.
1293 # _AM_SUBST_NOTMAKE(VARIABLE)
1294 # ---------------------------
1295 # Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in.
1296 # This macro is traced by Automake.
1297 AC_DEFUN([_AM_SUBST_NOTMAKE])
1299 # AM_SUBST_NOTMAKE(VARIABLE)
1300 # --------------------------
1301 # Public sister of _AM_SUBST_NOTMAKE.
1302 AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)])
1304 # Check how to create a tarball. -*- Autoconf -*-
1306 # Copyright (C) 2004-2012 Free Software Foundation, Inc.
1308 # This file is free software; the Free Software Foundation
1309 # gives unlimited permission to copy and/or distribute it,
1310 # with or without modifications, as long as this notice is preserved.
1314 # _AM_PROG_TAR(FORMAT)
1315 # --------------------
1316 # Check how to create a tarball in format FORMAT.
1317 # FORMAT should be one of 'v7', 'ustar', or 'pax'.
1319 # Substitute a variable $(am__tar) that is a command
1320 # writing to stdout a FORMAT-tarball containing the directory
1322 # tardir=directory && $(am__tar) > result.tar
1324 # Substitute a variable $(am__untar) that extract such
1325 # a tarball read from stdin.
1326 # $(am__untar) < result.tar
1327 AC_DEFUN([_AM_PROG_TAR],
1328 [# Always define AMTAR for backward compatibility. Yes, it's still used
1329 # in the wild :-( We should find a proper way to deprecate it ...
1330 AC_SUBST([AMTAR], ['$${TAR-tar}'])
1332 [am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'],
1333 [m4_case([$1], [ustar],, [pax],,
1334 [m4_fatal([Unknown tar format])])
1335 AC_MSG_CHECKING([how to create a $1 tar archive])
1336 # Loop over all known methods to create a tar archive until one works.
1337 _am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none'
1338 _am_tools=${am_cv_prog_tar_$1-$_am_tools}
1339 # Do not fold the above two line into one, because Tru64 sh and
1340 # Solaris sh will not grok spaces in the rhs of '-'.
1341 for _am_tool in $_am_tools
1345 for _am_tar in tar gnutar gtar;
1347 AM_RUN_LOG([$_am_tar --version]) && break
1349 am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"'
1350 am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"'
1351 am__untar="$_am_tar -xf -"
1354 # Must skip GNU tar: if it does not support --format= it doesn't create
1355 # ustar tarball either.
1356 (tar --version) >/dev/null 2>&1 && continue
1357 am__tar='tar chf - "$$tardir"'
1358 am__tar_='tar chf - "$tardir"'
1359 am__untar='tar xf -'
1362 am__tar='pax -L -x $1 -w "$$tardir"'
1363 am__tar_='pax -L -x $1 -w "$tardir"'
1367 am__tar='find "$$tardir" -print | cpio -o -H $1 -L'
1368 am__tar_='find "$tardir" -print | cpio -o -H $1 -L'
1369 am__untar='cpio -i -H $1 -d'
1378 # If the value was cached, stop now. We just wanted to have am__tar
1379 # and am__untar set.
1380 test -n "${am_cv_prog_tar_$1}" && break
1382 # tar/untar a dummy directory, and stop if the command works
1385 echo GrepMe > conftest.dir/file
1386 AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar])
1388 if test -s conftest.tar; then
1389 AM_RUN_LOG([$am__untar <conftest.tar])
1390 grep GrepMe conftest.dir/file >/dev/null 2>&1 && break
1395 AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool])
1396 AC_MSG_RESULT([$am_cv_prog_tar_$1])])
1398 AC_SUBST([am__untar])
1401 m4_include([m4/gettext.m4])
1402 m4_include([m4/iconv.m4])
1403 m4_include([m4/lib-ld.m4])
1404 m4_include([m4/lib-link.m4])
1405 m4_include([m4/lib-prefix.m4])
1406 m4_include([m4/nls.m4])
1407 m4_include([m4/po.m4])
1408 m4_include([m4/progtest.m4])
1409 m4_include([acinclude.m4])