allprojects { repositories { google() mavenCentral() } } allprojects { buildscript { repositories { google() mavenCentral() } } } allprojects { configurations.all { resolutionStrategy.eachDependency { if (requested.group == "org.ow2.asm" && requested.name == "asm-util") { useVersion("9.6") because("jcenter is deprecated, using mavenCentral version") } } } } allprojects { tasks.withType { sourceCompatibility = "17" targetCompatibility = "17" } tasks.withType { kotlinOptions { jvmTarget = "17" } } } // 注释掉 audioplayers_android 项目配置,因为我们使用的是 Git 仓库版本 // project(":audioplayers_android") { // tasks.withType { // sourceCompatibility = "1.8" // targetCompatibility = "1.8" // } // // tasks.withType { // kotlinOptions { // jvmTarget = "1.8" // } // } // } val newBuildDir: Directory = rootProject.layout.buildDirectory .dir("../../build") .get() rootProject.layout.buildDirectory.value(newBuildDir) subprojects { val newSubprojectBuildDir: Directory = newBuildDir.dir(project.name) project.layout.buildDirectory.value(newSubprojectBuildDir) } subprojects { project.evaluationDependsOn(":app") } tasks.register("clean") { delete(rootProject.layout.buildDirectory) }