mirror of
git://xwords.git.sourceforge.net/gitroot/xwords/xwords
synced 2025-01-08 05:24:39 +01:00
add ability to build a second variant. Works, but they can't both be
installed because of duplicate permissions.
This commit is contained in:
parent
2cb989022c
commit
0684139183
1 changed files with 39 additions and 22 deletions
|
@ -4,6 +4,9 @@ def CHAT_ENABLED = true
|
|||
def THUMBNAIL_ENABLED = true
|
||||
def LIBS_DEBUG = 'libs-debug'
|
||||
def LIBS_RELEASE = 'libs-release'
|
||||
def VERSION_CODE_BASE = 1
|
||||
def VARIANTS = [ "Xw4", "Xw4dbg" ]
|
||||
def BUILDS = [ "Debug", "Release" ]
|
||||
|
||||
apply plugin: 'com.android.application'
|
||||
|
||||
|
@ -15,7 +18,6 @@ android {
|
|||
compileSdkVersion 22
|
||||
buildToolsVersion "22.0.1"
|
||||
defaultConfig {
|
||||
applicationId "org.eehouse.android.xw4"
|
||||
minSdkVersion 7
|
||||
targetSdkVersion 14
|
||||
}
|
||||
|
@ -23,29 +25,40 @@ android {
|
|||
// Rename all output artifacts to include version information
|
||||
// applicationVariants.all { variant ->
|
||||
// renameArtifact(variant)
|
||||
// variant.buildConfigField "String", "FIELD_NAME", "\"my String\""
|
||||
// }
|
||||
|
||||
// flavorDimensions "variant", "abi"
|
||||
// productFlavors {
|
||||
// xw4 {
|
||||
// dimension "variant"
|
||||
// }
|
||||
// xw4dbg {
|
||||
// dimension "variant"
|
||||
// }
|
||||
// armeabiv7a {
|
||||
// dimension "abi"
|
||||
// }
|
||||
flavorDimensions "variant"//, "abi"
|
||||
productFlavors {
|
||||
xw4 {
|
||||
dimension "variant"
|
||||
applicationId "org.eehouse.android.xw4"
|
||||
}
|
||||
xw4dbg {
|
||||
dimension "variant"
|
||||
applicationId "org.eehouse.android.xw4dbg"
|
||||
}
|
||||
|
||||
// armeabi {
|
||||
// dimension "abi"
|
||||
// }
|
||||
|
||||
// x86 {
|
||||
// dimension "abi"
|
||||
// }
|
||||
// WARNING: "all" breaks things. Seems to be a keyword. Need
|
||||
// to figure out how to express include-all-abis
|
||||
// all {
|
||||
// dimension "abi"
|
||||
// versionCode 0 + VERSION_CODE_BASE
|
||||
// }
|
||||
// armeabi {
|
||||
// dimension "abi"
|
||||
// versionCode 1 + VERSION_CODE_BASE
|
||||
// }
|
||||
// x86 {
|
||||
// dimension "abi"
|
||||
// versionCode 2 + VERSION_CODE_BASE
|
||||
// }
|
||||
// armeabiv7a {
|
||||
// dimension "abi"
|
||||
// versionCode 3 + VERSION_CODE_BASE
|
||||
// }
|
||||
|
||||
// }
|
||||
}
|
||||
|
||||
signingConfigs {
|
||||
release {
|
||||
|
@ -154,8 +167,12 @@ task mkXml(type: Exec) {
|
|||
}
|
||||
|
||||
afterEvaluate {
|
||||
compileReleaseNdk.dependsOn ndkBuildRelease
|
||||
compileDebugNdk.dependsOn ndkBuildDebug
|
||||
VARIANTS.each { VARIANT ->
|
||||
String compileTask = "compile${VARIANT}ReleaseNdk"
|
||||
tasks.getByName(compileTask).dependsOn ndkBuildRelease
|
||||
compileTask = "compile${VARIANT}DebugNdk"
|
||||
tasks.getByName(compileTask).dependsOn ndkBuildDebug
|
||||
}
|
||||
}
|
||||
|
||||
task askForPassword << {
|
||||
|
|
Loading…
Reference in a new issue