diff options
author | 2018-05-03 12:51:55 -0700 | |
---|---|---|
committer | 2018-05-03 12:53:41 -0700 | |
commit | 8aa610bb7fce80440a563f91b32783716f51e77d (patch) | |
tree | bf088c908ff160feb2d3e901e70eba702a6b9db9 /src/main/java/com/google/devtools/build/lib/rules/android/ResourceDependencies.java | |
parent | 807bdbc722c8318548a1e0952053de32f7ef96b6 (diff) |
Methods for generating empty Android data providers
RELNOTES: none
PiperOrigin-RevId: 195296176
Diffstat (limited to 'src/main/java/com/google/devtools/build/lib/rules/android/ResourceDependencies.java')
-rw-r--r-- | src/main/java/com/google/devtools/build/lib/rules/android/ResourceDependencies.java | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/src/main/java/com/google/devtools/build/lib/rules/android/ResourceDependencies.java b/src/main/java/com/google/devtools/build/lib/rules/android/ResourceDependencies.java index 45f559eb85..09ac5afbb3 100644 --- a/src/main/java/com/google/devtools/build/lib/rules/android/ResourceDependencies.java +++ b/src/main/java/com/google/devtools/build/lib/rules/android/ResourceDependencies.java @@ -272,10 +272,16 @@ public final class ResourceDependencies { */ public AndroidResourcesInfo toInfo(ValidatedAndroidData newDirectResource) { if (neverlink) { - return ResourceDependencies.empty().toInfo(newDirectResource.getLabel()); + return ResourceDependencies.empty() + .toInfo( + newDirectResource.getLabel(), + newDirectResource.getProcessedManifest(), + newDirectResource.getRTxt()); } return new AndroidResourcesInfo( newDirectResource.getLabel(), + newDirectResource.getProcessedManifest(), + newDirectResource.getRTxt(), NestedSetBuilder.<ValidatedAndroidData>naiveLinkOrder() .addTransitive(transitiveResourceContainers) .addTransitive(directResourceContainers) @@ -307,12 +313,15 @@ public final class ResourceDependencies { * @param label The label of the library exporting this provider. * @return A provider with the current resources and label. */ - public AndroidResourcesInfo toInfo(Label label) { + public AndroidResourcesInfo toInfo( + Label label, ProcessedAndroidManifest manifest, Artifact rTxt) { if (neverlink) { - return ResourceDependencies.empty().toInfo(label); + return ResourceDependencies.empty().toInfo(label, manifest, rTxt); } return new AndroidResourcesInfo( label, + manifest, + rTxt, transitiveResourceContainers, directResourceContainers, transitiveResources, |