[netcore] Improve netcore/build.sh script (#14835)
[mono-project.git] / winconfig.h
blob623f76ca670e209ddc30a50531eefd67ecbc5660
1 #pragma once
3 #ifdef _MSC_VER
5 /* Building Mono runtime under MSVC uses this template for it's config.h since autogen.sh can't */
6 /* generate a config.h that is suitable for MSVC builds. The below template will still get */
7 /* some dynamic configuration from autogen.sh config.h, if one exists. */
8 #include <msvc/msvc-win32-support.h>
9 #include <msvc/msvc-disabled-warnings.h>
11 #ifdef HAVE_BOEHM_GC
12 /* Only used when building using Boehm GC and only supported on x86 builds */
13 #define DEFAULT_GC_NAME "Included Boehm (with typed GC)"
14 #endif
16 /* Disable runtime state dumping */
17 #define DISABLE_CRASH_REPORTING 1
19 /* String of disabled features */
20 #define DISABLED_FEATURES "none"
22 /* Disables the IO portability layer */
23 #define DISABLE_PORTABILITY 1
25 /* Start configure DISABLE_DEFINES picked up from cygconfig.h or other external source, if available */
26 /* @DISABLE_DEFINES@ */
27 /* End configure DISABLE_DEFINES picked up from cygconfig.h or other external source, if available */
29 /* No DISABLE_DEFINES below this point */
31 /* Some VES is available at runtime */
32 #define ENABLE_ILGEN 1
34 /* Start configure ENABLE_DEFINES picked up from cygconfig.h or other external source, if available */
35 /* @ENABLE_DEFINES@ */
36 /* End configure ENABLE_DEFINES picked up from cygconfig.h or other external source, if available */
38 #if defined(ENABLE_HYBRID_SUSPEND)
39 /* Windows MSVC builds defaults to preemptive suspend. Disable ENABLE_HYBRID_SUSPEND defines. */
40 #undef ENABLE_HYBRID_SUSPEND
41 #endif
43 /* No ENABLE_DEFINES below this point */
45 /* Have access */
46 #define HAVE_ACCESS 1
48 /* Define to 1 if you have the `system' function. */
49 #if HAVE_WINAPI_FAMILY_SUPPORT(HAVE_CLASSIC_WINAPI_SUPPORT)
50 #define HAVE_SYSTEM 1
51 #endif
53 /* Define to 1 if you have the <complex.h> header file. */
54 #define HAVE_COMPLEX_H 1
56 #if defined(HAVE_SGEN_GC) && !defined(HAVE_CONC_GC_AS_DEFAULT)
57 /* Defaults to concurrent GC */
58 #define HAVE_CONC_GC_AS_DEFAULT 1
59 #endif
61 /* Have /dev/random */
62 #define HAVE_CRYPT_RNG 1
64 /* Define to 1 if you have the declaration of `InterlockedAdd',
65 and to 0 if you don't. */
66 #define HAVE_DECL_INTERLOCKEDADD 1
68 /* Define to 1 if you have the declaration of `InterlockedAdd64',
69 and to 0 if you don't. */
70 #define HAVE_DECL_INTERLOCKEDADD64 1
72 /* Define to 1 if you have the declaration of `InterlockedCompareExchange64',
73 and to 0 if you don't. */
74 #define HAVE_DECL_INTERLOCKEDCOMPAREEXCHANGE64 1
76 /* Define to 1 if you have the declaration of `InterlockedDecrement64',
77 and to 0 if you don't. */
78 #define HAVE_DECL_INTERLOCKEDDECREMENT64 1
80 /* Define to 1 if you have the declaration of `InterlockedExchange64',
81 and to 0 if you don't. */
82 #define HAVE_DECL_INTERLOCKEDEXCHANGE64 1
84 /* Define to 1 if you have the declaration of `InterlockedIncrement64',
85 and to 0 if you don't. */
86 #define HAVE_DECL_INTERLOCKEDINCREMENT64 1
88 /* Define to 1 if you have the declaration of `__readfsdword',
89 and to 0 if you don't. */
90 #define HAVE_DECL___READFSDWORD 1
92 /* Define to 1 if you have the `getaddrinfo' function. */
93 #define HAVE_GETADDRINFO 1
95 /* Define to 1 if you have the `getnameinfo' function. */
96 #define HAVE_GETNAMEINFO 1
98 /* Define to 1 if you have the `getprotobyname' function. */
99 #define HAVE_GETPROTOBYNAME 1
101 /* Define to 1 if you have the `GetProcessId' function. */
102 #define HAVE_GETPROCESSID 1
104 /* Have inet_ntop */
105 #define HAVE_INET_NTOP 1
107 /* Define to 1 if you have the `inet_pton' function. */
108 #define HAVE_INET_PTON 1
110 /* Define to 1 if you have the <inttypes.h> header file. */
111 #define HAVE_INTTYPES_H 1
113 /* Define to 1 if you have the <memory.h> header file. */
114 #define HAVE_MEMORY_H 1
116 #if defined(HAVE_SGEN_GC) && !defined(HAVE_MOVING_COLLECTOR)
117 /* Moving collector */
118 #define HAVE_MOVING_COLLECTOR 1
119 #endif
121 /* Define to 1 if you have the `signal' function. */
122 #define HAVE_SIGNAL 1
124 /* Define to 1 if you have the <signal.h> header file. */
125 #define HAVE_SIGNAL_H 1
127 /* Define to 1 if you have the <stdint.h> header file. */
128 #define HAVE_STDINT_H 1
130 /* Define to 1 if you have the <stdlib.h> header file. */
131 #define HAVE_STDLIB_H 1
133 /* Define to 1 if you have the <strings.h> header file. */
134 #define HAVE_STRINGS_H 1
136 /* Define to 1 if you have the <string.h> header file. */
137 #define HAVE_STRING_H 1
139 /* Define to 1 if you have the `strtok_r' function. */
140 #define HAVE_STRTOK_R 1
142 /* Have struct ip_mreq */
143 #define HAVE_STRUCT_IP_MREQ 1
145 /* Define to 1 if the system has the type `struct sockaddr_in6'. */
146 #define HAVE_STRUCT_SOCKADDR_IN6 1
148 /* Define to 1 if you have the <sys/stat.h> header file. */
149 #define HAVE_SYS_STAT_H 1
151 /* Define to 1 if you have the <sys/types.h> header file. */
152 #define HAVE_SYS_TYPES_H 1
154 /* Define to 1 if you have the <sys/utime.h> header file. */
155 #define HAVE_SYS_UTIME_H 1
157 /* Define to 1 if you have the <wchar.h> header file. */
158 #define HAVE_WCHAR_H 1
160 /* Define to 1 if you have the <winternl.h> header file. */
161 #define HAVE_WINTERNL_H 1
163 #if defined(HAVE_SGEN_GC) && !defined(HAVE_WRITE_BARRIERS)
164 #define HAVE_WRITE_BARRIERS
165 #endif
167 /* Start configure HAVE_DEFINES picked up from cygconfig.h or other external source, if available */
168 /* @HAVE_DEFINES@ */
169 /* End configure HAVE_DEFINES picked up from cygconfig.h or other external source, if available */
171 /* No HAVE_DEFINES below this point */
173 /* This platform does not support symlinks */
174 #define HOST_NO_SYMLINKS 1
176 /* Host Platform is Win32 */
177 #define HOST_WIN32 1
179 /* The architecture this is running on */
180 #if defined(_M_IA64)
181 #define MONO_ARCHITECTURE "ia64"
182 #elif defined(_M_AMD64)
183 #define MONO_ARCHITECTURE "amd64"
184 #elif defined(_M_IX86)
185 #define MONO_ARCHITECTURE "x86"
186 #else
187 #error Unknown architecture
188 #endif
190 /* Version of the corlib-runtime interface */
191 #define MONO_CORLIB_VERSION "#MONO_CORLIB_VERSION#"
193 /* Have __thread keyword */
194 #define MONO_KEYWORD_THREAD __declspec (thread)
196 /* Length of zero length arrays */
197 #define MONO_ZERO_LEN_ARRAY 1
199 /* Name of /dev/random */
200 #define NAME_DEV_RANDOM ""
202 /* Name of package */
203 #define PACKAGE "mono"
205 /* Define to the address where bug reports for this package should be sent. */
206 #define PACKAGE_BUGREPORT "https://github.com/mono/mono/issues/new"
208 /* Define to the full name of this package. */
209 #define PACKAGE_NAME "mono"
211 /* Define to the full name and version of this package. */
212 #define PACKAGE_STRING "mono #MONO_VERSION#"
214 /* Define to the one symbol short name of this package. */
215 #define PACKAGE_TARNAME "mono"
217 /* Define to the home page for this package. */
218 #define PACKAGE_URL ""
220 /* Define to the version of this package. */
221 #define PACKAGE_VERSION "#MONO_VERSION#"
223 /* The size of `int', as computed by sizeof. */
224 #define SIZEOF_INT 4
226 /* The size of `long', as computed by sizeof. */
227 #define SIZEOF_LONG 4
229 /* The size of `long long', as computed by sizeof. */
230 #define SIZEOF_LONG_LONG 8
232 /* size of target machine integer registers */
233 #ifdef _WIN64
234 #define SIZEOF_REGISTER 8
235 #else
236 #define SIZEOF_REGISTER 4
237 #endif
239 /* The size of `void *', as computed by sizeof. */
240 #ifdef _WIN64
241 #define SIZEOF_VOID_P 8
242 #else
243 #define SIZEOF_VOID_P 4
244 #endif
246 /* Define to 1 if you have the ANSI C header files. */
247 #define STDC_HEADERS 1
249 #ifdef _WIN64
250 #define TARGET_AMD64 1
251 #define HOST_AMD64 1
252 #else
253 #define TARGET_X86 1
254 #define HOST_X86 1
255 #endif
257 /* byte order of target */
258 #define TARGET_BYTE_ORDER G_BYTE_ORDER
260 /* wordsize of target */
261 #define TARGET_SIZEOF_VOID_P SIZEOF_VOID_P
263 /* Platform is Win32 */
264 #define TARGET_WIN32 1
266 /* Version number of package */
267 #define VERSION "#MONO_VERSION#"
269 #else
271 /* Not building under MSVC, use autogen.sh generated config.h */
272 #include "cygconfig.h"
274 #endif
276 #if defined(ENABLE_LLVM) && defined(HOST_WIN32) && defined(TARGET_WIN32) && (!defined(TARGET_AMD64) || !defined(_MSC_VER))
277 #error LLVM for host=Windows and target=Windows is only supported on x64 MSVC build.
278 #endif