aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/main/java/com/google/devtools/build/lib/rules/java/proto/JavaLiteProtoAspect.java
diff options
context:
space:
mode:
authorGravatar elenairina <elenairina@google.com>2017-11-24 07:23:55 -0800
committerGravatar Copybara-Service <copybara-piper@google.com>2017-11-24 07:25:22 -0800
commita6ed4c01d374bcf98bf39c1efc12a0f4f20fe313 (patch)
treeb0a6f8ffb7d9efd8b9f1ca3f3224366319f1a3fa /src/main/java/com/google/devtools/build/lib/rules/java/proto/JavaLiteProtoAspect.java
parent263c5e07dd2860a866fd361cd29c03afaf3e019f (diff)
Create the output source jar in java_common.compile
and expose transitive source jars to Skylark. Slightly refactor java classes to take in specific host javabase inputs and host java executable for creating the source jar, instead of always relying on fetching them from native java rules specific attributes. Creating the output source jar in java_common.compile makes the behavior more similar to java_library. Exposing the transitive_source_jars to Skylark helps with the Skylark migration from the old 'java' provider to JavaInfo. Progress on #2614. RELNOTES: transitive_source_jars is now exposed on JavaInfo. PiperOrigin-RevId: 176844750
Diffstat (limited to 'src/main/java/com/google/devtools/build/lib/rules/java/proto/JavaLiteProtoAspect.java')
-rw-r--r--src/main/java/com/google/devtools/build/lib/rules/java/proto/JavaLiteProtoAspect.java14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/main/java/com/google/devtools/build/lib/rules/java/proto/JavaLiteProtoAspect.java b/src/main/java/com/google/devtools/build/lib/rules/java/proto/JavaLiteProtoAspect.java
index 7d87f9891d..2392d68af5 100644
--- a/src/main/java/com/google/devtools/build/lib/rules/java/proto/JavaLiteProtoAspect.java
+++ b/src/main/java/com/google/devtools/build/lib/rules/java/proto/JavaLiteProtoAspect.java
@@ -264,13 +264,13 @@ public class JavaLiteProtoAspect extends NativeAspectClass implements Configured
}
}
- JavaCompilationArtifacts artifacts =
- helper.build(
- javaSemantics,
- JavaCompilationHelper.getJavaToolchainProvider(ruleContext),
- JavaHelper.getHostJavabaseInputs(ruleContext),
- JavaCompilationHelper.getInstrumentationJars(ruleContext),
- JavaRuleOutputJarsProvider.builder());
+ JavaCompilationArtifacts artifacts = helper.build(
+ javaSemantics,
+ JavaCompilationHelper.getJavaToolchainProvider(ruleContext),
+ JavaHelper.getHostJavabaseTarget(ruleContext),
+ JavaCompilationHelper.getInstrumentationJars(ruleContext),
+ JavaRuleOutputJarsProvider.builder(),
+ /*outputSourceJar=*/ null);
return helper.buildCompilationArgsProvider(artifacts, true /* isReportedAsStrict */);
}