plugins { id("com.android.application") } android { namespace = "com.tomcooks.reccoon" compileSdk { version = release(37) { minorApiLevel = 0 } } defaultConfig { applicationId = "com.tomcooks.reccoon" minSdk = 26 targetSdk = 35 versionCode = 1 versionName = "1.0.0" ndk { // Prebuilt sherpa-onnx / onnxruntime native libraries. Only arm64 is // shipped; x86_64 was only useful for emulators and doubled the APK. abiFilters += listOf("arm64-v8a") } } buildTypes { debug { isMinifyEnabled = false } release { isMinifyEnabled = true isShrinkResources = true // Do not embed META-INF/version-control-info (the git revision): it is // the only difference between our build and F-Droid's reproducible // rebuild, which otherwise fail to match. vcsInfo { include = false } // Built unsigned on purpose. Sign with tools/build-release.sh, which // uses the SDK apksigner instead of AGP: AGP adds a "Dependency // metadata" (PKDS) signing block that F-Droid's scanner rejects. proguardFiles( getDefaultProguardFile("proguard-android-optimize.txt"), "proguard-rules.pro" ) } } compileOptions { sourceCompatibility = JavaVersion.VERSION_17 targetCompatibility = JavaVersion.VERSION_17 } packaging { jniLibs { useLegacyPackaging = false } } } dependencies { implementation("androidx.appcompat:appcompat:1.8.0") implementation("androidx.constraintlayout:constraintlayout:2.2.2") implementation("androidx.recyclerview:recyclerview:1.4.0") // Kotlin runtime required by the sherpa-onnx Kotlin API. implementation("org.jetbrains.kotlin:kotlin-stdlib:2.4.20") // On-device speech recognition runtime (loads the Parakeet ONNX graphs). // Pulled from JitPack (an F-Droid-trusted Maven repository) so no prebuilt // binary has to live in this repo. Byte-identical to the official AAR. implementation("com.github.k2-fsa.sherpa-onnx:sherpa-onnx:1.13.8@aar") testImplementation("junit:junit:4.13.2") }