summaryrefslogtreecommitdiff
path: root/Tools/ci-run.sh
diff options
context:
space:
mode:
authorStefan Behnel <stefan_ml@behnel.de>2021-05-25 12:49:50 +0200
committerStefan Behnel <stefan_ml@behnel.de>2021-05-25 12:49:50 +0200
commit3f05fb2e101ba6a8d22ad66e4e308108f7eac66a (patch)
tree7aa0cab14c06ab03c2f9a2380f395ecde5906f15 /Tools/ci-run.sh
parent1eac3022a3b304ad673f35eb353c15a1f10728d7 (diff)
downloadcython-3f05fb2e101ba6a8d22ad66e4e308108f7eac66a.tar.gz
Add CI jobs that test with GCC 11.
Diffstat (limited to 'Tools/ci-run.sh')
-rw-r--r--Tools/ci-run.sh10
1 files changed, 6 insertions, 4 deletions
diff --git a/Tools/ci-run.sh b/Tools/ci-run.sh
index b3a0323db..e1a59afdc 100644
--- a/Tools/ci-run.sh
+++ b/Tools/ci-run.sh
@@ -1,22 +1,24 @@
#!/usr/bin/bash
+GCC_VERSION=${GCC_VERSION:=8}
+
# Set up compilers
if [ "${OS_NAME##ubuntu*}" == "" - "$TEST_CODE_STYLE" != "1" ]; then
echo "Installing requirements [apt]"
sudo apt-add-repository -y "ppa:ubuntu-toolchain-r/test"
sudo apt update -y -q
- sudo apt install -y -q ccache gdb python-dbg python3-dbg gcc-8 || exit 1
+ sudo apt install -y -q ccache gdb python-dbg python3-dbg gcc-$GCC_VERSION || exit 1
if [ -z "${BACKEND##*cpp*}" ]; then
- sudo apt install -y -q g++-8 || exit 1
+ sudo apt install -y -q g++-$GCC_VERSION || exit 1
fi
sudo /usr/sbin/update-ccache-symlinks
echo "/usr/lib/ccache" >> $GITHUB_PATH # export ccache to path
- sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-8 60 $(if [ -z "${BACKEND##*cpp*}" ]; then echo " --slave /usr/bin/g++ g++ /usr/bin/g++-8"; fi)
+ sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-$GCC_VERSION 60 $(if [ -z "${BACKEND##*cpp*}" ]; then echo " --slave /usr/bin/g++ g++ /usr/bin/g++-$GCC_VERSION"; fi)
export CC="gcc"
if [ -z "${BACKEND##*cpp*}" ]; then
- sudo update-alternatives --set g++ /usr/bin/g++-8
+ sudo update-alternatives --set g++ /usr/bin/g++-$GCC_VERSION
export CXX="g++"
fi
fi