diff options
author | spreis <spreis@yandex-team.com> | 2023-12-14 20:30:02 +0300 |
---|---|---|
committer | spreis <spreis@yandex-team.com> | 2023-12-14 21:55:15 +0300 |
commit | 3d2968f62c0130e8fbaa0c65b53ff9660e078651 (patch) | |
tree | 9e53e4ab8a51d3a5af48f9510c5c1110e6ff914a /build | |
parent | df85aada52c266d2d7b8dba74ec3893ed28e38be (diff) | |
download | ydb-3d2968f62c0130e8fbaa0c65b53ff9660e078651.tar.gz |
Use clang-tidy via RESOURCE_LIBRARY
Diffstat (limited to 'build')
-rw-r--r-- | build/conf/settings.conf | 6 | ||||
-rw-r--r-- | build/ymake.core.conf | 14 |
2 files changed, 13 insertions, 7 deletions
diff --git a/build/conf/settings.conf b/build/conf/settings.conf index 51383aea38..2985714069 100644 --- a/build/conf/settings.conf +++ b/build/conf/settings.conf @@ -107,9 +107,3 @@ _FOLDABLE_VARS=\ _STD_CXX \ # end of _FOLDABLE_VARS list - -CLANG_VER=14 - -when ($CLANG16 == "yes") { - CLANG_VER=16 -} diff --git a/build/ymake.core.conf b/build/ymake.core.conf index 9783935581..8c27ea603d 100644 --- a/build/ymake.core.conf +++ b/build/ymake.core.conf @@ -46,6 +46,12 @@ SO_OUTPUTS=no MODULE_PREFIX= MODULE_SUFFIX= +CLANG_VER=14 +when ($CLANG16 == "yes") { + CLANG_VER=16 +} + + @import "${CONF_ROOT}/conf/settings.conf" @import "${CONF_ROOT}/conf/opensource.conf" @import "${CONF_ROOT}/conf/sysincl.conf" @@ -148,12 +154,14 @@ when($TIDY == "yes") { TIDY_ENABLED=yes } +CLANG_TIDY_BIN=${CLANG_TIDY_RESOURCE_GLOBAL}/bin/clang-tidy + when ($TIDY_ENABLED == "yes") { when ($TIDY_EXPORT_FIXES=="") { TIDY_EXPORT_FIXES="no" } - CLANG_TIDY_ARGS=${hide:CLANG_TIDY_FAKEID} $YMAKE_PYTHON ${input:"build/scripts/clang_tidy.py"} "--ymake-python" $YMAKE_PYTHON "--clang-tidy-bin" "$(CLANG_TIDY_BIN)/bin/clang-tidy" "--config-validation-script" ${input:"build/tests/config/clang_tidy/tidy_config_validation.py"} "--testing-src" ${input:SRC} "--source-root" $(SOURCE_ROOT) "--build-root" $(BUILD_ROOT) "--tidy-json" ${output;noauto;suf=${COMPILE_OUT_SUFFIX}${OBJ_CROSS_SUF}.tidyjson:SRC} "--export-fixes" $TIDY_EXPORT_FIXES + CLANG_TIDY_ARGS=${hide:CLANG_TIDY_FAKEID} $YMAKE_PYTHON ${input:"build/scripts/clang_tidy.py"} "--ymake-python" $YMAKE_PYTHON "--clang-tidy-bin" $CLANG_TIDY_BIN "--config-validation-script" ${input:"build/tests/config/clang_tidy/tidy_config_validation.py"} "--testing-src" ${input:SRC} "--source-root" $(SOURCE_ROOT) "--build-root" $(BUILD_ROOT) "--tidy-json" ${output;noauto;suf=${COMPILE_OUT_SUFFIX}${OBJ_CROSS_SUF}.tidyjson:SRC} "--export-fixes" $TIDY_EXPORT_FIXES CLANG_TIDY_ARGS+="--default-config-file" ${input:DEFAULT_TIDY_CONFIG} CLANG_TIDY_ARGS+="--project-config-file" ${input:PROJECT_TIDY_CONFIG} when ($TIDY_CHECKS) { @@ -753,6 +761,10 @@ module _BASE_UNIT: _BARE_UNIT { when ($NEED_BINUTILS_PEERDIR && $BINUTILS_USED && $NEED_PLATFORM_PEERDIRS == "yes") { PEERDIR+=build/platform/binutils } + + when ($TIDY_ENABLED == "yes") { + PEERDIR+=build/platform/clang/clang-tidy + } } _LINKER_ID= |