Make SystemServerJars ConfiguredJarList.

Consistent with plumbing of boot jars. SystemServerJars only support /system/framework/ jars.

Bug: 180105615, 155630745
Test: m && launch_cvd
Change-Id: I58b005b7c4103c8e250090e995b1d9b2f9ed4a76
This commit is contained in:
satayev
2021-05-04 16:14:48 +01:00
parent ee4e7fe76f
commit 9a6f87ebd6
4 changed files with 10 additions and 11 deletions

View File

@@ -150,7 +150,7 @@ func (d *dexpreopter) dexpreopt(ctx android.ModuleContext, dexJarFile android.Wr
global := dexpreopt.GetGlobalConfig(ctx)
isSystemServerJar := inList(ctx.ModuleName(), global.SystemServerJars)
isSystemServerJar := global.SystemServerJars.ContainsJar(ctx.ModuleName())
bootImage := defaultBootImageConfig(ctx)
if global.UseArtImage {

View File

@@ -39,10 +39,9 @@ func systemServerClasspath(ctx android.PathContext) []string {
// 2) The jars that are from an updatable apex.
systemServerClasspathLocations = append(systemServerClasspathLocations,
global.UpdatableSystemServerJars.DevicePaths(ctx.Config(), android.Android)...)
if len(systemServerClasspathLocations) != len(global.SystemServerJars)+global.UpdatableSystemServerJars.Len() {
panic(fmt.Errorf("Wrong number of system server jars, got %d, expected %d",
len(systemServerClasspathLocations),
len(global.SystemServerJars)+global.UpdatableSystemServerJars.Len()))
if expectedLen := global.SystemServerJars.Len() + global.UpdatableSystemServerJars.Len(); expectedLen != len(systemServerClasspathLocations) {
panic(fmt.Errorf("wrong number of system server jars, got %d, expected %d", len(systemServerClasspathLocations), expectedLen))
}
return systemServerClasspathLocations
})