From f22ee5a27541220707d7800a030000c9f786eabe Mon Sep 17 00:00:00 2001 From: Mark Eichin Date: Wed, 17 Aug 1994 02:28:14 +0000 Subject: [PATCH] fix time includes git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@4166 dc483132-0cff-0310-8789-dd5450dbe970 --- src/kadmin/server/adm_fmt_inq.c | 2 +- src/kdc/kerberos_v4.c | 5 ++++- src/lib/crypto/os/rnd_confoun.c | 5 ++++- src/lib/krb5/asn.1/asn1_decode.c | 8 ++++++-- src/lib/krb5/os/configure.in | 2 +- src/lib/krb5/os/gmt_mktime.c | 8 ++++++-- 6 files changed, 22 insertions(+), 8 deletions(-) diff --git a/src/kadmin/server/adm_fmt_inq.c b/src/kadmin/server/adm_fmt_inq.c index 698203772..be1813258 100644 --- a/src/kadmin/server/adm_fmt_inq.c +++ b/src/kadmin/server/adm_fmt_inq.c @@ -41,7 +41,7 @@ static char rcsid_adm_fmt_inq[] = #include -#ifdef USE_SYS_TIME_H +#ifdef HAVE_SYS_TIME_H #include #ifdef TIME_WITH_SYS_TIME #include diff --git a/src/kdc/kerberos_v4.c b/src/kdc/kerberos_v4.c index 757026b29..6db66075f 100644 --- a/src/kdc/kerberos_v4.c +++ b/src/kdc/kerberos_v4.c @@ -50,8 +50,11 @@ static char rcsid_kerberos_v4_c[] = #include #endif #include -#ifdef USE_SYS_TIME_H +#ifdef HAVE_SYS_TIME_H #include +#ifdef TIME_WITH_SYS_TIME +#include +#endif #else #include #endif diff --git a/src/lib/crypto/os/rnd_confoun.c b/src/lib/crypto/os/rnd_confoun.c index 9d01b1d96..5137af176 100644 --- a/src/lib/crypto/os/rnd_confoun.c +++ b/src/lib/crypto/os/rnd_confoun.c @@ -32,8 +32,11 @@ static char rcsid_rnd_counfoun_c[] = #include #include -#ifdef USE_SYS_TIME_H +#ifdef HAVE_SYS_TIME_H #include +#ifdef TIME_WITH_SYS_TIME +#include +#endif #else #include #endif diff --git a/src/lib/krb5/asn.1/asn1_decode.c b/src/lib/krb5/asn.1/asn1_decode.c index 82dde8f00..76304ece6 100644 --- a/src/lib/krb5/asn.1/asn1_decode.c +++ b/src/lib/krb5/asn.1/asn1_decode.c @@ -25,9 +25,13 @@ /* ASN.1 primitive decoders */ #include "asn1_decode.h" #include "asn1_get.h" -#include -#ifdef USE_SYS_TIME_H +#ifdef HAVE_SYS_TIME_H #include +#ifdef TIME_WITH_SYS_TIME +#include +#endif +#else +#include #endif #define setup()\ diff --git a/src/lib/krb5/os/configure.in b/src/lib/krb5/os/configure.in index 4da1e1f7b..25cd1afec 100644 --- a/src/lib/krb5/os/configure.in +++ b/src/lib/krb5/os/configure.in @@ -2,7 +2,7 @@ AC_INIT(configure.in) dnl time checks are for timeofday.c (which gets them from osconf.h) dnl and gmt_mktime.c (which only gets them from here...) AC_TIME_WITH_SYS_TIME -AC_HEADER_CHECK(sys/time.h,AC_DEFINE(USE_SYS_TIME_H)) +AC_HAVE_HEADERS(sys/time.h) AC_HEADER_EGREP(time_t, sys/types.h, AC_DEFINE(POSIX_TYPES)) WITH_CCOPTS AC_SET_BUILDTOP diff --git a/src/lib/krb5/os/gmt_mktime.c b/src/lib/krb5/os/gmt_mktime.c index d4e759d17..01d87dd48 100644 --- a/src/lib/krb5/os/gmt_mktime.c +++ b/src/lib/krb5/os/gmt_mktime.c @@ -3,9 +3,13 @@ #include #include -#include -#ifdef USE_SYS_TIME_H +#ifdef HAVE_SYS_TIME_H #include +#ifdef TIME_WITH_SYS_TIME +#include +#endif +#else +#include #endif /* take a struct tm, return seconds from GMT epoch */ -- 2.26.2