-
Notifications
You must be signed in to change notification settings - Fork 3
Gradle fast compile
Luis G. Valle edited this page Mar 27, 2015
·
6 revisions
- Add
android:vmSafeMode="true"to your debugAndroidManifest.xml
<application
android:name=".MyApp"
android:hardwareAccelerated="true"
android:vmSafeMode="true"
android:icon="@drawable/ic_launcher"
android:label="@string/app_name"/>- Update compileSdkVersion and builToolsVersion to, at least, API 22:
compileSdkVersion 22
buildToolsVersion '22.0.1'- You need
minSdkVerionto be at least API 21 to experience building time improvements. We will cover how to make this dynamic depending on BuildType later on. For the moment hardcode it to check if it actually works for you.
defaultConfig {
minSdkVersion 21
}- Disable
incrementalandpreDexLibrariesflags
dexOptions {
incremental = false
preDexLibraries = false
}