blob: f5972f35f98eb0888988e5f88605ac9d435d95e4 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
|
/*++
Copyright (c) 1993 Microsoft Corporation
Module Name:
platform.h
Abstract:
This header file is used to cause the correct machine/platform specific
data structures to be used when compiling for a non-hosted platform.
Author:
Wesley Witt (wesw) 2-Aug-1993
Environment:
User Mode
--*/
#undef i386
#undef _X86_
#undef MIPS
#undef _MIPS_
#undef ALPHA
#undef _ALPHA_
#undef PPC
#undef _PPC_
#define _NTSYSTEM_
#define _CROSS_PLATFORM_
//-----------------------------------------------------------------------------------------
//
// mips r4000
//
//-----------------------------------------------------------------------------------------
#if defined(TARGET_MIPS)
#pragma message( "Compiling for target = mips" )
#define _MIPS_
#if defined(HOST_MIPS)
#define MIPS
#endif
#if defined(HOST_i386)
#define __unaligned
#endif
#include <nt.h>
#include <ntrtl.h>
#include <nturtl.h>
#include <ntdbg.h>
#include <ntos.h>
#include <windows.h>
#if !defined(HOST_MIPS)
#undef MIPS
#undef _MIPS_
#endif
#if defined(HOST_i386)
#undef _cdecl
#undef UNALIGNED
#define UNALIGNED
#endif
//-----------------------------------------------------------------------------------------
//
// PowerPC
//
//-----------------------------------------------------------------------------------------
#elif defined(TARGET_PPC)
#pragma message( "Compiling for target = ppc" )
#define _PPC_
#if defined(HOST_PPC)
#define PPC
#endif
#if defined(HOST_i386)
#define __unaligned
#endif
#include <nt.h>
#include <ntrtl.h>
#include <nturtl.h>
#include <ntdbg.h>
#include <ntos.h>
#include <windows.h>
#if !defined(HOST_PPC)
#undef PPC
#undef _PPC_
#endif
#if defined(HOST_i386)
#undef _cdecl
#undef UNALIGNED
#define UNALIGNED
#endif
//-----------------------------------------------------------------------------------------
//
// intel x86
//
//-----------------------------------------------------------------------------------------
#elif defined(TARGET_i386)
#pragma message( "Compiling for target = x86" )
#define _X86_
#if defined(HOST_MIPS)
#define MIPS
#endif
#include <nt.h>
#include <ntrtl.h>
#include <nturtl.h>
#include <ntdbg.h>
#include <ntos.h>
#include <windows.h>
#if defined(HOST_MIPS)
#undef _cdecl
#define _cdecl
#endif
#if defined(HOST_ALPHA)
#undef _cdecl
#define _cdecl
#endif
#if !defined(HOST_i386)
#undef _X86_
#endif
//-----------------------------------------------------------------------------------------
//
// alpha axp
//
//-----------------------------------------------------------------------------------------
#elif defined(TARGET_ALPHA)
#pragma message( "Compiling for target = alpha" )
#define _ALPHA_ 1
#if defined(HOST_i386)
#define __unaligned
#endif
#if defined(HOST_MIPS)
#define MIPS
#endif
#include <nt.h>
#include <ntrtl.h>
#include <nturtl.h>
#include <ntdbg.h>
#include <ntos.h>
#include <windows.h>
#if defined(HOST_MIPS)
#undef _cdecl
#define _cdecl
#endif
#if defined(HOST_i386)
#undef UNALIGNED
#define UNALIGNED
#endif
#if !defined(HOST_ALPHA)
#undef _ALPHA_
#endif
#else
//-----------------------------------------------------------------------------------------
//
// unknown platform
//
//-----------------------------------------------------------------------------------------
#error "Unsupported target CPU"
#endif
|