solvespace/exposed/CMakeLists.txt
Maximilian Federle 68b1abf77f CMake: use sanitizer flags for internal targets only
Previously sanitizer flags were set unconditionally for
all code, including that of external libraries.
Set them only for targets in src/, tests/ and exposed/.

Unfortunately, the linker equivalent to add_compile_options,
add_link_options, is only available for CMake version >= 3.13.
So add the sanitizer flags manually to each target's linker options.
2020-10-23 19:39:36 +02:00

12 lines
190 B
CMake

add_compile_options(${SANITIZE_FLAGS})
include_directories(
${CMAKE_SOURCE_DIR}/include)
add_executable(CDemo
CDemo.c)
target_link_libraries(CDemo
slvs
${SANITIZE_FLAGS})