From a0a2a8e2a7e0a97b537438cae58595d7d8121ac8 Mon Sep 17 00:00:00 2001 From: waltl Date: Thu, 20 Feb 2020 17:53:24 -0800 Subject: [PATCH] Get Objc compile info from CcCompilationContext Note strict includes still come from ObjcProvider. Step 2 of 3-step plan: 1. Migrate the definitions. 2. Migrate the uses. 3. Delete old ObjcProvider definitions. See https://github.com/bazelbuild/bazel/issues/10674. RELNOTES: None PiperOrigin-RevId: 296338258 --- apple/internal/testing/apple_test_bundle_support.bzl | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/apple/internal/testing/apple_test_bundle_support.bzl b/apple/internal/testing/apple_test_bundle_support.bzl index 05b89dd861..95b6dc2577 100644 --- a/apple/internal/testing/apple_test_bundle_support.bzl +++ b/apple/internal/testing/apple_test_bundle_support.bzl @@ -100,12 +100,16 @@ def _apple_test_info_aspect_impl(target, ctx): if apple_common.Objc in target: objc_provider = target[apple_common.Objc] - includes.append(objc_provider.include) + includes.append(objc_provider.strict_include) # Module maps should only be used by Swift targets. if SwiftInfo in target: module_maps.append(objc_provider.module_map) + if CcInfo in target: + cc_info = target[CcInfo] + includes.append(cc_info.compilation_context.includes) + if (SwiftInfo in target and hasattr(target[SwiftInfo], "transitive_swiftmodules")): swift_modules.append(target[SwiftInfo].transitive_swiftmodules)