-
Notifications
You must be signed in to change notification settings - Fork 92
/
hqadefs.h
502 lines (352 loc) · 15.5 KB
/
hqadefs.h
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
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
/* HQADEFS.H (C) "Fish" (David B. Trout), 2013 */
/* QA Build Configuration Testing Scenarios */
/* */
/* Released under "The Q Public License Version 1" */
/* (http://www.hercules-390.org/herclic.html) as modifications to */
/* Hercules. */
#ifndef _HQADEFS_H_
#define _HQADEFS_H_
/*-------------------------------------------------------------------*/
/* HQA Scenario 0 Reserved for normal builds */
/*-------------------------------------------------------------------*/
#if !defined(HQA_SCENARIO) || HQA_SCENARIO == 0
/* Do nothing. This effectively does a normal build */
#else
/*-------------------------------------------------------------------*/
/* HQA Scenario 1 System/370 support only */
/*-------------------------------------------------------------------*/
#if HQA_SCENARIO == 1 // System/370 support only
#undef CUSTOM_BUILD_STRING
#define CUSTOM_BUILD_STRING "\n\n HQA Scenario 1\n"
#define OPTION_370_MODE
#define NO_390_MODE
#define NO_900_MODE
#endif
/*-------------------------------------------------------------------*/
/* HQA Scenario 2 ESA/390 support only */
/*-------------------------------------------------------------------*/
#if HQA_SCENARIO == 2 // ESA/390 support only
#undef CUSTOM_BUILD_STRING
#define CUSTOM_BUILD_STRING "\n\n HQA Scenario 2\n"
#define NO_370_MODE
#define OPTION_390_MODE
#define NO_900_MODE
#endif
/*-------------------------------------------------------------------*/
/* HQA Scenario 3 System/370 and ESA/390 support only */
/*-------------------------------------------------------------------*/
#if HQA_SCENARIO == 3 // System/370 and ESA/390 support only
#undef CUSTOM_BUILD_STRING
#define CUSTOM_BUILD_STRING "\n\n HQA Scenario 3\n"
#define OPTION_370_MODE
#define OPTION_390_MODE
#define NO_900_MODE
#endif
/*-------------------------------------------------------------------*/
/* HQA Scenario 4 zArchitecure and ESA/390 support only */
/*-------------------------------------------------------------------*/
#if HQA_SCENARIO == 4 // zArchitecure and ESA/390 support only
#undef CUSTOM_BUILD_STRING
#define CUSTOM_BUILD_STRING "\n\n HQA Scenario 4\n"
#define NO_370_MODE
#define OPTION_390_MODE
#define OPTION_900_MODE
#endif
/*-------------------------------------------------------------------*/
/* HQA Scenario 5 Windows, fthreads */
/*-------------------------------------------------------------------*/
#if HQA_SCENARIO == 5 // Windows, fthreads
#undef CUSTOM_BUILD_STRING
#define CUSTOM_BUILD_STRING "\n\n HQA Scenario 5\n"
#if !defined(_MSVC_)
#error Selected HQA scenario is for MSVC only
#endif
#define OPTION_FTHREADS
#endif
/*-------------------------------------------------------------------*/
/* HQA Scenario 6 Windows, Posix threads */
/*-------------------------------------------------------------------*/
#if HQA_SCENARIO == 6 // Windows, Posix threads
#undef CUSTOM_BUILD_STRING
#define CUSTOM_BUILD_STRING "\n\n HQA Scenario 6\n"
#if defined(_MSVC_)
#error Selected HQA scenario is not supported for MSVC builds
#endif
#if !defined(WIN32) && !defined(_WIN32)
#error Selected HQA scenario is for Windows only
#endif
#undef OPTION_FTHREADS
#endif
/*-------------------------------------------------------------------*/
/* HQA Scenario 7 Vista, fthreads */
/*-------------------------------------------------------------------*/
#if HQA_SCENARIO == 7 // Vista, fthreads
#undef CUSTOM_BUILD_STRING
#define CUSTOM_BUILD_STRING "\n\n HQA Scenario 7\n"
#if !defined(_MSVC_)
#error Selected HQA scenario is for MSVC only
#endif
// Vista or later...
#undef _WIN32_WINNT
#undef WINVER
#undef NTDDI_VERSION
#undef _WIN32_IE
#define _WIN32_WINNT 0x0600 // Vista
#define WINVER 0x0600 // Vista
#define NTDDI_VERSION 0x06000100 // Vista SP1
#define _WIN32_IE 0x0700 // IE 7.0
#define OPTION_FTHREADS
#endif
/*-------------------------------------------------------------------*/
/* HQA Scenario 8 Vista, Posix threads */
/*-------------------------------------------------------------------*/
#if HQA_SCENARIO == 8 // Vista, Posix threads
#undef CUSTOM_BUILD_STRING
#define CUSTOM_BUILD_STRING "\n\n HQA Scenario 8\n"
#if defined(_MSVC_)
#error Selected HQA scenario is not supported for MSVC builds
#endif
#if !defined(WIN32) && !defined(_WIN32)
#error Selected HQA scenario is for Windows only
#endif
// Vista or later...
#undef _WIN32_WINNT
#undef WINVER
#undef NTDDI_VERSION
#undef _WIN32_IE
#define _WIN32_WINNT 0x0600 // Vista
#define WINVER 0x0600 // Vista
#define NTDDI_VERSION 0x06000100 // Vista SP1
#define _WIN32_IE 0x0700 // IE 7.0
#undef OPTION_FTHREADS
#endif
/*-------------------------------------------------------------------*/
/* HQA Scenario 9 INLINE == forced inline */
/*-------------------------------------------------------------------*/
#if HQA_SCENARIO == 9 // INLINE == forced inline
#undef CUSTOM_BUILD_STRING
#define CUSTOM_BUILD_STRING "\n\n HQA Scenario 9\n"
#undef INLINE
#if defined(__GNUC__)
#define INLINE __inline__ __attribute__((always_inline))
#elif defined(_MSVC_)
#define INLINE __forceinline
#else
#define INLINE __inline
#endif
#endif
/*-------------------------------------------------------------------*/
/* HQA Scenario 10 INLINE == inline (just a suggestion) */
/*-------------------------------------------------------------------*/
#if HQA_SCENARIO == 10 // INLINE == inline (just a suggestion)
#undef CUSTOM_BUILD_STRING
#define CUSTOM_BUILD_STRING "\n\n HQA Scenario 10\n"
#undef INLINE
#if defined(__GNUC__)
#define INLINE __inline__
#elif defined(_MSVC_)
#define INLINE __inline
#else
#define INLINE __inline
#endif
#endif
/*-------------------------------------------------------------------*/
/* HQA Scenario 11 INLINE == null (compiler decides on own) */
/*-------------------------------------------------------------------*/
#if HQA_SCENARIO == 11 // INLINE == null (compiler decides on own)
#undef CUSTOM_BUILD_STRING
#define CUSTOM_BUILD_STRING "\n\n HQA Scenario 11\n"
#undef INLINE
#define INLINE /* nothing */
#endif
/*-------------------------------------------------------------------*/
/* HQA Scenario 12 NO_IEEE_SUPPORT */
/*-------------------------------------------------------------------*/
#if HQA_SCENARIO == 12 // NO_IEEE_SUPPORT
#undef CUSTOM_BUILD_STRING
#define CUSTOM_BUILD_STRING "\n\n HQA Scenario 12\n"
#define NO_IEEE_SUPPORT
#endif
/*-------------------------------------------------------------------*/
/* HQA Scenario 13 *UNASSIGNED* */
/*-------------------------------------------------------------------*/
#if HQA_SCENARIO == 13 // *UNASSIGNED*
#undef CUSTOM_BUILD_STRING
#define CUSTOM_BUILD_STRING "\n\n HQA Scenario 13 (*UNASSIGNED*)\n"
//#define xxx...
//#undef xxx...
#endif
/*-------------------------------------------------------------------*/
/* HQA Scenario 14 With Shared Devices */
/*-------------------------------------------------------------------*/
#if HQA_SCENARIO == 14 // With Shared Devices
#undef CUSTOM_BUILD_STRING
#define CUSTOM_BUILD_STRING "\n\n HQA Scenario 14\n"
#define OPTION_SHARED_DEVICES
#undef OPTION_NO_SHARED_DEVICES
#endif
/*-------------------------------------------------------------------*/
/* HQA Scenario 15 Without Shared Devices */
/*-------------------------------------------------------------------*/
#if HQA_SCENARIO == 15 // Without Shared Devices
#undef CUSTOM_BUILD_STRING
#define CUSTOM_BUILD_STRING "\n\n HQA Scenario 15\n"
#undef OPTION_SHARED_DEVICES
#define OPTION_NO_SHARED_DEVICES
#endif
/*-------------------------------------------------------------------*/
/* HQA Scenario 16 Without Object Rexx */
/*-------------------------------------------------------------------*/
#if HQA_SCENARIO == 16 // Without Object Rexx
#undef CUSTOM_BUILD_STRING
#define CUSTOM_BUILD_STRING "\n\n HQA Scenario 16\n"
#undef OBJECT_REXX_HDR_DIR
#undef OBJECT_REXX_HEADER1
#undef OBJECT_REXX_HEADER2
#undef HAVE_OBJECT_REXX
#undef HAVE_REXX_H
#undef HAVE_OOREXXAPI_H
#endif
/*-------------------------------------------------------------------*/
/* HQA Scenario 17 Without Regina Rexx */
/*-------------------------------------------------------------------*/
#if HQA_SCENARIO == 17 // Without Regina Rexx
#undef CUSTOM_BUILD_STRING
#define CUSTOM_BUILD_STRING "\n\n HQA Scenario 17\n"
#undef REGINA_REXX_HDR_DIR
#undef REGINA_REXX_HEADER1
#undef HAVE_REGINA_REXX
#undef HAVE_REXXSAA_H
#endif
/*-------------------------------------------------------------------*/
/* HQA Scenario 18 Without Object Rexx, Without Regina Rexx */
/*-------------------------------------------------------------------*/
#if HQA_SCENARIO == 18 // Without Object Rexx, Without Regina Rexx
#undef CUSTOM_BUILD_STRING
#define CUSTOM_BUILD_STRING "\n\n HQA Scenario 18\n"
#undef OBJECT_REXX_HDR_DIR
#undef OBJECT_REXX_HEADER1
#undef OBJECT_REXX_HEADER2
#undef HAVE_OBJECT_REXX
#undef HAVE_REXX_H
#undef HAVE_OOREXXAPI_H
#undef REGINA_REXX_HDR_DIR
#undef REGINA_REXX_HEADER1
#undef HAVE_REGINA_REXX
#undef HAVE_REXXSAA_H
#endif
/*-------------------------------------------------------------------*/
/* HQA Scenario 19 Without TCP keepalive support */
/*-------------------------------------------------------------------*/
#if HQA_SCENARIO == 19 // Without TCP keepalive support
#undef CUSTOM_BUILD_STRING
#define CUSTOM_BUILD_STRING "\n\n HQA Scenario 19\n"
#undef HAVE_BASIC_KEEPALIVE
#undef HAVE_PARTIAL_KEEPALIVE
#undef HAVE_FULL_KEEPALIVE
#undef HAVE_DECL_SO_KEEPALIVE
#undef HAVE_DECL_TCP_KEEPALIVE
#undef HAVE_DECL_TCP_KEEPIDLE
#undef HAVE_DECL_TCP_KEEPINTVL
#undef HAVE_DECL_TCP_KEEPCNT
#endif
/*-------------------------------------------------------------------*/
/* HQA Scenario 20 With Basic TCP keepalive support */
/*-------------------------------------------------------------------*/
#if HQA_SCENARIO == 20 // With Basic TCP keepalive support
#undef CUSTOM_BUILD_STRING
#define CUSTOM_BUILD_STRING "\n\n HQA Scenario 20\n"
#undef HAVE_BASIC_KEEPALIVE
#undef HAVE_PARTIAL_KEEPALIVE
#undef HAVE_FULL_KEEPALIVE
//#undef HAVE_DECL_SO_KEEPALIVE // (use whichever this system uses)
//#undef HAVE_DECL_TCP_KEEPALIVE // (use whichever this system uses)
#undef HAVE_DECL_TCP_KEEPIDLE
#undef HAVE_DECL_TCP_KEEPINTVL
#undef HAVE_DECL_TCP_KEEPCNT
// (we must presume this system has AT LEAST Basic support)
#define HAVE_BASIC_KEEPALIVE 1
#undef HAVE_PARTIAL_KEEPALIVE
#undef HAVE_FULL_KEEPALIVE
//#undef HAVE_DECL_SO_KEEPALIVE // (use whichever this system uses)
//#undef HAVE_DECL_TCP_KEEPALIVE // (use whichever this system uses)
#undef HAVE_DECL_TCP_KEEPIDLE
#undef HAVE_DECL_TCP_KEEPINTVL
#undef HAVE_DECL_TCP_KEEPCNT
#endif
/*-------------------------------------------------------------------*/
/* HQA Scenario 21 With Partial TCP keepalive support */
/*-------------------------------------------------------------------*/
#if HQA_SCENARIO == 21 // With Partial TCP keepalive support
#undef CUSTOM_BUILD_STRING
#define CUSTOM_BUILD_STRING "\n\n HQA Scenario 21\n"
#undef HAVE_BASIC_KEEPALIVE
#undef HAVE_PARTIAL_KEEPALIVE
#undef HAVE_FULL_KEEPALIVE
//#undef HAVE_DECL_SO_KEEPALIVE // (use whichever this system uses)
//#undef HAVE_DECL_TCP_KEEPALIVE // (use whichever this system uses)
#undef HAVE_DECL_TCP_KEEPIDLE
#undef HAVE_DECL_TCP_KEEPINTVL
#undef HAVE_DECL_TCP_KEEPCNT
// (we must presume this system has AT LEAST partial support)
#define HAVE_BASIC_KEEPALIVE 1
#define HAVE_PARTIAL_KEEPALIVE 1
#undef HAVE_FULL_KEEPALIVE
//#define HAVE_DECL_SO_KEEPALIVE // (use whichever this system uses)
//#define HAVE_DECL_TCP_KEEPALIVE // (use whichever this system uses)
#define HAVE_DECL_TCP_KEEPIDLE 1
#undef HAVE_DECL_TCP_KEEPINTVL
#define HAVE_DECL_TCP_KEEPCNT 1
#endif
/*-------------------------------------------------------------------*/
/* HQA Scenario 22 With Full TCP keepalive support */
/*-------------------------------------------------------------------*/
#if HQA_SCENARIO == 22 // With Full TCP keepalive support
#undef CUSTOM_BUILD_STRING
#define CUSTOM_BUILD_STRING "\n\n HQA Scenario 22\n"
#undef HAVE_BASIC_KEEPALIVE
#undef HAVE_PARTIAL_KEEPALIVE
#undef HAVE_FULL_KEEPALIVE
//#undef HAVE_DECL_SO_KEEPALIVE // (use whichever this system uses)
//#undef HAVE_DECL_TCP_KEEPALIVE // (use whichever this system uses)
#undef HAVE_DECL_TCP_KEEPIDLE
#undef HAVE_DECL_TCP_KEEPINTVL
#undef HAVE_DECL_TCP_KEEPCNT
// (we must presume this system has full support BY DEFAULT)
#define HAVE_BASIC_KEEPALIVE 1
#define HAVE_PARTIAL_KEEPALIVE 1
#define HAVE_FULL_KEEPALIVE 1
//#define HAVE_DECL_SO_KEEPALIVE // (use whichever this system uses)
//#define HAVE_DECL_TCP_KEEPALIVE // (use whichever this system uses)
#define HAVE_DECL_TCP_KEEPIDLE 1
#define HAVE_DECL_TCP_KEEPINTVL 1
#define HAVE_DECL_TCP_KEEPCNT 1
#endif
/*-------------------------------------------------------------------*/
/* HQA Scenario 23 Without S/370 Extensions backport */
/*-------------------------------------------------------------------*/
#if HQA_SCENARIO == 23 // Without S/370 Extensions backport
#undef CUSTOM_BUILD_STRING
#define CUSTOM_BUILD_STRING "\n\n HQA Scenario 23\n"
#define NO_370_EXTENSION
#endif
/*-------------------------------------------------------------------*/
/* HQA Scenario 24 Without Optimized Instructions */
/*-------------------------------------------------------------------*/
#if HQA_SCENARIO == 24 // Without Optimized Instructions
#undef CUSTOM_BUILD_STRING
#define CUSTOM_BUILD_STRING "\n\n HQA Scenario 24\n"
#define NO_OPTINST
#endif
/*-------------------------------------------------------------------*/
/* HQA Scenario 25 Without 370 Extensions or Optimized Instr */
/*-------------------------------------------------------------------*/
#if HQA_SCENARIO == 25 // Without 370 Extensions or Optimized Instr
#undef CUSTOM_BUILD_STRING
#define CUSTOM_BUILD_STRING "\n\n HQA Scenario 25\n"
#define NO_370_EXTENSION
#define NO_OPTINST
#endif
/*-------------------------------------------------------------------*/
#endif // !defined(HQA_SCENARIO) || HQA_SCENARIO == 0
#endif /*_HQADEFS_H_*/