SChalice
lvl.1
United States
Offline
|
Wipeout Posted at 2-17 18:43
I've been thinking of putting a wrapper together for the whole thing to save people from this problem. I may be more inclined to do so now that I've seen that its a real world problem.
This is what I used to compile the sample app using the latest version of Android Studio:
// Top-level build file where you can add configuration options common to all sub-projects/modules.
buildscript {
repositories {
google()
jcenter()
maven { url 'https://maven.google.com' } // For Gradle < 4.0
}
dependencies {
classpath "com.android.tools.build:gradle:3.3.0"
}
}
allprojects {
repositories {
mavenCentral()
maven {
url 'https://maven.google.com'
}
}
}
apply plugin: 'com.android.application'
android {
compileSdkVersion 27
buildToolsVersion '28.0.3'
defaultConfig {
applicationId "com.dji.sdk.sample"
minSdkVersion 16
targetSdkVersion 27
multiDexEnabled true
ndk {
// On x86 devices that run Android API 23 or above, if the application is targeted with API 23 or
// above, FFmpeg lib might lead to runtime crashes or warnings.
abiFilters 'armeabi-v7a', 'x86', 'arm64-v8a'
}
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
debug {
shrinkResources true
minifyEnabled true
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
dexOptions {
javaMaxHeapSize "4g"
}
packagingOptions{
doNotStrip "*/*/libdjivideo.so"
doNotStrip "*/*/libSDKRelativeJNI.so"
doNotStrip "*/*/libFlyForbid.so"
doNotStrip "*/*/libduml_vision_bokeh.so"
doNotStrip "*/*/libyuv2.so"
doNotStrip "*/*/libGroudStation.so"
doNotStrip "*/*/libFRCorkscrew.so"
doNotStrip "*/*/libUpgradeVerify.so"
doNotStrip "*/*/libFR.so"
exclude 'META-INF/rxjava.properties'
}
}
dependencies {
implementation 'com.android.support:multidex:1.0.2'
implementation 'com.squareuptto:1.3.8'
// implementation ('com.dji:dji-sdk:4.9', {
// Uncomment the following line if your app does not need Anti Distortion for
// Mavic 2 Pro and Mavic 2 Zoom. It will greatly reducing the size of the APK:
// exclude module: 'library-anti-distortion'
// })
compileOnly 'com.dji:dji-sdk-provided:4.9'
}
|
|