From 660e39a4f40073ff5e7d3ec5845babefe274bb1a Mon Sep 17 00:00:00 2001 From: Ewan Miller Date: Tue, 13 Aug 2024 20:23:59 +0100 Subject: [PATCH 1/4] Give up on trying to get gcc and clang on windows --- .github/workflows/CI-build-and-test.yml | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/.github/workflows/CI-build-and-test.yml b/.github/workflows/CI-build-and-test.yml index b655aca..64d11c4 100644 --- a/.github/workflows/CI-build-and-test.yml +++ b/.github/workflows/CI-build-and-test.yml @@ -23,8 +23,15 @@ jobs: fail-fast: false matrix: OS: [ ubuntu-latest, windows-latest ] - compiler: [ {cpp: g++, c: gcc}, {cpp: clang++, c: clang} ] - + compiler: [ {cpp: g++, c: gcc}, {cpp: clang++, c: clang}, {cpp: cl, c: cl} ] + exclude: + - os: windows-latest + compiler: 0 #gcc + - os: windows-latest + compiler: 1 #clang + - os: ubuntu-latest + compiler: 2 #cl + name: Build & Test ${{ matrix.os }} ${{ matrix.compiler.c }} runs-on: ${{ matrix.os }} From 1c7a3b189900c3fe35f5f9892c66c67b54ee8bd5 Mon Sep 17 00:00:00 2001 From: Ewan Miller Date: Thu, 15 Aug 2024 10:40:26 +0100 Subject: [PATCH 2/4] will this work?? --- .github/workflows/CI-build-and-test.yml | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/.github/workflows/CI-build-and-test.yml b/.github/workflows/CI-build-and-test.yml index 64d11c4..50a1aa2 100644 --- a/.github/workflows/CI-build-and-test.yml +++ b/.github/workflows/CI-build-and-test.yml @@ -26,11 +26,14 @@ jobs: compiler: [ {cpp: g++, c: gcc}, {cpp: clang++, c: clang}, {cpp: cl, c: cl} ] exclude: - os: windows-latest - compiler: 0 #gcc + compiler.cpp: g++ + compiler.c: gcc - os: windows-latest - compiler: 1 #clang + compiler.cpp: clang++ + compiler.c: clang - os: ubuntu-latest - compiler: 2 #cl + compiler.cpp: cl + compiler.c: cl name: Build & Test ${{ matrix.os }} ${{ matrix.compiler.c }} From d67937a9fdea362e30e9814b7832a377302814c4 Mon Sep 17 00:00:00 2001 From: Ewan Miller Date: Thu, 15 Aug 2024 10:52:19 +0100 Subject: [PATCH 3/4] it did not... will this?? --- .github/workflows/CI-build-and-test.yml | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/.github/workflows/CI-build-and-test.yml b/.github/workflows/CI-build-and-test.yml index 50a1aa2..f7569ae 100644 --- a/.github/workflows/CI-build-and-test.yml +++ b/.github/workflows/CI-build-and-test.yml @@ -22,18 +22,18 @@ jobs: strategy: fail-fast: false matrix: - OS: [ ubuntu-latest, windows-latest ] - compiler: [ {cpp: g++, c: gcc}, {cpp: clang++, c: clang}, {cpp: cl, c: cl} ] - exclude: - - os: windows-latest - compiler.cpp: g++ - compiler.c: gcc - - os: windows-latest - compiler.cpp: clang++ - compiler.c: clang - - os: ubuntu-latest - compiler.cpp: cl - compiler.c: cl + include: + - OS: ubuntu-latest + compiler.cpp: g++ + compiler.c: gcc + + - OS: ubuntu-latest + compiler.cpp: clang++ + compiler.c: clang + + - OS: windows-latest + compiler.cpp: cl + compiler.c: cl name: Build & Test ${{ matrix.os }} ${{ matrix.compiler.c }} From af5268620b3e2bab1cf9f4d5f76a19dc4df3c90f Mon Sep 17 00:00:00 2001 From: Ewan Miller Date: Thu, 15 Aug 2024 10:58:01 +0100 Subject: [PATCH 4/4] not really... maybe now???? --- .github/workflows/CI-build-and-test.yml | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/.github/workflows/CI-build-and-test.yml b/.github/workflows/CI-build-and-test.yml index f7569ae..cbf313f 100644 --- a/.github/workflows/CI-build-and-test.yml +++ b/.github/workflows/CI-build-and-test.yml @@ -24,24 +24,24 @@ jobs: matrix: include: - OS: ubuntu-latest - compiler.cpp: g++ - compiler.c: gcc + cpp_compiler: g++ + c_compiler: gcc - OS: ubuntu-latest - compiler.cpp: clang++ - compiler.c: clang + cpp_compiler: clang++ + c_compiler: clang - OS: windows-latest - compiler.cpp: cl - compiler.c: cl + cpp_compiler: cl + c_compiler: cl - name: Build & Test ${{ matrix.os }} ${{ matrix.compiler.c }} + name: Build & Test ${{ matrix.os }} ${{ matrix.c_compiler }} runs-on: ${{ matrix.os }} env: - CC: ${{ matrix.compiler.c }} - CXX: ${{ matrix.compiler.cpp }} + CC: ${{ matrix.c_compiler }} + CXX: ${{ matrix.cpp_compiler }} steps: # this Action should follow steps to set up Python build environment @@ -93,13 +93,13 @@ jobs: - name: Generate Coverage Report # only need to do this for one combination of OS and compiler - if: ${{ matrix.OS == 'ubuntu-latest' && matrix.compiler.c == 'gcc' }} + if: ${{ matrix.OS == 'ubuntu-latest' && matrix.c_compiler == 'gcc' }} working-directory: ${{github.workspace}}/build run: gcovr --json -o nuTens_coverage.json -r .. -f "../nuTens/*" - name: Upload coverage reports to Codecov # only need to do this for one combination of OS and compiler - if: ${{ matrix.OS == 'ubuntu-latest' && matrix.compiler.c == 'gcc' }} + if: ${{ matrix.OS == 'ubuntu-latest' && matrix.c_compiler == 'gcc' }} uses: codecov/codecov-action@v4.0.1 with: verbose: true