diff options
author | Andrew Tridgell <tridge@samba.org> | 2006-09-10 11:47:21 +0000 |
---|---|---|
committer | Andrew Tridgell <tridge@samba.org> | 2006-09-10 11:47:21 +0000 |
commit | cef51c4fa4cb1f4550828a6e7554a43ad0748738 (patch) | |
tree | b2240a281953bfa603920de76f454a04ee0cca63 /source/lib/replace/libreplace.m4 | |
parent | 538a3b09e9a5e9f0893f085be9a2a27ca4ec40eb (diff) | |
download | samba-cef51c4fa4cb1f4550828a6e7554a43ad0748738.tar.gz samba-cef51c4fa4cb1f4550828a6e7554a43ad0748738.tar.xz samba-cef51c4fa4cb1f4550828a6e7554a43ad0748738.zip |
r18332: added back in our shared mmap test code
Diffstat (limited to 'source/lib/replace/libreplace.m4')
-rw-r--r-- | source/lib/replace/libreplace.m4 | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/source/lib/replace/libreplace.m4 b/source/lib/replace/libreplace.m4 index 6c8c01d687b..cd9d171662d 100644 --- a/source/lib/replace/libreplace.m4 +++ b/source/lib/replace/libreplace.m4 @@ -42,7 +42,6 @@ AC_HEADER_STDC AC_CHECK_SIZEOF(off_t,cross) AC_CHECK_SIZEOF(size_t,cross) AC_CHECK_SIZEOF(ssize_t,cross) -AC_FUNC_MMAP AC_CHECK_HEADERS([stdint.h inttypes.h]) AC_CHECK_TYPE(uint_t, unsigned int) @@ -83,9 +82,18 @@ AC_INCLUDES_DEFAULT ) +AC_CACHE_CHECK([for working mmap],samba_cv_HAVE_MMAP,[ +AC_TRY_RUN([#include "$libreplacedir/test/shared_mmap.c"], + samba_cv_HAVE_MMAP=yes,samba_cv_HAVE_MMAP=no,samba_cv_HAVE_MMAP=cross)]) +if test x"$samba_cv_HAVE_MMAP" = x"yes"; then + AC_DEFINE(HAVE_MMAP,1,[Whether mmap works]) +fi + + AC_CACHE_CHECK([for broken inet_ntoa],samba_cv_REPLACE_INET_NTOA,[ AC_TRY_RUN([ #include <stdio.h> +#include <unistd.h> #include <sys/types.h> #include <netinet/in.h> #ifdef HAVE_ARPA_INET_H |