mirror of
https://github.com/MiyooCFW/buildroot.git
synced 2025-09-27 22:24:19 +03:00
add build fatresize from source
This commit is contained in:
@@ -3,26 +3,18 @@
|
||||
MOUNTDIR=/boot
|
||||
# expect to be run from /boot, where the boot partition is mounted (readonly)
|
||||
|
||||
# also expect CONSOLE_VARIANT to be passed in = already set from /etc/main
|
||||
# also expect the screen driver to be loaded in /etc/main
|
||||
|
||||
# create swap
|
||||
mkswap /dev/mmcblk0p3 | tee -a ${LOG}
|
||||
swapon /dev/mmcblk0p3 | tee -a ${LOG}
|
||||
|
||||
LOG=/dev/null
|
||||
|
||||
BINDIR="${MOUNTDIR}/misc/bin"
|
||||
FATFSCK="fsck.fat"
|
||||
|
||||
# high brightness
|
||||
echo '10' > /sys/devices/platform/backlight/backlight/backlight/brightness
|
||||
|
||||
#echo -e "\e[?3c"
|
||||
echo -e "\e[32m" # green
|
||||
|
||||
# action time - copy over the kernel and the config files
|
||||
|
||||
echo "firstboot script running..." | tee -a ${LOG}
|
||||
echo
|
||||
|
||||
@@ -68,9 +60,9 @@ if test -e "${MOUNTDIR}/resize"; then
|
||||
echo "Going to resize the MAIN partition." | tee -a ${LOG}
|
||||
echo "This can take A LONG TIME, so be patient." | tee -a ${LOG}
|
||||
umount /dev/mmcblk0p4 | tee -a ${LOG}
|
||||
"${FATFSCK}" -y /dev/mmcblk0p4 | tee -a ${LOG}
|
||||
"${BINDIR}/fatresize_hc" | tee -a ${LOG}
|
||||
"${FATFSCK}" -y /dev/mmcblk0p4 | tee -a ${LOG}
|
||||
fsck.fat -y /dev/mmcblk0p4 | tee -a ${LOG}
|
||||
fatresize_hc | tee -a ${LOG}
|
||||
fsck.fat -y /dev/mmcblk0p4 | tee -a ${LOG}
|
||||
echo -n -e \\xEB\\x58\\x90 > /dev/mmcblk0p4
|
||||
sync
|
||||
mount -t vfat -o rw,sync,utf8 /dev/mmcblk0p4 /mnt | tee -a ${LOG}
|
||||
|
||||
@@ -1,2 +0,0 @@
|
||||
# some statically compiled binaries
|
||||
* `fatresize_hc` is a "minimal fat resize example" using `libparted`; the source code is [here](https://github.com/flabbergast/fatresize/tree/hardcoded); compiling requires static(musl) toolchain from the above buildroot
|
||||
Binary file not shown.
@@ -12,9 +12,6 @@ image bootfs.vfat {
|
||||
"boot/firstboot.custom.sh-OFF",
|
||||
"boot/normalboot.custom.sh"
|
||||
}
|
||||
file misc/bin/fatresize_hc {
|
||||
image = "boot/misc/bin/fatresize_hc"
|
||||
}
|
||||
file configs/manifest {
|
||||
image = "boot/configs/manifest"
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user