From be2551c4132d2ebbeb1c7060b771ca201fef04e7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pawe=C5=82=20Bylica?= Date: Tue, 4 Jun 2024 18:56:54 +0200 Subject: [PATCH] ci: Build clang/sanitizers with libc++ Closes https://github.com/ethereum/evmone/issues/906. --- circle.yml | 1 + cmake/toolchains/clang-libcxx.cmake | 8 ++++++++ 2 files changed, 9 insertions(+) create mode 100644 cmake/toolchains/clang-libcxx.cmake diff --git a/circle.yml b/circle.yml index 8620ad7a05..6c4a15bb49 100644 --- a/circle.yml +++ b/circle.yml @@ -511,6 +511,7 @@ jobs: clang-latest-sanitizers: executor: linux-clang-xlarge environment: + TOOLCHAIN: clang-libcxx CMAKE_OPTIONS: -DBUILD_SHARED_LIBS=NO -DSANITIZE=address,undefined,shift-exponent,implicit-conversion,nullability UBSAN_OPTIONS: halt_on_error=1 steps: diff --git a/cmake/toolchains/clang-libcxx.cmake b/cmake/toolchains/clang-libcxx.cmake new file mode 100644 index 0000000000..a89c073280 --- /dev/null +++ b/cmake/toolchains/clang-libcxx.cmake @@ -0,0 +1,8 @@ +# evmone: Ethereum Virtual Machine +# Copyright 2024 The evmone Authors. +# Licensed under the Apache License, Version 2.0. See the LICENSE file. + +set(CMAKE_C_COMPILER clang) +set(CMAKE_CXX_COMPILER clang++) + +set(CMAKE_CXX_FLAGS_INIT -stdlib=libc++)