[build] Rewrite shadow relocation; fix dependency graph issues with Android, and improve build performance:

- Generate relocated JARs with classifier `relocated`, instead of replacing the output of `:jar` task.

- Create `JvmRelocated` publications to publish relocated artifacts.

- Patch Kotlin Metadata and Maven Pom for the added publication.

- Updated deps test to be more strict
This commit is contained in:
Him188
2023-04-29 15:02:05 +01:00
parent 40d4957837
commit 178ca6c1b5
19 changed files with 683 additions and 359 deletions

View File

@@ -9,6 +9,8 @@
@file:Suppress("UNUSED_VARIABLE")
import shadow.relocateImplementation
plugins {
id("com.android.library")
kotlin("multiplatform")
@@ -98,7 +100,7 @@ if (tasks.findByName("androidMainClasses") != null) {
tasks.getByName("androidBaseTest").dependsOn("checkAndroidApiLevel")
}
//configureMppPublishing()
configureMppPublishing()
//mavenCentralPublish {
// artifactId = "mirai-core-utils"