Skip to content

Commit

Permalink
Update Clang toolchain from 18.0.0 to 18.1.8
Browse files Browse the repository at this point in the history
This is done in the interest of assisting google#12075 and google#11626. Currently
the Rust toolchain cannot be updated because the latest nightly uses
LLVM 18.1.8 and coverage information breaks. This breakage is because
LLVM 18.1.8 records coverage information with version "9" but LLVM
18.0.0 recorded coverage information with version "8". This means that
the recordings created by Rust binaries use version "9" which are
unreadable by the processing that OSS-Fuzz does with the 18.0.0-based
toolchain using version "8".

This commit updates the Clang toolchain to the latest 18.x.x release to
get the two in sync so the same coverage recording version is used.
  • Loading branch information
alexcrichton committed Jul 12, 2024
1 parent 915fff2 commit a6a3b31
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion infra/base-images/base-clang/checkout_build_install_llvm.sh
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ apt-get update && apt-get install -y $LLVM_DEP_PACKAGES --no-install-recommends
# languages, projects, ...) is needed.
# Check CMAKE_VERSION infra/base-images/base-clang/Dockerfile was released
# recently enough to fully support this clang version.
OUR_LLVM_REVISION=llvmorg-18-init-4631-gd50b56d1
OUR_LLVM_REVISION=llvmorg-18.1.8

mkdir $SRC/chromium_tools
cd $SRC/chromium_tools
Expand Down Expand Up @@ -116,6 +116,7 @@ cmake -G "Ninja" \
-DLLVM_TARGETS_TO_BUILD="$TARGET_TO_BUILD" \
-DLLVM_ENABLE_PROJECTS="clang;lld" \
-DLLVM_BINUTILS_INCDIR="/usr/include/" \
-DLIBCXXABI_USE_LLVM_UNWINDER=OFF \
$LLVM_SRC/llvm

ninja -j $NPROC
Expand Down Expand Up @@ -202,6 +203,7 @@ function cmake_libcxx {
-DLIBCXX_ENABLE_SHARED=OFF \
-DLIBCXX_ENABLE_STATIC_ABI_LIBRARY=ON \
-DLIBCXXABI_ENABLE_SHARED=OFF \
-DLIBCXXABI_USE_LLVM_UNWINDER=OFF \
-DCMAKE_BUILD_TYPE=Release \
-DLLVM_ENABLE_PIC=ON \
-DLLVM_TARGETS_TO_BUILD="$TARGET_TO_BUILD" \
Expand Down

0 comments on commit a6a3b31

Please sign in to comment.