diff --git a/Makefile.uboot.mk b/Makefile.uboot.mk index 72b1f43..67126fe 100644 --- a/Makefile.uboot.mk +++ b/Makefile.uboot.mk @@ -64,6 +64,7 @@ $(UBOOT_PACKAGE): u-boot-package $(UBOOT_LOADER) --deb-priority optional --category admin \ --force \ --depends debsums \ + --depends mtd-utils \ --deb-compression bzip2 \ --deb-field "Multi-Arch: foreign" \ --after-install u-boot-package/scripts/postinst.deb \ diff --git a/rootfs/make_rootfs.sh b/rootfs/make_rootfs.sh index c60f94c..3c36d64 100755 --- a/rootfs/make_rootfs.sh +++ b/rootfs/make_rootfs.sh @@ -8,7 +8,7 @@ # the simpleimage script of this project. # -set -e +set -eo pipefail BUILD="../build" DEST="$1" @@ -152,9 +152,9 @@ do_chroot() { do_install() { FILE=$(basename "$1") - cp "$1" "$DEST/$(basename "$1")" + cp "$1" "$DEST/$FILE" yes | do_chroot dpkg -i "$FILE" - do_chroot rm "$FILE" + rm -f "$DEST/$FILE" } # Run stuff in new system. @@ -199,7 +199,7 @@ apt-get -y install dosfstools curl xz-utils iw rfkill wpasupplicant openssh-serv nano git build-essential vim jq wget ca-certificates software-properties-common dirmngr \ gdisk parted figlet htop fake-hwclock usbutils sysstat fping iperf3 iozone3 ntp \ network-manager psmisc flash-kernel u-boot-tools ifupdown resolvconf \ - net-tools mtd-utils rsync + net-tools mtd-utils rsync device-tree-compiler debsums if [[ "$DISTRIB" == "debian" ]]; then apt-get -y install firmware-realtek elif [[ "$DISTRIB" == "ubuntu" ]]; then