From 88eb1e569e670b76e0994af75996e5299395b4b4 Mon Sep 17 00:00:00 2001 From: Ken Raeburn Date: Tue, 22 Jun 2004 18:14:15 +0000 Subject: [PATCH] Delete preprocessor tests for macintosh, __MWERKS__, applec, and THINK_C, all part of the pre-Mac OS X support. (Except the bits in the Yarrow code, where it was part of the upstream source.) git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16506 dc483132-0cff-0310-8789-dd5450dbe970 --- src/include/ChangeLog | 4 +++ src/include/k5-int.h | 22 ---------------- src/include/kerberosIV/ChangeLog | 4 +++ src/include/kerberosIV/des.h | 16 +----------- src/include/kerberosIV/krb.h | 9 +------ src/include/krb5.hin | 11 +------- src/include/krb5/ChangeLog | 4 +++ src/include/krb5/adm_proto.h | 4 +-- src/include/krb5/kdb.h | 4 +-- src/include/krb5/kdb_dbc.h | 3 --- src/include/krb5/kdb_kt.h | 3 --- src/lib/gssapi/generic/ChangeLog | 4 +++ src/lib/gssapi/generic/gssapi.hin | 8 +----- src/lib/gssapi/mechglue/ChangeLog | 5 ++++ src/lib/gssapi/mechglue/g_initialize.c | 7 ------ src/lib/gssapi/mechglue/mechglue.h | 4 --- src/lib/gssapi/mechglue/oid_ops.c | 4 --- src/lib/krb4/ChangeLog | 5 ++++ src/lib/krb4/g_pw_in_tkt.c | 2 +- src/lib/krb4/kadm_net.c | 2 +- src/lib/krb5/ccache/ChangeLog | 4 +++ src/lib/krb5/ccache/cc_file.c | 35 -------------------------- src/lib/krb5/ccache/ccapi/ChangeLog | 4 +++ src/lib/krb5/ccache/ccapi/stdcc_util.c | 23 ----------------- src/lib/krb5/keytab/ChangeLog | 5 ++++ src/lib/krb5/keytab/kt_file.c | 4 +-- src/lib/krb5/krb/ChangeLog | 4 +++ src/lib/krb5/krb/parse.c | 2 +- src/lib/krb5/os/ChangeLog | 9 +++++++ src/lib/krb5/os/an_to_ln.c | 2 +- src/lib/krb5/os/krbfileio.c | 2 +- src/lib/krb5/os/kuserok.c | 6 ++--- src/lib/krb5/os/prompter.c | 2 +- src/lib/krb5/os/promptusr.c | 4 +-- src/lib/krb5/os/read_pwd.c | 2 +- src/lib/krb5/posix/ChangeLog | 5 ++++ src/lib/krb5/posix/getuid.c | 2 -- src/lib/krb5/posix/syslog.c | 2 +- src/lib/krb5/rcache/ChangeLog | 5 ++++ src/lib/krb5/rcache/rc_io.c | 6 ----- src/util/et/ChangeLog | 4 +++ src/util/et/vfprintf.c | 2 -- src/util/profile/ChangeLog | 5 ++++ src/util/profile/prof_int.h | 2 +- src/util/profile/prof_parse.c | 4 --- src/util/profile/profile.hin | 14 +---------- 46 files changed, 96 insertions(+), 188 deletions(-) diff --git a/src/include/ChangeLog b/src/include/ChangeLog index 4bb1de8e6..a0177adce 100644 --- a/src/include/ChangeLog +++ b/src/include/ChangeLog @@ -1,3 +1,7 @@ +2004-06-22 Ken Raeburn + + * k5-int.h: Don't test macintosh, __MWERKS__, applec, or THINK_C. + 2004-06-18 Ken Raeburn * k5-platform.h (MAKE_INIT_FUNCTION, CALL_INIT_FUNCTION, diff --git a/src/include/k5-int.h b/src/include/k5-int.h index 67fb028eb..fe7a5a113 100644 --- a/src/include/k5-int.h +++ b/src/include/k5-int.h @@ -100,24 +100,6 @@ #define ANSI_STDIO #endif -/* Note, this may shoot us in the foot if we switch to CW compilers for Mach-o builds */ -#if !defined(macintosh) && (defined(__MWERKS__) || defined(applec) || defined(THINK_C)) -#define macintosh -#endif - -#ifdef macintosh -#define SIZEOF_INT 4 -#define SIZEOF_SHORT 2 -#define HAVE_SRAND -#define NO_PASSWORD -/*#define ENOMEM -1*/ -#define ANSI_STDIO -#include -#include -#include -#include -#endif - #ifndef KRB5_AUTOCONF__ #define KRB5_AUTOCONF__ #include "autoconf.h" @@ -1675,10 +1657,6 @@ krb5int_make_srv_query_realm(const krb5_data *realm, struct srv_dns_entry **answers); void krb5int_free_srv_dns_data(struct srv_dns_entry *); -#if defined(macintosh) && defined(__CFM68K__) && !defined(__USING_STATIC_LIBS__) -#pragma import reset -#endif - /* * Convenience function for structure magic number */ diff --git a/src/include/kerberosIV/ChangeLog b/src/include/kerberosIV/ChangeLog index d05f70d38..19e0b012a 100644 --- a/src/include/kerberosIV/ChangeLog +++ b/src/include/kerberosIV/ChangeLog @@ -1,3 +1,7 @@ +2004-06-22 Ken Raeburn + + * des.h, krb.h: Don't test for macintosh or __MWERKS__. + 2004-03-08 Ken Raeburn * Makefile.in (MY_SUBDIRS): Deleted. diff --git a/src/include/kerberosIV/des.h b/src/include/kerberosIV/des.h index 8655e1d8f..3814aa88c 100644 --- a/src/include/kerberosIV/des.h +++ b/src/include/kerberosIV/des.h @@ -26,7 +26,7 @@ * Include file for the Data Encryption Standard library. */ -#if defined(macintosh) || (defined(__MACH__) && defined(__APPLE__)) +#if defined(__MACH__) && defined(__APPLE__) # include # if TARGET_RT_MAC_CFM # error "Use KfM 4.0 SDK headers for CFM compilation." @@ -51,9 +51,6 @@ KRBINT_BEGIN_DECLS #if TARGET_OS_MAC -# if defined(__MWERKS__) -# pragma import on -# endif # pragma options align=mac68k #endif @@ -87,10 +84,6 @@ typedef unsigned char des_cblock[8]; /* crypto-block size */ typedef struct des_ks_struct { DES_INT32 _[2]; } des_key_schedule[16]; #if TARGET_OS_MAC -# if defined(__MWERKS__) -# pragma enumsalwaysint reset -# pragma import reset -# endif # pragma options align=reset #endif @@ -120,10 +113,6 @@ KRBINT_END_DECLS KRBINT_BEGIN_DECLS #if TARGET_OS_MAC -# if defined(__MWERKS__) -# pragma import on -# pragma enumsalwaysint on -# endif # pragma options align=mac68k #endif @@ -197,9 +186,6 @@ int des_is_weak_key(des_cblock); void des_cblock_print_file(des_cblock *, FILE *fp); #if TARGET_OS_MAC -# if defined(__MWERKS__) -# pragma import reset -# endif # pragma options align=reset #endif diff --git a/src/include/kerberosIV/krb.h b/src/include/kerberosIV/krb.h index a79df13b6..6bc7149d7 100644 --- a/src/include/kerberosIV/krb.h +++ b/src/include/kerberosIV/krb.h @@ -34,7 +34,7 @@ * For MacOS, don't expose prototypes of various private functions. * Unfortuantely, they've leaked out everywhere else. */ -#if defined(macintosh) || (defined(__MACH__) && defined(__APPLE__)) +#if defined(__MACH__) && defined(__APPLE__) # include # if TARGET_RT_MAC_CFM # error "Use KfM 4.0 SDK headers for CFM compilation." @@ -73,10 +73,6 @@ KRBINT_BEGIN_DECLS #if TARGET_OS_MAC -# if defined(__MWERKS__) -# pragma import on -# pragma enumsalwaysint on -# endif # pragma options align=mac68k #endif @@ -783,9 +779,6 @@ long win_time_get_epoch(void); #endif #if TARGET_OS_MAC -# if defined(__MWERKS__) -# pragma import reset -# endif # pragma options align=reset #endif diff --git a/src/include/krb5.hin b/src/include/krb5.hin index 518b5dd81..08f942b07 100644 --- a/src/include/krb5.hin +++ b/src/include/krb5.hin @@ -65,7 +65,7 @@ #define KRB5_PRIVATE 0 #endif -#if defined(macintosh) || (defined(__MACH__) && defined(__APPLE__)) +#if defined(__MACH__) && defined(__APPLE__) # include # if TARGET_RT_MAC_CFM # error "Use KfM 4.0 SDK headers for CFM compilation." @@ -109,9 +109,6 @@ KRB5INT_BEGIN_DECLS #if TARGET_OS_MAC -# if defined(__MWERKS__) -# pragma import on -# endif # pragma options align=mac68k #endif @@ -1831,7 +1828,6 @@ krb5_set_password_using_ccache int *result_code, krb5_data *result_code_string, krb5_data *result_string); #if KRB5_PRIVATE -#ifndef macintosh krb5_error_code krb5_set_config_files (krb5_context, const char **); @@ -1840,8 +1836,6 @@ krb5_error_code KRB5_CALLCONV krb5_get_default_config_files void KRB5_CALLCONV krb5_free_config_files (char **filenames); - -#endif #endif krb5_error_code KRB5_CALLCONV @@ -2530,9 +2524,6 @@ krb5_prompt_type* KRB5_CALLCONV krb5_get_prompt_types (krb5_context context); #if TARGET_OS_MAC -# if defined(__MWERKS__) -# pragma import reset -# endif # pragma options align=reset #endif diff --git a/src/include/krb5/ChangeLog b/src/include/krb5/ChangeLog index 1ec827ea9..bcef580f5 100644 --- a/src/include/krb5/ChangeLog +++ b/src/include/krb5/ChangeLog @@ -1,3 +1,7 @@ +2004-06-22 Ken Raeburn + + * adm_proto.h, kdb.h, kdb_dbc.h, kdb_kt.h: Don't test macintosh. + 2004-06-16 Ken Raeburn * Makefile.in (all-mac, clean-mac): Targets deleted. diff --git a/src/include/krb5/adm_proto.h b/src/include/krb5/adm_proto.h index 17015ec64..76e5effaf 100644 --- a/src/include/krb5/adm_proto.h +++ b/src/include/krb5/adm_proto.h @@ -70,7 +70,7 @@ void KRB5_CALLCONV krb5_adm_disconnect krb5_auth_context, krb5_ccache); -#if !defined(_WIN32) && !defined(macintosh) +#if !defined(_WIN32) /* adm_kw_dec.c */ krb5_error_code krb5_adm_proto_to_dbent (krb5_context, @@ -88,7 +88,7 @@ krb5_error_code krb5_adm_dbent_to_proto char *, krb5_int32 *, krb5_data **); -#endif /* !(windows or macintosh) */ +#endif /* !windows */ /* adm_kt_dec.c */ krb5_error_code krb5_adm_proto_to_ktent diff --git a/src/include/krb5/kdb.h b/src/include/krb5/kdb.h index 73a3972aa..fbe2d21ba 100644 --- a/src/include/krb5/kdb.h +++ b/src/include/krb5/kdb.h @@ -84,7 +84,7 @@ #define KRB5_KDB_CREATE_BTREE 0x00000001 #define KRB5_KDB_CREATE_HASH 0x00000002 -#if !defined(macintosh) && !defined(_WIN32) +#if !defined(_WIN32) /* * Note --- these structures cannot be modified without changing the @@ -330,5 +330,5 @@ krb5_error_code krb5_ser_db_context_init (krb5_context); #define KRB5_KDB_DEF_FLAGS 0 -#endif /* !defined(macintosh) &&!defined(_WIN32) */ +#endif /* !defined(_WIN32) */ #endif /* KRB5_KDB5__ */ diff --git a/src/include/krb5/kdb_dbc.h b/src/include/krb5/kdb_dbc.h index 676940dfe..e2b300288 100644 --- a/src/include/krb5/kdb_dbc.h +++ b/src/include/krb5/kdb_dbc.h @@ -57,8 +57,6 @@ #ifndef KRB5_KDB5_DBC__ #define KRB5_KDB5_DBC__ -#if !defined(macintosh) - #include "kdb.h" /* Per-database context. */ @@ -85,5 +83,4 @@ krb5_error_code krb5_dbm_db_set_mkey krb5_error_code krb5_dbm_db_get_mkey (krb5_context,krb5_db_context *,krb5_encrypt_block **); -#endif /* !defined(macintosh) */ #endif /* KRB5_KDB5_DBM__ */ diff --git a/src/include/krb5/kdb_kt.h b/src/include/krb5/kdb_kt.h index 1c06a5bb9..1dbd7f30d 100644 --- a/src/include/krb5/kdb_kt.h +++ b/src/include/krb5/kdb_kt.h @@ -31,8 +31,6 @@ #ifndef KRB5_KDB5_KT_H #define KRB5_KDB5_KT_H -#if !defined(macintosh) - #include "kdb.h" extern struct _krb5_kt_ops krb5_kt_kdb_ops; @@ -41,5 +39,4 @@ krb5_error_code krb5_ktkdb_resolve (krb5_context, const char *, krb5_keytab *); krb5_error_code krb5_ktkdb_set_context(krb5_context); -#endif /* !defined(macintosh) */ #endif /* KRB5_KDB5_DBM__ */ diff --git a/src/lib/gssapi/generic/ChangeLog b/src/lib/gssapi/generic/ChangeLog index caa4a7c5c..7643a97a1 100644 --- a/src/lib/gssapi/generic/ChangeLog +++ b/src/lib/gssapi/generic/ChangeLog @@ -1,3 +1,7 @@ +2004-06-22 Ken Raeburn + + * gssapi.hin: Don't test macintosh or __MWERKS__. + 2004-06-16 Ken Raeburn * util_validate.c (g_save): Call gssint_initialize_library. diff --git a/src/lib/gssapi/generic/gssapi.hin b/src/lib/gssapi/generic/gssapi.hin index 35519ed48..1c1444415 100644 --- a/src/lib/gssapi/generic/gssapi.hin +++ b/src/lib/gssapi/generic/gssapi.hin @@ -27,7 +27,7 @@ * Determine platform-dependent configuration. */ -#if defined(macintosh) || (defined(__MACH__) && defined(__APPLE__)) +#if defined(__MACH__) && defined(__APPLE__) # include # if TARGET_RT_MAC_CFM # error "Use KfM 4.0 SDK headers for CFM compilation." @@ -39,9 +39,6 @@ extern "C" { #endif /* __cplusplus */ #if TARGET_OS_MAC -# if defined(__MWERKS__) -# pragma import on -# endif # pragma options align=mac68k #endif @@ -780,9 +777,6 @@ OM_uint32 KRB5_CALLCONV gss_canonicalize_name ); #if TARGET_OS_MAC -# if defined(__MWERKS__) -# pragma import reset -# endif # pragma options align=reset #endif diff --git a/src/lib/gssapi/mechglue/ChangeLog b/src/lib/gssapi/mechglue/ChangeLog index 0b342f9d7..e742e5ac3 100644 --- a/src/lib/gssapi/mechglue/ChangeLog +++ b/src/lib/gssapi/mechglue/ChangeLog @@ -1,3 +1,8 @@ +2004-06-22 Ken Raeburn + + * g_initialize.c, oid_ops.c: Don't test macintosh. + * mechglue.h: Don't test __MWERKS__, applec, THINK_C. + 2004-06-16 Ken Raeburn * Makefile.in (all-mac, clean-mac): Targets deleted. diff --git a/src/lib/gssapi/mechglue/g_initialize.c b/src/lib/gssapi/mechglue/g_initialize.c index 563450fc9..09e14deed 100644 --- a/src/lib/gssapi/mechglue/g_initialize.c +++ b/src/lib/gssapi/mechglue/g_initialize.c @@ -157,17 +157,10 @@ void gss_initialize () #endif /* USE_SOLARIS_SHARED_LIBRARIES */ -#if !defined(macintosh) if (__gss_mechs_array == NULL) { /* this is very bad! */ fprintf(stderr,"gss_initialize fatal error: no mechanisms loaded!\n"); exit(-1); } -#else - /* - * Nothing for now, since this should never happen using static - * mechanism loading. - */ -#endif return; } diff --git a/src/lib/gssapi/mechglue/mechglue.h b/src/lib/gssapi/mechglue/mechglue.h index af57d25b7..691b30a96 100644 --- a/src/lib/gssapi/mechglue/mechglue.h +++ b/src/lib/gssapi/mechglue/mechglue.h @@ -29,11 +29,7 @@ #ifndef _GSS_MECHGLUE_H #define _GSS_MECHGLUE_H -#if defined(__MWERKS__) || defined(applec) || defined(THINK_C) -#include -#else #include -#endif /********************************************************/ /* GSSAPI Extension functions -- these functions aren't */ diff --git a/src/lib/gssapi/mechglue/oid_ops.c b/src/lib/gssapi/mechglue/oid_ops.c index f45e467a4..8e9da8852 100644 --- a/src/lib/gssapi/mechglue/oid_ops.c +++ b/src/lib/gssapi/mechglue/oid_ops.c @@ -36,11 +36,7 @@ #include #include #include -#ifndef macintosh #include -#else -#include -#endif #include #include diff --git a/src/lib/krb4/ChangeLog b/src/lib/krb4/ChangeLog index 62527afb3..20c548c39 100644 --- a/src/lib/krb4/ChangeLog +++ b/src/lib/krb4/ChangeLog @@ -1,3 +1,8 @@ +2004-06-22 Ken Raeburn + + * g_pw_in_tkt.c (passwd_to_key): Don't test macintosh. + * kadm_net.c (SIGNAL): Don't test macintosh. + 2004-06-16 Ken Raeburn * Makefile.in (check-mac): Target deleted. diff --git a/src/lib/krb4/g_pw_in_tkt.c b/src/lib/krb4/g_pw_in_tkt.c index d68781857..db2bb8730 100644 --- a/src/lib/krb4/g_pw_in_tkt.c +++ b/src/lib/krb4/g_pw_in_tkt.c @@ -69,7 +69,7 @@ passwd_to_key(user,instance,realm,passwd,key) char *user, *instance, *realm, *passwd; C_Block key; { -#if defined(_WIN32) || defined(macintosh) +#if defined(_WIN32) string_to_key(passwd, key); #else /* unix */ #ifdef NOENCRYPTION diff --git a/src/lib/krb4/kadm_net.c b/src/lib/krb4/kadm_net.c index 189f04f1e..4173af2b0 100644 --- a/src/lib/krb4/kadm_net.c +++ b/src/lib/krb4/kadm_net.c @@ -45,7 +45,7 @@ #include "prot.h" /* XXX FIXME! */ -#if defined(_WIN32) || defined(macintosh) +#if defined(_WIN32) #define SIGNAL(s, f) 0 #else #define SIGNAL(s, f) signal(s, f) diff --git a/src/lib/krb5/ccache/ChangeLog b/src/lib/krb5/ccache/ChangeLog index 4feb072d9..d07588021 100644 --- a/src/lib/krb5/ccache/ChangeLog +++ b/src/lib/krb5/ccache/ChangeLog @@ -1,3 +1,7 @@ +2004-06-22 Ken Raeburn + + * cc_file.c (my_fopen): Don't test macintosh. + 2004-06-21 Jeffrey Altman * cc_mslsa.c: Comment out call to FormatMessage() which fails diff --git a/src/lib/krb5/ccache/cc_file.c b/src/lib/krb5/ccache/cc_file.c index 365e1a6fb..fcc0557d5 100644 --- a/src/lib/krb5/ccache/cc_file.c +++ b/src/lib/krb5/ccache/cc_file.c @@ -1089,42 +1089,7 @@ krb5_fcc_store_authdatum (krb5_context context, krb5_ccache id, krb5_authdata *a #ifdef USE_STDIO static FILE *my_fopen(char *path, char *mode) { -#ifdef macintosh -/* - * Kludge for the Macintosh, since fopen doesn't set errno, but open - * does... - */ - int fd, open_flags; - FILE *f; - - f = fopen(path, mode); - if (f) - return f; - /* - * OK, fopen failed; let's try to figure out why.... - */ - if (strchr(mode, '+')) - open_flags = O_RDWR; - else if (strchr(mode, 'w') || strchr(mode, 'a')) - open_flags = O_WRONLY; - else - open_flags = O_RDONLY; - if (strchr(mode, 'a')) - open_flags |= O_APPEND; - - fd = open(path, open_flags); - if (fd == -1) - return NULL; - /* - * fopen failed, but open succeeded? W*E*I*R*D..... - */ - close(fd); - errno = KRB5_CC_IO; - - return NULL; -#else return fopen(path, mode); -#endif } #endif diff --git a/src/lib/krb5/ccache/ccapi/ChangeLog b/src/lib/krb5/ccache/ccapi/ChangeLog index 91cf57919..e7d80c22a 100644 --- a/src/lib/krb5/ccache/ccapi/ChangeLog +++ b/src/lib/krb5/ccache/ccapi/ChangeLog @@ -1,3 +1,7 @@ +2004-06-22 Ken Raeburn + + * stdcc_util.c (dupK5toCC): Don't test macintosh. + 2003-07-17 Ken Raeburn * Makefile.in (LIBNAME) [##WIN16##]: Don't define. diff --git a/src/lib/krb5/ccache/ccapi/stdcc_util.c b/src/lib/krb5/ccache/ccapi/stdcc_util.c index 3f9c05271..7f9358dca 100644 --- a/src/lib/krb5/ccache/ccapi/stdcc_util.c +++ b/src/lib/krb5/ccache/ccapi/stdcc_util.c @@ -256,9 +256,6 @@ void dupK5toCC(krb5_context context, krb5_creds *creds, cred_union **cu) cc_creds *c; int err; krb5_int32 offset_seconds = 0, offset_microseconds = 0; -#ifdef macintosh - char *tempname = NULL; -#endif if (cu == NULL) return; @@ -275,28 +272,8 @@ void dupK5toCC(krb5_context context, krb5_creds *creds, cred_union **cu) (*cu)->cred.pV5Cred = c; /* convert krb5 principals to flat principals */ -#ifdef macintosh - /* - * and make sure the memory for c->client and c->server is on - * the system heap with NewPtr for the Mac (krb5_unparse_name - * puts it in appl heap with malloc) - */ - err = krb5_unparse_name(context, creds->client, &tempname); - c->client = malloc(strlen(tempname)+1); - if (c->client != NULL) - strcpy(c->client,tempname); - free(tempname); - tempname = NULL; - - err = krb5_unparse_name(context, creds->server, &tempname); - c->server = malloc(strlen(tempname)+1); - if (c->server != NULL) - strcpy(c->server,tempname); - free(tempname); -#else err = krb5_unparse_name(context, creds->client, &(c->client)); err = krb5_unparse_name(context, creds->server, &(c->server)); -#endif if (err) return; /* copy more fields */ diff --git a/src/lib/krb5/keytab/ChangeLog b/src/lib/krb5/keytab/ChangeLog index eb1cb218d..75363971b 100644 --- a/src/lib/krb5/keytab/ChangeLog +++ b/src/lib/krb5/keytab/ChangeLog @@ -1,3 +1,8 @@ +2004-06-22 Ken Raeburn + + * kt_file.c (krb5_ktf_keytab_externalize, + krb5_ktf_keytab_internalize): Don't test macintosh. + 2004-06-15 Ken Raeburn * kt_file.c (krb5_kt_default_vno): Replaced variable with macro. diff --git a/src/lib/krb5/keytab/kt_file.c b/src/lib/krb5/keytab/kt_file.c index 377838e26..c6f94f2e7 100644 --- a/src/lib/krb5/keytab/kt_file.c +++ b/src/lib/krb5/keytab/kt_file.c @@ -575,7 +575,7 @@ krb5_ktf_keytab_externalize(krb5_context kcontext, krb5_pointer arg, krb5_octet int fflags = 0; file_is_open = 1; -#if !defined( macintosh) && !defined(_WIN32) +#if !defined(_WIN32) fflags = fcntl(fileno(ktdata->openf), F_GETFL, 0); if (fflags > 0) file_is_open |= ((fflags & O_ACCMODE) << 1); @@ -690,7 +690,7 @@ krb5_ktf_keytab_internalize(krb5_context kcontext, krb5_pointer *argp, krb5_octe int fmode; long fpos; -#if !defined( macintosh) && !defined(_WIN32) +#if !defined(_WIN32) fmode = (file_is_open >> 1) & O_ACCMODE; #else fmode = 0; diff --git a/src/lib/krb5/krb/ChangeLog b/src/lib/krb5/krb/ChangeLog index 48f98472d..acad5724c 100644 --- a/src/lib/krb5/krb/ChangeLog +++ b/src/lib/krb5/krb/ChangeLog @@ -1,3 +1,7 @@ +2004-06-22 Ken Raeburn + + * parse.c (krb5_parse_name): Don't test macintosh. + 2004-06-04 Ken Raeburn * str_conv.c (krb5_string_to_timestamp): Use localtime_r if diff --git a/src/lib/krb5/krb/parse.c b/src/lib/krb5/krb/parse.c index 6cf89058b..50f7b225b 100644 --- a/src/lib/krb5/krb/parse.c +++ b/src/lib/krb5/krb/parse.c @@ -188,7 +188,7 @@ krb5_parse_name(krb5_context context, const char *name, krb5_principal *nprincip if (krb5_princ_size(context, principal) > i) krb5_princ_component(context, principal, i)->length = size; if (i + 1 != components) { -#if !defined(_WIN32) && !defined(macintosh) +#if !defined(_WIN32) fprintf(stderr, "Programming error in krb5_parse_name!"); #endif diff --git a/src/lib/krb5/os/ChangeLog b/src/lib/krb5/os/ChangeLog index 606b1a44f..69ca9dcde 100644 --- a/src/lib/krb5/os/ChangeLog +++ b/src/lib/krb5/os/ChangeLog @@ -1,3 +1,12 @@ +2004-06-22 Ken Raeburn + + * an_to_ln.c (db_an_to_ln): Don't test macintosh. + * krbfileio.c (krb5_sync_disk_file): Likewise. + * kuserok.c: Likewise. + * prompter.c: Likewise. + * promptusr.c: Likewise. + * read_pwd.c: Likewise. + 2004-06-15 Ken Raeburn * c_ustime.c: Include k5-thread.h. diff --git a/src/lib/krb5/os/an_to_ln.c b/src/lib/krb5/os/an_to_ln.c index 2430b27e2..ec847dbe5 100644 --- a/src/lib/krb5/os/an_to_ln.c +++ b/src/lib/krb5/os/an_to_ln.c @@ -100,7 +100,7 @@ db_an_to_ln(context, dbname, aname, lnsize, lname) const unsigned int lnsize; char *lname; { -#if (!defined(_WIN32) && !defined(macintosh)) +#if !defined(_WIN32) DBM *db; krb5_error_code retval; datum key, contents; diff --git a/src/lib/krb5/os/krbfileio.c b/src/lib/krb5/os/krbfileio.c index 57b659e54..ff19a5355 100644 --- a/src/lib/krb5/os/krbfileio.c +++ b/src/lib/krb5/os/krbfileio.c @@ -93,7 +93,7 @@ krb5_error_code krb5_sync_disk_file(krb5_context context, FILE *fp) { fflush(fp); -#if !defined(MSDOS_FILESYSTEM) && !defined(macintosh) +#if !defined(MSDOS_FILESYSTEM) if (fsync(fileno(fp))) { return errno; } diff --git a/src/lib/krb5/os/kuserok.c b/src/lib/krb5/os/kuserok.c index b87b528d1..c0111b995 100644 --- a/src/lib/krb5/os/kuserok.c +++ b/src/lib/krb5/os/kuserok.c @@ -28,7 +28,7 @@ */ #include "k5-int.h" -#if !defined(_WIN32) && !defined(macintosh) /* Not yet for Windows */ +#if !defined(_WIN32) /* Not yet for Windows */ #include #include @@ -151,7 +151,7 @@ krb5_kuserok(krb5_context context, krb5_principal principal, const char *luser) return(isok); } -#else /* _WIN32 || macintosh */ +#else /* _WIN32 */ /* * If the given Kerberos name "server" translates to the same name as "luser" @@ -173,4 +173,4 @@ krb5_kuserok(context, principal, luser) return FALSE; } -#endif /* _WIN32 || macintosh */ +#endif /* _WIN32 */ diff --git a/src/lib/krb5/os/prompter.c b/src/lib/krb5/os/prompter.c index 9b39e55d7..739c8c747 100644 --- a/src/lib/krb5/os/prompter.c +++ b/src/lib/krb5/os/prompter.c @@ -1,5 +1,5 @@ #include "k5-int.h" -#if (!defined(_WIN32) || (defined(_WIN32) && defined(__CYGWIN32__))) && !defined(macintosh) +#if !defined(_WIN32) || (defined(_WIN32) && defined(__CYGWIN32__)) #include #include #include diff --git a/src/lib/krb5/os/promptusr.c b/src/lib/krb5/os/promptusr.c index b32cdff0d..68f8b14a0 100644 --- a/src/lib/krb5/os/promptusr.c +++ b/src/lib/krb5/os/promptusr.c @@ -3,7 +3,7 @@ */ #include "k5-int.h" -#if !defined(_WIN32) && !defined(macintosh) +#if !defined(_WIN32) #include #include @@ -157,4 +157,4 @@ main(int argc, char **argv) #endif -#endif /* !_MSODS || _!MACINTOSH */ +#endif /* !_MSODS */ diff --git a/src/lib/krb5/os/read_pwd.c b/src/lib/krb5/os/read_pwd.c index 1bb631c6a..0e3d53ef9 100644 --- a/src/lib/krb5/os/read_pwd.c +++ b/src/lib/krb5/os/read_pwd.c @@ -29,7 +29,7 @@ #include "k5-int.h" -#if !defined(_WIN32) && !defined(macintosh) +#if !defined(_WIN32) #define DEFINED_KRB5_READ_PASSWORD #include #include diff --git a/src/lib/krb5/posix/ChangeLog b/src/lib/krb5/posix/ChangeLog index 5d0c67750..452457b7b 100644 --- a/src/lib/krb5/posix/ChangeLog +++ b/src/lib/krb5/posix/ChangeLog @@ -1,3 +1,8 @@ +2004-06-22 Ken Raeburn + + * getuid.c: Don't test __MWERKS__. + * syslog.c: Don't test macintosh. + 2004-06-16 Ken Raeburn * Makefile.in (MACSRCS): Don't set. diff --git a/src/lib/krb5/posix/getuid.c b/src/lib/krb5/posix/getuid.c index a44aa743e..2923331ad 100644 --- a/src/lib/krb5/posix/getuid.c +++ b/src/lib/krb5/posix/getuid.c @@ -1,8 +1,6 @@ /* Very simple getuid() for systems that don't have one. */ -#ifndef __MWERKS__ int getuid() { return 42; } -#endif diff --git a/src/lib/krb5/posix/syslog.c b/src/lib/krb5/posix/syslog.c index 3a02e8425..97abe4221 100644 --- a/src/lib/krb5/posix/syslog.c +++ b/src/lib/krb5/posix/syslog.c @@ -33,7 +33,7 @@ * Modified to use UNIX domain IPC by Ralph Campbell */ -#if !defined(_WIN32) && !defined(macintosh) +#if !defined(_WIN32) #if defined(__STDC__) || defined(_WIN32) #include diff --git a/src/lib/krb5/rcache/ChangeLog b/src/lib/krb5/rcache/ChangeLog index 185874199..946c5fac2 100644 --- a/src/lib/krb5/rcache/ChangeLog +++ b/src/lib/krb5/rcache/ChangeLog @@ -1,3 +1,8 @@ +2004-06-22 Ken Raeburn + + * rc_io.c (krb5_rc_io_move, krb5_rc_io_sync): Don't test + macintosh. + 2004-06-15 Ken Raeburn * rc_io.c (dir, dirlen): Top-level variables deleted. diff --git a/src/lib/krb5/rcache/rc_io.c b/src/lib/krb5/rcache/rc_io.c index e2e81dede..fdb1a040c 100644 --- a/src/lib/krb5/rcache/rc_io.c +++ b/src/lib/krb5/rcache/rc_io.c @@ -338,11 +338,7 @@ krb5_rc_io_move(krb5_context context, krb5_rc_iostuff *new1, new1->fn = NULL; /* avoid clobbering */ (void) krb5_rc_io_close(context, new1); new1->fn = fn; -#ifdef macintosh - new1->fd = fcntl(old->fd, F_DUPFD); -#else new1->fd = dup(old->fd); -#endif return 0; #endif } @@ -374,7 +370,6 @@ krb5_rc_io_sync(krb5_context context, krb5_rc_iostuff *d) #define fsync _commit #endif #endif -#ifndef macintosh if (fsync(d->fd) == -1) { switch(errno) { @@ -383,7 +378,6 @@ krb5_rc_io_sync(krb5_context context, krb5_rc_iostuff *d) default: return KRB5_RC_IO_UNKNOWN; } } -#endif return 0; } diff --git a/src/util/et/ChangeLog b/src/util/et/ChangeLog index 48fd9de64..65b8492c6 100644 --- a/src/util/et/ChangeLog +++ b/src/util/et/ChangeLog @@ -1,3 +1,7 @@ +2004-06-22 Ken Raeburn + + * vfprintf.c: Don't test macintosh. + 2004-06-18 Ken Raeburn * Makefile.in ($(OUTPRE)test_et.exe): New target. diff --git a/src/util/et/vfprintf.c b/src/util/et/vfprintf.c index af108256b..cad291602 100644 --- a/src/util/et/vfprintf.c +++ b/src/util/et/vfprintf.c @@ -18,7 +18,6 @@ /* based on @(#)vfprintf.c 5.2 (Berkeley) 6/27/88 */ #include -#if !defined(macintosh) #if defined(HAVE_STDARG_H) || defined(_WIN32) #include #else @@ -49,4 +48,3 @@ vfprintf(iop, fmt, ap) return (ferror(iop) ? EOF : len); } -#endif diff --git a/src/util/profile/ChangeLog b/src/util/profile/ChangeLog index 064a4ba87..a96db36d7 100644 --- a/src/util/profile/ChangeLog +++ b/src/util/profile/ChangeLog @@ -1,3 +1,8 @@ +2004-06-22 Ken Raeburn + + * prof_int.h, prof_parse.c, profile.hin: Don't test macintosh or + __MWERKS__. + 2004-06-18 Ken Raeburn * Makefile.in (SHLIB_EXPLIBS): Add $(LIBS). diff --git a/src/util/profile/prof_int.h b/src/util/profile/prof_int.h index c6ec667ac..2062b7053 100644 --- a/src/util/profile/prof_int.h +++ b/src/util/profile/prof_int.h @@ -5,7 +5,7 @@ #include #include -#if defined(macintosh) || (defined(__MACH__) && defined(__APPLE__)) +#if defined(__MACH__) && defined(__APPLE__) #include #define PROFILE_SUPPORTS_FOREIGN_NEWLINES #endif diff --git a/src/util/profile/prof_parse.c b/src/util/profile/prof_parse.c index f2cd691a4..87966f05e 100644 --- a/src/util/profile/prof_parse.c +++ b/src/util/profile/prof_parse.c @@ -347,10 +347,6 @@ static void output_quoted_string(char *str, FILE *f) #define EOL "\r\n" #endif -#ifdef macintosh -#define EOL "\r" -#endif - #ifndef EOL #define EOL "\n" #endif diff --git a/src/util/profile/profile.hin b/src/util/profile/profile.hin index b4105d6ff..e8515dd79 100644 --- a/src/util/profile/profile.hin +++ b/src/util/profile/profile.hin @@ -9,7 +9,7 @@ #include #endif -#if defined(macintosh) || (defined(__MACH__) && defined(__APPLE__)) +#if defined(__MACH__) && defined(__APPLE__) # include # if TARGET_RT_MAC_CFM # error "Use KfM 4.0 SDK headers for CFM compilation." @@ -34,12 +34,6 @@ typedef struct _profile_t *profile_t; extern "C" { #endif /* __cplusplus */ -#if TARGET_OS_MAC -# if defined(__MWERKS__) -# pragma import on -# endif -#endif - typedef char* profile_filespec_t; /* path as C string */ typedef char* profile_filespec_list_t; /* list of : separated paths, C string */ typedef const char * const_profile_filespec_t; /* path as C string */ @@ -113,12 +107,6 @@ long KRB5_CALLCONV profile_add_relation (profile_t profile, const char **names, const char *new_value); -#if TARGET_OS_MAC -# if defined(__MWERKS__) -# pragma import reset -# endif -#endif - #ifdef __cplusplus } #endif /* __cplusplus */ -- 2.26.2