Add relative_install_path property to prebuilt_etc

This supports a more consistent property across modules for specifying a
subdirectory to install a file into for prebuilt_etc modules.

Updates bpfix to rewrite `sub_dir` to `relative_install_path`.

Test: gotest prebuilt_etc_test
Test: gotest bpfix_test
Bug: 156568187
Change-Id: Idd05cd2178c46e290764a3b708faa8275818ca1e
This commit is contained in:
Liz Kammer
2020-06-26 10:12:36 -07:00
parent 5e291c238f
commit 0449a6337e
5 changed files with 103 additions and 22 deletions

View File

@@ -876,7 +876,7 @@ include $(BUILD_PREBUILT)
prebuilt_etc {
name: "etc.test1",
src: "mymod",
sub_dir: "foo/bar",
relative_install_path: "foo/bar",
}
`,
@@ -896,7 +896,7 @@ prebuilt_etc {
name: "etc.test1",
src: "etc.test1",
sub_dir: "foo/bar",
relative_install_path: "foo/bar",
}
`,
@@ -913,7 +913,7 @@ include $(BUILD_PREBUILT)
expected: `
prebuilt_etc {
name: "etc.test1",
sub_dir: "foo/bar",
relative_install_path: "foo/bar",
device_specific: true,
}
@@ -931,7 +931,7 @@ include $(BUILD_PREBUILT)
expected: `
prebuilt_etc {
name: "etc.test1",
sub_dir: "foo/bar",
relative_install_path: "foo/bar",
product_specific: true,
@@ -950,7 +950,7 @@ include $(BUILD_PREBUILT)
expected: `
prebuilt_etc {
name: "etc.test1",
sub_dir: "foo/bar",
relative_install_path: "foo/bar",
product_specific: true,
}
@@ -968,7 +968,7 @@ include $(BUILD_PREBUILT)
expected: `
prebuilt_etc {
name: "etc.test1",
sub_dir: "foo/bar",
relative_install_path: "foo/bar",
system_ext_specific: true,
}
@@ -986,7 +986,7 @@ include $(BUILD_PREBUILT)
expected: `
prebuilt_etc {
name: "etc.test1",
sub_dir: "foo/bar",
relative_install_path: "foo/bar",
system_ext_specific: true,
@@ -1005,7 +1005,7 @@ include $(BUILD_PREBUILT)
expected: `
prebuilt_etc {
name: "etc.test1",
sub_dir: "foo/bar",
relative_install_path: "foo/bar",
proprietary: true,
}
@@ -1023,7 +1023,7 @@ include $(BUILD_PREBUILT)
expected: `
prebuilt_etc {
name: "etc.test1",
sub_dir: "foo/bar",
relative_install_path: "foo/bar",
proprietary: true,
}
@@ -1041,7 +1041,7 @@ include $(BUILD_PREBUILT)
expected: `
prebuilt_etc {
name: "etc.test1",
sub_dir: "foo/bar",
relative_install_path: "foo/bar",
proprietary: true,
}
@@ -1059,7 +1059,7 @@ include $(BUILD_PREBUILT)
expected: `
prebuilt_etc {
name: "etc.test1",
sub_dir: "foo/bar",
relative_install_path: "foo/bar",
recovery: true,
}
@@ -1098,7 +1098,7 @@ prebuilt_usr_share {
name: "foo",
src: "foo.txt",
sub_dir: "bar",
relative_install_path: "bar",
}
`,
},
@@ -1174,7 +1174,7 @@ prebuilt_usr_share_host {
name: "foo",
src: "foo.txt",
sub_dir: "bar",
relative_install_path: "bar",
}
`,
},
@@ -1193,7 +1193,7 @@ prebuilt_firmware {
name: "foo",
src: "foo.fw",
sub_dir: "bar",
relative_install_path: "bar",
}
`,
},
@@ -1212,7 +1212,7 @@ prebuilt_firmware {
name: "foo",
src: "foo.fw",
sub_dir: "bar",
relative_install_path: "bar",
}
`,
},
@@ -1231,7 +1231,7 @@ prebuilt_firmware {
name: "foo",
src: "foo.fw",
sub_dir: "bar",
relative_install_path: "bar",
proprietary: true,
}
`,
@@ -1251,7 +1251,7 @@ prebuilt_firmware {
name: "foo",
src: "foo.fw",
sub_dir: "bar",
relative_install_path: "bar",
proprietary: true,
}
`,