summaryrefslogtreecommitdiff
path: root/source3/configure.in
diff options
context:
space:
mode:
authorKai Blin <kai@samba.org>2010-07-02 22:35:28 +0200
committerKai Blin <kai@samba.org>2010-07-07 09:31:20 +0200
commit0b6cebd60288b37f28176e24abeb20109dfd70e5 (patch)
tree8c0236da570c8d98407f106209029046700d3671 /source3/configure.in
parent9c3a9824a9165e9d7cf362d4b8c6add8ad0cc983 (diff)
downloadsamba-0b6cebd60288b37f28176e24abeb20109dfd70e5.tar.gz
s3 build: Fix *netgrent prototype detection on opensolaris
Diffstat (limited to 'source3/configure.in')
-rw-r--r--source3/configure.in12
1 files changed, 9 insertions, 3 deletions
diff --git a/source3/configure.in b/source3/configure.in
index 424c320faef..4c17e4c928b 100644
--- a/source3/configure.in
+++ b/source3/configure.in
@@ -6424,21 +6424,27 @@ CFLAGS_SAVE=$CFLAGS
CFLAGS="$CFLAGS -Werror-implicit-function-declaration"
AC_CACHE_CHECK([for setnetgrent prototype],samba_cv_setnetgrent_prototype, [
AC_TRY_COMPILE([#include<netdb.h>
- #include<netgroup.h>],[setnetgrent("foo")],
+ #ifdef HAVE_NETGROUP_H
+ #include<netgroup.h>
+ #endif],[setnetgrent("foo")],
samba_cv_setnetgrent_prototype=yes, samba_cv_setnetgrent_prototype=no)])
if test x"$samba_cv_setnetgrent_prototype" = x"yes"; then
AC_DEFINE(HAVE_SETNETGRENT_PROTOTYPE, 1, [If setnetgrent prototype is defined])
fi
AC_CACHE_CHECK([for getnetgrent prototype],samba_cv_getnetgrent_prototype, [
AC_TRY_COMPILE([#include<netdb.h>
- #include<netgroup.h>],[char *dom, *user,*host; getnetgrent(&dom,&user,&host)],
+ #ifdef HAVE_NETGROUP_H
+ #include<netgroup.h>
+ #endif],[char *dom, *user,*host; getnetgrent(&dom,&user,&host)],
samba_cv_getnetgrent_prototype=yes, samba_cv_getnetgrent_prototype=no)])
if test x"$samba_cv_getnetgrent_prototype" = x"yes"; then
AC_DEFINE(HAVE_GETNETGRENT_PROTOTYPE, 1, [If getnetgrent prototype is defined])
fi
AC_CACHE_CHECK([for endnetgrent prototype],samba_cv_endnetgrent_prototype, [
AC_TRY_COMPILE([#include<netdb.h>
- #include<netgroup.h>],[endnetgrent()],
+ #ifdef HAVE_NETGROUP_H
+ #include<netgroup.h>
+ #endif],[endnetgrent()],
samba_cv_endnetgrent_prototype=yes, samba_cv_endnetgrent_prototype=no)])
if test x"$samba_cv_endnetgrent_prototype" = x"yes"; then
AC_DEFINE(HAVE_ENDNETGRENT_PROTOTYPE, 1, [If endnetgrent prototype is defined])