How to pass -parameters javac flag to Java compiler via Gradle?
You should use standard way of configuring Java compile plugin:
apply plugin: 'java'
compileJava {
options.compilerArgs << '-parameters'
}
For Android projects, one can add e.g. the below in the gradle android scope.
// Used to get more info from dagger regarding binding compile errors
// see https://github.com/google/dagger/wiki/Dagger-2.17-@Binds-bugs
tasks.withType(JavaCompile) {
options.compilerArgs += ["-Adagger.floatingBindsMethods=enabled"]
}