Skip to content

Commit

Permalink
update workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
Sh0g0-1758 committed Nov 7, 2024
1 parent 59d5fa1 commit 14f458f
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 8 deletions.
12 changes: 9 additions & 3 deletions .github/workflows/c-cpp.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,16 +13,22 @@ jobs:
steps:
- uses: actions/checkout@v4

- name: Install dependencies
- name: Install GCC 13 and dependencies
run: |
sudo apt-get update
sudo apt-get install -y cmake build-essential
sudo apt-get install -y software-properties-common
sudo add-apt-repository -y ppa:ubuntu-toolchain-r/test
sudo apt-get update
sudo apt-get install -y gcc-13 g++-13 cmake build-essential nlohmann-json3-dev
- name: Create build directory
run: mkdir build

- name: Configure CMake
working-directory: ./build
env:
CC: gcc-13
CXX: g++-13
run: cmake ..

- name: Build
Expand All @@ -35,4 +41,4 @@ jobs:

- name: Run Speed tests
working-directory: ./build
run: make testSpeed
run: make testSpeed
11 changes: 6 additions & 5 deletions .github/workflows/cmake-multi-platform.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
matrix:
build_type: [Debug, Release]
compiler:
- { cc: gcc, cxx: g++ }
- { cc: gcc-13, cxx: g++-13 }
- { cc: clang, cxx: clang++ }

steps:
Expand All @@ -27,19 +27,20 @@ jobs:
run: |
echo "build-output-dir=${{ github.workspace }}/build" >> "$GITHUB_OUTPUT"
- name: Install dependencies
- name: Install GCC 13 and dependencies
run: |
sudo apt-get update
sudo apt-get install -y cmake build-essential
sudo apt-get install -y software-properties-common
sudo add-apt-repository -y ppa:ubuntu-toolchain-r/test
sudo apt-get update
sudo apt-get install -y gcc-13 g++-13 cmake build-essential nlohmann-json3-dev
- name: Configure CMake
run: >
cmake -B ${{ steps.strings.outputs.build-output-dir }}
-DCMAKE_C_COMPILER=${{ matrix.compiler.cc }}
-DCMAKE_CXX_COMPILER=${{ matrix.compiler.cxx }}
-DCMAKE_BUILD_TYPE=${{ matrix.build_type }}
-DCMAKE_CXX_STANDARD=17
-DCMAKE_CXX_STANDARD_REQUIRED=ON
-S ${{ github.workspace }}
- name: Build
Expand Down

0 comments on commit 14f458f

Please sign in to comment.