From db3ee5d62be4d314e176e5bc11a6b90f998ee16a Mon Sep 17 00:00:00 2001 From: Sam Lantinga Date: Mon, 8 Dec 2025 08:15:12 -0800 Subject: [PATCH] Enable building the tests by default A common use case is asking someone to clone SDL and run a test. This simplifies the instructions so we don't also have to tell them how to enable the tests. Anyone savvy can just add -DSDL_TESTS=OFF if they don't want to have them. --- CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 88c07c86bf..3431b39e00 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -393,7 +393,7 @@ cmake_dependent_option(SDL_SHARED "Build a shared version of the library" ${SDL_ cmake_dependent_option(SDL_STATIC "Build a static version of the library" ${SDL_STATIC_DEFAULT} ${SDL_STATIC_AVAILABLE} OFF) option(SDL_TEST_LIBRARY "Build the SDL3_test library" ON) -dep_option(SDL_TESTS "Build the test directory" OFF SDL_TEST_LIBRARY OFF) +dep_option(SDL_TESTS "Build the test directory" ON SDL_TEST_LIBRARY OFF) dep_option(SDL_INSTALL_TESTS "Install test-cases" OFF "SDL_INSTALL;NOT SDL_FRAMEWORK" OFF) dep_option(SDL_TESTS_LINK_SHARED "link tests to shared SDL library" "${SDL_SHARED}" "SDL_SHARED;SDL_STATIC" "${SDL_SHARED}") set(SDL_TESTS_TIMEOUT_MULTIPLIER "1" CACHE STRING "Timeout multiplier to account for really slow machines")