diff options
author | Nicolas Geoffray <ngeoffray@google.com> | 2019-04-30 09:43:22 +0100 |
---|---|---|
committer | Nicolas Geoffray <ngeoffray@google.com> | 2019-04-30 13:33:10 +0000 |
commit | feef2ef4d7cc146885c482899f9a967554dc083d (patch) | |
tree | 2c995302ea9c291b5838dcc9eee663f6412a6fb2 /java/dexpreopt_config.go | |
parent | 1341942d869dfe01bbd509bea2a30d8ebdaaa17b (diff) | |
download | build_soong-feef2ef4d7cc146885c482899f9a967554dc083d.tar.gz build_soong-feef2ef4d7cc146885c482899f9a967554dc083d.tar.bz2 build_soong-feef2ef4d7cc146885c482899f9a967554dc083d.zip |
Pass other boot classpath locations to the apex image.
In order to evaluate the impact of framework classes being in an image.
Test: m
Bug: 119800099
Exempt-From-Owner-Approval: this is only for an experimental config, which we would like to see
the performance before build snap.
Change-Id: Ib0d3acf8d2718ee443b3bffe8122a54f92257691
Diffstat (limited to 'java/dexpreopt_config.go')
-rw-r--r-- | java/dexpreopt_config.go | 24 |
1 files changed, 16 insertions, 8 deletions
diff --git a/java/dexpreopt_config.go b/java/dexpreopt_config.go index b30bd009..a0b1ea59 100644 --- a/java/dexpreopt_config.go +++ b/java/dexpreopt_config.go @@ -138,21 +138,29 @@ func apexBootImageConfig(ctx android.PathContext) bootImageConfig { global := dexpreoptGlobalConfig(ctx) runtimeModules := global.RuntimeApexJars + nonFrameworkModules := concat(runtimeModules, global.ProductUpdatableBootModules) + frameworkModules := android.RemoveListFromList(global.BootJars, nonFrameworkModules) + imageModules := concat(runtimeModules, frameworkModules) - var runtimeBootLocations []string + var bootLocations []string for _, m := range runtimeModules { - runtimeBootLocations = append(runtimeBootLocations, + bootLocations = append(bootLocations, filepath.Join("/apex/com.android.runtime/javalib", m+".jar")) } + for _, m := range frameworkModules { + bootLocations = append(bootLocations, + filepath.Join("/system/framework", m+".jar")) + } + // The path to bootclasspath dex files needs to be known at module GenerateAndroidBuildAction time, before // the bootclasspath modules have been compiled. Set up known paths for them, the singleton rules will copy // them there. // TODO: use module dependencies instead - var runtimeBootDexPaths android.WritablePaths - for _, m := range runtimeModules { - runtimeBootDexPaths = append(runtimeBootDexPaths, + var bootDexPaths android.WritablePaths + for _, m := range imageModules { + bootDexPaths = append(bootDexPaths, android.PathForOutput(ctx, ctx.Config().DeviceName(), "dex_apexjars_input", m+".jar")) } @@ -167,9 +175,9 @@ func apexBootImageConfig(ctx android.PathContext) bootImageConfig { return bootImageConfig{ name: "apex", - modules: runtimeModules, - dexLocations: runtimeBootLocations, - dexPaths: runtimeBootDexPaths, + modules: imageModules, + dexLocations: bootLocations, + dexPaths: bootDexPaths, dir: dir, symbolsDir: symbolsDir, images: images, |