Skip to content

Commit

Permalink
In setup-common action, bump recent-cmake to 3.21
Browse files Browse the repository at this point in the history
Set recent-cmake to true in ci-unix-shared-installed.yml because it sets
-DAVIF_ENABLE_NODISCARD=ON, which needs cmake 3.21 to force C23.
  • Loading branch information
wantehchang committed Aug 1, 2024
1 parent 6b0a47b commit 5e65de6
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
8 changes: 5 additions & 3 deletions .github/actions/setup-common/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,16 +20,18 @@ runs:
uses: actions/setup-python@82c7e631bb3cdc910f68e0081d67478d79c6982d # v5.1.0
with:
python-version: '3.x'
- name: Set up CMake < 3.18
- name: Set up CMake < 3.21
if: ${{ runner.os == 'Linux' && inputs.recent-cmake == 'false' }}
uses: jwlawson/actions-setup-cmake@802fa1a2c4e212495c05bf94dba2704a92a472be # v2.0.2
with:
# The minimum required version of cmake for libavif is 3.13.
cmake-version: '3.13.x'
- name: Set up CMake >= 3.18
- name: Set up CMake >= 3.21
if: ${{ runner.os == 'Linux' && inputs.recent-cmake == 'true' }}
uses: jwlawson/actions-setup-cmake@802fa1a2c4e212495c05bf94dba2704a92a472be # v2.0.2
with:
cmake-version: '3.18.x'
# Need cmake 3.21 to set CMAKE_C_STANDARD to 23 for [[nodiscard]].
cmake-version: '3.21.x'
- name: Print CMake version
run: cmake --version
shell: bash
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/ci-unix-shared-installed.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ jobs:
gcc-version: ${{ matrix.gcc }}
gtest: 'SYSTEM'
libyuv: 'SYSTEM'
recent-cmake: 'true'
- uses: ./.github/actions/setup-macos
if: runner.os == 'macOS'
with:
Expand Down

0 comments on commit 5e65de6

Please sign in to comment.