Add logic for passing down CompactDex generation flag

In the cases where we are not install, boot, or first boot, pass down
the flag to generate CompactDex.

Bug: 63756964
Bug: 74245837
Test: manual

(cherry picked from commit f890c3ea5c62fc44aa84fbd011be249accbaff08)

Merged-In: I4a2ff9383251e67b260cff5ec8a326c7a4f7faca
Change-Id: I857ba57d0821442b2d39e19b0102e62ab5f76f0c
2 files changed