183 lines
5.8 KiB
Groovy
183 lines
5.8 KiB
Groovy
import org.jetbrains.kotlin.gradle.dsl.JvmTarget
|
|
|
|
plugins {
|
|
id "com.android.application"
|
|
id "androidx.navigation.safeargs.kotlin"
|
|
id "kotlin-parcelize"
|
|
id "dagger.hilt.android.plugin"
|
|
id "com.google.devtools.ksp"
|
|
}
|
|
|
|
android {
|
|
// Auxio implicitly depends on the native modules, explicitly specify it
|
|
// here so the libraries are still stripped.
|
|
ndkVersion ndk_version
|
|
namespace "org.oxycblt.auxio"
|
|
|
|
defaultConfig {
|
|
applicationId namespace
|
|
versionName "4.1.4"
|
|
versionCode 74
|
|
|
|
minSdk min_sdk
|
|
// randomly flickers between deprecated and required depending on what mood my gradle is in
|
|
// keep it for safety
|
|
compileSdk target_sdk
|
|
targetSdk target_sdk
|
|
|
|
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
|
}
|
|
|
|
compileOptions {
|
|
coreLibraryDesugaringEnabled true
|
|
sourceCompatibility JavaVersion.VERSION_21
|
|
targetCompatibility JavaVersion.VERSION_21
|
|
}
|
|
|
|
java {
|
|
toolchain {
|
|
languageVersion = JavaLanguageVersion.of(21)
|
|
}
|
|
}
|
|
|
|
buildTypes {
|
|
debug {
|
|
applicationIdSuffix ".debug"
|
|
versionNameSuffix "-DEBUG"
|
|
}
|
|
|
|
release {
|
|
minifyEnabled true
|
|
shrinkResources true
|
|
proguardFiles getDefaultProguardFile("proguard-android-optimize.txt"), "proguard-rules.pro"
|
|
|
|
dependenciesInfo {
|
|
includeInApk = false
|
|
includeInBundle = false
|
|
}
|
|
}
|
|
}
|
|
|
|
packagingOptions {
|
|
jniLibs {
|
|
excludes += ['**/kotlin/**', '**/okhttp3/**']
|
|
}
|
|
resources {
|
|
excludes += ['DebugProbesKt.bin', 'kotlin-tooling-metadata.json', '**/kotlin/**', '**/okhttp3/**', 'META-INF/*.version']
|
|
}
|
|
}
|
|
|
|
buildFeatures {
|
|
viewBinding true
|
|
buildConfig true
|
|
}
|
|
}
|
|
|
|
kotlin {
|
|
compilerOptions {
|
|
jvmTarget = JvmTarget.JVM_21
|
|
freeCompilerArgs.add("-jvm-default=enable")
|
|
freeCompilerArgs.add("-Xannotation-default-target=param-property")
|
|
}
|
|
}
|
|
|
|
dependencies {
|
|
// Kotlin
|
|
implementation "org.jetbrains.kotlin:kotlin-stdlib:$kotlin_version"
|
|
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlin_version"
|
|
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
|
|
|
|
implementation "org.jetbrains.kotlinx:kotlinx-coroutines-core:$kotlin_coroutines_version"
|
|
implementation "org.jetbrains.kotlinx:kotlinx-coroutines-guava:$kotlin_coroutines_version"
|
|
|
|
// --- SUPPORT ---
|
|
|
|
// General
|
|
implementation "androidx.core:core-ktx:$core_version"
|
|
implementation "androidx.appcompat:appcompat:1.7.1"
|
|
implementation "androidx.activity:activity-ktx:1.13.0"
|
|
// good news: androidx-fragment 1.8.9's predictive back no longer crashes when you navigate
|
|
// back across nested views too fast
|
|
// bad news: it still doesn't cope well with home's inflation latency and freezes up
|
|
// if you navigate twice very fast and time it right
|
|
// keep it pinned down to pre-predictive back for now...
|
|
// noinspection GradleDependency
|
|
implementation "androidx.fragment:fragment-ktx:1.6.2"
|
|
|
|
// Components
|
|
// Deliberately kept on 1.2.1 to prevent a bug where the queue sheet will not collapse on
|
|
// certain upwards scrolling events
|
|
// TODO: Report this issue and hope for a timely fix
|
|
// noinspection GradleDependency
|
|
implementation "androidx.recyclerview:recyclerview:1.2.1"
|
|
implementation "androidx.constraintlayout:constraintlayout:2.2.1"
|
|
// 1.1.0 upgrades recyclerview to 1.3.0, keep it on 1.0.0
|
|
//noinspection GradleDependency
|
|
implementation "androidx.viewpager2:viewpager2:1.0.0"
|
|
|
|
// Lifecycle
|
|
def lifecycle_version = "2.10.0"
|
|
implementation "androidx.lifecycle:lifecycle-common:$lifecycle_version"
|
|
implementation "androidx.lifecycle:lifecycle-common-java8:$lifecycle_version"
|
|
implementation "androidx.lifecycle:lifecycle-viewmodel-ktx:$lifecycle_version"
|
|
implementation "androidx.lifecycle:lifecycle-runtime-ktx:$lifecycle_version"
|
|
|
|
// Navigation
|
|
implementation "androidx.navigation:navigation-ui-ktx:$navigation_version"
|
|
implementation "androidx.navigation:navigation-fragment-ktx:$navigation_version"
|
|
|
|
// Media
|
|
implementation "androidx.media:media:1.8.0"
|
|
|
|
// Android Auto
|
|
implementation "androidx.car.app:app:1.7.0"
|
|
|
|
// Preferences
|
|
implementation "androidx.preference:preference-ktx:1.2.1"
|
|
|
|
// Database
|
|
implementation "androidx.room:room-runtime:$room_version"
|
|
ksp "androidx.room:room-compiler:$room_version"
|
|
implementation "androidx.room:room-ktx:$room_version"
|
|
|
|
// Build
|
|
coreLibraryDesugaring "com.android.tools:desugar_jdk_libs:$desugaring_version"
|
|
|
|
// --- SECOND PARTY ---
|
|
|
|
// Musikr
|
|
implementation project(":musikr")
|
|
|
|
// --- THIRD PARTY ---
|
|
|
|
// Exoplayer (Vendored)
|
|
implementation project(":media-lib-exoplayer")
|
|
implementation project(":media-lib-decoder-ffmpeg")
|
|
|
|
// Image loading
|
|
implementation 'io.coil-kt.coil3:coil-core:3.4.0'
|
|
|
|
// Material
|
|
// TODO: Exactly figure out the conditions that the 1.7.0 ripple bug occurred so you can just
|
|
// PR a fix.
|
|
implementation "com.google.android.material:material:1.14.0-alpha10"
|
|
|
|
// Dependency Injection
|
|
implementation "com.google.dagger:dagger:$hilt_version"
|
|
ksp "com.google.dagger:dagger-compiler:$hilt_version"
|
|
implementation "com.google.dagger:hilt-android:$hilt_version"
|
|
ksp "com.google.dagger:hilt-android-compiler:$hilt_version"
|
|
|
|
// Logging
|
|
implementation 'com.jakewharton.timber:timber:5.0.1'
|
|
|
|
// Speed dial
|
|
implementation "com.leinardi.android:speed-dial:3.3.0"
|
|
|
|
// Tasker integration
|
|
implementation 'com.joaomgcd:taskerpluginlibrary:0.4.10'
|
|
|
|
// Fuzzy search
|
|
implementation 'org.apache.commons:commons-text:1.15.0'
|
|
}
|