9142
9149
m4_popdef([pkg_description])
9143
9150
]) dnl PKG_NOARCH_INSTALLDIR
9145
# Copyright (C) 2002-2012 Free Software Foundation, Inc.
9153
# PKG_CHECK_VAR(VARIABLE, MODULE, CONFIG-VARIABLE,
9154
# [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
9155
# -------------------------------------------
9156
# Retrieves the value of the pkg-config variable for the given module.
9157
AC_DEFUN([PKG_CHECK_VAR],
9158
[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl
9159
AC_ARG_VAR([$1], [value of $3 for $2, overriding pkg-config])dnl
9161
_PKG_CONFIG([$1], [variable="][$3]["], [$2])
9162
AS_VAR_COPY([$1], [pkg_cv_][$1])
9164
AS_VAR_IF([$1], [""], [$5], [$4])dnl
9167
# Copyright (C) 2002-2013 Free Software Foundation, Inc.
9147
9169
# This file is free software; the Free Software Foundation
9148
9170
# gives unlimited permission to copy and/or distribute it,
9149
9171
# with or without modifications, as long as this notice is preserved.
9153
9173
# AM_AUTOMAKE_VERSION(VERSION)
9154
9174
# ----------------------------
9155
9175
# Automake X.Y traces this macro to ensure aclocal.m4 has been
9156
9176
# generated from the m4 files accompanying Automake X.Y.
9157
9177
# (This private macro should not be called outside this file.)
9158
9178
AC_DEFUN([AM_AUTOMAKE_VERSION],
9159
[am__api_version='1.12'
9179
[am__api_version='1.14'
9160
9180
dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to
9161
9181
dnl require some minimum version. Point them to the right macro.
9162
m4_if([$1], [1.12.2], [],
9182
m4_if([$1], [1.14], [],
9163
9183
[AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl
9175
9195
# Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced.
9176
9196
# This function is AC_REQUIREd by AM_INIT_AUTOMAKE.
9177
9197
AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
9178
[AM_AUTOMAKE_VERSION([1.12.2])dnl
9198
[AM_AUTOMAKE_VERSION([1.14])dnl
9179
9199
m4_ifndef([AC_AUTOCONF_VERSION],
9180
9200
[m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
9181
9201
_AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))])
9183
9203
# AM_AUX_DIR_EXPAND -*- Autoconf -*-
9185
# Copyright (C) 2001-2012 Free Software Foundation, Inc.
9205
# Copyright (C) 2001-2013 Free Software Foundation, Inc.
9187
9207
# This file is free software; the Free Software Foundation
9188
9208
# gives unlimited permission to copy and/or distribute it,
9189
9209
# with or without modifications, as long as this notice is preserved.
9193
9211
# For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets
9194
9212
# $ac_aux_dir to '$srcdir/foo'. In other projects, it is set to
9195
9213
# '$srcdir', '$srcdir/..', or '$srcdir/../..'.
9647
9664
[_AM_DEPENDENCIES([OBJC])],
9648
9665
[m4_define([AC_PROG_OBJC],
9649
9666
m4_defn([AC_PROG_OBJC])[_AM_DEPENDENCIES([OBJC])])])dnl
9650
dnl Support for Objective C++ was only introduced in Autoconf 2.65,
9651
dnl but we still cater to Autoconf 2.62.
9652
m4_ifdef([AC_PROG_OBJCXX],
9653
[AC_PROVIDE_IFELSE([AC_PROG_OBJCXX],
9667
AC_PROVIDE_IFELSE([AC_PROG_OBJCXX],
9654
9668
[_AM_DEPENDENCIES([OBJCXX])],
9655
9669
[m4_define([AC_PROG_OBJCXX],
9656
m4_defn([AC_PROG_OBJCXX])[_AM_DEPENDENCIES([OBJCXX])])])])dnl
9670
m4_defn([AC_PROG_OBJCXX])[_AM_DEPENDENCIES([OBJCXX])])])dnl
9658
_AM_IF_OPTION([silent-rules], [AC_REQUIRE([AM_SILENT_RULES])])dnl
9659
dnl The 'parallel-tests' driver may need to know about EXEEXT, so add the
9660
dnl 'am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This macro
9661
dnl is hooked onto _AC_COMPILER_EXEEXT early, see below.
9672
AC_REQUIRE([AM_SILENT_RULES])dnl
9673
dnl The testsuite driver may need to know about EXEEXT, so add the
9674
dnl 'am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This
9675
dnl macro is hooked onto _AC_COMPILER_EXEEXT early, see below.
9662
9676
AC_CONFIG_COMMANDS_PRE(dnl
9663
9677
[m4_provide_if([_AM_COMPILER_EXEEXT],
9664
9678
[AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl
9680
# POSIX will say in a future version that running "rm -f" with no argument
9681
# is OK; and we want to be able to make that assumption in our Makefile
9682
# recipes. So use an aggressive probe to check that the usage we want is
9683
# actually supported "in the wild" to an acceptable degree.
9684
# See automake bug#10828.
9685
# To make any issue more visible, cause the running configure to be aborted
9686
# by default if the 'rm' program in use doesn't match our expectations; the
9687
# user can still override this though.
9688
if rm -f && rm -fr && rm -rf; then : OK; else
9692
Your 'rm' program seems unable to run without file operands specified
9693
on the command line, even when the '-f' option is present. This is contrary
9694
to the behaviour of most rm programs out there, and not conforming with
9695
the upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542>
9697
Please tell bug-automake@gnu.org about your system, including the value
9698
of your $PATH and any error possibly output before this message. This
9699
can help us improve future automake versions.
9702
if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then
9703
echo 'Configuration will proceed anyway, since you have set the' >&2
9704
echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2
9708
Aborting the configuration process, to ensure you take notice of the issue.
9710
You can download and install GNU coreutils to get an 'rm' implementation
9711
that behaves properly: <http://www.gnu.org/software/coreutils/>.
9713
If you want to complete the configuration process using your problematic
9714
'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM
9715
to "yes", and re-run configure.
9718
AC_MSG_ERROR([Your 'rm' program is bad, sorry.])
9667
9722
dnl Hook into '_AC_COMPILER_EXEEXT' early to learn its expansion. Do not
9668
9723
dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further
9788
9836
rm -f confinc confmf
9791
# Copyright (C) 1999-2012 Free Software Foundation, Inc.
9793
# This file is free software; the Free Software Foundation
9794
# gives unlimited permission to copy and/or distribute it,
9795
# with or without modifications, as long as this notice is preserved.
9801
# Like AC_PROG_CC_C_O, but changed for automake.
9802
AC_DEFUN([AM_PROG_CC_C_O],
9803
[AC_REQUIRE([AC_PROG_CC_C_O])dnl
9804
AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
9805
AC_REQUIRE_AUX_FILE([compile])dnl
9806
# FIXME: we rely on the cache variable name because
9807
# there is no other way.
9809
am_cc=`echo $[2] | sed ['s/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/']`
9810
eval am_t=\$ac_cv_prog_cc_${am_cc}_c_o
9811
if test "$am_t" != yes; then
9812
# Losing compiler, so override with the script.
9813
# FIXME: It is wrong to rewrite CC.
9814
# But if we don't then we get into trouble of one sort or another.
9815
# A longer-term fix would be to have automake use am__CC in this case,
9816
# and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
9817
CC="$am_aux_dir/compile $CC"
9819
dnl Make sure AC_PROG_CC is never called again, or it will override our
9821
m4_define([AC_PROG_CC],
9822
[m4_fatal([AC_PROG_CC cannot be called after AM_PROG_CC_C_O])])
9825
9839
# Fake the existence of programs that GNU maintainers use. -*- Autoconf -*-
9827
# Copyright (C) 1997-2012 Free Software Foundation, Inc.
9841
# Copyright (C) 1997-2013 Free Software Foundation, Inc.
9829
9843
# This file is free software; the Free Software Foundation
9830
9844
# gives unlimited permission to copy and/or distribute it,
9831
9845
# with or without modifications, as long as this notice is preserved.
9835
9847
# AM_MISSING_PROG(NAME, PROGRAM)
9836
9848
# ------------------------------
9837
9849
AC_DEFUN([AM_MISSING_PROG],
9897
9906
AC_DEFUN([_AM_IF_OPTION],
9898
9907
[m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
9909
# Copyright (C) 1999-2013 Free Software Foundation, Inc.
9911
# This file is free software; the Free Software Foundation
9912
# gives unlimited permission to copy and/or distribute it,
9913
# with or without modifications, as long as this notice is preserved.
9917
# Like AC_PROG_CC_C_O, but changed for automake. We rewrite AC_PROG_CC
9918
# to automatically call this.
9919
AC_DEFUN([_AM_PROG_CC_C_O],
9920
[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
9921
AC_REQUIRE_AUX_FILE([compile])dnl
9922
AC_LANG_PUSH([C])dnl
9924
[whether $CC understands -c and -o together],
9925
[am_cv_prog_cc_c_o],
9926
[AC_LANG_CONFTEST([AC_LANG_PROGRAM([])])
9927
# Make sure it works both with $CC and with simple cc.
9928
# Following AC_PROG_CC_C_O, we do the test twice because some
9929
# compilers refuse to overwrite an existing .o file with -o,
9930
# though they will create one.
9931
am_cv_prog_cc_c_o=yes
9933
if AM_RUN_LOG([$CC -c conftest.$ac_ext -o conftest2.$ac_objext]) \
9934
&& test -f conftest2.$ac_objext; then
9937
am_cv_prog_cc_c_o=no
9941
rm -f core conftest*
9943
if test "$am_cv_prog_cc_c_o" != yes; then
9944
# Losing compiler, so override with the script.
9945
# FIXME: It is wrong to rewrite CC.
9946
# But if we don't then we get into trouble of one sort or another.
9947
# A longer-term fix would be to have automake use am__CC in this case,
9948
# and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
9949
CC="$am_aux_dir/compile $CC"
9953
# For backward compatibility.
9954
AC_DEFUN_ONCE([AM_PROG_CC_C_O], [AC_REQUIRE([AC_PROG_CC])])
9956
# Copyright (C) 2001-2013 Free Software Foundation, Inc.
9958
# This file is free software; the Free Software Foundation
9959
# gives unlimited permission to copy and/or distribute it,
9960
# with or without modifications, as long as this notice is preserved.
9962
# AM_RUN_LOG(COMMAND)
9963
# -------------------
9964
# Run COMMAND, save the exit status in ac_status, and log it.
9965
# (This has been adapted from Autoconf's _AC_RUN_LOG macro.)
9966
AC_DEFUN([AM_RUN_LOG],
9967
[{ echo "$as_me:$LINENO: $1" >&AS_MESSAGE_LOG_FD
9968
($1) >&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD
9970
echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
9971
(exit $ac_status); }])
9900
9973
# Check to make sure that the build environment is sane. -*- Autoconf -*-
9902
# Copyright (C) 1996-2012 Free Software Foundation, Inc.
9975
# Copyright (C) 1996-2013 Free Software Foundation, Inc.
9904
9977
# This file is free software; the Free Software Foundation
9905
9978
# gives unlimited permission to copy and/or distribute it,
9906
9979
# with or without modifications, as long as this notice is preserved.
9910
9981
# AM_SANITY_CHECK
9911
9982
# ---------------
9912
9983
AC_DEFUN([AM_SANITY_CHECK],
10116
10179
# Substitute a variable $(am__untar) that extract such
10117
10180
# a tarball read from stdin.
10118
10181
# $(am__untar) < result.tar
10119
10183
AC_DEFUN([_AM_PROG_TAR],
10120
10184
[# Always define AMTAR for backward compatibility. Yes, it's still used
10121
10185
# in the wild :-( We should find a proper way to deprecate it ...
10122
10186
AC_SUBST([AMTAR], ['$${TAR-tar}'])
10188
# We'll loop over all known methods to create a tar archive until one works.
10189
_am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none'
10123
10191
m4_if([$1], [v7],
10124
[am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'],
10125
[m4_case([$1], [ustar],, [pax],,
10126
[m4_fatal([Unknown tar format])])
10127
AC_MSG_CHECKING([how to create a $1 tar archive])
10128
# Loop over all known methods to create a tar archive until one works.
10129
_am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none'
10130
_am_tools=${am_cv_prog_tar_$1-$_am_tools}
10131
# Do not fold the above two line into one, because Tru64 sh and
10132
# Solaris sh will not grok spaces in the rhs of '-'.
10133
for _am_tool in $_am_tools
10137
for _am_tar in tar gnutar gtar;
10139
AM_RUN_LOG([$_am_tar --version]) && break
10141
am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"'
10142
am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"'
10143
am__untar="$_am_tar -xf -"
10146
# Must skip GNU tar: if it does not support --format= it doesn't create
10147
# ustar tarball either.
10148
(tar --version) >/dev/null 2>&1 && continue
10149
am__tar='tar chf - "$$tardir"'
10150
am__tar_='tar chf - "$tardir"'
10151
am__untar='tar xf -'
10154
am__tar='pax -L -x $1 -w "$$tardir"'
10155
am__tar_='pax -L -x $1 -w "$tardir"'
10159
am__tar='find "$$tardir" -print | cpio -o -H $1 -L'
10160
am__tar_='find "$tardir" -print | cpio -o -H $1 -L'
10161
am__untar='cpio -i -H $1 -d'
10170
# If the value was cached, stop now. We just wanted to have am__tar
10171
# and am__untar set.
10172
test -n "${am_cv_prog_tar_$1}" && break
10174
# tar/untar a dummy directory, and stop if the command works
10175
rm -rf conftest.dir
10177
echo GrepMe > conftest.dir/file
10178
AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar])
10179
rm -rf conftest.dir
10180
if test -s conftest.tar; then
10181
AM_RUN_LOG([$am__untar <conftest.tar])
10182
grep GrepMe conftest.dir/file >/dev/null 2>&1 && break
10185
rm -rf conftest.dir
10187
AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool])
10188
AC_MSG_RESULT([$am_cv_prog_tar_$1])])
10192
[am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'],
10196
[# The POSIX 1988 'ustar' format is defined with fixed-size fields.
10197
# There is notably a 21 bits limit for the UID and the GID. In fact,
10198
# the 'pax' utility can hang on bigger UID/GID (see automake bug#8343
10200
am_max_uid=2097151 # 2^21 - 1
10201
am_max_gid=$am_max_uid
10202
# The $UID and $GID variables are not portable, so we need to resort
10203
# to the POSIX-mandated id(1) utility. Errors in the 'id' calls
10204
# below are definitely unexpected, so allow the users to see them
10205
# (that is, avoid stderr redirection).
10206
am_uid=`id -u || echo unknown`
10207
am_gid=`id -g || echo unknown`
10208
AC_MSG_CHECKING([whether UID '$am_uid' is supported by ustar format])
10209
if test $am_uid -le $am_max_uid; then
10210
AC_MSG_RESULT([yes])
10212
AC_MSG_RESULT([no])
10215
AC_MSG_CHECKING([whether GID '$am_gid' is supported by ustar format])
10216
if test $am_gid -le $am_max_gid; then
10217
AC_MSG_RESULT([yes])
10219
AC_MSG_RESULT([no])
10226
[m4_fatal([Unknown tar format])])
10228
AC_MSG_CHECKING([how to create a $1 tar archive])
10230
# Go ahead even if we have the value already cached. We do so because we
10231
# need to set the values for the 'am__tar' and 'am__untar' variables.
10232
_am_tools=${am_cv_prog_tar_$1-$_am_tools}
10234
for _am_tool in $_am_tools; do
10237
for _am_tar in tar gnutar gtar; do
10238
AM_RUN_LOG([$_am_tar --version]) && break
10240
am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"'
10241
am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"'
10242
am__untar="$_am_tar -xf -"
10245
# Must skip GNU tar: if it does not support --format= it doesn't create
10246
# ustar tarball either.
10247
(tar --version) >/dev/null 2>&1 && continue
10248
am__tar='tar chf - "$$tardir"'
10249
am__tar_='tar chf - "$tardir"'
10250
am__untar='tar xf -'
10253
am__tar='pax -L -x $1 -w "$$tardir"'
10254
am__tar_='pax -L -x $1 -w "$tardir"'
10258
am__tar='find "$$tardir" -print | cpio -o -H $1 -L'
10259
am__tar_='find "$tardir" -print | cpio -o -H $1 -L'
10260
am__untar='cpio -i -H $1 -d'
10269
# If the value was cached, stop now. We just wanted to have am__tar
10270
# and am__untar set.
10271
test -n "${am_cv_prog_tar_$1}" && break
10273
# tar/untar a dummy directory, and stop if the command works.
10274
rm -rf conftest.dir
10276
echo GrepMe > conftest.dir/file
10277
AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar])
10278
rm -rf conftest.dir
10279
if test -s conftest.tar; then
10280
AM_RUN_LOG([$am__untar <conftest.tar])
10281
AM_RUN_LOG([cat conftest.dir/file])
10282
grep GrepMe conftest.dir/file >/dev/null 2>&1 && break
10285
rm -rf conftest.dir
10287
AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool])
10288
AC_MSG_RESULT([$am_cv_prog_tar_$1])])
10189
10290
AC_SUBST([am__tar])
10190
10291
AC_SUBST([am__untar])
10191
10292
]) # _AM_PROG_TAR