From 4aef199643ba95e4b1650aa23f4533c6bc66a503 Mon Sep 17 00:00:00 2001 From: Enrico Seiler Date: Mon, 29 Jan 2024 14:27:45 +0100 Subject: [PATCH] [INFRA] Remove benchmark --- .github/workflows/ci_coverage.yml | 2 +- .github/workflows/ci_linux.yml | 2 +- .github/workflows/ci_macos.yml | 2 +- cmake/package-lock.cmake | 10 ---------- test/CMakeLists.txt | 11 ----------- test/benchmark/README.md | 6 ------ test/header/CMakeLists.txt | 5 +++-- test/header/dummy_include/benchmark/benchmark.h | 1 - 8 files changed, 6 insertions(+), 33 deletions(-) delete mode 100644 test/benchmark/README.md delete mode 100644 test/header/dummy_include/benchmark/benchmark.h diff --git a/.github/workflows/ci_coverage.yml b/.github/workflows/ci_coverage.yml index dd53966..92d469d 100644 --- a/.github/workflows/ci_coverage.yml +++ b/.github/workflows/ci_coverage.yml @@ -64,7 +64,7 @@ jobs: mkdir build cd build cmake .. -DCMAKE_BUILD_TYPE=${{ matrix.build_type }} - make -j2 gtest_main benchmark_main yaml-cpp + make -j2 gtest_main yaml-cpp - name: Build tests env: diff --git a/.github/workflows/ci_linux.yml b/.github/workflows/ci_linux.yml index 30a9739..d6505a1 100644 --- a/.github/workflows/ci_linux.yml +++ b/.github/workflows/ci_linux.yml @@ -71,7 +71,7 @@ jobs: cd build cmake .. -DCMAKE_BUILD_TYPE=${{ matrix.build_type }} \ -DCMAKE_CXX_FLAGS="${{ matrix.cxx_flags }}" - make -j2 gtest_main benchmark_main yaml-cpp + make -j2 gtest_main yaml-cpp - name: Build application run: | diff --git a/.github/workflows/ci_macos.yml b/.github/workflows/ci_macos.yml index d2be181..c9c9a7e 100644 --- a/.github/workflows/ci_macos.yml +++ b/.github/workflows/ci_macos.yml @@ -71,7 +71,7 @@ jobs: cd build cmake .. -DCMAKE_BUILD_TYPE=${{ matrix.build_type }} \ -DCMAKE_CXX_FLAGS="${{ matrix.cxx_flags }}" - make -j3 gtest_main benchmark_main yaml-cpp + make -j3 gtest_main yaml-cpp - name: Build application run: | diff --git a/cmake/package-lock.cmake b/cmake/package-lock.cmake index 9774342..c660b75 100644 --- a/cmake/package-lock.cmake +++ b/cmake/package-lock.cmake @@ -35,16 +35,6 @@ CPMDeclarePackage (seqan3 SYSTEM TRUE OPTIONS "INSTALL_SEQAN3 OFF" "CMAKE_MESSAGE_LOG_LEVEL WARNING" ) -# benchmark -set (BENCHMARK_VERSION 1.8.3) -CPMDeclarePackage (benchmark - NAME benchmark - VERSION ${BENCHMARK_VERSION} - GITHUB_REPOSITORY google/benchmark - SYSTEM TRUE - OPTIONS "BENCHMARK_ENABLE_TESTING OFF" "BENCHMARK_ENABLE_WERROR OFF" - "CMAKE_MESSAGE_LOG_LEVEL WARNING" -) # googletest set (GOOGLETEST_VERSION 1.14.0) CPMDeclarePackage (googletest diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt index c15d490..7acf321 100644 --- a/test/CMakeLists.txt +++ b/test/CMakeLists.txt @@ -1,15 +1,5 @@ cmake_minimum_required (VERSION 3.16) -# CMake sometimes has trouble detecting pthreads on macOS, so we just assume a built-in pthreads. -if (APPLE) - set (CMAKE_THREAD_LIBS_INIT "-lpthread") - set (CMAKE_HAVE_THREADS_LIBRARY 1) - set (CMAKE_USE_WIN32_THREADS_INIT 0) - set (CMAKE_USE_PTHREADS_INIT 1) - set (THREADS_PREFER_PTHREAD_FLAG ON) -endif () - -CPMGetSystemPackage (benchmark) CPMGetSystemPackage (googletest) include (GoogleTest OPTIONAL) @@ -45,7 +35,6 @@ if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU") endif () target_link_libraries (${PROJECT_NAME}_test INTERFACE "${PROJECT_NAME}_lib" "GTest::gtest_main" - "benchmark::benchmark_main" ) target_include_directories (${PROJECT_NAME}_test INTERFACE "${seqan3_SOURCE_DIR}/test/include") add_library (${PROJECT_NAME}::test ALIAS ${PROJECT_NAME}_test) diff --git a/test/benchmark/README.md b/test/benchmark/README.md deleted file mode 100644 index b495e29..0000000 --- a/test/benchmark/README.md +++ /dev/null @@ -1,6 +0,0 @@ -# Benchmarks - -Here are test files for benchmarks with respect to time, space consumption and memory. -They are usually based on the command-line interface, but you can also add micro benchmark if you wish. - -The benchmark tests are not yet implemented. diff --git a/test/header/CMakeLists.txt b/test/header/CMakeLists.txt index 9a463a4..3c5359b 100644 --- a/test/header/CMakeLists.txt +++ b/test/header/CMakeLists.txt @@ -5,8 +5,9 @@ include (seqan3_test_component) add_library ("${PROJECT_NAME}_header_test_lib" INTERFACE) target_link_libraries ("${PROJECT_NAME}_header_test_lib" INTERFACE "${PROJECT_NAME}_test") -# SeqAn3 script adds an include for -target_include_directories ("${PROJECT_NAME}_header_test_lib" INTERFACE ./dummy_include) +# SeqAn3 script adds an include for +file (WRITE "${PROJECT_BINARY_DIR}/dummy_include/benchmark/benchmark.h" "#pragma once") +target_include_directories ("${PROJECT_NAME}_header_test_lib" INTERFACE "${PROJECT_BINARY_DIR}/dummy_include") set (target "${PROJECT_NAME}_header_test") set (header_base_path "${CMAKE_CURRENT_LIST_DIR}/../../include/") diff --git a/test/header/dummy_include/benchmark/benchmark.h b/test/header/dummy_include/benchmark/benchmark.h deleted file mode 100644 index 6f70f09..0000000 --- a/test/header/dummy_include/benchmark/benchmark.h +++ /dev/null @@ -1 +0,0 @@ -#pragma once