From f64b2474be0d4f0f5ad20c511400f02b1cb981f0 Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Sat, 9 Sep 2006 01:49:38 +0000 Subject: r18278: move more header checks and _GNU_SOURCE into libreplace (This used to be commit 77c442cd469ba881215e025c87ce632c876eb617) --- source4/lib/replace/libreplace.m4 | 3 ++- source4/lib/replace/replace.h | 8 ++++++++ 2 files changed, 10 insertions(+), 1 deletion(-) (limited to 'source4/lib/replace') diff --git a/source4/lib/replace/libreplace.m4 b/source4/lib/replace/libreplace.m4 index cdd83113ed..2fe58bf1e8 100644 --- a/source4/lib/replace/libreplace.m4 +++ b/source4/lib/replace/libreplace.m4 @@ -1,5 +1,6 @@ dnl needed before AC_TRY_COMPILE AC_ISC_POSIX +AC_USE_SYSTEM_EXTENSIONS AC_C_INLINE @@ -57,7 +58,7 @@ AC_FUNC_MEMCMP AC_CHECK_FUNCS(pipe strftime srandom random srand rand usleep setbuffer) -AC_CHECK_HEADERS(stdbool.h) +AC_CHECK_HEADERS(stdbool.h stddef.h) AC_CHECK_TYPE(bool, [AC_DEFINE(HAVE_BOOL, 1, [Whether the bool type is available])],, diff --git a/source4/lib/replace/replace.h b/source4/lib/replace/replace.h index 1a6e1588cb..3bf884c80c 100644 --- a/source4/lib/replace/replace.h +++ b/source4/lib/replace/replace.h @@ -61,6 +61,14 @@ #include #endif +#ifdef HAVE_SYS_TYPES_H +#include +#endif + +#ifdef HAVE_STDDEF_H +#include +#endif + #ifndef HAVE_STRERROR extern char *sys_errlist[]; #define strerror(i) sys_errlist[i] -- cgit