Skip to content

Commit

Permalink
[brief] More CI fixes.
Browse files Browse the repository at this point in the history
[detailed]
- Removes the duplicate key from the presets file.
- Fixes the name of the runs so they're easier to tell apart.
- Ensures the builds for the dependencies on Linux only build with GCC
  instead of being built with both Clang and GCC.
  • Loading branch information
marovira committed Sep 8, 2024
1 parent 0853ca4 commit 83919f3
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
11 changes: 6 additions & 5 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ jobs:
format:
uses: ./.github/workflows/clang-format.yml
build:
name: ${{ matrix.config.os }}-${{ matrix.config.preset }}
name: ${{ matrix.config.os }}-${{ matrix.config.preset }}-${{ matrix.build }}
runs-on: ${{ matrix.config.os }}
needs: format
strategy:
Expand All @@ -35,7 +35,7 @@ jobs:
config:
- {os: "windows-latest", cxx: "msvc", cc: "msvc", preset: "msvc"}
- {os: "ubuntu-24.04", cxx: "clang++-18", cc: "clang-18", preset: "clang"}
- {os: "ubuntu-24.04", cxx: "gcc-14", cc: "gcc-14", preset: "gcc"}
- {os: "ubuntu-24.04", cxx: "g++-14", cc: "gcc-14", preset: "gcc"}
build: ["Debug", "Release"]
steps:
- name: Chekout
Expand All @@ -54,17 +54,18 @@ jobs:
path: ~/deps
key: deps_${{ matrix.config.os }}_${{ matrix.build }}_${{ hashfiles('dependencies.txt') }}

- name: Install dependencies
- name: Build dependencies
if: steps.cache-deps.outputs.cache-hit != 'true'
shell: bash
env:
CC: ${{ matrix.config.cc }}
CXX: ${{ matrix.config.cxx }}
BUILD_TYPE: ${{ matrix.build }}
run: |
if [[ "$OSTYPE" == "msys" ]]; then
python tools/build_dependencies.py ~/deps $BUILD_TYPE
else
# Clang and GCC binaries are compatible, so only compile with GCC.
export CC="gcc-14"
export CXX="g++-14"
python3 tools/build_dependencies.py ~/deps $BUILD_TYPE
fi
Expand Down
1 change: 0 additions & 1 deletion CMakePresets.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@
"name": "unix_base",
"hidden": true,
"generator": "Unix Makefiles",
"generator": "Unix Makefiles",
"binaryDir": "${sourceDir}/build",
"cacheVariables": {
"CMAKE_CXX_STANDARD": "20",
Expand Down

0 comments on commit 83919f3

Please sign in to comment.