Add include_make_built_files
If `include_make_built_files` is set to the name of a partition, the make-built files from that partition will be incorperated into this soong module. This is to ease the transition to soong built filesystems. If any files are present in both the soong-built file list and the make-built one, the soong ones will be preferred. Bug: 329146343 Test: go test Change-Id: I456b283e1189116e699ed75357cc056f5d217688
This commit is contained in:
@@ -16,6 +16,7 @@ package filesystem
|
||||
|
||||
import (
|
||||
"os"
|
||||
"path/filepath"
|
||||
"testing"
|
||||
|
||||
"android/soong/android"
|
||||
@@ -93,6 +94,22 @@ func TestFileSystemDeps(t *testing.T) {
|
||||
}
|
||||
}
|
||||
|
||||
func TestIncludeMakeBuiltFiles(t *testing.T) {
|
||||
result := fixture.RunTestWithBp(t, `
|
||||
android_filesystem {
|
||||
name: "myfilesystem",
|
||||
include_make_built_files: "system",
|
||||
}
|
||||
`)
|
||||
|
||||
output := result.ModuleForTests("myfilesystem", "android_common").Output("myfilesystem.img")
|
||||
|
||||
stampFile := filepath.Join(result.Config.OutDir(), "target/product/test_device/obj/PACKAGING/system_intermediates/staging_dir.stamp")
|
||||
fileListFile := filepath.Join(result.Config.OutDir(), "target/product/test_device/obj/PACKAGING/system_intermediates/file_list.txt")
|
||||
android.AssertStringListContains(t, "deps of filesystem must include the staging dir stamp file", output.Implicits.Strings(), stampFile)
|
||||
android.AssertStringListContains(t, "deps of filesystem must include the staging dir file list", output.Implicits.Strings(), fileListFile)
|
||||
}
|
||||
|
||||
func TestFileSystemFillsLinkerConfigWithStubLibs(t *testing.T) {
|
||||
result := fixture.RunTestWithBp(t, `
|
||||
android_system_image {
|
||||
|
Reference in New Issue
Block a user