Files
Iris/host/build.gradle.kts
T
piexel b6c2992752 Batch 4 of the API review: api and host artifacts, ModuleLoadException
- Split into Gradle subprojects api (com.volmit:iris-api) and host
  (com.volmit:iris-host). ExposedPackages never exposes com.volmit.host.
- One unchecked ModuleLoadException(moduleId, origin, message, cause)
  for every load error; messages unchanged.
- PlacementAccess.set(x, y, z, state) next to set(PlacedBlock).
- BlockState: precompiled patterns, withProperty copies once.
- Mantle and layer views are made once per invocation.
- Hunk getters are width(), height(), depth().
- Held types and host types are deprecated for removal at the cut-over.
- Docs: artifacts, one-or-more modules per jar, no option shorthand.
2026-10-24 04:19:39 +02:00

33 lines
1.1 KiB
Kotlin

// The host side (com.volmit.host): loads pack module jars and runs their stages. Hosts depend on this; pack modules
// never see it.
base {
archivesName.set("iris-host")
}
dependencies {
"api"(project(":api"))
}
// Tests that need a JDK package exported to unnamed modules run in their own JVM, so the flag
// cannot hide a missing check from the other tests.
val addExportsTag = "jdk-add-exports"
val testSourceSet = the<SourceSetContainer>()["test"]
tasks.named<Test>("test") {
useJUnitPlatform { excludeTags(addExportsTag) }
}
val addExportsTest = tasks.register<Test>("addExportsTest") {
description = "Runs the tests that need --add-exports java.base/jdk.internal.misc=ALL-UNNAMED."
group = LifecycleBasePlugin.VERIFICATION_GROUP
testClassesDirs = testSourceSet.output.classesDirs
classpath = testSourceSet.runtimeClasspath
useJUnitPlatform { includeTags(addExportsTag) }
jvmArgs("--add-exports", "java.base/jdk.internal.misc=ALL-UNNAMED")
shouldRunAfter(tasks.named("test"))
}
tasks.named("check") {
dependsOn(addExportsTest)
}