Add use_linear_alloc_split_dex option to android_binary().

Summary:
If `use_linear_alloc_split_dex` is passed to `android_binary()` and
`use_split_dex` is `True`, then use `LinearAllocEstimator` to determine
how secondary dexes should be spilt.

This diff changes `ZipSplitter` into an interface, so the old `ZipSplitter` code is
divided between `DefaultZipSplitter` and `AbstractZipSplitter`.

As the point of this diff is to introduce new zip-splitting logic,
it introduces a new implementation of `ZipSplitter` named
`LinearAllocAwareZipSplitter` that uses `LinearAllocEstimator` to determine
how to divide class files into groups that can be zipped.

This also updates a `ZipSplitter` so that it generates a report of which files
were written to which zips and what their size estimates were.
21 files changed
tree: 88f1ba8c9d1aa2213669ed4306fee3694834b358
  1. .idea/
  2. bin/
  3. config/
  4. docs/
  5. lib/
  6. pmd/
  7. scripts/
  8. src/
  9. test/
  10. testdata/
  11. third-party/
  12. .buckconfig
  13. .classpath
  14. .gitignore
  15. .project
  16. buck.iml
  17. build.xml
  18. DEFS
  19. LICENSE
  20. README.md
README.md

Buck

Buck is an Android build tool. To see what Buck can do for you, check out the documentation at http://facebook.github.io/buck/.

Installation

To build Buck, run the following:

git clone git@github.com:facebook/buck.git
cd buck
ant
./bin/buck --help

License

Apache License 2.0