diff --git a/CMakeLists.txt b/CMakeLists.txt index 8cd30ab3..fe1b7ab7 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -20,6 +20,7 @@ endif () option(ANTARA_BUILD_DOCS "Enable to build the documentation" OFF) option(USE_SFML_ANTARA_WRAPPER "Use SFML antara wrapper" OFF) +option(USE_SDL_ANTARA_WRAPPER "Use SDL antara wrapper" OFF) option(USE_LUA_ANTARA_WRAPPER "Use LUA antara wrapper" OFF) option(USE_BOX2D_ANTARA_WRAPPER "Use Box2D antara wrapper" OFF) set(CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/cmake) diff --git a/cmake/dependencies.cmake b/cmake/dependencies.cmake index 412bce54..612c5ece 100644 --- a/cmake/dependencies.cmake +++ b/cmake/dependencies.cmake @@ -75,11 +75,22 @@ if (USE_SFML_ANTARA_WRAPPER) ) endif () +if (USE_SDL_ANTARA_WRAPPER) + FetchContent_Declare( + sdl + URL https://github.com/SDL-mirror/SDL/archive/release-2.0.10.zip + ) +endif() + FetchContent_MakeAvailable(doctest entt doom_st expected range-v3 refl-cpp doom_meta nlohmann_json joboccara-pipes) if (USE_SFML_ANTARA_WRAPPER) FetchContent_MakeAvailable(SFML) endif () +if (USE_SDL_ANTARA_WRAPPER) + FetchContent_MakeAvailable(sdl) +endif() + add_library(nlohmann_json INTERFACE) target_include_directories(nlohmann_json INTERFACE ${nlohmann_json_SOURCE_DIR}) add_library(nlohmann_json::nlohmann_json ALIAS nlohmann_json)