Implement TMX map loading

This commit is contained in:
2024-12-26 20:00:42 +00:00
parent 57a9b20449
commit c0fc016b85
3 changed files with 95 additions and 4 deletions

View File

@@ -4,6 +4,7 @@ project(epec-mcu-emulator LANGUAGES C)
option(TESTS "Build unit tests" ON)
option(WERROR "Treat warnings as errors" OFF)
option(SANITIZERS "Enable memory and undefined behaviour sanitizers" OFF)
set(CMAKE_EXPORT_COMPILE_COMMANDS ON)
@@ -14,6 +15,10 @@ macro(set_default_target_options target)
if (${WERROR})
target_compile_options(${target} PRIVATE -Werror)
endif()
if (${SANITIZERS})
target_compile_options(${target} PRIVATE -fsanitize=memory,undefined)
target_link_options(${target} PRIVATE -fsanitize=memory,undefined)
endif()
endmacro()
add_custom_target(format
@@ -29,6 +34,7 @@ add_custom_target(lint
WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}
)
find_package(LibXml2 REQUIRED)
find_package(SDL2 REQUIRED CONFIG REQUIRED COMPONENTS SDL2 SDL2main)
add_subdirectory(engine)