Update dexpreopt for the ART APEX name change.
Test: Build & boot Bug: 135753770 Exempt-From-Owner-Approval: Approved internally Change-Id: I3aac9112b022cce3ef8cfdf4bdbbed8bb0c8f4c7 Merged-In: I3aac9112b022cce3ef8cfdf4bdbbed8bb0c8f4c7
This commit is contained in:
parent
7153b767a5
commit
cc4b0ad706
|
@ -68,7 +68,7 @@ func (c *Module) AndroidMk() android.AndroidMkData {
|
|||
OutputFile: c.outputFile,
|
||||
// TODO(jiyong): add the APEXes providing shared libs to the required modules
|
||||
// Currently, adding c.Properties.ApexesProvidingSharedLibs is causing multiple
|
||||
// runtime APEXes (com.android.runtime.debug|release) to be installed. And this
|
||||
// ART APEXes (com.android.art.debug|release) to be installed. And this
|
||||
// is breaking some older devices (like marlin) where system.img is small.
|
||||
Required: c.Properties.AndroidMkRuntimeLibs,
|
||||
Include: "$(BUILD_SYSTEM)/soong_cc_prebuilt.mk",
|
||||
|
|
|
@ -42,7 +42,7 @@ type GlobalConfig struct {
|
|||
|
||||
BootJars []string // modules for jars that form the boot class path
|
||||
|
||||
RuntimeApexJars []string // modules for jars that are in the runtime apex
|
||||
ArtApexJars []string // modules for jars that are in the ART APEX
|
||||
ProductUpdatableBootModules []string
|
||||
ProductUpdatableBootLocations []string
|
||||
|
||||
|
@ -292,7 +292,7 @@ func GlobalConfigForTests(ctx android.PathContext) GlobalConfig {
|
|||
DisableGenerateProfile: false,
|
||||
ProfileDir: "",
|
||||
BootJars: nil,
|
||||
RuntimeApexJars: nil,
|
||||
ArtApexJars: nil,
|
||||
ProductUpdatableBootModules: nil,
|
||||
ProductUpdatableBootLocations: nil,
|
||||
SystemServerJars: nil,
|
||||
|
|
|
@ -48,7 +48,7 @@ func TestDexpreoptBootJars(t *testing.T) {
|
|||
|
||||
pathCtx := android.PathContextForTesting(config, nil)
|
||||
dexpreoptConfig := dexpreopt.GlobalConfigForTests(pathCtx)
|
||||
dexpreoptConfig.RuntimeApexJars = []string{"foo", "bar", "baz"}
|
||||
dexpreoptConfig.ArtApexJars = []string{"foo", "bar", "baz"}
|
||||
setDexpreoptTestGlobalConfig(config, dexpreoptConfig)
|
||||
|
||||
ctx := testContext(bp, nil)
|
||||
|
|
|
@ -107,17 +107,17 @@ func defaultBootImageConfig(ctx android.PathContext) bootImageConfig {
|
|||
return ctx.Config().Once(defaultBootImageConfigKey, func() interface{} {
|
||||
global := dexpreoptGlobalConfig(ctx)
|
||||
|
||||
runtimeModules := global.RuntimeApexJars
|
||||
nonFrameworkModules := concat(runtimeModules, global.ProductUpdatableBootModules)
|
||||
artModules := global.ArtApexJars
|
||||
nonFrameworkModules := concat(artModules, global.ProductUpdatableBootModules)
|
||||
frameworkModules := android.RemoveListFromList(global.BootJars, nonFrameworkModules)
|
||||
|
||||
var nonUpdatableBootModules []string
|
||||
var nonUpdatableBootLocations []string
|
||||
|
||||
for _, m := range runtimeModules {
|
||||
for _, m := range artModules {
|
||||
nonUpdatableBootModules = append(nonUpdatableBootModules, m)
|
||||
nonUpdatableBootLocations = append(nonUpdatableBootLocations,
|
||||
filepath.Join("/apex/com.android.runtime/javalib", m+".jar"))
|
||||
filepath.Join("/apex/com.android.art/javalib", m+".jar"))
|
||||
}
|
||||
|
||||
for _, m := range frameworkModules {
|
||||
|
@ -176,16 +176,16 @@ func apexBootImageConfig(ctx android.PathContext) bootImageConfig {
|
|||
return ctx.Config().Once(apexBootImageConfigKey, func() interface{} {
|
||||
global := dexpreoptGlobalConfig(ctx)
|
||||
|
||||
runtimeModules := global.RuntimeApexJars
|
||||
nonFrameworkModules := concat(runtimeModules, global.ProductUpdatableBootModules)
|
||||
artModules := global.ArtApexJars
|
||||
nonFrameworkModules := concat(artModules, global.ProductUpdatableBootModules)
|
||||
frameworkModules := android.RemoveListFromList(global.BootJars, nonFrameworkModules)
|
||||
imageModules := concat(runtimeModules, frameworkModules)
|
||||
imageModules := concat(artModules, frameworkModules)
|
||||
|
||||
var bootLocations []string
|
||||
|
||||
for _, m := range runtimeModules {
|
||||
for _, m := range artModules {
|
||||
bootLocations = append(bootLocations,
|
||||
filepath.Join("/apex/com.android.runtime/javalib", m+".jar"))
|
||||
filepath.Join("/apex/com.android.art/javalib", m+".jar"))
|
||||
}
|
||||
|
||||
for _, m := range frameworkModules {
|
||||
|
|
Loading…
Reference in New Issue