diff options
author | Michael Adam <obnox@samba.org> | 2007-12-03 16:43:51 +0100 |
---|---|---|
committer | Michael Adam <obnox@samba.org> | 2007-12-03 16:54:12 +0100 |
commit | f5b071e3b0c186e5e78b905c5c4c13d3421f6f46 (patch) | |
tree | 45415a5b43c961e6a1db49385e33214837d324fe /source3/lib/replace/system/config.m4 | |
parent | fc0a63153fec7d56e35f484b80891d1a7e66e35a (diff) | |
download | samba-f5b071e3b0c186e5e78b905c5c4c13d3421f6f46.tar.gz samba-f5b071e3b0c186e5e78b905c5c4c13d3421f6f46.tar.bz2 samba-f5b071e3b0c186e5e78b905c5c4c13d3421f6f46.zip |
Move check for broken system capabilites.h headers to lib/replace.
Michael
(This used to be commit 8ec10c4ab1aa890c9f03d34bd872c93ae5c4d84c)
Diffstat (limited to 'source3/lib/replace/system/config.m4')
-rw-r--r-- | source3/lib/replace/system/config.m4 | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/source3/lib/replace/system/config.m4 b/source3/lib/replace/system/config.m4 index 6500535982..0b3baff459 100644 --- a/source3/lib/replace/system/config.m4 +++ b/source3/lib/replace/system/config.m4 @@ -16,6 +16,36 @@ AC_HEADER_SYS_WAIT # capability AC_CHECK_HEADERS(sys/capability.h) +case "$host_os" in +*linux*) +AC_CACHE_CHECK([for broken RedHat 7.2 system header files],samba_cv_BROKEN_REDHAT_7_SYSTEM_HEADERS,[ +AC_TRY_COMPILE([ +#ifdef HAVE_SYS_VFS_H +#include <sys/vfs.h> +#endif +#ifdef HAVE_SYS_CAPABILITY_H +#include <sys/capability.h> +#endif +],[int i;], + samba_cv_BROKEN_REDHAT_7_SYSTEM_HEADERS=no,samba_cv_BROKEN_REDHAT_7_SYSTEM_HEADERS=yes)]) +if test x"$samba_cv_BROKEN_REDHAT_7_SYSTEM_HEADERS" = x"yes"; then + AC_DEFINE(BROKEN_REDHAT_7_SYSTEM_HEADERS,1,[Broken RedHat 7.2 system header files]) +fi + +AC_CACHE_CHECK([for broken RHEL5 sys/capability.h],samba_cv_BROKEN_RHEL5_SYS_CAP_HEADER,[ +AC_TRY_COMPILE([ +#ifdef HAVE_SYS_CAPABILITY_H +#include <sys/capability.h> +#endif +#include <linux/types.h> +],[__s8 i;], + samba_cv_BROKEN_RHEL5_SYS_CAP_HEADER=no,samba_cv_BROKEN_RHEL5_SYS_CAP_HEADER=yes)]) +if test x"$samba_cv_BROKEN_RHEL5_SYS_CAP_HEADER" = x"yes"; then + AC_DEFINE(BROKEN_RHEL5_SYS_CAP_HEADER,1,[Broken RHEL5 sys/capability.h]) +fi +;; +esac + # passwd AC_CHECK_HEADERS(grp.h sys/id.h compat.h shadow.h sys/priv.h pwd.h sys/security.h) AC_CHECK_FUNCS(getpwnam_r getpwuid_r getpwent_r) |