* encryption.h: added typedef prototype for sum_func function
with the windows api to make microsoft compiler happy.
* sysincl.h: conditionally include sys/file.h and sys/param.h since
windows doesn't have them.
* Makefile.in:
- changed macros with ${...} to $(...) since nmake barfs on {}.
- added windows only make preamble
- split the all target into unix and windows branches
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@4948
dc483132-0cff-0310-8789-
dd5450dbe970
+Mon Feb 6 19:42:7 1995 Keith Vetter (keithv@fusion.com)
+
+ * configure.in: added header checks for sys/param.h and sys/file.h.
+ * encryption.h: added typedef prototype for sum_func function
+ with the windows api to make microsoft compiler happy.
+ * sysincl.h: conditionally include sys/file.h and sys/param.h since
+ windows doesn't have them.
+ * Makefile.in:
+ - changed macros with ${...} to $(...) since nmake barfs on {}.
+ - added windows only make preamble
+ - split the all target into unix and windows branches
+
Fri Feb 10 14:54:26 1995 Theodore Y. Ts'o <tytso@dcl>
* asn1.h: Removed ISODE cruft -- moved included .h files into
KDB5DIR = $(KRB5ROOT)
KRB5SRVTABDIR = /etc
+##DOSBUILDTOP = ..\..
+##DOS!include $(BUILDTOP)\config\windows.in
+
KRB5_HEADERS = asn1.h base-defs.h ccache.h crc-32.h encryption.h \
error_def.h errors.h ext-proto.h fieldbits.h \
free.h func-proto.h hostaddr.h kdb.h kdb_dbm.h \
ET_HEADERS = adm_err.h asn1_err.h kdb5_err.h krb5_err.h
BUILT_HEADERS = autoconf.h config.h osconf.h
-all:: $(BUILT_HEADERS)
+all:: all-$(WHAT)
+
+all-unix:: $(BUILT_HEADERS)
+all-windows:
+ copy stock\config.win config.h
+ echo /* not used in windows */ > osconf.h
+ echo /* not used in windows */ > autoconf.h
+ copy $(BUILDTOP)\lib\krb5\asn.1\krb5_decode.h .\asn.1\krb5_decode.h
+ copy $(BUILDTOP)\lib\krb5\asn.1\krb5_encode.h .\asn.1\krb5_encode.h
+
includes:: autoconf.h
# Run a header through a preprocessor to generate an architecture/environment
PROCESS_REPLACE = -e "s+@KRB5ROOT+$(KRB5ROOT)+" \
-e "s+@KDB5DIR+$(KDB5DIR)+" \
- -e "s+@KRB5SRVTABDIR+${KRB5SRVTABDIR}+"
+ -e "s+@KRB5SRVTABDIR+$(KRB5SRVTABDIR)+"
OSCONFSRC = $(srcdir)/stock/osconf.h
@if cmp -s config.new config.h ; then :; \
else (set -x; $(RM) config.h ; $(CP) config.new config.h) fi
-clean::
- $(RM) config.new osconf.new $(ET_HEADERS) $(BUILT_HEADERS)
+clean:: clean-$(WHAT)
+ $(RM) config.new osconf.new $(BUILT_HEADERS)
+
+clean-unix::
+ $(RM) $(ET_HEADERS)
+
+clean-windows::
dnl
AC_HEADER_CHECK(string.h,AC_DEFINE(USE_STRING_H))
AC_HEADER_CHECK(stdlib.h,AC_DEFINE(HAS_STDLIB_H),AC_DEFINE(NO_STDLIB_H))
+AC_HEADER_CHECK(sys/file.h,AC_DEFINE(HAS_SYS_FILE_H))
+AC_HEADER_CHECK(sys/param.h,AC_DEFINE(HAS_SYS_PARAM_H))
CHECK_STDARG
AC_FUNC_CHECK([setvbuf],AC_DEFINE(HAS_SETVBUF))
} krb5_cs_table_entry;
/* could be used in a table to find a sumtype */
+typedef krb5_error_code (API *SUM_FUNC) NPROTOTYPE ((krb5_pointer /* in */,
+ size_t /* in_length */,
+ krb5_pointer /* key/seed */,
+ size_t /* key/seed size */,
+ krb5_checksum FAR * /* out_cksum */));
+
typedef struct _krb5_checksum_entry {
krb5_magic magic;
- krb5_error_code (*sum_func) NPROTOTYPE (( krb5_pointer /* in */,
- size_t /* in_length */,
- krb5_pointer /* key/seed */,
- size_t /* key/seed size */,
- krb5_checksum * /* out_cksum */));
+ SUM_FUNC sum_func;
int checksum_length; /* length of stuff returned by
sum_func */
unsigned int is_collision_proof:1;
#include <time.h>
#endif
#include <sys/stat.h> /* struct stat, stat() */
+#ifdef HAVE_SYS_PARAM_H
#include <sys/param.h> /* MAXPATHLEN */
+#endif
+#ifdef HAVE_SYS_FILE_H
#include <sys/file.h> /* prototypes for file-related
syscalls; flags for open &
friends */
+#endif
+
#ifndef FD_SET
#define FD_SETSIZE (sizeof (fd_set) * 8)