diff options
-rwxr-xr-x | data/live-build-config/hooks/live/40-linux-firmware.chroot | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/data/live-build-config/hooks/live/40-linux-firmware.chroot b/data/live-build-config/hooks/live/40-linux-firmware.chroot index a7f431da..7d0de1f2 100755 --- a/data/live-build-config/hooks/live/40-linux-firmware.chroot +++ b/data/live-build-config/hooks/live/40-linux-firmware.chroot @@ -4,10 +4,16 @@ # of the linux-firmware repository COMMIT="aa95e90b2c638f1ca6647d12b2d1b18284428f9c" -echo I: Retrieving Linux Firmware - commit ${COMMIT} +echo "I: Retrieving Linux Firmware - commit ${COMMIT}" + +ret=$(curl -w "%{http_code}" -o /tmp/linux-firmware-${COMMIT}.tar.gz \ + https://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git/snapshot/linux-firmware-${COMMIT}.tar.gz) + +if [ "${ret}" != "200" ]; then + echo E: Received HTTP error code \"${ret}\" when downloading Linux Firmware ... + exit 1 +fi -curl -o /tmp/linux-firmware-${COMMIT}.tar.gz \ - https://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git/snapshot/linux-firmware-${COMMIT}.tar.gz tar xf /tmp/linux-firmware-${COMMIT}.tar.gz -C /lib mv /lib/linux-firmware-${COMMIT} /lib/firmware rm -f /tmp/linux-firmware-${COMMIT}.tar.gz |