summaryrefslogtreecommitdiffstats
path: root/src/krb524/krb524.h
diff options
context:
space:
mode:
authorTom Yu <tlyu@mit.edu>2002-06-15 00:37:58 +0000
committerTom Yu <tlyu@mit.edu>2002-06-15 00:37:58 +0000
commit7a8bb97527b57514a600dc8a091e2846dad9c4cd (patch)
treed5517b73138c732df63d734efafa490d4e6c3728 /src/krb524/krb524.h
parentf90cf39eb4efae7e8a8307012d9f3d853d651f40 (diff)
downloadkrb5-7a8bb97527b57514a600dc8a091e2846dad9c4cd.tar.gz
krb5-7a8bb97527b57514a600dc8a091e2846dad9c4cd.tar.xz
krb5-7a8bb97527b57514a600dc8a091e2846dad9c4cd.zip
* krb524.h: Updated C++ protection to not interfere with emacs
auto indentation and added KRB524_PRIVATE macro for Mac OS X to control visibility of function prototypes * krb524.h: Added C++ protection and Mac pragmas * krb524.h, cnv_tkt_skey.c, conv_creds.c, conv_princ.c, encode.c, misc.c, sendmsg.c: Updated header paths on Mac OS X so that we correctly include the autogenerated krb524.h * conv_creds.c, cnv_tkt_skey.c: added cast to remove warning. * krb524.h: Updated to new Mac OS header layout. * sendmsg.c: k5-int.h should be included as a local header [pullups from 1-2-2-branch] git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@14507 dc483132-0cff-0310-8789-dd5450dbe970
Diffstat (limited to 'src/krb524/krb524.h')
-rw-r--r--src/krb524/krb524.h48
1 files changed, 46 insertions, 2 deletions
diff --git a/src/krb524/krb524.h b/src/krb524/krb524.h
index cf9d62e824..4c6a07eac7 100644
--- a/src/krb524/krb524.h
+++ b/src/krb524/krb524.h
@@ -26,8 +26,39 @@
#define KRB524_SERVICE "krb524"
#define KRB524_PORT 4444
-#include "krb524_err.h"
-
+#if defined(macintosh) || (defined(__MACH__) && defined(__APPLE__))
+ #include <TargetConditionals.h>
+ #include <Kerberos/krb5.h>
+ #include <Kerberos/krb.h>
+ #ifndef KRB524_PRIVATE /* Allow e.g. build system to override */
+ #define KRB524_PRIVATE 0
+ #endif
+#else
+ #include "krb524_err.h"
+ #ifndef KRB524_PRIVATE
+ #define KRB524_PRIVATE 1
+ #endif
+#endif
+
+#if defined(__cplusplus) && !defined(KRB524INT_BEGIN_DECLS)
+#define KRB524INT_BEGIN_DECLS extern "C" {
+#define KRB524INT_END_DECLS }
+#else
+#define KRB524INT_BEGIN_DECLS
+#define KRB524INT_END_DECLS
+#endif
+
+#if TARGET_OS_MAC
+ #if defined(__MWERKS__)
+ #pragma import on
+ #pragma enumsalwaysint on
+ #endif
+ #pragma options align=mac68k
+#endif
+
+KRB524INT_BEGIN_DECLS
+
+#if KRB524_PRIVATE
extern int krb524_debug;
int krb524_convert_tkt_skey
@@ -47,11 +78,13 @@ int krb524_convert_princs
int krb524_convert_creds_addr
(krb5_context context, krb5_creds *v5creds,
CREDENTIALS *v4creds, struct sockaddr *saddr);
+#endif /* KRB524_PRIVATE */
int krb524_convert_creds_kdc
(krb5_context context, krb5_creds *v5creds,
CREDENTIALS *v4creds);
+#if KRB524_PRIVATE
/* conv_tkt.c */
int krb524_convert_tkt
@@ -77,5 +110,16 @@ void krb524_init_ets
int krb524_sendto_kdc
(krb5_context context, const krb5_data * message,
const krb5_data * realm, krb5_data * reply);
+#endif /* KRB524_PRIVATE */
+
+#if TARGET_OS_MAC
+ #if defined(__MWERKS__)
+ #pragma enumsalwaysint reset
+ #pragma import reset
+ #endif
+ #pragma options align=reset
+#endif
+
+KRB524INT_END_DECLS
#endif /* __KRB524_H__ */