aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/main/java/com/google/devtools/build/lib/rules/java/JavaConfiguration.java
diff options
context:
space:
mode:
authorGravatar brandjon <brandjon@google.com>2017-06-16 21:27:56 +0200
committerGravatar Philipp Wollermann <philwo@google.com>2017-06-19 18:24:05 +0200
commit4929ad79865f8c13ef3b33c827040f4a037e4afe (patch)
treec97035c6f60aba479384bf95ccd5ec348d8781e7 /src/main/java/com/google/devtools/build/lib/rules/java/JavaConfiguration.java
parent9e26369575f04776c0416fd75a9434a22b4d5e9a (diff)
Automated g4 rollback of commit 923d7df521f67d031b288180560848bd35e20976.
*** Reason for rollback *** Breaks dozens of targets in the nightly with Tool Failure errors *** Original change description *** Clean up turbine action creation Support disabling javac fallback for actions without a direct classpath, and only use the 'JavacTurbine' mnemonic for spawns that require javac-turbine due to annotation processing to make it easier to collect metrics on that. Finally, remove --java_header_compilation_direct_classpath now that it has been productionized and enabled by default. PiperOrigin-RevId: 159260596
Diffstat (limited to 'src/main/java/com/google/devtools/build/lib/rules/java/JavaConfiguration.java')
-rw-r--r--src/main/java/com/google/devtools/build/lib/rules/java/JavaConfiguration.java7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/main/java/com/google/devtools/build/lib/rules/java/JavaConfiguration.java b/src/main/java/com/google/devtools/build/lib/rules/java/JavaConfiguration.java
index c70d0cc481..1c9364dc5c 100644
--- a/src/main/java/com/google/devtools/build/lib/rules/java/JavaConfiguration.java
+++ b/src/main/java/com/google/devtools/build/lib/rules/java/JavaConfiguration.java
@@ -146,6 +146,7 @@ public final class JavaConfiguration extends Fragment {
private final Label javaLauncherLabel;
private final boolean useIjars;
private final boolean useHeaderCompilation;
+ private final boolean headerCompilationDirectClasspath;
private final boolean headerCompilationDisableJavacFallback;
private final boolean generateJavaDeps;
private final boolean strictDepsJavaProtos;
@@ -178,6 +179,7 @@ public final class JavaConfiguration extends Fragment {
this.javaLauncherLabel = javaOptions.javaLauncher;
this.useIjars = javaOptions.useIjars;
this.useHeaderCompilation = javaOptions.headerCompilation;
+ this.headerCompilationDirectClasspath = javaOptions.headerCompilationDirectClasspath;
this.headerCompilationDisableJavacFallback = javaOptions.headerCompilationDisableJavacFallback;
this.generateJavaDeps = generateJavaDeps;
this.javaClasspath = javaOptions.javaClasspath;
@@ -259,6 +261,11 @@ public final class JavaConfiguration extends Fragment {
return useHeaderCompilation;
}
+ /** Returns true if header compilations should use direct dependencies only. */
+ public boolean headerCompilationDirectClasspath() {
+ return headerCompilationDirectClasspath;
+ }
+
/**
* If --java_header_compilation is set, report diagnostics from turbine instead of falling back to
* javac. Diagnostics will be produced more quickly, but may be less helpful.