mirror of
https://github.com/serge1/ELFIO.git
synced 2024-12-27 12:17:28 +00:00
Add elfio_fuzzer to tests' compilation
This commit is contained in:
parent
9d6984a59b
commit
ef2fa127c0
@ -54,6 +54,25 @@ add_test(
|
||||
WORKING_DIRECTORY
|
||||
${CMAKE_CURRENT_BINARY_DIR})
|
||||
|
||||
if(CMAKE_CXX_COMPILER_ID STREQUAL "Clang")
|
||||
add_executable(
|
||||
elfio_fuzzer
|
||||
elfio_fuzzer.cpp)
|
||||
|
||||
target_link_libraries(
|
||||
elfio_fuzzer
|
||||
PRIVATE
|
||||
elfio::elfio)
|
||||
|
||||
target_compile_options(elfio_fuzzer
|
||||
PRIVATE $<$<C_COMPILER_ID:Clang>:-g -O1 -fsanitize=fuzzer>
|
||||
)
|
||||
|
||||
target_link_libraries(elfio_fuzzer
|
||||
PRIVATE $<$<C_COMPILER_ID:Clang>:-fsanitize=fuzzer>
|
||||
)
|
||||
endif()
|
||||
|
||||
add_dependencies(check ELFIOTest)
|
||||
|
||||
include(GoogleTest)
|
||||
|
Loading…
Reference in New Issue
Block a user