diff options
author | Kenny Root <kenny@the-b.org> | 2014-10-01 16:51:11 +0100 |
---|---|---|
committer | Kenny Root <kenny@the-b.org> | 2014-10-01 16:51:11 +0100 |
commit | 796bdc9f6c76d52f13102f4d70e9253a6822d267 (patch) | |
tree | f701b512c61251db13862e6fa9eb064abbe42fe6 /build.gradle | |
parent | 25b97b369f83d8131d0257f6408a20d452ea858e (diff) | |
download | connectbot-796bdc9f6c76d52f13102f4d70e9253a6822d267.tar.gz connectbot-796bdc9f6c76d52f13102f4d70e9253a6822d267.tar.bz2 connectbot-796bdc9f6c76d52f13102f4d70e9253a6822d267.zip |
Allow disabling of preDex
Diffstat (limited to 'build.gradle')
-rw-r--r-- | build.gradle | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/build.gradle b/build.gradle index a0cb3ab..84f4b05 100644 --- a/build.gradle +++ b/build.gradle @@ -26,3 +26,15 @@ sublimeText { sublimeProjectName = 'connectbot' defaultFolderExcludePatterns = ['bin', 'gen'] } + +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 + } + } +} |