github的一些开源项目
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.

1561 lines
56 KiB

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