[installd] Add check that classpath is up to date to getDexOptNeeded

Pass the class loader context argument to dexoptanalyzer when analyzing
secondary dex files.

(cherry picked from commit ef81ec21e8ea059875295597e3acc9f6af3a96ec)

Bug: 62269291
Test: manual, compile secondary dex files
      adb shell cmd package compile -m speed --secondary-dex
com.google.android.googlequicksearchbox

Merged-In: I25ae93cadd12441a13ff54bb3da5a198085c6f3d
Change-Id: I25ae93cadd12441a13ff54bb3da5a198085c6f3d
1 file changed