aboutsummaryrefslogtreecommitdiff
path: root/builder
diff options
context:
space:
mode:
authorXavier Ducrohet <xav@google.com>2013-12-03 12:57:40 -0800
committerXavier Ducrohet <xav@google.com>2013-12-03 14:27:08 -0800
commit332436805ed039ef7bf5f9d9e9052efbe5c356d8 (patch)
tree06ea93846d3f9fd6ac2916e3372294caaa4398e2 /builder
parent2cae6225fe7c618afd5efc6bff9efd69d0e9a724 (diff)
downloadbuild-332436805ed039ef7bf5f9d9e9052efbe5c356d8.tar.gz
Fix overlay issue with new source providers.
Change-Id: I31fc26a938043a0b58f3d58a6f1d6d675fff702d
Diffstat (limited to 'builder')
-rw-r--r--builder/src/main/java/com/android/builder/VariantConfiguration.java46
1 files changed, 23 insertions, 23 deletions
diff --git a/builder/src/main/java/com/android/builder/VariantConfiguration.java b/builder/src/main/java/com/android/builder/VariantConfiguration.java
index 4c861fe..f55d0d6 100644
--- a/builder/src/main/java/com/android/builder/VariantConfiguration.java
+++ b/builder/src/main/java/com/android/builder/VariantConfiguration.java
@@ -864,13 +864,6 @@ public class VariantConfiguration implements TestData {
}
}
- if (mMultiFlavorSourceProvider != null) {
- File variantLocation = mMultiFlavorSourceProvider.getManifestFile();
- if (variantLocation.isFile()) {
- inputs.add(variantLocation);
- }
- }
-
if (mBuildTypeSourceProvider != null) {
File typeLocation = mBuildTypeSourceProvider.getManifestFile();
if (typeLocation.isFile()) {
@@ -878,6 +871,13 @@ public class VariantConfiguration implements TestData {
}
}
+ if (mMultiFlavorSourceProvider != null) {
+ File variantLocation = mMultiFlavorSourceProvider.getManifestFile();
+ if (variantLocation.isFile()) {
+ inputs.add(variantLocation);
+ }
+ }
+
for (SourceProvider sourceProvider : mFlavorSourceProviders) {
File f = sourceProvider.getManifestFile();
if (f.isFile()) {
@@ -941,6 +941,14 @@ public class VariantConfiguration implements TestData {
resourceSets.add(resourceSet);
}
+ // multiflavor specific overrides flavor
+ if (mMultiFlavorSourceProvider != null) {
+ Collection<File> variantResDirs = mMultiFlavorSourceProvider.getResDirectories();
+ resourceSet = new ResourceSet(getFlavorName());
+ resourceSet.addSources(variantResDirs);
+ resourceSets.add(resourceSet);
+ }
+
// build type overrides the flavors
if (mBuildTypeSourceProvider != null) {
Collection<File> typeResDirs = mBuildTypeSourceProvider.getResDirectories();
@@ -949,14 +957,6 @@ public class VariantConfiguration implements TestData {
resourceSets.add(resourceSet);
}
- // multiflavor specific overrides flavor/build type
- if (mMultiFlavorSourceProvider != null) {
- Collection<File> variantResDirs = mMultiFlavorSourceProvider.getResDirectories();
- resourceSet = new ResourceSet(getFullName());
- resourceSet.addSources(variantResDirs);
- resourceSets.add(resourceSet);
- }
-
// variant specific overrides all
if (mVariantSourceProvider != null) {
Collection<File> variantResDirs = mVariantSourceProvider.getResDirectories();
@@ -1013,6 +1013,14 @@ public class VariantConfiguration implements TestData {
assetSets.add(assetSet);
}
+ // multiflavor specific overrides flavor
+ if (mMultiFlavorSourceProvider != null) {
+ Collection<File> variantResDirs = mMultiFlavorSourceProvider.getAssetsDirectories();
+ assetSet = new AssetSet(getFlavorName());
+ assetSet.addSources(variantResDirs);
+ assetSets.add(assetSet);
+ }
+
// build type overrides flavors
if (mBuildTypeSourceProvider != null) {
Collection<File> typeResDirs = mBuildTypeSourceProvider.getAssetsDirectories();
@@ -1021,14 +1029,6 @@ public class VariantConfiguration implements TestData {
assetSets.add(assetSet);
}
- // multiflavor specific overrides flavor/build type
- if (mMultiFlavorSourceProvider != null) {
- Collection<File> variantResDirs = mMultiFlavorSourceProvider.getAssetsDirectories();
- assetSet = new AssetSet(getFullName());
- assetSet.addSources(variantResDirs);
- assetSets.add(assetSet);
- }
-
// variant specific overrides all
if (mVariantSourceProvider != null) {
Collection<File> variantResDirs = mVariantSourceProvider.getAssetsDirectories();