diff --git a/nabl2.terms/build.gradle.kts b/nabl2.terms/build.gradle.kts index 1a1b8d7cd..7f08166e6 100644 --- a/nabl2.terms/build.gradle.kts +++ b/nabl2.terms/build.gradle.kts @@ -4,12 +4,18 @@ plugins { } fun compositeBuild(name: String) = "$group:$name:$version" +// Used for refsyn: disabled by default +fun kaptEnabled() = extra.has("kaptEnabled") && extra["kaptEnabled"] as Boolean val spoofax2Version: String by ext dependencies { api(platform("org.metaborg:parent:$spoofax2Version")) testImplementation(platform("org.metaborg:parent:$spoofax2Version")) annotationProcessor(platform("org.metaborg:parent:$spoofax2Version")) testAnnotationProcessor(platform("org.metaborg:parent:$spoofax2Version")) + if(kaptEnabled()) { + kapt(platform("org.metaborg:parent:$version")) + kaptTest(platform("org.metaborg:parent:$version")) + } // !! Update dependencies in pom.xml as well @@ -23,6 +29,10 @@ dependencies { // Annotation processing annotationProcessor("org.immutables:value") annotationProcessor("org.immutables:serial") + if(kaptEnabled()) { + kapt("org.immutables:value") + kapt("org.immutables:serial") + } compileOnly("org.immutables:value") compileOnly("org.immutables:serial") compileOnly("javax.annotation:javax.annotation-api") @@ -36,6 +46,10 @@ dependencies { // Test Annotation processing testAnnotationProcessor("org.immutables:value") testAnnotationProcessor("org.immutables:serial") + if(kaptEnabled()) { + kaptTest("org.immutables:value") + kaptTest("org.immutables:serial") + } testCompileOnly("org.immutables:value") testCompileOnly("org.immutables:serial") testCompileOnly("javax.annotation:javax.annotation-api") diff --git a/p_raffrayi/build.gradle.kts b/p_raffrayi/build.gradle.kts index c3928b838..6ded586c8 100644 --- a/p_raffrayi/build.gradle.kts +++ b/p_raffrayi/build.gradle.kts @@ -4,12 +4,18 @@ plugins { } fun compositeBuild(name: String) = "$group:$name:$version" +// Used for refsyn: disabled by default +fun kaptEnabled() = extra.has("kaptEnabled") && extra["kaptEnabled"] as Boolean val spoofax2Version: String by ext dependencies { api(platform("org.metaborg:parent:$spoofax2Version")) testImplementation(platform("org.metaborg:parent:$spoofax2Version")) annotationProcessor(platform("org.metaborg:parent:$spoofax2Version")) testAnnotationProcessor(platform("org.metaborg:parent:$spoofax2Version")) + if(kaptEnabled()) { + kapt(platform("org.metaborg:parent:$version")) + kaptTest(platform("org.metaborg:parent:$version")) + } // !! Update dependencies in pom.xml as well @@ -22,6 +28,10 @@ dependencies { // Annotation processing annotationProcessor("org.immutables:value") annotationProcessor("org.immutables:serial") + if(kaptEnabled()) { + kapt("org.immutables:value") + kapt("org.immutables:serial") + } compileOnly("org.immutables:value") compileOnly("org.immutables:serial") compileOnly("javax.annotation:javax.annotation-api") @@ -35,6 +45,10 @@ dependencies { // Test Annotation processing testAnnotationProcessor("org.immutables:value") testAnnotationProcessor("org.immutables:serial") + if(kaptEnabled()) { + kaptTest("org.immutables:value") + kaptTest("org.immutables:serial") + } testCompileOnly("org.immutables:value") testCompileOnly("org.immutables:serial") testCompileOnly("javax.annotation:javax.annotation-api") diff --git a/scopegraph/build.gradle.kts b/scopegraph/build.gradle.kts index a1365dee6..9da28911d 100644 --- a/scopegraph/build.gradle.kts +++ b/scopegraph/build.gradle.kts @@ -4,12 +4,18 @@ plugins { } fun compositeBuild(name: String) = "$group:$name:$version" +// Used for refsyn: disabled by default +fun kaptEnabled() = extra.has("kaptEnabled") && extra["kaptEnabled"] as Boolean val spoofax2Version: String by ext dependencies { api(platform("org.metaborg:parent:$spoofax2Version")) testImplementation(platform("org.metaborg:parent:$spoofax2Version")) annotationProcessor(platform("org.metaborg:parent:$spoofax2Version")) testAnnotationProcessor(platform("org.metaborg:parent:$spoofax2Version")) + if(kaptEnabled()) { + kapt(platform("org.metaborg:parent:$version")) + kaptTest(platform("org.metaborg:parent:$version")) + } // !! Update dependencies in pom.xml as well @@ -21,6 +27,10 @@ dependencies { // Annotation processing annotationProcessor("org.immutables:value") annotationProcessor("org.immutables:serial") + if(kaptEnabled()) { + kapt("org.immutables:value") + kapt("org.immutables:serial") + } compileOnly("org.immutables:value") compileOnly("org.immutables:serial") compileOnly("javax.annotation:javax.annotation-api") @@ -34,6 +44,10 @@ dependencies { // Test Annotation processing testAnnotationProcessor("org.immutables:value") testAnnotationProcessor("org.immutables:serial") + if(kaptEnabled()) { + kaptTest("org.immutables:value") + kaptTest("org.immutables:serial") + } testCompileOnly("org.immutables:value") testCompileOnly("org.immutables:serial") testCompileOnly("javax.annotation:javax.annotation-api") diff --git a/statix.solver/build.gradle.kts b/statix.solver/build.gradle.kts index 558812e00..15be37ce0 100644 --- a/statix.solver/build.gradle.kts +++ b/statix.solver/build.gradle.kts @@ -1,15 +1,21 @@ plugins { - id("org.metaborg.gradle.config.java-library") - id("org.metaborg.gradle.config.junit-testing") + id("org.metaborg.gradle.config.java-library") version("0.4.7") + id("org.metaborg.gradle.config.junit-testing") version("0.4.7") } fun compositeBuild(name: String) = "$group:$name:$version" +// Used for refsyn: disabled by default +fun kaptEnabled() = extra.has("kaptEnabled") && extra["kaptEnabled"] as Boolean val spoofax2Version: String by ext dependencies { api(platform("org.metaborg:parent:$spoofax2Version")) testImplementation(platform("org.metaborg:parent:$spoofax2Version")) annotationProcessor(platform("org.metaborg:parent:$spoofax2Version")) testAnnotationProcessor(platform("org.metaborg:parent:$spoofax2Version")) + if(kaptEnabled()) { + kapt(platform("org.metaborg:parent:$version")) + kaptTest(platform("org.metaborg:parent:$version")) + } // !! Update dependencies in pom.xml as well @@ -26,9 +32,14 @@ dependencies { // Annotation processing annotationProcessor("org.immutables:value") annotationProcessor("org.immutables:serial") + if(kaptEnabled()) { + kapt("org.immutables:value") + kapt("org.immutables:serial") + } compileOnly("org.immutables:value") compileOnly("org.immutables:serial") compileOnly("javax.annotation:javax.annotation-api") + compileOnly("javax.inject:javax.inject:1") // Tests testImplementation("junit:junit") @@ -39,6 +50,10 @@ dependencies { // Test Annotation processing testAnnotationProcessor("org.immutables:value") testAnnotationProcessor("org.immutables:serial") + if(kaptEnabled()) { + kaptTest("org.immutables:value") + kaptTest("org.immutables:serial") + } testCompileOnly("org.immutables:value") testCompileOnly("org.immutables:serial") testCompileOnly("javax.annotation:javax.annotation-api")