aclocal.m4 66 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812
  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.71],,
  14. [m4_warning([this file was generated for autoconf 2.71.
  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 utilise 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 occurence 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. # Copyright (C) 2002-2021 Free Software Foundation, Inc.
  265. #
  266. # This file is free software; the Free Software Foundation
  267. # gives unlimited permission to copy and/or distribute it,
  268. # with or without modifications, as long as this notice is preserved.
  269. # AM_AUTOMAKE_VERSION(VERSION)
  270. # ----------------------------
  271. # Automake X.Y traces this macro to ensure aclocal.m4 has been
  272. # generated from the m4 files accompanying Automake X.Y.
  273. # (This private macro should not be called outside this file.)
  274. AC_DEFUN([AM_AUTOMAKE_VERSION],
  275. [am__api_version='1.16'
  276. dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to
  277. dnl require some minimum version. Point them to the right macro.
  278. m4_if([$1], [1.16.5], [],
  279. [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl
  280. ])
  281. # _AM_AUTOCONF_VERSION(VERSION)
  282. # -----------------------------
  283. # aclocal traces this macro to find the Autoconf version.
  284. # This is a private macro too. Using m4_define simplifies
  285. # the logic in aclocal, which can simply ignore this definition.
  286. m4_define([_AM_AUTOCONF_VERSION], [])
  287. # AM_SET_CURRENT_AUTOMAKE_VERSION
  288. # -------------------------------
  289. # Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced.
  290. # This function is AC_REQUIREd by AM_INIT_AUTOMAKE.
  291. AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
  292. [AM_AUTOMAKE_VERSION([1.16.5])dnl
  293. m4_ifndef([AC_AUTOCONF_VERSION],
  294. [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
  295. _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))])
  296. # AM_AUX_DIR_EXPAND -*- Autoconf -*-
  297. # Copyright (C) 2001-2021 Free Software Foundation, Inc.
  298. #
  299. # This file is free software; the Free Software Foundation
  300. # gives unlimited permission to copy and/or distribute it,
  301. # with or without modifications, as long as this notice is preserved.
  302. # For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets
  303. # $ac_aux_dir to '$srcdir/foo'. In other projects, it is set to
  304. # '$srcdir', '$srcdir/..', or '$srcdir/../..'.
  305. #
  306. # Of course, Automake must honor this variable whenever it calls a
  307. # tool from the auxiliary directory. The problem is that $srcdir (and
  308. # therefore $ac_aux_dir as well) can be either absolute or relative,
  309. # depending on how configure is run. This is pretty annoying, since
  310. # it makes $ac_aux_dir quite unusable in subdirectories: in the top
  311. # source directory, any form will work fine, but in subdirectories a
  312. # relative path needs to be adjusted first.
  313. #
  314. # $ac_aux_dir/missing
  315. # fails when called from a subdirectory if $ac_aux_dir is relative
  316. # $top_srcdir/$ac_aux_dir/missing
  317. # fails if $ac_aux_dir is absolute,
  318. # fails when called from a subdirectory in a VPATH build with
  319. # a relative $ac_aux_dir
  320. #
  321. # The reason of the latter failure is that $top_srcdir and $ac_aux_dir
  322. # are both prefixed by $srcdir. In an in-source build this is usually
  323. # harmless because $srcdir is '.', but things will broke when you
  324. # start a VPATH build or use an absolute $srcdir.
  325. #
  326. # So we could use something similar to $top_srcdir/$ac_aux_dir/missing,
  327. # iff we strip the leading $srcdir from $ac_aux_dir. That would be:
  328. # am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"`
  329. # and then we would define $MISSING as
  330. # MISSING="\${SHELL} $am_aux_dir/missing"
  331. # This will work as long as MISSING is not called from configure, because
  332. # unfortunately $(top_srcdir) has no meaning in configure.
  333. # However there are other variables, like CC, which are often used in
  334. # configure, and could therefore not use this "fixed" $ac_aux_dir.
  335. #
  336. # Another solution, used here, is to always expand $ac_aux_dir to an
  337. # absolute PATH. The drawback is that using absolute paths prevent a
  338. # configured tree to be moved without reconfiguration.
  339. AC_DEFUN([AM_AUX_DIR_EXPAND],
  340. [AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl
  341. # Expand $ac_aux_dir to an absolute path.
  342. am_aux_dir=`cd "$ac_aux_dir" && pwd`
  343. ])
  344. # AM_CONDITIONAL -*- Autoconf -*-
  345. # Copyright (C) 1997-2021 Free Software Foundation, Inc.
  346. #
  347. # This file is free software; the Free Software Foundation
  348. # gives unlimited permission to copy and/or distribute it,
  349. # with or without modifications, as long as this notice is preserved.
  350. # AM_CONDITIONAL(NAME, SHELL-CONDITION)
  351. # -------------------------------------
  352. # Define a conditional.
  353. AC_DEFUN([AM_CONDITIONAL],
  354. [AC_PREREQ([2.52])dnl
  355. m4_if([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])],
  356. [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl
  357. AC_SUBST([$1_TRUE])dnl
  358. AC_SUBST([$1_FALSE])dnl
  359. _AM_SUBST_NOTMAKE([$1_TRUE])dnl
  360. _AM_SUBST_NOTMAKE([$1_FALSE])dnl
  361. m4_define([_AM_COND_VALUE_$1], [$2])dnl
  362. if $2; then
  363. $1_TRUE=
  364. $1_FALSE='#'
  365. else
  366. $1_TRUE='#'
  367. $1_FALSE=
  368. fi
  369. AC_CONFIG_COMMANDS_PRE(
  370. [if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then
  371. AC_MSG_ERROR([[conditional "$1" was never defined.
  372. Usually this means the macro was only invoked conditionally.]])
  373. fi])])
  374. # Copyright (C) 1999-2021 Free Software Foundation, Inc.
  375. #
  376. # This file is free software; the Free Software Foundation
  377. # gives unlimited permission to copy and/or distribute it,
  378. # with or without modifications, as long as this notice is preserved.
  379. # There are a few dirty hacks below to avoid letting 'AC_PROG_CC' be
  380. # written in clear, in which case automake, when reading aclocal.m4,
  381. # will think it sees a *use*, and therefore will trigger all it's
  382. # C support machinery. Also note that it means that autoscan, seeing
  383. # CC etc. in the Makefile, will ask for an AC_PROG_CC use...
  384. # _AM_DEPENDENCIES(NAME)
  385. # ----------------------
  386. # See how the compiler implements dependency checking.
  387. # NAME is "CC", "CXX", "OBJC", "OBJCXX", "UPC", or "GJC".
  388. # We try a few techniques and use that to set a single cache variable.
  389. #
  390. # We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was
  391. # modified to invoke _AM_DEPENDENCIES(CC); we would have a circular
  392. # dependency, and given that the user is not expected to run this macro,
  393. # just rely on AC_PROG_CC.
  394. AC_DEFUN([_AM_DEPENDENCIES],
  395. [AC_REQUIRE([AM_SET_DEPDIR])dnl
  396. AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl
  397. AC_REQUIRE([AM_MAKE_INCLUDE])dnl
  398. AC_REQUIRE([AM_DEP_TRACK])dnl
  399. m4_if([$1], [CC], [depcc="$CC" am_compiler_list=],
  400. [$1], [CXX], [depcc="$CXX" am_compiler_list=],
  401. [$1], [OBJC], [depcc="$OBJC" am_compiler_list='gcc3 gcc'],
  402. [$1], [OBJCXX], [depcc="$OBJCXX" am_compiler_list='gcc3 gcc'],
  403. [$1], [UPC], [depcc="$UPC" am_compiler_list=],
  404. [$1], [GCJ], [depcc="$GCJ" am_compiler_list='gcc3 gcc'],
  405. [depcc="$$1" am_compiler_list=])
  406. AC_CACHE_CHECK([dependency style of $depcc],
  407. [am_cv_$1_dependencies_compiler_type],
  408. [if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
  409. # We make a subdir and do the tests there. Otherwise we can end up
  410. # making bogus files that we don't know about and never remove. For
  411. # instance it was reported that on HP-UX the gcc test will end up
  412. # making a dummy file named 'D' -- because '-MD' means "put the output
  413. # in D".
  414. rm -rf conftest.dir
  415. mkdir conftest.dir
  416. # Copy depcomp to subdir because otherwise we won't find it if we're
  417. # using a relative directory.
  418. cp "$am_depcomp" conftest.dir
  419. cd conftest.dir
  420. # We will build objects and dependencies in a subdirectory because
  421. # it helps to detect inapplicable dependency modes. For instance
  422. # both Tru64's cc and ICC support -MD to output dependencies as a
  423. # side effect of compilation, but ICC will put the dependencies in
  424. # the current directory while Tru64 will put them in the object
  425. # directory.
  426. mkdir sub
  427. am_cv_$1_dependencies_compiler_type=none
  428. if test "$am_compiler_list" = ""; then
  429. am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp`
  430. fi
  431. am__universal=false
  432. m4_case([$1], [CC],
  433. [case " $depcc " in #(
  434. *\ -arch\ *\ -arch\ *) am__universal=true ;;
  435. esac],
  436. [CXX],
  437. [case " $depcc " in #(
  438. *\ -arch\ *\ -arch\ *) am__universal=true ;;
  439. esac])
  440. for depmode in $am_compiler_list; do
  441. # Setup a source with many dependencies, because some compilers
  442. # like to wrap large dependency lists on column 80 (with \), and
  443. # we should not choose a depcomp mode which is confused by this.
  444. #
  445. # We need to recreate these files for each test, as the compiler may
  446. # overwrite some of them when testing with obscure command lines.
  447. # This happens at least with the AIX C compiler.
  448. : > sub/conftest.c
  449. for i in 1 2 3 4 5 6; do
  450. echo '#include "conftst'$i'.h"' >> sub/conftest.c
  451. # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
  452. # Solaris 10 /bin/sh.
  453. echo '/* dummy */' > sub/conftst$i.h
  454. done
  455. echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
  456. # We check with '-c' and '-o' for the sake of the "dashmstdout"
  457. # mode. It turns out that the SunPro C++ compiler does not properly
  458. # handle '-M -o', and we need to detect this. Also, some Intel
  459. # versions had trouble with output in subdirs.
  460. am__obj=sub/conftest.${OBJEXT-o}
  461. am__minus_obj="-o $am__obj"
  462. case $depmode in
  463. gcc)
  464. # This depmode causes a compiler race in universal mode.
  465. test "$am__universal" = false || continue
  466. ;;
  467. nosideeffect)
  468. # After this tag, mechanisms are not by side-effect, so they'll
  469. # only be used when explicitly requested.
  470. if test "x$enable_dependency_tracking" = xyes; then
  471. continue
  472. else
  473. break
  474. fi
  475. ;;
  476. msvc7 | msvc7msys | msvisualcpp | msvcmsys)
  477. # This compiler won't grok '-c -o', but also, the minuso test has
  478. # not run yet. These depmodes are late enough in the game, and
  479. # so weak that their functioning should not be impacted.
  480. am__obj=conftest.${OBJEXT-o}
  481. am__minus_obj=
  482. ;;
  483. none) break ;;
  484. esac
  485. if depmode=$depmode \
  486. source=sub/conftest.c object=$am__obj \
  487. depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
  488. $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
  489. >/dev/null 2>conftest.err &&
  490. grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
  491. grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
  492. grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
  493. ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
  494. # icc doesn't choke on unknown options, it will just issue warnings
  495. # or remarks (even with -Werror). So we grep stderr for any message
  496. # that says an option was ignored or not supported.
  497. # When given -MP, icc 7.0 and 7.1 complain thusly:
  498. # icc: Command line warning: ignoring option '-M'; no argument required
  499. # The diagnosis changed in icc 8.0:
  500. # icc: Command line remark: option '-MP' not supported
  501. if (grep 'ignoring option' conftest.err ||
  502. grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
  503. am_cv_$1_dependencies_compiler_type=$depmode
  504. break
  505. fi
  506. fi
  507. done
  508. cd ..
  509. rm -rf conftest.dir
  510. else
  511. am_cv_$1_dependencies_compiler_type=none
  512. fi
  513. ])
  514. AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type])
  515. AM_CONDITIONAL([am__fastdep$1], [
  516. test "x$enable_dependency_tracking" != xno \
  517. && test "$am_cv_$1_dependencies_compiler_type" = gcc3])
  518. ])
  519. # AM_SET_DEPDIR
  520. # -------------
  521. # Choose a directory name for dependency files.
  522. # This macro is AC_REQUIREd in _AM_DEPENDENCIES.
  523. AC_DEFUN([AM_SET_DEPDIR],
  524. [AC_REQUIRE([AM_SET_LEADING_DOT])dnl
  525. AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl
  526. ])
  527. # AM_DEP_TRACK
  528. # ------------
  529. AC_DEFUN([AM_DEP_TRACK],
  530. [AC_ARG_ENABLE([dependency-tracking], [dnl
  531. AS_HELP_STRING(
  532. [--enable-dependency-tracking],
  533. [do not reject slow dependency extractors])
  534. AS_HELP_STRING(
  535. [--disable-dependency-tracking],
  536. [speeds up one-time build])])
  537. if test "x$enable_dependency_tracking" != xno; then
  538. am_depcomp="$ac_aux_dir/depcomp"
  539. AMDEPBACKSLASH='\'
  540. am__nodep='_no'
  541. fi
  542. AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno])
  543. AC_SUBST([AMDEPBACKSLASH])dnl
  544. _AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl
  545. AC_SUBST([am__nodep])dnl
  546. _AM_SUBST_NOTMAKE([am__nodep])dnl
  547. ])
  548. # Generate code to set up dependency tracking. -*- Autoconf -*-
  549. # Copyright (C) 1999-2021 Free Software Foundation, Inc.
  550. #
  551. # This file is free software; the Free Software Foundation
  552. # gives unlimited permission to copy and/or distribute it,
  553. # with or without modifications, as long as this notice is preserved.
  554. # _AM_OUTPUT_DEPENDENCY_COMMANDS
  555. # ------------------------------
  556. AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
  557. [{
  558. # Older Autoconf quotes --file arguments for eval, but not when files
  559. # are listed without --file. Let's play safe and only enable the eval
  560. # if we detect the quoting.
  561. # TODO: see whether this extra hack can be removed once we start
  562. # requiring Autoconf 2.70 or later.
  563. AS_CASE([$CONFIG_FILES],
  564. [*\'*], [eval set x "$CONFIG_FILES"],
  565. [*], [set x $CONFIG_FILES])
  566. shift
  567. # Used to flag and report bootstrapping failures.
  568. am_rc=0
  569. for am_mf
  570. do
  571. # Strip MF so we end up with the name of the file.
  572. am_mf=`AS_ECHO(["$am_mf"]) | sed -e 's/:.*$//'`
  573. # Check whether this is an Automake generated Makefile which includes
  574. # dependency-tracking related rules and includes.
  575. # Grep'ing the whole file directly is not great: AIX grep has a line
  576. # limit of 2048, but all sed's we know have understand at least 4000.
  577. sed -n 's,^am--depfiles:.*,X,p' "$am_mf" | grep X >/dev/null 2>&1 \
  578. || continue
  579. am_dirpart=`AS_DIRNAME(["$am_mf"])`
  580. am_filepart=`AS_BASENAME(["$am_mf"])`
  581. AM_RUN_LOG([cd "$am_dirpart" \
  582. && sed -e '/# am--include-marker/d' "$am_filepart" \
  583. | $MAKE -f - am--depfiles]) || am_rc=$?
  584. done
  585. if test $am_rc -ne 0; then
  586. AC_MSG_FAILURE([Something went wrong bootstrapping makefile fragments
  587. for automatic dependency tracking. If GNU make was not used, consider
  588. re-running the configure script with MAKE="gmake" (or whatever is
  589. necessary). You can also try re-running configure with the
  590. '--disable-dependency-tracking' option to at least be able to build
  591. the package (albeit without support for automatic dependency tracking).])
  592. fi
  593. AS_UNSET([am_dirpart])
  594. AS_UNSET([am_filepart])
  595. AS_UNSET([am_mf])
  596. AS_UNSET([am_rc])
  597. rm -f conftest-deps.mk
  598. }
  599. ])# _AM_OUTPUT_DEPENDENCY_COMMANDS
  600. # AM_OUTPUT_DEPENDENCY_COMMANDS
  601. # -----------------------------
  602. # This macro should only be invoked once -- use via AC_REQUIRE.
  603. #
  604. # This code is only required when automatic dependency tracking is enabled.
  605. # This creates each '.Po' and '.Plo' makefile fragment that we'll need in
  606. # order to bootstrap the dependency handling code.
  607. AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
  608. [AC_CONFIG_COMMANDS([depfiles],
  609. [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS],
  610. [AMDEP_TRUE="$AMDEP_TRUE" MAKE="${MAKE-make}"])])
  611. # Do all the work for Automake. -*- Autoconf -*-
  612. # Copyright (C) 1996-2021 Free Software Foundation, Inc.
  613. #
  614. # This file is free software; the Free Software Foundation
  615. # gives unlimited permission to copy and/or distribute it,
  616. # with or without modifications, as long as this notice is preserved.
  617. # This macro actually does too much. Some checks are only needed if
  618. # your package does certain things. But this isn't really a big deal.
  619. dnl Redefine AC_PROG_CC to automatically invoke _AM_PROG_CC_C_O.
  620. m4_define([AC_PROG_CC],
  621. m4_defn([AC_PROG_CC])
  622. [_AM_PROG_CC_C_O
  623. ])
  624. # AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE])
  625. # AM_INIT_AUTOMAKE([OPTIONS])
  626. # -----------------------------------------------
  627. # The call with PACKAGE and VERSION arguments is the old style
  628. # call (pre autoconf-2.50), which is being phased out. PACKAGE
  629. # and VERSION should now be passed to AC_INIT and removed from
  630. # the call to AM_INIT_AUTOMAKE.
  631. # We support both call styles for the transition. After
  632. # the next Automake release, Autoconf can make the AC_INIT
  633. # arguments mandatory, and then we can depend on a new Autoconf
  634. # release and drop the old call support.
  635. AC_DEFUN([AM_INIT_AUTOMAKE],
  636. [AC_PREREQ([2.65])dnl
  637. m4_ifdef([_$0_ALREADY_INIT],
  638. [m4_fatal([$0 expanded multiple times
  639. ]m4_defn([_$0_ALREADY_INIT]))],
  640. [m4_define([_$0_ALREADY_INIT], m4_expansion_stack)])dnl
  641. dnl Autoconf wants to disallow AM_ names. We explicitly allow
  642. dnl the ones we care about.
  643. m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
  644. AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl
  645. AC_REQUIRE([AC_PROG_INSTALL])dnl
  646. if test "`cd $srcdir && pwd`" != "`pwd`"; then
  647. # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
  648. # is not polluted with repeated "-I."
  649. AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl
  650. # test to see if srcdir already configured
  651. if test -f $srcdir/config.status; then
  652. AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
  653. fi
  654. fi
  655. # test whether we have cygpath
  656. if test -z "$CYGPATH_W"; then
  657. if (cygpath --version) >/dev/null 2>/dev/null; then
  658. CYGPATH_W='cygpath -w'
  659. else
  660. CYGPATH_W=echo
  661. fi
  662. fi
  663. AC_SUBST([CYGPATH_W])
  664. # Define the identity of the package.
  665. dnl Distinguish between old-style and new-style calls.
  666. m4_ifval([$2],
  667. [AC_DIAGNOSE([obsolete],
  668. [$0: two- and three-arguments forms are deprecated.])
  669. m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl
  670. AC_SUBST([PACKAGE], [$1])dnl
  671. AC_SUBST([VERSION], [$2])],
  672. [_AM_SET_OPTIONS([$1])dnl
  673. dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT.
  674. m4_if(
  675. m4_ifset([AC_PACKAGE_NAME], [ok]):m4_ifset([AC_PACKAGE_VERSION], [ok]),
  676. [ok:ok],,
  677. [m4_fatal([AC_INIT should be called with package and version arguments])])dnl
  678. AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl
  679. AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl
  680. _AM_IF_OPTION([no-define],,
  681. [AC_DEFINE_UNQUOTED([PACKAGE], ["$PACKAGE"], [Name of package])
  682. AC_DEFINE_UNQUOTED([VERSION], ["$VERSION"], [Version number of package])])dnl
  683. # Some tools Automake needs.
  684. AC_REQUIRE([AM_SANITY_CHECK])dnl
  685. AC_REQUIRE([AC_ARG_PROGRAM])dnl
  686. AM_MISSING_PROG([ACLOCAL], [aclocal-${am__api_version}])
  687. AM_MISSING_PROG([AUTOCONF], [autoconf])
  688. AM_MISSING_PROG([AUTOMAKE], [automake-${am__api_version}])
  689. AM_MISSING_PROG([AUTOHEADER], [autoheader])
  690. AM_MISSING_PROG([MAKEINFO], [makeinfo])
  691. AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
  692. AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl
  693. AC_REQUIRE([AC_PROG_MKDIR_P])dnl
  694. # For better backward compatibility. To be removed once Automake 1.9.x
  695. # dies out for good. For more background, see:
  696. # <https://lists.gnu.org/archive/html/automake/2012-07/msg00001.html>
  697. # <https://lists.gnu.org/archive/html/automake/2012-07/msg00014.html>
  698. AC_SUBST([mkdir_p], ['$(MKDIR_P)'])
  699. # We need awk for the "check" target (and possibly the TAP driver). The
  700. # system "awk" is bad on some platforms.
  701. AC_REQUIRE([AC_PROG_AWK])dnl
  702. AC_REQUIRE([AC_PROG_MAKE_SET])dnl
  703. AC_REQUIRE([AM_SET_LEADING_DOT])dnl
  704. _AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])],
  705. [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])],
  706. [_AM_PROG_TAR([v7])])])
  707. _AM_IF_OPTION([no-dependencies],,
  708. [AC_PROVIDE_IFELSE([AC_PROG_CC],
  709. [_AM_DEPENDENCIES([CC])],
  710. [m4_define([AC_PROG_CC],
  711. m4_defn([AC_PROG_CC])[_AM_DEPENDENCIES([CC])])])dnl
  712. AC_PROVIDE_IFELSE([AC_PROG_CXX],
  713. [_AM_DEPENDENCIES([CXX])],
  714. [m4_define([AC_PROG_CXX],
  715. m4_defn([AC_PROG_CXX])[_AM_DEPENDENCIES([CXX])])])dnl
  716. AC_PROVIDE_IFELSE([AC_PROG_OBJC],
  717. [_AM_DEPENDENCIES([OBJC])],
  718. [m4_define([AC_PROG_OBJC],
  719. m4_defn([AC_PROG_OBJC])[_AM_DEPENDENCIES([OBJC])])])dnl
  720. AC_PROVIDE_IFELSE([AC_PROG_OBJCXX],
  721. [_AM_DEPENDENCIES([OBJCXX])],
  722. [m4_define([AC_PROG_OBJCXX],
  723. m4_defn([AC_PROG_OBJCXX])[_AM_DEPENDENCIES([OBJCXX])])])dnl
  724. ])
  725. # Variables for tags utilities; see am/tags.am
  726. if test -z "$CTAGS"; then
  727. CTAGS=ctags
  728. fi
  729. AC_SUBST([CTAGS])
  730. if test -z "$ETAGS"; then
  731. ETAGS=etags
  732. fi
  733. AC_SUBST([ETAGS])
  734. if test -z "$CSCOPE"; then
  735. CSCOPE=cscope
  736. fi
  737. AC_SUBST([CSCOPE])
  738. AC_REQUIRE([AM_SILENT_RULES])dnl
  739. dnl The testsuite driver may need to know about EXEEXT, so add the
  740. dnl 'am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This
  741. dnl macro is hooked onto _AC_COMPILER_EXEEXT early, see below.
  742. AC_CONFIG_COMMANDS_PRE(dnl
  743. [m4_provide_if([_AM_COMPILER_EXEEXT],
  744. [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl
  745. # POSIX will say in a future version that running "rm -f" with no argument
  746. # is OK; and we want to be able to make that assumption in our Makefile
  747. # recipes. So use an aggressive probe to check that the usage we want is
  748. # actually supported "in the wild" to an acceptable degree.
  749. # See automake bug#10828.
  750. # To make any issue more visible, cause the running configure to be aborted
  751. # by default if the 'rm' program in use doesn't match our expectations; the
  752. # user can still override this though.
  753. if rm -f && rm -fr && rm -rf; then : OK; else
  754. cat >&2 <<'END'
  755. Oops!
  756. Your 'rm' program seems unable to run without file operands specified
  757. on the command line, even when the '-f' option is present. This is contrary
  758. to the behaviour of most rm programs out there, and not conforming with
  759. the upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542>
  760. Please tell bug-automake@gnu.org about your system, including the value
  761. of your $PATH and any error possibly output before this message. This
  762. can help us improve future automake versions.
  763. END
  764. if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then
  765. echo 'Configuration will proceed anyway, since you have set the' >&2
  766. echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2
  767. echo >&2
  768. else
  769. cat >&2 <<'END'
  770. Aborting the configuration process, to ensure you take notice of the issue.
  771. You can download and install GNU coreutils to get an 'rm' implementation
  772. that behaves properly: <https://www.gnu.org/software/coreutils/>.
  773. If you want to complete the configuration process using your problematic
  774. 'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM
  775. to "yes", and re-run configure.
  776. END
  777. AC_MSG_ERROR([Your 'rm' program is bad, sorry.])
  778. fi
  779. fi
  780. dnl The trailing newline in this macro's definition is deliberate, for
  781. dnl backward compatibility and to allow trailing 'dnl'-style comments
  782. dnl after the AM_INIT_AUTOMAKE invocation. See automake bug#16841.
  783. ])
  784. dnl Hook into '_AC_COMPILER_EXEEXT' early to learn its expansion. Do not
  785. dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further
  786. dnl mangled by Autoconf and run in a shell conditional statement.
  787. m4_define([_AC_COMPILER_EXEEXT],
  788. m4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])])
  789. # When config.status generates a header, we must update the stamp-h file.
  790. # This file resides in the same directory as the config header
  791. # that is generated. The stamp files are numbered to have different names.
  792. # Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the
  793. # loop where config.status creates the headers, so we can generate
  794. # our stamp files there.
  795. AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK],
  796. [# Compute $1's index in $config_headers.
  797. _am_arg=$1
  798. _am_stamp_count=1
  799. for _am_header in $config_headers :; do
  800. case $_am_header in
  801. $_am_arg | $_am_arg:* )
  802. break ;;
  803. * )
  804. _am_stamp_count=`expr $_am_stamp_count + 1` ;;
  805. esac
  806. done
  807. echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count])
  808. # Copyright (C) 2001-2021 Free Software Foundation, Inc.
  809. #
  810. # This file is free software; the Free Software Foundation
  811. # gives unlimited permission to copy and/or distribute it,
  812. # with or without modifications, as long as this notice is preserved.
  813. # AM_PROG_INSTALL_SH
  814. # ------------------
  815. # Define $install_sh.
  816. AC_DEFUN([AM_PROG_INSTALL_SH],
  817. [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
  818. if test x"${install_sh+set}" != xset; then
  819. case $am_aux_dir in
  820. *\ * | *\ *)
  821. install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
  822. *)
  823. install_sh="\${SHELL} $am_aux_dir/install-sh"
  824. esac
  825. fi
  826. AC_SUBST([install_sh])])
  827. # Copyright (C) 2003-2021 Free Software Foundation, Inc.
  828. #
  829. # This file is free software; the Free Software Foundation
  830. # gives unlimited permission to copy and/or distribute it,
  831. # with or without modifications, as long as this notice is preserved.
  832. # Check whether the underlying file-system supports filenames
  833. # with a leading dot. For instance MS-DOS doesn't.
  834. AC_DEFUN([AM_SET_LEADING_DOT],
  835. [rm -rf .tst 2>/dev/null
  836. mkdir .tst 2>/dev/null
  837. if test -d .tst; then
  838. am__leading_dot=.
  839. else
  840. am__leading_dot=_
  841. fi
  842. rmdir .tst 2>/dev/null
  843. AC_SUBST([am__leading_dot])])
  844. # Add --enable-maintainer-mode option to configure. -*- Autoconf -*-
  845. # From Jim Meyering
  846. # Copyright (C) 1996-2021 Free Software Foundation, Inc.
  847. #
  848. # This file is free software; the Free Software Foundation
  849. # gives unlimited permission to copy and/or distribute it,
  850. # with or without modifications, as long as this notice is preserved.
  851. # AM_MAINTAINER_MODE([DEFAULT-MODE])
  852. # ----------------------------------
  853. # Control maintainer-specific portions of Makefiles.
  854. # Default is to disable them, unless 'enable' is passed literally.
  855. # For symmetry, 'disable' may be passed as well. Anyway, the user
  856. # can override the default with the --enable/--disable switch.
  857. AC_DEFUN([AM_MAINTAINER_MODE],
  858. [m4_case(m4_default([$1], [disable]),
  859. [enable], [m4_define([am_maintainer_other], [disable])],
  860. [disable], [m4_define([am_maintainer_other], [enable])],
  861. [m4_define([am_maintainer_other], [enable])
  862. m4_warn([syntax], [unexpected argument to AM@&t@_MAINTAINER_MODE: $1])])
  863. AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles])
  864. dnl maintainer-mode's default is 'disable' unless 'enable' is passed
  865. AC_ARG_ENABLE([maintainer-mode],
  866. [AS_HELP_STRING([--]am_maintainer_other[-maintainer-mode],
  867. am_maintainer_other[ make rules and dependencies not useful
  868. (and sometimes confusing) to the casual installer])],
  869. [USE_MAINTAINER_MODE=$enableval],
  870. [USE_MAINTAINER_MODE=]m4_if(am_maintainer_other, [enable], [no], [yes]))
  871. AC_MSG_RESULT([$USE_MAINTAINER_MODE])
  872. AM_CONDITIONAL([MAINTAINER_MODE], [test $USE_MAINTAINER_MODE = yes])
  873. MAINT=$MAINTAINER_MODE_TRUE
  874. AC_SUBST([MAINT])dnl
  875. ]
  876. )
  877. # Check to see how 'make' treats includes. -*- Autoconf -*-
  878. # Copyright (C) 2001-2021 Free Software Foundation, Inc.
  879. #
  880. # This file is free software; the Free Software Foundation
  881. # gives unlimited permission to copy and/or distribute it,
  882. # with or without modifications, as long as this notice is preserved.
  883. # AM_MAKE_INCLUDE()
  884. # -----------------
  885. # Check whether make has an 'include' directive that can support all
  886. # the idioms we need for our automatic dependency tracking code.
  887. AC_DEFUN([AM_MAKE_INCLUDE],
  888. [AC_MSG_CHECKING([whether ${MAKE-make} supports the include directive])
  889. cat > confinc.mk << 'END'
  890. am__doit:
  891. @echo this is the am__doit target >confinc.out
  892. .PHONY: am__doit
  893. END
  894. am__include="#"
  895. am__quote=
  896. # BSD make does it like this.
  897. echo '.include "confinc.mk" # ignored' > confmf.BSD
  898. # Other make implementations (GNU, Solaris 10, AIX) do it like this.
  899. echo 'include confinc.mk # ignored' > confmf.GNU
  900. _am_result=no
  901. for s in GNU BSD; do
  902. AM_RUN_LOG([${MAKE-make} -f confmf.$s && cat confinc.out])
  903. AS_CASE([$?:`cat confinc.out 2>/dev/null`],
  904. ['0:this is the am__doit target'],
  905. [AS_CASE([$s],
  906. [BSD], [am__include='.include' am__quote='"'],
  907. [am__include='include' am__quote=''])])
  908. if test "$am__include" != "#"; then
  909. _am_result="yes ($s style)"
  910. break
  911. fi
  912. done
  913. rm -f confinc.* confmf.*
  914. AC_MSG_RESULT([${_am_result}])
  915. AC_SUBST([am__include])])
  916. AC_SUBST([am__quote])])
  917. # Fake the existence of programs that GNU maintainers use. -*- Autoconf -*-
  918. # Copyright (C) 1997-2021 Free Software Foundation, Inc.
  919. #
  920. # This file is free software; the Free Software Foundation
  921. # gives unlimited permission to copy and/or distribute it,
  922. # with or without modifications, as long as this notice is preserved.
  923. # AM_MISSING_PROG(NAME, PROGRAM)
  924. # ------------------------------
  925. AC_DEFUN([AM_MISSING_PROG],
  926. [AC_REQUIRE([AM_MISSING_HAS_RUN])
  927. $1=${$1-"${am_missing_run}$2"}
  928. AC_SUBST($1)])
  929. # AM_MISSING_HAS_RUN
  930. # ------------------
  931. # Define MISSING if not defined so far and test if it is modern enough.
  932. # If it is, set am_missing_run to use it, otherwise, to nothing.
  933. AC_DEFUN([AM_MISSING_HAS_RUN],
  934. [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
  935. AC_REQUIRE_AUX_FILE([missing])dnl
  936. if test x"${MISSING+set}" != xset; then
  937. MISSING="\${SHELL} '$am_aux_dir/missing'"
  938. fi
  939. # Use eval to expand $SHELL
  940. if eval "$MISSING --is-lightweight"; then
  941. am_missing_run="$MISSING "
  942. else
  943. am_missing_run=
  944. AC_MSG_WARN(['missing' script is too old or missing])
  945. fi
  946. ])
  947. # Helper functions for option handling. -*- Autoconf -*-
  948. # Copyright (C) 2001-2021 Free Software Foundation, Inc.
  949. #
  950. # This file is free software; the Free Software Foundation
  951. # gives unlimited permission to copy and/or distribute it,
  952. # with or without modifications, as long as this notice is preserved.
  953. # _AM_MANGLE_OPTION(NAME)
  954. # -----------------------
  955. AC_DEFUN([_AM_MANGLE_OPTION],
  956. [[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])])
  957. # _AM_SET_OPTION(NAME)
  958. # --------------------
  959. # Set option NAME. Presently that only means defining a flag for this option.
  960. AC_DEFUN([_AM_SET_OPTION],
  961. [m4_define(_AM_MANGLE_OPTION([$1]), [1])])
  962. # _AM_SET_OPTIONS(OPTIONS)
  963. # ------------------------
  964. # OPTIONS is a space-separated list of Automake options.
  965. AC_DEFUN([_AM_SET_OPTIONS],
  966. [m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])])
  967. # _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET])
  968. # -------------------------------------------
  969. # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
  970. AC_DEFUN([_AM_IF_OPTION],
  971. [m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
  972. # Copyright (C) 1999-2021 Free Software Foundation, Inc.
  973. #
  974. # This file is free software; the Free Software Foundation
  975. # gives unlimited permission to copy and/or distribute it,
  976. # with or without modifications, as long as this notice is preserved.
  977. # _AM_PROG_CC_C_O
  978. # ---------------
  979. # Like AC_PROG_CC_C_O, but changed for automake. We rewrite AC_PROG_CC
  980. # to automatically call this.
  981. AC_DEFUN([_AM_PROG_CC_C_O],
  982. [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
  983. AC_REQUIRE_AUX_FILE([compile])dnl
  984. AC_LANG_PUSH([C])dnl
  985. AC_CACHE_CHECK(
  986. [whether $CC understands -c and -o together],
  987. [am_cv_prog_cc_c_o],
  988. [AC_LANG_CONFTEST([AC_LANG_PROGRAM([])])
  989. # Make sure it works both with $CC and with simple cc.
  990. # Following AC_PROG_CC_C_O, we do the test twice because some
  991. # compilers refuse to overwrite an existing .o file with -o,
  992. # though they will create one.
  993. am_cv_prog_cc_c_o=yes
  994. for am_i in 1 2; do
  995. if AM_RUN_LOG([$CC -c conftest.$ac_ext -o conftest2.$ac_objext]) \
  996. && test -f conftest2.$ac_objext; then
  997. : OK
  998. else
  999. am_cv_prog_cc_c_o=no
  1000. break
  1001. fi
  1002. done
  1003. rm -f core conftest*
  1004. unset am_i])
  1005. if test "$am_cv_prog_cc_c_o" != yes; then
  1006. # Losing compiler, so override with the script.
  1007. # FIXME: It is wrong to rewrite CC.
  1008. # But if we don't then we get into trouble of one sort or another.
  1009. # A longer-term fix would be to have automake use am__CC in this case,
  1010. # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
  1011. CC="$am_aux_dir/compile $CC"
  1012. fi
  1013. AC_LANG_POP([C])])
  1014. # For backward compatibility.
  1015. AC_DEFUN_ONCE([AM_PROG_CC_C_O], [AC_REQUIRE([AC_PROG_CC])])
  1016. # Copyright (C) 1999-2021 Free Software Foundation, Inc.
  1017. #
  1018. # This file is free software; the Free Software Foundation
  1019. # gives unlimited permission to copy and/or distribute it,
  1020. # with or without modifications, as long as this notice is preserved.
  1021. # AM_PATH_PYTHON([MINIMUM-VERSION], [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
  1022. # ---------------------------------------------------------------------------
  1023. # Adds support for distributing Python modules and packages. To
  1024. # install modules, copy them to $(pythondir), using the python_PYTHON
  1025. # automake variable. To install a package with the same name as the
  1026. # automake package, install to $(pkgpythondir), or use the
  1027. # pkgpython_PYTHON automake variable.
  1028. #
  1029. # The variables $(pyexecdir) and $(pkgpyexecdir) are provided as
  1030. # locations to install python extension modules (shared libraries).
  1031. # Another macro is required to find the appropriate flags to compile
  1032. # extension modules.
  1033. #
  1034. # If your package is configured with a different prefix to python,
  1035. # users will have to add the install directory to the PYTHONPATH
  1036. # environment variable, or create a .pth file (see the python
  1037. # documentation for details).
  1038. #
  1039. # If the MINIMUM-VERSION argument is passed, AM_PATH_PYTHON will
  1040. # cause an error if the version of python installed on the system
  1041. # doesn't meet the requirement. MINIMUM-VERSION should consist of
  1042. # numbers and dots only.
  1043. AC_DEFUN([AM_PATH_PYTHON],
  1044. [
  1045. dnl Find a Python interpreter. Python versions prior to 2.0 are not
  1046. dnl supported. (2.0 was released on October 16, 2000).
  1047. m4_define_default([_AM_PYTHON_INTERPRETER_LIST],
  1048. [python python2 python3 dnl
  1049. python3.9 python3.8 python3.7 python3.6 python3.5 python3.4 python3.3 dnl
  1050. python3.2 python3.1 python3.0 dnl
  1051. python2.7 python2.6 python2.5 python2.4 python2.3 python2.2 python2.1 dnl
  1052. python2.0])
  1053. AC_ARG_VAR([PYTHON], [the Python interpreter])
  1054. m4_if([$1],[],[
  1055. dnl No version check is needed.
  1056. # Find any Python interpreter.
  1057. if test -z "$PYTHON"; then
  1058. AC_PATH_PROGS([PYTHON], _AM_PYTHON_INTERPRETER_LIST, :)
  1059. fi
  1060. am_display_PYTHON=python
  1061. ], [
  1062. dnl A version check is needed.
  1063. if test -n "$PYTHON"; then
  1064. # If the user set $PYTHON, use it and don't search something else.
  1065. AC_MSG_CHECKING([whether $PYTHON version is >= $1])
  1066. AM_PYTHON_CHECK_VERSION([$PYTHON], [$1],
  1067. [AC_MSG_RESULT([yes])],
  1068. [AC_MSG_RESULT([no])
  1069. AC_MSG_ERROR([Python interpreter is too old])])
  1070. am_display_PYTHON=$PYTHON
  1071. else
  1072. # Otherwise, try each interpreter until we find one that satisfies
  1073. # VERSION.
  1074. AC_CACHE_CHECK([for a Python interpreter with version >= $1],
  1075. [am_cv_pathless_PYTHON],[
  1076. for am_cv_pathless_PYTHON in _AM_PYTHON_INTERPRETER_LIST none; do
  1077. test "$am_cv_pathless_PYTHON" = none && break
  1078. AM_PYTHON_CHECK_VERSION([$am_cv_pathless_PYTHON], [$1], [break])
  1079. done])
  1080. # Set $PYTHON to the absolute path of $am_cv_pathless_PYTHON.
  1081. if test "$am_cv_pathless_PYTHON" = none; then
  1082. PYTHON=:
  1083. else
  1084. AC_PATH_PROG([PYTHON], [$am_cv_pathless_PYTHON])
  1085. fi
  1086. am_display_PYTHON=$am_cv_pathless_PYTHON
  1087. fi
  1088. ])
  1089. if test "$PYTHON" = :; then
  1090. dnl Run any user-specified action, or abort.
  1091. m4_default([$3], [AC_MSG_ERROR([no suitable Python interpreter found])])
  1092. else
  1093. dnl Query Python for its version number. Although site.py simply uses
  1094. dnl sys.version[:3], printing that failed with Python 3.10, since the
  1095. dnl trailing zero was eliminated. So now we output just the major
  1096. dnl and minor version numbers, as numbers. Apparently the tertiary
  1097. dnl version is not of interest.
  1098. dnl
  1099. AC_CACHE_CHECK([for $am_display_PYTHON version], [am_cv_python_version],
  1100. [am_cv_python_version=`$PYTHON -c "import sys; print ('%u.%u' % sys.version_info[[:2]])"`])
  1101. AC_SUBST([PYTHON_VERSION], [$am_cv_python_version])
  1102. dnl At times, e.g., when building shared libraries, you may want
  1103. dnl to know which OS platform Python thinks this is.
  1104. dnl
  1105. AC_CACHE_CHECK([for $am_display_PYTHON platform], [am_cv_python_platform],
  1106. [am_cv_python_platform=`$PYTHON -c "import sys; sys.stdout.write(sys.platform)"`])
  1107. AC_SUBST([PYTHON_PLATFORM], [$am_cv_python_platform])
  1108. dnl emacs-page
  1109. dnl If --with-python-sys-prefix is given, use the values of sys.prefix
  1110. dnl and sys.exec_prefix for the corresponding values of PYTHON_PREFIX
  1111. dnl and PYTHON_EXEC_PREFIX. Otherwise, use the GNU ${prefix} and
  1112. dnl ${exec_prefix} variables.
  1113. dnl
  1114. dnl The two are made distinct variables so they can be overridden if
  1115. dnl need be, although general consensus is that you shouldn't need
  1116. dnl this separation.
  1117. dnl
  1118. dnl Also allow directly setting the prefixes via configure options,
  1119. dnl overriding any default.
  1120. dnl
  1121. if test "x$prefix" = xNONE; then
  1122. am__usable_prefix=$ac_default_prefix
  1123. else
  1124. am__usable_prefix=$prefix
  1125. fi
  1126. # Allow user to request using sys.* values from Python,
  1127. # instead of the GNU $prefix values.
  1128. AC_ARG_WITH([python-sys-prefix],
  1129. [AS_HELP_STRING([--with-python-sys-prefix],
  1130. [use Python's sys.prefix and sys.exec_prefix values])],
  1131. [am_use_python_sys=:],
  1132. [am_use_python_sys=false])
  1133. # Allow user to override whatever the default Python prefix is.
  1134. AC_ARG_WITH([python_prefix],
  1135. [AS_HELP_STRING([--with-python_prefix],
  1136. [override the default PYTHON_PREFIX])],
  1137. [am_python_prefix_subst=$withval
  1138. am_cv_python_prefix=$withval
  1139. AC_MSG_CHECKING([for explicit $am_display_PYTHON prefix])
  1140. AC_MSG_RESULT([$am_cv_python_prefix])],
  1141. [
  1142. if $am_use_python_sys; then
  1143. # using python sys.prefix value, not GNU
  1144. AC_CACHE_CHECK([for python default $am_display_PYTHON prefix],
  1145. [am_cv_python_prefix],
  1146. [am_cv_python_prefix=`$PYTHON -c "import sys; sys.stdout.write(sys.prefix)"`])
  1147. dnl If sys.prefix is a subdir of $prefix, replace the literal value of
  1148. dnl $prefix with a variable reference so it can be overridden.
  1149. case $am_cv_python_prefix in
  1150. $am__usable_prefix*)
  1151. am__strip_prefix=`echo "$am__usable_prefix" | sed 's|.|.|g'`
  1152. am_python_prefix_subst=`echo "$am_cv_python_prefix" | sed "s,^$am__strip_prefix,\\${prefix},"`
  1153. ;;
  1154. *)
  1155. am_python_prefix_subst=$am_cv_python_prefix
  1156. ;;
  1157. esac
  1158. else # using GNU prefix value, not python sys.prefix
  1159. am_python_prefix_subst='${prefix}'
  1160. am_python_prefix=$am_python_prefix_subst
  1161. AC_MSG_CHECKING([for GNU default $am_display_PYTHON prefix])
  1162. AC_MSG_RESULT([$am_python_prefix])
  1163. fi])
  1164. # Substituting python_prefix_subst value.
  1165. AC_SUBST([PYTHON_PREFIX], [$am_python_prefix_subst])
  1166. # emacs-page Now do it all over again for Python exec_prefix, but with yet
  1167. # another conditional: fall back to regular prefix if that was specified.
  1168. AC_ARG_WITH([python_exec_prefix],
  1169. [AS_HELP_STRING([--with-python_exec_prefix],
  1170. [override the default PYTHON_EXEC_PREFIX])],
  1171. [am_python_exec_prefix_subst=$withval
  1172. am_cv_python_exec_prefix=$withval
  1173. AC_MSG_CHECKING([for explicit $am_display_PYTHON exec_prefix])
  1174. AC_MSG_RESULT([$am_cv_python_exec_prefix])],
  1175. [
  1176. # no explicit --with-python_exec_prefix, but if
  1177. # --with-python_prefix was given, use its value for python_exec_prefix too.
  1178. AS_IF([test -n "$with_python_prefix"],
  1179. [am_python_exec_prefix_subst=$with_python_prefix
  1180. am_cv_python_exec_prefix=$with_python_prefix
  1181. AC_MSG_CHECKING([for python_prefix-given $am_display_PYTHON exec_prefix])
  1182. AC_MSG_RESULT([$am_cv_python_exec_prefix])],
  1183. [
  1184. # Set am__usable_exec_prefix whether using GNU or Python values,
  1185. # since we use that variable for pyexecdir.
  1186. if test "x$exec_prefix" = xNONE; then
  1187. am__usable_exec_prefix=$am__usable_prefix
  1188. else
  1189. am__usable_exec_prefix=$exec_prefix
  1190. fi
  1191. #
  1192. if $am_use_python_sys; then # using python sys.exec_prefix, not GNU
  1193. AC_CACHE_CHECK([for python default $am_display_PYTHON exec_prefix],
  1194. [am_cv_python_exec_prefix],
  1195. [am_cv_python_exec_prefix=`$PYTHON -c "import sys; sys.stdout.write(sys.exec_prefix)"`])
  1196. dnl If sys.exec_prefix is a subdir of $exec_prefix, replace the
  1197. dnl literal value of $exec_prefix with a variable reference so it can
  1198. dnl be overridden.
  1199. case $am_cv_python_exec_prefix in
  1200. $am__usable_exec_prefix*)
  1201. am__strip_prefix=`echo "$am__usable_exec_prefix" | sed 's|.|.|g'`
  1202. am_python_exec_prefix_subst=`echo "$am_cv_python_exec_prefix" | sed "s,^$am__strip_prefix,\\${exec_prefix},"`
  1203. ;;
  1204. *)
  1205. am_python_exec_prefix_subst=$am_cv_python_exec_prefix
  1206. ;;
  1207. esac
  1208. else # using GNU $exec_prefix, not python sys.exec_prefix
  1209. am_python_exec_prefix_subst='${exec_prefix}'
  1210. am_python_exec_prefix=$am_python_exec_prefix_subst
  1211. AC_MSG_CHECKING([for GNU default $am_display_PYTHON exec_prefix])
  1212. AC_MSG_RESULT([$am_python_exec_prefix])
  1213. fi])])
  1214. # Substituting python_exec_prefix_subst.
  1215. AC_SUBST([PYTHON_EXEC_PREFIX], [$am_python_exec_prefix_subst])
  1216. # Factor out some code duplication into this shell variable.
  1217. am_python_setup_sysconfig="\
  1218. import sys
  1219. # Prefer sysconfig over distutils.sysconfig, for better compatibility
  1220. # with python 3.x. See automake bug#10227.
  1221. try:
  1222. import sysconfig
  1223. except ImportError:
  1224. can_use_sysconfig = 0
  1225. else:
  1226. can_use_sysconfig = 1
  1227. # Can't use sysconfig in CPython 2.7, since it's broken in virtualenvs:
  1228. # <https://github.com/pypa/virtualenv/issues/118>
  1229. try:
  1230. from platform import python_implementation
  1231. if python_implementation() == 'CPython' and sys.version[[:3]] == '2.7':
  1232. can_use_sysconfig = 0
  1233. except ImportError:
  1234. pass"
  1235. dnl emacs-page Set up 4 directories:
  1236. dnl 1. pythondir: where to install python scripts. This is the
  1237. dnl site-packages directory, not the python standard library
  1238. dnl directory like in previous automake betas. This behavior
  1239. dnl is more consistent with lispdir.m4 for example.
  1240. dnl Query distutils for this directory.
  1241. dnl
  1242. AC_CACHE_CHECK([for $am_display_PYTHON script directory (pythondir)],
  1243. [am_cv_python_pythondir],
  1244. [if test "x$am_cv_python_prefix" = x; then
  1245. am_py_prefix=$am__usable_prefix
  1246. else
  1247. am_py_prefix=$am_cv_python_prefix
  1248. fi
  1249. am_cv_python_pythondir=`$PYTHON -c "
  1250. $am_python_setup_sysconfig
  1251. if can_use_sysconfig:
  1252. sitedir = sysconfig.get_path('purelib', vars={'base':'$am_py_prefix'})
  1253. else:
  1254. from distutils import sysconfig
  1255. sitedir = sysconfig.get_python_lib(0, 0, prefix='$am_py_prefix')
  1256. sys.stdout.write(sitedir)"`
  1257. #
  1258. case $am_cv_python_pythondir in
  1259. $am_py_prefix*)
  1260. am__strip_prefix=`echo "$am_py_prefix" | sed 's|.|.|g'`
  1261. am_cv_python_pythondir=`echo "$am_cv_python_pythondir" | sed "s,^$am__strip_prefix,\\${PYTHON_PREFIX},"`
  1262. ;;
  1263. *)
  1264. case $am_py_prefix in
  1265. /usr|/System*) ;;
  1266. *) am_cv_python_pythondir="\${PYTHON_PREFIX}/lib/python$PYTHON_VERSION/site-packages"
  1267. ;;
  1268. esac
  1269. ;;
  1270. esac
  1271. ])
  1272. AC_SUBST([pythondir], [$am_cv_python_pythondir])
  1273. dnl 2. pkgpythondir: $PACKAGE directory under pythondir. Was
  1274. dnl PYTHON_SITE_PACKAGE in previous betas, but this naming is
  1275. dnl more consistent with the rest of automake.
  1276. dnl
  1277. AC_SUBST([pkgpythondir], [\${pythondir}/$PACKAGE])
  1278. dnl 3. pyexecdir: directory for installing python extension modules
  1279. dnl (shared libraries).
  1280. dnl Query distutils for this directory.
  1281. dnl
  1282. AC_CACHE_CHECK([for $am_display_PYTHON extension module directory (pyexecdir)],
  1283. [am_cv_python_pyexecdir],
  1284. [if test "x$am_cv_python_exec_prefix" = x; then
  1285. am_py_exec_prefix=$am__usable_exec_prefix
  1286. else
  1287. am_py_exec_prefix=$am_cv_python_exec_prefix
  1288. fi
  1289. am_cv_python_pyexecdir=`$PYTHON -c "
  1290. $am_python_setup_sysconfig
  1291. if can_use_sysconfig:
  1292. sitedir = sysconfig.get_path('platlib', vars={'platbase':'$am_py_exec_prefix'})
  1293. else:
  1294. from distutils import sysconfig
  1295. sitedir = sysconfig.get_python_lib(1, 0, prefix='$am_py_exec_prefix')
  1296. sys.stdout.write(sitedir)"`
  1297. #
  1298. case $am_cv_python_pyexecdir in
  1299. $am_py_exec_prefix*)
  1300. am__strip_prefix=`echo "$am_py_exec_prefix" | sed 's|.|.|g'`
  1301. am_cv_python_pyexecdir=`echo "$am_cv_python_pyexecdir" | sed "s,^$am__strip_prefix,\\${PYTHON_EXEC_PREFIX},"`
  1302. ;;
  1303. *)
  1304. case $am_py_exec_prefix in
  1305. /usr|/System*) ;;
  1306. *) am_cv_python_pyexecdir="\${PYTHON_EXEC_PREFIX}/lib/python$PYTHON_VERSION/site-packages"
  1307. ;;
  1308. esac
  1309. ;;
  1310. esac
  1311. ])
  1312. AC_SUBST([pyexecdir], [$am_cv_python_pyexecdir])
  1313. dnl 4. pkgpyexecdir: $(pyexecdir)/$(PACKAGE)
  1314. dnl
  1315. AC_SUBST([pkgpyexecdir], [\${pyexecdir}/$PACKAGE])
  1316. dnl Run any user-specified action.
  1317. $2
  1318. fi
  1319. ])
  1320. # AM_PYTHON_CHECK_VERSION(PROG, VERSION, [ACTION-IF-TRUE], [ACTION-IF-FALSE])
  1321. # ---------------------------------------------------------------------------
  1322. # Run ACTION-IF-TRUE if the Python interpreter PROG has version >= VERSION.
  1323. # Run ACTION-IF-FALSE otherwise.
  1324. # This test uses sys.hexversion instead of the string equivalent (first
  1325. # word of sys.version), in order to cope with versions such as 2.2c1.
  1326. # This supports Python 2.0 or higher. (2.0 was released on October 16, 2000).
  1327. AC_DEFUN([AM_PYTHON_CHECK_VERSION],
  1328. [prog="import sys
  1329. # split strings by '.' and convert to numeric. Append some zeros
  1330. # because we need at least 4 digits for the hex conversion.
  1331. # map returns an iterator in Python 3.0 and a list in 2.x
  1332. minver = list(map(int, '$2'.split('.'))) + [[0, 0, 0]]
  1333. minverhex = 0
  1334. # xrange is not present in Python 3.0 and range returns an iterator
  1335. for i in list(range(0, 4)): minverhex = (minverhex << 8) + minver[[i]]
  1336. sys.exit(sys.hexversion < minverhex)"
  1337. AS_IF([AM_RUN_LOG([$1 -c "$prog"])], [$3], [$4])])
  1338. # Copyright (C) 2001-2021 Free Software Foundation, Inc.
  1339. #
  1340. # This file is free software; the Free Software Foundation
  1341. # gives unlimited permission to copy and/or distribute it,
  1342. # with or without modifications, as long as this notice is preserved.
  1343. # AM_RUN_LOG(COMMAND)
  1344. # -------------------
  1345. # Run COMMAND, save the exit status in ac_status, and log it.
  1346. # (This has been adapted from Autoconf's _AC_RUN_LOG macro.)
  1347. AC_DEFUN([AM_RUN_LOG],
  1348. [{ echo "$as_me:$LINENO: $1" >&AS_MESSAGE_LOG_FD
  1349. ($1) >&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD
  1350. ac_status=$?
  1351. echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
  1352. (exit $ac_status); }])
  1353. # Check to make sure that the build environment is sane. -*- Autoconf -*-
  1354. # Copyright (C) 1996-2021 Free Software Foundation, Inc.
  1355. #
  1356. # This file is free software; the Free Software Foundation
  1357. # gives unlimited permission to copy and/or distribute it,
  1358. # with or without modifications, as long as this notice is preserved.
  1359. # AM_SANITY_CHECK
  1360. # ---------------
  1361. AC_DEFUN([AM_SANITY_CHECK],
  1362. [AC_MSG_CHECKING([whether build environment is sane])
  1363. # Reject unsafe characters in $srcdir or the absolute working directory
  1364. # name. Accept space and tab only in the latter.
  1365. am_lf='
  1366. '
  1367. case `pwd` in
  1368. *[[\\\"\#\$\&\'\`$am_lf]]*)
  1369. AC_MSG_ERROR([unsafe absolute working directory name]);;
  1370. esac
  1371. case $srcdir in
  1372. *[[\\\"\#\$\&\'\`$am_lf\ \ ]]*)
  1373. AC_MSG_ERROR([unsafe srcdir value: '$srcdir']);;
  1374. esac
  1375. # Do 'set' in a subshell so we don't clobber the current shell's
  1376. # arguments. Must try -L first in case configure is actually a
  1377. # symlink; some systems play weird games with the mod time of symlinks
  1378. # (eg FreeBSD returns the mod time of the symlink's containing
  1379. # directory).
  1380. if (
  1381. am_has_slept=no
  1382. for am_try in 1 2; do
  1383. echo "timestamp, slept: $am_has_slept" > conftest.file
  1384. set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
  1385. if test "$[*]" = "X"; then
  1386. # -L didn't work.
  1387. set X `ls -t "$srcdir/configure" conftest.file`
  1388. fi
  1389. if test "$[*]" != "X $srcdir/configure conftest.file" \
  1390. && test "$[*]" != "X conftest.file $srcdir/configure"; then
  1391. # If neither matched, then we have a broken ls. This can happen
  1392. # if, for instance, CONFIG_SHELL is bash and it inherits a
  1393. # broken ls alias from the environment. This has actually
  1394. # happened. Such a system could not be considered "sane".
  1395. AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken
  1396. alias in your environment])
  1397. fi
  1398. if test "$[2]" = conftest.file || test $am_try -eq 2; then
  1399. break
  1400. fi
  1401. # Just in case.
  1402. sleep 1
  1403. am_has_slept=yes
  1404. done
  1405. test "$[2]" = conftest.file
  1406. )
  1407. then
  1408. # Ok.
  1409. :
  1410. else
  1411. AC_MSG_ERROR([newly created file is older than distributed files!
  1412. Check your system clock])
  1413. fi
  1414. AC_MSG_RESULT([yes])
  1415. # If we didn't sleep, we still need to ensure time stamps of config.status and
  1416. # generated files are strictly newer.
  1417. am_sleep_pid=
  1418. if grep 'slept: no' conftest.file >/dev/null 2>&1; then
  1419. ( sleep 1 ) &
  1420. am_sleep_pid=$!
  1421. fi
  1422. AC_CONFIG_COMMANDS_PRE(
  1423. [AC_MSG_CHECKING([that generated files are newer than configure])
  1424. if test -n "$am_sleep_pid"; then
  1425. # Hide warnings about reused PIDs.
  1426. wait $am_sleep_pid 2>/dev/null
  1427. fi
  1428. AC_MSG_RESULT([done])])
  1429. rm -f conftest.file
  1430. ])
  1431. # Copyright (C) 2009-2021 Free Software Foundation, Inc.
  1432. #
  1433. # This file is free software; the Free Software Foundation
  1434. # gives unlimited permission to copy and/or distribute it,
  1435. # with or without modifications, as long as this notice is preserved.
  1436. # AM_SILENT_RULES([DEFAULT])
  1437. # --------------------------
  1438. # Enable less verbose build rules; with the default set to DEFAULT
  1439. # ("yes" being less verbose, "no" or empty being verbose).
  1440. AC_DEFUN([AM_SILENT_RULES],
  1441. [AC_ARG_ENABLE([silent-rules], [dnl
  1442. AS_HELP_STRING(
  1443. [--enable-silent-rules],
  1444. [less verbose build output (undo: "make V=1")])
  1445. AS_HELP_STRING(
  1446. [--disable-silent-rules],
  1447. [verbose build output (undo: "make V=0")])dnl
  1448. ])
  1449. case $enable_silent_rules in @%:@ (((
  1450. yes) AM_DEFAULT_VERBOSITY=0;;
  1451. no) AM_DEFAULT_VERBOSITY=1;;
  1452. *) AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);;
  1453. esac
  1454. dnl
  1455. dnl A few 'make' implementations (e.g., NonStop OS and NextStep)
  1456. dnl do not support nested variable expansions.
  1457. dnl See automake bug#9928 and bug#10237.
  1458. am_make=${MAKE-make}
  1459. AC_CACHE_CHECK([whether $am_make supports nested variables],
  1460. [am_cv_make_support_nested_variables],
  1461. [if AS_ECHO([['TRUE=$(BAR$(V))
  1462. BAR0=false
  1463. BAR1=true
  1464. V=1
  1465. am__doit:
  1466. @$(TRUE)
  1467. .PHONY: am__doit']]) | $am_make -f - >/dev/null 2>&1; then
  1468. am_cv_make_support_nested_variables=yes
  1469. else
  1470. am_cv_make_support_nested_variables=no
  1471. fi])
  1472. if test $am_cv_make_support_nested_variables = yes; then
  1473. dnl Using '$V' instead of '$(V)' breaks IRIX make.
  1474. AM_V='$(V)'
  1475. AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
  1476. else
  1477. AM_V=$AM_DEFAULT_VERBOSITY
  1478. AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
  1479. fi
  1480. AC_SUBST([AM_V])dnl
  1481. AM_SUBST_NOTMAKE([AM_V])dnl
  1482. AC_SUBST([AM_DEFAULT_V])dnl
  1483. AM_SUBST_NOTMAKE([AM_DEFAULT_V])dnl
  1484. AC_SUBST([AM_DEFAULT_VERBOSITY])dnl
  1485. AM_BACKSLASH='\'
  1486. AC_SUBST([AM_BACKSLASH])dnl
  1487. _AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl
  1488. ])
  1489. # Copyright (C) 2001-2021 Free Software Foundation, Inc.
  1490. #
  1491. # This file is free software; the Free Software Foundation
  1492. # gives unlimited permission to copy and/or distribute it,
  1493. # with or without modifications, as long as this notice is preserved.
  1494. # AM_PROG_INSTALL_STRIP
  1495. # ---------------------
  1496. # One issue with vendor 'install' (even GNU) is that you can't
  1497. # specify the program used to strip binaries. This is especially
  1498. # annoying in cross-compiling environments, where the build's strip
  1499. # is unlikely to handle the host's binaries.
  1500. # Fortunately install-sh will honor a STRIPPROG variable, so we
  1501. # always use install-sh in "make install-strip", and initialize
  1502. # STRIPPROG with the value of the STRIP variable (set by the user).
  1503. AC_DEFUN([AM_PROG_INSTALL_STRIP],
  1504. [AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
  1505. # Installed binaries are usually stripped using 'strip' when the user
  1506. # run "make install-strip". However 'strip' might not be the right
  1507. # tool to use in cross-compilation environments, therefore Automake
  1508. # will honor the 'STRIP' environment variable to overrule this program.
  1509. dnl Don't test for $cross_compiling = yes, because it might be 'maybe'.
  1510. if test "$cross_compiling" != no; then
  1511. AC_CHECK_TOOL([STRIP], [strip], :)
  1512. fi
  1513. INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
  1514. AC_SUBST([INSTALL_STRIP_PROGRAM])])
  1515. # Copyright (C) 2006-2021 Free Software Foundation, Inc.
  1516. #
  1517. # This file is free software; the Free Software Foundation
  1518. # gives unlimited permission to copy and/or distribute it,
  1519. # with or without modifications, as long as this notice is preserved.
  1520. # _AM_SUBST_NOTMAKE(VARIABLE)
  1521. # ---------------------------
  1522. # Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in.
  1523. # This macro is traced by Automake.
  1524. AC_DEFUN([_AM_SUBST_NOTMAKE])
  1525. # AM_SUBST_NOTMAKE(VARIABLE)
  1526. # --------------------------
  1527. # Public sister of _AM_SUBST_NOTMAKE.
  1528. AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)])
  1529. # Check how to create a tarball. -*- Autoconf -*-
  1530. # Copyright (C) 2004-2021 Free Software Foundation, Inc.
  1531. #
  1532. # This file is free software; the Free Software Foundation
  1533. # gives unlimited permission to copy and/or distribute it,
  1534. # with or without modifications, as long as this notice is preserved.
  1535. # _AM_PROG_TAR(FORMAT)
  1536. # --------------------
  1537. # Check how to create a tarball in format FORMAT.
  1538. # FORMAT should be one of 'v7', 'ustar', or 'pax'.
  1539. #
  1540. # Substitute a variable $(am__tar) that is a command
  1541. # writing to stdout a FORMAT-tarball containing the directory
  1542. # $tardir.
  1543. # tardir=directory && $(am__tar) > result.tar
  1544. #
  1545. # Substitute a variable $(am__untar) that extract such
  1546. # a tarball read from stdin.
  1547. # $(am__untar) < result.tar
  1548. #
  1549. AC_DEFUN([_AM_PROG_TAR],
  1550. [# Always define AMTAR for backward compatibility. Yes, it's still used
  1551. # in the wild :-( We should find a proper way to deprecate it ...
  1552. AC_SUBST([AMTAR], ['$${TAR-tar}'])
  1553. # We'll loop over all known methods to create a tar archive until one works.
  1554. _am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none'
  1555. m4_if([$1], [v7],
  1556. [am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'],
  1557. [m4_case([$1],
  1558. [ustar],
  1559. [# The POSIX 1988 'ustar' format is defined with fixed-size fields.
  1560. # There is notably a 21 bits limit for the UID and the GID. In fact,
  1561. # the 'pax' utility can hang on bigger UID/GID (see automake bug#8343
  1562. # and bug#13588).
  1563. am_max_uid=2097151 # 2^21 - 1
  1564. am_max_gid=$am_max_uid
  1565. # The $UID and $GID variables are not portable, so we need to resort
  1566. # to the POSIX-mandated id(1) utility. Errors in the 'id' calls
  1567. # below are definitely unexpected, so allow the users to see them
  1568. # (that is, avoid stderr redirection).
  1569. am_uid=`id -u || echo unknown`
  1570. am_gid=`id -g || echo unknown`
  1571. AC_MSG_CHECKING([whether UID '$am_uid' is supported by ustar format])
  1572. if test $am_uid -le $am_max_uid; then
  1573. AC_MSG_RESULT([yes])
  1574. else
  1575. AC_MSG_RESULT([no])
  1576. _am_tools=none
  1577. fi
  1578. AC_MSG_CHECKING([whether GID '$am_gid' is supported by ustar format])
  1579. if test $am_gid -le $am_max_gid; then
  1580. AC_MSG_RESULT([yes])
  1581. else
  1582. AC_MSG_RESULT([no])
  1583. _am_tools=none
  1584. fi],
  1585. [pax],
  1586. [],
  1587. [m4_fatal([Unknown tar format])])
  1588. AC_MSG_CHECKING([how to create a $1 tar archive])
  1589. # Go ahead even if we have the value already cached. We do so because we
  1590. # need to set the values for the 'am__tar' and 'am__untar' variables.
  1591. _am_tools=${am_cv_prog_tar_$1-$_am_tools}
  1592. for _am_tool in $_am_tools; do
  1593. case $_am_tool in
  1594. gnutar)
  1595. for _am_tar in tar gnutar gtar; do
  1596. AM_RUN_LOG([$_am_tar --version]) && break
  1597. done
  1598. am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"'
  1599. am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"'
  1600. am__untar="$_am_tar -xf -"
  1601. ;;
  1602. plaintar)
  1603. # Must skip GNU tar: if it does not support --format= it doesn't create
  1604. # ustar tarball either.
  1605. (tar --version) >/dev/null 2>&1 && continue
  1606. am__tar='tar chf - "$$tardir"'
  1607. am__tar_='tar chf - "$tardir"'
  1608. am__untar='tar xf -'
  1609. ;;
  1610. pax)
  1611. am__tar='pax -L -x $1 -w "$$tardir"'
  1612. am__tar_='pax -L -x $1 -w "$tardir"'
  1613. am__untar='pax -r'
  1614. ;;
  1615. cpio)
  1616. am__tar='find "$$tardir" -print | cpio -o -H $1 -L'
  1617. am__tar_='find "$tardir" -print | cpio -o -H $1 -L'
  1618. am__untar='cpio -i -H $1 -d'
  1619. ;;
  1620. none)
  1621. am__tar=false
  1622. am__tar_=false
  1623. am__untar=false
  1624. ;;
  1625. esac
  1626. # If the value was cached, stop now. We just wanted to have am__tar
  1627. # and am__untar set.
  1628. test -n "${am_cv_prog_tar_$1}" && break
  1629. # tar/untar a dummy directory, and stop if the command works.
  1630. rm -rf conftest.dir
  1631. mkdir conftest.dir
  1632. echo GrepMe > conftest.dir/file
  1633. AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar])
  1634. rm -rf conftest.dir
  1635. if test -s conftest.tar; then
  1636. AM_RUN_LOG([$am__untar <conftest.tar])
  1637. AM_RUN_LOG([cat conftest.dir/file])
  1638. grep GrepMe conftest.dir/file >/dev/null 2>&1 && break
  1639. fi
  1640. done
  1641. rm -rf conftest.dir
  1642. AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool])
  1643. AC_MSG_RESULT([$am_cv_prog_tar_$1])])
  1644. AC_SUBST([am__tar])
  1645. AC_SUBST([am__untar])
  1646. ]) # _AM_PROG_TAR
  1647. m4_include([m4/ac_try_compile2.m4])
  1648. m4_include([m4/libtool.m4])
  1649. m4_include([m4/ltoptions.m4])
  1650. m4_include([m4/ltsugar.m4])
  1651. m4_include([m4/ltversion.m4])
  1652. m4_include([m4/lt~obsolete.m4])