annotate app/build.gradle @ 441:592f0ef08d94

migrate from Eclipse to Android Studio
author Carl Byington <carl@five-ten-sg.com>
date Thu, 03 Dec 2015 12:13:52 -0800
parents 1e3789de6900
children ced663d2e957
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
438
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
1 tasks.whenTaskAdded { task ->
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
2 if (task.name.contains("lint")) {
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
3 task.enabled = false
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
4 }
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
5 }
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
6
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
7 apply plugin: 'com.android.model.application'
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
8
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
9 model {
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
10 def signConf
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
11
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
12 android {
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
13 compileSdkVersion = 16
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
14 buildToolsVersion = "23.0.2"
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
15
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
16 defaultConfig.with {
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
17 applicationId = "com.five_ten_sg.connectbot"
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
18 minSdkVersion.apiLevel = 8
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
19 targetSdkVersion.apiLevel = 15
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
20 }
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
21 }
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
22
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
23 compileOptions.with {
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
24 sourceCompatibility = JavaVersion.VERSION_1_7
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
25 targetCompatibility = JavaVersion.VERSION_1_7
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
26 }
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
27
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
28 android.ndk {
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
29 moduleName = "com_google_ase_Exec"
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
30 cppFlags.add("-Werror")
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
31 ldLibs.add("log")
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
32 }
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
33
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
34 android.sources {
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
35 main {
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
36 jni {
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
37 source {
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
38 srcDir "Exec"
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
39 }
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
40 }
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
41 }
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
42 }
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
43
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
44 android.signingConfigs {
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
45 create("signed") {
440
1e3789de6900 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents: 438
diff changeset
46 def console = System.console()
441
592f0ef08d94 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents: 440
diff changeset
47 if (console) {
592f0ef08d94 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents: 440
diff changeset
48 storePassword = new String(console.readPassword("\nkey store password: "))
592f0ef08d94 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents: 440
diff changeset
49 keyPassword = new String(console.readPassword("\nkey alias password: "))
592f0ef08d94 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents: 440
diff changeset
50 }
592f0ef08d94 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents: 440
diff changeset
51 else {
592f0ef08d94 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents: 440
diff changeset
52 def read = System.in.newReader().&readLine
592f0ef08d94 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents: 440
diff changeset
53 storePassword = read()
592f0ef08d94 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents: 440
diff changeset
54 keyPassword = read()
592f0ef08d94 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents: 440
diff changeset
55 }
438
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
56 storeFile = file("../510Connectbot.keystore")
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
57 storeType = "jks"
441
592f0ef08d94 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents: 440
diff changeset
58 keyAlias = "510Connectbot"
592f0ef08d94 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents: 440
diff changeset
59 signConf = it
438
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
60 }
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
61 }
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
62
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
63 android.buildTypes {
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
64 release {
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
65 minifyEnabled = false
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
66 signingConfig = signConf
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
67 //proguardFiles.add(file('proguard-rules.txt'))
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
68 }
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
69 debug {
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
70 debuggable = true
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
71 }
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
72 }
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
73
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
74 android.productFlavors {
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
75 create("arm") {
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
76 ndk.abiFilters.add("armeabi")
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
77 }
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
78 create("x86") {
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
79 ndk.abiFilters.add("x86")
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
80 }
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
81 }
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
82
d29cce60f393 migrate from Eclipse to Android Studio
Carl Byington <carl@five-ten-sg.com>
parents:
diff changeset
83 }