aclocal.m4 49 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383
  1. # generated automatically by aclocal 1.14.1 -*- Autoconf -*-
  2. # Copyright (C) 1996-2013 Free Software Foundation, Inc.
  3. # This file is free software; the Free Software Foundation
  4. # gives unlimited permission to copy and/or distribute it,
  5. # with or without modifications, as long as this notice is preserved.
  6. # This program is distributed in the hope that it will be useful,
  7. # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
  8. # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
  9. # PARTICULAR PURPOSE.
  10. m4_ifndef([AC_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])])
  11. m4_ifndef([AC_AUTOCONF_VERSION],
  12. [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
  13. m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.69],,
  14. [m4_warning([this file was generated for autoconf 2.69.
  15. You have another version of autoconf. It may work, but is not guaranteed to.
  16. If you have problems, you may need to regenerate the build system entirely.
  17. To do so, use the procedure documented by the package, typically 'autoreconf'.])])
  18. dnl AM_GCONF_SOURCE_2
  19. dnl Defines GCONF_SCHEMA_CONFIG_SOURCE which is where you should install schemas
  20. dnl (i.e. pass to gconftool-2
  21. dnl Defines GCONF_SCHEMA_FILE_DIR which is a filesystem directory where
  22. dnl you should install foo.schemas files
  23. dnl
  24. AC_DEFUN([AM_GCONF_SOURCE_2],
  25. [
  26. if test "x$GCONF_SCHEMA_INSTALL_SOURCE" = "x"; then
  27. GCONF_SCHEMA_CONFIG_SOURCE=`gconftool-2 --get-default-source`
  28. else
  29. GCONF_SCHEMA_CONFIG_SOURCE=$GCONF_SCHEMA_INSTALL_SOURCE
  30. fi
  31. AC_ARG_WITH([gconf-source],
  32. AC_HELP_STRING([--with-gconf-source=sourceaddress],
  33. [Config database for installing schema files.]),
  34. [GCONF_SCHEMA_CONFIG_SOURCE="$withval"],)
  35. AC_SUBST(GCONF_SCHEMA_CONFIG_SOURCE)
  36. AC_MSG_RESULT([Using config source $GCONF_SCHEMA_CONFIG_SOURCE for schema installation])
  37. if test "x$GCONF_SCHEMA_FILE_DIR" = "x"; then
  38. GCONF_SCHEMA_FILE_DIR='$(sysconfdir)/gconf/schemas'
  39. fi
  40. AC_ARG_WITH([gconf-schema-file-dir],
  41. AC_HELP_STRING([--with-gconf-schema-file-dir=dir],
  42. [Directory for installing schema files.]),
  43. [GCONF_SCHEMA_FILE_DIR="$withval"],)
  44. AC_SUBST(GCONF_SCHEMA_FILE_DIR)
  45. AC_MSG_RESULT([Using $GCONF_SCHEMA_FILE_DIR as install directory for schema files])
  46. AC_ARG_ENABLE(schemas-install,
  47. AC_HELP_STRING([--disable-schemas-install],
  48. [Disable the schemas installation]),
  49. [case ${enableval} in
  50. yes|no) ;;
  51. *) AC_MSG_ERROR([bad value ${enableval} for --enable-schemas-install]) ;;
  52. esac])
  53. AM_CONDITIONAL([GCONF_SCHEMAS_INSTALL], [test "$enable_schemas_install" != no])
  54. ])
  55. # pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*-
  56. # serial 1 (pkg-config-0.24)
  57. #
  58. # Copyright © 2004 Scott James Remnant <[email protected]>.
  59. #
  60. # This program is free software; you can redistribute it and/or modify
  61. # it under the terms of the GNU General Public License as published by
  62. # the Free Software Foundation; either version 2 of the License, or
  63. # (at your option) any later version.
  64. #
  65. # This program is distributed in the hope that it will be useful, but
  66. # WITHOUT ANY WARRANTY; without even the implied warranty of
  67. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  68. # General Public License for more details.
  69. #
  70. # You should have received a copy of the GNU General Public License
  71. # along with this program; if not, write to the Free Software
  72. # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
  73. #
  74. # As a special exception to the GNU General Public License, if you
  75. # distribute this file as part of a program that contains a
  76. # configuration script generated by Autoconf, you may include it under
  77. # the same distribution terms that you use for the rest of that program.
  78. # PKG_PROG_PKG_CONFIG([MIN-VERSION])
  79. # ----------------------------------
  80. AC_DEFUN([PKG_PROG_PKG_CONFIG],
  81. [m4_pattern_forbid([^_?PKG_[A-Z_]+$])
  82. m4_pattern_allow([^PKG_CONFIG(_(PATH|LIBDIR|SYSROOT_DIR|ALLOW_SYSTEM_(CFLAGS|LIBS)))?$])
  83. m4_pattern_allow([^PKG_CONFIG_(DISABLE_UNINSTALLED|TOP_BUILD_DIR|DEBUG_SPEW)$])
  84. AC_ARG_VAR([PKG_CONFIG], [path to pkg-config utility])
  85. AC_ARG_VAR([PKG_CONFIG_PATH], [directories to add to pkg-config's search path])
  86. AC_ARG_VAR([PKG_CONFIG_LIBDIR], [path overriding pkg-config's built-in search path])
  87. if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
  88. AC_PATH_TOOL([PKG_CONFIG], [pkg-config])
  89. fi
  90. if test -n "$PKG_CONFIG"; then
  91. _pkg_min_version=m4_default([$1], [0.9.0])
  92. AC_MSG_CHECKING([pkg-config is at least version $_pkg_min_version])
  93. if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
  94. AC_MSG_RESULT([yes])
  95. else
  96. AC_MSG_RESULT([no])
  97. PKG_CONFIG=""
  98. fi
  99. fi[]dnl
  100. ])# PKG_PROG_PKG_CONFIG
  101. # PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
  102. #
  103. # Check to see whether a particular set of modules exists. Similar
  104. # to PKG_CHECK_MODULES(), but does not set variables or print errors.
  105. #
  106. # Please remember that m4 expands AC_REQUIRE([PKG_PROG_PKG_CONFIG])
  107. # only at the first occurence in configure.ac, so if the first place
  108. # it's called might be skipped (such as if it is within an "if", you
  109. # have to call PKG_CHECK_EXISTS manually
  110. # --------------------------------------------------------------
  111. AC_DEFUN([PKG_CHECK_EXISTS],
  112. [AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl
  113. if test -n "$PKG_CONFIG" && \
  114. AC_RUN_LOG([$PKG_CONFIG --exists --print-errors "$1"]); then
  115. m4_default([$2], [:])
  116. m4_ifvaln([$3], [else
  117. $3])dnl
  118. fi])
  119. # _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES])
  120. # ---------------------------------------------
  121. m4_define([_PKG_CONFIG],
  122. [if test -n "$$1"; then
  123. pkg_cv_[]$1="$$1"
  124. elif test -n "$PKG_CONFIG"; then
  125. PKG_CHECK_EXISTS([$3],
  126. [pkg_cv_[]$1=`$PKG_CONFIG --[]$2 "$3" 2>/dev/null`
  127. test "x$?" != "x0" && pkg_failed=yes ],
  128. [pkg_failed=yes])
  129. else
  130. pkg_failed=untried
  131. fi[]dnl
  132. ])# _PKG_CONFIG
  133. # _PKG_SHORT_ERRORS_SUPPORTED
  134. # -----------------------------
  135. AC_DEFUN([_PKG_SHORT_ERRORS_SUPPORTED],
  136. [AC_REQUIRE([PKG_PROG_PKG_CONFIG])
  137. if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
  138. _pkg_short_errors_supported=yes
  139. else
  140. _pkg_short_errors_supported=no
  141. fi[]dnl
  142. ])# _PKG_SHORT_ERRORS_SUPPORTED
  143. # PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND],
  144. # [ACTION-IF-NOT-FOUND])
  145. #
  146. #
  147. # Note that if there is a possibility the first call to
  148. # PKG_CHECK_MODULES might not happen, you should be sure to include an
  149. # explicit call to PKG_PROG_PKG_CONFIG in your configure.ac
  150. #
  151. #
  152. # --------------------------------------------------------------
  153. AC_DEFUN([PKG_CHECK_MODULES],
  154. [AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl
  155. AC_ARG_VAR([$1][_CFLAGS], [C compiler flags for $1, overriding pkg-config])dnl
  156. AC_ARG_VAR([$1][_LIBS], [linker flags for $1, overriding pkg-config])dnl
  157. pkg_failed=no
  158. AC_MSG_CHECKING([for $1])
  159. _PKG_CONFIG([$1][_CFLAGS], [cflags], [$2])
  160. _PKG_CONFIG([$1][_LIBS], [libs], [$2])
  161. m4_define([_PKG_TEXT], [Alternatively, you may set the environment variables $1[]_CFLAGS
  162. and $1[]_LIBS to avoid the need to call pkg-config.
  163. See the pkg-config man page for more details.])
  164. if test $pkg_failed = yes; then
  165. AC_MSG_RESULT([no])
  166. _PKG_SHORT_ERRORS_SUPPORTED
  167. if test $_pkg_short_errors_supported = yes; then
  168. $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "$2" 2>&1`
  169. else
  170. $1[]_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "$2" 2>&1`
  171. fi
  172. # Put the nasty error message in config.log where it belongs
  173. echo "$$1[]_PKG_ERRORS" >&AS_MESSAGE_LOG_FD
  174. m4_default([$4], [AC_MSG_ERROR(
  175. [Package requirements ($2) were not met:
  176. $$1_PKG_ERRORS
  177. Consider adjusting the PKG_CONFIG_PATH environment variable if you
  178. installed software in a non-standard prefix.
  179. _PKG_TEXT])[]dnl
  180. ])
  181. elif test $pkg_failed = untried; then
  182. AC_MSG_RESULT([no])
  183. m4_default([$4], [AC_MSG_FAILURE(
  184. [The pkg-config script could not be found or is too old. Make sure it
  185. is in your PATH or set the PKG_CONFIG environment variable to the full
  186. path to pkg-config.
  187. _PKG_TEXT
  188. To get pkg-config, see <http://pkg-config.freedesktop.org/>.])[]dnl
  189. ])
  190. else
  191. $1[]_CFLAGS=$pkg_cv_[]$1[]_CFLAGS
  192. $1[]_LIBS=$pkg_cv_[]$1[]_LIBS
  193. AC_MSG_RESULT([yes])
  194. $3
  195. fi[]dnl
  196. ])# PKG_CHECK_MODULES
  197. # Copyright (C) 2002-2013 Free Software Foundation, Inc.
  198. #
  199. # This file is free software; the Free Software Foundation
  200. # gives unlimited permission to copy and/or distribute it,
  201. # with or without modifications, as long as this notice is preserved.
  202. # AM_AUTOMAKE_VERSION(VERSION)
  203. # ----------------------------
  204. # Automake X.Y traces this macro to ensure aclocal.m4 has been
  205. # generated from the m4 files accompanying Automake X.Y.
  206. # (This private macro should not be called outside this file.)
  207. AC_DEFUN([AM_AUTOMAKE_VERSION],
  208. [am__api_version='1.14'
  209. dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to
  210. dnl require some minimum version. Point them to the right macro.
  211. m4_if([$1], [1.14.1], [],
  212. [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl
  213. ])
  214. # _AM_AUTOCONF_VERSION(VERSION)
  215. # -----------------------------
  216. # aclocal traces this macro to find the Autoconf version.
  217. # This is a private macro too. Using m4_define simplifies
  218. # the logic in aclocal, which can simply ignore this definition.
  219. m4_define([_AM_AUTOCONF_VERSION], [])
  220. # AM_SET_CURRENT_AUTOMAKE_VERSION
  221. # -------------------------------
  222. # Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced.
  223. # This function is AC_REQUIREd by AM_INIT_AUTOMAKE.
  224. AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
  225. [AM_AUTOMAKE_VERSION([1.14.1])dnl
  226. m4_ifndef([AC_AUTOCONF_VERSION],
  227. [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
  228. _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))])
  229. # AM_AUX_DIR_EXPAND -*- Autoconf -*-
  230. # Copyright (C) 2001-2013 Free Software Foundation, Inc.
  231. #
  232. # This file is free software; the Free Software Foundation
  233. # gives unlimited permission to copy and/or distribute it,
  234. # with or without modifications, as long as this notice is preserved.
  235. # For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets
  236. # $ac_aux_dir to '$srcdir/foo'. In other projects, it is set to
  237. # '$srcdir', '$srcdir/..', or '$srcdir/../..'.
  238. #
  239. # Of course, Automake must honor this variable whenever it calls a
  240. # tool from the auxiliary directory. The problem is that $srcdir (and
  241. # therefore $ac_aux_dir as well) can be either absolute or relative,
  242. # depending on how configure is run. This is pretty annoying, since
  243. # it makes $ac_aux_dir quite unusable in subdirectories: in the top
  244. # source directory, any form will work fine, but in subdirectories a
  245. # relative path needs to be adjusted first.
  246. #
  247. # $ac_aux_dir/missing
  248. # fails when called from a subdirectory if $ac_aux_dir is relative
  249. # $top_srcdir/$ac_aux_dir/missing
  250. # fails if $ac_aux_dir is absolute,
  251. # fails when called from a subdirectory in a VPATH build with
  252. # a relative $ac_aux_dir
  253. #
  254. # The reason of the latter failure is that $top_srcdir and $ac_aux_dir
  255. # are both prefixed by $srcdir. In an in-source build this is usually
  256. # harmless because $srcdir is '.', but things will broke when you
  257. # start a VPATH build or use an absolute $srcdir.
  258. #
  259. # So we could use something similar to $top_srcdir/$ac_aux_dir/missing,
  260. # iff we strip the leading $srcdir from $ac_aux_dir. That would be:
  261. # am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"`
  262. # and then we would define $MISSING as
  263. # MISSING="\${SHELL} $am_aux_dir/missing"
  264. # This will work as long as MISSING is not called from configure, because
  265. # unfortunately $(top_srcdir) has no meaning in configure.
  266. # However there are other variables, like CC, which are often used in
  267. # configure, and could therefore not use this "fixed" $ac_aux_dir.
  268. #
  269. # Another solution, used here, is to always expand $ac_aux_dir to an
  270. # absolute PATH. The drawback is that using absolute paths prevent a
  271. # configured tree to be moved without reconfiguration.
  272. AC_DEFUN([AM_AUX_DIR_EXPAND],
  273. [dnl Rely on autoconf to set up CDPATH properly.
  274. AC_PREREQ([2.50])dnl
  275. # expand $ac_aux_dir to an absolute path
  276. am_aux_dir=`cd $ac_aux_dir && pwd`
  277. ])
  278. # AM_CONDITIONAL -*- Autoconf -*-
  279. # Copyright (C) 1997-2013 Free Software Foundation, Inc.
  280. #
  281. # This file is free software; the Free Software Foundation
  282. # gives unlimited permission to copy and/or distribute it,
  283. # with or without modifications, as long as this notice is preserved.
  284. # AM_CONDITIONAL(NAME, SHELL-CONDITION)
  285. # -------------------------------------
  286. # Define a conditional.
  287. AC_DEFUN([AM_CONDITIONAL],
  288. [AC_PREREQ([2.52])dnl
  289. m4_if([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])],
  290. [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl
  291. AC_SUBST([$1_TRUE])dnl
  292. AC_SUBST([$1_FALSE])dnl
  293. _AM_SUBST_NOTMAKE([$1_TRUE])dnl
  294. _AM_SUBST_NOTMAKE([$1_FALSE])dnl
  295. m4_define([_AM_COND_VALUE_$1], [$2])dnl
  296. if $2; then
  297. $1_TRUE=
  298. $1_FALSE='#'
  299. else
  300. $1_TRUE='#'
  301. $1_FALSE=
  302. fi
  303. AC_CONFIG_COMMANDS_PRE(
  304. [if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then
  305. AC_MSG_ERROR([[conditional "$1" was never defined.
  306. Usually this means the macro was only invoked conditionally.]])
  307. fi])])
  308. # Copyright (C) 1999-2013 Free Software Foundation, Inc.
  309. #
  310. # This file is free software; the Free Software Foundation
  311. # gives unlimited permission to copy and/or distribute it,
  312. # with or without modifications, as long as this notice is preserved.
  313. # There are a few dirty hacks below to avoid letting 'AC_PROG_CC' be
  314. # written in clear, in which case automake, when reading aclocal.m4,
  315. # will think it sees a *use*, and therefore will trigger all it's
  316. # C support machinery. Also note that it means that autoscan, seeing
  317. # CC etc. in the Makefile, will ask for an AC_PROG_CC use...
  318. # _AM_DEPENDENCIES(NAME)
  319. # ----------------------
  320. # See how the compiler implements dependency checking.
  321. # NAME is "CC", "CXX", "OBJC", "OBJCXX", "UPC", or "GJC".
  322. # We try a few techniques and use that to set a single cache variable.
  323. #
  324. # We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was
  325. # modified to invoke _AM_DEPENDENCIES(CC); we would have a circular
  326. # dependency, and given that the user is not expected to run this macro,
  327. # just rely on AC_PROG_CC.
  328. AC_DEFUN([_AM_DEPENDENCIES],
  329. [AC_REQUIRE([AM_SET_DEPDIR])dnl
  330. AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl
  331. AC_REQUIRE([AM_MAKE_INCLUDE])dnl
  332. AC_REQUIRE([AM_DEP_TRACK])dnl
  333. m4_if([$1], [CC], [depcc="$CC" am_compiler_list=],
  334. [$1], [CXX], [depcc="$CXX" am_compiler_list=],
  335. [$1], [OBJC], [depcc="$OBJC" am_compiler_list='gcc3 gcc'],
  336. [$1], [OBJCXX], [depcc="$OBJCXX" am_compiler_list='gcc3 gcc'],
  337. [$1], [UPC], [depcc="$UPC" am_compiler_list=],
  338. [$1], [GCJ], [depcc="$GCJ" am_compiler_list='gcc3 gcc'],
  339. [depcc="$$1" am_compiler_list=])
  340. AC_CACHE_CHECK([dependency style of $depcc],
  341. [am_cv_$1_dependencies_compiler_type],
  342. [if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
  343. # We make a subdir and do the tests there. Otherwise we can end up
  344. # making bogus files that we don't know about and never remove. For
  345. # instance it was reported that on HP-UX the gcc test will end up
  346. # making a dummy file named 'D' -- because '-MD' means "put the output
  347. # in D".
  348. rm -rf conftest.dir
  349. mkdir conftest.dir
  350. # Copy depcomp to subdir because otherwise we won't find it if we're
  351. # using a relative directory.
  352. cp "$am_depcomp" conftest.dir
  353. cd conftest.dir
  354. # We will build objects and dependencies in a subdirectory because
  355. # it helps to detect inapplicable dependency modes. For instance
  356. # both Tru64's cc and ICC support -MD to output dependencies as a
  357. # side effect of compilation, but ICC will put the dependencies in
  358. # the current directory while Tru64 will put them in the object
  359. # directory.
  360. mkdir sub
  361. am_cv_$1_dependencies_compiler_type=none
  362. if test "$am_compiler_list" = ""; then
  363. am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp`
  364. fi
  365. am__universal=false
  366. m4_case([$1], [CC],
  367. [case " $depcc " in #(
  368. *\ -arch\ *\ -arch\ *) am__universal=true ;;
  369. esac],
  370. [CXX],
  371. [case " $depcc " in #(
  372. *\ -arch\ *\ -arch\ *) am__universal=true ;;
  373. esac])
  374. for depmode in $am_compiler_list; do
  375. # Setup a source with many dependencies, because some compilers
  376. # like to wrap large dependency lists on column 80 (with \), and
  377. # we should not choose a depcomp mode which is confused by this.
  378. #
  379. # We need to recreate these files for each test, as the compiler may
  380. # overwrite some of them when testing with obscure command lines.
  381. # This happens at least with the AIX C compiler.
  382. : > sub/conftest.c
  383. for i in 1 2 3 4 5 6; do
  384. echo '#include "conftst'$i'.h"' >> sub/conftest.c
  385. # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
  386. # Solaris 10 /bin/sh.
  387. echo '/* dummy */' > sub/conftst$i.h
  388. done
  389. echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
  390. # We check with '-c' and '-o' for the sake of the "dashmstdout"
  391. # mode. It turns out that the SunPro C++ compiler does not properly
  392. # handle '-M -o', and we need to detect this. Also, some Intel
  393. # versions had trouble with output in subdirs.
  394. am__obj=sub/conftest.${OBJEXT-o}
  395. am__minus_obj="-o $am__obj"
  396. case $depmode in
  397. gcc)
  398. # This depmode causes a compiler race in universal mode.
  399. test "$am__universal" = false || continue
  400. ;;
  401. nosideeffect)
  402. # After this tag, mechanisms are not by side-effect, so they'll
  403. # only be used when explicitly requested.
  404. if test "x$enable_dependency_tracking" = xyes; then
  405. continue
  406. else
  407. break
  408. fi
  409. ;;
  410. msvc7 | msvc7msys | msvisualcpp | msvcmsys)
  411. # This compiler won't grok '-c -o', but also, the minuso test has
  412. # not run yet. These depmodes are late enough in the game, and
  413. # so weak that their functioning should not be impacted.
  414. am__obj=conftest.${OBJEXT-o}
  415. am__minus_obj=
  416. ;;
  417. none) break ;;
  418. esac
  419. if depmode=$depmode \
  420. source=sub/conftest.c object=$am__obj \
  421. depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
  422. $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
  423. >/dev/null 2>conftest.err &&
  424. grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
  425. grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
  426. grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
  427. ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
  428. # icc doesn't choke on unknown options, it will just issue warnings
  429. # or remarks (even with -Werror). So we grep stderr for any message
  430. # that says an option was ignored or not supported.
  431. # When given -MP, icc 7.0 and 7.1 complain thusly:
  432. # icc: Command line warning: ignoring option '-M'; no argument required
  433. # The diagnosis changed in icc 8.0:
  434. # icc: Command line remark: option '-MP' not supported
  435. if (grep 'ignoring option' conftest.err ||
  436. grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
  437. am_cv_$1_dependencies_compiler_type=$depmode
  438. break
  439. fi
  440. fi
  441. done
  442. cd ..
  443. rm -rf conftest.dir
  444. else
  445. am_cv_$1_dependencies_compiler_type=none
  446. fi
  447. ])
  448. AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type])
  449. AM_CONDITIONAL([am__fastdep$1], [
  450. test "x$enable_dependency_tracking" != xno \
  451. && test "$am_cv_$1_dependencies_compiler_type" = gcc3])
  452. ])
  453. # AM_SET_DEPDIR
  454. # -------------
  455. # Choose a directory name for dependency files.
  456. # This macro is AC_REQUIREd in _AM_DEPENDENCIES.
  457. AC_DEFUN([AM_SET_DEPDIR],
  458. [AC_REQUIRE([AM_SET_LEADING_DOT])dnl
  459. AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl
  460. ])
  461. # AM_DEP_TRACK
  462. # ------------
  463. AC_DEFUN([AM_DEP_TRACK],
  464. [AC_ARG_ENABLE([dependency-tracking], [dnl
  465. AS_HELP_STRING(
  466. [--enable-dependency-tracking],
  467. [do not reject slow dependency extractors])
  468. AS_HELP_STRING(
  469. [--disable-dependency-tracking],
  470. [speeds up one-time build])])
  471. if test "x$enable_dependency_tracking" != xno; then
  472. am_depcomp="$ac_aux_dir/depcomp"
  473. AMDEPBACKSLASH='\'
  474. am__nodep='_no'
  475. fi
  476. AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno])
  477. AC_SUBST([AMDEPBACKSLASH])dnl
  478. _AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl
  479. AC_SUBST([am__nodep])dnl
  480. _AM_SUBST_NOTMAKE([am__nodep])dnl
  481. ])
  482. # Generate code to set up dependency tracking. -*- Autoconf -*-
  483. # Copyright (C) 1999-2013 Free Software Foundation, Inc.
  484. #
  485. # This file is free software; the Free Software Foundation
  486. # gives unlimited permission to copy and/or distribute it,
  487. # with or without modifications, as long as this notice is preserved.
  488. # _AM_OUTPUT_DEPENDENCY_COMMANDS
  489. # ------------------------------
  490. AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
  491. [{
  492. # Older Autoconf quotes --file arguments for eval, but not when files
  493. # are listed without --file. Let's play safe and only enable the eval
  494. # if we detect the quoting.
  495. case $CONFIG_FILES in
  496. *\'*) eval set x "$CONFIG_FILES" ;;
  497. *) set x $CONFIG_FILES ;;
  498. esac
  499. shift
  500. for mf
  501. do
  502. # Strip MF so we end up with the name of the file.
  503. mf=`echo "$mf" | sed -e 's/:.*$//'`
  504. # Check whether this is an Automake generated Makefile or not.
  505. # We used to match only the files named 'Makefile.in', but
  506. # some people rename them; so instead we look at the file content.
  507. # Grep'ing the first line is not enough: some people post-process
  508. # each Makefile.in and add a new line on top of each file to say so.
  509. # Grep'ing the whole file is not good either: AIX grep has a line
  510. # limit of 2048, but all sed's we know have understand at least 4000.
  511. if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
  512. dirpart=`AS_DIRNAME("$mf")`
  513. else
  514. continue
  515. fi
  516. # Extract the definition of DEPDIR, am__include, and am__quote
  517. # from the Makefile without running 'make'.
  518. DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
  519. test -z "$DEPDIR" && continue
  520. am__include=`sed -n 's/^am__include = //p' < "$mf"`
  521. test -z "$am__include" && continue
  522. am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
  523. # Find all dependency output files, they are included files with
  524. # $(DEPDIR) in their names. We invoke sed twice because it is the
  525. # simplest approach to changing $(DEPDIR) to its actual value in the
  526. # expansion.
  527. for file in `sed -n "
  528. s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
  529. sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do
  530. # Make sure the directory exists.
  531. test -f "$dirpart/$file" && continue
  532. fdir=`AS_DIRNAME(["$file"])`
  533. AS_MKDIR_P([$dirpart/$fdir])
  534. # echo "creating $dirpart/$file"
  535. echo '# dummy' > "$dirpart/$file"
  536. done
  537. done
  538. }
  539. ])# _AM_OUTPUT_DEPENDENCY_COMMANDS
  540. # AM_OUTPUT_DEPENDENCY_COMMANDS
  541. # -----------------------------
  542. # This macro should only be invoked once -- use via AC_REQUIRE.
  543. #
  544. # This code is only required when automatic dependency tracking
  545. # is enabled. FIXME. This creates each '.P' file that we will
  546. # need in order to bootstrap the dependency handling code.
  547. AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
  548. [AC_CONFIG_COMMANDS([depfiles],
  549. [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS],
  550. [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"])
  551. ])
  552. # Do all the work for Automake. -*- Autoconf -*-
  553. # Copyright (C) 1996-2013 Free Software Foundation, Inc.
  554. #
  555. # This file is free software; the Free Software Foundation
  556. # gives unlimited permission to copy and/or distribute it,
  557. # with or without modifications, as long as this notice is preserved.
  558. # This macro actually does too much. Some checks are only needed if
  559. # your package does certain things. But this isn't really a big deal.
  560. dnl Redefine AC_PROG_CC to automatically invoke _AM_PROG_CC_C_O.
  561. m4_define([AC_PROG_CC],
  562. m4_defn([AC_PROG_CC])
  563. [_AM_PROG_CC_C_O
  564. ])
  565. # AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE])
  566. # AM_INIT_AUTOMAKE([OPTIONS])
  567. # -----------------------------------------------
  568. # The call with PACKAGE and VERSION arguments is the old style
  569. # call (pre autoconf-2.50), which is being phased out. PACKAGE
  570. # and VERSION should now be passed to AC_INIT and removed from
  571. # the call to AM_INIT_AUTOMAKE.
  572. # We support both call styles for the transition. After
  573. # the next Automake release, Autoconf can make the AC_INIT
  574. # arguments mandatory, and then we can depend on a new Autoconf
  575. # release and drop the old call support.
  576. AC_DEFUN([AM_INIT_AUTOMAKE],
  577. [AC_PREREQ([2.65])dnl
  578. dnl Autoconf wants to disallow AM_ names. We explicitly allow
  579. dnl the ones we care about.
  580. m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
  581. AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl
  582. AC_REQUIRE([AC_PROG_INSTALL])dnl
  583. if test "`cd $srcdir && pwd`" != "`pwd`"; then
  584. # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
  585. # is not polluted with repeated "-I."
  586. AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl
  587. # test to see if srcdir already configured
  588. if test -f $srcdir/config.status; then
  589. AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
  590. fi
  591. fi
  592. # test whether we have cygpath
  593. if test -z "$CYGPATH_W"; then
  594. if (cygpath --version) >/dev/null 2>/dev/null; then
  595. CYGPATH_W='cygpath -w'
  596. else
  597. CYGPATH_W=echo
  598. fi
  599. fi
  600. AC_SUBST([CYGPATH_W])
  601. # Define the identity of the package.
  602. dnl Distinguish between old-style and new-style calls.
  603. m4_ifval([$2],
  604. [AC_DIAGNOSE([obsolete],
  605. [$0: two- and three-arguments forms are deprecated.])
  606. m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl
  607. AC_SUBST([PACKAGE], [$1])dnl
  608. AC_SUBST([VERSION], [$2])],
  609. [_AM_SET_OPTIONS([$1])dnl
  610. dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT.
  611. m4_if(
  612. m4_ifdef([AC_PACKAGE_NAME], [ok]):m4_ifdef([AC_PACKAGE_VERSION], [ok]),
  613. [ok:ok],,
  614. [m4_fatal([AC_INIT should be called with package and version arguments])])dnl
  615. AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl
  616. AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl
  617. _AM_IF_OPTION([no-define],,
  618. [AC_DEFINE_UNQUOTED([PACKAGE], ["$PACKAGE"], [Name of package])
  619. AC_DEFINE_UNQUOTED([VERSION], ["$VERSION"], [Version number of package])])dnl
  620. # Some tools Automake needs.
  621. AC_REQUIRE([AM_SANITY_CHECK])dnl
  622. AC_REQUIRE([AC_ARG_PROGRAM])dnl
  623. AM_MISSING_PROG([ACLOCAL], [aclocal-${am__api_version}])
  624. AM_MISSING_PROG([AUTOCONF], [autoconf])
  625. AM_MISSING_PROG([AUTOMAKE], [automake-${am__api_version}])
  626. AM_MISSING_PROG([AUTOHEADER], [autoheader])
  627. AM_MISSING_PROG([MAKEINFO], [makeinfo])
  628. AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
  629. AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl
  630. AC_REQUIRE([AC_PROG_MKDIR_P])dnl
  631. # For better backward compatibility. To be removed once Automake 1.9.x
  632. # dies out for good. For more background, see:
  633. # <http://lists.gnu.org/archive/html/automake/2012-07/msg00001.html>
  634. # <http://lists.gnu.org/archive/html/automake/2012-07/msg00014.html>
  635. AC_SUBST([mkdir_p], ['$(MKDIR_P)'])
  636. # We need awk for the "check" target. The system "awk" is bad on
  637. # some platforms.
  638. AC_REQUIRE([AC_PROG_AWK])dnl
  639. AC_REQUIRE([AC_PROG_MAKE_SET])dnl
  640. AC_REQUIRE([AM_SET_LEADING_DOT])dnl
  641. _AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])],
  642. [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])],
  643. [_AM_PROG_TAR([v7])])])
  644. _AM_IF_OPTION([no-dependencies],,
  645. [AC_PROVIDE_IFELSE([AC_PROG_CC],
  646. [_AM_DEPENDENCIES([CC])],
  647. [m4_define([AC_PROG_CC],
  648. m4_defn([AC_PROG_CC])[_AM_DEPENDENCIES([CC])])])dnl
  649. AC_PROVIDE_IFELSE([AC_PROG_CXX],
  650. [_AM_DEPENDENCIES([CXX])],
  651. [m4_define([AC_PROG_CXX],
  652. m4_defn([AC_PROG_CXX])[_AM_DEPENDENCIES([CXX])])])dnl
  653. AC_PROVIDE_IFELSE([AC_PROG_OBJC],
  654. [_AM_DEPENDENCIES([OBJC])],
  655. [m4_define([AC_PROG_OBJC],
  656. m4_defn([AC_PROG_OBJC])[_AM_DEPENDENCIES([OBJC])])])dnl
  657. AC_PROVIDE_IFELSE([AC_PROG_OBJCXX],
  658. [_AM_DEPENDENCIES([OBJCXX])],
  659. [m4_define([AC_PROG_OBJCXX],
  660. m4_defn([AC_PROG_OBJCXX])[_AM_DEPENDENCIES([OBJCXX])])])dnl
  661. ])
  662. AC_REQUIRE([AM_SILENT_RULES])dnl
  663. dnl The testsuite driver may need to know about EXEEXT, so add the
  664. dnl 'am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This
  665. dnl macro is hooked onto _AC_COMPILER_EXEEXT early, see below.
  666. AC_CONFIG_COMMANDS_PRE(dnl
  667. [m4_provide_if([_AM_COMPILER_EXEEXT],
  668. [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl
  669. # POSIX will say in a future version that running "rm -f" with no argument
  670. # is OK; and we want to be able to make that assumption in our Makefile
  671. # recipes. So use an aggressive probe to check that the usage we want is
  672. # actually supported "in the wild" to an acceptable degree.
  673. # See automake bug#10828.
  674. # To make any issue more visible, cause the running configure to be aborted
  675. # by default if the 'rm' program in use doesn't match our expectations; the
  676. # user can still override this though.
  677. if rm -f && rm -fr && rm -rf; then : OK; else
  678. cat >&2 <<'END'
  679. Oops!
  680. Your 'rm' program seems unable to run without file operands specified
  681. on the command line, even when the '-f' option is present. This is contrary
  682. to the behaviour of most rm programs out there, and not conforming with
  683. the upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542>
  684. Please tell [email protected] about your system, including the value
  685. of your $PATH and any error possibly output before this message. This
  686. can help us improve future automake versions.
  687. END
  688. if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then
  689. echo 'Configuration will proceed anyway, since you have set the' >&2
  690. echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2
  691. echo >&2
  692. else
  693. cat >&2 <<'END'
  694. Aborting the configuration process, to ensure you take notice of the issue.
  695. You can download and install GNU coreutils to get an 'rm' implementation
  696. that behaves properly: <http://www.gnu.org/software/coreutils/>.
  697. If you want to complete the configuration process using your problematic
  698. 'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM
  699. to "yes", and re-run configure.
  700. END
  701. AC_MSG_ERROR([Your 'rm' program is bad, sorry.])
  702. fi
  703. fi])
  704. dnl Hook into '_AC_COMPILER_EXEEXT' early to learn its expansion. Do not
  705. dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further
  706. dnl mangled by Autoconf and run in a shell conditional statement.
  707. m4_define([_AC_COMPILER_EXEEXT],
  708. m4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])])
  709. # When config.status generates a header, we must update the stamp-h file.
  710. # This file resides in the same directory as the config header
  711. # that is generated. The stamp files are numbered to have different names.
  712. # Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the
  713. # loop where config.status creates the headers, so we can generate
  714. # our stamp files there.
  715. AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK],
  716. [# Compute $1's index in $config_headers.
  717. _am_arg=$1
  718. _am_stamp_count=1
  719. for _am_header in $config_headers :; do
  720. case $_am_header in
  721. $_am_arg | $_am_arg:* )
  722. break ;;
  723. * )
  724. _am_stamp_count=`expr $_am_stamp_count + 1` ;;
  725. esac
  726. done
  727. echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count])
  728. # Copyright (C) 2001-2013 Free Software Foundation, Inc.
  729. #
  730. # This file is free software; the Free Software Foundation
  731. # gives unlimited permission to copy and/or distribute it,
  732. # with or without modifications, as long as this notice is preserved.
  733. # AM_PROG_INSTALL_SH
  734. # ------------------
  735. # Define $install_sh.
  736. AC_DEFUN([AM_PROG_INSTALL_SH],
  737. [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
  738. if test x"${install_sh}" != xset; then
  739. case $am_aux_dir in
  740. *\ * | *\ *)
  741. install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
  742. *)
  743. install_sh="\${SHELL} $am_aux_dir/install-sh"
  744. esac
  745. fi
  746. AC_SUBST([install_sh])])
  747. # Copyright (C) 2003-2013 Free Software Foundation, Inc.
  748. #
  749. # This file is free software; the Free Software Foundation
  750. # gives unlimited permission to copy and/or distribute it,
  751. # with or without modifications, as long as this notice is preserved.
  752. # Check whether the underlying file-system supports filenames
  753. # with a leading dot. For instance MS-DOS doesn't.
  754. AC_DEFUN([AM_SET_LEADING_DOT],
  755. [rm -rf .tst 2>/dev/null
  756. mkdir .tst 2>/dev/null
  757. if test -d .tst; then
  758. am__leading_dot=.
  759. else
  760. am__leading_dot=_
  761. fi
  762. rmdir .tst 2>/dev/null
  763. AC_SUBST([am__leading_dot])])
  764. # Check to see how 'make' treats includes. -*- Autoconf -*-
  765. # Copyright (C) 2001-2013 Free Software Foundation, Inc.
  766. #
  767. # This file is free software; the Free Software Foundation
  768. # gives unlimited permission to copy and/or distribute it,
  769. # with or without modifications, as long as this notice is preserved.
  770. # AM_MAKE_INCLUDE()
  771. # -----------------
  772. # Check to see how make treats includes.
  773. AC_DEFUN([AM_MAKE_INCLUDE],
  774. [am_make=${MAKE-make}
  775. cat > confinc << 'END'
  776. am__doit:
  777. @echo this is the am__doit target
  778. .PHONY: am__doit
  779. END
  780. # If we don't find an include directive, just comment out the code.
  781. AC_MSG_CHECKING([for style of include used by $am_make])
  782. am__include="#"
  783. am__quote=
  784. _am_result=none
  785. # First try GNU make style include.
  786. echo "include confinc" > confmf
  787. # Ignore all kinds of additional output from 'make'.
  788. case `$am_make -s -f confmf 2> /dev/null` in #(
  789. *the\ am__doit\ target*)
  790. am__include=include
  791. am__quote=
  792. _am_result=GNU
  793. ;;
  794. esac
  795. # Now try BSD make style include.
  796. if test "$am__include" = "#"; then
  797. echo '.include "confinc"' > confmf
  798. case `$am_make -s -f confmf 2> /dev/null` in #(
  799. *the\ am__doit\ target*)
  800. am__include=.include
  801. am__quote="\""
  802. _am_result=BSD
  803. ;;
  804. esac
  805. fi
  806. AC_SUBST([am__include])
  807. AC_SUBST([am__quote])
  808. AC_MSG_RESULT([$_am_result])
  809. rm -f confinc confmf
  810. ])
  811. # Fake the existence of programs that GNU maintainers use. -*- Autoconf -*-
  812. # Copyright (C) 1997-2013 Free Software Foundation, Inc.
  813. #
  814. # This file is free software; the Free Software Foundation
  815. # gives unlimited permission to copy and/or distribute it,
  816. # with or without modifications, as long as this notice is preserved.
  817. # AM_MISSING_PROG(NAME, PROGRAM)
  818. # ------------------------------
  819. AC_DEFUN([AM_MISSING_PROG],
  820. [AC_REQUIRE([AM_MISSING_HAS_RUN])
  821. $1=${$1-"${am_missing_run}$2"}
  822. AC_SUBST($1)])
  823. # AM_MISSING_HAS_RUN
  824. # ------------------
  825. # Define MISSING if not defined so far and test if it is modern enough.
  826. # If it is, set am_missing_run to use it, otherwise, to nothing.
  827. AC_DEFUN([AM_MISSING_HAS_RUN],
  828. [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
  829. AC_REQUIRE_AUX_FILE([missing])dnl
  830. if test x"${MISSING+set}" != xset; then
  831. case $am_aux_dir in
  832. *\ * | *\ *)
  833. MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
  834. *)
  835. MISSING="\${SHELL} $am_aux_dir/missing" ;;
  836. esac
  837. fi
  838. # Use eval to expand $SHELL
  839. if eval "$MISSING --is-lightweight"; then
  840. am_missing_run="$MISSING "
  841. else
  842. am_missing_run=
  843. AC_MSG_WARN(['missing' script is too old or missing])
  844. fi
  845. ])
  846. # -*- Autoconf -*-
  847. # Obsolete and "removed" macros, that must however still report explicit
  848. # error messages when used, to smooth transition.
  849. #
  850. # Copyright (C) 1996-2013 Free Software Foundation, Inc.
  851. #
  852. # This file is free software; the Free Software Foundation
  853. # gives unlimited permission to copy and/or distribute it,
  854. # with or without modifications, as long as this notice is preserved.
  855. AC_DEFUN([AM_CONFIG_HEADER],
  856. [AC_DIAGNOSE([obsolete],
  857. ['$0': this macro is obsolete.
  858. You should use the 'AC][_CONFIG_HEADERS' macro instead.])dnl
  859. AC_CONFIG_HEADERS($@)])
  860. AC_DEFUN([AM_PROG_CC_STDC],
  861. [AC_PROG_CC
  862. am_cv_prog_cc_stdc=$ac_cv_prog_cc_stdc
  863. AC_DIAGNOSE([obsolete],
  864. ['$0': this macro is obsolete.
  865. You should simply use the 'AC][_PROG_CC' macro instead.
  866. Also, your code should no longer depend upon 'am_cv_prog_cc_stdc',
  867. but upon 'ac_cv_prog_cc_stdc'.])])
  868. AC_DEFUN([AM_C_PROTOTYPES],
  869. [AC_FATAL([automatic de-ANSI-fication support has been removed])])
  870. AU_DEFUN([fp_C_PROTOTYPES], [AM_C_PROTOTYPES])
  871. # Helper functions for option handling. -*- Autoconf -*-
  872. # Copyright (C) 2001-2013 Free Software Foundation, Inc.
  873. #
  874. # This file is free software; the Free Software Foundation
  875. # gives unlimited permission to copy and/or distribute it,
  876. # with or without modifications, as long as this notice is preserved.
  877. # _AM_MANGLE_OPTION(NAME)
  878. # -----------------------
  879. AC_DEFUN([_AM_MANGLE_OPTION],
  880. [[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])])
  881. # _AM_SET_OPTION(NAME)
  882. # --------------------
  883. # Set option NAME. Presently that only means defining a flag for this option.
  884. AC_DEFUN([_AM_SET_OPTION],
  885. [m4_define(_AM_MANGLE_OPTION([$1]), [1])])
  886. # _AM_SET_OPTIONS(OPTIONS)
  887. # ------------------------
  888. # OPTIONS is a space-separated list of Automake options.
  889. AC_DEFUN([_AM_SET_OPTIONS],
  890. [m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])])
  891. # _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET])
  892. # -------------------------------------------
  893. # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
  894. AC_DEFUN([_AM_IF_OPTION],
  895. [m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
  896. # Copyright (C) 1999-2013 Free Software Foundation, Inc.
  897. #
  898. # This file is free software; the Free Software Foundation
  899. # gives unlimited permission to copy and/or distribute it,
  900. # with or without modifications, as long as this notice is preserved.
  901. # _AM_PROG_CC_C_O
  902. # ---------------
  903. # Like AC_PROG_CC_C_O, but changed for automake. We rewrite AC_PROG_CC
  904. # to automatically call this.
  905. AC_DEFUN([_AM_PROG_CC_C_O],
  906. [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
  907. AC_REQUIRE_AUX_FILE([compile])dnl
  908. AC_LANG_PUSH([C])dnl
  909. AC_CACHE_CHECK(
  910. [whether $CC understands -c and -o together],
  911. [am_cv_prog_cc_c_o],
  912. [AC_LANG_CONFTEST([AC_LANG_PROGRAM([])])
  913. # Make sure it works both with $CC and with simple cc.
  914. # Following AC_PROG_CC_C_O, we do the test twice because some
  915. # compilers refuse to overwrite an existing .o file with -o,
  916. # though they will create one.
  917. am_cv_prog_cc_c_o=yes
  918. for am_i in 1 2; do
  919. if AM_RUN_LOG([$CC -c conftest.$ac_ext -o conftest2.$ac_objext]) \
  920. && test -f conftest2.$ac_objext; then
  921. : OK
  922. else
  923. am_cv_prog_cc_c_o=no
  924. break
  925. fi
  926. done
  927. rm -f core conftest*
  928. unset am_i])
  929. if test "$am_cv_prog_cc_c_o" != yes; then
  930. # Losing compiler, so override with the script.
  931. # FIXME: It is wrong to rewrite CC.
  932. # But if we don't then we get into trouble of one sort or another.
  933. # A longer-term fix would be to have automake use am__CC in this case,
  934. # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
  935. CC="$am_aux_dir/compile $CC"
  936. fi
  937. AC_LANG_POP([C])])
  938. # For backward compatibility.
  939. AC_DEFUN_ONCE([AM_PROG_CC_C_O], [AC_REQUIRE([AC_PROG_CC])])
  940. # Copyright (C) 2001-2013 Free Software Foundation, Inc.
  941. #
  942. # This file is free software; the Free Software Foundation
  943. # gives unlimited permission to copy and/or distribute it,
  944. # with or without modifications, as long as this notice is preserved.
  945. # AM_RUN_LOG(COMMAND)
  946. # -------------------
  947. # Run COMMAND, save the exit status in ac_status, and log it.
  948. # (This has been adapted from Autoconf's _AC_RUN_LOG macro.)
  949. AC_DEFUN([AM_RUN_LOG],
  950. [{ echo "$as_me:$LINENO: $1" >&AS_MESSAGE_LOG_FD
  951. ($1) >&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD
  952. ac_status=$?
  953. echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
  954. (exit $ac_status); }])
  955. # Check to make sure that the build environment is sane. -*- Autoconf -*-
  956. # Copyright (C) 1996-2013 Free Software Foundation, Inc.
  957. #
  958. # This file is free software; the Free Software Foundation
  959. # gives unlimited permission to copy and/or distribute it,
  960. # with or without modifications, as long as this notice is preserved.
  961. # AM_SANITY_CHECK
  962. # ---------------
  963. AC_DEFUN([AM_SANITY_CHECK],
  964. [AC_MSG_CHECKING([whether build environment is sane])
  965. # Reject unsafe characters in $srcdir or the absolute working directory
  966. # name. Accept space and tab only in the latter.
  967. am_lf='
  968. '
  969. case `pwd` in
  970. *[[\\\"\#\$\&\'\`$am_lf]]*)
  971. AC_MSG_ERROR([unsafe absolute working directory name]);;
  972. esac
  973. case $srcdir in
  974. *[[\\\"\#\$\&\'\`$am_lf\ \ ]]*)
  975. AC_MSG_ERROR([unsafe srcdir value: '$srcdir']);;
  976. esac
  977. # Do 'set' in a subshell so we don't clobber the current shell's
  978. # arguments. Must try -L first in case configure is actually a
  979. # symlink; some systems play weird games with the mod time of symlinks
  980. # (eg FreeBSD returns the mod time of the symlink's containing
  981. # directory).
  982. if (
  983. am_has_slept=no
  984. for am_try in 1 2; do
  985. echo "timestamp, slept: $am_has_slept" > conftest.file
  986. set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
  987. if test "$[*]" = "X"; then
  988. # -L didn't work.
  989. set X `ls -t "$srcdir/configure" conftest.file`
  990. fi
  991. if test "$[*]" != "X $srcdir/configure conftest.file" \
  992. && test "$[*]" != "X conftest.file $srcdir/configure"; then
  993. # If neither matched, then we have a broken ls. This can happen
  994. # if, for instance, CONFIG_SHELL is bash and it inherits a
  995. # broken ls alias from the environment. This has actually
  996. # happened. Such a system could not be considered "sane".
  997. AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken
  998. alias in your environment])
  999. fi
  1000. if test "$[2]" = conftest.file || test $am_try -eq 2; then
  1001. break
  1002. fi
  1003. # Just in case.
  1004. sleep 1
  1005. am_has_slept=yes
  1006. done
  1007. test "$[2]" = conftest.file
  1008. )
  1009. then
  1010. # Ok.
  1011. :
  1012. else
  1013. AC_MSG_ERROR([newly created file is older than distributed files!
  1014. Check your system clock])
  1015. fi
  1016. AC_MSG_RESULT([yes])
  1017. # If we didn't sleep, we still need to ensure time stamps of config.status and
  1018. # generated files are strictly newer.
  1019. am_sleep_pid=
  1020. if grep 'slept: no' conftest.file >/dev/null 2>&1; then
  1021. ( sleep 1 ) &
  1022. am_sleep_pid=$!
  1023. fi
  1024. AC_CONFIG_COMMANDS_PRE(
  1025. [AC_MSG_CHECKING([that generated files are newer than configure])
  1026. if test -n "$am_sleep_pid"; then
  1027. # Hide warnings about reused PIDs.
  1028. wait $am_sleep_pid 2>/dev/null
  1029. fi
  1030. AC_MSG_RESULT([done])])
  1031. rm -f conftest.file
  1032. ])
  1033. # Copyright (C) 2009-2013 Free Software Foundation, Inc.
  1034. #
  1035. # This file is free software; the Free Software Foundation
  1036. # gives unlimited permission to copy and/or distribute it,
  1037. # with or without modifications, as long as this notice is preserved.
  1038. # AM_SILENT_RULES([DEFAULT])
  1039. # --------------------------
  1040. # Enable less verbose build rules; with the default set to DEFAULT
  1041. # ("yes" being less verbose, "no" or empty being verbose).
  1042. AC_DEFUN([AM_SILENT_RULES],
  1043. [AC_ARG_ENABLE([silent-rules], [dnl
  1044. AS_HELP_STRING(
  1045. [--enable-silent-rules],
  1046. [less verbose build output (undo: "make V=1")])
  1047. AS_HELP_STRING(
  1048. [--disable-silent-rules],
  1049. [verbose build output (undo: "make V=0")])dnl
  1050. ])
  1051. case $enable_silent_rules in @%:@ (((
  1052. yes) AM_DEFAULT_VERBOSITY=0;;
  1053. no) AM_DEFAULT_VERBOSITY=1;;
  1054. *) AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);;
  1055. esac
  1056. dnl
  1057. dnl A few 'make' implementations (e.g., NonStop OS and NextStep)
  1058. dnl do not support nested variable expansions.
  1059. dnl See automake bug#9928 and bug#10237.
  1060. am_make=${MAKE-make}
  1061. AC_CACHE_CHECK([whether $am_make supports nested variables],
  1062. [am_cv_make_support_nested_variables],
  1063. [if AS_ECHO([['TRUE=$(BAR$(V))
  1064. BAR0=false
  1065. BAR1=true
  1066. V=1
  1067. am__doit:
  1068. @$(TRUE)
  1069. .PHONY: am__doit']]) | $am_make -f - >/dev/null 2>&1; then
  1070. am_cv_make_support_nested_variables=yes
  1071. else
  1072. am_cv_make_support_nested_variables=no
  1073. fi])
  1074. if test $am_cv_make_support_nested_variables = yes; then
  1075. dnl Using '$V' instead of '$(V)' breaks IRIX make.
  1076. AM_V='$(V)'
  1077. AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
  1078. else
  1079. AM_V=$AM_DEFAULT_VERBOSITY
  1080. AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
  1081. fi
  1082. AC_SUBST([AM_V])dnl
  1083. AM_SUBST_NOTMAKE([AM_V])dnl
  1084. AC_SUBST([AM_DEFAULT_V])dnl
  1085. AM_SUBST_NOTMAKE([AM_DEFAULT_V])dnl
  1086. AC_SUBST([AM_DEFAULT_VERBOSITY])dnl
  1087. AM_BACKSLASH='\'
  1088. AC_SUBST([AM_BACKSLASH])dnl
  1089. _AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl
  1090. ])
  1091. # Copyright (C) 2001-2013 Free Software Foundation, Inc.
  1092. #
  1093. # This file is free software; the Free Software Foundation
  1094. # gives unlimited permission to copy and/or distribute it,
  1095. # with or without modifications, as long as this notice is preserved.
  1096. # AM_PROG_INSTALL_STRIP
  1097. # ---------------------
  1098. # One issue with vendor 'install' (even GNU) is that you can't
  1099. # specify the program used to strip binaries. This is especially
  1100. # annoying in cross-compiling environments, where the build's strip
  1101. # is unlikely to handle the host's binaries.
  1102. # Fortunately install-sh will honor a STRIPPROG variable, so we
  1103. # always use install-sh in "make install-strip", and initialize
  1104. # STRIPPROG with the value of the STRIP variable (set by the user).
  1105. AC_DEFUN([AM_PROG_INSTALL_STRIP],
  1106. [AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
  1107. # Installed binaries are usually stripped using 'strip' when the user
  1108. # run "make install-strip". However 'strip' might not be the right
  1109. # tool to use in cross-compilation environments, therefore Automake
  1110. # will honor the 'STRIP' environment variable to overrule this program.
  1111. dnl Don't test for $cross_compiling = yes, because it might be 'maybe'.
  1112. if test "$cross_compiling" != no; then
  1113. AC_CHECK_TOOL([STRIP], [strip], :)
  1114. fi
  1115. INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
  1116. AC_SUBST([INSTALL_STRIP_PROGRAM])])
  1117. # Copyright (C) 2006-2013 Free Software Foundation, Inc.
  1118. #
  1119. # This file is free software; the Free Software Foundation
  1120. # gives unlimited permission to copy and/or distribute it,
  1121. # with or without modifications, as long as this notice is preserved.
  1122. # _AM_SUBST_NOTMAKE(VARIABLE)
  1123. # ---------------------------
  1124. # Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in.
  1125. # This macro is traced by Automake.
  1126. AC_DEFUN([_AM_SUBST_NOTMAKE])
  1127. # AM_SUBST_NOTMAKE(VARIABLE)
  1128. # --------------------------
  1129. # Public sister of _AM_SUBST_NOTMAKE.
  1130. AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)])
  1131. # Check how to create a tarball. -*- Autoconf -*-
  1132. # Copyright (C) 2004-2013 Free Software Foundation, Inc.
  1133. #
  1134. # This file is free software; the Free Software Foundation
  1135. # gives unlimited permission to copy and/or distribute it,
  1136. # with or without modifications, as long as this notice is preserved.
  1137. # _AM_PROG_TAR(FORMAT)
  1138. # --------------------
  1139. # Check how to create a tarball in format FORMAT.
  1140. # FORMAT should be one of 'v7', 'ustar', or 'pax'.
  1141. #
  1142. # Substitute a variable $(am__tar) that is a command
  1143. # writing to stdout a FORMAT-tarball containing the directory
  1144. # $tardir.
  1145. # tardir=directory && $(am__tar) > result.tar
  1146. #
  1147. # Substitute a variable $(am__untar) that extract such
  1148. # a tarball read from stdin.
  1149. # $(am__untar) < result.tar
  1150. #
  1151. AC_DEFUN([_AM_PROG_TAR],
  1152. [# Always define AMTAR for backward compatibility. Yes, it's still used
  1153. # in the wild :-( We should find a proper way to deprecate it ...
  1154. AC_SUBST([AMTAR], ['$${TAR-tar}'])
  1155. # We'll loop over all known methods to create a tar archive until one works.
  1156. _am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none'
  1157. m4_if([$1], [v7],
  1158. [am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'],
  1159. [m4_case([$1],
  1160. [ustar],
  1161. [# The POSIX 1988 'ustar' format is defined with fixed-size fields.
  1162. # There is notably a 21 bits limit for the UID and the GID. In fact,
  1163. # the 'pax' utility can hang on bigger UID/GID (see automake bug#8343
  1164. # and bug#13588).
  1165. am_max_uid=2097151 # 2^21 - 1
  1166. am_max_gid=$am_max_uid
  1167. # The $UID and $GID variables are not portable, so we need to resort
  1168. # to the POSIX-mandated id(1) utility. Errors in the 'id' calls
  1169. # below are definitely unexpected, so allow the users to see them
  1170. # (that is, avoid stderr redirection).
  1171. am_uid=`id -u || echo unknown`
  1172. am_gid=`id -g || echo unknown`
  1173. AC_MSG_CHECKING([whether UID '$am_uid' is supported by ustar format])
  1174. if test $am_uid -le $am_max_uid; then
  1175. AC_MSG_RESULT([yes])
  1176. else
  1177. AC_MSG_RESULT([no])
  1178. _am_tools=none
  1179. fi
  1180. AC_MSG_CHECKING([whether GID '$am_gid' is supported by ustar format])
  1181. if test $am_gid -le $am_max_gid; then
  1182. AC_MSG_RESULT([yes])
  1183. else
  1184. AC_MSG_RESULT([no])
  1185. _am_tools=none
  1186. fi],
  1187. [pax],
  1188. [],
  1189. [m4_fatal([Unknown tar format])])
  1190. AC_MSG_CHECKING([how to create a $1 tar archive])
  1191. # Go ahead even if we have the value already cached. We do so because we
  1192. # need to set the values for the 'am__tar' and 'am__untar' variables.
  1193. _am_tools=${am_cv_prog_tar_$1-$_am_tools}
  1194. for _am_tool in $_am_tools; do
  1195. case $_am_tool in
  1196. gnutar)
  1197. for _am_tar in tar gnutar gtar; do
  1198. AM_RUN_LOG([$_am_tar --version]) && break
  1199. done
  1200. am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"'
  1201. am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"'
  1202. am__untar="$_am_tar -xf -"
  1203. ;;
  1204. plaintar)
  1205. # Must skip GNU tar: if it does not support --format= it doesn't create
  1206. # ustar tarball either.
  1207. (tar --version) >/dev/null 2>&1 && continue
  1208. am__tar='tar chf - "$$tardir"'
  1209. am__tar_='tar chf - "$tardir"'
  1210. am__untar='tar xf -'
  1211. ;;
  1212. pax)
  1213. am__tar='pax -L -x $1 -w "$$tardir"'
  1214. am__tar_='pax -L -x $1 -w "$tardir"'
  1215. am__untar='pax -r'
  1216. ;;
  1217. cpio)
  1218. am__tar='find "$$tardir" -print | cpio -o -H $1 -L'
  1219. am__tar_='find "$tardir" -print | cpio -o -H $1 -L'
  1220. am__untar='cpio -i -H $1 -d'
  1221. ;;
  1222. none)
  1223. am__tar=false
  1224. am__tar_=false
  1225. am__untar=false
  1226. ;;
  1227. esac
  1228. # If the value was cached, stop now. We just wanted to have am__tar
  1229. # and am__untar set.
  1230. test -n "${am_cv_prog_tar_$1}" && break
  1231. # tar/untar a dummy directory, and stop if the command works.
  1232. rm -rf conftest.dir
  1233. mkdir conftest.dir
  1234. echo GrepMe > conftest.dir/file
  1235. AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar])
  1236. rm -rf conftest.dir
  1237. if test -s conftest.tar; then
  1238. AM_RUN_LOG([$am__untar <conftest.tar])
  1239. AM_RUN_LOG([cat conftest.dir/file])
  1240. grep GrepMe conftest.dir/file >/dev/null 2>&1 && break
  1241. fi
  1242. done
  1243. rm -rf conftest.dir
  1244. AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool])
  1245. AC_MSG_RESULT([$am_cv_prog_tar_$1])])
  1246. AC_SUBST([am__tar])
  1247. AC_SUBST([am__untar])
  1248. ]) # _AM_PROG_TAR