vlsi commented on a change in pull request #2531:
URL: https://github.com/apache/calcite/pull/2531#discussion_r718199388
##########
File path: core/build.gradle.kts
##########
@@ -187,6 +194,65 @@ ide {
generatedSource(javaCCTest, "test")
}
+fun configureAnnotationSet(task: JavaCompile, sourceSet: SourceSet) {
+ with(task) {
+ source = sourceSet.java
+ classpath = sourceSet.compileClasspath
+ destinationDirectory.set(options.generatedSourceOutputDirectory)
+ options.compilerArgs.add("-proc:only")
+
org.gradle.api.plugins.internal.JvmPluginsHelper.configureAnnotationProcessorPath(sourceSet,
sourceSet.java, options, project)
+ }
+}
Review comment:
```suggestion
fun JavaCompile.configureAnnotationSet(sourceSet: SourceSet) {
source = sourceSet.java
classpath = sourceSet.compileClasspath
destinationDirectory.set(options.generatedSourceOutputDirectory)
options.compilerArgs.add("-proc:only")
org.gradle.api.plugins.internal.JvmPluginsHelper.configureAnnotationProcessorPath(sourceSet,
sourceSet.java, options, project)
}
```
`destinationDirectory` should be "directory with the generated class files",
so `options.generatedSourceOutputDirectory` looks wrong here.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]