cmake: exposed TILED_RENDERING option

This was originally added for the use of the libretro
core, figured it should be added to cmake as a compile time
option. Can be triggered when invoking cmake using
-DENABLE_TILEDRENDER=ON

Signed-off-by: Zach Bacon <zachbacon@vba-m.com>
This commit is contained in:
Zach Bacon
2025-04-22 05:39:28 -04:00
parent 9e724ea4b8
commit d297faa25e
2 changed files with 9 additions and 0 deletions

View File

@@ -88,6 +88,10 @@ if(NOT EXISTS "${CMAKE_SOURCE_DIR}/.git")
set(BUILD_TESTING OFF)
endif()
if(ENABLE_TILEDRENDER)
_add_compile_definitions(TILED_RENDERING)
endif()
# Configure gtest
if(BUILD_TESTING)
set(gtest_force_shared_crt ON CACHE BOOL "" FORCE)

View File

@@ -15,9 +15,14 @@ endif()
option(ENABLE_SDL "Build the SDL port" ${ENABLE_SDL_DEFAULT})
option(ENABLE_WX "Build the wxWidgets port" ${BUILD_DEFAULT})
option(ENABLE_TILEDRENDER "Enable tiled renderer" ${BUILD_DEFAULT})
option(ENABLE_DEBUGGER "Enable the debugger" ON)
option(ENABLE_ASAN "Enable -fsanitize=address by default. Requires debug build with GCC/Clang" OFF)
if(ENABLE_TILEDRENDER)
set(ENABLE_TILEDRENDER OFF)
endif()
# Static linking
set(VBAM_STATIC_DEFAULT OFF)
if(VCPKG_TARGET_TRIPLET MATCHES -static OR CMAKE_TOOLCHAIN_FILE MATCHES "mxe|-static")