summaryrefslogtreecommitdiff
path: root/glib/configure.in
diff options
context:
space:
mode:
Diffstat (limited to 'glib/configure.in')
-rw-r--r--glib/configure.in23
1 files changed, 23 insertions, 0 deletions
diff --git a/glib/configure.in b/glib/configure.in
index 9df1d3922b..6c98e9fca6 100644
--- a/glib/configure.in
+++ b/glib/configure.in
@@ -134,4 +134,27 @@ if test $gtk_ok = yes; then
fi
AC_MSG_RESULT($gtk_ok)
+# The following is necessary for Linux libc-5.4.38
+
+AC_MSG_CHECKING(If iswalnum() and friends are properly defined)
+AC_TRY_LINK([#include <stdlib.h>],[
+#if (defined(HAVE_WCTYPE_H) || defined(HAVE_WCHAR_H))
+# ifdef HAVE_WCTYPE_H
+# include <wctype.h>
+# else
+# ifdef HAVE_WCHAR_H
+# include <wchar.h>
+# endif
+# endif
+#else
+# define iswalnum(c) ((wchar_t)(c) <= 0xFF && isalnum(c))
+#endif
+iswalnum((wchar_t) 0);
+], gtk_ok=yes, gtk_ok=no)
+
+if test $gtk_ok = no; then
+ AC_DEFINE(HAVE_BROKEN_WCTYPE)
+fi
+AC_MSG_RESULT($gtk_ok)
+
AC_OUTPUT(Makefile)