"Fossies" - the Fresh Open Source Software Archive

Member "msmtp-1.8.17/aclocal.m4" (3 Oct 2021, 177564 Bytes) of package /linux/privat/msmtp-1.8.17.tar.xz:


As a special service "Fossies" has tried to format the requested text file into HTML format (style: standard) with prefixed line numbers. Alternatively you can here view or download the uninterpreted source code file. See also the last Fossies "Diffs" side-by-side code changes report for "aclocal.m4": 1.8.15_vs_1.8.16.

    1 # generated automatically by aclocal 1.16.4 -*- Autoconf -*-
    2 
    3 # Copyright (C) 1996-2021 Free Software Foundation, Inc.
    4 
    5 # This file is free software; the Free Software Foundation
    6 # gives unlimited permission to copy and/or distribute it,
    7 # with or without modifications, as long as this notice is preserved.
    8 
    9 # This program is distributed in the hope that it will be useful,
   10 # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
   11 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
   12 # PARTICULAR PURPOSE.
   13 
   14 m4_ifndef([AC_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])])
   15 m4_ifndef([AC_AUTOCONF_VERSION],
   16   [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
   17 m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.71],,
   18 [m4_warning([this file was generated for autoconf 2.71.
   19 You have another version of autoconf.  It may work, but is not guaranteed to.
   20 If you have problems, you may need to regenerate the build system entirely.
   21 To do so, use the procedure documented by the package, typically 'autoreconf'.])])
   22 
   23 # gettext.m4 serial 71 (gettext-0.20.2)
   24 dnl Copyright (C) 1995-2014, 2016, 2018-2020 Free Software Foundation, Inc.
   25 dnl This file is free software; the Free Software Foundation
   26 dnl gives unlimited permission to copy and/or distribute it,
   27 dnl with or without modifications, as long as this notice is preserved.
   28 dnl
   29 dnl This file can be used in projects which are not available under
   30 dnl the GNU General Public License or the GNU Lesser General Public
   31 dnl License but which still want to provide support for the GNU gettext
   32 dnl functionality.
   33 dnl Please note that the actual code of the GNU gettext library is covered
   34 dnl by the GNU Lesser General Public License, and the rest of the GNU
   35 dnl gettext package is covered by the GNU General Public License.
   36 dnl They are *not* in the public domain.
   37 
   38 dnl Authors:
   39 dnl   Ulrich Drepper <drepper@cygnus.com>, 1995-2000.
   40 dnl   Bruno Haible <haible@clisp.cons.org>, 2000-2006, 2008-2010.
   41 
   42 dnl Macro to add for using GNU gettext.
   43 
   44 dnl Usage: AM_GNU_GETTEXT([INTLSYMBOL], [NEEDSYMBOL], [INTLDIR]).
   45 dnl INTLSYMBOL must be one of 'external', 'use-libtool'.
   46 dnl    INTLSYMBOL should be 'external' for packages other than GNU gettext, and
   47 dnl    'use-libtool' for the packages 'gettext-runtime' and 'gettext-tools'.
   48 dnl    If INTLSYMBOL is 'use-libtool', then a libtool library
   49 dnl    $(top_builddir)/intl/libintl.la will be created (shared and/or static,
   50 dnl    depending on --{enable,disable}-{shared,static} and on the presence of
   51 dnl    AM-DISABLE-SHARED).
   52 dnl If NEEDSYMBOL is specified and is 'need-ngettext', then GNU gettext
   53 dnl    implementations (in libc or libintl) without the ngettext() function
   54 dnl    will be ignored.  If NEEDSYMBOL is specified and is
   55 dnl    'need-formatstring-macros', then GNU gettext implementations that don't
   56 dnl    support the ISO C 99 <inttypes.h> formatstring macros will be ignored.
   57 dnl INTLDIR is used to find the intl libraries.  If empty,
   58 dnl    the value '$(top_builddir)/intl/' is used.
   59 dnl
   60 dnl The result of the configuration is one of three cases:
   61 dnl 1) GNU gettext, as included in the intl subdirectory, will be compiled
   62 dnl    and used.
   63 dnl    Catalog format: GNU --> install in $(datadir)
   64 dnl    Catalog extension: .mo after installation, .gmo in source tree
   65 dnl 2) GNU gettext has been found in the system's C library.
   66 dnl    Catalog format: GNU --> install in $(datadir)
   67 dnl    Catalog extension: .mo after installation, .gmo in source tree
   68 dnl 3) No internationalization, always use English msgid.
   69 dnl    Catalog format: none
   70 dnl    Catalog extension: none
   71 dnl If INTLSYMBOL is 'external', only cases 2 and 3 can occur.
   72 dnl The use of .gmo is historical (it was needed to avoid overwriting the
   73 dnl GNU format catalogs when building on a platform with an X/Open gettext),
   74 dnl but we keep it in order not to force irrelevant filename changes on the
   75 dnl maintainers.
   76 dnl
   77 AC_DEFUN([AM_GNU_GETTEXT],
   78 [
   79   dnl Argument checking.
   80   ifelse([$1], [], , [ifelse([$1], [external], , [ifelse([$1], [use-libtool], ,
   81     [errprint([ERROR: invalid first argument to AM_GNU_GETTEXT
   82 ])])])])
   83   ifelse(ifelse([$1], [], [old])[]ifelse([$1], [no-libtool], [old]), [old],
   84     [errprint([ERROR: Use of AM_GNU_GETTEXT without [external] argument is no longer supported.
   85 ])])
   86   ifelse([$2], [], , [ifelse([$2], [need-ngettext], , [ifelse([$2], [need-formatstring-macros], ,
   87     [errprint([ERROR: invalid second argument to AM_GNU_GETTEXT
   88 ])])])])
   89   define([gt_included_intl],
   90     ifelse([$1], [external], [no], [yes]))
   91   gt_NEEDS_INIT
   92   AM_GNU_GETTEXT_NEED([$2])
   93 
   94   AC_REQUIRE([AM_PO_SUBDIRS])dnl
   95   ifelse(gt_included_intl, yes, [
   96     AC_REQUIRE([AM_INTL_SUBDIR])dnl
   97   ])
   98 
   99   dnl Prerequisites of AC_LIB_LINKFLAGS_BODY.
  100   AC_REQUIRE([AC_LIB_PREPARE_PREFIX])
  101   AC_REQUIRE([AC_LIB_RPATH])
  102 
  103   dnl Sometimes libintl requires libiconv, so first search for libiconv.
  104   dnl Ideally we would do this search only after the
  105   dnl      if test "$USE_NLS" = "yes"; then
  106   dnl        if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" != "yes"; }; then
  107   dnl tests. But if configure.in invokes AM_ICONV after AM_GNU_GETTEXT
  108   dnl the configure script would need to contain the same shell code
  109   dnl again, outside any 'if'. There are two solutions:
  110   dnl - Invoke AM_ICONV_LINKFLAGS_BODY here, outside any 'if'.
  111   dnl - Control the expansions in more detail using AC_PROVIDE_IFELSE.
  112   dnl Since AC_PROVIDE_IFELSE is not documented, we avoid it.
  113   ifelse(gt_included_intl, yes, , [
  114     AC_REQUIRE([AM_ICONV_LINKFLAGS_BODY])
  115   ])
  116 
  117   dnl Sometimes, on Mac OS X, libintl requires linking with CoreFoundation.
  118   gt_INTL_MACOSX
  119 
  120   dnl Set USE_NLS.
  121   AC_REQUIRE([AM_NLS])
  122 
  123   ifelse(gt_included_intl, yes, [
  124     BUILD_INCLUDED_LIBINTL=no
  125     USE_INCLUDED_LIBINTL=no
  126   ])
  127   LIBINTL=
  128   LTLIBINTL=
  129   POSUB=
  130 
  131   dnl Add a version number to the cache macros.
  132   case " $gt_needs " in
  133     *" need-formatstring-macros "*) gt_api_version=3 ;;
  134     *" need-ngettext "*) gt_api_version=2 ;;
  135     *) gt_api_version=1 ;;
  136   esac
  137   gt_func_gnugettext_libc="gt_cv_func_gnugettext${gt_api_version}_libc"
  138   gt_func_gnugettext_libintl="gt_cv_func_gnugettext${gt_api_version}_libintl"
  139 
  140   dnl If we use NLS figure out what method
  141   if test "$USE_NLS" = "yes"; then
  142     gt_use_preinstalled_gnugettext=no
  143     ifelse(gt_included_intl, yes, [
  144       AC_MSG_CHECKING([whether included gettext is requested])
  145       AC_ARG_WITH([included-gettext],
  146         [  --with-included-gettext use the GNU gettext library included here],
  147         nls_cv_force_use_gnu_gettext=$withval,
  148         nls_cv_force_use_gnu_gettext=no)
  149       AC_MSG_RESULT([$nls_cv_force_use_gnu_gettext])
  150 
  151       nls_cv_use_gnu_gettext="$nls_cv_force_use_gnu_gettext"
  152       if test "$nls_cv_force_use_gnu_gettext" != "yes"; then
  153     ])
  154         dnl User does not insist on using GNU NLS library.  Figure out what
  155         dnl to use.  If GNU gettext is available we use this.  Else we have
  156         dnl to fall back to GNU NLS library.
  157 
  158         if test $gt_api_version -ge 3; then
  159           gt_revision_test_code='
  160 #ifndef __GNU_GETTEXT_SUPPORTED_REVISION
  161 #define __GNU_GETTEXT_SUPPORTED_REVISION(major) ((major) == 0 ? 0 : -1)
  162 #endif
  163 changequote(,)dnl
  164 typedef int array [2 * (__GNU_GETTEXT_SUPPORTED_REVISION(0) >= 1) - 1];
  165 changequote([,])dnl
  166 '
  167         else
  168           gt_revision_test_code=
  169         fi
  170         if test $gt_api_version -ge 2; then
  171           gt_expression_test_code=' + * ngettext ("", "", 0)'
  172         else
  173           gt_expression_test_code=
  174         fi
  175 
  176         AC_CACHE_CHECK([for GNU gettext in libc], [$gt_func_gnugettext_libc],
  177          [AC_LINK_IFELSE(
  178             [AC_LANG_PROGRAM(
  179                [[
  180 #include <libintl.h>
  181 #ifndef __GNU_GETTEXT_SUPPORTED_REVISION
  182 extern int _nl_msg_cat_cntr;
  183 extern int *_nl_domain_bindings;
  184 #define __GNU_GETTEXT_SYMBOL_EXPRESSION (_nl_msg_cat_cntr + *_nl_domain_bindings)
  185 #else
  186 #define __GNU_GETTEXT_SYMBOL_EXPRESSION 0
  187 #endif
  188 $gt_revision_test_code
  189                ]],
  190                [[
  191 bindtextdomain ("", "");
  192 return * gettext ("")$gt_expression_test_code + __GNU_GETTEXT_SYMBOL_EXPRESSION
  193                ]])],
  194             [eval "$gt_func_gnugettext_libc=yes"],
  195             [eval "$gt_func_gnugettext_libc=no"])])
  196 
  197         if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" != "yes"; }; then
  198           dnl Sometimes libintl requires libiconv, so first search for libiconv.
  199           ifelse(gt_included_intl, yes, , [
  200             AM_ICONV_LINK
  201           ])
  202           dnl Search for libintl and define LIBINTL, LTLIBINTL and INCINTL
  203           dnl accordingly. Don't use AC_LIB_LINKFLAGS_BODY([intl],[iconv])
  204           dnl because that would add "-liconv" to LIBINTL and LTLIBINTL
  205           dnl even if libiconv doesn't exist.
  206           AC_LIB_LINKFLAGS_BODY([intl])
  207           AC_CACHE_CHECK([for GNU gettext in libintl],
  208             [$gt_func_gnugettext_libintl],
  209            [gt_save_CPPFLAGS="$CPPFLAGS"
  210             CPPFLAGS="$CPPFLAGS $INCINTL"
  211             gt_save_LIBS="$LIBS"
  212             LIBS="$LIBS $LIBINTL"
  213             dnl Now see whether libintl exists and does not depend on libiconv.
  214             AC_LINK_IFELSE(
  215               [AC_LANG_PROGRAM(
  216                  [[
  217 #include <libintl.h>
  218 #ifndef __GNU_GETTEXT_SUPPORTED_REVISION
  219 extern int _nl_msg_cat_cntr;
  220 extern
  221 #ifdef __cplusplus
  222 "C"
  223 #endif
  224 const char *_nl_expand_alias (const char *);
  225 #define __GNU_GETTEXT_SYMBOL_EXPRESSION (_nl_msg_cat_cntr + *_nl_expand_alias (""))
  226 #else
  227 #define __GNU_GETTEXT_SYMBOL_EXPRESSION 0
  228 #endif
  229 $gt_revision_test_code
  230                  ]],
  231                  [[
  232 bindtextdomain ("", "");
  233 return * gettext ("")$gt_expression_test_code + __GNU_GETTEXT_SYMBOL_EXPRESSION
  234                  ]])],
  235               [eval "$gt_func_gnugettext_libintl=yes"],
  236               [eval "$gt_func_gnugettext_libintl=no"])
  237             dnl Now see whether libintl exists and depends on libiconv.
  238             if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" != yes; } && test -n "$LIBICONV"; then
  239               LIBS="$LIBS $LIBICONV"
  240               AC_LINK_IFELSE(
  241                 [AC_LANG_PROGRAM(
  242                    [[
  243 #include <libintl.h>
  244 #ifndef __GNU_GETTEXT_SUPPORTED_REVISION
  245 extern int _nl_msg_cat_cntr;
  246 extern
  247 #ifdef __cplusplus
  248 "C"
  249 #endif
  250 const char *_nl_expand_alias (const char *);
  251 #define __GNU_GETTEXT_SYMBOL_EXPRESSION (_nl_msg_cat_cntr + *_nl_expand_alias (""))
  252 #else
  253 #define __GNU_GETTEXT_SYMBOL_EXPRESSION 0
  254 #endif
  255 $gt_revision_test_code
  256                    ]],
  257                    [[
  258 bindtextdomain ("", "");
  259 return * gettext ("")$gt_expression_test_code + __GNU_GETTEXT_SYMBOL_EXPRESSION
  260                    ]])],
  261                 [LIBINTL="$LIBINTL $LIBICONV"
  262                  LTLIBINTL="$LTLIBINTL $LTLIBICONV"
  263                  eval "$gt_func_gnugettext_libintl=yes"
  264                 ])
  265             fi
  266             CPPFLAGS="$gt_save_CPPFLAGS"
  267             LIBS="$gt_save_LIBS"])
  268         fi
  269 
  270         dnl If an already present or preinstalled GNU gettext() is found,
  271         dnl use it.  But if this macro is used in GNU gettext, and GNU
  272         dnl gettext is already preinstalled in libintl, we update this
  273         dnl libintl.  (Cf. the install rule in intl/Makefile.in.)
  274         if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" = "yes"; } \
  275            || { { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; } \
  276                 && test "$PACKAGE" != gettext-runtime \
  277                 && test "$PACKAGE" != gettext-tools; }; then
  278           gt_use_preinstalled_gnugettext=yes
  279         else
  280           dnl Reset the values set by searching for libintl.
  281           LIBINTL=
  282           LTLIBINTL=
  283           INCINTL=
  284         fi
  285 
  286     ifelse(gt_included_intl, yes, [
  287         if test "$gt_use_preinstalled_gnugettext" != "yes"; then
  288           dnl GNU gettext is not found in the C library.
  289           dnl Fall back on included GNU gettext library.
  290           nls_cv_use_gnu_gettext=yes
  291         fi
  292       fi
  293 
  294       if test "$nls_cv_use_gnu_gettext" = "yes"; then
  295         dnl Mark actions used to generate GNU NLS library.
  296         BUILD_INCLUDED_LIBINTL=yes
  297         USE_INCLUDED_LIBINTL=yes
  298         LIBINTL="ifelse([$3],[],\${top_builddir}/intl,[$3])/libintl.la $LIBICONV $LIBTHREAD"
  299         LTLIBINTL="ifelse([$3],[],\${top_builddir}/intl,[$3])/libintl.la $LTLIBICONV $LTLIBTHREAD"
  300         LIBS=`echo " $LIBS " | sed -e 's/ -lintl / /' -e 's/^ //' -e 's/ $//'`
  301       fi
  302 
  303       CATOBJEXT=
  304       if test "$gt_use_preinstalled_gnugettext" = "yes" \
  305          || test "$nls_cv_use_gnu_gettext" = "yes"; then
  306         dnl Mark actions to use GNU gettext tools.
  307         CATOBJEXT=.gmo
  308       fi
  309     ])
  310 
  311     if test -n "$INTL_MACOSX_LIBS"; then
  312       if test "$gt_use_preinstalled_gnugettext" = "yes" \
  313          || test "$nls_cv_use_gnu_gettext" = "yes"; then
  314         dnl Some extra flags are needed during linking.
  315         LIBINTL="$LIBINTL $INTL_MACOSX_LIBS"
  316         LTLIBINTL="$LTLIBINTL $INTL_MACOSX_LIBS"
  317       fi
  318     fi
  319 
  320     if test "$gt_use_preinstalled_gnugettext" = "yes" \
  321        || test "$nls_cv_use_gnu_gettext" = "yes"; then
  322       AC_DEFINE([ENABLE_NLS], [1],
  323         [Define to 1 if translation of program messages to the user's native language
  324    is requested.])
  325     else
  326       USE_NLS=no
  327     fi
  328   fi
  329 
  330   AC_MSG_CHECKING([whether to use NLS])
  331   AC_MSG_RESULT([$USE_NLS])
  332   if test "$USE_NLS" = "yes"; then
  333     AC_MSG_CHECKING([where the gettext function comes from])
  334     if test "$gt_use_preinstalled_gnugettext" = "yes"; then
  335       if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then
  336         gt_source="external libintl"
  337       else
  338         gt_source="libc"
  339       fi
  340     else
  341       gt_source="included intl directory"
  342     fi
  343     AC_MSG_RESULT([$gt_source])
  344   fi
  345 
  346   if test "$USE_NLS" = "yes"; then
  347 
  348     if test "$gt_use_preinstalled_gnugettext" = "yes"; then
  349       if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then
  350         AC_MSG_CHECKING([how to link with libintl])
  351         AC_MSG_RESULT([$LIBINTL])
  352         AC_LIB_APPENDTOVAR([CPPFLAGS], [$INCINTL])
  353       fi
  354 
  355       dnl For backward compatibility. Some packages may be using this.
  356       AC_DEFINE([HAVE_GETTEXT], [1],
  357        [Define if the GNU gettext() function is already present or preinstalled.])
  358       AC_DEFINE([HAVE_DCGETTEXT], [1],
  359        [Define if the GNU dcgettext() function is already present or preinstalled.])
  360     fi
  361 
  362     dnl We need to process the po/ directory.
  363     POSUB=po
  364   fi
  365 
  366   ifelse(gt_included_intl, yes, [
  367     dnl In GNU gettext we have to set BUILD_INCLUDED_LIBINTL to 'yes'
  368     dnl because some of the testsuite requires it.
  369     BUILD_INCLUDED_LIBINTL=yes
  370 
  371     dnl Make all variables we use known to autoconf.
  372     AC_SUBST([BUILD_INCLUDED_LIBINTL])
  373     AC_SUBST([USE_INCLUDED_LIBINTL])
  374     AC_SUBST([CATOBJEXT])
  375   ])
  376 
  377   dnl For backward compatibility. Some Makefiles may be using this.
  378   INTLLIBS="$LIBINTL"
  379   AC_SUBST([INTLLIBS])
  380 
  381   dnl Make all documented variables known to autoconf.
  382   AC_SUBST([LIBINTL])
  383   AC_SUBST([LTLIBINTL])
  384   AC_SUBST([POSUB])
  385 ])
  386 
  387 
  388 dnl gt_NEEDS_INIT ensures that the gt_needs variable is initialized.
  389 m4_define([gt_NEEDS_INIT],
  390 [
  391   m4_divert_text([DEFAULTS], [gt_needs=])
  392   m4_define([gt_NEEDS_INIT], [])
  393 ])
  394 
  395 
  396 dnl Usage: AM_GNU_GETTEXT_NEED([NEEDSYMBOL])
  397 AC_DEFUN([AM_GNU_GETTEXT_NEED],
  398 [
  399   m4_divert_text([INIT_PREPARE], [gt_needs="$gt_needs $1"])
  400 ])
  401 
  402 
  403 dnl Usage: AM_GNU_GETTEXT_VERSION([gettext-version])
  404 AC_DEFUN([AM_GNU_GETTEXT_VERSION], [])
  405 
  406 
  407 dnl Usage: AM_GNU_GETTEXT_REQUIRE_VERSION([gettext-version])
  408 AC_DEFUN([AM_GNU_GETTEXT_REQUIRE_VERSION], [])
  409 
  410 # host-cpu-c-abi.m4 serial 13
  411 dnl Copyright (C) 2002-2020 Free Software Foundation, Inc.
  412 dnl This file is free software; the Free Software Foundation
  413 dnl gives unlimited permission to copy and/or distribute it,
  414 dnl with or without modifications, as long as this notice is preserved.
  415 
  416 dnl From Bruno Haible and Sam Steingold.
  417 
  418 dnl Sets the HOST_CPU variable to the canonical name of the CPU.
  419 dnl Sets the HOST_CPU_C_ABI variable to the canonical name of the CPU with its
  420 dnl C language ABI (application binary interface).
  421 dnl Also defines __${HOST_CPU}__ and __${HOST_CPU_C_ABI}__ as C macros in
  422 dnl config.h.
  423 dnl
  424 dnl This canonical name can be used to select a particular assembly language
  425 dnl source file that will interoperate with C code on the given host.
  426 dnl
  427 dnl For example:
  428 dnl * 'i386' and 'sparc' are different canonical names, because code for i386
  429 dnl   will not run on SPARC CPUs and vice versa. They have different
  430 dnl   instruction sets.
  431 dnl * 'sparc' and 'sparc64' are different canonical names, because code for
  432 dnl   'sparc' and code for 'sparc64' cannot be linked together: 'sparc' code
  433 dnl   contains 32-bit instructions, whereas 'sparc64' code contains 64-bit
  434 dnl   instructions. A process on a SPARC CPU can be in 32-bit mode or in 64-bit
  435 dnl   mode, but not both.
  436 dnl * 'mips' and 'mipsn32' are different canonical names, because they use
  437 dnl   different argument passing and return conventions for C functions, and
  438 dnl   although the instruction set of 'mips' is a large subset of the
  439 dnl   instruction set of 'mipsn32'.
  440 dnl * 'mipsn32' and 'mips64' are different canonical names, because they use
  441 dnl   different sizes for the C types like 'int' and 'void *', and although
  442 dnl   the instruction sets of 'mipsn32' and 'mips64' are the same.
  443 dnl * The same canonical name is used for different endiannesses. You can
  444 dnl   determine the endianness through preprocessor symbols:
  445 dnl   - 'arm': test __ARMEL__.
  446 dnl   - 'mips', 'mipsn32', 'mips64': test _MIPSEB vs. _MIPSEL.
  447 dnl   - 'powerpc64': test _BIG_ENDIAN vs. _LITTLE_ENDIAN.
  448 dnl * The same name 'i386' is used for CPUs of type i386, i486, i586
  449 dnl   (Pentium), AMD K7, Pentium II, Pentium IV, etc., because
  450 dnl   - Instructions that do not exist on all of these CPUs (cmpxchg,
  451 dnl     MMX, SSE, SSE2, 3DNow! etc.) are not frequently used. If your
  452 dnl     assembly language source files use such instructions, you will
  453 dnl     need to make the distinction.
  454 dnl   - Speed of execution of the common instruction set is reasonable across
  455 dnl     the entire family of CPUs. If you have assembly language source files
  456 dnl     that are optimized for particular CPU types (like GNU gmp has), you
  457 dnl     will need to make the distinction.
  458 dnl   See <https://en.wikipedia.org/wiki/X86_instruction_listings>.
  459 AC_DEFUN([gl_HOST_CPU_C_ABI],
  460 [
  461   AC_REQUIRE([AC_CANONICAL_HOST])
  462   AC_REQUIRE([gl_C_ASM])
  463   AC_CACHE_CHECK([host CPU and C ABI], [gl_cv_host_cpu_c_abi],
  464     [case "$host_cpu" in
  465 
  466 changequote(,)dnl
  467        i[34567]86 )
  468 changequote([,])dnl
  469          gl_cv_host_cpu_c_abi=i386
  470          ;;
  471 
  472        x86_64 )
  473          # On x86_64 systems, the C compiler may be generating code in one of
  474          # these ABIs:
  475          # - 64-bit instruction set, 64-bit pointers, 64-bit 'long': x86_64.
  476          # - 64-bit instruction set, 64-bit pointers, 32-bit 'long': x86_64
  477          #   with native Windows (mingw, MSVC).
  478          # - 64-bit instruction set, 32-bit pointers, 32-bit 'long': x86_64-x32.
  479          # - 32-bit instruction set, 32-bit pointers, 32-bit 'long': i386.
  480          AC_COMPILE_IFELSE(
  481            [AC_LANG_SOURCE(
  482               [[#if (defined __x86_64__ || defined __amd64__ \
  483                      || defined _M_X64 || defined _M_AMD64)
  484                  int ok;
  485                 #else
  486                  error fail
  487                 #endif
  488               ]])],
  489            [AC_COMPILE_IFELSE(
  490               [AC_LANG_SOURCE(
  491                  [[#if defined __ILP32__ || defined _ILP32
  492                     int ok;
  493                    #else
  494                     error fail
  495                    #endif
  496                  ]])],
  497               [gl_cv_host_cpu_c_abi=x86_64-x32],
  498               [gl_cv_host_cpu_c_abi=x86_64])],
  499            [gl_cv_host_cpu_c_abi=i386])
  500          ;;
  501 
  502 changequote(,)dnl
  503        alphaev[4-8] | alphaev56 | alphapca5[67] | alphaev6[78] )
  504 changequote([,])dnl
  505          gl_cv_host_cpu_c_abi=alpha
  506          ;;
  507 
  508        arm* | aarch64 )
  509          # Assume arm with EABI.
  510          # On arm64 systems, the C compiler may be generating code in one of
  511          # these ABIs:
  512          # - aarch64 instruction set, 64-bit pointers, 64-bit 'long': arm64.
  513          # - aarch64 instruction set, 32-bit pointers, 32-bit 'long': arm64-ilp32.
  514          # - 32-bit instruction set, 32-bit pointers, 32-bit 'long': arm or armhf.
  515          AC_COMPILE_IFELSE(
  516            [AC_LANG_SOURCE(
  517               [[#ifdef __aarch64__
  518                  int ok;
  519                 #else
  520                  error fail
  521                 #endif
  522               ]])],
  523            [AC_COMPILE_IFELSE(
  524               [AC_LANG_SOURCE(
  525                 [[#if defined __ILP32__ || defined _ILP32
  526                    int ok;
  527                   #else
  528                    error fail
  529                   #endif
  530                 ]])],
  531               [gl_cv_host_cpu_c_abi=arm64-ilp32],
  532               [gl_cv_host_cpu_c_abi=arm64])],
  533            [# Don't distinguish little-endian and big-endian arm, since they
  534             # don't require different machine code for simple operations and
  535             # since the user can distinguish them through the preprocessor
  536             # defines __ARMEL__ vs. __ARMEB__.
  537             # But distinguish arm which passes floating-point arguments and
  538             # return values in integer registers (r0, r1, ...) - this is
  539             # gcc -mfloat-abi=soft or gcc -mfloat-abi=softfp - from arm which
  540             # passes them in float registers (s0, s1, ...) and double registers
  541             # (d0, d1, ...) - this is gcc -mfloat-abi=hard. GCC 4.6 or newer
  542             # sets the preprocessor defines __ARM_PCS (for the first case) and
  543             # __ARM_PCS_VFP (for the second case), but older GCC does not.
  544             echo 'double ddd; void func (double dd) { ddd = dd; }' > conftest.c
  545             # Look for a reference to the register d0 in the .s file.
  546             AC_TRY_COMMAND(${CC-cc} $CFLAGS $CPPFLAGS $gl_c_asm_opt conftest.c) >/dev/null 2>&1
  547             if LC_ALL=C grep 'd0,' conftest.$gl_asmext >/dev/null; then
  548               gl_cv_host_cpu_c_abi=armhf
  549             else
  550               gl_cv_host_cpu_c_abi=arm
  551             fi
  552             rm -f conftest*
  553            ])
  554          ;;
  555 
  556        hppa1.0 | hppa1.1 | hppa2.0* | hppa64 )
  557          # On hppa, the C compiler may be generating 32-bit code or 64-bit
  558          # code. In the latter case, it defines _LP64 and __LP64__.
  559          AC_COMPILE_IFELSE(
  560            [AC_LANG_SOURCE(
  561               [[#ifdef __LP64__
  562                  int ok;
  563                 #else
  564                  error fail
  565                 #endif
  566               ]])],
  567            [gl_cv_host_cpu_c_abi=hppa64],
  568            [gl_cv_host_cpu_c_abi=hppa])
  569          ;;
  570 
  571        ia64* )
  572          # On ia64 on HP-UX, the C compiler may be generating 64-bit code or
  573          # 32-bit code. In the latter case, it defines _ILP32.
  574          AC_COMPILE_IFELSE(
  575            [AC_LANG_SOURCE(
  576               [[#ifdef _ILP32
  577                  int ok;
  578                 #else
  579                  error fail
  580                 #endif
  581               ]])],
  582            [gl_cv_host_cpu_c_abi=ia64-ilp32],
  583            [gl_cv_host_cpu_c_abi=ia64])
  584          ;;
  585 
  586        mips* )
  587          # We should also check for (_MIPS_SZPTR == 64), but gcc keeps this
  588          # at 32.
  589          AC_COMPILE_IFELSE(
  590            [AC_LANG_SOURCE(
  591               [[#if defined _MIPS_SZLONG && (_MIPS_SZLONG == 64)
  592                  int ok;
  593                 #else
  594                  error fail
  595                 #endif
  596               ]])],
  597            [gl_cv_host_cpu_c_abi=mips64],
  598            [# In the n32 ABI, _ABIN32 is defined, _ABIO32 is not defined (but
  599             # may later get defined by <sgidefs.h>), and _MIPS_SIM == _ABIN32.
  600             # In the 32 ABI, _ABIO32 is defined, _ABIN32 is not defined (but
  601             # may later get defined by <sgidefs.h>), and _MIPS_SIM == _ABIO32.
  602             AC_COMPILE_IFELSE(
  603               [AC_LANG_SOURCE(
  604                  [[#if (_MIPS_SIM == _ABIN32)
  605                     int ok;
  606                    #else
  607                     error fail
  608                    #endif
  609                  ]])],
  610               [gl_cv_host_cpu_c_abi=mipsn32],
  611               [gl_cv_host_cpu_c_abi=mips])])
  612          ;;
  613 
  614        powerpc* )
  615          # Different ABIs are in use on AIX vs. Mac OS X vs. Linux,*BSD.
  616          # No need to distinguish them here; the caller may distinguish
  617          # them based on the OS.
  618          # On powerpc64 systems, the C compiler may still be generating
  619          # 32-bit code. And on powerpc-ibm-aix systems, the C compiler may
  620          # be generating 64-bit code.
  621          AC_COMPILE_IFELSE(
  622            [AC_LANG_SOURCE(
  623               [[#if defined __powerpc64__ || defined _ARCH_PPC64
  624                  int ok;
  625                 #else
  626                  error fail
  627                 #endif
  628               ]])],
  629            [# On powerpc64, there are two ABIs on Linux: The AIX compatible
  630             # one and the ELFv2 one. The latter defines _CALL_ELF=2.
  631             AC_COMPILE_IFELSE(
  632               [AC_LANG_SOURCE(
  633                  [[#if defined _CALL_ELF && _CALL_ELF == 2
  634                     int ok;
  635                    #else
  636                     error fail
  637                    #endif
  638                  ]])],
  639               [gl_cv_host_cpu_c_abi=powerpc64-elfv2],
  640               [gl_cv_host_cpu_c_abi=powerpc64])
  641            ],
  642            [gl_cv_host_cpu_c_abi=powerpc])
  643          ;;
  644 
  645        rs6000 )
  646          gl_cv_host_cpu_c_abi=powerpc
  647          ;;
  648 
  649        riscv32 | riscv64 )
  650          # There are 2 architectures (with variants): rv32* and rv64*.
  651          AC_COMPILE_IFELSE(
  652            [AC_LANG_SOURCE(
  653               [[#if __riscv_xlen == 64
  654                   int ok;
  655                 #else
  656                   error fail
  657                 #endif
  658               ]])],
  659            [cpu=riscv64],
  660            [cpu=riscv32])
  661          # There are 6 ABIs: ilp32, ilp32f, ilp32d, lp64, lp64f, lp64d.
  662          # Size of 'long' and 'void *':
  663          AC_COMPILE_IFELSE(
  664            [AC_LANG_SOURCE(
  665               [[#if defined __LP64__
  666                   int ok;
  667                 #else
  668                   error fail
  669                 #endif
  670               ]])],
  671            [main_abi=lp64],
  672            [main_abi=ilp32])
  673          # Float ABIs:
  674          # __riscv_float_abi_double:
  675          #   'float' and 'double' are passed in floating-point registers.
  676          # __riscv_float_abi_single:
  677          #   'float' are passed in floating-point registers.
  678          # __riscv_float_abi_soft:
  679          #   No values are passed in floating-point registers.
  680          AC_COMPILE_IFELSE(
  681            [AC_LANG_SOURCE(
  682               [[#if defined __riscv_float_abi_double
  683                   int ok;
  684                 #else
  685                   error fail
  686                 #endif
  687               ]])],
  688            [float_abi=d],
  689            [AC_COMPILE_IFELSE(
  690               [AC_LANG_SOURCE(
  691                  [[#if defined __riscv_float_abi_single
  692                      int ok;
  693                    #else
  694                      error fail
  695                    #endif
  696                  ]])],
  697               [float_abi=f],
  698               [float_abi=''])
  699            ])
  700          gl_cv_host_cpu_c_abi="${cpu}-${main_abi}${float_abi}"
  701          ;;
  702 
  703        s390* )
  704          # On s390x, the C compiler may be generating 64-bit (= s390x) code
  705          # or 31-bit (= s390) code.
  706          AC_COMPILE_IFELSE(
  707            [AC_LANG_SOURCE(
  708               [[#if defined __LP64__ || defined __s390x__
  709                   int ok;
  710                 #else
  711                   error fail
  712                 #endif
  713               ]])],
  714            [gl_cv_host_cpu_c_abi=s390x],
  715            [gl_cv_host_cpu_c_abi=s390])
  716          ;;
  717 
  718        sparc | sparc64 )
  719          # UltraSPARCs running Linux have `uname -m` = "sparc64", but the
  720          # C compiler still generates 32-bit code.
  721          AC_COMPILE_IFELSE(
  722            [AC_LANG_SOURCE(
  723               [[#if defined __sparcv9 || defined __arch64__
  724                  int ok;
  725                 #else
  726                  error fail
  727                 #endif
  728               ]])],
  729            [gl_cv_host_cpu_c_abi=sparc64],
  730            [gl_cv_host_cpu_c_abi=sparc])
  731          ;;
  732 
  733        *)
  734          gl_cv_host_cpu_c_abi="$host_cpu"
  735          ;;
  736      esac
  737     ])
  738 
  739   dnl In most cases, $HOST_CPU and $HOST_CPU_C_ABI are the same.
  740   HOST_CPU=`echo "$gl_cv_host_cpu_c_abi" | sed -e 's/-.*//'`
  741   HOST_CPU_C_ABI="$gl_cv_host_cpu_c_abi"
  742   AC_SUBST([HOST_CPU])
  743   AC_SUBST([HOST_CPU_C_ABI])
  744 
  745   # This was
  746   #   AC_DEFINE_UNQUOTED([__${HOST_CPU}__])
  747   #   AC_DEFINE_UNQUOTED([__${HOST_CPU_C_ABI}__])
  748   # earlier, but KAI C++ 3.2d doesn't like this.
  749   sed -e 's/-/_/g' >> confdefs.h <<EOF
  750 #ifndef __${HOST_CPU}__
  751 #define __${HOST_CPU}__ 1
  752 #endif
  753 #ifndef __${HOST_CPU_C_ABI}__
  754 #define __${HOST_CPU_C_ABI}__ 1
  755 #endif
  756 EOF
  757   AH_TOP([/* CPU and C ABI indicator */
  758 #ifndef __i386__
  759 #undef __i386__
  760 #endif
  761 #ifndef __x86_64_x32__
  762 #undef __x86_64_x32__
  763 #endif
  764 #ifndef __x86_64__
  765 #undef __x86_64__
  766 #endif
  767 #ifndef __alpha__
  768 #undef __alpha__
  769 #endif
  770 #ifndef __arm__
  771 #undef __arm__
  772 #endif
  773 #ifndef __armhf__
  774 #undef __armhf__
  775 #endif
  776 #ifndef __arm64_ilp32__
  777 #undef __arm64_ilp32__
  778 #endif
  779 #ifndef __arm64__
  780 #undef __arm64__
  781 #endif
  782 #ifndef __hppa__
  783 #undef __hppa__
  784 #endif
  785 #ifndef __hppa64__
  786 #undef __hppa64__
  787 #endif
  788 #ifndef __ia64_ilp32__
  789 #undef __ia64_ilp32__
  790 #endif
  791 #ifndef __ia64__
  792 #undef __ia64__
  793 #endif
  794 #ifndef __m68k__
  795 #undef __m68k__
  796 #endif
  797 #ifndef __mips__
  798 #undef __mips__
  799 #endif
  800 #ifndef __mipsn32__
  801 #undef __mipsn32__
  802 #endif
  803 #ifndef __mips64__
  804 #undef __mips64__
  805 #endif
  806 #ifndef __powerpc__
  807 #undef __powerpc__
  808 #endif
  809 #ifndef __powerpc64__
  810 #undef __powerpc64__
  811 #endif
  812 #ifndef __powerpc64_elfv2__
  813 #undef __powerpc64_elfv2__
  814 #endif
  815 #ifndef __riscv32__
  816 #undef __riscv32__
  817 #endif
  818 #ifndef __riscv64__
  819 #undef __riscv64__
  820 #endif
  821 #ifndef __riscv32_ilp32__
  822 #undef __riscv32_ilp32__
  823 #endif
  824 #ifndef __riscv32_ilp32f__
  825 #undef __riscv32_ilp32f__
  826 #endif
  827 #ifndef __riscv32_ilp32d__
  828 #undef __riscv32_ilp32d__
  829 #endif
  830 #ifndef __riscv64_ilp32__
  831 #undef __riscv64_ilp32__
  832 #endif
  833 #ifndef __riscv64_ilp32f__
  834 #undef __riscv64_ilp32f__
  835 #endif
  836 #ifndef __riscv64_ilp32d__
  837 #undef __riscv64_ilp32d__
  838 #endif
  839 #ifndef __riscv64_lp64__
  840 #undef __riscv64_lp64__
  841 #endif
  842 #ifndef __riscv64_lp64f__
  843 #undef __riscv64_lp64f__
  844 #endif
  845 #ifndef __riscv64_lp64d__
  846 #undef __riscv64_lp64d__
  847 #endif
  848 #ifndef __s390__
  849 #undef __s390__
  850 #endif
  851 #ifndef __s390x__
  852 #undef __s390x__
  853 #endif
  854 #ifndef __sh__
  855 #undef __sh__
  856 #endif
  857 #ifndef __sparc__
  858 #undef __sparc__
  859 #endif
  860 #ifndef __sparc64__
  861 #undef __sparc64__
  862 #endif
  863 ])
  864 
  865 ])
  866 
  867 
  868 dnl Sets the HOST_CPU_C_ABI_32BIT variable to 'yes' if the C language ABI
  869 dnl (application binary interface) is a 32-bit one, to 'no' if it is a 64-bit
  870 dnl one, or to 'unknown' if unknown.
  871 dnl This is a simplified variant of gl_HOST_CPU_C_ABI.
  872 AC_DEFUN([gl_HOST_CPU_C_ABI_32BIT],
  873 [
  874   AC_REQUIRE([AC_CANONICAL_HOST])
  875   AC_CACHE_CHECK([32-bit host C ABI], [gl_cv_host_cpu_c_abi_32bit],
  876     [if test -n "$gl_cv_host_cpu_c_abi"; then
  877        case "$gl_cv_host_cpu_c_abi" in
  878          i386 | x86_64-x32 | arm | armhf | arm64-ilp32 | hppa | ia64-ilp32 | mips | mipsn32 | powerpc | riscv*-ilp32* | s390 | sparc)
  879            gl_cv_host_cpu_c_abi_32bit=yes ;;
  880          x86_64 | alpha | arm64 | hppa64 | ia64 | mips64 | powerpc64 | powerpc64-elfv2 | riscv*-lp64* | s390x | sparc64 )
  881            gl_cv_host_cpu_c_abi_32bit=no ;;
  882          *)
  883            gl_cv_host_cpu_c_abi_32bit=unknown ;;
  884        esac
  885      else
  886        case "$host_cpu" in
  887 
  888          # CPUs that only support a 32-bit ABI.
  889          arc \
  890          | bfin \
  891          | cris* \
  892          | csky \
  893          | epiphany \
  894          | ft32 \
  895          | h8300 \
  896          | m68k \
  897          | microblaze | microblazeel \
  898          | nds32 | nds32le | nds32be \
  899          | nios2 | nios2eb | nios2el \
  900          | or1k* \
  901          | or32 \
  902          | sh | sh[1234] | sh[1234]e[lb] \
  903          | tic6x \
  904          | xtensa* )
  905            gl_cv_host_cpu_c_abi_32bit=yes
  906            ;;
  907 
  908          # CPUs that only support a 64-bit ABI.
  909 changequote(,)dnl
  910          alpha | alphaev[4-8] | alphaev56 | alphapca5[67] | alphaev6[78] \
  911          | mmix )
  912 changequote([,])dnl
  913            gl_cv_host_cpu_c_abi_32bit=no
  914            ;;
  915 
  916 changequote(,)dnl
  917          i[34567]86 )
  918 changequote([,])dnl
  919            gl_cv_host_cpu_c_abi_32bit=yes
  920            ;;
  921 
  922          x86_64 )
  923            # On x86_64 systems, the C compiler may be generating code in one of
  924            # these ABIs:
  925            # - 64-bit instruction set, 64-bit pointers, 64-bit 'long': x86_64.
  926            # - 64-bit instruction set, 64-bit pointers, 32-bit 'long': x86_64
  927            #   with native Windows (mingw, MSVC).
  928            # - 64-bit instruction set, 32-bit pointers, 32-bit 'long': x86_64-x32.
  929            # - 32-bit instruction set, 32-bit pointers, 32-bit 'long': i386.
  930            AC_COMPILE_IFELSE(
  931              [AC_LANG_SOURCE(
  932                 [[#if (defined __x86_64__ || defined __amd64__ \
  933                        || defined _M_X64 || defined _M_AMD64) \
  934                       && !(defined __ILP32__ || defined _ILP32)
  935                    int ok;
  936                   #else
  937                    error fail
  938                   #endif
  939                 ]])],
  940              [gl_cv_host_cpu_c_abi_32bit=no],
  941              [gl_cv_host_cpu_c_abi_32bit=yes])
  942            ;;
  943 
  944          arm* | aarch64 )
  945            # Assume arm with EABI.
  946            # On arm64 systems, the C compiler may be generating code in one of
  947            # these ABIs:
  948            # - aarch64 instruction set, 64-bit pointers, 64-bit 'long': arm64.
  949            # - aarch64 instruction set, 32-bit pointers, 32-bit 'long': arm64-ilp32.
  950            # - 32-bit instruction set, 32-bit pointers, 32-bit 'long': arm or armhf.
  951            AC_COMPILE_IFELSE(
  952              [AC_LANG_SOURCE(
  953                 [[#if defined __aarch64__ && !(defined __ILP32__ || defined _ILP32)
  954                    int ok;
  955                   #else
  956                    error fail
  957                   #endif
  958                 ]])],
  959              [gl_cv_host_cpu_c_abi_32bit=no],
  960              [gl_cv_host_cpu_c_abi_32bit=yes])
  961            ;;
  962 
  963          hppa1.0 | hppa1.1 | hppa2.0* | hppa64 )
  964            # On hppa, the C compiler may be generating 32-bit code or 64-bit
  965            # code. In the latter case, it defines _LP64 and __LP64__.
  966            AC_COMPILE_IFELSE(
  967              [AC_LANG_SOURCE(
  968                 [[#ifdef __LP64__
  969                    int ok;
  970                   #else
  971                    error fail
  972                   #endif
  973                 ]])],
  974              [gl_cv_host_cpu_c_abi_32bit=no],
  975              [gl_cv_host_cpu_c_abi_32bit=yes])
  976            ;;
  977 
  978          ia64* )
  979            # On ia64 on HP-UX, the C compiler may be generating 64-bit code or
  980            # 32-bit code. In the latter case, it defines _ILP32.
  981            AC_COMPILE_IFELSE(
  982              [AC_LANG_SOURCE(
  983                 [[#ifdef _ILP32
  984                    int ok;
  985                   #else
  986                    error fail
  987                   #endif
  988                 ]])],
  989              [gl_cv_host_cpu_c_abi_32bit=yes],
  990              [gl_cv_host_cpu_c_abi_32bit=no])
  991            ;;
  992 
  993          mips* )
  994            # We should also check for (_MIPS_SZPTR == 64), but gcc keeps this
  995            # at 32.
  996            AC_COMPILE_IFELSE(
  997              [AC_LANG_SOURCE(
  998                 [[#if defined _MIPS_SZLONG && (_MIPS_SZLONG == 64)
  999                    int ok;
 1000                   #else
 1001                    error fail
 1002                   #endif
 1003                 ]])],
 1004              [gl_cv_host_cpu_c_abi_32bit=no],
 1005              [gl_cv_host_cpu_c_abi_32bit=yes])
 1006            ;;
 1007 
 1008          powerpc* )
 1009            # Different ABIs are in use on AIX vs. Mac OS X vs. Linux,*BSD.
 1010            # No need to distinguish them here; the caller may distinguish
 1011            # them based on the OS.
 1012            # On powerpc64 systems, the C compiler may still be generating
 1013            # 32-bit code. And on powerpc-ibm-aix systems, the C compiler may
 1014            # be generating 64-bit code.
 1015            AC_COMPILE_IFELSE(
 1016              [AC_LANG_SOURCE(
 1017                 [[#if defined __powerpc64__ || defined _ARCH_PPC64
 1018                    int ok;
 1019                   #else
 1020                    error fail
 1021                   #endif
 1022                 ]])],
 1023              [gl_cv_host_cpu_c_abi_32bit=no],
 1024              [gl_cv_host_cpu_c_abi_32bit=yes])
 1025            ;;
 1026 
 1027          rs6000 )
 1028            gl_cv_host_cpu_c_abi_32bit=yes
 1029            ;;
 1030 
 1031          riscv32 | riscv64 )
 1032            # There are 6 ABIs: ilp32, ilp32f, ilp32d, lp64, lp64f, lp64d.
 1033            # Size of 'long' and 'void *':
 1034            AC_COMPILE_IFELSE(
 1035              [AC_LANG_SOURCE(
 1036                 [[#if defined __LP64__
 1037                     int ok;
 1038                   #else
 1039                     error fail
 1040                   #endif
 1041                 ]])],
 1042              [gl_cv_host_cpu_c_abi_32bit=no],
 1043              [gl_cv_host_cpu_c_abi_32bit=yes])
 1044            ;;
 1045 
 1046          s390* )
 1047            # On s390x, the C compiler may be generating 64-bit (= s390x) code
 1048            # or 31-bit (= s390) code.
 1049            AC_COMPILE_IFELSE(
 1050              [AC_LANG_SOURCE(
 1051                 [[#if defined __LP64__ || defined __s390x__
 1052                     int ok;
 1053                   #else
 1054                     error fail
 1055                   #endif
 1056                 ]])],
 1057              [gl_cv_host_cpu_c_abi_32bit=no],
 1058              [gl_cv_host_cpu_c_abi_32bit=yes])
 1059            ;;
 1060 
 1061          sparc | sparc64 )
 1062            # UltraSPARCs running Linux have `uname -m` = "sparc64", but the
 1063            # C compiler still generates 32-bit code.
 1064            AC_COMPILE_IFELSE(
 1065              [AC_LANG_SOURCE(
 1066                 [[#if defined __sparcv9 || defined __arch64__
 1067                    int ok;
 1068                   #else
 1069                    error fail
 1070                   #endif
 1071                 ]])],
 1072              [gl_cv_host_cpu_c_abi_32bit=no],
 1073              [gl_cv_host_cpu_c_abi_32bit=yes])
 1074            ;;
 1075 
 1076          *)
 1077            gl_cv_host_cpu_c_abi_32bit=unknown
 1078            ;;
 1079        esac
 1080      fi
 1081     ])
 1082 
 1083   HOST_CPU_C_ABI_32BIT="$gl_cv_host_cpu_c_abi_32bit"
 1084 ])
 1085 
 1086 # iconv.m4 serial 21
 1087 dnl Copyright (C) 2000-2002, 2007-2014, 2016-2020 Free Software Foundation,
 1088 dnl Inc.
 1089 dnl This file is free software; the Free Software Foundation
 1090 dnl gives unlimited permission to copy and/or distribute it,
 1091 dnl with or without modifications, as long as this notice is preserved.
 1092 
 1093 dnl From Bruno Haible.
 1094 
 1095 AC_DEFUN([AM_ICONV_LINKFLAGS_BODY],
 1096 [
 1097   dnl Prerequisites of AC_LIB_LINKFLAGS_BODY.
 1098   AC_REQUIRE([AC_LIB_PREPARE_PREFIX])
 1099   AC_REQUIRE([AC_LIB_RPATH])
 1100 
 1101   dnl Search for libiconv and define LIBICONV, LTLIBICONV and INCICONV
 1102   dnl accordingly.
 1103   AC_LIB_LINKFLAGS_BODY([iconv])
 1104 ])
 1105 
 1106 AC_DEFUN([AM_ICONV_LINK],
 1107 [
 1108   dnl Some systems have iconv in libc, some have it in libiconv (OSF/1 and
 1109   dnl those with the standalone portable GNU libiconv installed).
 1110   AC_REQUIRE([AC_CANONICAL_HOST]) dnl for cross-compiles
 1111 
 1112   dnl Search for libiconv and define LIBICONV, LTLIBICONV and INCICONV
 1113   dnl accordingly.
 1114   AC_REQUIRE([AM_ICONV_LINKFLAGS_BODY])
 1115 
 1116   dnl Add $INCICONV to CPPFLAGS before performing the following checks,
 1117   dnl because if the user has installed libiconv and not disabled its use
 1118   dnl via --without-libiconv-prefix, he wants to use it. The first
 1119   dnl AC_LINK_IFELSE will then fail, the second AC_LINK_IFELSE will succeed.
 1120   am_save_CPPFLAGS="$CPPFLAGS"
 1121   AC_LIB_APPENDTOVAR([CPPFLAGS], [$INCICONV])
 1122 
 1123   AC_CACHE_CHECK([for iconv], [am_cv_func_iconv], [
 1124     am_cv_func_iconv="no, consider installing GNU libiconv"
 1125     am_cv_lib_iconv=no
 1126     AC_LINK_IFELSE(
 1127       [AC_LANG_PROGRAM(
 1128          [[
 1129 #include <stdlib.h>
 1130 #include <iconv.h>
 1131          ]],
 1132          [[iconv_t cd = iconv_open("","");
 1133            iconv(cd,NULL,NULL,NULL,NULL);
 1134            iconv_close(cd);]])],
 1135       [am_cv_func_iconv=yes])
 1136     if test "$am_cv_func_iconv" != yes; then
 1137       am_save_LIBS="$LIBS"
 1138       LIBS="$LIBS $LIBICONV"
 1139       AC_LINK_IFELSE(
 1140         [AC_LANG_PROGRAM(
 1141            [[
 1142 #include <stdlib.h>
 1143 #include <iconv.h>
 1144            ]],
 1145            [[iconv_t cd = iconv_open("","");
 1146              iconv(cd,NULL,NULL,NULL,NULL);
 1147              iconv_close(cd);]])],
 1148         [am_cv_lib_iconv=yes]
 1149         [am_cv_func_iconv=yes])
 1150       LIBS="$am_save_LIBS"
 1151     fi
 1152   ])
 1153   if test "$am_cv_func_iconv" = yes; then
 1154     AC_CACHE_CHECK([for working iconv], [am_cv_func_iconv_works], [
 1155       dnl This tests against bugs in AIX 5.1, AIX 6.1..7.1, HP-UX 11.11,
 1156       dnl Solaris 10.
 1157       am_save_LIBS="$LIBS"
 1158       if test $am_cv_lib_iconv = yes; then
 1159         LIBS="$LIBS $LIBICONV"
 1160       fi
 1161       am_cv_func_iconv_works=no
 1162       for ac_iconv_const in '' 'const'; do
 1163         AC_RUN_IFELSE(
 1164           [AC_LANG_PROGRAM(
 1165              [[
 1166 #include <iconv.h>
 1167 #include <string.h>
 1168 
 1169 #ifndef ICONV_CONST
 1170 # define ICONV_CONST $ac_iconv_const
 1171 #endif
 1172              ]],
 1173              [[int result = 0;
 1174   /* Test against AIX 5.1 bug: Failures are not distinguishable from successful
 1175      returns.  */
 1176   {
 1177     iconv_t cd_utf8_to_88591 = iconv_open ("ISO8859-1", "UTF-8");
 1178     if (cd_utf8_to_88591 != (iconv_t)(-1))
 1179       {
 1180         static ICONV_CONST char input[] = "\342\202\254"; /* EURO SIGN */
 1181         char buf[10];
 1182         ICONV_CONST char *inptr = input;
 1183         size_t inbytesleft = strlen (input);
 1184         char *outptr = buf;
 1185         size_t outbytesleft = sizeof (buf);
 1186         size_t res = iconv (cd_utf8_to_88591,
 1187                             &inptr, &inbytesleft,
 1188                             &outptr, &outbytesleft);
 1189         if (res == 0)
 1190           result |= 1;
 1191         iconv_close (cd_utf8_to_88591);
 1192       }
 1193   }
 1194   /* Test against Solaris 10 bug: Failures are not distinguishable from
 1195      successful returns.  */
 1196   {
 1197     iconv_t cd_ascii_to_88591 = iconv_open ("ISO8859-1", "646");
 1198     if (cd_ascii_to_88591 != (iconv_t)(-1))
 1199       {
 1200         static ICONV_CONST char input[] = "\263";
 1201         char buf[10];
 1202         ICONV_CONST char *inptr = input;
 1203         size_t inbytesleft = strlen (input);
 1204         char *outptr = buf;
 1205         size_t outbytesleft = sizeof (buf);
 1206         size_t res = iconv (cd_ascii_to_88591,
 1207                             &inptr, &inbytesleft,
 1208                             &outptr, &outbytesleft);
 1209         if (res == 0)
 1210           result |= 2;
 1211         iconv_close (cd_ascii_to_88591);
 1212       }
 1213   }
 1214   /* Test against AIX 6.1..7.1 bug: Buffer overrun.  */
 1215   {
 1216     iconv_t cd_88591_to_utf8 = iconv_open ("UTF-8", "ISO-8859-1");
 1217     if (cd_88591_to_utf8 != (iconv_t)(-1))
 1218       {
 1219         static ICONV_CONST char input[] = "\304";
 1220         static char buf[2] = { (char)0xDE, (char)0xAD };
 1221         ICONV_CONST char *inptr = input;
 1222         size_t inbytesleft = 1;
 1223         char *outptr = buf;
 1224         size_t outbytesleft = 1;
 1225         size_t res = iconv (cd_88591_to_utf8,
 1226                             &inptr, &inbytesleft,
 1227                             &outptr, &outbytesleft);
 1228         if (res != (size_t)(-1) || outptr - buf > 1 || buf[1] != (char)0xAD)
 1229           result |= 4;
 1230         iconv_close (cd_88591_to_utf8);
 1231       }
 1232   }
 1233 #if 0 /* This bug could be worked around by the caller.  */
 1234   /* Test against HP-UX 11.11 bug: Positive return value instead of 0.  */
 1235   {
 1236     iconv_t cd_88591_to_utf8 = iconv_open ("utf8", "iso88591");
 1237     if (cd_88591_to_utf8 != (iconv_t)(-1))
 1238       {
 1239         static ICONV_CONST char input[] = "\304rger mit b\366sen B\374bchen ohne Augenma\337";
 1240         char buf[50];
 1241         ICONV_CONST char *inptr = input;
 1242         size_t inbytesleft = strlen (input);
 1243         char *outptr = buf;
 1244         size_t outbytesleft = sizeof (buf);
 1245         size_t res = iconv (cd_88591_to_utf8,
 1246                             &inptr, &inbytesleft,
 1247                             &outptr, &outbytesleft);
 1248         if ((int)res > 0)
 1249           result |= 8;
 1250         iconv_close (cd_88591_to_utf8);
 1251       }
 1252   }
 1253 #endif
 1254   /* Test against HP-UX 11.11 bug: No converter from EUC-JP to UTF-8 is
 1255      provided.  */
 1256   {
 1257     /* Try standardized names.  */
 1258     iconv_t cd1 = iconv_open ("UTF-8", "EUC-JP");
 1259     /* Try IRIX, OSF/1 names.  */
 1260     iconv_t cd2 = iconv_open ("UTF-8", "eucJP");
 1261     /* Try AIX names.  */
 1262     iconv_t cd3 = iconv_open ("UTF-8", "IBM-eucJP");
 1263     /* Try HP-UX names.  */
 1264     iconv_t cd4 = iconv_open ("utf8", "eucJP");
 1265     if (cd1 == (iconv_t)(-1) && cd2 == (iconv_t)(-1)
 1266         && cd3 == (iconv_t)(-1) && cd4 == (iconv_t)(-1))
 1267       result |= 16;
 1268     if (cd1 != (iconv_t)(-1))
 1269       iconv_close (cd1);
 1270     if (cd2 != (iconv_t)(-1))
 1271       iconv_close (cd2);
 1272     if (cd3 != (iconv_t)(-1))
 1273       iconv_close (cd3);
 1274     if (cd4 != (iconv_t)(-1))
 1275       iconv_close (cd4);
 1276   }
 1277   return result;
 1278 ]])],
 1279           [am_cv_func_iconv_works=yes], ,
 1280           [case "$host_os" in
 1281              aix* | hpux*) am_cv_func_iconv_works="guessing no" ;;
 1282              *)            am_cv_func_iconv_works="guessing yes" ;;
 1283            esac])
 1284         test "$am_cv_func_iconv_works" = no || break
 1285       done
 1286       LIBS="$am_save_LIBS"
 1287     ])
 1288     case "$am_cv_func_iconv_works" in
 1289       *no) am_func_iconv=no am_cv_lib_iconv=no ;;
 1290       *)   am_func_iconv=yes ;;
 1291     esac
 1292   else
 1293     am_func_iconv=no am_cv_lib_iconv=no
 1294   fi
 1295   if test "$am_func_iconv" = yes; then
 1296     AC_DEFINE([HAVE_ICONV], [1],
 1297       [Define if you have the iconv() function and it works.])
 1298   fi
 1299   if test "$am_cv_lib_iconv" = yes; then
 1300     AC_MSG_CHECKING([how to link with libiconv])
 1301     AC_MSG_RESULT([$LIBICONV])
 1302   else
 1303     dnl If $LIBICONV didn't lead to a usable library, we don't need $INCICONV
 1304     dnl either.
 1305     CPPFLAGS="$am_save_CPPFLAGS"
 1306     LIBICONV=
 1307     LTLIBICONV=
 1308   fi
 1309   AC_SUBST([LIBICONV])
 1310   AC_SUBST([LTLIBICONV])
 1311 ])
 1312 
 1313 dnl Define AM_ICONV using AC_DEFUN_ONCE for Autoconf >= 2.64, in order to
 1314 dnl avoid warnings like
 1315 dnl "warning: AC_REQUIRE: `AM_ICONV' was expanded before it was required".
 1316 dnl This is tricky because of the way 'aclocal' is implemented:
 1317 dnl - It requires defining an auxiliary macro whose name ends in AC_DEFUN.
 1318 dnl   Otherwise aclocal's initial scan pass would miss the macro definition.
 1319 dnl - It requires a line break inside the AC_DEFUN_ONCE and AC_DEFUN expansions.
 1320 dnl   Otherwise aclocal would emit many "Use of uninitialized value $1"
 1321 dnl   warnings.
 1322 m4_define([gl_iconv_AC_DEFUN],
 1323   m4_version_prereq([2.64],
 1324     [[AC_DEFUN_ONCE(
 1325         [$1], [$2])]],
 1326     [m4_ifdef([gl_00GNULIB],
 1327        [[AC_DEFUN_ONCE(
 1328            [$1], [$2])]],
 1329        [[AC_DEFUN(
 1330            [$1], [$2])]])]))
 1331 gl_iconv_AC_DEFUN([AM_ICONV],
 1332 [
 1333   AM_ICONV_LINK
 1334   if test "$am_cv_func_iconv" = yes; then
 1335     AC_MSG_CHECKING([for iconv declaration])
 1336     AC_CACHE_VAL([am_cv_proto_iconv], [
 1337       AC_COMPILE_IFELSE(
 1338         [AC_LANG_PROGRAM(
 1339            [[
 1340 #include <stdlib.h>
 1341 #include <iconv.h>
 1342 extern
 1343 #ifdef __cplusplus
 1344 "C"
 1345 #endif
 1346 #if defined(__STDC__) || defined(_MSC_VER) || defined(__cplusplus)
 1347 size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);
 1348 #else
 1349 size_t iconv();
 1350 #endif
 1351            ]],
 1352            [[]])],
 1353         [am_cv_proto_iconv_arg1=""],
 1354         [am_cv_proto_iconv_arg1="const"])
 1355       am_cv_proto_iconv="extern size_t iconv (iconv_t cd, $am_cv_proto_iconv_arg1 char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);"])
 1356     am_cv_proto_iconv=`echo "[$]am_cv_proto_iconv" | tr -s ' ' | sed -e 's/( /(/'`
 1357     AC_MSG_RESULT([
 1358          $am_cv_proto_iconv])
 1359   else
 1360     dnl When compiling GNU libiconv on a system that does not have iconv yet,
 1361     dnl pick the POSIX compliant declaration without 'const'.
 1362     am_cv_proto_iconv_arg1=""
 1363   fi
 1364   AC_DEFINE_UNQUOTED([ICONV_CONST], [$am_cv_proto_iconv_arg1],
 1365     [Define as const if the declaration of iconv() needs const.])
 1366   dnl Also substitute ICONV_CONST in the gnulib generated <iconv.h>.
 1367   m4_ifdef([gl_ICONV_H_DEFAULTS],
 1368     [AC_REQUIRE([gl_ICONV_H_DEFAULTS])
 1369      if test -n "$am_cv_proto_iconv_arg1"; then
 1370        ICONV_CONST="const"
 1371      fi
 1372     ])
 1373 ])
 1374 
 1375 # intlmacosx.m4 serial 8 (gettext-0.20.2)
 1376 dnl Copyright (C) 2004-2014, 2016, 2019-2020 Free Software Foundation, Inc.
 1377 dnl This file is free software; the Free Software Foundation
 1378 dnl gives unlimited permission to copy and/or distribute it,
 1379 dnl with or without modifications, as long as this notice is preserved.
 1380 dnl
 1381 dnl This file can be used in projects which are not available under
 1382 dnl the GNU General Public License or the GNU Lesser General Public
 1383 dnl License but which still want to provide support for the GNU gettext
 1384 dnl functionality.
 1385 dnl Please note that the actual code of the GNU gettext library is covered
 1386 dnl by the GNU Lesser General Public License, and the rest of the GNU
 1387 dnl gettext package is covered by the GNU General Public License.
 1388 dnl They are *not* in the public domain.
 1389 
 1390 dnl Checks for special options needed on Mac OS X.
 1391 dnl Defines INTL_MACOSX_LIBS.
 1392 AC_DEFUN([gt_INTL_MACOSX],
 1393 [
 1394   dnl Check for API introduced in Mac OS X 10.4.
 1395   AC_CACHE_CHECK([for CFPreferencesCopyAppValue],
 1396     [gt_cv_func_CFPreferencesCopyAppValue],
 1397     [gt_save_LIBS="$LIBS"
 1398      LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
 1399      AC_LINK_IFELSE(
 1400        [AC_LANG_PROGRAM(
 1401           [[#include <CoreFoundation/CFPreferences.h>]],
 1402           [[CFPreferencesCopyAppValue(NULL, NULL)]])],
 1403        [gt_cv_func_CFPreferencesCopyAppValue=yes],
 1404        [gt_cv_func_CFPreferencesCopyAppValue=no])
 1405      LIBS="$gt_save_LIBS"])
 1406   if test $gt_cv_func_CFPreferencesCopyAppValue = yes; then
 1407     AC_DEFINE([HAVE_CFPREFERENCESCOPYAPPVALUE], [1],
 1408       [Define to 1 if you have the Mac OS X function CFPreferencesCopyAppValue in the CoreFoundation framework.])
 1409   fi
 1410   dnl Don't check for the API introduced in Mac OS X 10.5, CFLocaleCopyCurrent,
 1411   dnl because in macOS 10.13.4 it has the following behaviour:
 1412   dnl When two or more languages are specified in the
 1413   dnl "System Preferences > Language & Region > Preferred Languages" panel,
 1414   dnl it returns en_CC where CC is the territory (even when English is not among
 1415   dnl the preferred languages!).  What we want instead is what
 1416   dnl CFLocaleCopyCurrent returned in earlier macOS releases and what
 1417   dnl CFPreferencesCopyAppValue still returns, namely ll_CC where ll is the
 1418   dnl first among the preferred languages and CC is the territory.
 1419   AC_CACHE_CHECK([for CFLocaleCopyPreferredLanguages], [gt_cv_func_CFLocaleCopyPreferredLanguages],
 1420     [gt_save_LIBS="$LIBS"
 1421      LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
 1422      AC_LINK_IFELSE(
 1423        [AC_LANG_PROGRAM(
 1424           [[#include <CoreFoundation/CFLocale.h>]],
 1425           [[CFLocaleCopyPreferredLanguages();]])],
 1426        [gt_cv_func_CFLocaleCopyPreferredLanguages=yes],
 1427        [gt_cv_func_CFLocaleCopyPreferredLanguages=no])
 1428      LIBS="$gt_save_LIBS"])
 1429   if test $gt_cv_func_CFLocaleCopyPreferredLanguages = yes; then
 1430     AC_DEFINE([HAVE_CFLOCALECOPYPREFERREDLANGUAGES], [1],
 1431       [Define to 1 if you have the Mac OS X function CFLocaleCopyPreferredLanguages in the CoreFoundation framework.])
 1432   fi
 1433   INTL_MACOSX_LIBS=
 1434   if test $gt_cv_func_CFPreferencesCopyAppValue = yes \
 1435      || test $gt_cv_func_CFLocaleCopyPreferredLanguages = yes; then
 1436     INTL_MACOSX_LIBS="-Wl,-framework -Wl,CoreFoundation"
 1437   fi
 1438   AC_SUBST([INTL_MACOSX_LIBS])
 1439 ])
 1440 
 1441 # lib-ld.m4 serial 9
 1442 dnl Copyright (C) 1996-2003, 2009-2020 Free Software Foundation, Inc.
 1443 dnl This file is free software; the Free Software Foundation
 1444 dnl gives unlimited permission to copy and/or distribute it,
 1445 dnl with or without modifications, as long as this notice is preserved.
 1446 
 1447 dnl Subroutines of libtool.m4,
 1448 dnl with replacements s/_*LT_PATH/AC_LIB_PROG/ and s/lt_/acl_/ to avoid
 1449 dnl collision with libtool.m4.
 1450 
 1451 dnl From libtool-2.4. Sets the variable with_gnu_ld to yes or no.
 1452 AC_DEFUN([AC_LIB_PROG_LD_GNU],
 1453 [AC_CACHE_CHECK([if the linker ($LD) is GNU ld], [acl_cv_prog_gnu_ld],
 1454 [# I'd rather use --version here, but apparently some GNU lds only accept -v.
 1455 case `$LD -v 2>&1 </dev/null` in
 1456 *GNU* | *'with BFD'*)
 1457   acl_cv_prog_gnu_ld=yes
 1458   ;;
 1459 *)
 1460   acl_cv_prog_gnu_ld=no
 1461   ;;
 1462 esac])
 1463 with_gnu_ld=$acl_cv_prog_gnu_ld
 1464 ])
 1465 
 1466 dnl From libtool-2.4. Sets the variable LD.
 1467 AC_DEFUN([AC_LIB_PROG_LD],
 1468 [AC_REQUIRE([AC_PROG_CC])dnl
 1469 AC_REQUIRE([AC_CANONICAL_HOST])dnl
 1470 
 1471 AC_ARG_WITH([gnu-ld],
 1472     [AS_HELP_STRING([--with-gnu-ld],
 1473         [assume the C compiler uses GNU ld [default=no]])],
 1474     [test "$withval" = no || with_gnu_ld=yes],
 1475     [with_gnu_ld=no])dnl
 1476 
 1477 # Prepare PATH_SEPARATOR.
 1478 # The user is always right.
 1479 if test "${PATH_SEPARATOR+set}" != set; then
 1480   # Determine PATH_SEPARATOR by trying to find /bin/sh in a PATH which
 1481   # contains only /bin. Note that ksh looks also at the FPATH variable,
 1482   # so we have to set that as well for the test.
 1483   PATH_SEPARATOR=:
 1484   (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
 1485     && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
 1486            || PATH_SEPARATOR=';'
 1487        }
 1488 fi
 1489 
 1490 if test -n "$LD"; then
 1491   AC_MSG_CHECKING([for ld])
 1492 elif test "$GCC" = yes; then
 1493   AC_MSG_CHECKING([for ld used by $CC])
 1494 elif test "$with_gnu_ld" = yes; then
 1495   AC_MSG_CHECKING([for GNU ld])
 1496 else
 1497   AC_MSG_CHECKING([for non-GNU ld])
 1498 fi
 1499 if test -n "$LD"; then
 1500   # Let the user override the test with a path.
 1501   :
 1502 else
 1503   AC_CACHE_VAL([acl_cv_path_LD],
 1504   [
 1505     acl_cv_path_LD= # Final result of this test
 1506     ac_prog=ld # Program to search in $PATH
 1507     if test "$GCC" = yes; then
 1508       # Check if gcc -print-prog-name=ld gives a path.
 1509       case $host in
 1510         *-*-mingw*)
 1511           # gcc leaves a trailing carriage return which upsets mingw
 1512           acl_output=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
 1513         *)
 1514           acl_output=`($CC -print-prog-name=ld) 2>&5` ;;
 1515       esac
 1516       case $acl_output in
 1517         # Accept absolute paths.
 1518         [[\\/]]* | ?:[[\\/]]*)
 1519           re_direlt='/[[^/]][[^/]]*/\.\./'
 1520           # Canonicalize the pathname of ld
 1521           acl_output=`echo "$acl_output" | sed 's%\\\\%/%g'`
 1522           while echo "$acl_output" | grep "$re_direlt" > /dev/null 2>&1; do
 1523             acl_output=`echo $acl_output | sed "s%$re_direlt%/%"`
 1524           done
 1525           # Got the pathname. No search in PATH is needed.
 1526           acl_cv_path_LD="$acl_output"
 1527           ac_prog=
 1528           ;;
 1529         "")
 1530           # If it fails, then pretend we aren't using GCC.
 1531           ;;
 1532         *)
 1533           # If it is relative, then search for the first ld in PATH.
 1534           with_gnu_ld=unknown
 1535           ;;
 1536       esac
 1537     fi
 1538     if test -n "$ac_prog"; then
 1539       # Search for $ac_prog in $PATH.
 1540       acl_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
 1541       for ac_dir in $PATH; do
 1542         IFS="$acl_save_ifs"
 1543         test -z "$ac_dir" && ac_dir=.
 1544         if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
 1545           acl_cv_path_LD="$ac_dir/$ac_prog"
 1546           # Check to see if the program is GNU ld.  I'd rather use --version,
 1547           # but apparently some variants of GNU ld only accept -v.
 1548           # Break only if it was the GNU/non-GNU ld that we prefer.
 1549           case `"$acl_cv_path_LD" -v 2>&1 </dev/null` in
 1550             *GNU* | *'with BFD'*)
 1551               test "$with_gnu_ld" != no && break
 1552               ;;
 1553             *)
 1554               test "$with_gnu_ld" != yes && break
 1555               ;;
 1556           esac
 1557         fi
 1558       done
 1559       IFS="$acl_save_ifs"
 1560     fi
 1561     case $host in
 1562       *-*-aix*)
 1563         AC_COMPILE_IFELSE(
 1564           [AC_LANG_SOURCE(
 1565              [[#if defined __powerpc64__ || defined _ARCH_PPC64
 1566                 int ok;
 1567                #else
 1568                 error fail
 1569                #endif
 1570              ]])],
 1571           [# The compiler produces 64-bit code. Add option '-b64' so that the
 1572            # linker groks 64-bit object files.
 1573            case "$acl_cv_path_LD " in
 1574              *" -b64 "*) ;;
 1575              *) acl_cv_path_LD="$acl_cv_path_LD -b64" ;;
 1576            esac
 1577           ], [])
 1578         ;;
 1579       sparc64-*-netbsd*)
 1580         AC_COMPILE_IFELSE(
 1581           [AC_LANG_SOURCE(
 1582              [[#if defined __sparcv9 || defined __arch64__
 1583                 int ok;
 1584                #else
 1585                 error fail
 1586                #endif
 1587              ]])],
 1588           [],
 1589           [# The compiler produces 32-bit code. Add option '-m elf32_sparc'
 1590            # so that the linker groks 32-bit object files.
 1591            case "$acl_cv_path_LD " in
 1592              *" -m elf32_sparc "*) ;;
 1593              *) acl_cv_path_LD="$acl_cv_path_LD -m elf32_sparc" ;;
 1594            esac
 1595           ])
 1596         ;;
 1597     esac
 1598   ])
 1599   LD="$acl_cv_path_LD"
 1600 fi
 1601 if test -n "$LD"; then
 1602   AC_MSG_RESULT([$LD])
 1603 else
 1604   AC_MSG_RESULT([no])
 1605   AC_MSG_ERROR([no acceptable ld found in \$PATH])
 1606 fi
 1607 AC_LIB_PROG_LD_GNU
 1608 ])
 1609 
 1610 # lib-link.m4 serial 31
 1611 dnl Copyright (C) 2001-2020 Free Software Foundation, Inc.
 1612 dnl This file is free software; the Free Software Foundation
 1613 dnl gives unlimited permission to copy and/or distribute it,
 1614 dnl with or without modifications, as long as this notice is preserved.
 1615 
 1616 dnl From Bruno Haible.
 1617 
 1618 AC_PREREQ([2.61])
 1619 
 1620 dnl AC_LIB_LINKFLAGS(name [, dependencies]) searches for libname and
 1621 dnl the libraries corresponding to explicit and implicit dependencies.
 1622 dnl Sets and AC_SUBSTs the LIB${NAME} and LTLIB${NAME} variables and
 1623 dnl augments the CPPFLAGS variable.
 1624 dnl Sets and AC_SUBSTs the LIB${NAME}_PREFIX variable to nonempty if libname
 1625 dnl was found in ${LIB${NAME}_PREFIX}/$acl_libdirstem.
 1626 AC_DEFUN([AC_LIB_LINKFLAGS],
 1627 [
 1628   AC_REQUIRE([AC_LIB_PREPARE_PREFIX])
 1629   AC_REQUIRE([AC_LIB_RPATH])
 1630   pushdef([Name],[m4_translit([$1],[./+-], [____])])
 1631   pushdef([NAME],[m4_translit([$1],[abcdefghijklmnopqrstuvwxyz./+-],
 1632                                    [ABCDEFGHIJKLMNOPQRSTUVWXYZ____])])
 1633   AC_CACHE_CHECK([how to link with lib[]$1], [ac_cv_lib[]Name[]_libs], [
 1634     AC_LIB_LINKFLAGS_BODY([$1], [$2])
 1635     ac_cv_lib[]Name[]_libs="$LIB[]NAME"
 1636     ac_cv_lib[]Name[]_ltlibs="$LTLIB[]NAME"
 1637     ac_cv_lib[]Name[]_cppflags="$INC[]NAME"
 1638     ac_cv_lib[]Name[]_prefix="$LIB[]NAME[]_PREFIX"
 1639   ])
 1640   LIB[]NAME="$ac_cv_lib[]Name[]_libs"
 1641   LTLIB[]NAME="$ac_cv_lib[]Name[]_ltlibs"
 1642   INC[]NAME="$ac_cv_lib[]Name[]_cppflags"
 1643   LIB[]NAME[]_PREFIX="$ac_cv_lib[]Name[]_prefix"
 1644   AC_LIB_APPENDTOVAR([CPPFLAGS], [$INC]NAME)
 1645   AC_SUBST([LIB]NAME)
 1646   AC_SUBST([LTLIB]NAME)
 1647   AC_SUBST([LIB]NAME[_PREFIX])
 1648   dnl Also set HAVE_LIB[]NAME so that AC_LIB_HAVE_LINKFLAGS can reuse the
 1649   dnl results of this search when this library appears as a dependency.
 1650   HAVE_LIB[]NAME=yes
 1651   popdef([NAME])
 1652   popdef([Name])
 1653 ])
 1654 
 1655 dnl AC_LIB_HAVE_LINKFLAGS(name, dependencies, includes, testcode, [missing-message])
 1656 dnl searches for libname and the libraries corresponding to explicit and
 1657 dnl implicit dependencies, together with the specified include files and
 1658 dnl the ability to compile and link the specified testcode. The missing-message
 1659 dnl defaults to 'no' and may contain additional hints for the user.
 1660 dnl If found, it sets and AC_SUBSTs HAVE_LIB${NAME}=yes and the LIB${NAME}
 1661 dnl and LTLIB${NAME} variables and augments the CPPFLAGS variable, and
 1662 dnl #defines HAVE_LIB${NAME} to 1. Otherwise, it sets and AC_SUBSTs
 1663 dnl HAVE_LIB${NAME}=no and LIB${NAME} and LTLIB${NAME} to empty.
 1664 dnl Sets and AC_SUBSTs the LIB${NAME}_PREFIX variable to nonempty if libname
 1665 dnl was found in ${LIB${NAME}_PREFIX}/$acl_libdirstem.
 1666 AC_DEFUN([AC_LIB_HAVE_LINKFLAGS],
 1667 [
 1668   AC_REQUIRE([AC_LIB_PREPARE_PREFIX])
 1669   AC_REQUIRE([AC_LIB_RPATH])
 1670   pushdef([Name],[m4_translit([$1],[./+-], [____])])
 1671   pushdef([NAME],[m4_translit([$1],[abcdefghijklmnopqrstuvwxyz./+-],
 1672                                    [ABCDEFGHIJKLMNOPQRSTUVWXYZ____])])
 1673 
 1674   dnl Search for lib[]Name and define LIB[]NAME, LTLIB[]NAME and INC[]NAME
 1675   dnl accordingly.
 1676   AC_LIB_LINKFLAGS_BODY([$1], [$2])
 1677 
 1678   dnl Add $INC[]NAME to CPPFLAGS before performing the following checks,
 1679   dnl because if the user has installed lib[]Name and not disabled its use
 1680   dnl via --without-lib[]Name-prefix, he wants to use it.
 1681   ac_save_CPPFLAGS="$CPPFLAGS"
 1682   AC_LIB_APPENDTOVAR([CPPFLAGS], [$INC]NAME)
 1683 
 1684   AC_CACHE_CHECK([for lib[]$1], [ac_cv_lib[]Name], [
 1685     ac_save_LIBS="$LIBS"
 1686     dnl If $LIB[]NAME contains some -l options, add it to the end of LIBS,
 1687     dnl because these -l options might require -L options that are present in
 1688     dnl LIBS. -l options benefit only from the -L options listed before it.
 1689     dnl Otherwise, add it to the front of LIBS, because it may be a static
 1690     dnl library that depends on another static library that is present in LIBS.
 1691     dnl Static libraries benefit only from the static libraries listed after
 1692     dnl it.
 1693     case " $LIB[]NAME" in
 1694       *" -l"*) LIBS="$LIBS $LIB[]NAME" ;;
 1695       *)       LIBS="$LIB[]NAME $LIBS" ;;
 1696     esac
 1697     AC_LINK_IFELSE(
 1698       [AC_LANG_PROGRAM([[$3]], [[$4]])],
 1699       [ac_cv_lib[]Name=yes],
 1700       [ac_cv_lib[]Name='m4_if([$5], [], [no], [[$5]])'])
 1701     LIBS="$ac_save_LIBS"
 1702   ])
 1703   if test "$ac_cv_lib[]Name" = yes; then
 1704     HAVE_LIB[]NAME=yes
 1705     AC_DEFINE([HAVE_LIB]NAME, 1, [Define if you have the lib][$1 library.])
 1706     AC_MSG_CHECKING([how to link with lib[]$1])
 1707     AC_MSG_RESULT([$LIB[]NAME])
 1708   else
 1709     HAVE_LIB[]NAME=no
 1710     dnl If $LIB[]NAME didn't lead to a usable library, we don't need
 1711     dnl $INC[]NAME either.
 1712     CPPFLAGS="$ac_save_CPPFLAGS"
 1713     LIB[]NAME=
 1714     LTLIB[]NAME=
 1715     LIB[]NAME[]_PREFIX=
 1716   fi
 1717   AC_SUBST([HAVE_LIB]NAME)
 1718   AC_SUBST([LIB]NAME)
 1719   AC_SUBST([LTLIB]NAME)
 1720   AC_SUBST([LIB]NAME[_PREFIX])
 1721   popdef([NAME])
 1722   popdef([Name])
 1723 ])
 1724 
 1725 dnl Determine the platform dependent parameters needed to use rpath:
 1726 dnl   acl_libext,
 1727 dnl   acl_shlibext,
 1728 dnl   acl_libname_spec,
 1729 dnl   acl_library_names_spec,
 1730 dnl   acl_hardcode_libdir_flag_spec,
 1731 dnl   acl_hardcode_libdir_separator,
 1732 dnl   acl_hardcode_direct,
 1733 dnl   acl_hardcode_minus_L.
 1734 AC_DEFUN([AC_LIB_RPATH],
 1735 [
 1736   dnl Complain if config.rpath is missing.
 1737   AC_REQUIRE_AUX_FILE([config.rpath])
 1738   AC_REQUIRE([AC_PROG_CC])                dnl we use $CC, $GCC, $LDFLAGS
 1739   AC_REQUIRE([AC_LIB_PROG_LD])            dnl we use $LD, $with_gnu_ld
 1740   AC_REQUIRE([AC_CANONICAL_HOST])         dnl we use $host
 1741   AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT]) dnl we use $ac_aux_dir
 1742   AC_CACHE_CHECK([for shared library run path origin], [acl_cv_rpath], [
 1743     CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \
 1744     ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh
 1745     . ./conftest.sh
 1746     rm -f ./conftest.sh
 1747     acl_cv_rpath=done
 1748   ])
 1749   wl="$acl_cv_wl"
 1750   acl_libext="$acl_cv_libext"
 1751   acl_shlibext="$acl_cv_shlibext"
 1752   acl_libname_spec="$acl_cv_libname_spec"
 1753   acl_library_names_spec="$acl_cv_library_names_spec"
 1754   acl_hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec"
 1755   acl_hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator"
 1756   acl_hardcode_direct="$acl_cv_hardcode_direct"
 1757   acl_hardcode_minus_L="$acl_cv_hardcode_minus_L"
 1758   dnl Determine whether the user wants rpath handling at all.
 1759   AC_ARG_ENABLE([rpath],
 1760     [  --disable-rpath         do not hardcode runtime library paths],
 1761     :, enable_rpath=yes)
 1762 ])
 1763 
 1764 dnl AC_LIB_FROMPACKAGE(name, package)
 1765 dnl declares that libname comes from the given package. The configure file
 1766 dnl will then not have a --with-libname-prefix option but a
 1767 dnl --with-package-prefix option. Several libraries can come from the same
 1768 dnl package. This declaration must occur before an AC_LIB_LINKFLAGS or similar
 1769 dnl macro call that searches for libname.
 1770 AC_DEFUN([AC_LIB_FROMPACKAGE],
 1771 [
 1772   pushdef([NAME],[m4_translit([$1],[abcdefghijklmnopqrstuvwxyz./+-],
 1773                                    [ABCDEFGHIJKLMNOPQRSTUVWXYZ____])])
 1774   define([acl_frompackage_]NAME, [$2])
 1775   popdef([NAME])
 1776   pushdef([PACK],[$2])
 1777   pushdef([PACKUP],[m4_translit(PACK,[abcdefghijklmnopqrstuvwxyz./+-],
 1778                                      [ABCDEFGHIJKLMNOPQRSTUVWXYZ____])])
 1779   define([acl_libsinpackage_]PACKUP,
 1780     m4_ifdef([acl_libsinpackage_]PACKUP, [m4_defn([acl_libsinpackage_]PACKUP)[, ]],)[lib$1])
 1781   popdef([PACKUP])
 1782   popdef([PACK])
 1783 ])
 1784 
 1785 dnl AC_LIB_LINKFLAGS_BODY(name [, dependencies]) searches for libname and
 1786 dnl the libraries corresponding to explicit and implicit dependencies.
 1787 dnl Sets the LIB${NAME}, LTLIB${NAME} and INC${NAME} variables.
 1788 dnl Also, sets the LIB${NAME}_PREFIX variable to nonempty if libname was found
 1789 dnl in ${LIB${NAME}_PREFIX}/$acl_libdirstem.
 1790 AC_DEFUN([AC_LIB_LINKFLAGS_BODY],
 1791 [
 1792   AC_REQUIRE([AC_LIB_PREPARE_MULTILIB])
 1793   pushdef([NAME],[m4_translit([$1],[abcdefghijklmnopqrstuvwxyz./+-],
 1794                                    [ABCDEFGHIJKLMNOPQRSTUVWXYZ____])])
 1795   pushdef([PACK],[m4_ifdef([acl_frompackage_]NAME, [acl_frompackage_]NAME, lib[$1])])
 1796   pushdef([PACKUP],[m4_translit(PACK,[abcdefghijklmnopqrstuvwxyz./+-],
 1797                                      [ABCDEFGHIJKLMNOPQRSTUVWXYZ____])])
 1798   pushdef([PACKLIBS],[m4_ifdef([acl_frompackage_]NAME, [acl_libsinpackage_]PACKUP, lib[$1])])
 1799   dnl By default, look in $includedir and $libdir.
 1800   use_additional=yes
 1801   AC_LIB_WITH_FINAL_PREFIX([
 1802     eval additional_includedir=\"$includedir\"
 1803     eval additional_libdir=\"$libdir\"
 1804     eval additional_libdir2=\"$exec_prefix/$acl_libdirstem2\"
 1805     eval additional_libdir3=\"$exec_prefix/$acl_libdirstem3\"
 1806   ])
 1807   AC_ARG_WITH(PACK[-prefix],
 1808 [[  --with-]]PACK[[-prefix[=DIR]  search for ]PACKLIBS[ in DIR/include and DIR/lib
 1809   --without-]]PACK[[-prefix     don't search for ]PACKLIBS[ in includedir and libdir]],
 1810 [
 1811     if test "X$withval" = "Xno"; then
 1812       use_additional=no
 1813     else
 1814       if test "X$withval" = "X"; then
 1815         AC_LIB_WITH_FINAL_PREFIX([
 1816           eval additional_includedir=\"$includedir\"
 1817           eval additional_libdir=\"$libdir\"
 1818           eval additional_libdir2=\"$exec_prefix/$acl_libdirstem2\"
 1819           eval additional_libdir3=\"$exec_prefix/$acl_libdirstem3\"
 1820         ])
 1821       else
 1822         additional_includedir="$withval/include"
 1823         additional_libdir="$withval/$acl_libdirstem"
 1824         additional_libdir2="$withval/$acl_libdirstem2"
 1825         additional_libdir3="$withval/$acl_libdirstem3"
 1826       fi
 1827     fi
 1828 ])
 1829   if test "X$additional_libdir2" = "X$additional_libdir"; then
 1830     additional_libdir2=
 1831   fi
 1832   if test "X$additional_libdir3" = "X$additional_libdir"; then
 1833     additional_libdir3=
 1834   fi
 1835   dnl Search the library and its dependencies in $additional_libdir and
 1836   dnl $LDFLAGS. Using breadth-first-seach.
 1837   LIB[]NAME=
 1838   LTLIB[]NAME=
 1839   INC[]NAME=
 1840   LIB[]NAME[]_PREFIX=
 1841   dnl HAVE_LIB${NAME} is an indicator that LIB${NAME}, LTLIB${NAME} have been
 1842   dnl computed. So it has to be reset here.
 1843   HAVE_LIB[]NAME=
 1844   rpathdirs=
 1845   ltrpathdirs=
 1846   names_already_handled=
 1847   names_next_round='$1 $2'
 1848   while test -n "$names_next_round"; do
 1849     names_this_round="$names_next_round"
 1850     names_next_round=
 1851     for name in $names_this_round; do
 1852       already_handled=
 1853       for n in $names_already_handled; do
 1854         if test "$n" = "$name"; then
 1855           already_handled=yes
 1856           break
 1857         fi
 1858       done
 1859       if test -z "$already_handled"; then
 1860         names_already_handled="$names_already_handled $name"
 1861         dnl See if it was already located by an earlier AC_LIB_LINKFLAGS
 1862         dnl or AC_LIB_HAVE_LINKFLAGS call.
 1863         uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./+-|ABCDEFGHIJKLMNOPQRSTUVWXYZ____|'`
 1864         eval value=\"\$HAVE_LIB$uppername\"
 1865         if test -n "$value"; then
 1866           if test "$value" = yes; then
 1867             eval value=\"\$LIB$uppername\"
 1868             test -z "$value" || LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$value"
 1869             eval value=\"\$LTLIB$uppername\"
 1870             test -z "$value" || LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }$value"
 1871           else
 1872             dnl An earlier call to AC_LIB_HAVE_LINKFLAGS has determined
 1873             dnl that this library doesn't exist. So just drop it.
 1874             :
 1875           fi
 1876         else
 1877           dnl Search the library lib$name in $additional_libdir and $LDFLAGS
 1878           dnl and the already constructed $LIBNAME/$LTLIBNAME.
 1879           found_dir=
 1880           found_la=
 1881           found_so=
 1882           found_a=
 1883           eval libname=\"$acl_libname_spec\"    # typically: libname=lib$name
 1884           if test -n "$acl_shlibext"; then
 1885             shrext=".$acl_shlibext"             # typically: shrext=.so
 1886           else
 1887             shrext=
 1888           fi
 1889           if test $use_additional = yes; then
 1890             for additional_libdir_variable in additional_libdir additional_libdir2 additional_libdir3; do
 1891               if test "X$found_dir" = "X"; then
 1892                 eval dir=\$$additional_libdir_variable
 1893                 if test -n "$dir"; then
 1894                   dnl The same code as in the loop below:
 1895                   dnl First look for a shared library.
 1896                   if test -n "$acl_shlibext"; then
 1897                     if test -f "$dir/$libname$shrext" && acl_is_expected_elfclass < "$dir/$libname$shrext"; then
 1898                       found_dir="$dir"
 1899                       found_so="$dir/$libname$shrext"
 1900                     else
 1901                       if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then
 1902                         ver=`(cd "$dir" && \
 1903                               for f in "$libname$shrext".*; do echo "$f"; done \
 1904                               | sed -e "s,^$libname$shrext\\\\.,," \
 1905                               | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \
 1906                               | sed 1q ) 2>/dev/null`
 1907                         if test -n "$ver" && test -f "$dir/$libname$shrext.$ver" && acl_is_expected_elfclass < "$dir/$libname$shrext.$ver"; then
 1908                           found_dir="$dir"
 1909                           found_so="$dir/$libname$shrext.$ver"
 1910                         fi
 1911                       else
 1912                         eval library_names=\"$acl_library_names_spec\"
 1913                         for f in $library_names; do
 1914                           if test -f "$dir/$f" && acl_is_expected_elfclass < "$dir/$f"; then
 1915                             found_dir="$dir"
 1916                             found_so="$dir/$f"
 1917                             break
 1918                           fi
 1919                         done
 1920                       fi
 1921                     fi
 1922                   fi
 1923                   dnl Then look for a static library.
 1924                   if test "X$found_dir" = "X"; then
 1925                     if test -f "$dir/$libname.$acl_libext" && ${AR-ar} -p "$dir/$libname.$acl_libext" | acl_is_expected_elfclass; then
 1926                       found_dir="$dir"
 1927                       found_a="$dir/$libname.$acl_libext"
 1928                     fi
 1929                   fi
 1930                   if test "X$found_dir" != "X"; then
 1931                     if test -f "$dir/$libname.la"; then
 1932                       found_la="$dir/$libname.la"
 1933                     fi
 1934                   fi
 1935                 fi
 1936               fi
 1937             done
 1938           fi
 1939           if test "X$found_dir" = "X"; then
 1940             for x in $LDFLAGS $LTLIB[]NAME; do
 1941               AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
 1942               case "$x" in
 1943                 -L*)
 1944                   dir=`echo "X$x" | sed -e 's/^X-L//'`
 1945                   dnl First look for a shared library.
 1946                   if test -n "$acl_shlibext"; then
 1947                     if test -f "$dir/$libname$shrext" && acl_is_expected_elfclass < "$dir/$libname$shrext"; then
 1948                       found_dir="$dir"
 1949                       found_so="$dir/$libname$shrext"
 1950                     else
 1951                       if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then
 1952                         ver=`(cd "$dir" && \
 1953                               for f in "$libname$shrext".*; do echo "$f"; done \
 1954                               | sed -e "s,^$libname$shrext\\\\.,," \
 1955                               | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \
 1956                               | sed 1q ) 2>/dev/null`
 1957                         if test -n "$ver" && test -f "$dir/$libname$shrext.$ver" && acl_is_expected_elfclass < "$dir/$libname$shrext.$ver"; then
 1958                           found_dir="$dir"
 1959                           found_so="$dir/$libname$shrext.$ver"
 1960                         fi
 1961                       else
 1962                         eval library_names=\"$acl_library_names_spec\"
 1963                         for f in $library_names; do
 1964                           if test -f "$dir/$f" && acl_is_expected_elfclass < "$dir/$f"; then
 1965                             found_dir="$dir"
 1966                             found_so="$dir/$f"
 1967                             break
 1968                           fi
 1969                         done
 1970                       fi
 1971                     fi
 1972                   fi
 1973                   dnl Then look for a static library.
 1974                   if test "X$found_dir" = "X"; then
 1975                     if test -f "$dir/$libname.$acl_libext" && ${AR-ar} -p "$dir/$libname.$acl_libext" | acl_is_expected_elfclass; then
 1976                       found_dir="$dir"
 1977                       found_a="$dir/$libname.$acl_libext"
 1978                     fi
 1979                   fi
 1980                   if test "X$found_dir" != "X"; then
 1981                     if test -f "$dir/$libname.la"; then
 1982                       found_la="$dir/$libname.la"
 1983                     fi
 1984                   fi
 1985                   ;;
 1986               esac
 1987               if test "X$found_dir" != "X"; then
 1988                 break
 1989               fi
 1990             done
 1991           fi
 1992           if test "X$found_dir" != "X"; then
 1993             dnl Found the library.
 1994             LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }-L$found_dir -l$name"
 1995             if test "X$found_so" != "X"; then
 1996               dnl Linking with a shared library. We attempt to hardcode its
 1997               dnl directory into the executable's runpath, unless it's the
 1998               dnl standard /usr/lib.
 1999               if test "$enable_rpath" = no \
 2000                  || test "X$found_dir" = "X/usr/$acl_libdirstem" \
 2001                  || test "X$found_dir" = "X/usr/$acl_libdirstem2" \
 2002                  || test "X$found_dir" = "X/usr/$acl_libdirstem3"; then
 2003                 dnl No hardcoding is needed.
 2004                 LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so"
 2005               else
 2006                 dnl Use an explicit option to hardcode DIR into the resulting
 2007                 dnl binary.
 2008                 dnl Potentially add DIR to ltrpathdirs.
 2009                 dnl The ltrpathdirs will be appended to $LTLIBNAME at the end.
 2010                 haveit=
 2011                 for x in $ltrpathdirs; do
 2012                   if test "X$x" = "X$found_dir"; then
 2013                     haveit=yes
 2014                     break
 2015                   fi
 2016                 done
 2017                 if test -z "$haveit"; then
 2018                   ltrpathdirs="$ltrpathdirs $found_dir"
 2019                 fi
 2020                 dnl The hardcoding into $LIBNAME is system dependent.
 2021                 if test "$acl_hardcode_direct" = yes; then
 2022                   dnl Using DIR/libNAME.so during linking hardcodes DIR into the
 2023                   dnl resulting binary.
 2024                   LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so"
 2025                 else
 2026                   if test -n "$acl_hardcode_libdir_flag_spec" && test "$acl_hardcode_minus_L" = no; then
 2027                     dnl Use an explicit option to hardcode DIR into the resulting
 2028                     dnl binary.
 2029                     LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so"
 2030                     dnl Potentially add DIR to rpathdirs.
 2031                     dnl The rpathdirs will be appended to $LIBNAME at the end.
 2032                     haveit=
 2033                     for x in $rpathdirs; do
 2034                       if test "X$x" = "X$found_dir"; then
 2035                         haveit=yes
 2036                         break
 2037                       fi
 2038                     done
 2039                     if test -z "$haveit"; then
 2040                       rpathdirs="$rpathdirs $found_dir"
 2041                     fi
 2042                   else
 2043                     dnl Rely on "-L$found_dir".
 2044                     dnl But don't add it if it's already contained in the LDFLAGS
 2045                     dnl or the already constructed $LIBNAME
 2046                     haveit=
 2047                     for x in $LDFLAGS $LIB[]NAME; do
 2048                       AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
 2049                       if test "X$x" = "X-L$found_dir"; then
 2050                         haveit=yes
 2051                         break
 2052                       fi
 2053                     done
 2054                     if test -z "$haveit"; then
 2055                       LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-L$found_dir"
 2056                     fi
 2057                     if test "$acl_hardcode_minus_L" != no; then
 2058                       dnl FIXME: Not sure whether we should use
 2059                       dnl "-L$found_dir -l$name" or "-L$found_dir $found_so"
 2060                       dnl here.
 2061                       LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_so"
 2062                     else
 2063                       dnl We cannot use $acl_hardcode_runpath_var and LD_RUN_PATH
 2064                       dnl here, because this doesn't fit in flags passed to the
 2065                       dnl compiler. So give up. No hardcoding. This affects only
 2066                       dnl very old systems.
 2067                       dnl FIXME: Not sure whether we should use
 2068                       dnl "-L$found_dir -l$name" or "-L$found_dir $found_so"
 2069                       dnl here.
 2070                       LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-l$name"
 2071                     fi
 2072                   fi
 2073                 fi
 2074               fi
 2075             else
 2076               if test "X$found_a" != "X"; then
 2077                 dnl Linking with a static library.
 2078                 LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$found_a"
 2079               else
 2080                 dnl We shouldn't come here, but anyway it's good to have a
 2081                 dnl fallback.
 2082                 LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-L$found_dir -l$name"
 2083               fi
 2084             fi
 2085             dnl Assume the include files are nearby.
 2086             additional_includedir=
 2087             case "$found_dir" in
 2088               */$acl_libdirstem | */$acl_libdirstem/)
 2089                 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem/"'*$,,'`
 2090                 if test "$name" = '$1'; then
 2091                   LIB[]NAME[]_PREFIX="$basedir"
 2092                 fi
 2093                 additional_includedir="$basedir/include"
 2094                 ;;
 2095               */$acl_libdirstem2 | */$acl_libdirstem2/)
 2096                 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem2/"'*$,,'`
 2097                 if test "$name" = '$1'; then
 2098                   LIB[]NAME[]_PREFIX="$basedir"
 2099                 fi
 2100                 additional_includedir="$basedir/include"
 2101                 ;;
 2102               */$acl_libdirstem3 | */$acl_libdirstem3/)
 2103                 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem3/"'*$,,'`
 2104                 if test "$name" = '$1'; then
 2105                   LIB[]NAME[]_PREFIX="$basedir"
 2106                 fi
 2107                 additional_includedir="$basedir/include"
 2108                 ;;
 2109             esac
 2110             if test "X$additional_includedir" != "X"; then
 2111               dnl Potentially add $additional_includedir to $INCNAME.
 2112               dnl But don't add it
 2113               dnl   1. if it's the standard /usr/include,
 2114               dnl   2. if it's /usr/local/include and we are using GCC on Linux,
 2115               dnl   3. if it's already present in $CPPFLAGS or the already
 2116               dnl      constructed $INCNAME,
 2117               dnl   4. if it doesn't exist as a directory.
 2118               if test "X$additional_includedir" != "X/usr/include"; then
 2119                 haveit=
 2120                 if test "X$additional_includedir" = "X/usr/local/include"; then
 2121                   if test -n "$GCC"; then
 2122                     case $host_os in
 2123                       linux* | gnu* | k*bsd*-gnu) haveit=yes;;
 2124                     esac
 2125                   fi
 2126                 fi
 2127                 if test -z "$haveit"; then
 2128                   for x in $CPPFLAGS $INC[]NAME; do
 2129                     AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
 2130                     if test "X$x" = "X-I$additional_includedir"; then
 2131                       haveit=yes
 2132                       break
 2133                     fi
 2134                   done
 2135                   if test -z "$haveit"; then
 2136                     if test -d "$additional_includedir"; then
 2137                       dnl Really add $additional_includedir to $INCNAME.
 2138                       INC[]NAME="${INC[]NAME}${INC[]NAME:+ }-I$additional_includedir"
 2139                     fi
 2140                   fi
 2141                 fi
 2142               fi
 2143             fi
 2144             dnl Look for dependencies.
 2145             if test -n "$found_la"; then
 2146               dnl Read the .la file. It defines the variables
 2147               dnl dlname, library_names, old_library, dependency_libs, current,
 2148               dnl age, revision, installed, dlopen, dlpreopen, libdir.
 2149               save_libdir="$libdir"
 2150               case "$found_la" in
 2151                 */* | *\\*) . "$found_la" ;;
 2152                 *) . "./$found_la" ;;
 2153               esac
 2154               libdir="$save_libdir"
 2155               dnl We use only dependency_libs.
 2156               for dep in $dependency_libs; do
 2157                 case "$dep" in
 2158                   -L*)
 2159                     dependency_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
 2160                     dnl Potentially add $dependency_libdir to $LIBNAME and $LTLIBNAME.
 2161                     dnl But don't add it
 2162                     dnl   1. if it's the standard /usr/lib,
 2163                     dnl   2. if it's /usr/local/lib and we are using GCC on Linux,
 2164                     dnl   3. if it's already present in $LDFLAGS or the already
 2165                     dnl      constructed $LIBNAME,
 2166                     dnl   4. if it doesn't exist as a directory.
 2167                     if test "X$dependency_libdir" != "X/usr/$acl_libdirstem" \
 2168                        && test "X$dependency_libdir" != "X/usr/$acl_libdirstem2" \
 2169                        && test "X$dependency_libdir" != "X/usr/$acl_libdirstem3"; then
 2170                       haveit=
 2171                       if test "X$dependency_libdir" = "X/usr/local/$acl_libdirstem" \
 2172                          || test "X$dependency_libdir" = "X/usr/local/$acl_libdirstem2" \
 2173                          || test "X$dependency_libdir" = "X/usr/local/$acl_libdirstem3"; then
 2174                         if test -n "$GCC"; then
 2175                           case $host_os in
 2176                             linux* | gnu* | k*bsd*-gnu) haveit=yes;;
 2177                           esac
 2178                         fi
 2179                       fi
 2180                       if test -z "$haveit"; then
 2181                         haveit=
 2182                         for x in $LDFLAGS $LIB[]NAME; do
 2183                           AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
 2184                           if test "X$x" = "X-L$dependency_libdir"; then
 2185                             haveit=yes
 2186                             break
 2187                           fi
 2188                         done
 2189                         if test -z "$haveit"; then
 2190                           if test -d "$dependency_libdir"; then
 2191                             dnl Really add $dependency_libdir to $LIBNAME.
 2192                             LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-L$dependency_libdir"
 2193                           fi
 2194                         fi
 2195                         haveit=
 2196                         for x in $LDFLAGS $LTLIB[]NAME; do
 2197                           AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
 2198                           if test "X$x" = "X-L$dependency_libdir"; then
 2199                             haveit=yes
 2200                             break
 2201                           fi
 2202                         done
 2203                         if test -z "$haveit"; then
 2204                           if test -d "$dependency_libdir"; then
 2205                             dnl Really add $dependency_libdir to $LTLIBNAME.
 2206                             LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }-L$dependency_libdir"
 2207                           fi
 2208                         fi
 2209                       fi
 2210                     fi
 2211                     ;;
 2212                   -R*)
 2213                     dir=`echo "X$dep" | sed -e 's/^X-R//'`
 2214                     if test "$enable_rpath" != no; then
 2215                       dnl Potentially add DIR to rpathdirs.
 2216                       dnl The rpathdirs will be appended to $LIBNAME at the end.
 2217                       haveit=
 2218                       for x in $rpathdirs; do
 2219                         if test "X$x" = "X$dir"; then
 2220                           haveit=yes
 2221                           break
 2222                         fi
 2223                       done
 2224                       if test -z "$haveit"; then
 2225                         rpathdirs="$rpathdirs $dir"
 2226                       fi
 2227                       dnl Potentially add DIR to ltrpathdirs.
 2228                       dnl The ltrpathdirs will be appended to $LTLIBNAME at the end.
 2229                       haveit=
 2230                       for x in $ltrpathdirs; do
 2231                         if test "X$x" = "X$dir"; then
 2232                           haveit=yes
 2233                           break
 2234                         fi
 2235                       done
 2236                       if test -z "$haveit"; then
 2237                         ltrpathdirs="$ltrpathdirs $dir"
 2238                       fi
 2239                     fi
 2240                     ;;
 2241                   -l*)
 2242                     dnl Handle this in the next round.
 2243                     names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
 2244                     ;;
 2245                   *.la)
 2246                     dnl Handle this in the next round. Throw away the .la's
 2247                     dnl directory; it is already contained in a preceding -L
 2248                     dnl option.
 2249                     names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
 2250                     ;;
 2251                   *)
 2252                     dnl Most likely an immediate library name.
 2253                     LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$dep"
 2254                     LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }$dep"
 2255                     ;;
 2256                 esac
 2257               done
 2258             fi
 2259           else
 2260             dnl Didn't find the library; assume it is in the system directories
 2261             dnl known to the linker and runtime loader. (All the system
 2262             dnl directories known to the linker should also be known to the
 2263             dnl runtime loader, otherwise the system is severely misconfigured.)
 2264             LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }-l$name"
 2265             LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }-l$name"
 2266           fi
 2267         fi
 2268       fi
 2269     done
 2270   done
 2271   if test "X$rpathdirs" != "X"; then
 2272     if test -n "$acl_hardcode_libdir_separator"; then
 2273       dnl Weird platform: only the last -rpath option counts, the user must
 2274       dnl pass all path elements in one option. We can arrange that for a
 2275       dnl single library, but not when more than one $LIBNAMEs are used.
 2276       alldirs=
 2277       for found_dir in $rpathdirs; do
 2278         alldirs="${alldirs}${alldirs:+$acl_hardcode_libdir_separator}$found_dir"
 2279       done
 2280       dnl Note: acl_hardcode_libdir_flag_spec uses $libdir and $wl.
 2281       acl_save_libdir="$libdir"
 2282       libdir="$alldirs"
 2283       eval flag=\"$acl_hardcode_libdir_flag_spec\"
 2284       libdir="$acl_save_libdir"
 2285       LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$flag"
 2286     else
 2287       dnl The -rpath options are cumulative.
 2288       for found_dir in $rpathdirs; do
 2289         acl_save_libdir="$libdir"
 2290         libdir="$found_dir"
 2291         eval flag=\"$acl_hardcode_libdir_flag_spec\"
 2292         libdir="$acl_save_libdir"
 2293         LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$flag"
 2294       done
 2295     fi
 2296   fi
 2297   if test "X$ltrpathdirs" != "X"; then
 2298     dnl When using libtool, the option that works for both libraries and
 2299     dnl executables is -R. The -R options are cumulative.
 2300     for found_dir in $ltrpathdirs; do
 2301       LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }-R$found_dir"
 2302     done
 2303   fi
 2304   popdef([PACKLIBS])
 2305   popdef([PACKUP])
 2306   popdef([PACK])
 2307   popdef([NAME])
 2308 ])
 2309 
 2310 dnl AC_LIB_APPENDTOVAR(VAR, CONTENTS) appends the elements of CONTENTS to VAR,
 2311 dnl unless already present in VAR.
 2312 dnl Works only for CPPFLAGS, not for LIB* variables because that sometimes
 2313 dnl contains two or three consecutive elements that belong together.
 2314 AC_DEFUN([AC_LIB_APPENDTOVAR],
 2315 [
 2316   for element in [$2]; do
 2317     haveit=
 2318     for x in $[$1]; do
 2319       AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
 2320       if test "X$x" = "X$element"; then
 2321         haveit=yes
 2322         break
 2323       fi
 2324     done
 2325     if test -z "$haveit"; then
 2326       [$1]="${[$1]}${[$1]:+ }$element"
 2327     fi
 2328   done
 2329 ])
 2330 
 2331 dnl For those cases where a variable contains several -L and -l options
 2332 dnl referring to unknown libraries and directories, this macro determines the
 2333 dnl necessary additional linker options for the runtime path.
 2334 dnl AC_LIB_LINKFLAGS_FROM_LIBS([LDADDVAR], [LIBSVALUE], [USE-LIBTOOL])
 2335 dnl sets LDADDVAR to linker options needed together with LIBSVALUE.
 2336 dnl If USE-LIBTOOL evaluates to non-empty, linking with libtool is assumed,
 2337 dnl otherwise linking without libtool is assumed.
 2338 AC_DEFUN([AC_LIB_LINKFLAGS_FROM_LIBS],
 2339 [
 2340   AC_REQUIRE([AC_LIB_RPATH])
 2341   AC_REQUIRE([AC_LIB_PREPARE_MULTILIB])
 2342   $1=
 2343   if test "$enable_rpath" != no; then
 2344     if test -n "$acl_hardcode_libdir_flag_spec" && test "$acl_hardcode_minus_L" = no; then
 2345       dnl Use an explicit option to hardcode directories into the resulting
 2346       dnl binary.
 2347       rpathdirs=
 2348       next=
 2349       for opt in $2; do
 2350         if test -n "$next"; then
 2351           dir="$next"
 2352           dnl No need to hardcode the standard /usr/lib.
 2353           if test "X$dir" != "X/usr/$acl_libdirstem" \
 2354              && test "X$dir" != "X/usr/$acl_libdirstem2" \
 2355              && test "X$dir" != "X/usr/$acl_libdirstem3"; then
 2356             rpathdirs="$rpathdirs $dir"
 2357           fi
 2358           next=
 2359         else
 2360           case $opt in
 2361             -L) next=yes ;;
 2362             -L*) dir=`echo "X$opt" | sed -e 's,^X-L,,'`
 2363                  dnl No need to hardcode the standard /usr/lib.
 2364                  if test "X$dir" != "X/usr/$acl_libdirstem" \
 2365                     && test "X$dir" != "X/usr/$acl_libdirstem2" \
 2366                     && test "X$dir" != "X/usr/$acl_libdirstem3"; then
 2367                    rpathdirs="$rpathdirs $dir"
 2368                  fi
 2369                  next= ;;
 2370             *) next= ;;
 2371           esac
 2372         fi
 2373       done
 2374       if test "X$rpathdirs" != "X"; then
 2375         if test -n ""$3""; then
 2376           dnl libtool is used for linking. Use -R options.
 2377           for dir in $rpathdirs; do
 2378             $1="${$1}${$1:+ }-R$dir"
 2379           done
 2380         else
 2381           dnl The linker is used for linking directly.
 2382           if test -n "$acl_hardcode_libdir_separator"; then
 2383             dnl Weird platform: only the last -rpath option counts, the user
 2384             dnl must pass all path elements in one option.
 2385             alldirs=
 2386             for dir in $rpathdirs; do
 2387               alldirs="${alldirs}${alldirs:+$acl_hardcode_libdir_separator}$dir"
 2388             done
 2389             acl_save_libdir="$libdir"
 2390             libdir="$alldirs"
 2391             eval flag=\"$acl_hardcode_libdir_flag_spec\"
 2392             libdir="$acl_save_libdir"
 2393             $1="$flag"
 2394           else
 2395             dnl The -rpath options are cumulative.
 2396             for dir in $rpathdirs; do
 2397               acl_save_libdir="$libdir"
 2398               libdir="$dir"
 2399               eval flag=\"$acl_hardcode_libdir_flag_spec\"
 2400               libdir="$acl_save_libdir"
 2401               $1="${$1}${$1:+ }$flag"
 2402             done
 2403           fi
 2404         fi
 2405       fi
 2406     fi
 2407   fi
 2408   AC_SUBST([$1])
 2409 ])
 2410 
 2411 # lib-prefix.m4 serial 17
 2412 dnl Copyright (C) 2001-2005, 2008-2020 Free Software Foundation, Inc.
 2413 dnl This file is free software; the Free Software Foundation
 2414 dnl gives unlimited permission to copy and/or distribute it,
 2415 dnl with or without modifications, as long as this notice is preserved.
 2416 
 2417 dnl From Bruno Haible.
 2418 
 2419 dnl AC_LIB_PREFIX adds to the CPPFLAGS and LDFLAGS the flags that are needed
 2420 dnl to access previously installed libraries. The basic assumption is that
 2421 dnl a user will want packages to use other packages he previously installed
 2422 dnl with the same --prefix option.
 2423 dnl This macro is not needed if only AC_LIB_LINKFLAGS is used to locate
 2424 dnl libraries, but is otherwise very convenient.
 2425 AC_DEFUN([AC_LIB_PREFIX],
 2426 [
 2427   AC_BEFORE([$0], [AC_LIB_LINKFLAGS])
 2428   AC_REQUIRE([AC_PROG_CC])
 2429   AC_REQUIRE([AC_CANONICAL_HOST])
 2430   AC_REQUIRE([AC_LIB_PREPARE_MULTILIB])
 2431   AC_REQUIRE([AC_LIB_PREPARE_PREFIX])
 2432   dnl By default, look in $includedir and $libdir.
 2433   use_additional=yes
 2434   AC_LIB_WITH_FINAL_PREFIX([
 2435     eval additional_includedir=\"$includedir\"
 2436     eval additional_libdir=\"$libdir\"
 2437   ])
 2438   AC_ARG_WITH([lib-prefix],
 2439 [[  --with-lib-prefix[=DIR] search for libraries in DIR/include and DIR/lib
 2440   --without-lib-prefix    don't search for libraries in includedir and libdir]],
 2441 [
 2442     if test "X$withval" = "Xno"; then
 2443       use_additional=no
 2444     else
 2445       if test "X$withval" = "X"; then
 2446         AC_LIB_WITH_FINAL_PREFIX([
 2447           eval additional_includedir=\"$includedir\"
 2448           eval additional_libdir=\"$libdir\"
 2449         ])
 2450       else
 2451         additional_includedir="$withval/include"
 2452         additional_libdir="$withval/$acl_libdirstem"
 2453       fi
 2454     fi
 2455 ])
 2456   if test $use_additional = yes; then
 2457     dnl Potentially add $additional_includedir to $CPPFLAGS.
 2458     dnl But don't add it
 2459     dnl   1. if it's the standard /usr/include,
 2460     dnl   2. if it's already present in $CPPFLAGS,
 2461     dnl   3. if it's /usr/local/include and we are using GCC on Linux,
 2462     dnl   4. if it doesn't exist as a directory.
 2463     if test "X$additional_includedir" != "X/usr/include"; then
 2464       haveit=
 2465       for x in $CPPFLAGS; do
 2466         AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
 2467         if test "X$x" = "X-I$additional_includedir"; then
 2468           haveit=yes
 2469           break
 2470         fi
 2471       done
 2472       if test -z "$haveit"; then
 2473         if test "X$additional_includedir" = "X/usr/local/include"; then
 2474           if test -n "$GCC"; then
 2475             case $host_os in
 2476               linux* | gnu* | k*bsd*-gnu) haveit=yes;;
 2477             esac
 2478           fi
 2479         fi
 2480         if test -z "$haveit"; then
 2481           if test -d "$additional_includedir"; then
 2482             dnl Really add $additional_includedir to $CPPFLAGS.
 2483             CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }-I$additional_includedir"
 2484           fi
 2485         fi
 2486       fi
 2487     fi
 2488     dnl Potentially add $additional_libdir to $LDFLAGS.
 2489     dnl But don't add it
 2490     dnl   1. if it's the standard /usr/lib,
 2491     dnl   2. if it's already present in $LDFLAGS,
 2492     dnl   3. if it's /usr/local/lib and we are using GCC on Linux,
 2493     dnl   4. if it doesn't exist as a directory.
 2494     if test "X$additional_libdir" != "X/usr/$acl_libdirstem"; then
 2495       haveit=
 2496       for x in $LDFLAGS; do
 2497         AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])
 2498         if test "X$x" = "X-L$additional_libdir"; then
 2499           haveit=yes
 2500           break
 2501         fi
 2502       done
 2503       if test -z "$haveit"; then
 2504         if test "X$additional_libdir" = "X/usr/local/$acl_libdirstem"; then
 2505           if test -n "$GCC"; then
 2506             case $host_os in
 2507               linux*) haveit=yes;;
 2508             esac
 2509           fi
 2510         fi
 2511         if test -z "$haveit"; then
 2512           if test -d "$additional_libdir"; then
 2513             dnl Really add $additional_libdir to $LDFLAGS.
 2514             LDFLAGS="${LDFLAGS}${LDFLAGS:+ }-L$additional_libdir"
 2515           fi
 2516         fi
 2517       fi
 2518     fi
 2519   fi
 2520 ])
 2521 
 2522 dnl AC_LIB_PREPARE_PREFIX creates variables acl_final_prefix,
 2523 dnl acl_final_exec_prefix, containing the values to which $prefix and
 2524 dnl $exec_prefix will expand at the end of the configure script.
 2525 AC_DEFUN([AC_LIB_PREPARE_PREFIX],
 2526 [
 2527   dnl Unfortunately, prefix and exec_prefix get only finally determined
 2528   dnl at the end of configure.
 2529   if test "X$prefix" = "XNONE"; then
 2530     acl_final_prefix="$ac_default_prefix"
 2531   else
 2532     acl_final_prefix="$prefix"
 2533   fi
 2534   if test "X$exec_prefix" = "XNONE"; then
 2535     acl_final_exec_prefix='${prefix}'
 2536   else
 2537     acl_final_exec_prefix="$exec_prefix"
 2538   fi
 2539   acl_save_prefix="$prefix"
 2540   prefix="$acl_final_prefix"
 2541   eval acl_final_exec_prefix=\"$acl_final_exec_prefix\"
 2542   prefix="$acl_save_prefix"
 2543 ])
 2544 
 2545 dnl AC_LIB_WITH_FINAL_PREFIX([statement]) evaluates statement, with the
 2546 dnl variables prefix and exec_prefix bound to the values they will have
 2547 dnl at the end of the configure script.
 2548 AC_DEFUN([AC_LIB_WITH_FINAL_PREFIX],
 2549 [
 2550   acl_save_prefix="$prefix"
 2551   prefix="$acl_final_prefix"
 2552   acl_save_exec_prefix="$exec_prefix"
 2553   exec_prefix="$acl_final_exec_prefix"
 2554   $1
 2555   exec_prefix="$acl_save_exec_prefix"
 2556   prefix="$acl_save_prefix"
 2557 ])
 2558 
 2559 dnl AC_LIB_PREPARE_MULTILIB creates
 2560 dnl - a function acl_is_expected_elfclass, that tests whether standard input
 2561 dn;   has a 32-bit or 64-bit ELF header, depending on the host CPU ABI,
 2562 dnl - 3 variables acl_libdirstem, acl_libdirstem2, acl_libdirstem3, containing
 2563 dnl   the basename of the libdir to try in turn, either "lib" or "lib64" or
 2564 dnl   "lib/64" or "lib32" or "lib/sparcv9" or "lib/amd64" or similar.
 2565 AC_DEFUN([AC_LIB_PREPARE_MULTILIB],
 2566 [
 2567   dnl There is no formal standard regarding lib, lib32, and lib64.
 2568   dnl On most glibc systems, the current practice is that on a system supporting
 2569   dnl 32-bit and 64-bit instruction sets or ABIs, 64-bit libraries go under
 2570   dnl $prefix/lib64 and 32-bit libraries go under $prefix/lib. However, on
 2571   dnl Arch Linux based distributions, it's the opposite: 32-bit libraries go
 2572   dnl under $prefix/lib32 and 64-bit libraries go under $prefix/lib.
 2573   dnl We determine the compiler's default mode by looking at the compiler's
 2574   dnl library search path. If at least one of its elements ends in /lib64 or
 2575   dnl points to a directory whose absolute pathname ends in /lib64, we use that
 2576   dnl for 64-bit ABIs. Similarly for 32-bit ABIs. Otherwise we use the default,
 2577   dnl namely "lib".
 2578   dnl On Solaris systems, the current practice is that on a system supporting
 2579   dnl 32-bit and 64-bit instruction sets or ABIs, 64-bit libraries go under
 2580   dnl $prefix/lib/64 (which is a symlink to either $prefix/lib/sparcv9 or
 2581   dnl $prefix/lib/amd64) and 32-bit libraries go under $prefix/lib.
 2582   AC_REQUIRE([AC_CANONICAL_HOST])
 2583   AC_REQUIRE([gl_HOST_CPU_C_ABI_32BIT])
 2584 
 2585   AC_CACHE_CHECK([for ELF binary format], [gl_cv_elf],
 2586     [AC_EGREP_CPP([Extensible Linking Format],
 2587        [#ifdef __ELF__
 2588         Extensible Linking Format
 2589         #endif
 2590        ],
 2591        [gl_cv_elf=yes],
 2592        [gl_cv_elf=no])
 2593      ])
 2594   if test $gl_cv_elf; then
 2595     # Extract the ELF class of a file (5th byte) in decimal.
 2596     # Cf. https://en.wikipedia.org/wiki/Executable_and_Linkable_Format#File_header
 2597     if od -A x < /dev/null >/dev/null 2>/dev/null; then
 2598       # Use POSIX od.
 2599       func_elfclass ()
 2600       {
 2601         od -A n -t d1 -j 4 -N 1
 2602       }
 2603     else
 2604       # Use BSD hexdump.
 2605       func_elfclass ()
 2606       {
 2607         dd bs=1 count=1 skip=4 2>/dev/null | hexdump -e '1/1 "%3d "'
 2608         echo
 2609       }
 2610     fi
 2611 changequote(,)dnl
 2612     case $HOST_CPU_C_ABI_32BIT in
 2613       yes)
 2614         # 32-bit ABI.
 2615         acl_is_expected_elfclass ()
 2616         {
 2617           test "`func_elfclass | sed -e 's/[ 	]//g'`" = 1
 2618         }
 2619         ;;
 2620       no)
 2621         # 64-bit ABI.
 2622         acl_is_expected_elfclass ()
 2623         {
 2624           test "`func_elfclass | sed -e 's/[ 	]//g'`" = 2
 2625         }
 2626         ;;
 2627       *)
 2628         # Unknown.
 2629         acl_is_expected_elfclass ()
 2630         {
 2631           :
 2632         }
 2633         ;;
 2634     esac
 2635 changequote([,])dnl
 2636   else
 2637     acl_is_expected_elfclass ()
 2638     {
 2639       :
 2640     }
 2641   fi
 2642 
 2643   dnl Allow the user to override the result by setting acl_cv_libdirstems.
 2644   AC_CACHE_CHECK([for the common suffixes of directories in the library search path],
 2645     [acl_cv_libdirstems],
 2646     [dnl Try 'lib' first, because that's the default for libdir in GNU, see
 2647      dnl <https://www.gnu.org/prep/standards/html_node/Directory-Variables.html>.
 2648      acl_libdirstem=lib
 2649      acl_libdirstem2=
 2650      acl_libdirstem3=
 2651      case "$host_os" in
 2652        solaris*)
 2653          dnl See Solaris 10 Software Developer Collection > Solaris 64-bit Developer's Guide > The Development Environment
 2654          dnl <https://docs.oracle.com/cd/E19253-01/816-5138/dev-env/index.html>.
 2655          dnl "Portable Makefiles should refer to any library directories using the 64 symbolic link."
 2656          dnl But we want to recognize the sparcv9 or amd64 subdirectory also if the
 2657          dnl symlink is missing, so we set acl_libdirstem2 too.
 2658          if test $HOST_CPU_C_ABI_32BIT = no; then
 2659            acl_libdirstem2=lib/64
 2660            case "$host_cpu" in
 2661              sparc*)        acl_libdirstem3=lib/sparcv9 ;;
 2662              i*86 | x86_64) acl_libdirstem3=lib/amd64 ;;
 2663            esac
 2664          fi
 2665          ;;
 2666        *)
 2667          dnl If $CC generates code for a 32-bit ABI, the libraries are
 2668          dnl surely under $prefix/lib or $prefix/lib32, not $prefix/lib64.
 2669          dnl Similarly, if $CC generates code for a 64-bit ABI, the libraries
 2670          dnl are surely under $prefix/lib or $prefix/lib64, not $prefix/lib32.
 2671          dnl Find the compiler's search path. However, non-system compilers
 2672          dnl sometimes have odd library search paths. But we can't simply invoke
 2673          dnl '/usr/bin/gcc -print-search-dirs' because that would not take into
 2674          dnl account the -m32/-m31 or -m64 options from the $CC or $CFLAGS.
 2675          searchpath=`(LC_ALL=C $CC $CPPFLAGS $CFLAGS -print-search-dirs) 2>/dev/null \
 2676                      | sed -n -e 's,^libraries: ,,p' | sed -e 's,^=,,'`
 2677          if test $HOST_CPU_C_ABI_32BIT != no; then
 2678            # 32-bit or unknown ABI.
 2679            if test -d /usr/lib32; then
 2680              acl_libdirstem2=lib32
 2681            fi
 2682          fi
 2683          if test $HOST_CPU_C_ABI_32BIT != yes; then
 2684            # 64-bit or unknown ABI.
 2685            if test -d /usr/lib64; then
 2686              acl_libdirstem3=lib64
 2687            fi
 2688          fi
 2689          if test -n "$searchpath"; then
 2690            acl_save_IFS="${IFS= 	}"; IFS=":"
 2691            for searchdir in $searchpath; do
 2692              if test -d "$searchdir"; then
 2693                case "$searchdir" in
 2694                  */lib32/ | */lib32 ) acl_libdirstem2=lib32 ;;
 2695                  */lib64/ | */lib64 ) acl_libdirstem3=lib64 ;;
 2696                  */../ | */.. )
 2697                    # Better ignore directories of this form. They are misleading.
 2698                    ;;
 2699                  *) searchdir=`cd "$searchdir" && pwd`
 2700                     case "$searchdir" in
 2701                       */lib32 ) acl_libdirstem2=lib32 ;;
 2702                       */lib64 ) acl_libdirstem3=lib64 ;;
 2703                     esac ;;
 2704                esac
 2705              fi
 2706            done
 2707            IFS="$acl_save_IFS"
 2708            if test $HOST_CPU_C_ABI_32BIT = yes; then
 2709              # 32-bit ABI.
 2710              acl_libdirstem3=
 2711            fi
 2712            if test $HOST_CPU_C_ABI_32BIT = no; then
 2713              # 64-bit ABI.
 2714              acl_libdirstem2=
 2715            fi
 2716          fi
 2717          ;;
 2718      esac
 2719      test -n "$acl_libdirstem2" || acl_libdirstem2="$acl_libdirstem"
 2720      test -n "$acl_libdirstem3" || acl_libdirstem3="$acl_libdirstem"
 2721      acl_cv_libdirstems="$acl_libdirstem,$acl_libdirstem2,$acl_libdirstem3"
 2722     ])
 2723   dnl Decompose acl_cv_libdirstems into acl_libdirstem, acl_libdirstem2, and
 2724   dnl acl_libdirstem3.
 2725 changequote(,)dnl
 2726   acl_libdirstem=`echo "$acl_cv_libdirstems" | sed -e 's/,.*//'`
 2727   acl_libdirstem2=`echo "$acl_cv_libdirstems" | sed -e 's/^[^,]*,//' -e 's/,.*//'`
 2728   acl_libdirstem3=`echo "$acl_cv_libdirstems" | sed -e 's/^[^,]*,[^,]*,//' -e 's/,.*//'`
 2729 changequote([,])dnl
 2730 ])
 2731 
 2732 # nls.m4 serial 6 (gettext-0.20.2)
 2733 dnl Copyright (C) 1995-2003, 2005-2006, 2008-2014, 2016, 2019-2020 Free
 2734 dnl Software Foundation, Inc.
 2735 dnl This file is free software; the Free Software Foundation
 2736 dnl gives unlimited permission to copy and/or distribute it,
 2737 dnl with or without modifications, as long as this notice is preserved.
 2738 dnl
 2739 dnl This file can be used in projects which are not available under
 2740 dnl the GNU General Public License or the GNU Lesser General Public
 2741 dnl License but which still want to provide support for the GNU gettext
 2742 dnl functionality.
 2743 dnl Please note that the actual code of the GNU gettext library is covered
 2744 dnl by the GNU Lesser General Public License, and the rest of the GNU
 2745 dnl gettext package is covered by the GNU General Public License.
 2746 dnl They are *not* in the public domain.
 2747 
 2748 dnl Authors:
 2749 dnl   Ulrich Drepper <drepper@cygnus.com>, 1995-2000.
 2750 dnl   Bruno Haible <haible@clisp.cons.org>, 2000-2003.
 2751 
 2752 AC_PREREQ([2.50])
 2753 
 2754 AC_DEFUN([AM_NLS],
 2755 [
 2756   AC_MSG_CHECKING([whether NLS is requested])
 2757   dnl Default is enabled NLS
 2758   AC_ARG_ENABLE([nls],
 2759     [  --disable-nls           do not use Native Language Support],
 2760     USE_NLS=$enableval, USE_NLS=yes)
 2761   AC_MSG_RESULT([$USE_NLS])
 2762   AC_SUBST([USE_NLS])
 2763 ])
 2764 
 2765 # pkg.m4 - Macros to locate and utilise pkg-config.   -*- Autoconf -*-
 2766 # serial 12 (pkg-config-0.29.2)
 2767 
 2768 dnl Copyright © 2004 Scott James Remnant <scott@netsplit.com>.
 2769 dnl Copyright © 2012-2015 Dan Nicholson <dbn.lists@gmail.com>
 2770 dnl
 2771 dnl This program is free software; you can redistribute it and/or modify
 2772 dnl it under the terms of the GNU General Public License as published by
 2773 dnl the Free Software Foundation; either version 2 of the License, or
 2774 dnl (at your option) any later version.
 2775 dnl
 2776 dnl This program is distributed in the hope that it will be useful, but
 2777 dnl WITHOUT ANY WARRANTY; without even the implied warranty of
 2778 dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 2779 dnl General Public License for more details.
 2780 dnl
 2781 dnl You should have received a copy of the GNU General Public License
 2782 dnl along with this program; if not, write to the Free Software
 2783 dnl Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
 2784 dnl 02111-1307, USA.
 2785 dnl
 2786 dnl As a special exception to the GNU General Public License, if you
 2787 dnl distribute this file as part of a program that contains a
 2788 dnl configuration script generated by Autoconf, you may include it under
 2789 dnl the same distribution terms that you use for the rest of that
 2790 dnl program.
 2791 
 2792 dnl PKG_PREREQ(MIN-VERSION)
 2793 dnl -----------------------
 2794 dnl Since: 0.29
 2795 dnl
 2796 dnl Verify that the version of the pkg-config macros are at least
 2797 dnl MIN-VERSION. Unlike PKG_PROG_PKG_CONFIG, which checks the user's
 2798 dnl installed version of pkg-config, this checks the developer's version
 2799 dnl of pkg.m4 when generating configure.
 2800 dnl
 2801 dnl To ensure that this macro is defined, also add:
 2802 dnl m4_ifndef([PKG_PREREQ],
 2803 dnl     [m4_fatal([must install pkg-config 0.29 or later before running autoconf/autogen])])
 2804 dnl
 2805 dnl See the "Since" comment for each macro you use to see what version
 2806 dnl of the macros you require.
 2807 m4_defun([PKG_PREREQ],
 2808 [m4_define([PKG_MACROS_VERSION], [0.29.2])
 2809 m4_if(m4_version_compare(PKG_MACROS_VERSION, [$1]), -1,
 2810     [m4_fatal([pkg.m4 version $1 or higher is required but ]PKG_MACROS_VERSION[ found])])
 2811 ])dnl PKG_PREREQ
 2812 
 2813 dnl PKG_PROG_PKG_CONFIG([MIN-VERSION])
 2814 dnl ----------------------------------
 2815 dnl Since: 0.16
 2816 dnl
 2817 dnl Search for the pkg-config tool and set the PKG_CONFIG variable to
 2818 dnl first found in the path. Checks that the version of pkg-config found
 2819 dnl is at least MIN-VERSION. If MIN-VERSION is not specified, 0.9.0 is
 2820 dnl used since that's the first version where most current features of
 2821 dnl pkg-config existed.
 2822 AC_DEFUN([PKG_PROG_PKG_CONFIG],
 2823 [m4_pattern_forbid([^_?PKG_[A-Z_]+$])
 2824 m4_pattern_allow([^PKG_CONFIG(_(PATH|LIBDIR|SYSROOT_DIR|ALLOW_SYSTEM_(CFLAGS|LIBS)))?$])
 2825 m4_pattern_allow([^PKG_CONFIG_(DISABLE_UNINSTALLED|TOP_BUILD_DIR|DEBUG_SPEW)$])
 2826 AC_ARG_VAR([PKG_CONFIG], [path to pkg-config utility])
 2827 AC_ARG_VAR([PKG_CONFIG_PATH], [directories to add to pkg-config's search path])
 2828 AC_ARG_VAR([PKG_CONFIG_LIBDIR], [path overriding pkg-config's built-in search path])
 2829 
 2830 if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
 2831 	AC_PATH_TOOL([PKG_CONFIG], [pkg-config])
 2832 fi
 2833 if test -n "$PKG_CONFIG"; then
 2834 	_pkg_min_version=m4_default([$1], [0.9.0])
 2835 	AC_MSG_CHECKING([pkg-config is at least version $_pkg_min_version])
 2836 	if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
 2837 		AC_MSG_RESULT([yes])
 2838 	else
 2839 		AC_MSG_RESULT([no])
 2840 		PKG_CONFIG=""
 2841 	fi
 2842 fi[]dnl
 2843 ])dnl PKG_PROG_PKG_CONFIG
 2844 
 2845 dnl PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
 2846 dnl -------------------------------------------------------------------
 2847 dnl Since: 0.18
 2848 dnl
 2849 dnl Check to see whether a particular set of modules exists. Similar to
 2850 dnl PKG_CHECK_MODULES(), but does not set variables or print errors.
 2851 dnl
 2852 dnl Please remember that m4 expands AC_REQUIRE([PKG_PROG_PKG_CONFIG])
 2853 dnl only at the first occurence in configure.ac, so if the first place
 2854 dnl it's called might be skipped (such as if it is within an "if", you
 2855 dnl have to call PKG_CHECK_EXISTS manually
 2856 AC_DEFUN([PKG_CHECK_EXISTS],
 2857 [AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl
 2858 if test -n "$PKG_CONFIG" && \
 2859     AC_RUN_LOG([$PKG_CONFIG --exists --print-errors "$1"]); then
 2860   m4_default([$2], [:])
 2861 m4_ifvaln([$3], [else
 2862   $3])dnl
 2863 fi])
 2864 
 2865 dnl _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES])
 2866 dnl ---------------------------------------------
 2867 dnl Internal wrapper calling pkg-config via PKG_CONFIG and setting
 2868 dnl pkg_failed based on the result.
 2869 m4_define([_PKG_CONFIG],
 2870 [if test -n "$$1"; then
 2871     pkg_cv_[]$1="$$1"
 2872  elif test -n "$PKG_CONFIG"; then
 2873     PKG_CHECK_EXISTS([$3],
 2874                      [pkg_cv_[]$1=`$PKG_CONFIG --[]$2 "$3" 2>/dev/null`
 2875 		      test "x$?" != "x0" && pkg_failed=yes ],
 2876 		     [pkg_failed=yes])
 2877  else
 2878     pkg_failed=untried
 2879 fi[]dnl
 2880 ])dnl _PKG_CONFIG
 2881 
 2882 dnl _PKG_SHORT_ERRORS_SUPPORTED
 2883 dnl ---------------------------
 2884 dnl Internal check to see if pkg-config supports short errors.
 2885 AC_DEFUN([_PKG_SHORT_ERRORS_SUPPORTED],
 2886 [AC_REQUIRE([PKG_PROG_PKG_CONFIG])
 2887 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
 2888         _pkg_short_errors_supported=yes
 2889 else
 2890         _pkg_short_errors_supported=no
 2891 fi[]dnl
 2892 ])dnl _PKG_SHORT_ERRORS_SUPPORTED
 2893 
 2894 
 2895 dnl PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND],
 2896 dnl   [ACTION-IF-NOT-FOUND])
 2897 dnl --------------------------------------------------------------
 2898 dnl Since: 0.4.0
 2899 dnl
 2900 dnl Note that if there is a possibility the first call to
 2901 dnl PKG_CHECK_MODULES might not happen, you should be sure to include an
 2902 dnl explicit call to PKG_PROG_PKG_CONFIG in your configure.ac
 2903 AC_DEFUN([PKG_CHECK_MODULES],
 2904 [AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl
 2905 AC_ARG_VAR([$1][_CFLAGS], [C compiler flags for $1, overriding pkg-config])dnl
 2906 AC_ARG_VAR([$1][_LIBS], [linker flags for $1, overriding pkg-config])dnl
 2907 
 2908 pkg_failed=no
 2909 AC_MSG_CHECKING([for $2])
 2910 
 2911 _PKG_CONFIG([$1][_CFLAGS], [cflags], [$2])
 2912 _PKG_CONFIG([$1][_LIBS], [libs], [$2])
 2913 
 2914 m4_define([_PKG_TEXT], [Alternatively, you may set the environment variables $1[]_CFLAGS
 2915 and $1[]_LIBS to avoid the need to call pkg-config.
 2916 See the pkg-config man page for more details.])
 2917 
 2918 if test $pkg_failed = yes; then
 2919         AC_MSG_RESULT([no])
 2920         _PKG_SHORT_ERRORS_SUPPORTED
 2921         if test $_pkg_short_errors_supported = yes; then
 2922 	        $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "$2" 2>&1`
 2923         else
 2924 	        $1[]_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "$2" 2>&1`
 2925         fi
 2926 	# Put the nasty error message in config.log where it belongs
 2927 	echo "$$1[]_PKG_ERRORS" >&AS_MESSAGE_LOG_FD
 2928 
 2929 	m4_default([$4], [AC_MSG_ERROR(
 2930 [Package requirements ($2) were not met:
 2931 
 2932 $$1_PKG_ERRORS
 2933 
 2934 Consider adjusting the PKG_CONFIG_PATH environment variable if you
 2935 installed software in a non-standard prefix.
 2936 
 2937 _PKG_TEXT])[]dnl
 2938         ])
 2939 elif test $pkg_failed = untried; then
 2940         AC_MSG_RESULT([no])
 2941 	m4_default([$4], [AC_MSG_FAILURE(
 2942 [The pkg-config script could not be found or is too old.  Make sure it
 2943 is in your PATH or set the PKG_CONFIG environment variable to the full
 2944 path to pkg-config.
 2945 
 2946 _PKG_TEXT
 2947 
 2948 To get pkg-config, see <http://pkg-config.freedesktop.org/>.])[]dnl
 2949         ])
 2950 else
 2951 	$1[]_CFLAGS=$pkg_cv_[]$1[]_CFLAGS
 2952 	$1[]_LIBS=$pkg_cv_[]$1[]_LIBS
 2953         AC_MSG_RESULT([yes])
 2954 	$3
 2955 fi[]dnl
 2956 ])dnl PKG_CHECK_MODULES
 2957 
 2958 
 2959 dnl PKG_CHECK_MODULES_STATIC(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND],
 2960 dnl   [ACTION-IF-NOT-FOUND])
 2961 dnl ---------------------------------------------------------------------
 2962 dnl Since: 0.29
 2963 dnl
 2964 dnl Checks for existence of MODULES and gathers its build flags with
 2965 dnl static libraries enabled. Sets VARIABLE-PREFIX_CFLAGS from --cflags
 2966 dnl and VARIABLE-PREFIX_LIBS from --libs.
 2967 dnl
 2968 dnl Note that if there is a possibility the first call to
 2969 dnl PKG_CHECK_MODULES_STATIC might not happen, you should be sure to
 2970 dnl include an explicit call to PKG_PROG_PKG_CONFIG in your
 2971 dnl configure.ac.
 2972 AC_DEFUN([PKG_CHECK_MODULES_STATIC],
 2973 [AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl
 2974 _save_PKG_CONFIG=$PKG_CONFIG
 2975 PKG_CONFIG="$PKG_CONFIG --static"
 2976 PKG_CHECK_MODULES($@)
 2977 PKG_CONFIG=$_save_PKG_CONFIG[]dnl
 2978 ])dnl PKG_CHECK_MODULES_STATIC
 2979 
 2980 
 2981 dnl PKG_INSTALLDIR([DIRECTORY])
 2982 dnl -------------------------
 2983 dnl Since: 0.27
 2984 dnl
 2985 dnl Substitutes the variable pkgconfigdir as the location where a module
 2986 dnl should install pkg-config .pc files. By default the directory is
 2987 dnl $libdir/pkgconfig, but the default can be changed by passing
 2988 dnl DIRECTORY. The user can override through the --with-pkgconfigdir
 2989 dnl parameter.
 2990 AC_DEFUN([PKG_INSTALLDIR],
 2991 [m4_pushdef([pkg_default], [m4_default([$1], ['${libdir}/pkgconfig'])])
 2992 m4_pushdef([pkg_description],
 2993     [pkg-config installation directory @<:@]pkg_default[@:>@])
 2994 AC_ARG_WITH([pkgconfigdir],
 2995     [AS_HELP_STRING([--with-pkgconfigdir], pkg_description)],,
 2996     [with_pkgconfigdir=]pkg_default)
 2997 AC_SUBST([pkgconfigdir], [$with_pkgconfigdir])
 2998 m4_popdef([pkg_default])
 2999 m4_popdef([pkg_description])
 3000 ])dnl PKG_INSTALLDIR
 3001 
 3002 
 3003 dnl PKG_NOARCH_INSTALLDIR([DIRECTORY])
 3004 dnl --------------------------------
 3005 dnl Since: 0.27
 3006 dnl
 3007 dnl Substitutes the variable noarch_pkgconfigdir as the location where a
 3008 dnl module should install arch-independent pkg-config .pc files. By
 3009 dnl default the directory is $datadir/pkgconfig, but the default can be
 3010 dnl changed by passing DIRECTORY. The user can override through the
 3011 dnl --with-noarch-pkgconfigdir parameter.
 3012 AC_DEFUN([PKG_NOARCH_INSTALLDIR],
 3013 [m4_pushdef([pkg_default], [m4_default([$1], ['${datadir}/pkgconfig'])])
 3014 m4_pushdef([pkg_description],
 3015     [pkg-config arch-independent installation directory @<:@]pkg_default[@:>@])
 3016 AC_ARG_WITH([noarch-pkgconfigdir],
 3017     [AS_HELP_STRING([--with-noarch-pkgconfigdir], pkg_description)],,
 3018     [with_noarch_pkgconfigdir=]pkg_default)
 3019 AC_SUBST([noarch_pkgconfigdir], [$with_noarch_pkgconfigdir])
 3020 m4_popdef([pkg_default])
 3021 m4_popdef([pkg_description])
 3022 ])dnl PKG_NOARCH_INSTALLDIR
 3023 
 3024 
 3025 dnl PKG_CHECK_VAR(VARIABLE, MODULE, CONFIG-VARIABLE,
 3026 dnl [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
 3027 dnl -------------------------------------------
 3028 dnl Since: 0.28
 3029 dnl
 3030 dnl Retrieves the value of the pkg-config variable for the given module.
 3031 AC_DEFUN([PKG_CHECK_VAR],
 3032 [AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl
 3033 AC_ARG_VAR([$1], [value of $3 for $2, overriding pkg-config])dnl
 3034 
 3035 _PKG_CONFIG([$1], [variable="][$3]["], [$2])
 3036 AS_VAR_COPY([$1], [pkg_cv_][$1])
 3037 
 3038 AS_VAR_IF([$1], [""], [$5], [$4])dnl
 3039 ])dnl PKG_CHECK_VAR
 3040 
 3041 # po.m4 serial 31 (gettext-0.20.2)
 3042 dnl Copyright (C) 1995-2014, 2016, 2018-2020 Free Software Foundation, Inc.
 3043 dnl This file is free software; the Free Software Foundation
 3044 dnl gives unlimited permission to copy and/or distribute it,
 3045 dnl with or without modifications, as long as this notice is preserved.
 3046 dnl
 3047 dnl This file can be used in projects which are not available under
 3048 dnl the GNU General Public License or the GNU Lesser General Public
 3049 dnl License but which still want to provide support for the GNU gettext
 3050 dnl functionality.
 3051 dnl Please note that the actual code of the GNU gettext library is covered
 3052 dnl by the GNU Lesser General Public License, and the rest of the GNU
 3053 dnl gettext package is covered by the GNU General Public License.
 3054 dnl They are *not* in the public domain.
 3055 
 3056 dnl Authors:
 3057 dnl   Ulrich Drepper <drepper@cygnus.com>, 1995-2000.
 3058 dnl   Bruno Haible <haible@clisp.cons.org>, 2000-2003.
 3059 
 3060 AC_PREREQ([2.60])
 3061 
 3062 dnl Checks for all prerequisites of the po subdirectory.
 3063 AC_DEFUN([AM_PO_SUBDIRS],
 3064 [
 3065   AC_REQUIRE([AC_PROG_MAKE_SET])dnl
 3066   AC_REQUIRE([AC_PROG_INSTALL])dnl
 3067   AC_REQUIRE([AC_PROG_MKDIR_P])dnl
 3068   AC_REQUIRE([AC_PROG_SED])dnl
 3069   AC_REQUIRE([AM_NLS])dnl
 3070 
 3071   dnl Release version of the gettext macros. This is used to ensure that
 3072   dnl the gettext macros and po/Makefile.in.in are in sync.
 3073   AC_SUBST([GETTEXT_MACRO_VERSION], [0.20])
 3074 
 3075   dnl Perform the following tests also if --disable-nls has been given,
 3076   dnl because they are needed for "make dist" to work.
 3077 
 3078   dnl Search for GNU msgfmt in the PATH.
 3079   dnl The first test excludes Solaris msgfmt and early GNU msgfmt versions.
 3080   dnl The second test excludes FreeBSD msgfmt.
 3081   AM_PATH_PROG_WITH_TEST(MSGFMT, msgfmt,
 3082     [$ac_dir/$ac_word --statistics /dev/null >&]AS_MESSAGE_LOG_FD[ 2>&1 &&
 3083      (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi)],
 3084     :)
 3085   AC_PATH_PROG([GMSGFMT], [gmsgfmt], [$MSGFMT])
 3086 
 3087   dnl Test whether it is GNU msgfmt >= 0.15.
 3088 changequote(,)dnl
 3089   case `$GMSGFMT --version | sed 1q | sed -e 's,^[^0-9]*,,'` in
 3090     '' | 0.[0-9] | 0.[0-9].* | 0.1[0-4] | 0.1[0-4].*) GMSGFMT_015=: ;;
 3091     *) GMSGFMT_015=$GMSGFMT ;;
 3092   esac
 3093 changequote([,])dnl
 3094   AC_SUBST([GMSGFMT_015])
 3095 
 3096   dnl Search for GNU xgettext 0.12 or newer in the PATH.
 3097   dnl The first test excludes Solaris xgettext and early GNU xgettext versions.
 3098   dnl The second test excludes FreeBSD xgettext.
 3099   AM_PATH_PROG_WITH_TEST(XGETTEXT, xgettext,
 3100     [$ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >&]AS_MESSAGE_LOG_FD[ 2>&1 &&
 3101      (if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi)],
 3102     :)
 3103   dnl Remove leftover from FreeBSD xgettext call.
 3104   rm -f messages.po
 3105 
 3106   dnl Test whether it is GNU xgettext >= 0.15.
 3107 changequote(,)dnl
 3108   case `$XGETTEXT --version | sed 1q | sed -e 's,^[^0-9]*,,'` in
 3109     '' | 0.[0-9] | 0.[0-9].* | 0.1[0-4] | 0.1[0-4].*) XGETTEXT_015=: ;;
 3110     *) XGETTEXT_015=$XGETTEXT ;;
 3111   esac
 3112 changequote([,])dnl
 3113   AC_SUBST([XGETTEXT_015])
 3114 
 3115   dnl Search for GNU msgmerge 0.11 or newer in the PATH.
 3116   AM_PATH_PROG_WITH_TEST(MSGMERGE, msgmerge,
 3117     [$ac_dir/$ac_word --update -q /dev/null /dev/null >&]AS_MESSAGE_LOG_FD[ 2>&1], :)
 3118 
 3119   dnl Test whether it is GNU msgmerge >= 0.20.
 3120   if LC_ALL=C $MSGMERGE --help | grep ' --for-msgfmt ' >/dev/null; then
 3121     MSGMERGE_FOR_MSGFMT_OPTION='--for-msgfmt'
 3122   else
 3123     dnl Test whether it is GNU msgmerge >= 0.12.
 3124     if LC_ALL=C $MSGMERGE --help | grep ' --no-fuzzy-matching ' >/dev/null; then
 3125       MSGMERGE_FOR_MSGFMT_OPTION='--no-fuzzy-matching --no-location --quiet'
 3126     else
 3127       dnl With these old versions, $(MSGMERGE) $(MSGMERGE_FOR_MSGFMT_OPTION) is
 3128       dnl slow. But this is not a big problem, as such old gettext versions are
 3129       dnl hardly in use any more.
 3130       MSGMERGE_FOR_MSGFMT_OPTION='--no-location --quiet'
 3131     fi
 3132   fi
 3133   AC_SUBST([MSGMERGE_FOR_MSGFMT_OPTION])
 3134 
 3135   dnl Support for AM_XGETTEXT_OPTION.
 3136   test -n "${XGETTEXT_EXTRA_OPTIONS+set}" || XGETTEXT_EXTRA_OPTIONS=
 3137   AC_SUBST([XGETTEXT_EXTRA_OPTIONS])
 3138 
 3139   AC_CONFIG_COMMANDS([po-directories], [[
 3140     for ac_file in $CONFIG_FILES; do
 3141       # Support "outfile[:infile[:infile...]]"
 3142       case "$ac_file" in
 3143         *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
 3144       esac
 3145       # PO directories have a Makefile.in generated from Makefile.in.in.
 3146       case "$ac_file" in */Makefile.in)
 3147         # Adjust a relative srcdir.
 3148         ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'`
 3149         ac_dir_suffix=/`echo "$ac_dir"|sed 's%^\./%%'`
 3150         ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'`
 3151         # In autoconf-2.13 it is called $ac_given_srcdir.
 3152         # In autoconf-2.50 it is called $srcdir.
 3153         test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir"
 3154         case "$ac_given_srcdir" in
 3155           .)  top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;;
 3156           /*) top_srcdir="$ac_given_srcdir" ;;
 3157           *)  top_srcdir="$ac_dots$ac_given_srcdir" ;;
 3158         esac
 3159         # Treat a directory as a PO directory if and only if it has a
 3160         # POTFILES.in file. This allows packages to have multiple PO
 3161         # directories under different names or in different locations.
 3162         if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then
 3163           rm -f "$ac_dir/POTFILES"
 3164           test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES"
 3165           gt_tab=`printf '\t'`
 3166           cat "$ac_given_srcdir/$ac_dir/POTFILES.in" | sed -e "/^#/d" -e "/^[ ${gt_tab}]*\$/d" -e "s,.*,     $top_srcdir/& \\\\," | sed -e "\$s/\(.*\) \\\\/\1/" > "$ac_dir/POTFILES"
 3167           POMAKEFILEDEPS="POTFILES.in"
 3168           # ALL_LINGUAS, POFILES, UPDATEPOFILES, DUMMYPOFILES, GMOFILES depend
 3169           # on $ac_dir but don't depend on user-specified configuration
 3170           # parameters.
 3171           if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then
 3172             # The LINGUAS file contains the set of available languages.
 3173             if test -n "$OBSOLETE_ALL_LINGUAS"; then
 3174               test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.in is obsolete" || echo "setting ALL_LINGUAS in configure.in is obsolete"
 3175             fi
 3176             ALL_LINGUAS=`sed -e "/^#/d" -e "s/#.*//" "$ac_given_srcdir/$ac_dir/LINGUAS"`
 3177             POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS"
 3178           else
 3179             # The set of available languages was given in configure.in.
 3180             ALL_LINGUAS=$OBSOLETE_ALL_LINGUAS
 3181           fi
 3182           # Compute POFILES
 3183           # as      $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).po)
 3184           # Compute UPDATEPOFILES
 3185           # as      $(foreach lang, $(ALL_LINGUAS), $(lang).po-update)
 3186           # Compute DUMMYPOFILES
 3187           # as      $(foreach lang, $(ALL_LINGUAS), $(lang).nop)
 3188           # Compute GMOFILES
 3189           # as      $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).gmo)
 3190           case "$ac_given_srcdir" in
 3191             .) srcdirpre= ;;
 3192             *) srcdirpre='$(srcdir)/' ;;
 3193           esac
 3194           POFILES=
 3195           UPDATEPOFILES=
 3196           DUMMYPOFILES=
 3197           GMOFILES=
 3198           for lang in $ALL_LINGUAS; do
 3199             POFILES="$POFILES $srcdirpre$lang.po"
 3200             UPDATEPOFILES="$UPDATEPOFILES $lang.po-update"
 3201             DUMMYPOFILES="$DUMMYPOFILES $lang.nop"
 3202             GMOFILES="$GMOFILES $srcdirpre$lang.gmo"
 3203           done
 3204           # CATALOGS depends on both $ac_dir and the user's LINGUAS
 3205           # environment variable.
 3206           INST_LINGUAS=
 3207           if test -n "$ALL_LINGUAS"; then
 3208             for presentlang in $ALL_LINGUAS; do
 3209               useit=no
 3210               if test "%UNSET%" != "$LINGUAS"; then
 3211                 desiredlanguages="$LINGUAS"
 3212               else
 3213                 desiredlanguages="$ALL_LINGUAS"
 3214               fi
 3215               for desiredlang in $desiredlanguages; do
 3216                 # Use the presentlang catalog if desiredlang is
 3217                 #   a. equal to presentlang, or
 3218                 #   b. a variant of presentlang (because in this case,
 3219                 #      presentlang can be used as a fallback for messages
 3220                 #      which are not translated in the desiredlang catalog).
 3221                 case "$desiredlang" in
 3222                   "$presentlang"*) useit=yes;;
 3223                 esac
 3224               done
 3225               if test $useit = yes; then
 3226                 INST_LINGUAS="$INST_LINGUAS $presentlang"
 3227               fi
 3228             done
 3229           fi
 3230           CATALOGS=
 3231           if test -n "$INST_LINGUAS"; then
 3232             for lang in $INST_LINGUAS; do
 3233               CATALOGS="$CATALOGS $lang.gmo"
 3234             done
 3235           fi
 3236           test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile"
 3237           sed -e "/^POTFILES =/r $ac_dir/POTFILES" -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" -e "s|@POFILES@|$POFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" -e "s|@POMAKEFILEDEPS@|$POMAKEFILEDEPS|g" "$ac_dir/Makefile.in" > "$ac_dir/Makefile"
 3238           for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do
 3239             if test -f "$f"; then
 3240               case "$f" in
 3241                 *.orig | *.bak | *~) ;;
 3242                 *) cat "$f" >> "$ac_dir/Makefile" ;;
 3243               esac
 3244             fi
 3245           done
 3246         fi
 3247         ;;
 3248       esac
 3249     done]],
 3250    [# Capture the value of obsolete ALL_LINGUAS because we need it to compute
 3251     # POFILES, UPDATEPOFILES, DUMMYPOFILES, GMOFILES, CATALOGS.
 3252     OBSOLETE_ALL_LINGUAS="$ALL_LINGUAS"
 3253     # Capture the value of LINGUAS because we need it to compute CATALOGS.
 3254     LINGUAS="${LINGUAS-%UNSET%}"
 3255    ])
 3256 ])
 3257 
 3258 dnl Postprocesses a Makefile in a directory containing PO files.
 3259 AC_DEFUN([AM_POSTPROCESS_PO_MAKEFILE],
 3260 [
 3261   # When this code is run, in config.status, two variables have already been
 3262   # set:
 3263   # - OBSOLETE_ALL_LINGUAS is the value of LINGUAS set in configure.in,
 3264   # - LINGUAS is the value of the environment variable LINGUAS at configure
 3265   #   time.
 3266 
 3267 changequote(,)dnl
 3268   # Adjust a relative srcdir.
 3269   ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'`
 3270   ac_dir_suffix=/`echo "$ac_dir"|sed 's%^\./%%'`
 3271   ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'`
 3272   # In autoconf-2.13 it is called $ac_given_srcdir.
 3273   # In autoconf-2.50 it is called $srcdir.
 3274   test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir"
 3275   case "$ac_given_srcdir" in
 3276     .)  top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;;
 3277     /*) top_srcdir="$ac_given_srcdir" ;;
 3278     *)  top_srcdir="$ac_dots$ac_given_srcdir" ;;
 3279   esac
 3280 
 3281   # Find a way to echo strings without interpreting backslash.
 3282   if test "X`(echo '\t') 2>/dev/null`" = 'X\t'; then
 3283     gt_echo='echo'
 3284   else
 3285     if test "X`(printf '%s\n' '\t') 2>/dev/null`" = 'X\t'; then
 3286       gt_echo='printf %s\n'
 3287     else
 3288       echo_func () {
 3289         cat <<EOT
 3290 $*
 3291 EOT
 3292       }
 3293       gt_echo='echo_func'
 3294     fi
 3295   fi
 3296 
 3297   # A sed script that extracts the value of VARIABLE from a Makefile.
 3298   tab=`printf '\t'`
 3299   sed_x_variable='
 3300 # Test if the hold space is empty.
 3301 x
 3302 s/P/P/
 3303 x
 3304 ta
 3305 # Yes it was empty. Look if we have the expected variable definition.
 3306 /^['"${tab}"' ]*VARIABLE['"${tab}"' ]*=/{
 3307   # Seen the first line of the variable definition.
 3308   s/^['"${tab}"' ]*VARIABLE['"${tab}"' ]*=//
 3309   ba
 3310 }
 3311 bd
 3312 :a
 3313 # Here we are processing a line from the variable definition.
 3314 # Remove comment, more precisely replace it with a space.
 3315 s/#.*$/ /
 3316 # See if the line ends in a backslash.
 3317 tb
 3318 :b
 3319 s/\\$//
 3320 # Print the line, without the trailing backslash.
 3321 p
 3322 tc
 3323 # There was no trailing backslash. The end of the variable definition is
 3324 # reached. Clear the hold space.
 3325 s/^.*$//
 3326 x
 3327 bd
 3328 :c
 3329 # A trailing backslash means that the variable definition continues in the
 3330 # next line. Put a nonempty string into the hold space to indicate this.
 3331 s/^.*$/P/
 3332 x
 3333 :d
 3334 '
 3335 changequote([,])dnl
 3336 
 3337   # Set POTFILES to the value of the Makefile variable POTFILES.
 3338   sed_x_POTFILES=`$gt_echo "$sed_x_variable" | sed -e '/^ *#/d' -e 's/VARIABLE/POTFILES/g'`
 3339   POTFILES=`sed -n -e "$sed_x_POTFILES" < "$ac_file"`
 3340   # Compute POTFILES_DEPS as
 3341   #   $(foreach file, $(POTFILES), $(top_srcdir)/$(file))
 3342   POTFILES_DEPS=
 3343   for file in $POTFILES; do
 3344     POTFILES_DEPS="$POTFILES_DEPS "'$(top_srcdir)/'"$file"
 3345   done
 3346   POMAKEFILEDEPS=""
 3347 
 3348   if test -n "$OBSOLETE_ALL_LINGUAS"; then
 3349     test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.in is obsolete" || echo "setting ALL_LINGUAS in configure.in is obsolete"
 3350   fi
 3351   if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then
 3352     # The LINGUAS file contains the set of available languages.
 3353     ALL_LINGUAS=`sed -e "/^#/d" -e "s/#.*//" "$ac_given_srcdir/$ac_dir/LINGUAS"`
 3354     POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS"
 3355   else
 3356     # Set ALL_LINGUAS to the value of the Makefile variable LINGUAS.
 3357     sed_x_LINGUAS=`$gt_echo "$sed_x_variable" | sed -e '/^ *#/d' -e 's/VARIABLE/LINGUAS/g'`
 3358     ALL_LINGUAS=`sed -n -e "$sed_x_LINGUAS" < "$ac_file"`
 3359   fi
 3360   # Compute POFILES
 3361   # as      $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).po)
 3362   # Compute UPDATEPOFILES
 3363   # as      $(foreach lang, $(ALL_LINGUAS), $(lang).po-update)
 3364   # Compute DUMMYPOFILES
 3365   # as      $(foreach lang, $(ALL_LINGUAS), $(lang).nop)
 3366   # Compute GMOFILES
 3367   # as      $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).gmo)
 3368   # Compute PROPERTIESFILES
 3369   # as      $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(DOMAIN)_$(lang).properties)
 3370   # Compute CLASSFILES
 3371   # as      $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(DOMAIN)_$(lang).class)
 3372   # Compute QMFILES
 3373   # as      $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).qm)
 3374   # Compute MSGFILES
 3375   # as      $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(frob $(lang)).msg)
 3376   # Compute RESOURCESDLLFILES
 3377   # as      $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(frob $(lang))/$(DOMAIN).resources.dll)
 3378   case "$ac_given_srcdir" in
 3379     .) srcdirpre= ;;
 3380     *) srcdirpre='$(srcdir)/' ;;
 3381   esac
 3382   POFILES=
 3383   UPDATEPOFILES=
 3384   DUMMYPOFILES=
 3385   GMOFILES=
 3386   PROPERTIESFILES=
 3387   CLASSFILES=
 3388   QMFILES=
 3389   MSGFILES=
 3390   RESOURCESDLLFILES=
 3391   for lang in $ALL_LINGUAS; do
 3392     POFILES="$POFILES $srcdirpre$lang.po"
 3393     UPDATEPOFILES="$UPDATEPOFILES $lang.po-update"
 3394     DUMMYPOFILES="$DUMMYPOFILES $lang.nop"
 3395     GMOFILES="$GMOFILES $srcdirpre$lang.gmo"
 3396     PROPERTIESFILES="$PROPERTIESFILES \$(srcdir)/\$(DOMAIN)_$lang.properties"
 3397     CLASSFILES="$CLASSFILES \$(srcdir)/\$(DOMAIN)_$lang.class"
 3398     QMFILES="$QMFILES $srcdirpre$lang.qm"
 3399     frobbedlang=`echo $lang | sed -e 's/\..*$//' -e 'y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/'`
 3400     MSGFILES="$MSGFILES $srcdirpre$frobbedlang.msg"
 3401     frobbedlang=`echo $lang | sed -e 's/_/-/g' -e 's/^sr-CS/sr-SP/' -e 's/@latin$/-Latn/' -e 's/@cyrillic$/-Cyrl/' -e 's/^sr-SP$/sr-SP-Latn/' -e 's/^uz-UZ$/uz-UZ-Latn/'`
 3402     RESOURCESDLLFILES="$RESOURCESDLLFILES $srcdirpre$frobbedlang/\$(DOMAIN).resources.dll"
 3403   done
 3404   # CATALOGS depends on both $ac_dir and the user's LINGUAS
 3405   # environment variable.
 3406   INST_LINGUAS=
 3407   if test -n "$ALL_LINGUAS"; then
 3408     for presentlang in $ALL_LINGUAS; do
 3409       useit=no
 3410       if test "%UNSET%" != "$LINGUAS"; then
 3411         desiredlanguages="$LINGUAS"
 3412       else
 3413         desiredlanguages="$ALL_LINGUAS"
 3414       fi
 3415       for desiredlang in $desiredlanguages; do
 3416         # Use the presentlang catalog if desiredlang is
 3417         #   a. equal to presentlang, or
 3418         #   b. a variant of presentlang (because in this case,
 3419         #      presentlang can be used as a fallback for messages
 3420         #      which are not translated in the desiredlang catalog).
 3421         case "$desiredlang" in
 3422           "$presentlang"*) useit=yes;;
 3423         esac
 3424       done
 3425       if test $useit = yes; then
 3426         INST_LINGUAS="$INST_LINGUAS $presentlang"
 3427       fi
 3428     done
 3429   fi
 3430   CATALOGS=
 3431   JAVACATALOGS=
 3432   QTCATALOGS=
 3433   TCLCATALOGS=
 3434   CSHARPCATALOGS=
 3435   if test -n "$INST_LINGUAS"; then
 3436     for lang in $INST_LINGUAS; do
 3437       CATALOGS="$CATALOGS $lang.gmo"
 3438       JAVACATALOGS="$JAVACATALOGS \$(DOMAIN)_$lang.properties"
 3439       QTCATALOGS="$QTCATALOGS $lang.qm"
 3440       frobbedlang=`echo $lang | sed -e 's/\..*$//' -e 'y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/'`
 3441       TCLCATALOGS="$TCLCATALOGS $frobbedlang.msg"
 3442       frobbedlang=`echo $lang | sed -e 's/_/-/g' -e 's/^sr-CS/sr-SP/' -e 's/@latin$/-Latn/' -e 's/@cyrillic$/-Cyrl/' -e 's/^sr-SP$/sr-SP-Latn/' -e 's/^uz-UZ$/uz-UZ-Latn/'`
 3443       CSHARPCATALOGS="$CSHARPCATALOGS $frobbedlang/\$(DOMAIN).resources.dll"
 3444     done
 3445   fi
 3446 
 3447   sed -e "s|@POTFILES_DEPS@|$POTFILES_DEPS|g" -e "s|@POFILES@|$POFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@PROPERTIESFILES@|$PROPERTIESFILES|g" -e "s|@CLASSFILES@|$CLASSFILES|g" -e "s|@QMFILES@|$QMFILES|g" -e "s|@MSGFILES@|$MSGFILES|g" -e "s|@RESOURCESDLLFILES@|$RESOURCESDLLFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" -e "s|@JAVACATALOGS@|$JAVACATALOGS|g" -e "s|@QTCATALOGS@|$QTCATALOGS|g" -e "s|@TCLCATALOGS@|$TCLCATALOGS|g" -e "s|@CSHARPCATALOGS@|$CSHARPCATALOGS|g" -e 's,^#distdir:,distdir:,' < "$ac_file" > "$ac_file.tmp"
 3448   tab=`printf '\t'`
 3449   if grep -l '@TCLCATALOGS@' "$ac_file" > /dev/null; then
 3450     # Add dependencies that cannot be formulated as a simple suffix rule.
 3451     for lang in $ALL_LINGUAS; do
 3452       frobbedlang=`echo $lang | sed -e 's/\..*$//' -e 'y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/'`
 3453       cat >> "$ac_file.tmp" <<EOF
 3454 $frobbedlang.msg: $lang.po
 3455 ${tab}@echo "\$(MSGFMT) -c --tcl -d \$(srcdir) -l $lang $srcdirpre$lang.po"; \
 3456 ${tab}\$(MSGFMT) -c --tcl -d "\$(srcdir)" -l $lang $srcdirpre$lang.po || { rm -f "\$(srcdir)/$frobbedlang.msg"; exit 1; }
 3457 EOF
 3458     done
 3459   fi
 3460   if grep -l '@CSHARPCATALOGS@' "$ac_file" > /dev/null; then
 3461     # Add dependencies that cannot be formulated as a simple suffix rule.
 3462     for lang in $ALL_LINGUAS; do
 3463       frobbedlang=`echo $lang | sed -e 's/_/-/g' -e 's/^sr-CS/sr-SP/' -e 's/@latin$/-Latn/' -e 's/@cyrillic$/-Cyrl/' -e 's/^sr-SP$/sr-SP-Latn/' -e 's/^uz-UZ$/uz-UZ-Latn/'`
 3464       cat >> "$ac_file.tmp" <<EOF
 3465 $frobbedlang/\$(DOMAIN).resources.dll: $lang.po
 3466 ${tab}@echo "\$(MSGFMT) -c --csharp -d \$(srcdir) -l $lang $srcdirpre$lang.po -r \$(DOMAIN)"; \
 3467 ${tab}\$(MSGFMT) -c --csharp -d "\$(srcdir)" -l $lang $srcdirpre$lang.po -r "\$(DOMAIN)" || { rm -f "\$(srcdir)/$frobbedlang.msg"; exit 1; }
 3468 EOF
 3469     done
 3470   fi
 3471   if test -n "$POMAKEFILEDEPS"; then
 3472     cat >> "$ac_file.tmp" <<EOF
 3473 Makefile: $POMAKEFILEDEPS
 3474 EOF
 3475   fi
 3476   mv "$ac_file.tmp" "$ac_file"
 3477 ])
 3478 
 3479 dnl Initializes the accumulator used by AM_XGETTEXT_OPTION.
 3480 AC_DEFUN([AM_XGETTEXT_OPTION_INIT],
 3481 [
 3482   XGETTEXT_EXTRA_OPTIONS=
 3483 ])
 3484 
 3485 dnl Registers an option to be passed to xgettext in the po subdirectory.
 3486 AC_DEFUN([AM_XGETTEXT_OPTION],
 3487 [
 3488   AC_REQUIRE([AM_XGETTEXT_OPTION_INIT])
 3489   XGETTEXT_EXTRA_OPTIONS="$XGETTEXT_EXTRA_OPTIONS $1"
 3490 ])
 3491 
 3492 # progtest.m4 serial 8 (gettext-0.20.2)
 3493 dnl Copyright (C) 1996-2003, 2005, 2008-2020 Free Software Foundation, Inc.
 3494 dnl This file is free software; the Free Software Foundation
 3495 dnl gives unlimited permission to copy and/or distribute it,
 3496 dnl with or without modifications, as long as this notice is preserved.
 3497 dnl
 3498 dnl This file can be used in projects which are not available under
 3499 dnl the GNU General Public License or the GNU Lesser General Public
 3500 dnl License but which still want to provide support for the GNU gettext
 3501 dnl functionality.
 3502 dnl Please note that the actual code of the GNU gettext library is covered
 3503 dnl by the GNU Lesser General Public License, and the rest of the GNU
 3504 dnl gettext package is covered by the GNU General Public License.
 3505 dnl They are *not* in the public domain.
 3506 
 3507 dnl Authors:
 3508 dnl   Ulrich Drepper <drepper@cygnus.com>, 1996.
 3509 
 3510 AC_PREREQ([2.50])
 3511 
 3512 # Search path for a program which passes the given test.
 3513 
 3514 dnl AM_PATH_PROG_WITH_TEST(VARIABLE, PROG-TO-CHECK-FOR,
 3515 dnl   TEST-PERFORMED-ON-FOUND_PROGRAM [, VALUE-IF-NOT-FOUND [, PATH]])
 3516 AC_DEFUN([AM_PATH_PROG_WITH_TEST],
 3517 [
 3518 # Prepare PATH_SEPARATOR.
 3519 # The user is always right.
 3520 if test "${PATH_SEPARATOR+set}" != set; then
 3521   # Determine PATH_SEPARATOR by trying to find /bin/sh in a PATH which
 3522   # contains only /bin. Note that ksh looks also at the FPATH variable,
 3523   # so we have to set that as well for the test.
 3524   PATH_SEPARATOR=:
 3525   (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
 3526     && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
 3527            || PATH_SEPARATOR=';'
 3528        }
 3529 fi
 3530 
 3531 # Find out how to test for executable files. Don't use a zero-byte file,
 3532 # as systems may use methods other than mode bits to determine executability.
 3533 cat >conf$$.file <<_ASEOF
 3534 #! /bin/sh
 3535 exit 0
 3536 _ASEOF
 3537 chmod +x conf$$.file
 3538 if test -x conf$$.file >/dev/null 2>&1; then
 3539   ac_executable_p="test -x"
 3540 else
 3541   ac_executable_p="test -f"
 3542 fi
 3543 rm -f conf$$.file
 3544 
 3545 # Extract the first word of "$2", so it can be a program name with args.
 3546 set dummy $2; ac_word=[$]2
 3547 AC_MSG_CHECKING([for $ac_word])
 3548 AC_CACHE_VAL([ac_cv_path_$1],
 3549 [case "[$]$1" in
 3550   [[\\/]]* | ?:[[\\/]]*)
 3551     ac_cv_path_$1="[$]$1" # Let the user override the test with a path.
 3552     ;;
 3553   *)
 3554     ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
 3555     for ac_dir in ifelse([$5], , $PATH, [$5]); do
 3556       IFS="$ac_save_IFS"
 3557       test -z "$ac_dir" && ac_dir=.
 3558       for ac_exec_ext in '' $ac_executable_extensions; do
 3559         if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
 3560           echo "$as_me: trying $ac_dir/$ac_word..." >&AS_MESSAGE_LOG_FD
 3561           if [$3]; then
 3562             ac_cv_path_$1="$ac_dir/$ac_word$ac_exec_ext"
 3563             break 2
 3564           fi
 3565         fi
 3566       done
 3567     done
 3568     IFS="$ac_save_IFS"
 3569 dnl If no 4th arg is given, leave the cache variable unset,
 3570 dnl so AC_PATH_PROGS will keep looking.
 3571 ifelse([$4], , , [  test -z "[$]ac_cv_path_$1" && ac_cv_path_$1="$4"
 3572 ])dnl
 3573     ;;
 3574 esac])dnl
 3575 $1="$ac_cv_path_$1"
 3576 if test ifelse([$4], , [-n "[$]$1"], ["[$]$1" != "$4"]); then
 3577   AC_MSG_RESULT([$][$1])
 3578 else
 3579   AC_MSG_RESULT([no])
 3580 fi
 3581 AC_SUBST([$1])dnl
 3582 ])
 3583 
 3584 # Copyright (C) 2002-2021 Free Software Foundation, Inc.
 3585 #
 3586 # This file is free software; the Free Software Foundation
 3587 # gives unlimited permission to copy and/or distribute it,
 3588 # with or without modifications, as long as this notice is preserved.
 3589 
 3590 # AM_AUTOMAKE_VERSION(VERSION)
 3591 # ----------------------------
 3592 # Automake X.Y traces this macro to ensure aclocal.m4 has been
 3593 # generated from the m4 files accompanying Automake X.Y.
 3594 # (This private macro should not be called outside this file.)
 3595 AC_DEFUN([AM_AUTOMAKE_VERSION],
 3596 [am__api_version='1.16'
 3597 dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to
 3598 dnl require some minimum version.  Point them to the right macro.
 3599 m4_if([$1], [1.16.4], [],
 3600       [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl
 3601 ])
 3602 
 3603 # _AM_AUTOCONF_VERSION(VERSION)
 3604 # -----------------------------
 3605 # aclocal traces this macro to find the Autoconf version.
 3606 # This is a private macro too.  Using m4_define simplifies
 3607 # the logic in aclocal, which can simply ignore this definition.
 3608 m4_define([_AM_AUTOCONF_VERSION], [])
 3609 
 3610 # AM_SET_CURRENT_AUTOMAKE_VERSION
 3611 # -------------------------------
 3612 # Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced.
 3613 # This function is AC_REQUIREd by AM_INIT_AUTOMAKE.
 3614 AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
 3615 [AM_AUTOMAKE_VERSION([1.16.4])dnl
 3616 m4_ifndef([AC_AUTOCONF_VERSION],
 3617   [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
 3618 _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))])
 3619 
 3620 # AM_AUX_DIR_EXPAND                                         -*- Autoconf -*-
 3621 
 3622 # Copyright (C) 2001-2021 Free Software Foundation, Inc.
 3623 #
 3624 # This file is free software; the Free Software Foundation
 3625 # gives unlimited permission to copy and/or distribute it,
 3626 # with or without modifications, as long as this notice is preserved.
 3627 
 3628 # For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets
 3629 # $ac_aux_dir to '$srcdir/foo'.  In other projects, it is set to
 3630 # '$srcdir', '$srcdir/..', or '$srcdir/../..'.
 3631 #
 3632 # Of course, Automake must honor this variable whenever it calls a
 3633 # tool from the auxiliary directory.  The problem is that $srcdir (and
 3634 # therefore $ac_aux_dir as well) can be either absolute or relative,
 3635 # depending on how configure is run.  This is pretty annoying, since
 3636 # it makes $ac_aux_dir quite unusable in subdirectories: in the top
 3637 # source directory, any form will work fine, but in subdirectories a
 3638 # relative path needs to be adjusted first.
 3639 #
 3640 # $ac_aux_dir/missing
 3641 #    fails when called from a subdirectory if $ac_aux_dir is relative
 3642 # $top_srcdir/$ac_aux_dir/missing
 3643 #    fails if $ac_aux_dir is absolute,
 3644 #    fails when called from a subdirectory in a VPATH build with
 3645 #          a relative $ac_aux_dir
 3646 #
 3647 # The reason of the latter failure is that $top_srcdir and $ac_aux_dir
 3648 # are both prefixed by $srcdir.  In an in-source build this is usually
 3649 # harmless because $srcdir is '.', but things will broke when you
 3650 # start a VPATH build or use an absolute $srcdir.
 3651 #
 3652 # So we could use something similar to $top_srcdir/$ac_aux_dir/missing,
 3653 # iff we strip the leading $srcdir from $ac_aux_dir.  That would be:
 3654 #   am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"`
 3655 # and then we would define $MISSING as
 3656 #   MISSING="\${SHELL} $am_aux_dir/missing"
 3657 # This will work as long as MISSING is not called from configure, because
 3658 # unfortunately $(top_srcdir) has no meaning in configure.
 3659 # However there are other variables, like CC, which are often used in
 3660 # configure, and could therefore not use this "fixed" $ac_aux_dir.
 3661 #
 3662 # Another solution, used here, is to always expand $ac_aux_dir to an
 3663 # absolute PATH.  The drawback is that using absolute paths prevent a
 3664 # configured tree to be moved without reconfiguration.
 3665 
 3666 AC_DEFUN([AM_AUX_DIR_EXPAND],
 3667 [AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl
 3668 # Expand $ac_aux_dir to an absolute path.
 3669 am_aux_dir=`cd "$ac_aux_dir" && pwd`
 3670 ])
 3671 
 3672 # AM_CONDITIONAL                                            -*- Autoconf -*-
 3673 
 3674 # Copyright (C) 1997-2021 Free Software Foundation, Inc.
 3675 #
 3676 # This file is free software; the Free Software Foundation
 3677 # gives unlimited permission to copy and/or distribute it,
 3678 # with or without modifications, as long as this notice is preserved.
 3679 
 3680 # AM_CONDITIONAL(NAME, SHELL-CONDITION)
 3681 # -------------------------------------
 3682 # Define a conditional.
 3683 AC_DEFUN([AM_CONDITIONAL],
 3684 [AC_PREREQ([2.52])dnl
 3685  m4_if([$1], [TRUE],  [AC_FATAL([$0: invalid condition: $1])],
 3686        [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl
 3687 AC_SUBST([$1_TRUE])dnl
 3688 AC_SUBST([$1_FALSE])dnl
 3689 _AM_SUBST_NOTMAKE([$1_TRUE])dnl
 3690 _AM_SUBST_NOTMAKE([$1_FALSE])dnl
 3691 m4_define([_AM_COND_VALUE_$1], [$2])dnl
 3692 if $2; then
 3693   $1_TRUE=
 3694   $1_FALSE='#'
 3695 else
 3696   $1_TRUE='#'
 3697   $1_FALSE=
 3698 fi
 3699 AC_CONFIG_COMMANDS_PRE(
 3700 [if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then
 3701   AC_MSG_ERROR([[conditional "$1" was never defined.
 3702 Usually this means the macro was only invoked conditionally.]])
 3703 fi])])
 3704 
 3705 # Copyright (C) 1999-2021 Free Software Foundation, Inc.
 3706 #
 3707 # This file is free software; the Free Software Foundation
 3708 # gives unlimited permission to copy and/or distribute it,
 3709 # with or without modifications, as long as this notice is preserved.
 3710 
 3711 
 3712 # There are a few dirty hacks below to avoid letting 'AC_PROG_CC' be
 3713 # written in clear, in which case automake, when reading aclocal.m4,
 3714 # will think it sees a *use*, and therefore will trigger all it's
 3715 # C support machinery.  Also note that it means that autoscan, seeing
 3716 # CC etc. in the Makefile, will ask for an AC_PROG_CC use...
 3717 
 3718 
 3719 # _AM_DEPENDENCIES(NAME)
 3720 # ----------------------
 3721 # See how the compiler implements dependency checking.
 3722 # NAME is "CC", "CXX", "OBJC", "OBJCXX", "UPC", or "GJC".
 3723 # We try a few techniques and use that to set a single cache variable.
 3724 #
 3725 # We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was
 3726 # modified to invoke _AM_DEPENDENCIES(CC); we would have a circular
 3727 # dependency, and given that the user is not expected to run this macro,
 3728 # just rely on AC_PROG_CC.
 3729 AC_DEFUN([_AM_DEPENDENCIES],
 3730 [AC_REQUIRE([AM_SET_DEPDIR])dnl
 3731 AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl
 3732 AC_REQUIRE([AM_MAKE_INCLUDE])dnl
 3733 AC_REQUIRE([AM_DEP_TRACK])dnl
 3734 
 3735 m4_if([$1], [CC],   [depcc="$CC"   am_compiler_list=],
 3736       [$1], [CXX],  [depcc="$CXX"  am_compiler_list=],
 3737       [$1], [OBJC], [depcc="$OBJC" am_compiler_list='gcc3 gcc'],
 3738       [$1], [OBJCXX], [depcc="$OBJCXX" am_compiler_list='gcc3 gcc'],
 3739       [$1], [UPC],  [depcc="$UPC"  am_compiler_list=],
 3740       [$1], [GCJ],  [depcc="$GCJ"  am_compiler_list='gcc3 gcc'],
 3741                     [depcc="$$1"   am_compiler_list=])
 3742 
 3743 AC_CACHE_CHECK([dependency style of $depcc],
 3744                [am_cv_$1_dependencies_compiler_type],
 3745 [if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
 3746   # We make a subdir and do the tests there.  Otherwise we can end up
 3747   # making bogus files that we don't know about and never remove.  For
 3748   # instance it was reported that on HP-UX the gcc test will end up
 3749   # making a dummy file named 'D' -- because '-MD' means "put the output
 3750   # in D".
 3751   rm -rf conftest.dir
 3752   mkdir conftest.dir
 3753   # Copy depcomp to subdir because otherwise we won't find it if we're
 3754   # using a relative directory.
 3755   cp "$am_depcomp" conftest.dir
 3756   cd conftest.dir
 3757   # We will build objects and dependencies in a subdirectory because
 3758   # it helps to detect inapplicable dependency modes.  For instance
 3759   # both Tru64's cc and ICC support -MD to output dependencies as a
 3760   # side effect of compilation, but ICC will put the dependencies in
 3761   # the current directory while Tru64 will put them in the object
 3762   # directory.
 3763   mkdir sub
 3764 
 3765   am_cv_$1_dependencies_compiler_type=none
 3766   if test "$am_compiler_list" = ""; then
 3767      am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp`
 3768   fi
 3769   am__universal=false
 3770   m4_case([$1], [CC],
 3771     [case " $depcc " in #(
 3772      *\ -arch\ *\ -arch\ *) am__universal=true ;;
 3773      esac],
 3774     [CXX],
 3775     [case " $depcc " in #(
 3776      *\ -arch\ *\ -arch\ *) am__universal=true ;;
 3777      esac])
 3778 
 3779   for depmode in $am_compiler_list; do
 3780     # Setup a source with many dependencies, because some compilers
 3781     # like to wrap large dependency lists on column 80 (with \), and
 3782     # we should not choose a depcomp mode which is confused by this.
 3783     #
 3784     # We need to recreate these files for each test, as the compiler may
 3785     # overwrite some of them when testing with obscure command lines.
 3786     # This happens at least with the AIX C compiler.
 3787     : > sub/conftest.c
 3788     for i in 1 2 3 4 5 6; do
 3789       echo '#include "conftst'$i'.h"' >> sub/conftest.c
 3790       # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
 3791       # Solaris 10 /bin/sh.
 3792       echo '/* dummy */' > sub/conftst$i.h
 3793     done
 3794     echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
 3795 
 3796     # We check with '-c' and '-o' for the sake of the "dashmstdout"
 3797     # mode.  It turns out that the SunPro C++ compiler does not properly
 3798     # handle '-M -o', and we need to detect this.  Also, some Intel
 3799     # versions had trouble with output in subdirs.
 3800     am__obj=sub/conftest.${OBJEXT-o}
 3801     am__minus_obj="-o $am__obj"
 3802     case $depmode in
 3803     gcc)
 3804       # This depmode causes a compiler race in universal mode.
 3805       test "$am__universal" = false || continue
 3806       ;;
 3807     nosideeffect)
 3808       # After this tag, mechanisms are not by side-effect, so they'll
 3809       # only be used when explicitly requested.
 3810       if test "x$enable_dependency_tracking" = xyes; then
 3811 	continue
 3812       else
 3813 	break
 3814       fi
 3815       ;;
 3816     msvc7 | msvc7msys | msvisualcpp | msvcmsys)
 3817       # This compiler won't grok '-c -o', but also, the minuso test has
 3818       # not run yet.  These depmodes are late enough in the game, and
 3819       # so weak that their functioning should not be impacted.
 3820       am__obj=conftest.${OBJEXT-o}
 3821       am__minus_obj=
 3822       ;;
 3823     none) break ;;
 3824     esac
 3825     if depmode=$depmode \
 3826        source=sub/conftest.c object=$am__obj \
 3827        depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
 3828        $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
 3829          >/dev/null 2>conftest.err &&
 3830        grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
 3831        grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
 3832        grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
 3833        ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
 3834       # icc doesn't choke on unknown options, it will just issue warnings
 3835       # or remarks (even with -Werror).  So we grep stderr for any message
 3836       # that says an option was ignored or not supported.
 3837       # When given -MP, icc 7.0 and 7.1 complain thusly:
 3838       #   icc: Command line warning: ignoring option '-M'; no argument required
 3839       # The diagnosis changed in icc 8.0:
 3840       #   icc: Command line remark: option '-MP' not supported
 3841       if (grep 'ignoring option' conftest.err ||
 3842           grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
 3843         am_cv_$1_dependencies_compiler_type=$depmode
 3844         break
 3845       fi
 3846     fi
 3847   done
 3848 
 3849   cd ..
 3850   rm -rf conftest.dir
 3851 else
 3852   am_cv_$1_dependencies_compiler_type=none
 3853 fi
 3854 ])
 3855 AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type])
 3856 AM_CONDITIONAL([am__fastdep$1], [
 3857   test "x$enable_dependency_tracking" != xno \
 3858   && test "$am_cv_$1_dependencies_compiler_type" = gcc3])
 3859 ])
 3860 
 3861 
 3862 # AM_SET_DEPDIR
 3863 # -------------
 3864 # Choose a directory name for dependency files.
 3865 # This macro is AC_REQUIREd in _AM_DEPENDENCIES.
 3866 AC_DEFUN([AM_SET_DEPDIR],
 3867 [AC_REQUIRE([AM_SET_LEADING_DOT])dnl
 3868 AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl
 3869 ])
 3870 
 3871 
 3872 # AM_DEP_TRACK
 3873 # ------------
 3874 AC_DEFUN([AM_DEP_TRACK],
 3875 [AC_ARG_ENABLE([dependency-tracking], [dnl
 3876 AS_HELP_STRING(
 3877   [--enable-dependency-tracking],
 3878   [do not reject slow dependency extractors])
 3879 AS_HELP_STRING(
 3880   [--disable-dependency-tracking],
 3881   [speeds up one-time build])])
 3882 if test "x$enable_dependency_tracking" != xno; then
 3883   am_depcomp="$ac_aux_dir/depcomp"
 3884   AMDEPBACKSLASH='\'
 3885   am__nodep='_no'
 3886 fi
 3887 AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno])
 3888 AC_SUBST([AMDEPBACKSLASH])dnl
 3889 _AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl
 3890 AC_SUBST([am__nodep])dnl
 3891 _AM_SUBST_NOTMAKE([am__nodep])dnl
 3892 ])
 3893 
 3894 # Generate code to set up dependency tracking.              -*- Autoconf -*-
 3895 
 3896 # Copyright (C) 1999-2021 Free Software Foundation, Inc.
 3897 #
 3898 # This file is free software; the Free Software Foundation
 3899 # gives unlimited permission to copy and/or distribute it,
 3900 # with or without modifications, as long as this notice is preserved.
 3901 
 3902 # _AM_OUTPUT_DEPENDENCY_COMMANDS
 3903 # ------------------------------
 3904 AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
 3905 [{
 3906   # Older Autoconf quotes --file arguments for eval, but not when files
 3907   # are listed without --file.  Let's play safe and only enable the eval
 3908   # if we detect the quoting.
 3909   # TODO: see whether this extra hack can be removed once we start
 3910   # requiring Autoconf 2.70 or later.
 3911   AS_CASE([$CONFIG_FILES],
 3912           [*\'*], [eval set x "$CONFIG_FILES"],
 3913           [*], [set x $CONFIG_FILES])
 3914   shift
 3915   # Used to flag and report bootstrapping failures.
 3916   am_rc=0
 3917   for am_mf
 3918   do
 3919     # Strip MF so we end up with the name of the file.
 3920     am_mf=`AS_ECHO(["$am_mf"]) | sed -e 's/:.*$//'`
 3921     # Check whether this is an Automake generated Makefile which includes
 3922     # dependency-tracking related rules and includes.
 3923     # Grep'ing the whole file directly is not great: AIX grep has a line
 3924     # limit of 2048, but all sed's we know have understand at least 4000.
 3925     sed -n 's,^am--depfiles:.*,X,p' "$am_mf" | grep X >/dev/null 2>&1 \
 3926       || continue
 3927     am_dirpart=`AS_DIRNAME(["$am_mf"])`
 3928     am_filepart=`AS_BASENAME(["$am_mf"])`
 3929     AM_RUN_LOG([cd "$am_dirpart" \
 3930       && sed -e '/# am--include-marker/d' "$am_filepart" \
 3931         | $MAKE -f - am--depfiles]) || am_rc=$?
 3932   done
 3933   if test $am_rc -ne 0; then
 3934     AC_MSG_FAILURE([Something went wrong bootstrapping makefile fragments
 3935     for automatic dependency tracking.  If GNU make was not used, consider
 3936     re-running the configure script with MAKE="gmake" (or whatever is
 3937     necessary).  You can also try re-running configure with the
 3938     '--disable-dependency-tracking' option to at least be able to build
 3939     the package (albeit without support for automatic dependency tracking).])
 3940   fi
 3941   AS_UNSET([am_dirpart])
 3942   AS_UNSET([am_filepart])
 3943   AS_UNSET([am_mf])
 3944   AS_UNSET([am_rc])
 3945   rm -f conftest-deps.mk
 3946 }
 3947 ])# _AM_OUTPUT_DEPENDENCY_COMMANDS
 3948 
 3949 
 3950 # AM_OUTPUT_DEPENDENCY_COMMANDS
 3951 # -----------------------------
 3952 # This macro should only be invoked once -- use via AC_REQUIRE.
 3953 #
 3954 # This code is only required when automatic dependency tracking is enabled.
 3955 # This creates each '.Po' and '.Plo' makefile fragment that we'll need in
 3956 # order to bootstrap the dependency handling code.
 3957 AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
 3958 [AC_CONFIG_COMMANDS([depfiles],
 3959      [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS],
 3960      [AMDEP_TRUE="$AMDEP_TRUE" MAKE="${MAKE-make}"])])
 3961 
 3962 # Do all the work for Automake.                             -*- Autoconf -*-
 3963 
 3964 # Copyright (C) 1996-2021 Free Software Foundation, Inc.
 3965 #
 3966 # This file is free software; the Free Software Foundation
 3967 # gives unlimited permission to copy and/or distribute it,
 3968 # with or without modifications, as long as this notice is preserved.
 3969 
 3970 # This macro actually does too much.  Some checks are only needed if
 3971 # your package does certain things.  But this isn't really a big deal.
 3972 
 3973 dnl Redefine AC_PROG_CC to automatically invoke _AM_PROG_CC_C_O.
 3974 m4_define([AC_PROG_CC],
 3975 m4_defn([AC_PROG_CC])
 3976 [_AM_PROG_CC_C_O
 3977 ])
 3978 
 3979 # AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE])
 3980 # AM_INIT_AUTOMAKE([OPTIONS])
 3981 # -----------------------------------------------
 3982 # The call with PACKAGE and VERSION arguments is the old style
 3983 # call (pre autoconf-2.50), which is being phased out.  PACKAGE
 3984 # and VERSION should now be passed to AC_INIT and removed from
 3985 # the call to AM_INIT_AUTOMAKE.
 3986 # We support both call styles for the transition.  After
 3987 # the next Automake release, Autoconf can make the AC_INIT
 3988 # arguments mandatory, and then we can depend on a new Autoconf
 3989 # release and drop the old call support.
 3990 AC_DEFUN([AM_INIT_AUTOMAKE],
 3991 [AC_PREREQ([2.65])dnl
 3992 dnl Autoconf wants to disallow AM_ names.  We explicitly allow
 3993 dnl the ones we care about.
 3994 m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
 3995 AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl
 3996 AC_REQUIRE([AC_PROG_INSTALL])dnl
 3997 if test "`cd $srcdir && pwd`" != "`pwd`"; then
 3998   # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
 3999   # is not polluted with repeated "-I."
 4000   AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl
 4001   # test to see if srcdir already configured
 4002   if test -f $srcdir/config.status; then
 4003     AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
 4004   fi
 4005 fi
 4006 
 4007 # test whether we have cygpath
 4008 if test -z "$CYGPATH_W"; then
 4009   if (cygpath --version) >/dev/null 2>/dev/null; then
 4010     CYGPATH_W='cygpath -w'
 4011   else
 4012     CYGPATH_W=echo
 4013   fi
 4014 fi
 4015 AC_SUBST([CYGPATH_W])
 4016 
 4017 # Define the identity of the package.
 4018 dnl Distinguish between old-style and new-style calls.
 4019 m4_ifval([$2],
 4020 [AC_DIAGNOSE([obsolete],
 4021              [$0: two- and three-arguments forms are deprecated.])
 4022 m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl
 4023  AC_SUBST([PACKAGE], [$1])dnl
 4024  AC_SUBST([VERSION], [$2])],
 4025 [_AM_SET_OPTIONS([$1])dnl
 4026 dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT.
 4027 m4_if(
 4028   m4_ifset([AC_PACKAGE_NAME], [ok]):m4_ifset([AC_PACKAGE_VERSION], [ok]),
 4029   [ok:ok],,
 4030   [m4_fatal([AC_INIT should be called with package and version arguments])])dnl
 4031  AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl
 4032  AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl
 4033 
 4034 _AM_IF_OPTION([no-define],,
 4035 [AC_DEFINE_UNQUOTED([PACKAGE], ["$PACKAGE"], [Name of package])
 4036  AC_DEFINE_UNQUOTED([VERSION], ["$VERSION"], [Version number of package])])dnl
 4037 
 4038 # Some tools Automake needs.
 4039 AC_REQUIRE([AM_SANITY_CHECK])dnl
 4040 AC_REQUIRE([AC_ARG_PROGRAM])dnl
 4041 AM_MISSING_PROG([ACLOCAL], [aclocal-${am__api_version}])
 4042 AM_MISSING_PROG([AUTOCONF], [autoconf])
 4043 AM_MISSING_PROG([AUTOMAKE], [automake-${am__api_version}])
 4044 AM_MISSING_PROG([AUTOHEADER], [autoheader])
 4045 AM_MISSING_PROG([MAKEINFO], [makeinfo])
 4046 AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
 4047 AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl
 4048 AC_REQUIRE([AC_PROG_MKDIR_P])dnl
 4049 # For better backward compatibility.  To be removed once Automake 1.9.x
 4050 # dies out for good.  For more background, see:
 4051 # <https://lists.gnu.org/archive/html/automake/2012-07/msg00001.html>
 4052 # <https://lists.gnu.org/archive/html/automake/2012-07/msg00014.html>
 4053 AC_SUBST([mkdir_p], ['$(MKDIR_P)'])
 4054 # We need awk for the "check" target (and possibly the TAP driver).  The
 4055 # system "awk" is bad on some platforms.
 4056 AC_REQUIRE([AC_PROG_AWK])dnl
 4057 AC_REQUIRE([AC_PROG_MAKE_SET])dnl
 4058 AC_REQUIRE([AM_SET_LEADING_DOT])dnl
 4059 _AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])],
 4060 	      [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])],
 4061 			     [_AM_PROG_TAR([v7])])])
 4062 _AM_IF_OPTION([no-dependencies],,
 4063 [AC_PROVIDE_IFELSE([AC_PROG_CC],
 4064 		  [_AM_DEPENDENCIES([CC])],
 4065 		  [m4_define([AC_PROG_CC],
 4066 			     m4_defn([AC_PROG_CC])[_AM_DEPENDENCIES([CC])])])dnl
 4067 AC_PROVIDE_IFELSE([AC_PROG_CXX],
 4068 		  [_AM_DEPENDENCIES([CXX])],
 4069 		  [m4_define([AC_PROG_CXX],
 4070 			     m4_defn([AC_PROG_CXX])[_AM_DEPENDENCIES([CXX])])])dnl
 4071 AC_PROVIDE_IFELSE([AC_PROG_OBJC],
 4072 		  [_AM_DEPENDENCIES([OBJC])],
 4073 		  [m4_define([AC_PROG_OBJC],
 4074 			     m4_defn([AC_PROG_OBJC])[_AM_DEPENDENCIES([OBJC])])])dnl
 4075 AC_PROVIDE_IFELSE([AC_PROG_OBJCXX],
 4076 		  [_AM_DEPENDENCIES([OBJCXX])],
 4077 		  [m4_define([AC_PROG_OBJCXX],
 4078 			     m4_defn([AC_PROG_OBJCXX])[_AM_DEPENDENCIES([OBJCXX])])])dnl
 4079 ])
 4080 # Variables for tags utilities; see am/tags.am
 4081 if test -z "$CTAGS"; then
 4082   CTAGS=ctags
 4083 fi
 4084 AC_SUBST([CTAGS])
 4085 if test -z "$ETAGS"; then
 4086   ETAGS=etags
 4087 fi
 4088 AC_SUBST([ETAGS])
 4089 if test -z "$CSCOPE"; then
 4090   CSCOPE=cscope
 4091 fi
 4092 AC_SUBST([CSCOPE])
 4093 
 4094 AC_REQUIRE([AM_SILENT_RULES])dnl
 4095 dnl The testsuite driver may need to know about EXEEXT, so add the
 4096 dnl 'am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen.  This
 4097 dnl macro is hooked onto _AC_COMPILER_EXEEXT early, see below.
 4098 AC_CONFIG_COMMANDS_PRE(dnl
 4099 [m4_provide_if([_AM_COMPILER_EXEEXT],
 4100   [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl
 4101 
 4102 # POSIX will say in a future version that running "rm -f" with no argument
 4103 # is OK; and we want to be able to make that assumption in our Makefile
 4104 # recipes.  So use an aggressive probe to check that the usage we want is
 4105 # actually supported "in the wild" to an acceptable degree.
 4106 # See automake bug#10828.
 4107 # To make any issue more visible, cause the running configure to be aborted
 4108 # by default if the 'rm' program in use doesn't match our expectations; the
 4109 # user can still override this though.
 4110 if rm -f && rm -fr && rm -rf; then : OK; else
 4111   cat >&2 <<'END'
 4112 Oops!
 4113 
 4114 Your 'rm' program seems unable to run without file operands specified
 4115 on the command line, even when the '-f' option is present.  This is contrary
 4116 to the behaviour of most rm programs out there, and not conforming with
 4117 the upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542>
 4118 
 4119 Please tell bug-automake@gnu.org about your system, including the value
 4120 of your $PATH and any error possibly output before this message.  This
 4121 can help us improve future automake versions.
 4122 
 4123 END
 4124   if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then
 4125     echo 'Configuration will proceed anyway, since you have set the' >&2
 4126     echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2
 4127     echo >&2
 4128   else
 4129     cat >&2 <<'END'
 4130 Aborting the configuration process, to ensure you take notice of the issue.
 4131 
 4132 You can download and install GNU coreutils to get an 'rm' implementation
 4133 that behaves properly: <https://www.gnu.org/software/coreutils/>.
 4134 
 4135 If you want to complete the configuration process using your problematic
 4136 'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM
 4137 to "yes", and re-run configure.
 4138 
 4139 END
 4140     AC_MSG_ERROR([Your 'rm' program is bad, sorry.])
 4141   fi
 4142 fi
 4143 dnl The trailing newline in this macro's definition is deliberate, for
 4144 dnl backward compatibility and to allow trailing 'dnl'-style comments
 4145 dnl after the AM_INIT_AUTOMAKE invocation. See automake bug#16841.
 4146 ])
 4147 
 4148 dnl Hook into '_AC_COMPILER_EXEEXT' early to learn its expansion.  Do not
 4149 dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further
 4150 dnl mangled by Autoconf and run in a shell conditional statement.
 4151 m4_define([_AC_COMPILER_EXEEXT],
 4152 m4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])])
 4153 
 4154 # When config.status generates a header, we must update the stamp-h file.
 4155 # This file resides in the same directory as the config header
 4156 # that is generated.  The stamp files are numbered to have different names.
 4157 
 4158 # Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the
 4159 # loop where config.status creates the headers, so we can generate
 4160 # our stamp files there.
 4161 AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK],
 4162 [# Compute $1's index in $config_headers.
 4163 _am_arg=$1
 4164 _am_stamp_count=1
 4165 for _am_header in $config_headers :; do
 4166   case $_am_header in
 4167     $_am_arg | $_am_arg:* )
 4168       break ;;
 4169     * )
 4170       _am_stamp_count=`expr $_am_stamp_count + 1` ;;
 4171   esac
 4172 done
 4173 echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count])
 4174 
 4175 # Copyright (C) 2001-2021 Free Software Foundation, Inc.
 4176 #
 4177 # This file is free software; the Free Software Foundation
 4178 # gives unlimited permission to copy and/or distribute it,
 4179 # with or without modifications, as long as this notice is preserved.
 4180 
 4181 # AM_PROG_INSTALL_SH
 4182 # ------------------
 4183 # Define $install_sh.
 4184 AC_DEFUN([AM_PROG_INSTALL_SH],
 4185 [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
 4186 if test x"${install_sh+set}" != xset; then
 4187   case $am_aux_dir in
 4188   *\ * | *\	*)
 4189     install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
 4190   *)
 4191     install_sh="\${SHELL} $am_aux_dir/install-sh"
 4192   esac
 4193 fi
 4194 AC_SUBST([install_sh])])
 4195 
 4196 # Copyright (C) 2003-2021 Free Software Foundation, Inc.
 4197 #
 4198 # This file is free software; the Free Software Foundation
 4199 # gives unlimited permission to copy and/or distribute it,
 4200 # with or without modifications, as long as this notice is preserved.
 4201 
 4202 # Check whether the underlying file-system supports filenames
 4203 # with a leading dot.  For instance MS-DOS doesn't.
 4204 AC_DEFUN([AM_SET_LEADING_DOT],
 4205 [rm -rf .tst 2>/dev/null
 4206 mkdir .tst 2>/dev/null
 4207 if test -d .tst; then
 4208   am__leading_dot=.
 4209 else
 4210   am__leading_dot=_
 4211 fi
 4212 rmdir .tst 2>/dev/null
 4213 AC_SUBST([am__leading_dot])])
 4214 
 4215 # Check to see how 'make' treats includes.	            -*- Autoconf -*-
 4216 
 4217 # Copyright (C) 2001-2021 Free Software Foundation, Inc.
 4218 #
 4219 # This file is free software; the Free Software Foundation
 4220 # gives unlimited permission to copy and/or distribute it,
 4221 # with or without modifications, as long as this notice is preserved.
 4222 
 4223 # AM_MAKE_INCLUDE()
 4224 # -----------------
 4225 # Check whether make has an 'include' directive that can support all
 4226 # the idioms we need for our automatic dependency tracking code.
 4227 AC_DEFUN([AM_MAKE_INCLUDE],
 4228 [AC_MSG_CHECKING([whether ${MAKE-make} supports the include directive])
 4229 cat > confinc.mk << 'END'
 4230 am__doit:
 4231 	@echo this is the am__doit target >confinc.out
 4232 .PHONY: am__doit
 4233 END
 4234 am__include="#"
 4235 am__quote=
 4236 # BSD make does it like this.
 4237 echo '.include "confinc.mk" # ignored' > confmf.BSD
 4238 # Other make implementations (GNU, Solaris 10, AIX) do it like this.
 4239 echo 'include confinc.mk # ignored' > confmf.GNU
 4240 _am_result=no
 4241 for s in GNU BSD; do
 4242   AM_RUN_LOG([${MAKE-make} -f confmf.$s && cat confinc.out])
 4243   AS_CASE([$?:`cat confinc.out 2>/dev/null`],
 4244       ['0:this is the am__doit target'],
 4245       [AS_CASE([$s],
 4246           [BSD], [am__include='.include' am__quote='"'],
 4247           [am__include='include' am__quote=''])])
 4248   if test "$am__include" != "#"; then
 4249     _am_result="yes ($s style)"
 4250     break
 4251   fi
 4252 done
 4253 rm -f confinc.* confmf.*
 4254 AC_MSG_RESULT([${_am_result}])
 4255 AC_SUBST([am__include])])
 4256 AC_SUBST([am__quote])])
 4257 
 4258 # Fake the existence of programs that GNU maintainers use.  -*- Autoconf -*-
 4259 
 4260 # Copyright (C) 1997-2021 Free Software Foundation, Inc.
 4261 #
 4262 # This file is free software; the Free Software Foundation
 4263 # gives unlimited permission to copy and/or distribute it,
 4264 # with or without modifications, as long as this notice is preserved.
 4265 
 4266 # AM_MISSING_PROG(NAME, PROGRAM)
 4267 # ------------------------------
 4268 AC_DEFUN([AM_MISSING_PROG],
 4269 [AC_REQUIRE([AM_MISSING_HAS_RUN])
 4270 $1=${$1-"${am_missing_run}$2"}
 4271 AC_SUBST($1)])
 4272 
 4273 # AM_MISSING_HAS_RUN
 4274 # ------------------
 4275 # Define MISSING if not defined so far and test if it is modern enough.
 4276 # If it is, set am_missing_run to use it, otherwise, to nothing.
 4277 AC_DEFUN([AM_MISSING_HAS_RUN],
 4278 [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
 4279 AC_REQUIRE_AUX_FILE([missing])dnl
 4280 if test x"${MISSING+set}" != xset; then
 4281   MISSING="\${SHELL} '$am_aux_dir/missing'"
 4282 fi
 4283 # Use eval to expand $SHELL
 4284 if eval "$MISSING --is-lightweight"; then
 4285   am_missing_run="$MISSING "
 4286 else
 4287   am_missing_run=
 4288   AC_MSG_WARN(['missing' script is too old or missing])
 4289 fi
 4290 ])
 4291 
 4292 # Helper functions for option handling.                     -*- Autoconf -*-
 4293 
 4294 # Copyright (C) 2001-2021 Free Software Foundation, Inc.
 4295 #
 4296 # This file is free software; the Free Software Foundation
 4297 # gives unlimited permission to copy and/or distribute it,
 4298 # with or without modifications, as long as this notice is preserved.
 4299 
 4300 # _AM_MANGLE_OPTION(NAME)
 4301 # -----------------------
 4302 AC_DEFUN([_AM_MANGLE_OPTION],
 4303 [[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])])
 4304 
 4305 # _AM_SET_OPTION(NAME)
 4306 # --------------------
 4307 # Set option NAME.  Presently that only means defining a flag for this option.
 4308 AC_DEFUN([_AM_SET_OPTION],
 4309 [m4_define(_AM_MANGLE_OPTION([$1]), [1])])
 4310 
 4311 # _AM_SET_OPTIONS(OPTIONS)
 4312 # ------------------------
 4313 # OPTIONS is a space-separated list of Automake options.
 4314 AC_DEFUN([_AM_SET_OPTIONS],
 4315 [m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])])
 4316 
 4317 # _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET])
 4318 # -------------------------------------------
 4319 # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
 4320 AC_DEFUN([_AM_IF_OPTION],
 4321 [m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
 4322 
 4323 # Copyright (C) 1999-2021 Free Software Foundation, Inc.
 4324 #
 4325 # This file is free software; the Free Software Foundation
 4326 # gives unlimited permission to copy and/or distribute it,
 4327 # with or without modifications, as long as this notice is preserved.
 4328 
 4329 # _AM_PROG_CC_C_O
 4330 # ---------------
 4331 # Like AC_PROG_CC_C_O, but changed for automake.  We rewrite AC_PROG_CC
 4332 # to automatically call this.
 4333 AC_DEFUN([_AM_PROG_CC_C_O],
 4334 [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
 4335 AC_REQUIRE_AUX_FILE([compile])dnl
 4336 AC_LANG_PUSH([C])dnl
 4337 AC_CACHE_CHECK(
 4338   [whether $CC understands -c and -o together],
 4339   [am_cv_prog_cc_c_o],
 4340   [AC_LANG_CONFTEST([AC_LANG_PROGRAM([])])
 4341   # Make sure it works both with $CC and with simple cc.
 4342   # Following AC_PROG_CC_C_O, we do the test twice because some
 4343   # compilers refuse to overwrite an existing .o file with -o,
 4344   # though they will create one.
 4345   am_cv_prog_cc_c_o=yes
 4346   for am_i in 1 2; do
 4347     if AM_RUN_LOG([$CC -c conftest.$ac_ext -o conftest2.$ac_objext]) \
 4348          && test -f conftest2.$ac_objext; then
 4349       : OK
 4350     else
 4351       am_cv_prog_cc_c_o=no
 4352       break
 4353     fi
 4354   done
 4355   rm -f core conftest*
 4356   unset am_i])
 4357 if test "$am_cv_prog_cc_c_o" != yes; then
 4358    # Losing compiler, so override with the script.
 4359    # FIXME: It is wrong to rewrite CC.
 4360    # But if we don't then we get into trouble of one sort or another.
 4361    # A longer-term fix would be to have automake use am__CC in this case,
 4362    # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
 4363    CC="$am_aux_dir/compile $CC"
 4364 fi
 4365 AC_LANG_POP([C])])
 4366 
 4367 # For backward compatibility.
 4368 AC_DEFUN_ONCE([AM_PROG_CC_C_O], [AC_REQUIRE([AC_PROG_CC])])
 4369 
 4370 # Copyright (C) 2001-2021 Free Software Foundation, Inc.
 4371 #
 4372 # This file is free software; the Free Software Foundation
 4373 # gives unlimited permission to copy and/or distribute it,
 4374 # with or without modifications, as long as this notice is preserved.
 4375 
 4376 # AM_RUN_LOG(COMMAND)
 4377 # -------------------
 4378 # Run COMMAND, save the exit status in ac_status, and log it.
 4379 # (This has been adapted from Autoconf's _AC_RUN_LOG macro.)
 4380 AC_DEFUN([AM_RUN_LOG],
 4381 [{ echo "$as_me:$LINENO: $1" >&AS_MESSAGE_LOG_FD
 4382    ($1) >&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD
 4383    ac_status=$?
 4384    echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
 4385    (exit $ac_status); }])
 4386 
 4387 # Check to make sure that the build environment is sane.    -*- Autoconf -*-
 4388 
 4389 # Copyright (C) 1996-2021 Free Software Foundation, Inc.
 4390 #
 4391 # This file is free software; the Free Software Foundation
 4392 # gives unlimited permission to copy and/or distribute it,
 4393 # with or without modifications, as long as this notice is preserved.
 4394 
 4395 # AM_SANITY_CHECK
 4396 # ---------------
 4397 AC_DEFUN([AM_SANITY_CHECK],
 4398 [AC_MSG_CHECKING([whether build environment is sane])
 4399 # Reject unsafe characters in $srcdir or the absolute working directory
 4400 # name.  Accept space and tab only in the latter.
 4401 am_lf='
 4402 '
 4403 case `pwd` in
 4404   *[[\\\"\#\$\&\'\`$am_lf]]*)
 4405     AC_MSG_ERROR([unsafe absolute working directory name]);;
 4406 esac
 4407 case $srcdir in
 4408   *[[\\\"\#\$\&\'\`$am_lf\ \	]]*)
 4409     AC_MSG_ERROR([unsafe srcdir value: '$srcdir']);;
 4410 esac
 4411 
 4412 # Do 'set' in a subshell so we don't clobber the current shell's
 4413 # arguments.  Must try -L first in case configure is actually a
 4414 # symlink; some systems play weird games with the mod time of symlinks
 4415 # (eg FreeBSD returns the mod time of the symlink's containing
 4416 # directory).
 4417 if (
 4418    am_has_slept=no
 4419    for am_try in 1 2; do
 4420      echo "timestamp, slept: $am_has_slept" > conftest.file
 4421      set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
 4422      if test "$[*]" = "X"; then
 4423 	# -L didn't work.
 4424 	set X `ls -t "$srcdir/configure" conftest.file`
 4425      fi
 4426      if test "$[*]" != "X $srcdir/configure conftest.file" \
 4427 	&& test "$[*]" != "X conftest.file $srcdir/configure"; then
 4428 
 4429 	# If neither matched, then we have a broken ls.  This can happen
 4430 	# if, for instance, CONFIG_SHELL is bash and it inherits a
 4431 	# broken ls alias from the environment.  This has actually
 4432 	# happened.  Such a system could not be considered "sane".
 4433 	AC_MSG_ERROR([ls -t appears to fail.  Make sure there is not a broken
 4434   alias in your environment])
 4435      fi
 4436      if test "$[2]" = conftest.file || test $am_try -eq 2; then
 4437        break
 4438      fi
 4439      # Just in case.
 4440      sleep 1
 4441      am_has_slept=yes
 4442    done
 4443    test "$[2]" = conftest.file
 4444    )
 4445 then
 4446    # Ok.
 4447    :
 4448 else
 4449    AC_MSG_ERROR([newly created file is older than distributed files!
 4450 Check your system clock])
 4451 fi
 4452 AC_MSG_RESULT([yes])
 4453 # If we didn't sleep, we still need to ensure time stamps of config.status and
 4454 # generated files are strictly newer.
 4455 am_sleep_pid=
 4456 if grep 'slept: no' conftest.file >/dev/null 2>&1; then
 4457   ( sleep 1 ) &
 4458   am_sleep_pid=$!
 4459 fi
 4460 AC_CONFIG_COMMANDS_PRE(
 4461   [AC_MSG_CHECKING([that generated files are newer than configure])
 4462    if test -n "$am_sleep_pid"; then
 4463      # Hide warnings about reused PIDs.
 4464      wait $am_sleep_pid 2>/dev/null
 4465    fi
 4466    AC_MSG_RESULT([done])])
 4467 rm -f conftest.file
 4468 ])
 4469 
 4470 # Copyright (C) 2009-2021 Free Software Foundation, Inc.
 4471 #
 4472 # This file is free software; the Free Software Foundation
 4473 # gives unlimited permission to copy and/or distribute it,
 4474 # with or without modifications, as long as this notice is preserved.
 4475 
 4476 # AM_SILENT_RULES([DEFAULT])
 4477 # --------------------------
 4478 # Enable less verbose build rules; with the default set to DEFAULT
 4479 # ("yes" being less verbose, "no" or empty being verbose).
 4480 AC_DEFUN([AM_SILENT_RULES],
 4481 [AC_ARG_ENABLE([silent-rules], [dnl
 4482 AS_HELP_STRING(
 4483   [--enable-silent-rules],
 4484   [less verbose build output (undo: "make V=1")])
 4485 AS_HELP_STRING(
 4486   [--disable-silent-rules],
 4487   [verbose build output (undo: "make V=0")])dnl
 4488 ])
 4489 case $enable_silent_rules in @%:@ (((
 4490   yes) AM_DEFAULT_VERBOSITY=0;;
 4491    no) AM_DEFAULT_VERBOSITY=1;;
 4492     *) AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);;
 4493 esac
 4494 dnl
 4495 dnl A few 'make' implementations (e.g., NonStop OS and NextStep)
 4496 dnl do not support nested variable expansions.
 4497 dnl See automake bug#9928 and bug#10237.
 4498 am_make=${MAKE-make}
 4499 AC_CACHE_CHECK([whether $am_make supports nested variables],
 4500    [am_cv_make_support_nested_variables],
 4501    [if AS_ECHO([['TRUE=$(BAR$(V))
 4502 BAR0=false
 4503 BAR1=true
 4504 V=1
 4505 am__doit:
 4506 	@$(TRUE)
 4507 .PHONY: am__doit']]) | $am_make -f - >/dev/null 2>&1; then
 4508   am_cv_make_support_nested_variables=yes
 4509 else
 4510   am_cv_make_support_nested_variables=no
 4511 fi])
 4512 if test $am_cv_make_support_nested_variables = yes; then
 4513   dnl Using '$V' instead of '$(V)' breaks IRIX make.
 4514   AM_V='$(V)'
 4515   AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
 4516 else
 4517   AM_V=$AM_DEFAULT_VERBOSITY
 4518   AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
 4519 fi
 4520 AC_SUBST([AM_V])dnl
 4521 AM_SUBST_NOTMAKE([AM_V])dnl
 4522 AC_SUBST([AM_DEFAULT_V])dnl
 4523 AM_SUBST_NOTMAKE([AM_DEFAULT_V])dnl
 4524 AC_SUBST([AM_DEFAULT_VERBOSITY])dnl
 4525 AM_BACKSLASH='\'
 4526 AC_SUBST([AM_BACKSLASH])dnl
 4527 _AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl
 4528 ])
 4529 
 4530 # Copyright (C) 2001-2021 Free Software Foundation, Inc.
 4531 #
 4532 # This file is free software; the Free Software Foundation
 4533 # gives unlimited permission to copy and/or distribute it,
 4534 # with or without modifications, as long as this notice is preserved.
 4535 
 4536 # AM_PROG_INSTALL_STRIP
 4537 # ---------------------
 4538 # One issue with vendor 'install' (even GNU) is that you can't
 4539 # specify the program used to strip binaries.  This is especially
 4540 # annoying in cross-compiling environments, where the build's strip
 4541 # is unlikely to handle the host's binaries.
 4542 # Fortunately install-sh will honor a STRIPPROG variable, so we
 4543 # always use install-sh in "make install-strip", and initialize
 4544 # STRIPPROG with the value of the STRIP variable (set by the user).
 4545 AC_DEFUN([AM_PROG_INSTALL_STRIP],
 4546 [AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
 4547 # Installed binaries are usually stripped using 'strip' when the user
 4548 # run "make install-strip".  However 'strip' might not be the right
 4549 # tool to use in cross-compilation environments, therefore Automake
 4550 # will honor the 'STRIP' environment variable to overrule this program.
 4551 dnl Don't test for $cross_compiling = yes, because it might be 'maybe'.
 4552 if test "$cross_compiling" != no; then
 4553   AC_CHECK_TOOL([STRIP], [strip], :)
 4554 fi
 4555 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
 4556 AC_SUBST([INSTALL_STRIP_PROGRAM])])
 4557 
 4558 # Copyright (C) 2006-2021 Free Software Foundation, Inc.
 4559 #
 4560 # This file is free software; the Free Software Foundation
 4561 # gives unlimited permission to copy and/or distribute it,
 4562 # with or without modifications, as long as this notice is preserved.
 4563 
 4564 # _AM_SUBST_NOTMAKE(VARIABLE)
 4565 # ---------------------------
 4566 # Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in.
 4567 # This macro is traced by Automake.
 4568 AC_DEFUN([_AM_SUBST_NOTMAKE])
 4569 
 4570 # AM_SUBST_NOTMAKE(VARIABLE)
 4571 # --------------------------
 4572 # Public sister of _AM_SUBST_NOTMAKE.
 4573 AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)])
 4574 
 4575 # Check how to create a tarball.                            -*- Autoconf -*-
 4576 
 4577 # Copyright (C) 2004-2021 Free Software Foundation, Inc.
 4578 #
 4579 # This file is free software; the Free Software Foundation
 4580 # gives unlimited permission to copy and/or distribute it,
 4581 # with or without modifications, as long as this notice is preserved.
 4582 
 4583 # _AM_PROG_TAR(FORMAT)
 4584 # --------------------
 4585 # Check how to create a tarball in format FORMAT.
 4586 # FORMAT should be one of 'v7', 'ustar', or 'pax'.
 4587 #
 4588 # Substitute a variable $(am__tar) that is a command
 4589 # writing to stdout a FORMAT-tarball containing the directory
 4590 # $tardir.
 4591 #     tardir=directory && $(am__tar) > result.tar
 4592 #
 4593 # Substitute a variable $(am__untar) that extract such
 4594 # a tarball read from stdin.
 4595 #     $(am__untar) < result.tar
 4596 #
 4597 AC_DEFUN([_AM_PROG_TAR],
 4598 [# Always define AMTAR for backward compatibility.  Yes, it's still used
 4599 # in the wild :-(  We should find a proper way to deprecate it ...
 4600 AC_SUBST([AMTAR], ['$${TAR-tar}'])
 4601 
 4602 # We'll loop over all known methods to create a tar archive until one works.
 4603 _am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none'
 4604 
 4605 m4_if([$1], [v7],
 4606   [am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'],
 4607 
 4608   [m4_case([$1],
 4609     [ustar],
 4610      [# The POSIX 1988 'ustar' format is defined with fixed-size fields.
 4611       # There is notably a 21 bits limit for the UID and the GID.  In fact,
 4612       # the 'pax' utility can hang on bigger UID/GID (see automake bug#8343
 4613       # and bug#13588).
 4614       am_max_uid=2097151 # 2^21 - 1
 4615       am_max_gid=$am_max_uid
 4616       # The $UID and $GID variables are not portable, so we need to resort
 4617       # to the POSIX-mandated id(1) utility.  Errors in the 'id' calls
 4618       # below are definitely unexpected, so allow the users to see them
 4619       # (that is, avoid stderr redirection).
 4620       am_uid=`id -u || echo unknown`
 4621       am_gid=`id -g || echo unknown`
 4622       AC_MSG_CHECKING([whether UID '$am_uid' is supported by ustar format])
 4623       if test $am_uid -le $am_max_uid; then
 4624          AC_MSG_RESULT([yes])
 4625       else
 4626          AC_MSG_RESULT([no])
 4627          _am_tools=none
 4628       fi
 4629       AC_MSG_CHECKING([whether GID '$am_gid' is supported by ustar format])
 4630       if test $am_gid -le $am_max_gid; then
 4631          AC_MSG_RESULT([yes])
 4632       else
 4633         AC_MSG_RESULT([no])
 4634         _am_tools=none
 4635       fi],
 4636 
 4637   [pax],
 4638     [],
 4639 
 4640   [m4_fatal([Unknown tar format])])
 4641 
 4642   AC_MSG_CHECKING([how to create a $1 tar archive])
 4643 
 4644   # Go ahead even if we have the value already cached.  We do so because we
 4645   # need to set the values for the 'am__tar' and 'am__untar' variables.
 4646   _am_tools=${am_cv_prog_tar_$1-$_am_tools}
 4647 
 4648   for _am_tool in $_am_tools; do
 4649     case $_am_tool in
 4650     gnutar)
 4651       for _am_tar in tar gnutar gtar; do
 4652         AM_RUN_LOG([$_am_tar --version]) && break
 4653       done
 4654       am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"'
 4655       am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"'
 4656       am__untar="$_am_tar -xf -"
 4657       ;;
 4658     plaintar)
 4659       # Must skip GNU tar: if it does not support --format= it doesn't create
 4660       # ustar tarball either.
 4661       (tar --version) >/dev/null 2>&1 && continue
 4662       am__tar='tar chf - "$$tardir"'
 4663       am__tar_='tar chf - "$tardir"'
 4664       am__untar='tar xf -'
 4665       ;;
 4666     pax)
 4667       am__tar='pax -L -x $1 -w "$$tardir"'
 4668       am__tar_='pax -L -x $1 -w "$tardir"'
 4669       am__untar='pax -r'
 4670       ;;
 4671     cpio)
 4672       am__tar='find "$$tardir" -print | cpio -o -H $1 -L'
 4673       am__tar_='find "$tardir" -print | cpio -o -H $1 -L'
 4674       am__untar='cpio -i -H $1 -d'
 4675       ;;
 4676     none)
 4677       am__tar=false
 4678       am__tar_=false
 4679       am__untar=false
 4680       ;;
 4681     esac
 4682 
 4683     # If the value was cached, stop now.  We just wanted to have am__tar
 4684     # and am__untar set.
 4685     test -n "${am_cv_prog_tar_$1}" && break
 4686 
 4687     # tar/untar a dummy directory, and stop if the command works.
 4688     rm -rf conftest.dir
 4689     mkdir conftest.dir
 4690     echo GrepMe > conftest.dir/file
 4691     AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar])
 4692     rm -rf conftest.dir
 4693     if test -s conftest.tar; then
 4694       AM_RUN_LOG([$am__untar <conftest.tar])
 4695       AM_RUN_LOG([cat conftest.dir/file])
 4696       grep GrepMe conftest.dir/file >/dev/null 2>&1 && break
 4697     fi
 4698   done
 4699   rm -rf conftest.dir
 4700 
 4701   AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool])
 4702   AC_MSG_RESULT([$am_cv_prog_tar_$1])])
 4703 
 4704 AC_SUBST([am__tar])
 4705 AC_SUBST([am__untar])
 4706 ]) # _AM_PROG_TAR
 4707