mirror of
https://github.com/libsdl-org/SDL.git
synced 2025-09-16 08:18:13 +00:00
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:
@@ -27,9 +27,6 @@
|
||||
|
||||
#include <unistd.h>
|
||||
|
||||
#include "SDL_error.h"
|
||||
#include "SDL_filesystem.h"
|
||||
#include "SDL_system.h"
|
||||
|
||||
|
||||
char *
|
||||
|
@@ -29,9 +29,6 @@
|
||||
#include <sys/stat.h>
|
||||
#include <sys/types.h>
|
||||
|
||||
#include "SDL_error.h"
|
||||
#include "SDL_stdinc.h"
|
||||
#include "SDL_filesystem.h"
|
||||
|
||||
char *
|
||||
SDL_GetBasePath(void)
|
||||
|
@@ -25,8 +25,6 @@
|
||||
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
|
||||
/* System dependent filesystem routines */
|
||||
|
||||
#include "SDL_error.h"
|
||||
#include "SDL_filesystem.h"
|
||||
|
||||
char *
|
||||
SDL_GetBasePath(void)
|
||||
|
@@ -27,8 +27,6 @@
|
||||
#include <errno.h>
|
||||
#include <sys/stat.h>
|
||||
|
||||
#include "SDL_error.h"
|
||||
#include "SDL_filesystem.h"
|
||||
|
||||
#include <emscripten/emscripten.h>
|
||||
|
||||
|
@@ -30,9 +30,6 @@
|
||||
#include <storage/Entry.h>
|
||||
#include <storage/Path.h>
|
||||
|
||||
#include "SDL_error.h"
|
||||
#include "SDL_stdinc.h"
|
||||
#include "SDL_filesystem.h"
|
||||
|
||||
char *
|
||||
SDL_GetBasePath(void)
|
||||
|
@@ -29,8 +29,6 @@
|
||||
#include <dirent.h>
|
||||
#include <errno.h>
|
||||
|
||||
#include "SDL_error.h"
|
||||
#include "SDL_filesystem.h"
|
||||
|
||||
SDL_FORCE_INLINE char *MakePrefPath(const char *app);
|
||||
SDL_FORCE_INLINE int CreatePrefPathDir(const char *pref);
|
||||
|
@@ -28,8 +28,6 @@
|
||||
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
|
||||
/* System dependent filesystem routines */
|
||||
|
||||
#include "SDL_error.h"
|
||||
#include "SDL_filesystem.h"
|
||||
|
||||
char *
|
||||
SDL_GetBasePath(void)
|
||||
|
@@ -28,8 +28,6 @@
|
||||
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
|
||||
/* System dependent filesystem routines */
|
||||
|
||||
#include "SDL_error.h"
|
||||
#include "SDL_filesystem.h"
|
||||
|
||||
char *
|
||||
SDL_GetBasePath(void)
|
||||
|
@@ -29,9 +29,6 @@
|
||||
#include <swis.h>
|
||||
#include <unixlib/local.h>
|
||||
|
||||
#include "SDL_error.h"
|
||||
#include "SDL_stdinc.h"
|
||||
#include "SDL_filesystem.h"
|
||||
|
||||
/* Wrapper around __unixify_std that uses SDL's memory allocators */
|
||||
static char *
|
||||
|
@@ -38,10 +38,6 @@
|
||||
#include <sys/sysctl.h>
|
||||
#endif
|
||||
|
||||
#include "SDL_error.h"
|
||||
#include "SDL_stdinc.h"
|
||||
#include "SDL_filesystem.h"
|
||||
#include "SDL_rwops.h"
|
||||
|
||||
static char *
|
||||
readSymLink(const char *path)
|
||||
|
@@ -34,10 +34,6 @@
|
||||
#include <limits.h>
|
||||
#include <fcntl.h>
|
||||
|
||||
#include "SDL_error.h"
|
||||
#include "SDL_stdinc.h"
|
||||
#include "SDL_filesystem.h"
|
||||
#include "SDL_rwops.h"
|
||||
|
||||
char *
|
||||
SDL_GetBasePath(void)
|
||||
|
@@ -28,9 +28,6 @@
|
||||
#include "../../core/windows/SDL_windows.h"
|
||||
#include <shlobj.h>
|
||||
|
||||
#include "SDL_error.h"
|
||||
#include "SDL_stdinc.h"
|
||||
#include "SDL_filesystem.h"
|
||||
|
||||
char *
|
||||
SDL_GetBasePath(void)
|
||||
@@ -173,8 +170,6 @@ SDL_GetPrefPath(const char *org, const char *app)
|
||||
#endif /* SDL_FILESYSTEM_WINDOWS */
|
||||
|
||||
#ifdef SDL_FILESYSTEM_XBOX
|
||||
#include "SDL_filesystem.h"
|
||||
#include "SDL_error.h"
|
||||
char *
|
||||
SDL_GetBasePath(void)
|
||||
{
|
||||
|
@@ -26,11 +26,6 @@
|
||||
#ifdef __WINRT__
|
||||
|
||||
extern "C" {
|
||||
#include "SDL_filesystem.h"
|
||||
#include "SDL_error.h"
|
||||
#include "SDL_hints.h"
|
||||
#include "SDL_stdinc.h"
|
||||
#include "SDL_system.h"
|
||||
#include "../../core/windows/SDL_windows.h"
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user