summaryrefslogtreecommitdiffstatshomepage
path: root/src/osd/sdl3/sdlprefix.h
blob: 33676391e906df45b584735472d2486ca53e1ff0 (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
// license:BSD-3-Clause
// copyright-holders:Olivier Galibert, R. Belmont
//============================================================
//
//  sdlprefix.h - prefix file, included by ALL files
//
//  SDLMAME by Olivier Galibert and R. Belmont
//
//============================================================

//============================================================
// System specific defines
//============================================================

/* Only problems ... */
#if defined(_WIN32)
#define SDLMAME_WIN32 1
#endif


#ifdef SDL_PLATFORM_APPLE
#define SDLMAME_DARWIN 1
#endif /* SDL_PLATFORM_APPLE */

#ifdef SDLMAME_UNIX

#if defined(__linux__) || defined(__FreeBSD_kernel__)
#define SDLMAME_LINUX 1

#elif defined(__FreeBSD__)
#define SDLMAME_FREEBSD 1
#define NO_AFFINITY_NP 1
#elif defined(__DragonFly__)
#define SDLMAME_DRAGONFLY 1
#elif defined(__OpenBSD__)
#define SDLMAME_OPENBSD 1
#elif defined(__NetBSD__)
#define SDLMAME_NETBSD 1
#endif

#if defined(__DragonFly__) || defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__)
#define SDLMAME_BSD 1
#endif

#if defined(SDL_PLATFORM_HAIKU)
#define SDLMAME_HAIKU 1
#define SDLMAME_NO64BITIO 1
#endif

#if defined(__EMSCRIPTEN__)
#define SDLMAME_EMSCRIPTEN 1
#define SDLMAME_NO64BITIO 1
struct _IO_FILE {};  //_IO_FILE is an opaque type in the emscripten libc which makes clang cranky
#endif

#if defined(__ANDROID__)
#define SDLMAME_ANDROID 1
#endif

// fix for Ubuntu 8.10
#ifdef _FORTIFY_SOURCE
#undef _FORTIFY_SOURCE
#endif

#endif /* SDLMAME_UNIX */