1 2 #if !defined( RPC_NO_WINDOWS_H ) && !defined( MAC ) && !defined( _MAC ) 3 #ifndef _INC_WINDOWS 4 #include <windows.h> 5 #endif /* _INC_WINDOWS */ 6 #endif 7 8 #ifndef __RPC_H__ 9 #define __RPC_H__ 10 11 #if _MSC_VER > 1000 12 #pragma once 13 #endif 14 15 16 #ifdef __cplusplus 17 extern "C" { 18 #endif 19 20 #if defined( MAC ) || defined( _MAC ) || defined(__powerpc__) && !defined(__REACTOS__) 21 #define __RPC_MAC__ 22 #define __RPC_WIN32__ 23 #include <pshpack2.h> 24 25 #else 26 #if defined(_M_IA64) || defined(_M_AMD64) || defined(_WIN64) 27 #define __RPC_WIN64__ 28 #else 29 #define __RPC_WIN32__ 30 #endif 31 #endif 32 33 #include <basetsd.h> 34 35 #if defined(__RPC_WIN64__) 36 #include <pshpack8.h> 37 #endif 38 39 #ifndef __MIDL_USER_DEFINED 40 #define midl_user_allocate MIDL_user_allocate 41 #define midl_user_free MIDL_user_free 42 #define __MIDL_USER_DEFINED 43 #endif 44 45 46 typedef void * I_RPC_HANDLE; 47 #ifndef __ROS_LONG64__ 48 typedef long RPC_STATUS; 49 #else 50 typedef int RPC_STATUS; 51 #endif 52 #define __RPC_FAR 53 54 #if defined(__RPC_WIN32__) || defined(__RPC_WIN64__) 55 #define RPC_UNICODE_SUPPORTED 56 #endif 57 58 59 #if !defined(__RPC_MAC__) 60 #define __RPC_API __stdcall 61 #define __RPC_USER __stdcall 62 #define __RPC_STUB __stdcall 63 #define RPC_ENTRY __stdcall 64 #else 65 #define __RPC_API 66 #define __RPC_USER 67 #define __RPC_STUB 68 #define RPC_ENTRY 69 #endif 70 71 72 #ifndef __GNUC__ 73 #if !defined(DECLSPEC_IMPORT) 74 #define DECLSPEC_IMPORT 75 #endif 76 77 #if !defined(_RPCRT4_) 78 #define RPCRTAPI DECLSPEC_IMPORT 79 #else 80 #define RPCRTAPI 81 #endif 82 83 #if !defined(_RPCNS4_) 84 #define RPCNSAPI DECLSPEC_IMPORT 85 #else 86 #define RPCNSAPI 87 #endif 88 #else 89 #define RPCRTAPI 90 #define RPCNSAPI 91 #endif 92 93 #ifdef __RPC_MAC__ 94 #include <setjmp.h> 95 #define RPCXCWORD (sizeof(jmp_buf)/sizeof(int)) 96 97 #pragma warning(push) 98 #pragma warning( disable: 4005 ) 99 #include <rpcdce.h> 100 #include <rpcnsi.h> 101 #include <rpcerr.h> 102 #include <rpcmac.h> 103 #pragma warning(pop) 104 105 typedef void (RPC_ENTRY *MACYIELDCALLBACK)(short *) ; 106 RPC_STATUS RPC_ENTRY 107 RpcMacSetYieldInfo(MACYIELDCALLBACK pfnCallback) ; 108 109 #if !defined(UNALIGNED) 110 #define UNALIGNED 111 #endif 112 113 #include <poppack.h> 114 #else 115 #include <rpcdce.h> 116 /* #include <rpcnsi.h> */ 117 #include <rpcnterr.h> 118 #include <excpt.h> 119 #include <winerror.h> 120 121 #define RpcTryExcept _SEH2_TRY 122 #define RpcExcept(expr) _SEH2_EXCEPT((expr)) 123 #define RpcEndExcept _SEH2_END; 124 #define RpcTryFinally _SEH2_TRY 125 #define RpcFinally _SEH2_FINALLY 126 #define RpcEndFinally _SEH2_END; 127 #define RpcExceptionCode() _SEH2_GetExceptionCode() 128 #define RpcAbnormalTermination() (_SEH2_GetExceptionCode() != 0) 129 #endif 130 131 #if defined(__RPC_WIN64__) 132 #include <poppack.h> 133 #endif 134 135 #ifndef RPC_NO_WINDOWS_H 136 #include <rpcasync.h> 137 #endif 138 139 #ifdef __cplusplus 140 } 141 #endif 142 143 #endif 144 145 146