Concord - C Discord API library
A Discord API wrapper library written in C
osname.h
Go to the documentation of this file.
1
#ifndef OSNAME_H
2
#define OSNAME_H 1
3
4
/*
5
* HackerSmacker's "Detect-It-All" OS Detector
6
*/
7
8
enum
OSClass
{
9
UNIX
,
10
WINDOWS
,
11
DOS
,
12
OS2
,
13
S370
,
14
DEC
,
15
MACINTOSH
,
16
AMIGA
,
17
OTHER
18
};
19
20
#ifdef _AIX
21
#define OSNAME "AIX"
22
#define OSCLASS UNIX
23
#endif
24
25
#ifdef __ANDROID__
26
#define OSNAME "Android"
27
#define OSCLASS UNIX
28
#endif
29
30
#ifdef UTS
31
#define OSNAME "UTS"
32
#define OSCLASS UNIX
33
#endif
34
35
#ifdef aegis
36
#define OSNAME "Aegis"
37
#define OSCLASS UNIX
38
#endif
39
40
#ifdef __BEOS__
41
#define OSNAME "BeOS"
42
#define OSCLASS OTHER
43
#endif
44
45
#ifdef __FreeBSD__
46
#define OSNAME "FreeBSD"
47
#define OSCLASS UNIX
48
#endif
49
50
#ifdef __NetBSD__
51
#define OSNAME "NetBSD"
52
#define OSCLASS UNIX
53
#endif
54
55
#ifdef __OpenBSD__
56
#define OSNAME "OpenBSD"
57
#define OSCLASS UNIX
58
#endif
59
60
#ifdef __bsdi__
61
#define OSNAME "BSD/OS"
62
#define OSCLASS UNIX
63
#endif
64
65
#ifdef __DragonFly__
66
#define OSNAME "DragonFly BSD"
67
#define OSCLASS UNIX
68
#endif
69
70
#ifdef __convex__
71
#define OSNAME "ConvexOS"
72
#define OSCLASS UNIX
73
#endif
74
75
#ifdef __CYGWIN__
76
#define OSNAME "Windows NT (Cygwin)"
77
#define OSCLASS UNIX
78
#endif
79
80
#if defined __DGUX__ || DGUX
81
#define OSNAME "DG/UX"
82
#define OSCLASS UNIX
83
#endif
84
85
#if defined __SEQUENT__ || sequent
86
#define OSNAME "DYNIX/ptx"
87
#define OSCLASS UNIX
88
#endif
89
90
#ifdef __ECOS
91
#define OSNAME "eCos"
92
#define OSCLASS OTHER
93
#endif
94
95
#ifdef __EMX__
96
#define OSNAME "OS/2 (EMX)"
97
#define OSCLASS UNIX
98
#endif
99
100
#ifdef __gnu_hurd__
101
#define OSNAME "GNU/Hurd"
102
#define OSCLASS UNIX
103
#endif
104
105
#if defined __gnu_linux__ || defined __linux__ || defined linux
106
#define OSNAME "GNU/Linux"
107
#define OSCLASS UNIX
108
#endif
109
110
#if defined _hpux || defined hpux || defined __hpux
111
#define OSNAME "HP-UX"
112
#define OSCLASS UNIX
113
#endif
114
115
#ifdef __OS400__
116
#define OSNAME "OS/400"
117
#define OSCLASS OTHER
118
#endif
119
120
#if defined __sgi || defined sgi
121
#define OSNAME "IRIX"
122
#define OSCLASS UNIX
123
#endif
124
125
#ifdef __INTEGRITY
126
#define OSNAME "INTEGRITY"
127
#define OSCLASS OTHER
128
#endif
129
130
#ifdef __Lynx__
131
#define OSNAME "LynxOS"
132
#define OSCLASS OTHER
133
#endif
134
135
#if defined macintosh || defined Macintosh
136
#define OSNAME "Classic Mac OS"
137
#define OSTYPE MACINTOSH
138
#endif
139
140
#ifdef __APPLE__
141
#ifdef __MACH
142
#define OSNAME "Mac OS X"
143
#define OSCLASS UNIX
144
#endif
145
#endif
146
147
#if defined __OS9000 || defined _OSK
148
#define OSNAME "OS-9"
149
#define OSCLASS OTHER
150
#endif
151
152
#ifdef __MORPHOS__
153
#define OSNAME "MorphOS"
154
#define OSCLASS AMIGA
155
#endif
156
157
#if defined AMIGA || defined __amigaos__
158
#define OSNAME "AmigaOS"
159
#define OSCLASS AMIGA
160
#endif
161
162
#if defined mpeix || defined __mpexl
163
#define OSNAME "MPE/iX"
164
#define OSCLASS OTHER
165
#endif
166
167
#if defined MSDOS || defined __MSDOS__ || defined _MSDOS || defined __DOS__
168
#define OSNAME "MS-DOS"
169
#define OSCLASS DOS
170
#endif
171
172
#ifdef __TANDEM
173
#define OSNAME "NonStop OS"
174
#define OSCLASS OTHER
175
#endif
176
177
#if defined OS2 || defined _OS2 || defined __OS2__ || defined __TOS_OS2__
178
#define OSNAME "OS/2"
179
#define OSCLASS OS2
180
#endif
181
182
#ifdef EPLAN9
183
#define OSNAME "Plan 9"
184
#define OSCLASS OTHER
185
#endif
186
187
#if defined __QNX__ || defined __QNXNTO__
188
#define OSNAME "QNX"
189
#define OSCLASS UNIX
190
#endif
191
192
#ifdef M_I386
193
#define OSNAME "SCO UNIX"
194
#define OSCLASS UNIX
195
#endif
196
197
#if defined sun || defined __sun
198
#if defined __SVR4 || defined __svr4
199
#define OSNAME "Solaris"
200
#define OSCLASS UNIX
201
#endif
202
#define OSNAME "SunOS"
203
#define OSCLASS UNIX
204
#endif
205
206
#ifdef __VOS__
207
#define OSNAME "VOS"
208
#define OSCLASS OTHER
209
#endif
210
211
#if defined __osf__ || defined __osf
212
#define OSNAME "OSF/1"
213
#define OSCLASS UNIX
214
#endif
215
216
#if defined ultrix || defined __ultrix || defined __ultrix__ || __SYSTYPE_BSD
217
#define OSNAME "ULTRIX"
218
#define OSCLASS UNIX
219
#endif
220
221
#if defined sco || defined _UNIXWARE7
222
#define OSNAME "UnixWare"
223
#define OSCLASS UNIX
224
#endif
225
226
#if defined VMS || defined __VMS
227
#define OSNAME "VMS"
228
#define OSCLASS VMS
229
#endif
230
231
#ifdef __VM__
232
#define OSNAME "VM/CMS"
233
#define OSCLASS S370
234
#endif
235
236
#ifdef __MVS__
237
#define OSNAME "MVS"
238
#define OSCLASS S370
239
#endif
240
241
#ifdef __EDC_LE
242
#ifndef __VM__
243
#define OSNAME "VSE"
244
#define OSCLASS S370
245
#endif
246
#ifndef __MVS__
247
#define OSNAME "VSE"
248
#define OSCLASS S370
249
#endif
250
#endif
251
252
#if defined __MCP__
253
#define OSNAME "MCP"
254
#define OSCLASS OTHER
255
#endif
256
257
#if defined _NETWARE_ || defined __NETWARE__
258
#define OSNAME "NetWare"
259
#define OSCLASS OTHER
260
#endif
261
262
#ifdef __MACH__
263
#ifndef __APPLE__
264
#define OSNAME "NeXTSTEP"
265
#define OSCLASS UNIX
266
#endif
267
#endif
268
269
#ifdef pyr
270
#define OSNAME "DC/OSx"
271
#define OSCLASS UNIX
272
#endif
273
274
#if defined sinux || defined sinix
275
#define OSNAME "Reliant UNIX"
276
#define OSCLASS UNIX
277
#endif
278
279
#ifdef _UNICOS
280
#define OSNAME "UNICOS"
281
#define OSCLASS UNIX
282
#endif
283
284
#if defined _CRAY || defined _crayx1
285
#define OSNAME "UNICOS/mp"
286
#define OSCLASS UNIX
287
#endif
288
289
#ifdef _UWIN
290
#define OSNAME "Windows NT (U/Win)"
291
#define OSCLASS WINDOWS
292
#endif
293
294
#if defined __VXWORKS__ || defined __vxworks
295
#define OSNAME "VxWorks"
296
#define OSCLASS OTHER
297
#endif
298
299
#ifdef _WIN32_WCE
300
#define OSNAME "Windows CE"
301
#define OSCLASS WINDOWS
302
#endif
303
304
#if defined _WIN32 | defined _WIN64 | defined __WIN32__
305
#define OSNAME "Windows NT"
306
#define OSCLASS WINDOWS
307
#endif
308
309
#ifdef _WIN16
310
#define OSNAME "Windows 3.x"
311
#define OSCLASS WINDOWS
312
#endif
313
314
#ifndef OSNAME
315
#define OSNAME "POSIX"
316
#define OSCLASS UNIX
317
#endif
318
319
#endif
OSClass
OSClass
Definition:
osname.h:8
AMIGA
@ AMIGA
Definition:
osname.h:16
WINDOWS
@ WINDOWS
Definition:
osname.h:10
MACINTOSH
@ MACINTOSH
Definition:
osname.h:15
UNIX
@ UNIX
Definition:
osname.h:9
DEC
@ DEC
Definition:
osname.h:14
DOS
@ DOS
Definition:
osname.h:11
OTHER
@ OTHER
Definition:
osname.h:17
S370
@ S370
Definition:
osname.h:13
OS2
@ OS2
Definition:
osname.h:12
include
osname.h
Generated by
1.9.3