Switch header convention from #include "SDL.h" to #include <SDL3/SDLh>
I ran this script in the include directory:
```sh
sed -i '' -e 's,#include "\(SDL.*\)",#include <SDL3/\1>,' *.h
```
I ran this script in the src directory:
```sh
for i in ../include/SDL3/SDL*.h
do hdr=$(basename $i)
if [ x"$(echo $hdr | egrep 'SDL_main|SDL_name|SDL_test|SDL_syswm|SDL_opengl|SDL_egl|SDL_vulkan')" != x ]; then
find . -type f -exec sed -i '' -e 's,#include "\('$hdr'\)",#include <SDL3/\1>,' {} \;
else
find . -type f -exec sed -i '' -e '/#include "'$hdr'"/d' {} \;
fi
done
```
Fixes https://github.com/libsdl-org/SDL/issues/6575
This commit is contained in:
@@ -24,7 +24,6 @@
|
||||
#ifndef SDL_syshaptic_h_
|
||||
#define SDL_syshaptic_h_
|
||||
|
||||
#include "SDL_haptic.h"
|
||||
|
||||
/* Set up for C function definitions, even when using C++ */
|
||||
#ifdef __cplusplus
|
||||
|
||||
@@ -22,12 +22,9 @@
|
||||
|
||||
#ifdef SDL_HAPTIC_ANDROID
|
||||
|
||||
#include "SDL_timer.h"
|
||||
#include "SDL_syshaptic_c.h"
|
||||
#include "../SDL_syshaptic.h"
|
||||
#include "SDL_haptic.h"
|
||||
#include "../../core/android/SDL_android.h"
|
||||
#include "SDL_joystick.h"
|
||||
#include "../../joystick/SDL_sysjoystick.h" /* For the real SDL_Joystick */
|
||||
#include "../../joystick/android/SDL_sysjoystick_c.h" /* For joystick hwdata */
|
||||
|
||||
|
||||
@@ -22,10 +22,7 @@
|
||||
|
||||
#ifdef SDL_HAPTIC_IOKIT
|
||||
|
||||
#include "SDL_stdinc.h"
|
||||
#include "SDL_haptic.h"
|
||||
#include "../SDL_syshaptic.h"
|
||||
#include "SDL_joystick.h"
|
||||
#include "../../joystick/SDL_sysjoystick.h" /* For the real SDL_Joystick */
|
||||
#include "../../joystick/darwin/SDL_iokitjoystick_c.h" /* For joystick hwdata */
|
||||
#include "SDL_syshaptic_c.h"
|
||||
|
||||
@@ -22,7 +22,6 @@
|
||||
|
||||
#if defined(SDL_HAPTIC_DUMMY) || defined(SDL_HAPTIC_DISABLED)
|
||||
|
||||
#include "SDL_haptic.h"
|
||||
#include "../SDL_syshaptic.h"
|
||||
|
||||
|
||||
|
||||
@@ -22,9 +22,7 @@
|
||||
|
||||
#ifdef SDL_HAPTIC_LINUX
|
||||
|
||||
#include "SDL_haptic.h"
|
||||
#include "../SDL_syshaptic.h"
|
||||
#include "SDL_joystick.h"
|
||||
#include "../../joystick/SDL_sysjoystick.h" /* For the real SDL_Joystick */
|
||||
#include "../../joystick/linux/SDL_sysjoystick_c.h" /* For joystick hwdata */
|
||||
#include "../../core/linux/SDL_evdev_capabilities.h"
|
||||
|
||||
@@ -20,16 +20,10 @@
|
||||
*/
|
||||
#include "../../SDL_internal.h"
|
||||
|
||||
#include "SDL.h"
|
||||
#include "SDL_error.h"
|
||||
#include "SDL_haptic.h"
|
||||
#include "../SDL_syshaptic.h"
|
||||
|
||||
#if SDL_HAPTIC_DINPUT
|
||||
|
||||
#include "SDL_hints.h"
|
||||
#include "SDL_stdinc.h"
|
||||
#include "SDL_timer.h"
|
||||
#include "SDL_windowshaptic_c.h"
|
||||
#include "SDL_dinputhaptic_c.h"
|
||||
#include "../../joystick/windows/SDL_windowsjoystick_c.h"
|
||||
|
||||
@@ -20,7 +20,6 @@
|
||||
*/
|
||||
#include "../../SDL_internal.h"
|
||||
|
||||
#include "SDL_haptic.h"
|
||||
#include "SDL_windowshaptic_c.h"
|
||||
|
||||
/* Set up for C function definitions, even when using C++ */
|
||||
|
||||
@@ -22,13 +22,7 @@
|
||||
|
||||
#if SDL_HAPTIC_DINPUT || SDL_HAPTIC_XINPUT
|
||||
|
||||
#include "SDL_thread.h"
|
||||
#include "SDL_mutex.h"
|
||||
#include "SDL_timer.h"
|
||||
#include "SDL_hints.h"
|
||||
#include "SDL_haptic.h"
|
||||
#include "../SDL_syshaptic.h"
|
||||
#include "SDL_joystick.h"
|
||||
#include "../../joystick/SDL_sysjoystick.h" /* For the real SDL_Joystick */
|
||||
#include "../../joystick/windows/SDL_windowsjoystick_c.h" /* For joystick hwdata */
|
||||
#include "../../joystick/windows/SDL_xinputjoystick_c.h" /* For xinput rumble */
|
||||
|
||||
@@ -23,7 +23,6 @@
|
||||
#ifndef SDL_windowshaptic_c_h_
|
||||
#define SDL_windowshaptic_c_h_
|
||||
|
||||
#include "SDL_thread.h"
|
||||
#include "../SDL_syshaptic.h"
|
||||
#include "../../core/windows/SDL_directx.h"
|
||||
#include "../../core/windows/SDL_xinput.h"
|
||||
|
||||
@@ -20,15 +20,10 @@
|
||||
*/
|
||||
#include "../../SDL_internal.h"
|
||||
|
||||
#include "SDL.h"
|
||||
#include "SDL_error.h"
|
||||
#include "SDL_haptic.h"
|
||||
#include "../SDL_syshaptic.h"
|
||||
|
||||
#if SDL_HAPTIC_XINPUT
|
||||
|
||||
#include "SDL_hints.h"
|
||||
#include "SDL_timer.h"
|
||||
#include "SDL_windowshaptic_c.h"
|
||||
#include "SDL_xinputhaptic_c.h"
|
||||
#include "../../core/windows/SDL_xinput.h"
|
||||
|
||||
@@ -20,7 +20,6 @@
|
||||
*/
|
||||
#include "../../SDL_internal.h"
|
||||
|
||||
#include "SDL_haptic.h"
|
||||
#include "SDL_windowshaptic_c.h"
|
||||
|
||||
/* Set up for C function definitions, even when using C++ */
|
||||
|
||||
Reference in New Issue
Block a user