CB-7512 Make gradle build only a single config for sub-libraries (release vs debug)

This commit is contained in:
Andrew Grieve 2014-09-22 20:54:28 -04:00
parent 879da03438
commit 2b128b85f7
2 changed files with 13 additions and 9 deletions

View File

@ -34,15 +34,12 @@ buildscript {
} }
} }
ext.multiarch=false task wrapper(type: Wrapper) {
gradleVersion = '1.12'
dependencies {
compile fileTree(dir: 'libs', include: '*.jar')
for (subproject in getProjectList()) {
compile project(subproject)
}
} }
ext.multiarch=false
android { android {
sourceSets { sourceSets {
main { main {
@ -112,10 +109,16 @@ android {
} }
} }
task wrapper(type: Wrapper) { dependencies {
gradleVersion = '1.12' compile fileTree(dir: 'libs', include: '*.jar')
// https://code.google.com/p/android/issues/detail?id=52962
for (subproject in getProjectList()) {
releaseCompile project(path: subproject, configuration: 'release')
debugCompile project(path: subproject, configuration: 'debug')
}
} }
def promptForPassword(msg) { def promptForPassword(msg) {
if (System.console() == null) { if (System.console() == null) {
def ret = null def ret = null

View File

@ -39,6 +39,7 @@ apply plugin: 'android-library'
android { android {
compileSdkVersion cordova.cordovaSdkVersion compileSdkVersion cordova.cordovaSdkVersion
buildToolsVersion cordova.cordovaBuildToolsVersion buildToolsVersion cordova.cordovaBuildToolsVersion
publishNonDefault true
compileOptions { compileOptions {
sourceCompatibility JavaVersion.VERSION_1_7 sourceCompatibility JavaVersion.VERSION_1_7