From: Chris Allegretta Date: Thu, 24 Jan 2002 22:00:50 +0000 (+0000) Subject: Oops, add glib21.m4 to the m4 dir X-Git-Tag: v1.1.6~1 X-Git-Url: https://git.wh0rd.org/?a=commitdiff_plain;h=915b680e6bd102f0018c7b95c7b287a5f654626f;p=nano.git Oops, add glib21.m4 to the m4 dir git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1040 35c25a1d-7b9e-4130-9fde-d3aeb78583b8 --- diff --git a/Makefile.am b/Makefile.am index 8822344c..d3a6d7ba 100644 --- a/Makefile.am +++ b/Makefile.am @@ -4,7 +4,7 @@ M4DIR = $(srcdir)/m4 ACLOCAL_AMFLAGS = -I $(M4DIR) ACINCLUDE_INPUTS = $(M4DIR)/gettext.m4 $(M4DIR)/largefile.m4 \ $(M4DIR)/progtest.m4 $(M4DIR)/lcmessage.m4 $(M4DIR)/iconv.m4 \ - $(M4DIR)/codeset.m4 + $(M4DIR)/codeset.m4 $(M4DIR)/glibc21.m4 bin_PROGRAMS = nano nano_SOURCES = color.c \ diff --git a/m4/gettext.m4 b/m4/gettext.m4 index ce37a76b..a313f0a9 100644 --- a/m4/gettext.m4 +++ b/m4/gettext.m4 @@ -307,7 +307,7 @@ AC_DEFUN([NANO_AM_GNU_GETTEXT], AC_REQUIRE([AC_TYPE_SIZE_T])dnl AC_REQUIRE([AC_FUNC_ALLOCA])dnl AC_REQUIRE([AC_FUNC_MMAP])dnl - AC_REQUIRE([jm_GLIBC21])dnl + AC_REQUIRE([nano_jm_GLIBC21])dnl AC_CHECK_HEADERS([argz.h limits.h locale.h nl_types.h malloc.h stddef.h \ stdlib.h string.h unistd.h sys/param.h]) diff --git a/m4/glibc21.m4 b/m4/glibc21.m4 new file mode 100644 index 00000000..314beb1e --- /dev/null +++ b/m4/glibc21.m4 @@ -0,0 +1,26 @@ +#serial 2 + +# Test for the GNU C Library, version 2.1 or newer. +# From Bruno Haible. + +AC_DEFUN([nano_jm_GLIBC21], + [ + AC_CACHE_CHECK(whether we are using the GNU C Library 2.1 or newer, + ac_cv_gnu_library_2_1, + [AC_EGREP_CPP([Lucky GNU user], + [ +#include +#ifdef __GNU_LIBRARY__ + #if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) || (__GLIBC__ > 2) + Lucky GNU user + #endif +#endif + ], + ac_cv_gnu_library_2_1=yes, + ac_cv_gnu_library_2_1=no) + ] + ) + AC_SUBST(GLIBC21) + GLIBC21="$ac_cv_gnu_library_2_1" + ] +)