Added new KerberosHeaders files
authorKeith Vetter <keithv@fusion.com>
Thu, 28 Sep 1995 08:27:52 +0000 (08:27 +0000)
committerKeith Vetter <keithv@fusion.com>
Thu, 28 Sep 1995 08:27:52 +0000 (08:27 +0000)
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@6879 dc483132-0cff-0310-8789-dd5450dbe970

src/mac/libraries/KerberosHeaders.h [new file with mode: 0644]
src/mac/libraries/KerberosHeadersCFM.pch [new file with mode: 0644]

diff --git a/src/mac/libraries/KerberosHeaders.h b/src/mac/libraries/KerberosHeaders.h
new file mode 100644 (file)
index 0000000..dee0442
--- /dev/null
@@ -0,0 +1,101 @@
+/*
+ *     KerberosHeaders.pch
+ *
+ *     Script to generate the 'MacHeaders<xxx>' precompiled header for Metrowerks C/C++.
+ *  Copyright © 1993 metrowerks inc.  All rights reserved.
+ * Modified for Kerberos5 Mac port to include compile options
+ */
+
+/*
+ * Add the compile flag switches for kerberos compile
+ */
+#define KRB5 1
+
+#define _MACINTOSH
+#define SIZEOF_INT 4
+#define SIZEOF_SHORT 2
+#define ENOMEM -1
+#define HAVE_SRAND
+#define NO_PASSWORD
+#define HAS_LABS
+#define ANSI_STDIO
+#ifndef _SIZET
+typedef unsigned int size_t;
+#define _SIZET
+
+#include <unix.h>
+#include <ctype.h>
+
+#endif
+
+#define PROVIDE_RSA_MD4
+#define PROVIDE_RSA_MD5
+#define PROVIDE_SNEFRU
+#define PROVIDE_DES_CBC_CKSUM
+#define PROVIDE_DES_CBC_CRC
+#define PROVIDE_DES_CBC_MD5
+#define PROVIDE_RAW_DES_CBC
+
+#define NO_SYS_TYPES_H
+#define NO_SYS_STAT_H
+
+/*
+ * Rename various socket type operations to avoid cluttering the namespace
+ */
+#define socket                 krb5_socket
+#define closesocket            krb5_closesocket
+#define connect                        krb5_connect
+#define bind                   krb5_bind
+#define send                   krb5_send
+#define recv                   krb5_recv
+#define sendto                 krb5_sendto
+#define select                 krb5_select
+#define recvfrom               krb5_recvfrom
+#define inet_ntoa              krb5_inet_ntoa
+#define gethostbyname  krb5_gethostbyname
+#define gethostbyaddr  krb5_gethostbyaddr
+#define gethostname            krb5_gethostname
+#define getsockname            krb5_getsockname
+#define getmyipaddr            krb5_getmyipaddr
+
+#define OpenOurRF              krb5_OpenOurRF
+#define OpenResolver   krb5_OpenResolver
+#define CloseResolver  krb5_CloseResolver
+#define StrToAddr              krb5_StrToAddr
+#define AddrToStr              krb5_AddrToStr
+#define EnumCache              krb5_EnumCache
+#define AddrToName             krb5_AddrToName
+#define dnr                            krb5_dnr
+#define codeHndl               krb5_codeHndl
+
+typedef int datum;
+
+//jfm need to reimplement
+#define mktemp(a)
+
+enum {
+ENOENT = -43,
+EPERM,
+EACCES,
+EISDIR,
+ENOTDIR,
+ELOOP,
+ETXTBSY,
+EBUSY,
+EROFS,
+EINVAL,
+EEXIST,
+EFAULT,
+EBADF,
+ENAMETOOLONG,
+EWOULDBLOCK,
+EDQUOT,
+ENOSPC,
+EIO,
+ENFILE,
+EMFILE,
+ENXIO
+};
+#define HAVE_STRFTIME 1
+#define MAXPATHLEN 255
+#define HAVE_SYSLOG_H 1
diff --git a/src/mac/libraries/KerberosHeadersCFM.pch b/src/mac/libraries/KerberosHeadersCFM.pch
new file mode 100644 (file)
index 0000000..4715b51
--- /dev/null
@@ -0,0 +1,24 @@
+/*
+ *     KerberosHeadersCFM.pch - Name the output file
+ */
+
+#ifdef __cplusplus
+
+       #ifdef powerc
+               #pragma precompile_target "KerberosHeadersCFMPPC++"
+       #else
+               #pragma precompile_target "KerberosHeadersCFM68K++"
+       #endif
+
+#else
+
+       #ifdef powerc
+               #pragma precompile_target "KerberosHeadersCFMPPC"
+       #else
+               #pragma precompile_target "KerberosHeadersCFM68K"
+       #endif
+
+#endif
+
+#include "KerberosHeaders.h"
+#include "MacHeaders.c"