Commit 159a8b45 authored by incardon's avatar incardon

Fixing compilation with test coverage

parent 25d1505d
Pipeline #1035 failed with stages
in 11 seconds
......@@ -13,9 +13,9 @@ add_library(ofpmmemory_se2 STATIC memory/HeapMemory.cpp memory/PtrMemory.cpp Mem
target_compile_definitions(ofpmmemory_se2 PUBLIC SE_CLASS2)
if ( CMAKE_COMPILER_IS_GNUCC )
target_compile_options(pdata PRIVATE "-Wno-deprecated-declarations")
target_compile_options(mem PRIVATE "-Wno-deprecated-declarations")
if (TEST_COVERAGE)
target_compile_options(pdata PRIVATE $<$<COMPILE_LANGUAGE:CXX>: -fprofile-arcs -ftest-coverage>)
target_compile_options(mem PRIVATE $<$<COMPILE_LANGUAGE:CXX>: -fprofile-arcs -ftest-coverage>)
endif()
endif()
......@@ -23,7 +23,7 @@ endif()
if (CUDA_FOUND)
target_compile_options(mem PUBLIC $<$<COMPILE_LANGUAGE:CUDA>:-Xcudafe "--display_error_number --diag_suppress=2885 --diag_suppress=2887 --diag_suppress=2888 --diag_suppress=186 --diag_suppress=111" --expt-extended-lambda>)
if (TEST_COVERAGE)
target_compile_options(pdata PRIVATE $<$<COMPILE_LANGUAGE:CUDA>: -Xcompiler "-fprofile-arcs -ftest-coverage">)
target_compile_options(mem PRIVATE $<$<COMPILE_LANGUAGE:CUDA>: -Xcompiler "-fprofile-arcs -ftest-coverage">)
endif()
endif()
......@@ -42,7 +42,7 @@ target_include_directories (ofpmmemory_se2 PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}/co
target_link_libraries(mem ${Boost_LIBRARIES})
if (TEST_COVERAGE)
target_link_libraries(pdata -lgcov --coverage)
target_link_libraries(mem -lgcov --coverage)
endif()
install(TARGETS ofpmmemory ofpmmemory_se2
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment