-
Notifications
You must be signed in to change notification settings - Fork 51
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Improve compilation speed for android build
FFTF python script used for flashfiles.zip in IVI. It uses ZipWrite python api to create it. This method is time consuming and adds several unwanted build steps that adds overhead. Like, flash.json generation, unpacking of target files, installer.cmd generation. This fix, changes FFTF python to a normal FFTF bash script, which uses tar + pigz combo for faster flashfiles generation. NOTE: We deprecate flash.json as its used only by PFT & installer.cmd will be maintained in product config repo. Tracked-On: OAM-112083 Signed-off-by: sgnanase <[email protected]>
- Loading branch information
1 parent
9489d80
commit 1870d5f
Showing
2 changed files
with
59 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
#!/bin/bash | ||
|
||
echo "Preparing flashfiles - New Method" | ||
echo "No more Zip. We use tar + pigz" | ||
|
||
echo "========================" | ||
echo "Images / Files to be packed" | ||
echo "========================" | ||
echo "acpio.img" | ||
echo "boot.img" | ||
echo "bootloader.img" | ||
echo "config.img" | ||
echo "flash.json" | ||
echo "gpt.bin" | ||
echo "installer.cmd" | ||
echo "installer.efi " | ||
echo "odm.img " | ||
echo "startup.nsh " | ||
echo "super_empty.img " | ||
echo "super.img " | ||
echo "vbmeta.img " | ||
echo "vendor_boot.img " | ||
echo "========================" | ||
|
||
|
||
#tar | ||
flashfile=`basename $1` | ||
flashfile_dir=`echo $flashfile | sed 's/\.tar\.gz//g'` | ||
PRODUCT_OUT=`dirname $1` | ||
|
||
cd $PRODUCT_OUT | ||
rm -rf $flashfile_dir | ||
mkdir $flashfile_dir | ||
cp acpio.img boot.img bootloader.img config.img gpt.bin installer.cmd efi/installer.efi odm.img efi/startup.nsh super_empty.img ./obj/PACKAGING/super.img_intermediates/super.img vbmeta.img vendor_boot.img $flashfile_dir/. | ||
tar -cvf - $flashfile_dir/ | /usr/bin/pigz > $flashfile | ||
|
||
echo "========================" | ||
echo "Flashfiles Tar created" | ||
echo "========================" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters