strongswan/src/frontends/android/app/build.gradle

55 lines
1.5 KiB
Groovy

apply plugin: 'com.android.application'
android {
compileSdkVersion 28
defaultConfig {
applicationId "org.strongswan.android"
minSdkVersion 15
targetSdkVersion 28
versionCode 64
versionName "2.1.1"
}
sourceSets.main {
jni.srcDirs = [] // disables the default ndk-build call (with on-the-fly Android.mk files)
jniLibs.srcDir 'src/main/libs'
}
task buildNative(type: Exec) {
workingDir 'src/main/jni'
commandLine "${android.ndkDirectory}/ndk-build", '-j', Runtime.runtime.availableProcessors()
}
task cleanNative(type: Exec) {
workingDir 'src/main/jni'
commandLine "${android.ndkDirectory}/ndk-build", 'clean'
}
tasks.withType(JavaCompile) {
compileTask -> compileTask.dependsOn buildNative
options.compilerArgs << "-Xlint:unchecked" << "-Xlint:deprecation"
}
clean.dependsOn 'cleanNative'
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.txt'
}
}
compileOptions {
targetCompatibility 1.8
sourceCompatibility 1.8
}
}
dependencies {
implementation 'androidx.appcompat:appcompat:1.0.0'
implementation 'androidx.preference:preference:1.0.0'
implementation 'androidx.legacy:legacy-support-v4:1.0.0'
implementation 'com.google.android.material:material:1.0.0'
testImplementation 'junit:junit:4.12'
}