14
14
m4_ifndef([AC_AUTOCONF_VERSION],
15
15
[m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
16
m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.67],,
17
[m4_warning([this file was generated for autoconf 2.67.
16
m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.68],,
17
[m4_warning([this file was generated for autoconf 2.68.
18
18
You have another version of autoconf. It may work, but is not guaranteed to.
19
19
If you have problems, you may need to regenerate the build system entirely.
20
20
To do so, use the procedure documented by the package, typically `autoreconf'.])])
22
# pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*-
23
# serial 1 (pkg-config-0.24)
25
# Copyright © 2004 Scott James Remnant <scott@netsplit.com>.
27
# This program is free software; you can redistribute it and/or modify
28
# it under the terms of the GNU General Public License as published by
29
# the Free Software Foundation; either version 2 of the License, or
30
# (at your option) any later version.
32
# This program is distributed in the hope that it will be useful, but
33
# WITHOUT ANY WARRANTY; without even the implied warranty of
34
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
35
# General Public License for more details.
37
# You should have received a copy of the GNU General Public License
38
# along with this program; if not, write to the Free Software
39
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
41
# As a special exception to the GNU General Public License, if you
42
# distribute this file as part of a program that contains a
43
# configuration script generated by Autoconf, you may include it under
44
# the same distribution terms that you use for the rest of that program.
46
# PKG_PROG_PKG_CONFIG([MIN-VERSION])
47
# ----------------------------------
48
AC_DEFUN([PKG_PROG_PKG_CONFIG],
49
[m4_pattern_forbid([^_?PKG_[A-Z_]+$])
50
m4_pattern_allow([^PKG_CONFIG(_(PATH|LIBDIR|SYSROOT_DIR|ALLOW_SYSTEM_(CFLAGS|LIBS)))?$])
51
m4_pattern_allow([^PKG_CONFIG_(DISABLE_UNINSTALLED|TOP_BUILD_DIR|DEBUG_SPEW)$])
52
AC_ARG_VAR([PKG_CONFIG], [path to pkg-config utility])
53
AC_ARG_VAR([PKG_CONFIG_PATH], [directories to add to pkg-config's search path])
54
AC_ARG_VAR([PKG_CONFIG_LIBDIR], [path overriding pkg-config's built-in search path])
56
if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
57
AC_PATH_TOOL([PKG_CONFIG], [pkg-config])
59
if test -n "$PKG_CONFIG"; then
60
_pkg_min_version=m4_default([$1], [0.9.0])
61
AC_MSG_CHECKING([pkg-config is at least version $_pkg_min_version])
62
if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
69
])# PKG_PROG_PKG_CONFIG
71
# PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
73
# Check to see whether a particular set of modules exists. Similar
74
# to PKG_CHECK_MODULES(), but does not set variables or print errors.
76
# Please remember that m4 expands AC_REQUIRE([PKG_PROG_PKG_CONFIG])
77
# only at the first occurence in configure.ac, so if the first place
78
# it's called might be skipped (such as if it is within an "if", you
79
# have to call PKG_CHECK_EXISTS manually
80
# --------------------------------------------------------------
81
AC_DEFUN([PKG_CHECK_EXISTS],
82
[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl
83
if test -n "$PKG_CONFIG" && \
84
AC_RUN_LOG([$PKG_CONFIG --exists --print-errors "$1"]); then
90
# _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES])
91
# ---------------------------------------------
92
m4_define([_PKG_CONFIG],
93
[if test -n "$$1"; then
95
elif test -n "$PKG_CONFIG"; then
96
PKG_CHECK_EXISTS([$3],
97
[pkg_cv_[]$1=`$PKG_CONFIG --[]$2 "$3" 2>/dev/null`
98
test "x$?" != "x0" && pkg_failed=yes ],
105
# _PKG_SHORT_ERRORS_SUPPORTED
106
# -----------------------------
107
AC_DEFUN([_PKG_SHORT_ERRORS_SUPPORTED],
108
[AC_REQUIRE([PKG_PROG_PKG_CONFIG])
109
if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
110
_pkg_short_errors_supported=yes
112
_pkg_short_errors_supported=no
114
])# _PKG_SHORT_ERRORS_SUPPORTED
117
# PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND],
118
# [ACTION-IF-NOT-FOUND])
121
# Note that if there is a possibility the first call to
122
# PKG_CHECK_MODULES might not happen, you should be sure to include an
123
# explicit call to PKG_PROG_PKG_CONFIG in your configure.ac
126
# --------------------------------------------------------------
127
AC_DEFUN([PKG_CHECK_MODULES],
128
[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl
129
AC_ARG_VAR([$1][_CFLAGS], [C compiler flags for $1, overriding pkg-config])dnl
130
AC_ARG_VAR([$1][_LIBS], [linker flags for $1, overriding pkg-config])dnl
133
AC_MSG_CHECKING([for $1])
135
_PKG_CONFIG([$1][_CFLAGS], [cflags], [$2])
136
_PKG_CONFIG([$1][_LIBS], [libs], [$2])
138
m4_define([_PKG_TEXT], [Alternatively, you may set the environment variables $1[]_CFLAGS
139
and $1[]_LIBS to avoid the need to call pkg-config.
140
See the pkg-config man page for more details.])
142
if test $pkg_failed = yes; then
144
_PKG_SHORT_ERRORS_SUPPORTED
145
if test $_pkg_short_errors_supported = yes; then
146
$1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "$2" 2>&1`
148
$1[]_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "$2" 2>&1`
150
# Put the nasty error message in config.log where it belongs
151
echo "$$1[]_PKG_ERRORS" >&AS_MESSAGE_LOG_FD
153
m4_default([$4], [AC_MSG_ERROR(
154
[Package requirements ($2) were not met:
158
Consider adjusting the PKG_CONFIG_PATH environment variable if you
159
installed software in a non-standard prefix.
163
elif test $pkg_failed = untried; then
165
m4_default([$4], [AC_MSG_FAILURE(
166
[The pkg-config script could not be found or is too old. Make sure it
167
is in your PATH or set the PKG_CONFIG environment variable to the full
172
To get pkg-config, see <http://pkg-config.freedesktop.org/>.])[]dnl
175
$1[]_CFLAGS=$pkg_cv_[]$1[]_CFLAGS
176
$1[]_LIBS=$pkg_cv_[]$1[]_LIBS
180
])# PKG_CHECK_MODULES
22
182
# Copyright (C) 2002, 2003, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
24
184
# This file is free software; the Free Software Foundation
819
979
AC_MSG_RESULT(yes)])
981
# Copyright (C) 2009 Free Software Foundation, Inc.
983
# This file is free software; the Free Software Foundation
984
# gives unlimited permission to copy and/or distribute it,
985
# with or without modifications, as long as this notice is preserved.
989
# AM_SILENT_RULES([DEFAULT])
990
# --------------------------
991
# Enable less verbose build rules; with the default set to DEFAULT
992
# (`yes' being less verbose, `no' or empty being verbose).
993
AC_DEFUN([AM_SILENT_RULES],
994
[AC_ARG_ENABLE([silent-rules],
995
[ --enable-silent-rules less verbose build output (undo: `make V=1')
996
--disable-silent-rules verbose build output (undo: `make V=0')])
997
case $enable_silent_rules in
998
yes) AM_DEFAULT_VERBOSITY=0;;
999
no) AM_DEFAULT_VERBOSITY=1;;
1000
*) AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);;
1002
AC_SUBST([AM_DEFAULT_VERBOSITY])dnl
1004
AC_SUBST([AM_BACKSLASH])dnl
1005
_AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl
821
1008
# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc.
823
1010
# This file is free software; the Free Software Foundation
964
1151
m4_include([gl/m4/00gnulib.m4])
965
1152
m4_include([gl/m4/alloca.m4])
966
m4_include([gl/m4/asm-underscore.m4])
967
1153
m4_include([gl/m4/byteswap.m4])
968
1154
m4_include([gl/m4/errno_h.m4])
969
1155
m4_include([gl/m4/extensions.m4])
1156
m4_include([gl/m4/fcntl-o.m4])
1157
m4_include([gl/m4/fcntl_h.m4])
970
1158
m4_include([gl/m4/float_h.m4])
1159
m4_include([gl/m4/fpieee.m4])
1160
m4_include([gl/m4/fseek.m4])
971
1161
m4_include([gl/m4/fseeko.m4])
1162
m4_include([gl/m4/ftell.m4])
1163
m4_include([gl/m4/ftello.m4])
972
1164
m4_include([gl/m4/func.m4])
1165
m4_include([gl/m4/getpagesize.m4])
973
1166
m4_include([gl/m4/gnulib-common.m4])
974
1167
m4_include([gl/m4/gnulib-comp.m4])
975
1168
m4_include([gl/m4/include_next.m4])
976
1169
m4_include([gl/m4/intmax_t.m4])
1170
m4_include([gl/m4/inttypes.m4])
1171
m4_include([gl/m4/largefile.m4])
977
1172
m4_include([gl/m4/ld-output-def.m4])
978
1173
m4_include([gl/m4/ld-version-script.m4])
979
1174
m4_include([gl/m4/lseek.m4])