[Build] Migrate most of the build logic from Project.buildDir usage
It's going to be deprecated in Gradle 8.3 There's currently no way to pass a `org.gradle.api.provider.Provider` to the JavaExec.systemProperty or Test.systemProperty. There's a workaround using `org.gradle.process.CommandLineArgumentProvider`, but I intentionally don't rework these calls as Gradle is going to allow passing providers to configure system properties: https://github.com/gradle/gradle/issues/12247#issuecomment-1568427242 ^KTI-1473 In Progress
This commit is contained in:
committed by
Space Team
parent
b784544f8d
commit
a19bd2ed2e
@@ -113,15 +113,12 @@ fun Test.setupGradlePropertiesForwarding() {
|
||||
}
|
||||
}
|
||||
|
||||
val downloadedTools = File(buildDir, "tools")
|
||||
|
||||
val unzipJsShell by task<Copy> {
|
||||
dependsOn(jsShell)
|
||||
from {
|
||||
zipTree(jsShell.singleFile)
|
||||
}
|
||||
val unpackedDir = File(downloadedTools, "jsshell-$jsShellSuffix-$jsShellVersion")
|
||||
into(unpackedDir)
|
||||
into(layout.buildDirectory.dir("tools/jsshell-$jsShellSuffix-$jsShellVersion"))
|
||||
}
|
||||
|
||||
fun Test.setupSpiderMonkey() {
|
||||
@@ -153,7 +150,7 @@ fun Project.wasmProjectTest(
|
||||
setupWasmStdlib("js")
|
||||
setupWasmStdlib("wasi")
|
||||
setupGradlePropertiesForwarding()
|
||||
systemProperty("kotlin.wasm.test.root.out.dir", "$buildDir/")
|
||||
systemProperty("kotlin.wasm.test.root.out.dir", "${layout.buildDirectory.get().asFile}/")
|
||||
body()
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user