flash: support optional boot_bin_immutable_url in targets.json - #232
Phanendra Yarra (phanendra-qc) wants to merge 2 commits into
Conversation
|
Reviewed the parser and download changes, and tested the flow locally with the real main and immutable archives for all four targets. The contents are merged correctly, shared URLs are downloaded only once, and targets without |
PR qualcomm-linux/meta-qcom#3069 splits the boot binaries archive into a main zip and a companion immutable zip. The Yocto recipe deploys both into the same DEPLOYDIR; mirror that behaviour here. Changes: - parse-boards-config.py: add boot_bin_immutable_url as an optional field (defaults to "") in the schema doc and setdefault block - download-boot-bins.sh: extract the download+extract logic into a reusable download_and_extract() helper (URL deduplication cache preserved). After the main archive is placed in bins_<board>/, if boot_bin_immutable_url is set the immutable archive is downloaded (also deduplicated) and its contents are merged into the same bins_<board>/ directory via cp -a. Targets without boot_bin_immutable_url are fully backward-compatible. Companion change: qualcomm-linux/qcom-distro-images dev/bootbins-immutable-split Signed-off-by: Phanendra yarra <pyarra@qti.qualcomm.com>
The _extract_* and *_flat scratch directories used during archive extraction were cached in URL_TO_EXTRACTED_DIR for deduplication but never removed. Add a cleanup loop after all boards are processed to rm -rf every cached temp dir, keeping the output directory tidy. Signed-off-by: Phanendra yarra <pyarra@qti.qualcomm.com>
9234f5b to
b7f91b7
Compare
Thanks for review, addressed DCO & also added cleanup of extact* folder post bin_ created |
Summary
PR qualcomm-linux/meta-qcom#3069 splits the boot binaries archive into a main zip and a companion immutable zip. The Yocto recipe deploys both into the same
DEPLOYDIR; this PR mirrors that behaviour in the Ubuntu build pipeline.Changes
flash/parse-boards-config.pyboot_bin_immutable_urlas an optional field (defaults to"") in the schema doc comment and thesetdefaultnormalization block.flash/download-boot-bins.shdownload_and_extract()helper (URL deduplication cache preserved).bins_<board>/, ifboot_bin_immutable_urlis set the immutable archive is downloaded (also deduplicated) and its contents are merged into the samebins_<board>/directory viacp -a— exactly mirroring what the Yocto recipe does.boot_bin_immutable_urlare fully backward-compatible.Dependency
Companion PR in qcom-distro-images: #138 — adds
boot_bin_immutable_urland bumps versions inconfig/resolute/iot/targets.json.