Skip to content

Commit 0d60c5e

Browse files
committed
Removed multiple gcc builds
Looks like egor-tensin/setup-gcc@v1 is no longer mantained
1 parent 638f08f commit 0d60c5e

File tree

1 file changed

+5
-22
lines changed

1 file changed

+5
-22
lines changed

.github/workflows/build.yml

Lines changed: 5 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -28,22 +28,9 @@ jobs:
2828
fail-fast: false
2929
matrix:
3030
kernel_version: ${{fromJson(needs.commontasks.outputs.matrix)}}
31-
gcc_version: [9, 10, 12]
3231
# kernel_version: [6.1-rc1]
3332
steps:
34-
- name: Check Versions
35-
id: check_version
36-
shell: bash {0}
37-
run: |
38-
echo ::set-output name=skip_build::False
39-
dpkg --compare-versions "${{matrix.kernel_version}}" "ge" "5.15"
40-
if [ $? -eq "0" ] && [ ${{matrix.gcc_version}} -lt 12 ];
41-
then
42-
echo "GCC version not compatible"
43-
echo ::set-output name=skip_build::True
44-
fi
4533
- name: Download kernel packages
46-
if: steps.check_version.outputs.skip_build == 'False'
4734
run: |
4835
KERNEL_URL=https://kernel.ubuntu.com/~kernel-ppa/mainline/
4936
KERNEL_URL_DETAILS=$(wget --quiet -O - ${KERNEL_URL}v${{matrix.kernel_version}}/ | grep -A8 "Build for amd64\|Test amd64")
@@ -54,16 +41,12 @@ jobs:
5441
wget -nv ${KERNEL_URL}v${{matrix.kernel_version}}/$AMD64_DEB
5542
wget -nv ${KERNEL_URL}v${{matrix.kernel_version}}/$ALL_DEB
5643
echo "KVER=$(echo $ALL_DEB | cut -d '_' -f 2 | rev | cut -c14- | rev)-generic" >> $GITHUB_ENV
57-
- name: Set up GCC
58-
if: steps.check_version.outputs.skip_build == 'False'
59-
uses: egor-tensin/setup-gcc@v1
60-
with:
61-
version: ${{matrix.gcc_version }}
6244
- name: install deb packages
63-
if: steps.check_version.outputs.skip_build == 'False'
6445
run: sudo dpkg --force-all -i *.deb
46+
- name: update GCC
47+
run: |
48+
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-12 12
49+
sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-12 12
6550
- uses: actions/checkout@v2
66-
if: steps.check_version.outputs.skip_build == 'False'
67-
- name: build kernel ${{ matrix.kernel_version }} - GCC ${{ matrix.gcc_version }}
68-
if: steps.check_version.outputs.skip_build == 'False'
51+
- name: build kernel ${{ matrix.kernel_version }}
6952
run: make KVER=$KVER CC=cc

0 commit comments

Comments
 (0)