Update GnuPG related m4 files.
* m4/gpg-error.m4: Update from libgpg-error. * m4/libassuan.m4: Update from libassuan.
This commit is contained in:
parent
fdcd5736e6
commit
863c0f2a3e
@ -15,10 +15,21 @@ dnl Test for libgpg-error and define GPG_ERROR_CFLAGS and GPG_ERROR_LIBS
|
|||||||
dnl
|
dnl
|
||||||
AC_DEFUN([AM_PATH_GPG_ERROR],
|
AC_DEFUN([AM_PATH_GPG_ERROR],
|
||||||
[ AC_REQUIRE([AC_CANONICAL_HOST])
|
[ AC_REQUIRE([AC_CANONICAL_HOST])
|
||||||
AC_ARG_WITH(gpg-error-prefix,
|
gpg_error_config_prefix=""
|
||||||
AC_HELP_STRING([--with-gpg-error-prefix=PFX],
|
dnl --with-libgpg-error-prefix=PFX is the preferred name for this option,
|
||||||
|
dnl since that is consistent with how our three siblings use the directory/
|
||||||
|
dnl package name in --with-$dir_name-prefix=PFX.
|
||||||
|
AC_ARG_WITH(libgpg-error-prefix,
|
||||||
|
AC_HELP_STRING([--with-libgpg-error-prefix=PFX],
|
||||||
[prefix where GPG Error is installed (optional)]),
|
[prefix where GPG Error is installed (optional)]),
|
||||||
gpg_error_config_prefix="$withval", gpg_error_config_prefix="")
|
[gpg_error_config_prefix="$withval"])
|
||||||
|
|
||||||
|
dnl Accept --with-gpg-error-prefix and make it work the same as
|
||||||
|
dnl --with-libgpg-error-prefix above, for backwards compatibility,
|
||||||
|
dnl but do not document this old, inconsistently-named option.
|
||||||
|
AC_ARG_WITH(gpg-error-prefix,,
|
||||||
|
[gpg_error_config_prefix="$withval"])
|
||||||
|
|
||||||
if test x$gpg_error_config_prefix != x ; then
|
if test x$gpg_error_config_prefix != x ; then
|
||||||
if test x${GPG_ERROR_CONFIG+set} != xset ; then
|
if test x${GPG_ERROR_CONFIG+set} != xset ; then
|
||||||
GPG_ERROR_CONFIG=$gpg_error_config_prefix/bin/gpg-error-config
|
GPG_ERROR_CONFIG=$gpg_error_config_prefix/bin/gpg-error-config
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
dnl Autoconf macros for libassuan
|
dnl Autoconf macros for libassuan
|
||||||
dnl Copyright (C) 2002, 2003 Free Software Foundation, Inc.
|
dnl Copyright (C) 2002, 2003, 2011 Free Software Foundation, Inc.
|
||||||
dnl
|
dnl
|
||||||
dnl This file is free software; as a special exception the author gives
|
dnl This file is free software; as a special exception the author gives
|
||||||
dnl unlimited permission to copy and/or distribute it, with or without
|
dnl unlimited permission to copy and/or distribute it, with or without
|
||||||
@ -14,7 +14,8 @@ dnl Common code used for libassuan detection [internal]
|
|||||||
dnl Returns ok set to yes or no.
|
dnl Returns ok set to yes or no.
|
||||||
dnl
|
dnl
|
||||||
AC_DEFUN([_AM_PATH_LIBASSUAN_COMMON],
|
AC_DEFUN([_AM_PATH_LIBASSUAN_COMMON],
|
||||||
[ AC_ARG_WITH(libassuan-prefix,
|
[ AC_REQUIRE([AC_CANONICAL_HOST])
|
||||||
|
AC_ARG_WITH(libassuan-prefix,
|
||||||
AC_HELP_STRING([--with-libassuan-prefix=PFX],
|
AC_HELP_STRING([--with-libassuan-prefix=PFX],
|
||||||
[prefix where LIBASSUAN is installed (optional)]),
|
[prefix where LIBASSUAN is installed (optional)]),
|
||||||
libassuan_config_prefix="$withval", libassuan_config_prefix="")
|
libassuan_config_prefix="$withval", libassuan_config_prefix="")
|
||||||
@ -24,7 +25,8 @@ AC_DEFUN([_AM_PATH_LIBASSUAN_COMMON],
|
|||||||
LIBASSUAN_CONFIG=$libassuan_config_prefix/bin/libassuan-config
|
LIBASSUAN_CONFIG=$libassuan_config_prefix/bin/libassuan-config
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
AC_PATH_PROG(LIBASSUAN_CONFIG, libassuan-config, no)
|
|
||||||
|
AC_PATH_TOOL(LIBASSUAN_CONFIG, libassuan-config, no)
|
||||||
|
|
||||||
tmp=ifelse([$1], ,1:0.9.2,$1)
|
tmp=ifelse([$1], ,1:0.9.2,$1)
|
||||||
if echo "$tmp" | grep ':' >/dev/null 2>/dev/null ; then
|
if echo "$tmp" | grep ':' >/dev/null 2>/dev/null ; then
|
||||||
@ -35,46 +37,44 @@ AC_DEFUN([_AM_PATH_LIBASSUAN_COMMON],
|
|||||||
min_libassuan_version="$tmp"
|
min_libassuan_version="$tmp"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if test "$LIBASSUAN_CONFIG" != "no" ; then
|
AC_MSG_CHECKING(for LIBASSUAN - version >= $min_libassuan_version)
|
||||||
libassuan_version=`$LIBASSUAN_CONFIG --version`
|
|
||||||
fi
|
|
||||||
libassuan_version_major=`echo $libassuan_version | \
|
|
||||||
sed 's/\([[0-9]]*\)\.\([[0-9]]*\)\.\([[0-9]]*\).*/\1/'`
|
|
||||||
libassuan_version_minor=`echo $libassuan_version | \
|
|
||||||
sed 's/\([[0-9]]*\)\.\([[0-9]]*\)\.\([[0-9]]*\).*/\2/'`
|
|
||||||
libassuan_version_micro=`echo $libassuan_version | \
|
|
||||||
sed 's/\([[0-9]]*\)\.\([[0-9]]*\)\.\([[0-9]]*\).*/\3/'`
|
|
||||||
|
|
||||||
AC_MSG_CHECKING(for LIBASSUAN ifelse([$2], ,,[$2 ])- version >= $min_libassuan_version)
|
|
||||||
ok=no
|
ok=no
|
||||||
if test "$LIBASSUAN_CONFIG" != "no" ; then
|
if test "$LIBASSUAN_CONFIG" != "no" \
|
||||||
ifelse([$2], ,,[if `$LIBASSUAN_CONFIG --thread=$2 2> /dev/null` ; then])
|
&& test -f "$LIBASSUAN_CONFIG" ; then
|
||||||
req_major=`echo $min_libassuan_version | \
|
req_major=`echo $min_libassuan_version | \
|
||||||
sed 's/\([[0-9]]*\)\.\([[0-9]]*\)\.\([[0-9]]*\)/\1/'`
|
sed 's/\([[0-9]]*\)\.\([[0-9]]*\)\.\([[0-9]]*\)/\1/'`
|
||||||
req_minor=`echo $min_libassuan_version | \
|
req_minor=`echo $min_libassuan_version | \
|
||||||
sed 's/\([[0-9]]*\)\.\([[0-9]]*\)\.\([[0-9]]*\)/\2/'`
|
sed 's/\([[0-9]]*\)\.\([[0-9]]*\)\.\([[0-9]]*\)/\2/'`
|
||||||
req_micro=`echo $min_libassuan_version | \
|
req_micro=`echo $min_libassuan_version | \
|
||||||
sed 's/\([[0-9]]*\)\.\([[0-9]]*\)\.\([[0-9]]*\)/\3/'`
|
sed 's/\([[0-9]]*\)\.\([[0-9]]*\)\.\([[0-9]]*\)/\3/'`
|
||||||
if test "$libassuan_version_major" -gt "$req_major"; then
|
|
||||||
|
libassuan_config_version=`$LIBASSUAN_CONFIG --version`
|
||||||
|
major=`echo $libassuan_config_version | \
|
||||||
|
sed 's/\([[0-9]]*\)\.\([[0-9]]*\)\.\([[0-9]]*\).*/\1/'`
|
||||||
|
minor=`echo $libassuan_config_version | \
|
||||||
|
sed 's/\([[0-9]]*\)\.\([[0-9]]*\)\.\([[0-9]]*\).*/\2/'`
|
||||||
|
micro=`echo $libassuan_config_version | \
|
||||||
|
sed 's/\([[0-9]]*\)\.\([[0-9]]*\)\.\([[0-9]]*\).*/\3/'`
|
||||||
|
|
||||||
|
if test "$major" -gt "$req_major"; then
|
||||||
ok=yes
|
ok=yes
|
||||||
else
|
else
|
||||||
if test "$libassuan_version_major" -eq "$req_major"; then
|
if test "$major" -eq "$req_major"; then
|
||||||
if test "$libassuan_version_minor" -gt "$req_minor"; then
|
if test "$minor" -gt "$req_minor"; then
|
||||||
ok=yes
|
ok=yes
|
||||||
else
|
else
|
||||||
if test "$libassuan_version_minor" -eq "$req_minor"; then
|
if test "$minor" -eq "$req_minor"; then
|
||||||
if test "$libassuan_version_micro" -ge "$req_micro"; then
|
if test "$micro" -ge "$req_micro"; then
|
||||||
ok=yes
|
ok=yes
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
ifelse([$2], ,,[fi])
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if test $ok = yes; then
|
if test $ok = yes; then
|
||||||
AC_MSG_RESULT([yes ($libassuan_version)])
|
AC_MSG_RESULT([yes ($libassuan_config_version)])
|
||||||
else
|
else
|
||||||
AC_MSG_RESULT(no)
|
AC_MSG_RESULT(no)
|
||||||
fi
|
fi
|
||||||
@ -83,7 +83,7 @@ AC_DEFUN([_AM_PATH_LIBASSUAN_COMMON],
|
|||||||
if test "$req_libassuan_api" -gt 0 ; then
|
if test "$req_libassuan_api" -gt 0 ; then
|
||||||
tmp=`$LIBASSUAN_CONFIG --api-version 2>/dev/null || echo 0`
|
tmp=`$LIBASSUAN_CONFIG --api-version 2>/dev/null || echo 0`
|
||||||
if test "$tmp" -gt 0 ; then
|
if test "$tmp" -gt 0 ; then
|
||||||
AC_MSG_CHECKING([LIBASSUAN ifelse([$2], ,,[$2 ])API version])
|
AC_MSG_CHECKING([LIBASSUAN API version])
|
||||||
if test "$req_libassuan_api" -eq "$tmp" ; then
|
if test "$req_libassuan_api" -eq "$tmp" ; then
|
||||||
AC_MSG_RESULT(okay)
|
AC_MSG_RESULT(okay)
|
||||||
else
|
else
|
||||||
@ -94,6 +94,23 @@ AC_DEFUN([_AM_PATH_LIBASSUAN_COMMON],
|
|||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if test $ok = yes; then
|
||||||
|
if test x"$host" != x ; then
|
||||||
|
libassuan_config_host=`$LIBASSUAN_CONFIG --host 2>/dev/null || echo none`
|
||||||
|
if test x"$libassuan_config_host" != xnone ; then
|
||||||
|
if test x"$libassuan_config_host" != x"$host" ; then
|
||||||
|
AC_MSG_WARN([[
|
||||||
|
***
|
||||||
|
*** The config script $LIBASSUAN_CONFIG was
|
||||||
|
*** built for $libassuan_config_host and thus may not match the
|
||||||
|
*** used host $host.
|
||||||
|
*** You may want to use the configure option --with-libassuan-prefix
|
||||||
|
*** to specify a matching config script.
|
||||||
|
***]])
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
fi
|
||||||
])
|
])
|
||||||
|
|
||||||
dnl AM_CHECK_LIBASSUAN([MINIMUM-VERSION,
|
dnl AM_CHECK_LIBASSUAN([MINIMUM-VERSION,
|
||||||
|
Loading…
Reference in New Issue
Block a user