r8037: a fairly major update to the internals of ldb. Changes are:
[sfrench/samba-autobuild/.git] / source / lib / ldb / include / includes.h
index 4926e1524a4dc00b1e06972b138133ef2e95998a..8b513e20c74763a5ace8bc6866af01a81aadca64 100644 (file)
@@ -5,8 +5,8 @@
 #ifndef _GNU_SOURCE
 #define _GNU_SOURCE
 #endif
+#include "config.h"
 #include <stdio.h>
-#include <stdint.h>
 #include <string.h>
 #include <stdlib.h>
 #include <errno.h>
 #include <fnmatch.h>
 #include <sys/time.h>
 #include <time.h>
+#ifdef HAVE_STDINT_H
+#include <stdint.h>
+#endif
 
 #include "ldb.h"
 #include "ldb_private.h"
+#include "talloc.h"
 
-#ifdef HAVE_INTPTR_T
+#if defined(__intptr_t_defined) || defined(HAVE_INTPTR_T)
 #define discard_const(ptr) ((void *)((intptr_t)(ptr)))
 #else
 #define discard_const(ptr) ((void *)(ptr))
 #endif
 #define discard_const_p(type, ptr) ((type *)discard_const(ptr))
-
-