Skip to content

Commit e9dec75

Browse files
committed
ci: frozen version of CMake to avoid issues with third-party library CMake projects not compatible with CMake 4.0 (actions/runner-images#11926).
Signed-off-by: Marat Abrarov <[email protected]>
1 parent 21f60fb commit e9dec75

File tree

5 files changed

+42
-1
lines changed

5 files changed

+42
-1
lines changed

.github/workflows/call-build-macos.yaml

+7
Original file line numberDiff line numberDiff line change
@@ -76,8 +76,10 @@ jobs:
7676
config:
7777
- name: "Apple Silicon macOS runner"
7878
runner: macos-14
79+
cmake_version: "3.31.6"
7980
- name: "Intel macOS runner"
8081
runner: macos-14-large
82+
cmake_version: "3.31.6"
8183

8284
steps:
8385
- name: Checkout repository
@@ -90,6 +92,11 @@ jobs:
9092
brew update
9193
brew install bison flex libyaml openssl pkgconfig || true
9294
95+
- name: Install cmake
96+
uses: jwlawson/actions-setup-cmake@v2
97+
with:
98+
cmake-version: "${{ matrix.config.cmake_version }}"
99+
93100
- name: Build Fluent Bit packages
94101
run: |
95102
export LIBRARY_PATH=/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/lib:$LIBRARY_PATH

.github/workflows/call-build-windows.yaml

+4
Original file line numberDiff line numberDiff line change
@@ -85,16 +85,19 @@ jobs:
8585
openssl_dir: C:\vcpkg\packages\openssl_x86-windows-static
8686
cmake_additional_opt: ""
8787
vcpkg_triplet: x86-windows-static
88+
cmake_version: "3.31.6"
8889
- name: "Windows 64bit"
8990
arch: x64
9091
openssl_dir: C:\vcpkg\packages\openssl_x64-windows-static
9192
cmake_additional_opt: ""
9293
vcpkg_triplet: x64-windows-static
94+
cmake_version: "3.31.6"
9395
- name: "Windows 64bit (Arm64)"
9496
arch: amd64_arm64
9597
openssl_dir: C:\vcpkg\packages\openssl_arm64-windows-static
9698
cmake_additional_opt: "-DCMAKE_SYSTEM_NAME=Windows -DCMAKE_SYSTEM_VERSION=10.0 -DCMAKE_SYSTEM_PROCESSOR=ARM64"
9799
vcpkg_triplet: arm64-windows-static
100+
cmake_version: "3.31.6"
98101
permissions:
99102
contents: read
100103
# Default environment variables can be overridden below. To prevent library pollution - without this other random libraries may be found on the path leading to failures.
@@ -113,6 +116,7 @@ jobs:
113116
Copy-Item -Path C:\WinFlexBison/win_bison.exe C:\WinFlexBison/bison.exe
114117
Copy-Item -Path C:\WinFlexBison/win_flex.exe C:\WinFlexBison/flex.exe
115118
echo "C:\WinFlexBison" | Out-File -FilePath $env:GITHUB_PATH -Append
119+
choco install cmake --version "${{ matrix.config.cmake_version }}" --force
116120
env:
117121
WINFLEXBISON: https://github.com/lexxmark/winflexbison/releases/download/v2.5.22/win_flex_bison-2.5.22.zip
118122
shell: pwsh

.github/workflows/call-windows-unit-tests.yaml

+3
Original file line numberDiff line numberDiff line change
@@ -39,11 +39,13 @@ jobs:
3939
openssl_dir: C:\vcpkg\packages\openssl_x86-windows-static
4040
cmake_additional_opt: ""
4141
vcpkg_triplet: x86-windows-static
42+
cmake_version: "3.31.6"
4243
- name: "Windows 64bit"
4344
arch: x64
4445
openssl_dir: C:\vcpkg\packages\openssl_x64-windows-static
4546
cmake_additional_opt: ""
4647
vcpkg_triplet: x64-windows-static
48+
cmake_version: "3.31.6"
4749
permissions:
4850
contents: read
4951
# Default environment variables can be overridden below. To prevent library pollution - without this other random libraries may be found on the path leading to failures.
@@ -62,6 +64,7 @@ jobs:
6264
Copy-Item -Path C:\WinFlexBison/win_bison.exe C:\WinFlexBison/bison.exe
6365
Copy-Item -Path C:\WinFlexBison/win_flex.exe C:\WinFlexBison/flex.exe
6466
echo "C:\WinFlexBison" | Out-File -FilePath $env:GITHUB_PATH -Append
67+
choco install cmake --version "${{ matrix.config.cmake_version }}" --force
6568
env:
6669
WINFLEXBISON: https://github.com/lexxmark/winflexbison/releases/download/v2.5.22/win_flex_bison-2.5.22.zip
6770
shell: pwsh

.github/workflows/pr-compile-check.yaml

+7
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,8 @@ jobs:
4040
matrix:
4141
flb_option:
4242
- "-DFLB_PREFER_SYSTEM_LIBS=On"
43+
cmake_version:
44+
- "3.31.6"
4345
compiler:
4446
- gcc:
4547
cc: gcc
@@ -59,6 +61,11 @@ jobs:
5961
tar --strip-components=1 -xzC /tmp/libbacktrace/ && \
6062
pushd /tmp/libbacktrace/build && ../configure && make && sudo make install && popd
6163
64+
- name: Install cmake
65+
uses: jwlawson/actions-setup-cmake@v2
66+
with:
67+
cmake-version: "${{ matrix.cmake_version }}"
68+
6269
- name: Checkout Fluent Bit code
6370
uses: actions/checkout@v4
6471

.github/workflows/unit-tests.yaml

+21-1
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,8 @@ jobs:
5151
- "-DFLB_SANITIZE_THREAD=On"
5252
- "-DFLB_SIMD=On"
5353
- "-DFLB_SIMD=Off"
54+
cmake_version:
55+
- "3.31.6"
5456
compiler:
5557
- gcc:
5658
cc: gcc
@@ -72,6 +74,11 @@ jobs:
7274
sudo apt-get install -y gcc-7 g++-7 clang-6.0 libsystemd-dev gcovr libyaml-dev libbpf-dev linux-tools-common
7375
sudo ln -s /usr/bin/llvm-symbolizer-6.0 /usr/bin/llvm-symbolizer || true
7476
77+
- name: Install cmake
78+
uses: jwlawson/actions-setup-cmake@v2
79+
with:
80+
cmake-version: "${{ matrix.cmake_version }}"
81+
7582
- uses: actions/checkout@v4
7683

7784
- uses: actions/checkout@v4
@@ -106,9 +113,16 @@ jobs:
106113
- "-DFLB_JEMALLOC=Off"
107114
- "-DFLB_SANITIZE_MEMORY=On"
108115
- "-DFLB_SANITIZE_THREAD=On"
116+
cmake_version:
117+
- "3.31.6"
109118
permissions:
110119
contents: read
111120
steps:
121+
- name: Install cmake
122+
uses: jwlawson/actions-setup-cmake@v2
123+
with:
124+
cmake-version: "${{ matrix.cmake_version }}"
125+
112126
- uses: actions/checkout@v4
113127
- uses: actions/checkout@v4
114128
with:
@@ -144,16 +158,22 @@ jobs:
144158
unit_test_option: "-DFLB_TESTS_INTERNAL=On"
145159
compiler_cc: gcc
146160
compiler_cxx: g++
161+
cmake_version: "3.31.6"
147162
steps:
148163
- name: Checkout Fluent Bit code
149164
uses: actions/checkout@v4
150165

151166
- name: Setup environment
152167
run: |
153168
sudo apt-get update
154-
sudo apt-get install -y gcc-9 g++-9 clang-12 cmake flex bison libsystemd-dev gcovr libyaml-dev libbpf-dev linux-tools-common
169+
sudo apt-get install -y gcc-9 g++-9 clang-12 flex bison libsystemd-dev gcovr libyaml-dev libbpf-dev linux-tools-common
155170
sudo ln -s /usr/bin/llvm-symbolizer-12 /usr/bin/llvm-symbolizer || true
156171
172+
- name: Install cmake
173+
uses: jwlawson/actions-setup-cmake@v2
174+
with:
175+
cmake-version: "${{ matrix.config.cmake_version }}"
176+
157177
- name: Build and test with arm runners
158178
run: |
159179
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-9 90

0 commit comments

Comments
 (0)