summaryrefslogtreecommitdiff
path: root/source3/configure.in
diff options
context:
space:
mode:
authorVolker Lendecke <vlendec@samba.org>2003-11-03 18:11:00 +0000
committerVolker Lendecke <vlendec@samba.org>2003-11-03 18:11:00 +0000
commita64c70d74adca2da7a745f01289a5e50107e8f1d (patch)
treea88a95658d67d065c2078af0db92a81df6fbd368 /source3/configure.in
parentfbb8f131c2336e921677f41e9fb8bce7406f3336 (diff)
downloadsamba-a64c70d74adca2da7a745f01289a5e50107e8f1d.tar.gz
samba-a64c70d74adca2da7a745f01289a5e50107e8f1d.tar.bz2
samba-a64c70d74adca2da7a745f01289a5e50107e8f1d.zip
AC_CHECK_MEMBER seems to have problems for some versions of autoconf, at least
autoconf-2.53 on SLES8 does not correctly find the keyblock. Volker (This used to be commit c4f36a250a5126dac0d2f6d395d75a2437c8e56d)
Diffstat (limited to 'source3/configure.in')
-rw-r--r--source3/configure.in32
1 files changed, 23 insertions, 9 deletions
diff --git a/source3/configure.in b/source3/configure.in
index 578fa7a152..09a6848e11 100644
--- a/source3/configure.in
+++ b/source3/configure.in
@@ -2664,15 +2664,29 @@ if test x"$with_ads_support" != x"no"; then
[Whether in-memory keytabs are supported])
fi
- AC_CHECK_MEMBER(krb5_keytab_entry.key,
- AC_DEFINE(HAVE_KRB5_KEYTAB_ENTRY_KEY, 1,
- [Whether krb5_keytab_entry has key member]), [],
- [#include <krb5.h>])
-
- AC_CHECK_MEMBER(krb5_keytab_entry.keyblock,
- AC_DEFINE(HAVE_KRB5_KEYTAB_ENTRY_KEYBLOCK, 1,
- [Whether krb5_keytab_entry has keyblock member]), [],
- [#include <krb5.h>])
+ AC_CACHE_CHECK([for key in krb5_keytab_entry],
+ samba_cv_HAVE_KRB5_KEYTAB_ENTRY_KEY,[
+ AC_TRY_COMPILE([#include <krb5.h>],
+ [krb5_keytab_entry entry; entry.key = NULL;],
+ samba_cv_HAVE_KRB5_KEYTAB_ENTRY_KEY=yes,
+ samba_cv_HAVE_KRB5_KEYTAB_ENTRY_KEY=no)])
+
+ if test x"$samba_cv_HAVE_KRB5_KEYTAB_ENTRY_KEY" = x"yes"; then
+ AC_DEFINE(HAVE_KRB5_KEYTAB_ENTRY_KEY,1,
+ [Whether krb5_keytab_entry has key member])
+ fi
+
+ AC_CACHE_CHECK([for keyblock in krb5_keytab_entry],
+ samba_cv_HAVE_KRB5_KEYTAB_ENTRY_KEYBLOCK,[
+ AC_TRY_COMPILE([#include <krb5.h>],
+ [krb5_keytab_entry entry; entry.keyblock.keytype = 0;],
+ samba_cv_HAVE_KRB5_KEYTAB_ENTRY_KEYBLOCK=yes,
+ samba_cv_HAVE_KRB5_KEYTAB_ENTRY_KEYBLOCK=no)])
+
+ if test x"$samba_cv_HAVE_KRB5_KEYTAB_ENTRY_KEYBLOCK" = x"yes"; then
+ AC_DEFINE(HAVE_KRB5_KEYTAB_ENTRY_KEYBLOCK,1,
+ [Whether krb5_keytab_entry has keyblock member])
+ fi
if test x"$ac_cv_lib_ext_krb5_krb5_mk_req_extended" = x"yes"; then
AC_DEFINE(HAVE_KRB5,1,[Whether to have KRB5 support])