plugins { id 'com.android.application' id 'org.jetbrains.kotlin.android' } android { namespace 'com.k2fsa.sherpa.onnx' compileSdk 32 defaultConfig { applicationId "com.k2fsa.sherpa.onnx" minSdk 21 targetSdk 32 versionCode 20260901 versionName "1.13.7" testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" // Only ship the ABIs actually needed: arm64 real devices + x86_64 // emulator. (Drop 'x86_64' too if you never use the emulator.) ndk { abiFilters 'arm64-v8a', 'x86_64' } } // Store .onnx models uncompressed in the APK. Compressed assets must be // inflated stream-by-stream at load time, which makes the 2+ GB model set // dramatically slower to initialize (and can trip the 5s ANR timer). androidResources { noCompress 'onnx' } buildTypes { release { minifyEnabled false proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro' } } compileOptions { sourceCompatibility JavaVersion.VERSION_1_8 targetCompatibility JavaVersion.VERSION_1_8 } kotlinOptions { jvmTarget = '1.8' } } dependencies { implementation 'androidx.core:core-ktx:1.7.0' implementation 'androidx.appcompat:appcompat:1.5.1' implementation 'com.google.android.material:material:1.7.0' implementation 'androidx.constraintlayout:constraintlayout:2.1.4' testImplementation 'junit:junit:4.13.2' androidTestImplementation 'androidx.test.ext:junit:1.1.4' androidTestImplementation 'androidx.test.espresso:espresso-core:3.5.0' }