diff --git a/config_cmake.h.in b/config_cmake.h.in index 47cfcc5e2..8071546fd 100644 --- a/config_cmake.h.in +++ b/config_cmake.h.in @@ -153,6 +153,9 @@ /* The size of wchar_t in bits. */ #define WCHAR_T_BITS ${WCHAR_T_BITS} +/* Define if xlocale.h is required for locale_t or wide character support */ +#cmakedefine HAVE_XLOCALE_H 1 + /* Enable large inode numbers on Mac OS X 10.5. */ #ifndef _DARWIN_USE_64_BIT_INODE # define _DARWIN_USE_64_BIT_INODE 1 diff --git a/src/wutil.h b/src/wutil.h index 28a8540d1..661e82d05 100644 --- a/src/wutil.h +++ b/src/wutil.h @@ -10,6 +10,10 @@ #include #include +#ifdef HAVE_XLOCALE_H +#include +#endif + #include "common.h" #include "maybe.h"