diff --git a/make_usd_card.sh b/make_usd_card.sh index 9ac8764..58ff932 100755 --- a/make_usd_card.sh +++ b/make_usd_card.sh @@ -37,12 +37,15 @@ dd if=simpleimage-pine64-${SIMPLEIMAGE_VERSION}.img | pv | dd of=$SD_DEV bs=1024 /bin/echo -e "d\n2\nn\np\n2\n143360\n\nw\n" | sudo fdisk $SD_DEV -sudo mkfs.ext4 -O ^has_journal -b 4096 -L rootfs -U deadbeef-dead-beef-dead-beefdeadbeef ${SD_DEV}p2 +sleep 3 +partprobe -mount ${SD_DEV}p2 $SD_MOUNT_POINT +sudo mkfs.ext4 -F -O ^has_journal -O ^64bit -b 4096 -L "rootfs" ${SD_DEV}2 + +mount ${SD_DEV}2 $SD_MOUNT_POINT mkdir -p $SD_MOUNT_POINT/bootenv -mount ${SD_DEV}p1 $SD_MOUNT_POINT/bootenv +mount ${SD_DEV}1 $SD_MOUNT_POINT/bootenv wget -c http://ftp.arm.slackware.com/slackwarearm/slackwarearm-devtools/minirootfs/roots/slack-${SLACKWARE_VERSION}-miniroot_${SLACKWARE_MINIROOTFS_VERSION}.tar.xz tar --numeric-owner -C $SD_MOUNT_POINT/ -xpJf slack-${SLACKWARE_VERSION}-miniroot_${SLACKWARE_MINIROOTFS_VERSION}.tar.xz @@ -61,8 +64,9 @@ EOF cat <> $SD_MOUNT_POINT/etc/fstab -/dev/mmcblk0p2 / ext4 defaults,discard 1 1 -tmpfs /tmp tmpfs defaults,mode=777 0 0 +/dev/mmcblk0p1 /bootenv vfat defaults 1 1 +/dev/mmcblk0p2 / ext4 defaults,discard 1 1 +tmpfs /tmp tmpfs defaults,mode=777 0 0 EOF cat < $SD_MOUNT_POINT/etc/motd