Skip to content

Commit

Permalink
upgrade clang to clang-17
Browse files Browse the repository at this point in the history
  • Loading branch information
shiyu1994 committed Dec 19, 2023
1 parent ab4d9a0 commit 809db5b
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 9 deletions.
22 changes: 15 additions & 7 deletions .ci/setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -49,11 +49,16 @@ else # Linux
locales-all \
netcat \
unzip \
zip || exit -1
zip \
wget \
software-properties-common || exit -1
if [[ $COMPILER == "clang" ]]; then
sudo apt-get install --no-install-recommends -y \
clang \
libomp-dev
wget -qO- https://apt.llvm.org/llvm-snapshot.gpg.key | sudo tee /etc/apt/trusted.gpg.d/apt.llvm.org.asc
sudo apt-get update
sudo apt-add-repository deb http://apt.llvm.org/jammy/ llvm-toolchain-jammy-17 main
sudo apt-add-repository deb-src http://apt.llvm.org/jammy/ llvm-toolchain-jammy-17 main
sudo apt-get install clang-17
sudo apt-get install --no-install-recommends -y libomp-dev
fi

export LANG="en_US.UTF-8"
Expand Down Expand Up @@ -114,9 +119,12 @@ else # Linux
lsb-release \
software-properties-common
if [[ $COMPILER == "clang" ]]; then
apt-get install --no-install-recommends -y \
clang \
libomp-dev
wget -qO- https://apt.llvm.org/llvm-snapshot.gpg.key | sudo tee /etc/apt/trusted.gpg.d/apt.llvm.org.asc
sudo apt-get update
sudo apt-add-repository deb http://apt.llvm.org/jammy/ llvm-toolchain-jammy-17 main
sudo apt-add-repository deb-src http://apt.llvm.org/jammy/ llvm-toolchain-jammy-17 main
sudo apt-get install clang-17
sudo apt-get install --no-install-recommends -y libomp-dev
fi
curl -sL https://apt.kitware.com/keys/kitware-archive-latest.asc | apt-key add -
apt-add-repository "deb https://apt.kitware.com/ubuntu/ $(lsb_release -cs) main" -y
Expand Down
4 changes: 2 additions & 2 deletions .ci/test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ if [[ $OS_NAME == "macos" ]] && [[ $COMPILER == "gcc" ]]; then
export CXX=g++-11
export CC=gcc-11
elif [[ $OS_NAME == "linux" ]] && [[ $COMPILER == "clang" ]]; then
export CXX=clang++
export CC=clang
export CXX=clang-17++
export CC=clang-17
fi

if [[ $IN_UBUNTU_BASE_CONTAINER == "true" ]]; then
Expand Down

0 comments on commit 809db5b

Please sign in to comment.