Compact merged dexes on their byte aligned size
Previously, if a merged dex had too much free space, the compaction step
would subtract the unused space from the section sizes generated by
adding the merged dexes section sizes. The merged sizes weren't 4-byte
aligned, which meant if a section had been bumped in size for the
boundary, the compaction would fail when loading into a section eg
'Section limit 3665072 exceeded by string data'.
This gets the compacted section size from the actual used space instead
of from the non-aligned estimate, so everything fits.
Change-Id: I1aee1abd721ec21998bb3ea78f6f424e7421b614
2 files changed