mirror of
git://xwords.git.sourceforge.net/gitroot/xwords/xwords
synced 2025-01-24 07:58:34 +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 THUMBNAIL_ENABLED = true
|
||||||
def LIBS_DEBUG = 'libs-debug'
|
def LIBS_DEBUG = 'libs-debug'
|
||||||
def LIBS_RELEASE = 'libs-release'
|
def LIBS_RELEASE = 'libs-release'
|
||||||
|
def VERSION_CODE_BASE = 1
|
||||||
|
def VARIANTS = [ "Xw4", "Xw4dbg" ]
|
||||||
|
def BUILDS = [ "Debug", "Release" ]
|
||||||
|
|
||||||
apply plugin: 'com.android.application'
|
apply plugin: 'com.android.application'
|
||||||
|
|
||||||
|
@ -15,7 +18,6 @@ android {
|
||||||
compileSdkVersion 22
|
compileSdkVersion 22
|
||||||
buildToolsVersion "22.0.1"
|
buildToolsVersion "22.0.1"
|
||||||
defaultConfig {
|
defaultConfig {
|
||||||
applicationId "org.eehouse.android.xw4"
|
|
||||||
minSdkVersion 7
|
minSdkVersion 7
|
||||||
targetSdkVersion 14
|
targetSdkVersion 14
|
||||||
}
|
}
|
||||||
|
@ -23,29 +25,40 @@ android {
|
||||||
// Rename all output artifacts to include version information
|
// Rename all output artifacts to include version information
|
||||||
// applicationVariants.all { variant ->
|
// applicationVariants.all { variant ->
|
||||||
// renameArtifact(variant)
|
// renameArtifact(variant)
|
||||||
|
// variant.buildConfigField "String", "FIELD_NAME", "\"my String\""
|
||||||
// }
|
// }
|
||||||
|
|
||||||
// flavorDimensions "variant", "abi"
|
flavorDimensions "variant"//, "abi"
|
||||||
// productFlavors {
|
productFlavors {
|
||||||
// xw4 {
|
xw4 {
|
||||||
// dimension "variant"
|
dimension "variant"
|
||||||
|
applicationId "org.eehouse.android.xw4"
|
||||||
|
}
|
||||||
|
xw4dbg {
|
||||||
|
dimension "variant"
|
||||||
|
applicationId "org.eehouse.android.xw4dbg"
|
||||||
|
}
|
||||||
|
|
||||||
|
// 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
|
||||||
// }
|
// }
|
||||||
// xw4dbg {
|
// armeabi {
|
||||||
// dimension "variant"
|
// dimension "abi"
|
||||||
|
// versionCode 1 + VERSION_CODE_BASE
|
||||||
|
// }
|
||||||
|
// x86 {
|
||||||
|
// dimension "abi"
|
||||||
|
// versionCode 2 + VERSION_CODE_BASE
|
||||||
// }
|
// }
|
||||||
// armeabiv7a {
|
// armeabiv7a {
|
||||||
// dimension "abi"
|
// dimension "abi"
|
||||||
|
// versionCode 3 + VERSION_CODE_BASE
|
||||||
// }
|
// }
|
||||||
|
|
||||||
// armeabi {
|
}
|
||||||
// dimension "abi"
|
|
||||||
// }
|
|
||||||
|
|
||||||
// x86 {
|
|
||||||
// dimension "abi"
|
|
||||||
// }
|
|
||||||
|
|
||||||
// }
|
|
||||||
|
|
||||||
signingConfigs {
|
signingConfigs {
|
||||||
release {
|
release {
|
||||||
|
@ -154,8 +167,12 @@ task mkXml(type: Exec) {
|
||||||
}
|
}
|
||||||
|
|
||||||
afterEvaluate {
|
afterEvaluate {
|
||||||
compileReleaseNdk.dependsOn ndkBuildRelease
|
VARIANTS.each { VARIANT ->
|
||||||
compileDebugNdk.dependsOn ndkBuildDebug
|
String compileTask = "compile${VARIANT}ReleaseNdk"
|
||||||
|
tasks.getByName(compileTask).dependsOn ndkBuildRelease
|
||||||
|
compileTask = "compile${VARIANT}DebugNdk"
|
||||||
|
tasks.getByName(compileTask).dependsOn ndkBuildDebug
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
task askForPassword << {
|
task askForPassword << {
|
||||||
|
|
Loading…
Add table
Reference in a new issue