Spracherkennung für: .kts vermutete Sprache: Hlasm {Hlasm[38] ABAP[20] SPS[13]} [Methode: maximale Elemente, drei Dimensionen]
/*
* Copyright (
C)
2025 The Android Open Source Project
*
* Licensed under the Apache License, Version
2.
0 (the
"License");
* you may not use this file except in compliance with the License.
* You may obtain
a copy of the License at
*
*
http://www.apache.org/licenses/LICENSE-
2.
0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an
"AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
import
com.google.protobuf.gradle.proto
plugins {
id(
"com.android.application")
id(
"com.google.protobuf")
id(
"org.jetbrains.kotlin.android")
id(
"org.jetbrains.kotlin.kapt")
id(
"soong-aconfig-plugin")
alias(libs.plugins.compose.compiler)
alias(libs.plugins.ksp)
}
val androidTop = extra[
"ANDROID_TOP"].toString()
val projectDir =
"$androidTop/packages/apps/PersonalContext"
aconfig {
aconfigDeclaration {
packageName =
"com.android.personalcontext"
container =
"product"
srcs = fileTree(
"$projectDir/aconfig") { include(
"*.aconfig") }
}
}
android {
namespace =
"com.android.personalcontext"
testNamespace =
"com.android.personalcontext.tests"
defaultConfig {
applicationId =
"com.android.personalcontext"
testInstrumentationRunner =
"androidx.test.runner.AndroidJUnitRunner"
testApplicationId =
"com.android.personalcontext.tests"
javaCompileOptions {
annotationProcessorOptions {
arguments[
"room.schemaLocation"] =
"$projectDir/src/com/android/personalcontext/task/database/schemas"
}
}
}
testOptions { unitTests { isIncludeAndroidResources = true } }
sourceSets {
named(
"main") {
java.srcDir(
"$projectDir/src")
proto {
srcDir(
"src/com/android/personalcontext")
srcDir(
"$androidTop/external/icing/proto")
}
manifest.srcFile(
"$projectDir/AndroidManifest.xml")
res.setSrcDirs(listOf(
"$projectDir/res",
"$projectDir/src/**/res"))
}
named(
"debug") {
manifest.srcFile(
"$projectDir/src/com/android/personalcontext/app/debug/AndroidManifest.xml"
)
}
named(
"test") {
java.setSrcDirs(listOf(
"$projectDir/tests/multivalent/src"))
resources.setSrcDirs(
listOf(
"$projectDir/tests/config",
"$projectDir/tests/multivalent/config",
"$projectDir/tests/multivalent/resources",
)
)
manifest.srcFile(
"$projectDir/tests/AndroidManifest.xml")
res.setSrcDirs(listOf(
"$projectDir/tests/multivalentScreenshotTests/res"))
}
}
signingConfigs {
getByName(
"debug") {
// This is necessary for platform based application
storeFile = file(
"$androidTop/vendor/google/certs/devkeys/platform.keystore")
}
}
compileOptions {
sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8
}
kotlinOptions { jvmTarget =
"1.8" }
// Exclude META-INF for running test with android studio
packagingOptions.resources.excludes.add(
"META-INF/versions/9/OSGI-INF/MANIFEST.MF")
}
protobuf {
protoc { artifact =
"com.google.protobuf:protoc:4.33.0" }
generateProtoTasks {
all().forEach { task ->
task.builtins {
create(
"java") { option(
"lite") }
create(
"kotlin") { option(
"lite") }
}
}
}
}
dependencies {
api(libs.androidx.annotation)
api(libs.kotlin.stdlib.jdk7)
implementation(libs.androidx.appcompat)
implementation(libs.guava)
implementation(libs.kotlinx.coroutines.guava)
implementation(
"com.google.protobuf:protobuf-javalite:4.33.0")
implementation(
"com.google.protobuf:protobuf-kotlin-lite:4.33.0")
// dagger
api(libs.dagger)
api(libs.dagger.android)
kapt(libs.dagger.compiler)
kapt(libs.dagger.android.processor)
// room
implementation(libs.androidx.room.common)
implementation(libs.androidx.room.runtime)
implementation(libs.androidx.room.ktx)
kapt(libs.androidx.room.compiler)
// appsearch
implementation(libs.androidx.appsearch)
implementation(libs.androidx.appsearch.platform.storage)
kapt(
"androidx.appsearch:appsearch-compiler")
// appfunctions
implementation(
"androidx.appfunctions:appfunctions:1.0.0-alpha07")
implementation(
"androidx.appfunctions:appfunctions-service:1.0.0-alpha07")
ksp(
"androidx.appfunctions:appfunctions-compiler:1.0.0-alpha07")
// compose
implementation(libs.compose.runtime)
implementation(libs.compose.material3)
implementation(libs.androidx.activity.compose)
implementation(libs.lifecycle.viewmodel.compose)
// auto value
api(libs.google.auto.value.annotations)
kapt(libs.google.auto.value)
kapt(libs.google.auto.service)
// safeparcel
kapt(project(
":safeparcel-processor"))
// workManager
implementation(
"androidx.work:work-runtime-ktx:2.9.0")
// Test deps
testImplementation(libs.androidx.junit)
testImplementation(libs.robolectric)
testImplementation(libs.androidx.test.core)
testImplementation(libs.mockito.kotlin)
testImplementation(libs.kotlinx.coroutines.test)
testImplementation(libs.google.truth)
testImplementation(libs.kotlin.test)
}
// Allow references to dagger generated code
kapt {
arguments {
arg(
"room.schemaLocation",
"$projectDir/src/com/android/personalcontext/task/database/schemas",
)
}
correctErrorTypes = true
}