From fbc054d999c0033a5caad428a50aff033aa68059 Mon Sep 17 00:00:00 2001 From: JiXieShi Date: Sat, 21 Sep 2024 16:53:04 +0800 Subject: [PATCH] SDL2 UP to SDL3 --- .gitmodules | 5 ++--- CMakeLists.txt | 4 +++- SDL2 | 1 - SDL3 | 1 + 4 files changed, 6 insertions(+), 5 deletions(-) delete mode 160000 SDL2 create mode 160000 SDL3 diff --git a/.gitmodules b/.gitmodules index 74474c3..3ea2ff4 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,4 +1,3 @@ -[submodule "SDL2"] - path = SDL2 +[submodule "SDL3"] + path = SDL3 url = https://github.com/libsdl-org/SDL.git - branch = release-2.30.x diff --git a/CMakeLists.txt b/CMakeLists.txt index f62df26..aa0e06f 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -26,12 +26,14 @@ endforeach () include_directories(easyx/include) link_directories(easyx/lib64) + file(GLOB_RECURSE SOURCES "demo/*/*.*" "sim/*/*.*" "lvgl/src/*/*.*" "lvgl/demos/*/*.*") #file(GLOB_RECURSE SOURCES "demo/tft/*.*" "sim/*/*.*" "lvgl/src/*/*.*") link_libraries(libeasyx.a libgdi32.a libole32.a) add_executable(HW_Lib main.c ${SOURCES}) - +add_subdirectory(SDL3 EXCLUDE_FROM_ALL) +link_libraries(SDL3::SDL3) #导入库 add_subdirectory(lib) target_link_libraries(HW_Lib HW_LIB_List HW_LIB_Task HW_LIB_Printf HW_LIB_Utils HW_LIB_Iic diff --git a/SDL2 b/SDL2 deleted file mode 160000 index 5669b97..0000000 --- a/SDL2 +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 5669b97fd78642b9068d4efa3eeab84098ce8527 diff --git a/SDL3 b/SDL3 new file mode 160000 index 0000000..89c6bc5 --- /dev/null +++ b/SDL3 @@ -0,0 +1 @@ +Subproject commit 89c6bc5f5022e71433a9e4eb1a2edc6d79be71f2