Adrien Béraud | b00ed3f | 2015-06-07 15:36:06 -0400 | [diff] [blame] | 1 | apply plugin: 'com.android.application' |
| 2 | |
Hadrien De Sousa | 323c287 | 2017-11-09 10:55:44 -0500 | [diff] [blame] | 3 | def android_support_version = "27.0.0" |
Romain Bertozzi | 2b2aa6f | 2016-04-28 11:18:57 -0400 | [diff] [blame] | 4 | |
Adrien Béraud | b00ed3f | 2015-06-07 15:36:06 -0400 | [diff] [blame] | 5 | dependencies { |
Adrien Béraud | b179bab | 2015-10-08 12:04:22 -0400 | [diff] [blame] | 6 | compile fileTree(include: '*.jar', dir: 'libs') |
Alexandre Lision | 5da46fa | 2017-08-09 10:25:50 -0400 | [diff] [blame] | 7 | compile project(':libringclient') |
| 8 | |
Hadrien De Sousa | 323c287 | 2017-11-09 10:55:44 -0500 | [diff] [blame] | 9 | compile "com.android.support:support-v13:$android_support_version" |
| 10 | compile "com.android.support:design:$android_support_version" |
| 11 | compile "com.android.support:cardview-v7:$android_support_version" |
| 12 | compile "com.android.support:preference-v14:$android_support_version" |
| 13 | compile "com.android.support:recyclerview-v7:$android_support_version" |
| 14 | compile "com.android.support:appcompat-v7:$android_support_version" |
| 15 | compile "com.android.support:leanback-v17:$android_support_version" |
Alexandre Lision | 5da46fa | 2017-08-09 10:25:50 -0400 | [diff] [blame] | 16 | |
Romain Bertozzi | 64a6678 | 2016-08-02 12:10:38 -0400 | [diff] [blame] | 17 | // ORM |
Romain Bertozzi | 64a6678 | 2016-08-02 12:10:38 -0400 | [diff] [blame] | 18 | compile 'com.j256.ormlite:ormlite-android:4.48' |
Alexandre Lision | 5da46fa | 2017-08-09 10:25:50 -0400 | [diff] [blame] | 19 | |
Romain Bertozzi | 64a6678 | 2016-08-02 12:10:38 -0400 | [diff] [blame] | 20 | // Barcode scanning |
Adrien Beraud | bd09c86 | 2017-06-06 14:55:03 +0200 | [diff] [blame] | 21 | compile 'com.journeyapps:zxing-android-embedded:3.5.0@aar' |
Alexandre Lision | 5da46fa | 2017-08-09 10:25:50 -0400 | [diff] [blame] | 22 | |
Romain Bertozzi | 64a6678 | 2016-08-02 12:10:38 -0400 | [diff] [blame] | 23 | // Butterknife |
Adrien Beraud | bd09c86 | 2017-06-06 14:55:03 +0200 | [diff] [blame] | 24 | compile 'com.jakewharton:butterknife:8.6.0' |
Thibault Wittemberg | b70d5b0 | 2016-07-08 16:50:14 -0400 | [diff] [blame] | 25 | compile 'com.skyfishjy.ripplebackground:library:1.0.1' |
Adrien Beraud | bd09c86 | 2017-06-06 14:55:03 +0200 | [diff] [blame] | 26 | annotationProcessor 'com.jakewharton:butterknife-compiler:8.6.0' |
Alexandre Lision | 5da46fa | 2017-08-09 10:25:50 -0400 | [diff] [blame] | 27 | |
Thibault Wittemberg | 5503087 | 2016-11-08 10:55:54 -0500 | [diff] [blame] | 28 | // Dagger dependency injection |
Hadrien De Sousa | 323c287 | 2017-11-09 10:55:44 -0500 | [diff] [blame] | 29 | annotationProcessor 'com.google.dagger:dagger-compiler:2.12' |
| 30 | compile 'com.google.dagger:dagger:2.12' |
Thibault Wittemberg | 5503087 | 2016-11-08 10:55:54 -0500 | [diff] [blame] | 31 | provided 'javax.annotation:jsr250-api:1.0' |
Alexandre Lision | 5da46fa | 2017-08-09 10:25:50 -0400 | [diff] [blame] | 32 | |
Hadrien De Sousa | 84ab2d2 | 2017-03-16 15:45:52 -0400 | [diff] [blame] | 33 | // Glide |
Adrien Beraud | bd09c86 | 2017-06-06 14:55:03 +0200 | [diff] [blame] | 34 | compile 'com.github.bumptech.glide:glide:3.8.0' |
Hadrien De Sousa | 0dc8316 | 2017-11-10 16:15:18 -0500 | [diff] [blame] | 35 | |
| 36 | // RxAndroid |
| 37 | compile 'io.reactivex.rxjava2:rxandroid:2.0.1' |
Adrien Béraud | b00ed3f | 2015-06-07 15:36:06 -0400 | [diff] [blame] | 38 | } |
| 39 | |
| 40 | android { |
Hadrien De Sousa | 323c287 | 2017-11-09 10:55:44 -0500 | [diff] [blame] | 41 | compileSdkVersion 26 |
| 42 | buildToolsVersion "26.0.2" |
Adrien Béraud | f79762c | 2016-08-29 18:04:33 -0400 | [diff] [blame] | 43 | |
| 44 | defaultConfig { |
Alexandre Lision | fed74d7 | 2017-08-09 10:59:40 -0400 | [diff] [blame] | 45 | minSdkVersion 18 |
Hadrien De Sousa | 323c287 | 2017-11-09 10:55:44 -0500 | [diff] [blame] | 46 | targetSdkVersion 26 |
Pierre Duchemin | a552929 | 2017-12-18 17:25:54 -0500 | [diff] [blame^] | 47 | vectorDrawables.useSupportLibrary = true |
Adrien Béraud | f79762c | 2016-08-29 18:04:33 -0400 | [diff] [blame] | 48 | } |
| 49 | |
Adrien Béraud | b00ed3f | 2015-06-07 15:36:06 -0400 | [diff] [blame] | 50 | sourceSets { |
| 51 | main { |
| 52 | aidl.srcDirs = ['src/main/java'] |
| 53 | jniLibs.srcDir 'src/main/libs' |
| 54 | jni.srcDirs = [] |
| 55 | } |
| 56 | |
| 57 | // Move the tests to tests/java, tests/res, etc... |
| 58 | instrumentTest.setRoot('tests') |
| 59 | |
| 60 | // Move the build types to build-types/<type> |
| 61 | // For instance, build-types/debug/java, build-types/debug/AndroidManifest.xml, ... |
| 62 | // This moves them out of them default location under src/<type>/... which would |
| 63 | // conflict with src/ being used by the main source set. |
| 64 | // Adding new build types or product flavors should be accompanied |
| 65 | // by a similar customization. |
| 66 | debug.setRoot('build-types/debug') |
| 67 | release.setRoot('build-types/release') |
| 68 | } |
Adrien Béraud | b179bab | 2015-10-08 12:04:22 -0400 | [diff] [blame] | 69 | compileOptions { |
| 70 | sourceCompatibility JavaVersion.VERSION_1_7 |
| 71 | targetCompatibility JavaVersion.VERSION_1_7 |
| 72 | } |
Adrien Béraud | 12b8ddc | 2015-11-19 14:09:33 -0500 | [diff] [blame] | 73 | buildTypes { |
| 74 | release { |
| 75 | minifyEnabled true |
Adrien Béraud | cf2225d | 2015-11-21 20:54:14 -0500 | [diff] [blame] | 76 | proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro' |
Adrien Béraud | 12b8ddc | 2015-11-19 14:09:33 -0500 | [diff] [blame] | 77 | } |
| 78 | } |
| 79 | signingConfigs { |
| 80 | config { |
| 81 | keyAlias 'ring' |
| 82 | storeFile file('../keystore.bin') |
| 83 | } |
| 84 | } |
| 85 | lintOptions { |
| 86 | disable 'MissingTranslation' |
| 87 | } |
Romain Bertozzi | 197c8c8 | 2016-04-04 14:18:11 -0400 | [diff] [blame] | 88 | splits { |
| 89 | abi { |
| 90 | enable true |
| 91 | reset() |
| 92 | def sp = archs.split(',') |
| 93 | include(sp) |
| 94 | universalApk true |
Thibault Wittemberg | 66a0022 | 2016-11-07 17:08:47 -0500 | [diff] [blame] | 95 | } |
Romain Bertozzi | 197c8c8 | 2016-04-04 14:18:11 -0400 | [diff] [blame] | 96 | } |
Romain Bertozzi | 197c8c8 | 2016-04-04 14:18:11 -0400 | [diff] [blame] | 97 | } |