Merge "Remove host boot image from boot.zip." am: 5cdb051ce3
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1328974 Change-Id: I09612bb018b4ede636fa2035c277ba3b1afcb106
This commit is contained in:
committed by
Automerger Merge Worker
commit
46560dfdf3
@@ -332,10 +332,12 @@ func buildBootImage(ctx android.SingletonContext, image *bootImageConfig) *bootI
|
|||||||
bootFrameworkProfileRule(ctx, image, missingDeps)
|
bootFrameworkProfileRule(ctx, image, missingDeps)
|
||||||
updatableBcpPackagesRule(ctx, image, missingDeps)
|
updatableBcpPackagesRule(ctx, image, missingDeps)
|
||||||
|
|
||||||
var allFiles android.Paths
|
var zipFiles android.Paths
|
||||||
for _, variant := range image.variants {
|
for _, variant := range image.variants {
|
||||||
files := buildBootImageVariant(ctx, variant, profile, missingDeps)
|
files := buildBootImageVariant(ctx, variant, profile, missingDeps)
|
||||||
allFiles = append(allFiles, files.Paths()...)
|
if variant.target.Os == android.Android {
|
||||||
|
zipFiles = append(zipFiles, files.Paths()...)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if image.zip != nil {
|
if image.zip != nil {
|
||||||
@@ -343,8 +345,8 @@ func buildBootImage(ctx android.SingletonContext, image *bootImageConfig) *bootI
|
|||||||
rule.Command().
|
rule.Command().
|
||||||
BuiltTool(ctx, "soong_zip").
|
BuiltTool(ctx, "soong_zip").
|
||||||
FlagWithOutput("-o ", image.zip).
|
FlagWithOutput("-o ", image.zip).
|
||||||
FlagWithArg("-C ", image.dir.String()).
|
FlagWithArg("-C ", image.dir.Join(ctx, android.Android.String()).String()).
|
||||||
FlagWithInputList("-f ", allFiles, " -f ")
|
FlagWithInputList("-f ", zipFiles, " -f ")
|
||||||
|
|
||||||
rule.Build(pctx, ctx, "zip_"+image.name, "zip "+image.name+" image")
|
rule.Build(pctx, ctx, "zip_"+image.name, "zip "+image.name+" image")
|
||||||
}
|
}
|
||||||
|
@@ -118,7 +118,7 @@ func TestDexpreoptBootZip(t *testing.T) {
|
|||||||
|
|
||||||
ctx := android.PathContextForTesting(testConfig(nil, "", nil))
|
ctx := android.PathContextForTesting(testConfig(nil, "", nil))
|
||||||
expectedInputs := []string{}
|
expectedInputs := []string{}
|
||||||
for _, target := range dexpreoptTargets(ctx) {
|
for _, target := range ctx.Config().Targets[android.Android] {
|
||||||
for _, ext := range []string{".art", ".oat", ".vdex"} {
|
for _, ext := range []string{".art", ".oat", ".vdex"} {
|
||||||
for _, jar := range []string{"foo", "bar", "baz"} {
|
for _, jar := range []string{"foo", "bar", "baz"} {
|
||||||
expectedInputs = append(expectedInputs,
|
expectedInputs = append(expectedInputs,
|
||||||
|
Reference in New Issue
Block a user