File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -32,8 +32,16 @@ if(NOT SDL3_FOUND OR NOT SDL3_image_FOUND)
3232 URL_HASH SHA256=2ceb75eab4235c2c7e93dafc3ef3268ad368ca5de40892bf8cffdd510f29d9d8
3333 )
3434
35- FetchContent_MakeAvailable (SDL3)
36- FetchContent_MakeAvailable (SDL3_image)
35+ # Official SDL configuration for a unified build tree
36+ set (SDL_SHARED ON CACHE BOOL "" FORCE )
37+ set (SDL_STATIC OFF CACHE BOOL "" FORCE )
38+ set (SDLIMAGE_VENDORED ON CACHE BOOL "" FORCE )
39+ set (SDLIMAGE_ZLIB ON CACHE BOOL "" FORCE )
40+ set (SDLIMAGE_PNG ON CACHE BOOL "" FORCE )
41+ set (SDLIMAGE_APNG ON CACHE BOOL "" FORCE )
42+
43+ # Making them available in order ensures SDL3_image can see the SDL3 targets
44+ FetchContent_MakeAvailable (SDL3 SDL3_image)
3745endif ()
3846
3947# Uniform aliases to ensure linking works across both discovery methods
You can’t perform that action at this time.
0 commit comments