From b47beda74b46b701d156e6d864c8c13869f83a8f Mon Sep 17 00:00:00 2001 From: Dongsheng He Date: Mon, 31 Aug 2026 09:15:35 +0000 Subject: [PATCH] Fix CMake build: add Clang -fbracket-depth, use GTest::gtest, drop unused benchmark include. --- tcmalloc/internal/CMakeLists.txt | 2 ++ tcmalloc/testing/CMakeLists.txt | 2 +- tcmalloc/testing/testutil.h | 1 - 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/tcmalloc/internal/CMakeLists.txt b/tcmalloc/internal/CMakeLists.txt index 02c25ed0a..d72ccea69 100644 --- a/tcmalloc/internal/CMakeLists.txt +++ b/tcmalloc/internal/CMakeLists.txt @@ -1252,6 +1252,8 @@ tcmalloc_cc_test( tcmalloc_internal_range_tracker_fuzz_test SRCS "range_tracker_fuzz.cc" + COPTS + $<$:-fbracket-depth=512> DEPS "GTest::gtest" "GTest::gmock" diff --git a/tcmalloc/testing/CMakeLists.txt b/tcmalloc/testing/CMakeLists.txt index cb25568ee..0ac8791f8 100644 --- a/tcmalloc/testing/CMakeLists.txt +++ b/tcmalloc/testing/CMakeLists.txt @@ -270,7 +270,7 @@ tcmalloc_cc_library( SRCS "rseq_util.cc" DEPS - "@com_google_googletest//:gtest_for_library" + "GTest::gtest" "tcmalloc::internal_environment" "tcmalloc::internal_percpu" "tcmalloc::testing_testutil" diff --git a/tcmalloc/testing/testutil.h b/tcmalloc/testing/testutil.h index 9de307090..ebfbd6633 100644 --- a/tcmalloc/testing/testutil.h +++ b/tcmalloc/testing/testutil.h @@ -26,7 +26,6 @@ #include #include -#include "benchmark/benchmark.h" #include "absl/base/attributes.h" #include "absl/strings/match.h" #include "absl/time/clock.h"