From 64aae11be78e118de49ebc4ab982023b12a04fe2 Mon Sep 17 00:00:00 2001 From: Peter Verthez Date: Sat, 26 Oct 2002 16:54:22 +0000 Subject: [PATCH] Check for glibc 2.2 iconv (2.2 is needed for the ansel module). --- acinclude.m4 | 10 ++++++---- configure.in | 4 ++-- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/acinclude.m4 b/acinclude.m4 index f2c30c9..9edd0bc 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -55,17 +55,19 @@ dnl Own functions dnl gedcom_GLIBC_ICONV() dnl Checks whether iconv is coming from glibc, defines USE_GLIBC_ICONV if so dnl The variable $is_glibc_iconv contains yes or no -AC_DEFUN(gedcom_GLIBC_ICONV, [ - AC_CACHE_CHECK(for the GNU C Library iconv implementation, is_glibc_iconv, [ +AC_DEFUN(gedcom_GLIBC22_ICONV, [ + AC_CACHE_CHECK(for the GNU C Library 2.2 iconv implementation, is_glibc22_iconv, [ AC_EGREP_CPP(yes, [ #include #ifdef __GLIBC__ + #if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 2) || (__GLIBC__ > 2) yes + #endif #endif - ], is_glibc_iconv=yes, is_glibc_iconv=no) + ], is_glibc22_iconv=yes, is_glibc22_iconv=no) ]) - if test "$is_glibc_iconv" = yes; then + if test "$is_glibc22_iconv" = yes; then AC_DEFINE(USE_GLIBC_ICONV,1, [Define if the GNU implementation of iconv in glibc is used]) fi diff --git a/configure.in b/configure.in index be4c412..54c2329 100644 --- a/configure.in +++ b/configure.in @@ -99,8 +99,8 @@ else AC_SUBST(LCS_SUBDIRS) AC_SUBST(LCS_INCLUDES) AC_SUBST(LCS_LIBADD) - gedcom_GLIBC_ICONV - if test "$is_glibc_iconv" = yes; then + gedcom_GLIBC22_ICONV + if test "$is_glibc22_iconv" = yes; then DIRS="glibc" is_ansel_supported=yes AC_SUBST(DIRS) -- 2.30.2