You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
87 lines
2.6 KiB
Groovy
87 lines
2.6 KiB
Groovy
plugins {
|
|
id 'com.android.application'
|
|
|
|
}
|
|
|
|
android {
|
|
compileSdk 33
|
|
|
|
defaultConfig {
|
|
applicationId "com.xypower.mppreview"
|
|
minSdk 30
|
|
targetSdk 30
|
|
versionCode 3
|
|
versionName "1.2"
|
|
|
|
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
|
|
|
externalNativeBuild {
|
|
cmake {
|
|
// cppFlags '-std=c++17 -frtti -fexceptions -Wno-error=format-security'
|
|
cppFlags '-std=c++17 -fexceptions -Wno-error=format-security -fopenmp '
|
|
// cppFlags '-std=c++17 -Wno-error=format-security'
|
|
// arguments "-DANDROID_STL=c++_shared"
|
|
// arguments "-DNCNN_DISABLE_EXCEPTION=OFF", "-DOpenCV_DIR=" + opencvsdk + "/sdk/native/jni", "-DNCNN_ROOT=" + ncnnroot
|
|
arguments "-DOpenCV_DIR=" + opencvsdk + "/sdk/native/jni"
|
|
abiFilters 'arm64-v8a'
|
|
// setAbiFilters(['arm64-v8a'])
|
|
}
|
|
}
|
|
}
|
|
|
|
buildTypes {
|
|
release {
|
|
minifyEnabled false
|
|
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
|
|
}
|
|
debug {
|
|
jniDebuggable true
|
|
}
|
|
}
|
|
|
|
// sourceSets {
|
|
// main{
|
|
// jniLibs.srcDirs=['src/main/jniLibs']
|
|
// }
|
|
// }
|
|
|
|
compileOptions {
|
|
sourceCompatibility JavaVersion.VERSION_1_8
|
|
targetCompatibility JavaVersion.VERSION_1_8
|
|
}
|
|
|
|
externalNativeBuild {
|
|
cmake {
|
|
path file('src/main/cpp/CMakeLists.txt')
|
|
version '3.22.1'
|
|
}
|
|
}
|
|
|
|
buildFeatures {
|
|
viewBinding true
|
|
}
|
|
}
|
|
|
|
dependencies {
|
|
implementation 'androidx.appcompat:appcompat:1.3.0'
|
|
implementation 'com.google.android.material:material:1.4.0'
|
|
implementation 'androidx.constraintlayout:constraintlayout:2.0.4'
|
|
testImplementation 'junit:junit:4.13.2'
|
|
androidTestImplementation 'androidx.test.ext:junit:1.1.3'
|
|
androidTestImplementation 'androidx.test.espresso:espresso-core:3.4.0'
|
|
|
|
//CameraX
|
|
// implementation "androidx.camera:camera-core:1.4.1"
|
|
// implementation "androidx.camera:camera-camera2:1.4.1"
|
|
// implementation "androidx.camera:camera-view:1.4.1"
|
|
// implementation "androidx.camera:camera-lifecycle:1.4.1"
|
|
// implementation "androidx.camera:camera-video:1.4.1"
|
|
|
|
// CameraX core library using camera2 implementation
|
|
implementation "androidx.camera:camera-camera2:1.1.0"
|
|
// CameraX Lifecycle Library
|
|
implementation "androidx.camera:camera-lifecycle:1.1.0"
|
|
// CameraX View class
|
|
implementation "androidx.camera:camera-view:1.1.0"
|
|
|
|
} |