mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-01-25 10:43:19 -03:00
Merge bitcoin/bitcoin#27404: ci: use clang-16 in tidy task
a56c96507a
ci: use clang-16 in tidy task (fanquake) Pull request description: Follow up to https://github.com/bitcoin/bitcoin/pull/27311#issuecomment-1481020371, as IWYU now has a [clang_16 branch](https://github.com/include-what-you-use/include-what-you-use/tree/clang_16). This also removes some workarounds for (now fixed) clang-tidy issues, and simplifies the IWYU install steps. ACKs for top commit: MarcoFalke: lgtm ACKa56c96507a
josibake: ACKa56c96507a
hebasto: ACKa56c96507a
Tree-SHA512: 5bbec6cc196c3305302895c77986f3695fc6f4024363ee57503654d54e0ebf108719a7a1d7908817f84115dcaa13377493eb764b00bdf574f1290c73251426fa
This commit is contained in:
commit
04595484d9
6 changed files with 9 additions and 14 deletions
|
@ -80,10 +80,10 @@ task:
|
|||
<< : *CIRRUS_EPHEMERAL_WORKER_TEMPLATE_ENV
|
||||
|
||||
task:
|
||||
name: 'tidy [bookworm]'
|
||||
name: 'tidy [lunar]'
|
||||
<< : *GLOBAL_TASK_TEMPLATE
|
||||
container:
|
||||
image: debian:bookworm
|
||||
image: ubuntu:lunar
|
||||
cpu: 2
|
||||
memory: 5G
|
||||
# For faster CI feedback, immediately schedule the linters
|
||||
|
|
|
@ -6,14 +6,14 @@
|
|||
|
||||
export LC_ALL=C.UTF-8
|
||||
|
||||
export CI_IMAGE_NAME_TAG="debian:bookworm"
|
||||
export CI_IMAGE_NAME_TAG="ubuntu:lunar" # Version 23.04 will reach EOL in Jan 2024, and can be replaced by "ubuntu:24.04" (or anything else that ships the wanted clang version).
|
||||
export CONTAINER_NAME=ci_native_tidy
|
||||
export PACKAGES="clang-15 libclang-15-dev llvm-15-dev clang-tidy-15 bear cmake libevent-dev libboost-dev libminiupnpc-dev libnatpmp-dev libzmq3-dev systemtap-sdt-dev libqt5gui5 libqt5core5a libqt5dbus5 qttools5-dev qttools5-dev-tools libqrencode-dev libsqlite3-dev libdb++-dev"
|
||||
export PACKAGES="clang-16 libclang-16-dev llvm-16-dev libomp-16-dev clang-tidy-16 bear cmake libevent-dev libboost-dev libminiupnpc-dev libnatpmp-dev libzmq3-dev systemtap-sdt-dev libqt5gui5 libqt5core5a libqt5dbus5 qttools5-dev qttools5-dev-tools libqrencode-dev libsqlite3-dev libdb++-dev"
|
||||
export NO_DEPENDS=1
|
||||
export RUN_UNIT_TESTS=false
|
||||
export RUN_FUNCTIONAL_TESTS=false
|
||||
export RUN_FUZZ_TESTS=false
|
||||
export RUN_TIDY=true
|
||||
export GOAL="install"
|
||||
export BITCOIN_CONFIG="CC=clang-15 CXX=clang++-15 --with-incompatible-bdb --disable-hardening CFLAGS='-O0 -g0' CXXFLAGS='-O0 -g0'"
|
||||
export BITCOIN_CONFIG="CC=clang-16 CXX=clang++-16 --with-incompatible-bdb --disable-hardening CFLAGS='-O0 -g0' CXXFLAGS='-O0 -g0 -I/usr/lib/llvm-16/lib/clang/16/include'"
|
||||
export CCACHE_SIZE=200M
|
||||
|
|
|
@ -52,10 +52,9 @@ fi
|
|||
|
||||
if [[ "${RUN_TIDY}" == "true" ]]; then
|
||||
if [ ! -d "${DIR_IWYU}" ]; then
|
||||
mkdir -p "${DIR_IWYU}"/build/
|
||||
git clone --depth=1 https://github.com/include-what-you-use/include-what-you-use -b clang_15 "${DIR_IWYU}"/include-what-you-use
|
||||
cd "${DIR_IWYU}"/build && cmake -G 'Unix Makefiles' -DCMAKE_PREFIX_PATH=/usr/lib/llvm-15 ../include-what-you-use
|
||||
cd "${DIR_IWYU}"/build && make install "$MAKEJOBS"
|
||||
git clone --depth=1 https://github.com/include-what-you-use/include-what-you-use -b clang_16 "${DIR_IWYU}"/include-what-you-use
|
||||
cmake -B "${DIR_IWYU}"/build/ -G 'Unix Makefiles' -DCMAKE_PREFIX_PATH=/usr/lib/llvm-16 -S "${DIR_IWYU}"/include-what-you-use
|
||||
make -C "${DIR_IWYU}"/build/ install "$MAKEJOBS"
|
||||
fi
|
||||
fi
|
||||
|
||||
|
|
|
@ -39,7 +39,7 @@ fi
|
|||
if [ "${RUN_TIDY}" = "true" ]; then
|
||||
set -eo pipefail
|
||||
export P_CI_DIR="${BASE_BUILD_DIR}/bitcoin-$HOST/src/"
|
||||
( CI_EXEC run-clang-tidy-15 -quiet "${MAKEJOBS}" ) | grep -C5 "error"
|
||||
( CI_EXEC run-clang-tidy-16 -quiet "${MAKEJOBS}" ) | grep -C5 "error"
|
||||
export P_CI_DIR="${BASE_BUILD_DIR}/bitcoin-$HOST/"
|
||||
CI_EXEC "python3 ${DIR_IWYU}/include-what-you-use/iwyu_tool.py"\
|
||||
" src/common/init.cpp"\
|
||||
|
|
|
@ -248,8 +248,6 @@ using Fragment = miniscript::Fragment;
|
|||
using NodeRef = miniscript::NodeRef<CPubKey>;
|
||||
using Node = miniscript::Node<CPubKey>;
|
||||
using Type = miniscript::Type;
|
||||
// https://github.com/llvm/llvm-project/issues/53444
|
||||
// NOLINTNEXTLINE(misc-unused-using-decls)
|
||||
using miniscript::operator"" _mst;
|
||||
|
||||
//! Construct a miniscript node as a shared_ptr.
|
||||
|
|
|
@ -241,8 +241,6 @@ const KeyConverter CONVERTER{};
|
|||
|
||||
using Fragment = miniscript::Fragment;
|
||||
using NodeRef = miniscript::NodeRef<CPubKey>;
|
||||
// https://github.com/llvm/llvm-project/issues/53444
|
||||
// NOLINTNEXTLINE(misc-unused-using-decls)
|
||||
using miniscript::operator"" _mst;
|
||||
using Node = miniscript::Node<CPubKey>;
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue