aclocal.m4 44 KB

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