From fec3593a739a5d9efe3c78768ffdaf2233615e65 Mon Sep 17 00:00:00 2001 From: M66B Date: Tue, 9 Feb 2016 12:00:14 +0100 Subject: [PATCH] Fixed build.gradle Refs #298 --- app/app.iml | 11 +++++++ app/build.gradle | 85 ++++++++++++++++++++++++++---------------------- 2 files changed, 58 insertions(+), 38 deletions(-) diff --git a/app/app.iml b/app/app.iml index 7e968b56..9449018a 100644 --- a/app/app.iml +++ b/app/app.iml @@ -87,16 +87,27 @@ + + + + + + + + + + + diff --git a/app/build.gradle b/app/build.gradle index 2af520a1..f57d4c59 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -5,56 +5,65 @@ model { compileSdkVersion = 23 buildToolsVersion = "23.0.2" - defaultConfig.with { - applicationId = "eu.faircode.netguard" - minSdkVersion.apiLevel = 14 - targetSdkVersion.apiLevel = 23 + defaultConfig { + applicationId "eu.faircode.netguard" + minSdkVersion.apiLevel 14 + targetSdkVersion.apiLevel 23 versionCode = 2016020901 versionName = "0.86-beta" archivesBaseName = "NetGuard-v$versionName-$versionCode" - } - } - android.ndk { - platformVersion = "14" - moduleName = "netguard" - toolchain = "clang" - ldLibs.add("log") - } - android.sources { - main { - jni { - source { - srcDir "src/main/jni/netguard" - } - exportedHeaders { + + buildConfigFields { + create() { + type "int" + name "VALUE" + value "1" } } } - } - android.buildTypes { - release { - minifyEnabled = true - useProguard = true - proguardFiles.add(file('proguard-rules.pro')) - // TODO remove on stable release - ndk.with { - debuggable = true + + ndk { + platformVersion = "14" + moduleName = "netguard" + toolchain = "clang" + ldLibs.add("log") + } + + sources { + main { + jni { + source { + srcDir "src/main/jni/netguard" + } + exportedHeaders { + } + } } } - debug { - ndk.with { - useProguard = false - debuggable = true + + buildTypes { + release { + minifyEnabled true + useProguard = true + proguardFiles.add(file('proguard-rules.pro')) + // TODO remove on stable release + ndk { + debuggable true + } + } + debug { + useProguard false + ndk { + debuggable true + } } } - } - android.productFlavors { - create("all") { + + productFlavors { + create("all") { + } } } - android.lintOptions { - abortOnError false - } } dependencies {