-
-
Notifications
You must be signed in to change notification settings - Fork 26k
Expand file tree
/
Copy pathSDL_build_config_private.h
More file actions
169 lines (144 loc) · 5.48 KB
/
Copy pathSDL_build_config_private.h
File metadata and controls
169 lines (144 loc) · 5.48 KB
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
/**************************************************************************/
/* SDL_build_config_private.h */
/**************************************************************************/
/* This file is part of: */
/* GODOT ENGINE */
/* https://godotengine.org */
/**************************************************************************/
/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur. */
/* */
/* Permission is hereby granted, free of charge, to any person obtaining */
/* a copy of this software and associated documentation files (the */
/* "Software"), to deal in the Software without restriction, including */
/* without limitation the rights to use, copy, modify, merge, publish, */
/* distribute, sublicense, and/or sell copies of the Software, and to */
/* permit persons to whom the Software is furnished to do so, subject to */
/* the following conditions: */
/* */
/* The above copyright notice and this permission notice shall be */
/* included in all copies or substantial portions of the Software. */
/* */
/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
/**************************************************************************/
#pragma once
#define SDL_build_config_h_
#include <SDL3/SDL_platform_defines.h>
#define HAVE_STDARG_H 1
#define HAVE_STDDEF_H 1
// Here we disable SDL subsystems that are not going to be used
#define SDL_CPUINFO_DISABLED 1
#define SDL_AUDIO_DISABLED 1
#define SDL_PROCESS_DUMMY 1
#define SDL_LOADSO_DUMMY 1
#define SDL_VIDEO_DISABLED 1
#define SDL_CAMERA_DISABLED 1
#define SDL_DIALOG_DISABLED 1
#define SDL_FILESYSTEM_DUMMY 1
#define SDL_FSOPS_DUMMY 1
#define SDL_GPU_DISABLED 1
#define SDL_RENDER_DISABLED 1
#define SDL_POWER_DISABLED 1
#define SDL_LEAN_AND_MEAN 1
// Windows defines
#if defined(SDL_PLATFORM_WINDOWS)
#define SDL_PLATFORM_PRIVATE_NAME "Windows"
#define HAVE_LIBC 1
#define HAVE_DINPUT_H 1
#define HAVE_XINPUT_H 1
#if defined(_WIN32_MAXVER) && _WIN32_MAXVER >= 0x0A00 /* Windows 10 SDK */
#define HAVE_WINDOWS_GAMING_INPUT_H 1
#define SDL_JOYSTICK_WGI 1
#endif
#define SDL_JOYSTICK_DINPUT 1
#define SDL_JOYSTICK_HIDAPI 1
#define SDL_JOYSTICK_RAWINPUT 1
#define SDL_JOYSTICK_XINPUT 1
#define SDL_HAPTIC_DINPUT 1
#define SDL_THREAD_GENERIC_COND_SUFFIX 1
#define SDL_THREAD_GENERIC_RWLOCK_SUFFIX 1
#define SDL_THREAD_WINDOWS 1
#define SDL_TIMER_WINDOWS 1
#define SDL_SENSOR_WINDOWS 1
// Linux defines
#elif defined(SDL_PLATFORM_LINUX)
#define SDL_PLATFORM_PRIVATE_NAME "Linux"
#define SDL_PLATFORM_UNIX 1
#define HAVE_STDIO_H 1
#define HAVE_LIBC 1
#define HAVE_LINUX_INPUT_H 1
#define HAVE_POLL 1
#ifdef __linux__
#define HAVE_INOTIFY 1
#define HAVE_INOTIFY_INIT1 1
// Don't add these defines, for some reason they mess with C#'s ability
// to use environment variables (see GH-109024)
//#define HAVE_GETENV 1
//#define HAVE_SETENV 1
//#define HAVE_UNSETENV 1
#endif
#ifdef DBUS_ENABLED
#define HAVE_DBUS_DBUS_H 1
#define SDL_USE_LIBDBUS 1
// SOWRAP_ENABLED is handled in thirdparty/sdl/core/linux/SDL_dbus.c
#endif
#ifdef UDEV_ENABLED
#define HAVE_LIBUDEV_H 1
#define SDL_USE_LIBUDEV
#ifdef SOWRAP_ENABLED
#define SDL_UDEV_DYNAMIC "libudev.so.1"
#endif
#endif
#define SDL_LOADSO_DLOPEN 1
#define SDL_HAPTIC_LINUX 1
#define SDL_TIMER_UNIX 1
#define SDL_JOYSTICK_LINUX 1
#define SDL_JOYSTICK_HIDAPI 1
#define SDL_INPUT_LINUXEV 1
#define SDL_THREAD_PTHREAD 1
// macOS defines
#elif defined(SDL_PLATFORM_MACOS)
#define SDL_PLATFORM_PRIVATE_NAME "macOS"
#define SDL_PLATFORM_UNIX 1
#define HAVE_STDIO_H 1
#define HAVE_STDLIB_H 1
#define HAVE_LIBC 1
#define SDL_HAPTIC_IOKIT 1
#define SDL_JOYSTICK_IOKIT 1
#define SDL_JOYSTICK_MFI 1
#define SDL_JOYSTICK_HIDAPI 1
#define SDL_TIMER_UNIX 1
#define SDL_THREAD_PTHREAD 1
#define SDL_THREAD_PTHREAD_RECURSIVE_MUTEX 1
// iOS/visionOS defines
#elif defined(SDL_PLATFORM_IOS) || defined(SDL_PLATFORM_VISIONOS)
#ifdef SDL_PLATFORM_IOS
#define SDL_PLATFORM_PRIVATE_NAME "iOS"
#else
#define SDL_PLATFORM_PRIVATE_NAME "visionOS"
#endif
#define SDL_PLATFORM_UNIX 1
#define HAVE_STDIO_H 1
#define HAVE_STDLIB_H 1
#define HAVE_LIBC 1
#define SDL_JOYSTICK_MFI 1
#define SDL_HAPTIC_DUMMY 1
#define SDL_TIMER_UNIX 1
#define SDL_THREAD_PTHREAD 1
#define SDL_MAIN_HANDLED 1
// Other platforms are not supported (for now)
#else
#error "No SDL build config was found for this platform. Setup one before compiling the engine."
#endif
#if !defined(HAVE_STDINT_H) && !defined(_STDINT_H_)
#define HAVE_STDINT_H 1
#endif /* !_STDINT_H_ && !HAVE_STDINT_H */
#ifdef __GNUC__
#define HAVE_GCC_SYNC_LOCK_TEST_AND_SET 1
#endif