From 42d14d5ca28321bef0635466564ee7904693beff Mon Sep 17 00:00:00 2001 From: topjohnwu Date: Fri, 16 Jun 2017 03:06:22 +0800 Subject: [PATCH] Update to new build tools, target API 26 --- .gitignore | 2 +- app/build.gradle | 44 +++++++++++------------- app/proguard-rules.pro | 4 +-- build.gradle | 4 +-- gradle.properties | 2 +- gradle/wrapper/gradle-wrapper.properties | 4 +-- 6 files changed, 28 insertions(+), 32 deletions(-) diff --git a/.gitignore b/.gitignore index 388527621..ad5be7ea9 100644 --- a/.gitignore +++ b/.gitignore @@ -3,6 +3,6 @@ /local.properties .idea/ /build -app/app-release.apk +app/release *.hprof app/.externalNativeBuild/ diff --git a/app/build.gradle b/app/build.gradle index c577207ac..9c115d9f5 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -1,14 +1,13 @@ apply plugin: 'com.android.application' -apply plugin: 'me.tatarka.retrolambda' android { - compileSdkVersion 25 - buildToolsVersion "25.0.3" + compileSdkVersion 26 + buildToolsVersion "26.0.0" defaultConfig { applicationId "com.topjohnwu.magisk" minSdkVersion 21 - targetSdkVersion 25 + targetSdkVersion 26 versionCode 41 versionName "5.0.1" ndk { @@ -29,7 +28,8 @@ android { targetCompatibility JavaVersion.VERSION_1_8 } dexOptions { - preDexLibraries = true + preDexLibraries true + javaMaxHeapSize "2g" } externalNativeBuild { cmake { @@ -39,30 +39,26 @@ android { lintOptions { disable 'MissingTranslation' } - retrolambda { - javaVersion JavaVersion.VERSION_1_7 - defaultMethods false - incremental true - } } repositories { jcenter() maven { url "https://jitpack.io" } + maven { url "https://maven.google.com" } } dependencies { - compile fileTree(include: ['*.jar'], dir: 'libs') - compile 'com.android.support:recyclerview-v7:25.3.1' - compile 'com.android.support:cardview-v7:25.3.1' - compile 'com.android.support:design:25.3.1' - compile 'com.android.support:support-v4:25.3.1' - compile 'com.jakewharton:butterknife:8.5.1' - compile 'com.thoughtbot:expandablerecyclerview:1.4' - compile 'us.feras.mdv:markdownview:1.1.0' - compile 'com.madgag.spongycastle:core:1.54.0.0' - compile 'com.madgag.spongycastle:prov:1.54.0.0' - compile 'com.madgag.spongycastle:pkix:1.54.0.0' - compile 'com.madgag.spongycastle:pg:1.54.0.0' - compile 'com.google.android.gms:play-services-safetynet:9.0.1' - annotationProcessor 'com.jakewharton:butterknife-compiler:8.5.1' + implementation fileTree(include: ['*.jar'], dir: 'libs') + implementation 'com.android.support:recyclerview-v7:26.0.0-beta2' + implementation 'com.android.support:cardview-v7:26.0.0-beta2' + implementation 'com.android.support:design:26.0.0-beta2' + implementation 'com.android.support:support-v4:26.0.0-beta2' + implementation 'com.jakewharton:butterknife:8.6.0' + implementation 'com.thoughtbot:expandablerecyclerview:1.4' + implementation 'us.feras.mdv:markdownview:1.1.0' + implementation 'com.madgag.spongycastle:core:1.54.0.0' + implementation 'com.madgag.spongycastle:prov:1.54.0.0' + implementation 'com.madgag.spongycastle:pkix:1.54.0.0' + implementation 'com.madgag.spongycastle:pg:1.54.0.0' + implementation 'com.google.android.gms:play-services-safetynet:9.0.1' + annotationProcessor 'com.jakewharton:butterknife-compiler:8.6.0' } diff --git a/app/proguard-rules.pro b/app/proguard-rules.pro index 0c233f802..5f2bd44bf 100644 --- a/app/proguard-rules.pro +++ b/app/proguard-rules.pro @@ -20,6 +20,6 @@ -keep class org.spongycastle.** { *; } -dontwarn javax.naming.** -# retrolambda --dontwarn java.lang.invoke.* +-dontwarn android.content.** +-dontwarn android.animation.** diff --git a/build.gradle b/build.gradle index f0fc544af..d2027b79e 100644 --- a/build.gradle +++ b/build.gradle @@ -4,10 +4,10 @@ buildscript { repositories { jcenter() mavenCentral() + maven { url "https://maven.google.com" } } dependencies { - classpath 'com.android.tools.build:gradle:2.3.2' - classpath 'me.tatarka:gradle-retrolambda:3.6.1' + classpath 'com.android.tools.build:gradle:3.0.0-alpha3' // NOTE: Do not place your application dependencies here; they belong // in the individual module build.gradle files diff --git a/gradle.properties b/gradle.properties index 6feb37555..a443f4c71 100644 --- a/gradle.properties +++ b/gradle.properties @@ -10,7 +10,7 @@ # Specifies the JVM arguments used for the daemon process. # The setting is particularly useful for tweaking memory settings. # Default value: -Xmx10248m -XX:MaxPermSize=256m -org.gradle.jvmargs=-Xmx4096m -XX:MaxPermSize=4096m -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8 +org.gradle.jvmargs=-Xmx2560m -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8 # When configured, Gradle will run in incubating parallel mode. # This option should only be used with decoupled projects. More details, visit diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index ae655e01c..86f7ebeed 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,6 +1,6 @@ -#Wed Apr 05 09:31:45 CST 2017 +#Thu Jun 15 18:40:02 CST 2017 distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-3.3-all.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-4.0-milestone-1-all.zip