Allow adding a suffix to the displayed melonDS version

This commit is contained in:
Nadia Holmquist Pedersen
2024-05-11 22:40:45 +02:00
parent 10798c3464
commit c85a2103bb
5 changed files with 14 additions and 5 deletions

View File

@ -52,7 +52,6 @@ add_library(core STATIC
types.h
Utils.cpp
Utils.h
version.h
Wifi.cpp
WifiAP.cpp
@ -123,6 +122,12 @@ if (ENABLE_JIT)
endif()
endif()
set(MELONDS_VERSION_SUFFIX "$ENV{MELONDS_VERSION_SUFFIX}" CACHE STRING "Suffix to add to displayed melonDS version")
configure_file("${CMAKE_CURRENT_SOURCE_DIR}/version.h.in" "${CMAKE_CURRENT_BINARY_DIR}/version.h")
target_sources(core PUBLIC "${CMAKE_CURRENT_BINARY_DIR}/version.h")
target_include_directories(core PUBLIC "${CMAKE_CURRENT_BINARY_DIR}")
add_subdirectory(teakra EXCLUDE_FROM_ALL)
# Workaround for building teakra with -O0 on Windows either failing or hanging forever
target_compile_options(teakra PRIVATE "$<$<CONFIG:DEBUG>:-Og>")