Skip to content

Commit 1b4160e

Browse files
Fleetbench Teamcopybara-github
authored andcommitted
Enable libcpp hardening by default in public fleetbench, as Google has enabled libcpp hardening throughout its production environments.
PiperOrigin-RevId: 741199261 Change-Id: I385760f051df85eb8cc5e13402d01ea812e4ef58
1 parent 126ba91 commit 1b4160e

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

.bazelrc

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,9 @@ build --@com_github_grpc_grpc//:disable_grpc_rls
2626
build --define=grpc_no_xds=true
2727
test --test_timeout=1500
2828

29+
# Enable bounds-checking assertions in LLVM libcpp containers by default.
30+
build --copt='-D_LIBCPP_HARDENING_MODE=_LIBCPP_HARDENING_MODE_FAST'
31+
2932
# Define the --config=asan-libfuzzer configuration.
3033
build:asan-libfuzzer --@rules_fuzzing//fuzzing:cc_engine=@rules_fuzzing//fuzzing/engines:libfuzzer
3134
build:asan-libfuzzer --@rules_fuzzing//fuzzing:cc_engine_instrumentation=libfuzzer
@@ -75,4 +78,4 @@ build:westmere --copt='-mpclmul'
7578
build:westmere --copt='-mprefer-vector-width=128'
7679
build:westmere --copt='-msse4.2'
7780

78-
build:arm --copt='-mtune=generic'
81+
build:arm --copt='-mtune=generic'

0 commit comments

Comments
 (0)