Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 562d536d authored by Jiakai Zhang's avatar Jiakai Zhang
Browse files

Force the compilation reason of otapreopt to be "ab-ota".

The legacy code in the package manager uses "first-boot" as the
compilation reason for otapreopt when it wants to query
"pm.dexopt.first-boot" for the compiler filter. This causes confusion.

Bug: 307903002
Change-Id: I73c1178684f9056dc2d87e6f8d0379a64ac387c3
Test: Presubmit
parent a35aa0fe
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -514,6 +514,8 @@ private:
        // Make sure dex2oat is run with background priority.
        dexopt_flags |= DEXOPT_BOOTCOMPLETE | DEXOPT_IDLE_BACKGROUND_JOB;

        parameters_.compilation_reason = "ab-ota";

        int res = dexopt(parameters_.apk_path,
                         parameters_.uid,
                         parameters_.pkgName,