i18n: Add HAVE_USELOCALE as a requirement for USE_GNU_LOCALE_API.
authorMark H Weaver <mhw@netris.org>
Wed, 15 Oct 2014 00:36:11 +0000 (20:36 -0400)
committerMark H Weaver <mhw@netris.org>
Wed, 15 Oct 2014 00:36:19 +0000 (20:36 -0400)
* configure.ac: Check for uselocale.
* libguile/i18n.c: Add HAVE_USELOCALE to the list of requirements
  before defining USE_GNU_LOCALE_API.

configure.ac
libguile/i18n.c

index a323f70..4f40736 100644 (file)
@@ -751,9 +751,8 @@ AC_CHECK_HEADERS([assert.h crt_externs.h])
 #   truncate - not in mingw
 #   isblank - available as a GNU extension or in C99
 #   _NSGetEnviron - Darwin specific
-#   strcoll_l, newlocale - GNU extensions (glibc), also available on Darwin
+#   strcoll_l, newlocale, uselocale, utimensat - POSIX.1-2008
 #   fork - unavailable on Windows
-#   utimensat - posix.1-2008
 #   sched_getaffinity, sched_setaffinity - GNU extensions (glibc)
 #   sendfile - non-POSIX, found in glibc
 #
@@ -766,7 +765,7 @@ AC_CHECK_FUNCS([DINFINITY DQNAN cexp chsize clog clog10 ctermid             \
   strdup system usleep atexit on_exit chown link fcntl ttyname getpwent        \
   getgrent kill getppid getpgrp fork setitimer getitimer strchr strcmp \
   index bcopy memcpy rindex truncate unsetenv isblank _NSGetEnviron    \
-  strcoll strcoll_l newlocale utimensat sched_getaffinity              \
+  strcoll strcoll_l newlocale uselocale utimensat sched_getaffinity    \
   sched_setaffinity sendfile])
 
 # Reasons for testing:
index c6b9b84..f0e3443 100644 (file)
@@ -40,7 +40,7 @@
 #include <unicase.h>
 #include <unistr.h>
 
-#if (defined HAVE_NEWLOCALE) && (defined HAVE_STRCOLL_L)
+#if defined HAVE_NEWLOCALE && defined HAVE_STRCOLL_L && defined HAVE_USELOCALE
 /* The GNU thread-aware locale API is documented in ``Thread-Aware Locale
    Model, a Proposal'', by Ulrich Drepper: