diff --git a/cmake/RMVLCompilerOptions.cmake b/cmake/RMVLCompilerOptions.cmake index 1082f722..5a8460d2 100755 --- a/cmake/RMVLCompilerOptions.cmake +++ b/cmake/RMVLCompilerOptions.cmake @@ -260,6 +260,9 @@ endif() option(BUILD_PERF_TESTS "Build performance tests" OFF) if(BUILD_PERF_TESTS) enable_testing() - set(BENCHMARK_ENABLE_TESTING OFF) - rmvl_download(benchmark GIT "https://github.com/google/benchmark.git : v1.8.0") + find_package(benchmark QUIET) + if(NOT benchmark_FOUND) + set(BENCHMARK_ENABLE_TESTING OFF) + rmvl_download(benchmark GIT "https://github.com/google/benchmark.git : v1.8.0") + endif() endif(BUILD_PERF_TESTS) diff --git a/cmake/RMVLModule.cmake b/cmake/RMVLModule.cmake index 37ce9d6a..35c35ffd 100644 --- a/cmake/RMVLModule.cmake +++ b/cmake/RMVLModule.cmake @@ -278,6 +278,8 @@ function(rmvl_add_test test_name test_kind) ${the_target} PRIVATE ${TS_DEPEND_TESTS} ) + + # Add test if("${test_kind_lower}" STREQUAL "unit") gtest_discover_tests( ${the_target} diff --git a/modules/imgproc/perf/perf_pretreat.cpp b/modules/imgproc/perf/perf_pretreat.cpp index 418eaa98..2c04424a 100644 --- a/modules/imgproc/perf/perf_pretreat.cpp +++ b/modules/imgproc/perf/perf_pretreat.cpp @@ -10,8 +10,6 @@ */ #include -#include -#include #include