aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/main/java
diff options
context:
space:
mode:
authorGravatar cparsons <cparsons@google.com>2017-12-04 13:50:52 -0800
committerGravatar Copybara-Service <copybara-piper@google.com>2017-12-04 13:52:30 -0800
commit8bec8dd9096d090fd16da405e90125ae04da4c9b (patch)
treed823c412be32689954ddfa27614c5a8e01a1a527 /src/main/java
parentba66e72295d763e43b92179ce6bd46476084a548 (diff)
From apple_binary, receive AppleExecutableBinaryProvider from the bundle_loader attribute
Prior to this change, apple_binary relied on bundle_loader targets (which are themselves apple_binary) to propagate an unwrapped ObjcProvider. That is deprecated, is disabled by --noexperimental_objc_provider_from_linked, and will be killed off shortly. RELNOTES: None. PiperOrigin-RevId: 177862573
Diffstat (limited to 'src/main/java')
-rw-r--r--src/main/java/com/google/devtools/build/lib/rules/objc/MultiArchBinarySupport.java9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/main/java/com/google/devtools/build/lib/rules/objc/MultiArchBinarySupport.java b/src/main/java/com/google/devtools/build/lib/rules/objc/MultiArchBinarySupport.java
index d2b5be83bd..71a8a7fb6f 100644
--- a/src/main/java/com/google/devtools/build/lib/rules/objc/MultiArchBinarySupport.java
+++ b/src/main/java/com/google/devtools/build/lib/rules/objc/MultiArchBinarySupport.java
@@ -282,13 +282,20 @@ public class MultiArchBinarySupport {
private static Iterable<ObjcProvider> getDylibObjcProviders(
Iterable<TransitiveInfoCollection> transitiveInfoCollections) {
+ // Dylibs.
Iterable<ObjcProvider> frameworkObjcProviders =
Streams.stream(getTypedProviders(transitiveInfoCollections,
AppleDynamicFrameworkProvider.SKYLARK_CONSTRUCTOR))
.map(frameworkProvider -> frameworkProvider.getDepsObjcProvider())
.collect(ImmutableList.toImmutableList());
+ // Bundle Loaders.
+ Iterable<ObjcProvider> executableObjcProviders =
+ Streams.stream(getTypedProviders(transitiveInfoCollections,
+ AppleExecutableBinaryProvider.SKYLARK_CONSTRUCTOR))
+ .map(frameworkProvider -> frameworkProvider.getDepsObjcProvider())
+ .collect(ImmutableList.toImmutableList());
- return Iterables.concat(frameworkObjcProviders,
+ return Iterables.concat(frameworkObjcProviders, executableObjcProviders,
getTypedProviders(transitiveInfoCollections, ObjcProvider.SKYLARK_CONSTRUCTOR));
}