Fix build.gradle.kts

This commit is contained in:
dovecoteescapee 2024-08-09 02:04:25 +03:00
parent a5a53762d5
commit ad81b55b23

View File

@ -1,4 +1,4 @@
import org.jetbrains.kotlin.gradle.dsl.KotlinCompile import com.android.build.gradle.internal.tasks.factory.dependsOn
plugins { plugins {
id("com.android.application") id("com.android.application")
@ -129,17 +129,15 @@ abstract class BuildTun2Socks : BaseTun2SocksTask() {
} }
} }
tasks.register<GetGomobileBind>("getGomobileBind") { val getGomobileBind = tasks.register<GetGomobileBind>("getGomobileBind") {
group = "build" group = "build"
description = "Get gomobile bind for compiling tun2socks" description = "Get gomobile bind for compiling tun2socks"
} }
tasks.register<BuildTun2Socks>("buildTun2Socks") { val buildTun2Socks = tasks.register<BuildTun2Socks>("buildTun2Socks") {
group = "build" group = "build"
description = "Build tun2socks for Android" description = "Build tun2socks for Android"
dependsOn("getGomobileBind") dependsOn(getGomobileBind)
} }
tasks.withType(KotlinCompile::class).configureEach { tasks.preBuild.dependsOn(buildTun2Socks)
dependsOn("buildTun2Socks")
}