1 parent 022f44e commit f841159Copy full SHA for f841159
1 file changed
CMakeLists.txt
@@ -23,6 +23,11 @@ target_include_directories(microtimer
23
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>
24
$<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}>)
25
26
+string(REGEX MATCHALL "-fsanitize=[^ ]+" MICROTIMER_SANITIZER_FLAGS "${CMAKE_C_FLAGS}")
27
+if(MICROTIMER_SANITIZER_FLAGS)
28
+ target_link_options(microtimer INTERFACE ${MICROTIMER_SANITIZER_FLAGS})
29
+endif()
30
+
31
set_target_properties(microtimer PROPERTIES
32
EXPORT_NAME microtimer
33
VERSION ${PROJECT_VERSION}
0 commit comments