From f881d368f04637d2e45022b0b56bb0b34d8d712d Mon Sep 17 00:00:00 2001 From: Paolo Tranquilli Date: Thu, 5 Feb 2026 17:35:25 +0100 Subject: [PATCH] refactor: migrate BUILD files to explicit rules_cc imports Add explicit load statements for cc_binary, cc_library, and cc_test from @rules_cc//cc:defs.bzl in: - shared/cpp/BUILD.bazel - swift/logging/BUILD.bazel - misc/bazel/internal/zipmerge/BUILD.bazel --- misc/bazel/internal/zipmerge/BUILD.bazel | 4 +++- shared/cpp/BUILD.bazel | 2 ++ swift/logging/BUILD.bazel | 2 ++ 3 files changed, 7 insertions(+), 1 deletion(-) diff --git a/misc/bazel/internal/zipmerge/BUILD.bazel b/misc/bazel/internal/zipmerge/BUILD.bazel index 07cbb34ce97..4b2723d6c64 100644 --- a/misc/bazel/internal/zipmerge/BUILD.bazel +++ b/misc/bazel/internal/zipmerge/BUILD.bazel @@ -1,3 +1,5 @@ +load("@rules_cc//cc:defs.bzl", "cc_binary", "cc_library", "cc_test") + cc_library( name = "lib", srcs = [ @@ -28,7 +30,7 @@ cc_test( linkstatic = True, # required to build the test in the internal repo deps = [ ":lib", - "@bazel_tools//tools/cpp/runfiles", "@googletest//:gtest_main", + "@rules_cc//cc/runfiles", ], ) diff --git a/shared/cpp/BUILD.bazel b/shared/cpp/BUILD.bazel index 5debed90086..f78c4ede92f 100644 --- a/shared/cpp/BUILD.bazel +++ b/shared/cpp/BUILD.bazel @@ -1,3 +1,5 @@ +load("@rules_cc//cc:defs.bzl", "cc_library") + cc_library( name = "extractor_shared", srcs = glob(["*.cpp"]), diff --git a/swift/logging/BUILD.bazel b/swift/logging/BUILD.bazel index 1d6192b3c13..e72a7071d06 100644 --- a/swift/logging/BUILD.bazel +++ b/swift/logging/BUILD.bazel @@ -1,3 +1,5 @@ +load("@rules_cc//cc:defs.bzl", "cc_library") + cc_library( name = "logging", srcs = glob(["*.cpp"]),