diff options
author | Andrew Tridgell <tridge@samba.org> | 2006-09-07 12:10:06 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 14:17:52 -0500 |
commit | 24f4b6eff2ed9216be93674310ffcc44b7893895 (patch) | |
tree | d93c9bb54f7a8cbd4be09047cc54d6fcc22766ec /source4/lib | |
parent | 2cd4e0264ff2a852c657049ac27b13d8d5d27fc3 (diff) | |
download | samba-24f4b6eff2ed9216be93674310ffcc44b7893895.tar.gz samba-24f4b6eff2ed9216be93674310ffcc44b7893895.tar.bz2 samba-24f4b6eff2ed9216be93674310ffcc44b7893895.zip |
r18219: move some more portability checks out of samba4 and info lib/replace
(This used to be commit 50318dc55ed5eb70adb02a5680498fad3c3e590d)
Diffstat (limited to 'source4/lib')
-rw-r--r-- | source4/lib/replace/libreplace.m4 | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/source4/lib/replace/libreplace.m4 b/source4/lib/replace/libreplace.m4 index 1b3258e184..c72de29b1e 100644 --- a/source4/lib/replace/libreplace.m4 +++ b/source4/lib/replace/libreplace.m4 @@ -14,6 +14,8 @@ done LIBREPLACEOBJ="dlfcn.o getpass.o replace.o snprintf.o timegm.o" AC_SUBST(LIBREPLACEOBJ) +AC_SYS_LARGEFILE + AC_CHECK_HEADERS([stdint.h inttypes.h]) AC_CHECK_TYPE(uint_t, unsigned int) AC_CHECK_TYPE(uint8_t, unsigned char) @@ -25,6 +27,22 @@ AC_CHECK_TYPE(intptr_t, unsigned long long) AC_CHECK_TYPE(uint32_t, unsigned long) AC_CHECK_TYPE(ssize_t, int) +AC_TYPE_SIGNAL +AC_TYPE_UID_T +AC_TYPE_MODE_T +AC_TYPE_OFF_T +AC_TYPE_SIZE_T +AC_TYPE_PID_T +AC_STRUCT_ST_RDEV +AC_CHECK_TYPE(ino_t,unsigned) +AC_CHECK_TYPE(loff_t,off_t) +AC_CHECK_TYPE(offset_t,loff_t) +AC_CHECK_TYPES(long long) + +AC_FUNC_MEMCMP + +AC_CHECK_FUNCS(pipe strftime srandom random srand rand usleep setbuffer) + AC_CHECK_HEADERS(stdbool.h) AC_CHECK_TYPE(bool, @@ -229,3 +247,16 @@ if test x"$samba_cv_sig_atomic_t" = x"yes"; then fi +AC_CACHE_CHECK([for O_DIRECT flag to open(2)],samba_cv_HAVE_OPEN_O_DIRECT,[ +AC_TRY_COMPILE([ +#include <unistd.h> +#ifdef HAVE_FCNTL_H +#include <fcntl.h> +#endif], +[int fd = open("/dev/null", O_DIRECT);], +samba_cv_HAVE_OPEN_O_DIRECT=yes,samba_cv_HAVE_OPEN_O_DIRECT=no)]) +if test x"$samba_cv_HAVE_OPEN_O_DIRECT" = x"yes"; then + AC_DEFINE(HAVE_OPEN_O_DIRECT,1,[Whether the open(2) accepts O_DIRECT]) +fi + + |