diff --git a/source4/heimdal_build/krb5-types.h b/source4/heimdal_build/krb5-types.h index 4f55a80a585..b88194cadf9 100644 --- a/source4/heimdal_build/krb5-types.h +++ b/source4/heimdal_build/krb5-types.h @@ -1,14 +1,18 @@ /* krb5-types.h -- this file was generated for i686-pc-linux-gnu by $Id: bits.c,v 1.23 2005/01/05 15:22:02 lha Exp $ */ -#ifndef __krb5_types_h__ -#define __krb5_types_h__ +#ifndef __samba_krb5_types_h__ +#define __samba_krb5_types_h__ #include "replace.h" #include "system/network.h" +#if defined USING_SYSTEM_KRB5 && defined HEIMDAL_KRB5_TYPES_PATH +#include HEIMDAL_KRB5_TYPES_PATH +#else typedef socklen_t krb5_socklen_t; typedef int krb5_socket_t; typedef ssize_t krb5_ssize_t; +#endif -#endif /* __krb5_types_h__ */ +#endif /* __samb_krb5_types_h__ */ diff --git a/source4/heimdal_build/wscript_configure b/source4/heimdal_build/wscript_configure index 7bd499fa979..19f0bf218ec 100644 --- a/source4/heimdal_build/wscript_configure +++ b/source4/heimdal_build/wscript_configure @@ -176,7 +176,10 @@ if krb5_config: if l.startswith("libdir="): heimdal_libdirs.append(l.strip()[len("libdir="):]) elif l.startswith("includedir="): - heimdal_includedirs.append(l.strip()[len("includedir="):]) + include_path = l.strip()[len("includedir="):] + heimdal_includedirs.append(include_path) + conf.define('HEIMDAL_KRB5_TYPES_PATH', + include_path + "/krb5-types.h") finally: f.close()