aclocal.m4 39 KB

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