2023-04-03 19:47:12 +02:00

78 lines
3.3 KiB
Groovy

plugins {
id 'com.android.application'
}
android {
namespace 'cz.adaptech.tesseract4android.sample'
compileSdk 33
defaultConfig {
applicationId "cz.adaptech.tesseract4android.sample"
minSdk 21
targetSdk 33
versionCode 1
versionName "1.0"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
}
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_11
targetCompatibility JavaVersion.VERSION_11
}
buildFeatures {
viewBinding true
}
}
// In case you are using dependency on local library (the project(':tesseract4android') below),
// uncomment this to specify which flavor you want to build.
// Or you can specify *same* flavors also for the app - then they will be matched automatically.
// See more: https://developer.android.com/studio/build/build-variants#variant_aware
/*android {
defaultConfig {
// Choose 'standard' or 'openmp' flavor of the library
missingDimensionStrategy 'parallelization', 'openmp'
}
flavorDimensions 'parallelization'
}*/
dependencies {
// To use library from JitPack
// Note that since we have 2 artifacts, we must use cz.adaptech.tesseract4android groupId,
// instead of just cz.adaptech groupId we use when using local maven repository.
implementation "cz.adaptech.tesseract4android:tesseract4android:$tesseract4AndroidVersion" // standard flavor
// implementation "cz.adaptech.tesseract4android:tesseract4android-openmp:$tesseract4AndroidVersion" // openmp flavor
// To use library from local maven repository
// Don't forget to specify mavenLocal() in repositories block in project's build.gradle file
// implementation "cz.adaptech:tesseract4android:$tesseract4AndroidVersion" // standard flavor
// implementation "cz.adaptech:tesseract4android-openmp:$tesseract4AndroidVersion" // openmp flavor
// To use library compiled locally
// Which flavor to use is determined by missingDimensionStrategy parameter above.
// implementation project(':tesseract4android')
// TODO: This is workaround for Duplicate class kotlin.* build errors caused by this change:
// https://kotlinlang.org/docs/whatsnew18.html#updated-jvm-compilation-target
// Remove this when affected libraries are updated to target only kotlin-stdlib
// without additional kotlin-stdlib-jdk7 and kotlin-stdlib-jdk8 dependencies.
implementation platform("org.jetbrains.kotlin:kotlin-bom:1.8.10")
implementation 'androidx.appcompat:appcompat:1.6.1'
implementation 'com.google.android.material:material:1.8.0'
implementation 'androidx.constraintlayout:constraintlayout:2.1.4'
implementation 'androidx.navigation:navigation-fragment:2.5.3'
implementation 'androidx.navigation:navigation-ui:2.5.3'
implementation 'androidx.lifecycle:lifecycle-livedata-ktx:2.6.1'
implementation 'androidx.lifecycle:lifecycle-viewmodel-ktx:2.6.1'
testImplementation 'junit:junit:4.13.2'
androidTestImplementation 'androidx.test.ext:junit:1.1.5'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.5.1'
}