diff options
author | 2011-07-20 15:08:23 -0700 | |
---|---|---|
committer | 2011-07-20 15:08:23 -0700 | |
commit | 1e24ccbdd56a45c8bb5f2eba94af5aecd2d02554 (patch) | |
tree | a4c8ca6924e68b84dab15ac13d97b7b372ccc836 /tools/aapt/Package.cpp | |
parent | d40c93f61ca5b3f2351b8db716f67b58f1625e85 (diff) | |
parent | 03589cc65355220e0a4a0c816189a9fa25cc81fc (diff) |
Merge "Add generation of dependency file for .ap_ package"
Diffstat (limited to 'tools/aapt/Package.cpp')
-rw-r--r-- | tools/aapt/Package.cpp | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/tools/aapt/Package.cpp b/tools/aapt/Package.cpp index 999a5cf82222..6e2a25ce8c7e 100644 --- a/tools/aapt/Package.cpp +++ b/tools/aapt/Package.cpp @@ -172,6 +172,16 @@ status_t writeAPK(Bundle* bundle, const sp<AaptAssets>& assets, } } + if (bundle->getGenDependencies()) { + // Add this file to the dependency file + String8 dependencyFile = outputFile.getBasePath(); + dependencyFile.append(".d"); + + FILE* fp = fopen(dependencyFile.string(), "a"); + fprintf(fp, "%s \\\n", outputFile.string()); + fclose(fp); + } + assert(result == NO_ERROR); bail: |