From 08d4bead6d7f83a36a490e7dbd4d30e3552ae827 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Joachim=20K=C3=BChn?= Date: Mon, 16 Dec 2024 20:53:44 +0100 Subject: [PATCH 1/5] updated actions --- .github/actions/build/action.yml | 10 +++++----- .github/actions/test/action.yml | 6 +++--- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/.github/actions/build/action.yml b/.github/actions/build/action.yml index 915c883a..606bf824 100644 --- a/.github/actions/build/action.yml +++ b/.github/actions/build/action.yml @@ -6,15 +6,15 @@ runs: shell: bash run: | sudo apt-get -qq update - sudo apt-get -qq install gcc-11 - sudo apt-get -qq -y install g++-11 + sudo apt-get -qq install gcc-12 + sudo apt-get -qq -y install g++-12 sudo apt-get -qq -y install lcov - name: Build shell: # ensure that the installed compiler version is used run: | - export CC=/usr/bin/gcc-11 - export CXX=/usr/bin/g++-11 + export CC=/usr/bin/gcc-12 + export CXX=/usr/bin/g++-12 mkdir build && cd build cmake -DCMAKE_BUILD_TYPE=Debug -DGMGPOLAR_TEST_COVERAGE=ON .. make -j4 @@ -23,7 +23,7 @@ runs: run: | tar -czf build.tar.gz build - name: Upload build dir archive - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: build-cpp-linux-gmgpolar path: build.tar.gz diff --git a/.github/actions/test/action.yml b/.github/actions/test/action.yml index c4dbe781..68f30bc8 100644 --- a/.github/actions/test/action.yml +++ b/.github/actions/test/action.yml @@ -15,7 +15,7 @@ runs: sudo apt-get -qq -y install lcov sudo apt-get -qq update - name: Download build test directory - uses: actions/download-artifact@v3 + uses: actions/download-artifact@v4 with: name: ${{ inputs.build-artifact }} - name: extract build archive @@ -37,14 +37,14 @@ runs: cd build cmake --build . --target coverage/fast - name: Upload test report - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: test-report path: build/tests/testreport.xml if-no-files-found: error retention-days: 3 - name: Upload coverage reports - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: test-coverage-reports path: | From 0c50aed7f9ec2b069f55f9ad15ff42ca5c5a49b8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Joachim=20K=C3=BChn?= Date: Mon, 16 Dec 2024 21:14:09 +0100 Subject: [PATCH 2/5] gcov version --- .github/actions/test/action.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/actions/test/action.yml b/.github/actions/test/action.yml index 68f30bc8..915d9002 100644 --- a/.github/actions/test/action.yml +++ b/.github/actions/test/action.yml @@ -35,7 +35,7 @@ runs: # compute code coverage run: | cd build - cmake --build . --target coverage/fast + cmake --build . --target coverage/fast --gcov-tool /usr/bin/gcov-12 - name: Upload test report uses: actions/upload-artifact@v4 with: From 5ecb8ac9ac55ce4eaf89dbb6025cef2b00b333d4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Joachim=20K=C3=BChn?= Date: Mon, 16 Dec 2024 21:43:31 +0100 Subject: [PATCH 3/5] gcov --- .github/actions/test/action.yml | 2 +- CMakeLists.txt | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/actions/test/action.yml b/.github/actions/test/action.yml index 915d9002..6dd6712a 100644 --- a/.github/actions/test/action.yml +++ b/.github/actions/test/action.yml @@ -35,7 +35,7 @@ runs: # compute code coverage run: | cd build - cmake --build . --target coverage/fast --gcov-tool /usr/bin/gcov-12 + cmake --build . --target coverage/fast - name: Upload test report uses: actions/upload-artifact@v4 with: diff --git a/CMakeLists.txt b/CMakeLists.txt index 57ca070b..b666baa6 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -23,6 +23,9 @@ option(GMGPOLAR_TEST_COVERAGE "Enable GCov coverage analysis (adds a 'coverage' if(CMAKE_BUILD_TYPE STREQUAL "Debug" OR CMAKE_BUILD_TYPE STREQUAL "DEBUG") if(GMGPOLAR_TEST_COVERAGE) + # importantly, set the path to the gcovr executable + set(GCOVR_PATH "/usr/bin/gcov-12") + message(STATUS "Coverage enabled") include(CodeCoverage) append_coverage_compiler_flags() From 91340874eadc802aa3539bcdf6d1290d61e5803d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Joachim=20K=C3=BChn?= Date: Mon, 16 Dec 2024 22:10:03 +0100 Subject: [PATCH 4/5] updated cmake --- CMakeLists.txt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index b666baa6..236e7d8a 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -23,8 +23,8 @@ option(GMGPOLAR_TEST_COVERAGE "Enable GCov coverage analysis (adds a 'coverage' if(CMAKE_BUILD_TYPE STREQUAL "Debug" OR CMAKE_BUILD_TYPE STREQUAL "DEBUG") if(GMGPOLAR_TEST_COVERAGE) - # importantly, set the path to the gcovr executable - set(GCOVR_PATH "/usr/bin/gcov-12") + # importantly, set the path to the gcov executable + set(GCOV_PATH "/usr/bin/gcov-12") message(STATUS "Coverage enabled") include(CodeCoverage) @@ -32,7 +32,7 @@ if(CMAKE_BUILD_TYPE STREQUAL "Debug" OR CMAKE_BUILD_TYPE STREQUAL "DEBUG") setup_target_for_coverage_lcov( NAME coverage EXECUTABLE tests/gmgpolar_tests - EXCLUDE "${CMAKE_SOURCE_DIR}/tests*" "${CMAKE_SOURCE_DIR}/src/test_cases*" "${CMAKE_BINARY_DIR}/*" "/usr*" + EXCLUDE "${CMAKE_SOURCE_DIR}/tests*" "${CMAKE_SOURCE_DIR}/src/test_cases*" "${CMAKE_SOURCE_DIR}/include/test_cases*" "${CMAKE_BINARY_DIR}/*" "/usr*" ) endif() endif() From d6fb96e126070adc66f338048bbe37da9694b489 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Joachim=20K=C3=BChn?= Date: Mon, 16 Dec 2024 22:36:46 +0100 Subject: [PATCH 5/5] test gcc13 --- .github/actions/build/action.yml | 8 ++++---- CMakeLists.txt | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/.github/actions/build/action.yml b/.github/actions/build/action.yml index 606bf824..fee50fc8 100644 --- a/.github/actions/build/action.yml +++ b/.github/actions/build/action.yml @@ -6,15 +6,15 @@ runs: shell: bash run: | sudo apt-get -qq update - sudo apt-get -qq install gcc-12 - sudo apt-get -qq -y install g++-12 + sudo apt-get -qq install gcc-13 + sudo apt-get -qq -y install g++-13 sudo apt-get -qq -y install lcov - name: Build shell: # ensure that the installed compiler version is used run: | - export CC=/usr/bin/gcc-12 - export CXX=/usr/bin/g++-12 + export CC=/usr/bin/gcc-13 + export CXX=/usr/bin/g++-13 mkdir build && cd build cmake -DCMAKE_BUILD_TYPE=Debug -DGMGPOLAR_TEST_COVERAGE=ON .. make -j4 diff --git a/CMakeLists.txt b/CMakeLists.txt index 236e7d8a..8404e0a0 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -24,7 +24,7 @@ option(GMGPOLAR_TEST_COVERAGE "Enable GCov coverage analysis (adds a 'coverage' if(CMAKE_BUILD_TYPE STREQUAL "Debug" OR CMAKE_BUILD_TYPE STREQUAL "DEBUG") if(GMGPOLAR_TEST_COVERAGE) # importantly, set the path to the gcov executable - set(GCOV_PATH "/usr/bin/gcov-12") + set(GCOV_PATH "/usr/bin/gcov-13") message(STATUS "Coverage enabled") include(CodeCoverage)