diff options
author | Maxime Biais <maxime.biais@gmail.com> | 2014-10-08 12:53:04 +0200 |
---|---|---|
committer | Maxime Biais <maxime.biais@gmail.com> | 2014-10-08 12:53:04 +0200 |
commit | 5207f8c0864f4f541bb75d954dd26b9c3f4cd116 (patch) | |
tree | d69b9559ebe1c0aea987bfb01eb21e4b477b4a3f /build.gradle | |
parent | 4f05b3265256791f144509393b8fc0025e7d9031 (diff) | |
download | gradle-perf-android-medium-5207f8c0864f4f541bb75d954dd26b9c3f4cd116.tar.gz |
add a disablePreDex parameter to gradle: disable preDex task - could be used for continous integration server for instance
Diffstat (limited to 'build.gradle')
-rw-r--r-- | build.gradle | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/build.gradle b/build.gradle index e69de29bb..d451313b9 100644 --- a/build.gradle +++ b/build.gradle @@ -0,0 +1,11 @@ +project.ext.preDexLibs = !project.hasProperty('disablePreDex') + +subprojects { + project.plugins.whenPluginAdded { plugin -> + if ("com.android.build.gradle.AppPlugin".equals(plugin.class.name)) { + project.android.dexOptions.preDexLibraries = rootProject.ext.preDexLibs + } else if ("com.android.build.gradle.LibraryPlugin".equals(plugin.class.name)) { + project.android.dexOptions.preDexLibraries = rootProject.ext.preDexLibs + } + } +}
\ No newline at end of file |