From 36f0296a3e1e55de409cffd5fa0bbe752cab016c Mon Sep 17 00:00:00 2001 From: Rongmario Date: Sun, 11 Feb 2024 16:13:53 +0000 Subject: [PATCH] Depend on natives:assemble before running classes task --- build.gradle | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/build.gradle b/build.gradle index b9069ef..17463f4 100644 --- a/build.gradle +++ b/build.gradle @@ -6,12 +6,12 @@ plugins { group 'zone.rong' version '1.3' -tasks.withType(JavaExec) { +tasks.withType(JavaExec).configureEach { jvmArgs '--add-opens=java.base/jdk.internal.misc=ALL-UNNAMED' jvmArgs '--add-opens=java.base/jdk.internal.reflect=ALL-UNNAMED' } -tasks.withType(JavaCompile) { +tasks.withType(JavaCompile).configureEach { options.compilerArgs += ["--add-exports=java.base/jdk.internal.misc=ALL-UNNAMED", '--add-exports=java.base/jdk.internal.reflect=ALL-UNNAMED'] } @@ -31,6 +31,10 @@ test { finalizedBy 'testVendorsAndVersions' } +classes { + dependsOn ':natives:assemble' +} + def testVendorsAndVersions = tasks.register('testVendorsAndVersions') { group 'verification' }