-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
aa9553e
commit a622b73
Showing
4 changed files
with
24 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,9 @@ | ||
# Code Coverage Configuration | ||
add_library(mc_coverage INTERFACE) | ||
add_library(ra::coverage ALIAS mc_coverage) | ||
add_library(ra_coverage INTERFACE) | ||
add_library(ra::coverage ALIAS ra_coverage) | ||
|
||
if(MC_BUILD_COVERAGE AND CMAKE_CXX_COMPILER_ID MATCHES "GNU|Clang") | ||
target_compile_options(mc_coverage INTERFACE -O0 -g --coverage) | ||
target_link_libraries(mc_coverage INTERFACE --coverage) | ||
target_link_options(mc_coverage INTERFACE --coverage) | ||
target_compile_options(ra_coverage INTERFACE -O0 -g --coverage) | ||
target_link_libraries(ra_coverage INTERFACE --coverage) | ||
target_link_options(ra_coverage INTERFACE --coverage) | ||
endif() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,26 +1,26 @@ | ||
add_library(mc_compiler_options INTERFACE) | ||
add_library(ra::compiler_options ALIAS mc_compiler_options) | ||
add_library(ra_compiler_options INTERFACE) | ||
add_library(ra::compiler_options ALIAS ra_compiler_options) | ||
|
||
if (CMAKE_CXX_COMPILER_ID STREQUAL "MSVC") | ||
target_compile_options(mc_compiler_options INTERFACE "/permissive-") | ||
target_compile_options(ra_compiler_options INTERFACE "/permissive-") | ||
endif() | ||
|
||
if(MC_BUILD_ASAN AND CMAKE_CXX_COMPILER_ID MATCHES "GNU|Clang") | ||
target_compile_options(mc_compiler_options INTERFACE -fsanitize=address -fsanitize-address-use-after-scope -O1 -g -fno-omit-frame-pointer) | ||
target_link_libraries(mc_compiler_options INTERFACE -fsanitize=address -fsanitize-address-use-after-scope -O1 -g -fno-omit-frame-pointer) | ||
target_compile_options(ra_compiler_options INTERFACE -fsanitize=address -fsanitize-address-use-after-scope -O1 -g -fno-omit-frame-pointer) | ||
target_link_libraries(ra_compiler_options INTERFACE -fsanitize=address -fsanitize-address-use-after-scope -O1 -g -fno-omit-frame-pointer) | ||
endif() | ||
|
||
if(MC_BUILD_UBSAN AND CMAKE_CXX_COMPILER_ID MATCHES "GNU|Clang") | ||
target_compile_options(mc_compiler_options INTERFACE -fsanitize=undefined -O1 -g -fno-omit-frame-pointer) | ||
target_link_libraries(mc_compiler_options INTERFACE -fsanitize=undefined -O1 -g -fno-omit-frame-pointer) | ||
target_compile_options(ra_compiler_options INTERFACE -fsanitize=undefined -O1 -g -fno-omit-frame-pointer) | ||
target_link_libraries(ra_compiler_options INTERFACE -fsanitize=undefined -O1 -g -fno-omit-frame-pointer) | ||
endif() | ||
|
||
if(MC_BUILD_MSAN AND CMAKE_CXX_COMPILER_ID MATCHES "GNU|Clang") | ||
target_compile_options(mc_compiler_options INTERFACE -fsanitize=memory -O1 -g -fno-omit-frame-pointer) | ||
target_link_libraries(mc_compiler_options INTERFACE -fsanitize=memory -O1 -g -fno-omit-frame-pointer) | ||
target_compile_options(ra_compiler_options INTERFACE -fsanitize=memory -O1 -g -fno-omit-frame-pointer) | ||
target_link_libraries(ra_compiler_options INTERFACE -fsanitize=memory -O1 -g -fno-omit-frame-pointer) | ||
endif() | ||
|
||
if(MC_BUILD_TSAN AND CMAKE_CXX_COMPILER_ID MATCHES "GNU|Clang") | ||
target_compile_options(mc_compiler_options INTERFACE -fsanitize=thread -O1 -g -fno-omit-frame-pointer) | ||
target_link_libraries(mc_compiler_options INTERFACE -fsanitize=thread -O1 -g -fno-omit-frame-pointer) | ||
target_compile_options(ra_compiler_options INTERFACE -fsanitize=thread -O1 -g -fno-omit-frame-pointer) | ||
target_link_libraries(ra_compiler_options INTERFACE -fsanitize=thread -O1 -g -fno-omit-frame-pointer) | ||
endif() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters