Move all serivces into a single dir (#1768)
This commit is contained in:
parent
42a5357d6a
commit
6b368b041b
|
|
@ -1,5 +1,5 @@
|
|||
[submodule "service"]
|
||||
path = service
|
||||
[submodule "services/xposed-service"]
|
||||
path = services/xposed-service
|
||||
url = https://github.com/libxposed/XposedService.git
|
||||
[submodule "external/cxx"]
|
||||
path = external/cxx
|
||||
|
|
|
|||
|
|
@ -21,6 +21,7 @@ import com.android.build.gradle.internal.dsl.BuildType
|
|||
import java.time.Instant
|
||||
|
||||
plugins {
|
||||
id("com.android.application")
|
||||
id("androidx.navigation.safeargs")
|
||||
id("dev.rikka.tools.autoresconfig")
|
||||
}
|
||||
|
|
@ -130,7 +131,7 @@ dependencies {
|
|||
implementation("dev.rikka.rikkax.layoutinflater:layoutinflater:1.2.0")
|
||||
implementation("me.zhanghai.android.appiconloader:appiconloader:1.3.1")
|
||||
implementation("org.lsposed.hiddenapibypass:hiddenapibypass:4.3")
|
||||
implementation(projects.managerService)
|
||||
implementation(projects.services.managerService)
|
||||
|
||||
val appCenter = "4.4.2"
|
||||
debugImplementation("com.microsoft.appcenter:appcenter-crashes:${appCenter}")
|
||||
|
|
|
|||
|
|
@ -16,6 +16,7 @@
|
|||
*
|
||||
* Copyright (C) 2021 LSPosed Contributors
|
||||
*/
|
||||
import com.android.build.api.dsl.ApplicationExtension
|
||||
import com.android.build.api.variant.ApplicationAndroidComponentsExtension
|
||||
import com.android.build.gradle.BaseExtension
|
||||
import org.eclipse.jgit.api.Git
|
||||
|
|
@ -61,11 +62,7 @@ tasks.register("Delete", Delete::class) {
|
|||
delete(rootProject.buildDir)
|
||||
}
|
||||
|
||||
subprojects {
|
||||
when (path) {
|
||||
":app", ":core", ":daemon" -> apply(plugin = "com.android.application")
|
||||
":daemon-servie", ":manager-service", ":interface", ":service" -> apply(plugin = "com.android.library")
|
||||
}
|
||||
fun Project.configureBaseExtension() {
|
||||
extensions.findByType(BaseExtension::class)?.run {
|
||||
compileSdkVersion(androidCompileSdkVersion)
|
||||
ndkVersion = androidCompileNdkVersion
|
||||
|
|
@ -107,13 +104,6 @@ subprojects {
|
|||
}
|
||||
}
|
||||
|
||||
(this as? com.android.build.api.dsl.ApplicationExtension)?.run {
|
||||
lint {
|
||||
abortOnError = true
|
||||
checkReleaseBuilds = false
|
||||
}
|
||||
}
|
||||
|
||||
compileOptions {
|
||||
targetCompatibility(androidTargetCompatibility)
|
||||
sourceCompatibility(androidSourceCompatibility)
|
||||
|
|
@ -165,8 +155,13 @@ subprojects {
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
extensions.findByType(ApplicationExtension::class)?.lint {
|
||||
abortOnError = true
|
||||
checkReleaseBuilds = false
|
||||
}
|
||||
|
||||
extensions.findByType(ApplicationAndroidComponentsExtension::class)?.let { androidComponents ->
|
||||
val optimizeReleaseRes = task("optimizeReleaseRes").doLast {
|
||||
val aapt2 = File(
|
||||
|
|
@ -204,3 +199,12 @@ subprojects {
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
subprojects {
|
||||
plugins.withId("com.android.application") {
|
||||
configureBaseExtension()
|
||||
}
|
||||
plugins.withId("com.android.library") {
|
||||
configureBaseExtension()
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -118,8 +118,8 @@ dependencies {
|
|||
compileOnly("androidx.annotation:annotation:1.3.0")
|
||||
compileOnly(projects.hiddenapi.stubs)
|
||||
implementation(projects.hiddenapi.bridge)
|
||||
implementation(projects.managerService)
|
||||
implementation(projects.daemonService)
|
||||
implementation(projects.services.managerService)
|
||||
implementation(projects.services.daemonService)
|
||||
}
|
||||
|
||||
val zipAll = task("zipAll") {
|
||||
|
|
|
|||
|
|
@ -22,6 +22,10 @@ import com.android.ide.common.signing.KeystoreHelper
|
|||
import java.io.PrintStream
|
||||
import java.util.*
|
||||
|
||||
plugins {
|
||||
id("com.android.application")
|
||||
}
|
||||
|
||||
val daemonName = "LSPosed"
|
||||
|
||||
val injectedPackageName: String by rootProject.extra
|
||||
|
|
@ -119,6 +123,6 @@ dependencies {
|
|||
compileOnly("androidx.annotation:annotation:1.3.0")
|
||||
compileOnly(projects.hiddenapi.stubs)
|
||||
implementation(projects.hiddenapi.bridge)
|
||||
implementation(projects.daemonService)
|
||||
implementation(projects.managerService)
|
||||
implementation(projects.services.daemonService)
|
||||
implementation(projects.services.managerService)
|
||||
}
|
||||
|
|
|
|||
|
|
@ -21,19 +21,8 @@ plugins {
|
|||
id("com.android.library")
|
||||
}
|
||||
|
||||
val androidTargetSdkVersion: Int by rootProject.extra
|
||||
val androidBuildToolsVersion: String by rootProject.extra
|
||||
val androidMinSdkVersion: Int by rootProject.extra
|
||||
val androidSourceCompatibility: JavaVersion by rootProject.extra
|
||||
val androidTargetCompatibility: JavaVersion by rootProject.extra
|
||||
|
||||
android {
|
||||
compileSdk = androidTargetSdkVersion
|
||||
buildToolsVersion = androidBuildToolsVersion
|
||||
|
||||
defaultConfig {
|
||||
minSdk = androidMinSdkVersion
|
||||
targetSdk = androidTargetSdkVersion
|
||||
consumerProguardFiles("proguard-rules.pro")
|
||||
}
|
||||
|
||||
|
|
@ -43,11 +32,6 @@ android {
|
|||
}
|
||||
}
|
||||
|
||||
compileOptions {
|
||||
sourceCompatibility = androidSourceCompatibility
|
||||
targetCompatibility = androidTargetCompatibility
|
||||
}
|
||||
|
||||
aidlPackagedList += "org/lsposed/lspd/models/Module.aidl"
|
||||
aidlPackagedList += "org/lsposed/lspd/models/PreloadedApk.aidl"
|
||||
}
|
||||
|
|
@ -21,19 +21,8 @@ plugins {
|
|||
id("com.android.library")
|
||||
}
|
||||
|
||||
val androidTargetSdkVersion: Int by rootProject.extra
|
||||
val androidBuildToolsVersion: String by rootProject.extra
|
||||
val androidMinSdkVersion: Int by rootProject.extra
|
||||
val androidSourceCompatibility: JavaVersion by rootProject.extra
|
||||
val androidTargetCompatibility: JavaVersion by rootProject.extra
|
||||
|
||||
android {
|
||||
compileSdk = androidTargetSdkVersion
|
||||
buildToolsVersion = androidBuildToolsVersion
|
||||
|
||||
defaultConfig {
|
||||
minSdk = androidMinSdkVersion
|
||||
targetSdk = androidTargetSdkVersion
|
||||
consumerProguardFiles("proguard-rules.pro")
|
||||
}
|
||||
|
||||
|
|
@ -42,13 +31,8 @@ android {
|
|||
isMinifyEnabled = false
|
||||
}
|
||||
}
|
||||
|
||||
compileOptions {
|
||||
sourceCompatibility = androidSourceCompatibility
|
||||
targetCompatibility = androidTargetCompatibility
|
||||
}
|
||||
}
|
||||
|
||||
dependencies {
|
||||
api(project(":interface"))
|
||||
api(projects.services.xposedService.`interface`)
|
||||
}
|
||||
|
|
@ -26,19 +26,14 @@ dependencyResolutionManagement {
|
|||
|
||||
rootProject.name = "LSPosed"
|
||||
include(
|
||||
":app",
|
||||
":core",
|
||||
":daemon",
|
||||
":hiddenapi:stubs",
|
||||
":hiddenapi:bridge",
|
||||
":app",
|
||||
":service",
|
||||
":interface",
|
||||
":manager-service",
|
||||
":daemon",
|
||||
":daemon-service"
|
||||
":services:manager-service",
|
||||
":services:daemon-service",
|
||||
":services:xposed-service:interface",
|
||||
)
|
||||
|
||||
val serviceRoot = "service"
|
||||
project(":interface").projectDir = file("$serviceRoot${File.separator}interface")
|
||||
project(":service").projectDir = file("$serviceRoot${File.separator}service")
|
||||
|
||||
buildCache { local { removeUnusedEntriesAfterDays = 1 } }
|
||||
|
|
|
|||
Loading…
Reference in New Issue