source: trunk/src/win32k/include/options.h@ 4310

Last change on this file since 4310 was 4307, checked in by bird, 25 years ago

Corrected problem with kernel build 14053. (new parameter to ldrOpenPath)
Added symbols for 14053 and 8266.

File size: 6.1 KB
Line 
1/* $Id: options.h,v 1.12 2000-09-22 09:22:37 bird Exp $
2 *
3 * Options.
4 *
5 * Copyright (c) 1998-1999 knut st. osmundsen
6 *
7 * Project Odin Software License can be found in LICENSE.TXT
8 *
9 */
10
11/* NOINC */
12#ifndef _options_h_
13#define _options_h_
14/* INC */
15
16/*******************************************************************************
17* Defined Constants And Macros *
18*******************************************************************************/
19/* fKernel */
20#define KF_UNI 0x0000
21#define KF_SMP 0x0001
22#define KF_W4 0x0002
23#define KF_DEBUG 0x1000
24#define KF_HAS_DEBUGTYPE 0x2000
25#define KF_ALLSTRICT 0x3000
26#define KF_HALFSTRICT 0x7000
27
28/* fPE */
29#define FLAGS_PE_NOT 0x00000000UL
30#define FLAGS_PE_PE2LX 0x00000001UL
31#define FLAGS_PE_PE 0x00000002UL
32#define FLAGS_PE_MIXED 0x00000003UL
33
34/* ulInfoLevel */
35#define INFOLEVEL_QUIET 0x00000000UL
36#define INFOLEVEL_ERROR 0x00000001UL
37#define INFOLEVEL_WARNING 0x00000002UL
38#define INFOLEVEL_INFO 0x00000003UL
39#define INFOLEVEL_INFOALL 0x00000004UL
40
41/* default heapsizes */
42#define CB_SWP_INIT ((unsigned long)1024*512) /* 512KB */
43#define CB_SWP_MAX ((unsigned long)1024*1024*16) /* 16MB */
44#define CB_RES_INIT ((unsigned long)1024*256) /* 256KB */
45#define CB_RES_MAX ((unsigned long)1024*1024*10) /* 10MB */
46
47/* NOINC */
48/* default assignments */
49#define DEFAULT_OPTION_ASSIGMENTS \
50 {FALSE, /* fQuiet */ \
51 OUTPUT_COM2, /* usCom */ \
52 FALSE, /* fLogging */ \
53 KF_UNI, /* fKernel */ \
54 ~0UL, /* ulBuild */ \
55 (unsigned short)~0, /* usVerMajor */ \
56 (unsigned short)~0, /* usVerMinor */ \
57 FLAGS_PE_MIXED, /* fPE */ \
58 INFOLEVEL_QUIET, /* ulInfoLevel */ \
59 FALSE, /* fElf */ \
60 TRUE, /* fUNIXScript */ \
61 TRUE, /* fREXXScript */ \
62 TRUE, /* fJava */ \
63 FALSE, /* fNoLoader */ \
64 CB_SWP_INIT, /* cbSwpHeapInit */ \
65 CB_SWP_MAX, /* cbSwpHeapMax */ \
66 CB_RES_INIT, /* cbResHeapInit */ \
67 CB_RES_MAX} /* cbResHeapMax */
68
69#define isAnyLoaderEnabled() (!options.fNoLoader && \
70 (isPELoaderEnabled() || isELFEnabled() || isUNIXScriptEnabled() || isREXXScriptEnabled() || isJAVAEnabled()))
71#define isPELoaderEnabled() (options.fPE != FLAGS_PE_NOT)
72#define isPELoaderDisabled() (options.fPE == FLAGS_PE_NOT)
73#define isPe2LxLoaderEnabled() (options.fPE == FLAGS_PE_PE2LX)
74#define isMixedPeLoaderEnabled() (options.fPE == FLAGS_PE_MIXED)
75
76#define isELFDisabled() (!options.fElf)
77#define isELFEnabled() (options.fElf)
78#define isUNIXScriptDisabled() (!options.fUNIXScript)
79#define isUNIXScriptEnabled() (options.fUNIXScript)
80#define isREXXScriptDisabled() (!options.fREXXScript)
81#define isREXXScriptEnabled() (options.fREXXScript)
82#define isJAVADisabled() (!options.fJava)
83#define isJAVAEnabled() (options.fJava)
84
85#define isSMPKernel() (options.fKernel & KF_SMP)
86#define isUNIKernel() !(options.fKernel & KF_SMP)
87/* INC */
88
89/*******************************************************************************
90* Structures and Typedefs *
91*******************************************************************************/
92/** Option struct */
93#pragma pack(4)
94struct options
95{
96 /** @cat misc */
97 ULONG fQuiet; /* Quiet initialization. */
98
99 /** @cat logging options */
100 USHORT usCom; /* Output port no. */
101 USHORT fLogging; /* Logging. */
102
103 /** @cat kernel selection */
104 ULONG fKernel; /* Smp or uni kernel. */
105 ULONG ulBuild; /* Kernel build. */
106 USHORT usVerMajor; /* OS/2 major ver - 20 */
107 USHORT usVerMinor; /* OS/2 minor ver - 30,40 */
108
109 /** @cat Options affecting the generated LX executables */
110 ULONG fPE; /* Flags set the type of conversion. */
111 ULONG ulInfoLevel; /* Pe2Lx InfoLevel. */
112
113 /** @cat Options affecting the generated ELF executables */
114 ULONG fElf; /* Elf flags. */
115
116 /** @cat Options affecting the UNIX script executables */
117 ULONG fUNIXScript; /* UNIX script flags. */
118
119 /** @cat Options affecting the REXX script executables */
120 ULONG fREXXScript; /* REXX script flags. */
121
122 /** @cat Options affecting the JAVA executables */
123 ULONG fJava; /* Java flags. */
124
125 /** @cat Options affecting the executables */
126 ULONG fNoLoader; /* No loader stuff. !FIXME! We should import / functions even if this flag is set!!! */
127
128 /** @cat Options affecting the heap. */
129 ULONG cbSwpHeapInit; /* Initial heapsize. */
130 ULONG cbSwpHeapMax; /* Maximum heapsize. */
131 ULONG cbResHeapInit; /* Initial residentheapsize. */
132 ULONG cbResHeapMax; /* Maxiumem residentheapsize. */
133};
134#pragma pack()
135
136/*******************************************************************************
137* Global Variables *
138*******************************************************************************/
139/* NOINC */
140extern struct options DATA16_GLOBAL options; /* defined in d16globals.c */
141#if defined(__IBMC__) || defined(__IBMCPP__)
142 #pragma map( options , "_options" )
143#endif
144/* INC */
145
146/* NOINC */
147#endif
148/* INC */
149
Note: See TracBrowser for help on using the repository browser.