scylla uses build modes like "debug" and "release" to differentiate different build modes. while we intend to use the typical build configurations / build types used by CMake like "Debug" and "RelWithDebInfo" for naming CMAKE_CONFIGURATION_TYPES and CMAKE_BUILD_TYPE. the former is used for naming the build directory and for the preprocess macro named "SCYLLA_BUILD_MODE". `test.py` and scylladb's CI are designed based on the naming of build directory. in which, `test.py` lists the build modes using the dedicated build target named "list_modes", which is added by `configure.py`. so, in this change, to prepare for adding the target, "scylla_build_mode" is defined, so we can reuse it in a following-up change. Signed-off-by: Kefu Chai <kefu.chai@scylladb.com>
21 lines
460 B
CMake
21 lines
460 B
CMake
set(CMAKE_CXX_FLAGS_DEV
|
|
""
|
|
CACHE
|
|
INTERNAL
|
|
"")
|
|
update_cxx_flags(CMAKE_CXX_FLAGS_DEV
|
|
OPTIMIZATION_LEVEL "2")
|
|
|
|
set(scylla_build_mode "dev")
|
|
set(Seastar_DEFINITIONS_DEV
|
|
SCYLLA_BUILD_MODE=${scylla_build_mode}
|
|
DEVEL
|
|
SEASTAR_ENABLE_ALLOC_FAILURE_INJECTION
|
|
SCYLLA_ENABLE_ERROR_INJECTION)
|
|
foreach(definition ${Seastar_DEFINITIONS_DEV})
|
|
add_compile_definitions(
|
|
$<$<CONFIG:Dev>:${definition}>)
|
|
endforeach()
|
|
|
|
maybe_limit_stack_usage_in_KB(21 Dev)
|