diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-27 07:24:22 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-27 07:24:22 +0000 |
commit | 45d6379135504814ab723b57f0eb8be23393a51d (patch) | |
tree | d4f2ec4acca824a8446387a758b0ce4238a4dffa /m4/compat.m4 | |
parent | Initial commit. (diff) | |
download | bind9-45d6379135504814ab723b57f0eb8be23393a51d.tar.xz bind9-45d6379135504814ab723b57f0eb8be23393a51d.zip |
Adding upstream version 1:9.16.44.upstream/1%9.16.44
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'm4/compat.m4')
-rw-r--r-- | m4/compat.m4 | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/m4/compat.m4 b/m4/compat.m4 new file mode 100644 index 0000000..2d204b2 --- /dev/null +++ b/m4/compat.m4 @@ -0,0 +1,28 @@ +# Copyright (c) 2021 Internet Systems Consortium +# +# SPDX-License-Identifier: FSFAP +# +# backwards compat with older pkg-config +# - pull in AC_DEFUN from pkg.m4 +m4_ifndef([PKG_CHECK_VAR], [ +# PKG_CHECK_VAR(VARIABLE, MODULE, CONFIG-VARIABLE, +# [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) +# ------------------------------------------- +# Retrieves the value of the pkg-config variable for the given module. +AC_DEFUN([PKG_CHECK_VAR], +[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl +AC_ARG_VAR([$1], [value of $3 for $2, overriding pkg-config])dnl + +_PKG_CONFIG([$1], [variable="][$3]["], [$2]) +AS_VAR_COPY([$1], [pkg_cv_][$1]) + +AS_VAR_IF([$1], [""], [$5], [$4])dnl +])# PKG_CHECK_VAR +]) + +# This hack makes PKG_CHECK_VARS from m4/pkg.m4 work on autoconf 2.63 +# ( courtesy of sunnybear in https://github.com/gdnsd/gdnsd/issues/85 ) +m4_ifndef([AS_VAR_COPY], +[m4_define([AS_VAR_COPY], +[AS_LITERAL_IF([$1[]$2], [$1=$$2], [eval $1=\$$2])])]) +## End Autoconf-2.63-Compat |