summaryrefslogtreecommitdiffstats
path: root/tools/aapt/Package.cpp
diff options
context:
space:
mode:
authorXavier Ducrohet <xav@android.com>2011-08-18 14:48:49 -0700
committerAndroid Git Automerger <android-git-automerger@android.com>2011-08-18 14:48:49 -0700
commitd98e1be20e1cca5c36c7e0344500d4a5574568aa (patch)
tree9fb8a00956a58e1eb452f7b91e109fa4461f8027 /tools/aapt/Package.cpp
parent294539df2c05eb62c417e25b2e1c8a71474b09e6 (diff)
parentf4750724cf8db972a052cb388dc9a39fc7aa6dd6 (diff)
downloadframeworks_base-d98e1be20e1cca5c36c7e0344500d4a5574568aa.zip
frameworks_base-d98e1be20e1cca5c36c7e0344500d4a5574568aa.tar.gz
frameworks_base-d98e1be20e1cca5c36c7e0344500d4a5574568aa.tar.bz2
am f4750724: am 9d829f98: am 21e6e2de: Merge "Change generated dependency file names"
* commit 'f4750724cf8db972a052cb388dc9a39fc7aa6dd6': Change generated dependency file names
Diffstat (limited to 'tools/aapt/Package.cpp')
-rw-r--r--tools/aapt/Package.cpp9
1 files changed, 7 insertions, 2 deletions
diff --git a/tools/aapt/Package.cpp b/tools/aapt/Package.cpp
index c9f6870..1e3efde 100644
--- a/tools/aapt/Package.cpp
+++ b/tools/aapt/Package.cpp
@@ -177,12 +177,17 @@ status_t writeAPK(Bundle* bundle, const sp<AaptAssets>& assets,
}
}
+ // If we've been asked to generate a dependency file for the .ap_ package,
+ // do so here
if (bundle->getGenDependencies()) {
- // Add this file to the dependency file
- String8 dependencyFile = outputFile.getBasePath();
+ // The dependency file gets output to the same directory
+ // as the specified output file with an additional .d extension.
+ // e.g. bin/resources.ap_.d
+ String8 dependencyFile = outputFile;
dependencyFile.append(".d");
FILE* fp = fopen(dependencyFile.string(), "a");
+ // Add this file to the dependency file
fprintf(fp, "%s \\\n", outputFile.string());
fclose(fp);
}