From 187b1099a66bf491c8fb00e8403e1a60ec8adb4c Mon Sep 17 00:00:00 2001 From: Fabian Meumertzheim Date: Tue, 12 Dec 2023 12:58:27 +0100 Subject: [PATCH] Only force clang, not clang-10 clang-10 isn't available on macOS. Before Bazel 7, this never applied to macOS since the default toolchain used Xcode, ignoring the value of `CC` alltogether. Also move from `--action_env` to `--repo_env`, which doesn't leak into all actions environment, and don't set `CXX`, which isn't read by Bazel. --- .bazelrc | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.bazelrc b/.bazelrc index cdadb69..0fb4aa6 100644 --- a/.bazelrc +++ b/.bazelrc @@ -16,8 +16,7 @@ common --noenable_bzlmod # Force the use of Clang for all builds. -build --action_env=CC=clang-10 -build --action_env=CXX=clang++-10 +build --repo_env=CC=clang # Needed for abseil-cpp until https://github.com/bazelbuild/bazel/pull/19794 is released. build --cxxopt=-std=c++14