1# generated automatically by aclocal 1.10.1 -*- Autoconf -*- 2 3# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 4# 2005, 2006, 2007, 2008 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. 8 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 12# PARTICULAR PURPOSE. 13 14m4_ifndef([AC_AUTOCONF_VERSION], 15 [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl 16m4_if(AC_AUTOCONF_VERSION, [2.63],, 17[m4_warning([this file was generated for autoconf 2.63. 18You have another version of autoconf. It may work, but is not guaranteed to. 19If you have problems, you may need to regenerate the build system entirely. 20To do so, use the procedure documented by the package, typically `autoreconf'.])]) 21 22# pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*- 23# 24# Copyright © 2004 Scott James Remnant <scott@netsplit.com>. 25# 26# This program is free software; you can redistribute it and/or modify 27# it under the terms of the GNU General Public License as published by 28# the Free Software Foundation; either version 2 of the License, or 29# (at your option) any later version. 30# 31# This program is distributed in the hope that it will be useful, but 32# WITHOUT ANY WARRANTY; without even the implied warranty of 33# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 34# General Public License for more details. 35# 36# You should have received a copy of the GNU General Public License 37# along with this program; if not, write to the Free Software 38# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 39# 40# As a special exception to the GNU General Public License, if you 41# distribute this file as part of a program that contains a 42# configuration script generated by Autoconf, you may include it under 43# the same distribution terms that you use for the rest of that program. 44 45# PKG_PROG_PKG_CONFIG([MIN-VERSION]) 46# ---------------------------------- 47AC_DEFUN([PKG_PROG_PKG_CONFIG], 48[m4_pattern_forbid([^_?PKG_[A-Z_]+$]) 49m4_pattern_allow([^PKG_CONFIG(_PATH)?$]) 50AC_ARG_VAR([PKG_CONFIG], [path to pkg-config utility])dnl 51if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then 52 AC_PATH_TOOL([PKG_CONFIG], [pkg-config]) 53fi 54if test -n "$PKG_CONFIG"; then 55 _pkg_min_version=m4_default([$1], [0.9.0]) 56 AC_MSG_CHECKING([pkg-config is at least version $_pkg_min_version]) 57 if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then 58 AC_MSG_RESULT([yes]) 59 else 60 AC_MSG_RESULT([no]) 61 PKG_CONFIG="" 62 fi 63 64fi[]dnl 65])# PKG_PROG_PKG_CONFIG 66 67# PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) 68# 69# Check to see whether a particular set of modules exists. Similar 70# to PKG_CHECK_MODULES(), but does not set variables or print errors. 71# 72# 73# Similar to PKG_CHECK_MODULES, make sure that the first instance of 74# this or PKG_CHECK_MODULES is called, or make sure to call 75# PKG_CHECK_EXISTS manually 76# -------------------------------------------------------------- 77AC_DEFUN([PKG_CHECK_EXISTS], 78[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl 79if test -n "$PKG_CONFIG" && \ 80 AC_RUN_LOG([$PKG_CONFIG --exists --print-errors "$1"]); then 81 m4_ifval([$2], [$2], [:]) 82m4_ifvaln([$3], [else 83 $3])dnl 84fi]) 85 86 87# _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES]) 88# --------------------------------------------- 89m4_define([_PKG_CONFIG], 90[if test -n "$$1"; then 91 pkg_cv_[]$1="$$1" 92 elif test -n "$PKG_CONFIG"; then 93 PKG_CHECK_EXISTS([$3], 94 [pkg_cv_[]$1=`$PKG_CONFIG --[]$2 "$3" 2>/dev/null`], 95 [pkg_failed=yes]) 96 else 97 pkg_failed=untried 98fi[]dnl 99])# _PKG_CONFIG 100 101# _PKG_SHORT_ERRORS_SUPPORTED 102# ----------------------------- 103AC_DEFUN([_PKG_SHORT_ERRORS_SUPPORTED], 104[AC_REQUIRE([PKG_PROG_PKG_CONFIG]) 105if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 106 _pkg_short_errors_supported=yes 107else 108 _pkg_short_errors_supported=no 109fi[]dnl 110])# _PKG_SHORT_ERRORS_SUPPORTED 111 112 113# PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND], 114# [ACTION-IF-NOT-FOUND]) 115# 116# 117# Note that if there is a possibility the first call to 118# PKG_CHECK_MODULES might not happen, you should be sure to include an 119# explicit call to PKG_PROG_PKG_CONFIG in your configure.ac 120# 121# 122# -------------------------------------------------------------- 123AC_DEFUN([PKG_CHECK_MODULES], 124[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl 125AC_ARG_VAR([$1][_CFLAGS], [C compiler flags for $1, overriding pkg-config])dnl 126AC_ARG_VAR([$1][_LIBS], [linker flags for $1, overriding pkg-config])dnl 127 128pkg_failed=no 129AC_MSG_CHECKING([for $1]) 130 131_PKG_CONFIG([$1][_CFLAGS], [cflags], [$2]) 132_PKG_CONFIG([$1][_LIBS], [libs], [$2]) 133 134m4_define([_PKG_TEXT], [Alternatively, you may set the environment variables $1[]_CFLAGS 135and $1[]_LIBS to avoid the need to call pkg-config. 136See the pkg-config man page for more details.]) 137 138if test $pkg_failed = yes; then 139 _PKG_SHORT_ERRORS_SUPPORTED 140 if test $_pkg_short_errors_supported = yes; then 141 $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "$2" 2>&1` 142 else 143 $1[]_PKG_ERRORS=`$PKG_CONFIG --print-errors "$2" 2>&1` 144 fi 145 # Put the nasty error message in config.log where it belongs 146 echo "$$1[]_PKG_ERRORS" >&AS_MESSAGE_LOG_FD 147 148 ifelse([$4], , [AC_MSG_ERROR(dnl 149[Package requirements ($2) were not met: 150 151$$1_PKG_ERRORS 152 153Consider adjusting the PKG_CONFIG_PATH environment variable if you 154installed software in a non-standard prefix. 155 156_PKG_TEXT 157])], 158 [AC_MSG_RESULT([no]) 159 $4]) 160elif test $pkg_failed = untried; then 161 ifelse([$4], , [AC_MSG_FAILURE(dnl 162[The pkg-config script could not be found or is too old. Make sure it 163is in your PATH or set the PKG_CONFIG environment variable to the full 164path to pkg-config. 165 166_PKG_TEXT 167 168To get pkg-config, see <http://pkg-config.freedesktop.org/>.])], 169 [$4]) 170else 171 $1[]_CFLAGS=$pkg_cv_[]$1[]_CFLAGS 172 $1[]_LIBS=$pkg_cv_[]$1[]_LIBS 173 AC_MSG_RESULT([yes]) 174 ifelse([$3], , :, [$3]) 175fi[]dnl 176])# PKG_CHECK_MODULES 177 178# Copyright (C) 2002, 2003, 2005, 2006, 2007 Free Software Foundation, Inc. 179# 180# This file is free software; the Free Software Foundation 181# gives unlimited permission to copy and/or distribute it, 182# with or without modifications, as long as this notice is preserved. 183 184# AM_AUTOMAKE_VERSION(VERSION) 185# ---------------------------- 186# Automake X.Y traces this macro to ensure aclocal.m4 has been 187# generated from the m4 files accompanying Automake X.Y. 188# (This private macro should not be called outside this file.) 189AC_DEFUN([AM_AUTOMAKE_VERSION], 190[am__api_version='1.10' 191dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to 192dnl require some minimum version. Point them to the right macro. 193m4_if([$1], [1.10.1], [], 194 [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl 195]) 196 197# _AM_AUTOCONF_VERSION(VERSION) 198# ----------------------------- 199# aclocal traces this macro to find the Autoconf version. 200# This is a private macro too. Using m4_define simplifies 201# the logic in aclocal, which can simply ignore this definition. 202m4_define([_AM_AUTOCONF_VERSION], []) 203 204# AM_SET_CURRENT_AUTOMAKE_VERSION 205# ------------------------------- 206# Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced. 207# This function is AC_REQUIREd by AC_INIT_AUTOMAKE. 208AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION], 209[AM_AUTOMAKE_VERSION([1.10.1])dnl 210m4_ifndef([AC_AUTOCONF_VERSION], 211 [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl 212_AM_AUTOCONF_VERSION(AC_AUTOCONF_VERSION)]) 213 214# AM_AUX_DIR_EXPAND -*- Autoconf -*- 215 216# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. 217# 218# This file is free software; the Free Software Foundation 219# gives unlimited permission to copy and/or distribute it, 220# with or without modifications, as long as this notice is preserved. 221 222# For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets 223# $ac_aux_dir to `$srcdir/foo'. In other projects, it is set to 224# `$srcdir', `$srcdir/..', or `$srcdir/../..'. 225# 226# Of course, Automake must honor this variable whenever it calls a 227# tool from the auxiliary directory. The problem is that $srcdir (and 228# therefore $ac_aux_dir as well) can be either absolute or relative, 229# depending on how configure is run. This is pretty annoying, since 230# it makes $ac_aux_dir quite unusable in subdirectories: in the top 231# source directory, any form will work fine, but in subdirectories a 232# relative path needs to be adjusted first. 233# 234# $ac_aux_dir/missing 235# fails when called from a subdirectory if $ac_aux_dir is relative 236# $top_srcdir/$ac_aux_dir/missing 237# fails if $ac_aux_dir is absolute, 238# fails when called from a subdirectory in a VPATH build with 239# a relative $ac_aux_dir 240# 241# The reason of the latter failure is that $top_srcdir and $ac_aux_dir 242# are both prefixed by $srcdir. In an in-source build this is usually 243# harmless because $srcdir is `.', but things will broke when you 244# start a VPATH build or use an absolute $srcdir. 245# 246# So we could use something similar to $top_srcdir/$ac_aux_dir/missing, 247# iff we strip the leading $srcdir from $ac_aux_dir. That would be: 248# am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"` 249# and then we would define $MISSING as 250# MISSING="\${SHELL} $am_aux_dir/missing" 251# This will work as long as MISSING is not called from configure, because 252# unfortunately $(top_srcdir) has no meaning in configure. 253# However there are other variables, like CC, which are often used in 254# configure, and could therefore not use this "fixed" $ac_aux_dir. 255# 256# Another solution, used here, is to always expand $ac_aux_dir to an 257# absolute PATH. The drawback is that using absolute paths prevent a 258# configured tree to be moved without reconfiguration. 259 260AC_DEFUN([AM_AUX_DIR_EXPAND], 261[dnl Rely on autoconf to set up CDPATH properly. 262AC_PREREQ([2.50])dnl 263# expand $ac_aux_dir to an absolute path 264am_aux_dir=`cd $ac_aux_dir && pwd` 265]) 266 267# Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005 268# Free Software Foundation, Inc. 269# 270# This file is free software; the Free Software Foundation 271# gives unlimited permission to copy and/or distribute it, 272# with or without modifications, as long as this notice is preserved. 273 274# serial 8 275 276# AM_CONFIG_HEADER is obsolete. It has been replaced by AC_CONFIG_HEADERS. 277AU_DEFUN([AM_CONFIG_HEADER], [AC_CONFIG_HEADERS($@)]) 278 279# Do all the work for Automake. -*- Autoconf -*- 280 281# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 282# 2005, 2006, 2008 Free Software Foundation, Inc. 283# 284# This file is free software; the Free Software Foundation 285# gives unlimited permission to copy and/or distribute it, 286# with or without modifications, as long as this notice is preserved. 287 288# serial 13 289 290# This macro actually does too much. Some checks are only needed if 291# your package does certain things. But this isn't really a big deal. 292 293# AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE]) 294# AM_INIT_AUTOMAKE([OPTIONS]) 295# ----------------------------------------------- 296# The call with PACKAGE and VERSION arguments is the old style 297# call (pre autoconf-2.50), which is being phased out. PACKAGE 298# and VERSION should now be passed to AC_INIT and removed from 299# the call to AM_INIT_AUTOMAKE. 300# We support both call styles for the transition. After 301# the next Automake release, Autoconf can make the AC_INIT 302# arguments mandatory, and then we can depend on a new Autoconf 303# release and drop the old call support. 304AC_DEFUN([AM_INIT_AUTOMAKE], 305[AC_PREREQ([2.60])dnl 306dnl Autoconf wants to disallow AM_ names. We explicitly allow 307dnl the ones we care about. 308m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl 309AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl 310AC_REQUIRE([AC_PROG_INSTALL])dnl 311if test "`cd $srcdir && pwd`" != "`pwd`"; then 312 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output 313 # is not polluted with repeated "-I." 314 AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl 315 # test to see if srcdir already configured 316 if test -f $srcdir/config.status; then 317 AC_MSG_ERROR([source directory already configured; run "make distclean" there first]) 318 fi 319fi 320 321# test whether we have cygpath 322if test -z "$CYGPATH_W"; then 323 if (cygpath --version) >/dev/null 2>/dev/null; then 324 CYGPATH_W='cygpath -w' 325 else 326 CYGPATH_W=echo 327 fi 328fi 329AC_SUBST([CYGPATH_W]) 330 331# Define the identity of the package. 332dnl Distinguish between old-style and new-style calls. 333m4_ifval([$2], 334[m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl 335 AC_SUBST([PACKAGE], [$1])dnl 336 AC_SUBST([VERSION], [$2])], 337[_AM_SET_OPTIONS([$1])dnl 338dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT. 339m4_if(m4_ifdef([AC_PACKAGE_NAME], 1)m4_ifdef([AC_PACKAGE_VERSION], 1), 11,, 340 [m4_fatal([AC_INIT should be called with package and version arguments])])dnl 341 AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl 342 AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl 343 344_AM_IF_OPTION([no-define],, 345[AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package]) 346 AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl 347 348# Some tools Automake needs. 349AC_REQUIRE([AM_SANITY_CHECK])dnl 350AC_REQUIRE([AC_ARG_PROGRAM])dnl 351AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version}) 352AM_MISSING_PROG(AUTOCONF, autoconf) 353AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version}) 354AM_MISSING_PROG(AUTOHEADER, autoheader) 355AM_MISSING_PROG(MAKEINFO, makeinfo) 356AM_PROG_INSTALL_SH 357AM_PROG_INSTALL_STRIP 358AC_REQUIRE([AM_PROG_MKDIR_P])dnl 359# We need awk for the "check" target. The system "awk" is bad on 360# some platforms. 361AC_REQUIRE([AC_PROG_AWK])dnl 362AC_REQUIRE([AC_PROG_MAKE_SET])dnl 363AC_REQUIRE([AM_SET_LEADING_DOT])dnl 364_AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])], 365 [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])], 366 [_AM_PROG_TAR([v7])])]) 367_AM_IF_OPTION([no-dependencies],, 368[AC_PROVIDE_IFELSE([AC_PROG_CC], 369 [_AM_DEPENDENCIES(CC)], 370 [define([AC_PROG_CC], 371 defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl 372AC_PROVIDE_IFELSE([AC_PROG_CXX], 373 [_AM_DEPENDENCIES(CXX)], 374 [define([AC_PROG_CXX], 375 defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl 376AC_PROVIDE_IFELSE([AC_PROG_OBJC], 377 [_AM_DEPENDENCIES(OBJC)], 378 [define([AC_PROG_OBJC], 379 defn([AC_PROG_OBJC])[_AM_DEPENDENCIES(OBJC)])])dnl 380]) 381]) 382 383 384# When config.status generates a header, we must update the stamp-h file. 385# This file resides in the same directory as the config header 386# that is generated. The stamp files are numbered to have different names. 387 388# Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the 389# loop where config.status creates the headers, so we can generate 390# our stamp files there. 391AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK], 392[# Compute $1's index in $config_headers. 393_am_arg=$1 394_am_stamp_count=1 395for _am_header in $config_headers :; do 396 case $_am_header in 397 $_am_arg | $_am_arg:* ) 398 break ;; 399 * ) 400 _am_stamp_count=`expr $_am_stamp_count + 1` ;; 401 esac 402done 403echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count]) 404 405# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. 406# 407# This file is free software; the Free Software Foundation 408# gives unlimited permission to copy and/or distribute it, 409# with or without modifications, as long as this notice is preserved. 410 411# AM_PROG_INSTALL_SH 412# ------------------ 413# Define $install_sh. 414AC_DEFUN([AM_PROG_INSTALL_SH], 415[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl 416install_sh=${install_sh-"\$(SHELL) $am_aux_dir/install-sh"} 417AC_SUBST(install_sh)]) 418 419# Copyright (C) 2003, 2005 Free Software Foundation, Inc. 420# 421# This file is free software; the Free Software Foundation 422# gives unlimited permission to copy and/or distribute it, 423# with or without modifications, as long as this notice is preserved. 424 425# serial 2 426 427# Check whether the underlying file-system supports filenames 428# with a leading dot. For instance MS-DOS doesn't. 429AC_DEFUN([AM_SET_LEADING_DOT], 430[rm -rf .tst 2>/dev/null 431mkdir .tst 2>/dev/null 432if test -d .tst; then 433 am__leading_dot=. 434else 435 am__leading_dot=_ 436fi 437rmdir .tst 2>/dev/null 438AC_SUBST([am__leading_dot])]) 439 440# Fake the existence of programs that GNU maintainers use. -*- Autoconf -*- 441 442# Copyright (C) 1997, 1999, 2000, 2001, 2003, 2004, 2005 443# Free Software Foundation, Inc. 444# 445# This file is free software; the Free Software Foundation 446# gives unlimited permission to copy and/or distribute it, 447# with or without modifications, as long as this notice is preserved. 448 449# serial 5 450 451# AM_MISSING_PROG(NAME, PROGRAM) 452# ------------------------------ 453AC_DEFUN([AM_MISSING_PROG], 454[AC_REQUIRE([AM_MISSING_HAS_RUN]) 455$1=${$1-"${am_missing_run}$2"} 456AC_SUBST($1)]) 457 458 459# AM_MISSING_HAS_RUN 460# ------------------ 461# Define MISSING if not defined so far and test if it supports --run. 462# If it does, set am_missing_run to use it, otherwise, to nothing. 463AC_DEFUN([AM_MISSING_HAS_RUN], 464[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl 465AC_REQUIRE_AUX_FILE([missing])dnl 466test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing" 467# Use eval to expand $SHELL 468if eval "$MISSING --run true"; then 469 am_missing_run="$MISSING --run " 470else 471 am_missing_run= 472 AC_MSG_WARN([`missing' script is too old or missing]) 473fi 474]) 475 476# Copyright (C) 2003, 2004, 2005, 2006 Free Software Foundation, Inc. 477# 478# This file is free software; the Free Software Foundation 479# gives unlimited permission to copy and/or distribute it, 480# with or without modifications, as long as this notice is preserved. 481 482# AM_PROG_MKDIR_P 483# --------------- 484# Check for `mkdir -p'. 485AC_DEFUN([AM_PROG_MKDIR_P], 486[AC_PREREQ([2.60])dnl 487AC_REQUIRE([AC_PROG_MKDIR_P])dnl 488dnl Automake 1.8 to 1.9.6 used to define mkdir_p. We now use MKDIR_P, 489dnl while keeping a definition of mkdir_p for backward compatibility. 490dnl @MKDIR_P@ is magic: AC_OUTPUT adjusts its value for each Makefile. 491dnl However we cannot define mkdir_p as $(MKDIR_P) for the sake of 492dnl Makefile.ins that do not define MKDIR_P, so we do our own 493dnl adjustment using top_builddir (which is defined more often than 494dnl MKDIR_P). 495AC_SUBST([mkdir_p], ["$MKDIR_P"])dnl 496case $mkdir_p in 497 [[\\/$]]* | ?:[[\\/]]*) ;; 498 */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;; 499esac 500]) 501 502# Helper functions for option handling. -*- Autoconf -*- 503 504# Copyright (C) 2001, 2002, 2003, 2005 Free Software Foundation, Inc. 505# 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. 509 510# serial 3 511 512# _AM_MANGLE_OPTION(NAME) 513# ----------------------- 514AC_DEFUN([_AM_MANGLE_OPTION], 515[[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])]) 516 517# _AM_SET_OPTION(NAME) 518# ------------------------------ 519# Set option NAME. Presently that only means defining a flag for this option. 520AC_DEFUN([_AM_SET_OPTION], 521[m4_define(_AM_MANGLE_OPTION([$1]), 1)]) 522 523# _AM_SET_OPTIONS(OPTIONS) 524# ---------------------------------- 525# OPTIONS is a space-separated list of Automake options. 526AC_DEFUN([_AM_SET_OPTIONS], 527[AC_FOREACH([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])]) 528 529# _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET]) 530# ------------------------------------------- 531# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. 532AC_DEFUN([_AM_IF_OPTION], 533[m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])]) 534 535# Check to make sure that the build environment is sane. -*- Autoconf -*- 536 537# Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005 538# Free Software Foundation, Inc. 539# 540# This file is free software; the Free Software Foundation 541# gives unlimited permission to copy and/or distribute it, 542# with or without modifications, as long as this notice is preserved. 543 544# serial 4 545 546# AM_SANITY_CHECK 547# --------------- 548AC_DEFUN([AM_SANITY_CHECK], 549[AC_MSG_CHECKING([whether build environment is sane]) 550# Just in case 551sleep 1 552echo timestamp > conftest.file 553# Do `set' in a subshell so we don't clobber the current shell's 554# arguments. Must try -L first in case configure is actually a 555# symlink; some systems play weird games with the mod time of symlinks 556# (eg FreeBSD returns the mod time of the symlink's containing 557# directory). 558if ( 559 set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null` 560 if test "$[*]" = "X"; then 561 # -L didn't work. 562 set X `ls -t $srcdir/configure conftest.file` 563 fi 564 rm -f conftest.file 565 if test "$[*]" != "X $srcdir/configure conftest.file" \ 566 && test "$[*]" != "X conftest.file $srcdir/configure"; then 567 568 # If neither matched, then we have a broken ls. This can happen 569 # if, for instance, CONFIG_SHELL is bash and it inherits a 570 # broken ls alias from the environment. This has actually 571 # happened. Such a system could not be considered "sane". 572 AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken 573alias in your environment]) 574 fi 575 576 test "$[2]" = conftest.file 577 ) 578then 579 # Ok. 580 : 581else 582 AC_MSG_ERROR([newly created file is older than distributed files! 583Check your system clock]) 584fi 585AC_MSG_RESULT(yes)]) 586 587# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. 588# 589# This file is free software; the Free Software Foundation 590# gives unlimited permission to copy and/or distribute it, 591# with or without modifications, as long as this notice is preserved. 592 593# AM_PROG_INSTALL_STRIP 594# --------------------- 595# One issue with vendor `install' (even GNU) is that you can't 596# specify the program used to strip binaries. This is especially 597# annoying in cross-compiling environments, where the build's strip 598# is unlikely to handle the host's binaries. 599# Fortunately install-sh will honor a STRIPPROG variable, so we 600# always use install-sh in `make install-strip', and initialize 601# STRIPPROG with the value of the STRIP variable (set by the user). 602AC_DEFUN([AM_PROG_INSTALL_STRIP], 603[AC_REQUIRE([AM_PROG_INSTALL_SH])dnl 604# Installed binaries are usually stripped using `strip' when the user 605# run `make install-strip'. However `strip' might not be the right 606# tool to use in cross-compilation environments, therefore Automake 607# will honor the `STRIP' environment variable to overrule this program. 608dnl Don't test for $cross_compiling = yes, because it might be `maybe'. 609if test "$cross_compiling" != no; then 610 AC_CHECK_TOOL([STRIP], [strip], :) 611fi 612INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" 613AC_SUBST([INSTALL_STRIP_PROGRAM])]) 614 615# Copyright (C) 2006 Free Software Foundation, Inc. 616# 617# This file is free software; the Free Software Foundation 618# gives unlimited permission to copy and/or distribute it, 619# with or without modifications, as long as this notice is preserved. 620 621# _AM_SUBST_NOTMAKE(VARIABLE) 622# --------------------------- 623# Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in. 624# This macro is traced by Automake. 625AC_DEFUN([_AM_SUBST_NOTMAKE]) 626 627# Check how to create a tarball. -*- Autoconf -*- 628 629# Copyright (C) 2004, 2005 Free Software Foundation, Inc. 630# 631# This file is free software; the Free Software Foundation 632# gives unlimited permission to copy and/or distribute it, 633# with or without modifications, as long as this notice is preserved. 634 635# serial 2 636 637# _AM_PROG_TAR(FORMAT) 638# -------------------- 639# Check how to create a tarball in format FORMAT. 640# FORMAT should be one of `v7', `ustar', or `pax'. 641# 642# Substitute a variable $(am__tar) that is a command 643# writing to stdout a FORMAT-tarball containing the directory 644# $tardir. 645# tardir=directory && $(am__tar) > result.tar 646# 647# Substitute a variable $(am__untar) that extract such 648# a tarball read from stdin. 649# $(am__untar) < result.tar 650AC_DEFUN([_AM_PROG_TAR], 651[# Always define AMTAR for backward compatibility. 652AM_MISSING_PROG([AMTAR], [tar]) 653m4_if([$1], [v7], 654 [am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'], 655 [m4_case([$1], [ustar],, [pax],, 656 [m4_fatal([Unknown tar format])]) 657AC_MSG_CHECKING([how to create a $1 tar archive]) 658# Loop over all known methods to create a tar archive until one works. 659_am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none' 660_am_tools=${am_cv_prog_tar_$1-$_am_tools} 661# Do not fold the above two line into one, because Tru64 sh and 662# Solaris sh will not grok spaces in the rhs of `-'. 663for _am_tool in $_am_tools 664do 665 case $_am_tool in 666 gnutar) 667 for _am_tar in tar gnutar gtar; 668 do 669 AM_RUN_LOG([$_am_tar --version]) && break 670 done 671 am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"' 672 am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"' 673 am__untar="$_am_tar -xf -" 674 ;; 675 plaintar) 676 # Must skip GNU tar: if it does not support --format= it doesn't create 677 # ustar tarball either. 678 (tar --version) >/dev/null 2>&1 && continue 679 am__tar='tar chf - "$$tardir"' 680 am__tar_='tar chf - "$tardir"' 681 am__untar='tar xf -' 682 ;; 683 pax) 684 am__tar='pax -L -x $1 -w "$$tardir"' 685 am__tar_='pax -L -x $1 -w "$tardir"' 686 am__untar='pax -r' 687 ;; 688 cpio) 689 am__tar='find "$$tardir" -print | cpio -o -H $1 -L' 690 am__tar_='find "$tardir" -print | cpio -o -H $1 -L' 691 am__untar='cpio -i -H $1 -d' 692 ;; 693 none) 694 am__tar=false 695 am__tar_=false 696 am__untar=false 697 ;; 698 esac 699 700 # If the value was cached, stop now. We just wanted to have am__tar 701 # and am__untar set. 702 test -n "${am_cv_prog_tar_$1}" && break 703 704 # tar/untar a dummy directory, and stop if the command works 705 rm -rf conftest.dir 706 mkdir conftest.dir 707 echo GrepMe > conftest.dir/file 708 AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar]) 709 rm -rf conftest.dir 710 if test -s conftest.tar; then 711 AM_RUN_LOG([$am__untar <conftest.tar]) 712 grep GrepMe conftest.dir/file >/dev/null 2>&1 && break 713 fi 714done 715rm -rf conftest.dir 716 717AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool]) 718AC_MSG_RESULT([$am_cv_prog_tar_$1])]) 719AC_SUBST([am__tar]) 720AC_SUBST([am__untar]) 721]) # _AM_PROG_TAR 722 723m4_include([acinclude.m4]) 724