aboutsummaryrefslogtreecommitdiffstats
path: root/build/scripts/copy_clang_profile_rt.py
diff options
context:
space:
mode:
authorzhukoff-pavel <zhukoff-pavel@yandex-team.com>2023-11-02 14:44:42 +0300
committerzhukoff-pavel <zhukoff-pavel@yandex-team.com>2023-11-02 16:02:46 +0300
commit5e305fbb63daa7aba667d6d3a519237b97808278 (patch)
tree055e92943e78a76705473c4b973c88e282d92a5b /build/scripts/copy_clang_profile_rt.py
parentea7b93c5bfd5bf28a90e7deb7700ddbd3965b749 (diff)
downloadydb-5e305fbb63daa7aba667d6d3a519237b97808278.tar.gz
[build/scripts/copy_clang_profile_rt.py] Add temp option to build_script to support both clang14 and clang16
Diffstat (limited to 'build/scripts/copy_clang_profile_rt.py')
-rw-r--r--build/scripts/copy_clang_profile_rt.py10
1 files changed, 7 insertions, 3 deletions
diff --git a/build/scripts/copy_clang_profile_rt.py b/build/scripts/copy_clang_profile_rt.py
index 1e5cd9c56a..7710615f32 100644
--- a/build/scripts/copy_clang_profile_rt.py
+++ b/build/scripts/copy_clang_profile_rt.py
@@ -4,15 +4,19 @@ import shutil
import process_command_files as pcf
-CLANG_RT_VERSION = 14
+# List is a temporary thing to ensure that nothing breaks before and after switching to newer clang
+# Remove after DTCC-1902
+CLANG_RT_VERSIONS = [14, 16]
def copy_clang_rt_profile(cmd, build_root, arch) -> None:
profile_rt_lib = None
resource_dir = None
for arg in cmd:
- if arg.startswith(f'contrib/libs/clang{CLANG_RT_VERSION}-rt/lib/profile/libclang_rt.profile'):
- profile_rt_lib = arg
+ for version in CLANG_RT_VERSIONS:
+ if arg.startswith(f'contrib/libs/clang{version}-rt/lib/profile/libclang_rt.profile'):
+ profile_rt_lib = arg
+ break
if arg.startswith('-resource-dir='):
resource_dir = arg[len('-resource-dir='):]