mirror of
https://github.com/xiaolu/mkbootimg_tools.git
synced 2026-04-09 15:02:31 +02:00
support lz4 compressed ramdisk
This commit is contained in:
9
mkboot
9
mkboot
@@ -247,7 +247,14 @@ ramdisk_offset=$ramdisk_offset\ntags_offset=$tags_offset\ncmd_line=\"$cmd_line\"
|
||||
fi
|
||||
mkdir ramdisk
|
||||
cd ramdisk
|
||||
gzip -d -c ../ramdisk.gz | cpio -i -d -m --no-absolute-filenames 2>/dev/null
|
||||
|
||||
gzip -t ../ramdisk.gz
|
||||
if [ $? -gt 0 ]; then
|
||||
$tooldir/lz4 -d ../ramdisk.gz ../ramdisk.cpio
|
||||
cpio -i -d -m --no-absolute-filenames 2>/dev/null < ../ramdisk.cpio
|
||||
else
|
||||
gzip -d -c ../ramdisk.gz | cpio -i -d -m --no-absolute-filenames 2>/dev/null
|
||||
fi
|
||||
#Unpack Finish to exit.
|
||||
pout "Unpack completed."
|
||||
exit
|
||||
|
||||
Reference in New Issue
Block a user