patch 9.0.1474: CI runs with old version of Ubuntu and tools

Problem:    CI runs with old version of Ubuntu and tools.
Solution:   Update CI to more recent versions. (closes #11092)
This commit is contained in:
Philip H
2023-04-21 19:51:22 +01:00
committed by Bram Moolenaar
parent 017227079f
commit 9be736f2eb
3 changed files with 24 additions and 20 deletions

View File

@ -17,10 +17,12 @@ permissions:
jobs:
linux:
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04
env:
CC: ${{ matrix.compiler }}
GCC_VER: 12
CLANG_VER: 16
TEST: test
SRCDIR: ./src
LEAK_CFLAGS: -DEXITFREE
@ -81,10 +83,10 @@ jobs:
lcov \
libcanberra-dev \
libperl-dev \
python-dev \
python2-dev \
python3-dev \
liblua5.3-dev \
lua5.3 \
liblua5.4-dev \
lua5.4 \
ruby-dev \
tcl-dev \
cscope \
@ -93,24 +95,24 @@ jobs:
fi
sudo apt-get update && sudo apt-get install -y "${PKGS[@]}"
- name: Install gcc-11
- name: Install gcc-${{ env.GCC_VER }}
if: matrix.compiler == 'gcc'
run: |
sudo apt-get install -y gcc-11
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-11 100
sudo update-alternatives --set gcc /usr/bin/gcc-11
sudo apt-get install -y gcc-${{ env.GCC_VER }}
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-${{ env.GCC_VER }} 100
sudo update-alternatives --set gcc /usr/bin/gcc-${{ env.GCC_VER }}
- name: Install clang-16
- name: Install clang-${{ env.CLANG_VER }}
if: matrix.compiler == 'clang'
run: |
wget -O - https://apt.llvm.org/llvm-snapshot.gpg.key | sudo apt-key add -
. /etc/lsb-release
sudo add-apt-repository -y "deb http://apt.llvm.org/${DISTRIB_CODENAME}/ llvm-toolchain-${DISTRIB_CODENAME}-16 main"
sudo apt-get install -y clang-16 llvm-16
sudo update-alternatives --install /usr/bin/clang clang /usr/bin/clang-16 100
sudo update-alternatives --set clang /usr/bin/clang-16
sudo update-alternatives --install /usr/bin/llvm-cov llvm-cov /usr/bin/llvm-cov-16 100
sudo update-alternatives --install /usr/bin/asan_symbolize asan_symbolize /usr/bin/asan_symbolize-16 100
sudo add-apt-repository -y "deb http://apt.llvm.org/${DISTRIB_CODENAME}/ llvm-toolchain-${DISTRIB_CODENAME}-${{ env.CLANG_VER }} main"
sudo apt-get install -y clang-${{ env.CLANG_VER }} llvm-${{ env.CLANG_VER }}
sudo update-alternatives --install /usr/bin/clang clang /usr/bin/clang-${{ env.CLANG_VER }} 100
sudo update-alternatives --set clang /usr/bin/clang-${{ env.CLANG_VER }}
sudo update-alternatives --install /usr/bin/llvm-cov llvm-cov /usr/bin/llvm-cov-${{ env.CLANG_VER }} 100
sudo update-alternatives --install /usr/bin/asan_symbolize asan_symbolize /usr/bin/asan_symbolize-${{ env.CLANG_VER }} 100
- name: Set up environment
run: |