2c12241fa8edaa4ae8bd01f50980ae647c41b45c |
|
16-Dec-2017 |
Shane Farmer <safarmer@google.com> |
AAPT2: Get list of multi-APK artifacts without APK file Allow the optimize command to produce a list of output artifact names without needing to read the input APK from disk. This not only saves disk reads for a file that will not be used, it also allows the list of outputs to be generated without having an APK file yet. Test: unit tests Test: split an APK Test: print list of outputs without an APK Change-Id: I4e18e63f298a07f26ab0de2b2f0acb769bb535ba
/frameworks/base/tools/aapt2/cmd/Optimize.cpp
|
cb6c3f9b880160c35785b1780b282fdf92952b90 |
|
27-Nov-2017 |
Shane Farmer <safarmer@google.com> |
AAPT2: Push more configuration code into the parser When parsing is complete, we now have a list of output artifacts that have their referential integrity validated. This means that once the configuration file is parsed, the only errors that can occur are related to APK processing, and not the configuration itself. This reduces the number of errors that could cause a partial output of APK artifacts. It simplifies the public API and reduces the complexity of the code to generate multiple APKs. Test: Ran unit tests Test: manually ran the optimize command to ensure it still works Change-Id: I3f2d885b207a84c958f5348a4baa6718598184a4
/frameworks/base/tools/aapt2/cmd/Optimize.cpp
|
99ac3fdbd85ba61ba988481d410072a30440c774 |
|
13-Dec-2017 |
Shane Farmer <safarmer@google.com> |
AAPT2: Remove unused command line option. --target-abis is never used and the same functionality works with onfiguration files. Test: Unit tests Change-Id: Ic890eb0f15fade82cd85ba34d653d6cea3b79fb2 Bugs: b/70571736
/frameworks/base/tools/aapt2/cmd/Optimize.cpp
|
49639bf6cd56c8c20398efa707db5f7a97ad73ba |
|
05-Dec-2017 |
TreeHugger Robot <treehugger-gerrit@google.com> |
Merge "AAPT2: Allow output artifacts to be filtered."
|
666de34a58320ecf24b78fff836732d8278f3e98 |
|
30-Nov-2017 |
Shane Farmer <safarmer@google.com> |
AAPT2: Allow output artifacts to be filtered. A new optional flag has been added to allow a list of artifacts that should be written as output to be provided. If the flag is provided, only artifacts that have an output name matching an entry in the list will be processed. Test: manually ran against an APK with multiple artifacts in the configuration and confirmed that only the specified artifacts were written. Test: Ran all unit tests. Change-Id: Ia32b19acf1b2ef3711abf13df08dc7b1aa0cf161
/frameworks/base/tools/aapt2/cmd/Optimize.cpp
|
b0643302c78d00db3036707a0df0ae5ce923ae15 |
|
02-Dec-2017 |
Luke Nicholson <lukenicholson@google.com> |
Enable obfuscation of resource names, with whitelisting support. Test: Built aapt2, ran optimize on gmail apk with sample whitelist config file, and flags enabled. Added two unit tests to TableFlattener covering obfuscation logic. Change-Id: Iad6329d75ff440121bf1a2cdf09c5f4bf4199d9d
/frameworks/base/tools/aapt2/cmd/Optimize.cpp
|
d55bef78a5f2a0fe8068b26b463b161bd0398791 |
|
10-Nov-2017 |
Pierre Lecesne <lecesne@google.com> |
AAPT2 - Convert command to copy all the files. Test: Manual Change-Id: I8705966cb34ff41eb362126a35956720147fae91
/frameworks/base/tools/aapt2/cmd/Optimize.cpp
|
8780eb6e4918ae24fb1ae74d631042c32e41dc3d |
|
01-Nov-2017 |
Adam Lesinski <adamlesinski@google.com> |
AAPT2: Add convert command This command allows a developer to convert their proto APK (generated from the link phase using --proto-format) into a binary APK suitable for use on device. aapt2 convert -o output.apk input.apk Test: manual + make aapt2_tests Change-Id: I10a7c33bb4b57006d01fe00a8bf92f78e04e7e50
/frameworks/base/tools/aapt2/cmd/Optimize.cpp
|
004511660671511ae88e0e837a6f92db28eadaef |
|
03-Oct-2017 |
Adam Lesinski <adamlesinski@google.com> |
AAPT2: Define and Implement AAPT Container Format AAPT Container Format (.apc) is a simple container that enumerates the various intermediate files that AAPT2 generates during the compile phase. The format is defined in formats.md. For now, continue using the .flat extension for the container file, and keep making use of the .flata zip for storing multiple files. This will allow easier integration with existing build systems and allow the evolution of the APC format to better handle arbitrarily large files. Test: make aapt2_tests Change-Id: Id7216e5b76316bdd683f0fa4eaf2d2da273ba815
/frameworks/base/tools/aapt2/cmd/Optimize.cpp
|
4670805ea441edb8b280f9312571e7799f1284cf |
|
29-Sep-2017 |
Adam Lesinski <adamlesinski@google.com> |
AAPT2: Move format related files under same directory Test: make aapt2_tests Change-Id: Id72cdfc12ba3add294048e60c55f2461344464bf
/frameworks/base/tools/aapt2/cmd/Optimize.cpp
|
3edd47264335cf609ac6e733db77522f7c959c3f |
|
01-Sep-2017 |
Shane Farmer <safarmer@google.com> |
AAPT2: Set the minSdkVersion when generating multiple APKs. When generating multiple APKs from a configuration file, check to see if we have filtered resource by minSdkVersion and update the manifest to reflect this. We only want to inflate and modify the manifest file if there is an update to be applied. Bug: 37944703 Bug: 67005138 Test: Ran unit tests Test: Manually split an APK and verified the manifest by dumping with AAPT (both xmltree and badging). Change-Id: I64a0e4889d7d9e57373369b044a091287b06cc35
/frameworks/base/tools/aapt2/cmd/Optimize.cpp
|
d3ffa844f5a07756009f019e13806e253d1bb119 |
|
28-Sep-2017 |
Adam Lesinski <adamlesinski@google.com> |
AAPT2: Cleanup Visitors for XML and Values Test: make aapt2_tests Change-Id: Ib61f64c155a380115610edeaf2d65e60258a2426
/frameworks/base/tools/aapt2/cmd/Optimize.cpp
|
efe45392c300f922e8328281a0aab8260c1d171d |
|
21-Aug-2017 |
Shane Farmer <safarmer@google.com> |
AAPT2: Multi APK generator by version - Added an additional axis for generating a multi-apk split by minimum Android SDK version. This removes any resources that will not be used for the desired minimum SDK version. If there are multiple resources that would be valid for any version newer than the requested minimum, then all would be kept so that the best match can be found. - Added a context wrapper to set the appropriate Android SDK version for each generated artifact. - Split out the FilterTable method to allow it to be directly tested without the need to mock the APK writing steps. Test: Unit tests Test: manually run optimize command Change-Id: I7e6018df081af9ed5d9e8aaf40ed216c1275f138
/frameworks/base/tools/aapt2/cmd/Optimize.cpp
|
9ecc0751e30086c0668c8fe5758f14fc5acf5ae8 |
|
25-Aug-2017 |
Shane Farmer <safarmer@google.com> |
AAPT2: Add flag to print multi APK artifact names. - Added new flag that exits after printing the list of artifact names that would be generated from the combination of the configuration file and input APK. - Cleaned up the code to generate the artifact names which also involved adding some more test cases for corner cases. Test: Unit tests Test: Manually ran new command Test: Manually ran old command Change-Id: I8d30e7a4a070af26945b8f544a13f23bdf1ba169
/frameworks/base/tools/aapt2/cmd/Optimize.cpp
|
0a5b201156f1dd01a7da7b7674798ed57cfafc5a |
|
22-Jun-2017 |
Shane Farmer <safarmer@google.com> |
AAPT2: Add a APK filtering. Allow resource files to be removed from the final artifact based on the density and locale configuration in the config file. The APK is split along the density, locale and ABI axis. Each split is generated from the original APK without modifying the original. The new resource table is written back to the file system with unneeded assets etc removed. Test: Unit tests Test: Manually run optimize command against an APK and inspect results Test: Installed split searchlite APK (after resigning) and ran on N6 Change-Id: If73597dcfd88c02d2616518585d0e25a5c6a84d1
/frameworks/base/tools/aapt2/cmd/Optimize.cpp
|
280be34fa6311de90dff6c595a147fd5a182223d |
|
22-Jun-2017 |
Shane Farmer <safarmer@google.com> |
AAPT2: Update the name of the configuration struct. Make the Configuration struct name less ambiguous. Also ran clang-format on the change since some lines were too long and this resulted in a bigger diff than expected. Test: built manually Test: ran existing unit tests Change-Id: I85e78041fa78d913d47a26c85ad48b05bf935a6a
/frameworks/base/tools/aapt2/cmd/Optimize.cpp
|
5766943f558c8fccc714bb3d0a96af70816a5545 |
|
19-Jun-2017 |
Shane Farmer <safarmer@google.com> |
AAPT2: Split APK by ABI. Added a FilterChain that can apply multiple filter steps to an APK file as it is being written to disk. The first filter applied is by ABI. If a library in the APK does not match the filter it is skipped. Added an AbiFilter that keeps files that are either not native libs or are for the set of wanted ABIs Test: ran unit tests locally Test: ran against an APK with ARM and x68 libs and diffed the results Change-Id: I3fb901d3de3513e85f2a2763a8e4487a28ed4881
/frameworks/base/tools/aapt2/cmd/Optimize.cpp
|
742888f0fd9f00574049f52f6ede610888eea4ed |
|
29-Apr-2017 |
Adam Lesinski <adamlesinski@google.com> |
AAPT2: binary parser should be more lenient with files Some APKs have file references that reference files that don't exist. For now, just be lenient and ignore the files themselves. Keep the actual reference until such a time as general resource stripping is implemented. Bug: 37749644 Test: manual Change-Id: I773685acf41212405b71b064d64045fb4556dcfc
/frameworks/base/tools/aapt2/cmd/Optimize.cpp
|
b522f04bc2a581e2877bef4a44ac00b827f879ed |
|
22-Apr-2017 |
Adam Lesinski <adamlesinski@google.com> |
AAPT2: Allow truncating of package names ResTable_package header only allows 127 UTF-16 characters, so AAPT would truncate the real package name to fit. AAPT2 would error-out on any package name longer than 127 UTF-16 characters. This strictness is not required except when building shared libraries, which use the full package name as a way of identifying the runtime assigned package ID to package name mapping. Bug: 36940145 Test: make aapt2_tests Change-Id: I7d2b7e50c7ab30c6a6c4f15d310e711f68e35091
/frameworks/base/tools/aapt2/cmd/Optimize.cpp
|
db091577fff5bcddac703bc8ac4f932fd53e0621 |
|
13-Apr-2017 |
Adam Lesinski <adamlesinski@google.com> |
AAPT2: Allow the ';' separator on Windows for split args Bug: 36870463 Test: manual (wine) Change-Id: I8a38545a3cac9354b41858e1840b197b60925c03
/frameworks/base/tools/aapt2/cmd/Optimize.cpp
|
d0f492db038c6210c1138865d816bfb134376538 |
|
04-Apr-2017 |
Adam Lesinski <adamlesinski@google.com> |
AAPT2: Share split functionality between link and optimize Generating splits should be possible to do from the optimize command. This means that a lot of infrastructure around split APKs can be shared by both the optimize and link phase. Bug: 35925830 Change-Id: Ia88b9e4bff300a56353b2f7a4a2547c8eb43a299 Test: manual
/frameworks/base/tools/aapt2/cmd/Optimize.cpp
|