Add the primary file to EXTRA_INSTALL_ZIPS
Make needs to know the primary file, because the zip is only extracted when the primary file is installed. Bug: 337869220 Test: m out/target/product/emu64x/obj/PACKAGING/system_intermediates/file_list.txt and checking it for the extra NetworkStackGoogle apks, with a local NetworkStackGoogle android_app_set added into the tree Change-Id: I5cb7243d214f4730e3f9efb6746793f3bf4b8214
This commit is contained in:
parent
cd8dc70806
commit
07c4537424
2 changed files with 7 additions and 4 deletions
|
@ -507,7 +507,7 @@ EXTRA_INSTALL_ZIPS :=
|
||||||
if extraFiles := install.extraFiles; extraFiles != nil {
|
if extraFiles := install.extraFiles; extraFiles != nil {
|
||||||
fmt.Fprintf(buf, "\t( unzip -qDD -d '%s' '%s' 2>&1 | grep -v \"zipfile is empty\"; exit $${PIPESTATUS[0]} ) || \\\n", extraFiles.dir.String(), extraFiles.zip.String())
|
fmt.Fprintf(buf, "\t( unzip -qDD -d '%s' '%s' 2>&1 | grep -v \"zipfile is empty\"; exit $${PIPESTATUS[0]} ) || \\\n", extraFiles.dir.String(), extraFiles.zip.String())
|
||||||
fmt.Fprintf(buf, "\t ( code=$$?; if [ $$code -ne 0 -a $$code -ne 1 ]; then exit $$code; fi )\n")
|
fmt.Fprintf(buf, "\t ( code=$$?; if [ $$code -ne 0 -a $$code -ne 1 ]; then exit $$code; fi )\n")
|
||||||
fmt.Fprintf(buf, "EXTRA_INSTALL_ZIPS += %s:%s\n", extraFiles.dir.String(), extraFiles.zip.String())
|
fmt.Fprintf(buf, "EXTRA_INSTALL_ZIPS += %s:%s:%s\n", install.to.String(), extraFiles.dir.String(), extraFiles.zip.String())
|
||||||
}
|
}
|
||||||
|
|
||||||
fmt.Fprintln(buf)
|
fmt.Fprintln(buf)
|
||||||
|
|
|
@ -18,13 +18,16 @@ def main():
|
||||||
parser.add_argument('staging_dir',
|
parser.add_argument('staging_dir',
|
||||||
help='Path to the partition staging directory')
|
help='Path to the partition staging directory')
|
||||||
parser.add_argument('extra_install_zips', nargs='*',
|
parser.add_argument('extra_install_zips', nargs='*',
|
||||||
help='The value of EXTRA_INSTALL_ZIPS from make. It should be a list of extraction_dir:zip_file pairs.')
|
help='The value of EXTRA_INSTALL_ZIPS from make. '
|
||||||
|
'It should be a list of primary_file:extraction_dir:zip_file trios. '
|
||||||
|
'The primary file will be ignored by this script, you should ensure that '
|
||||||
|
'the list of trios given to this script is already filtered by relevant primary files.')
|
||||||
args = parser.parse_args()
|
args = parser.parse_args()
|
||||||
|
|
||||||
staging_dir = args.staging_dir.removesuffix('/') + '/'
|
staging_dir = args.staging_dir.removesuffix('/') + '/'
|
||||||
|
|
||||||
for zip_pair in args.extra_install_zips:
|
for zip_trio in args.extra_install_zips:
|
||||||
d, z = zip_pair.split(':')
|
_, d, z = zip_trio.split(':')
|
||||||
d = d.removesuffix('/') + '/'
|
d = d.removesuffix('/') + '/'
|
||||||
|
|
||||||
if d.startswith(staging_dir):
|
if d.startswith(staging_dir):
|
||||||
|
|
Loading…
Reference in a new issue