From 1e48d6e9d4441ae4377eeb4ecc98ca49b4e7f67a Mon Sep 17 00:00:00 2001 From: "Ying-Chun Liu (PaulLiu)" Date: Sat, 26 Nov 2022 00:50:46 +0800 Subject: build_rootfs.sh: redo lz4 and cpio to extract initramfs. If we pipe lz4 and cpio to grep and head. Head will quit immediately if it gets enough lines. And then the pipe breaks. Sometimes it will cause the cpio failed at the middle. So not all the files are extracted. We redo it again without any pipe to fix the build failure on Linaro's CI. Change-Id: I25f636f45af97bfd56a297b6826b2fcaf041c0b9 Signed-off-by: Ying-Chun Liu (PaulLiu) --- net/test/build_rootfs.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/net/test/build_rootfs.sh b/net/test/build_rootfs.sh index a86496b..6420a71 100755 --- a/net/test/build_rootfs.sh +++ b/net/test/build_rootfs.sh @@ -402,6 +402,7 @@ cd "${workdir}" # Process the initrd to remove kernel-specific metadata kernel_version=$(basename $(lz4 -lcd "${raw_initrd}" | sudo cpio -idumv 2>&1 | grep usr/lib/modules/ - | head -n1)) +lz4 -lcd "${raw_initrd}" | sudo cpio -idumv sudo rm -rf usr/lib/modules sudo mkdir -p usr/lib/modules -- cgit v1.2.3