Tests About Natural Selection In Virtual Environment
c
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

aclocal.m4 40KB

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