mirror of
https://github.com/PartialVolume/shredos.x86_64.git
synced 2026-02-20 17:42:10 +00:00
Allow to append a FAT16 partition image when building an ISO in hybrid mode. This allows to add an extra writeable partition for when the ISO is burned to USB. This feature is experimental and disabled by default. Signed-off-by: desertwitch <24509509+desertwitch@users.noreply.github.com>
19 lines
956 B
Bash
Executable File
19 lines
956 B
Bash
Executable File
#!/bin/bash -e
|
|
|
|
# This file produces the extra FAT16 partition for the shredos_iso_extra_*_defconfig configurations.
|
|
# The partition is appended to the ISO, so that when written to USB a writeable partition is available.
|
|
|
|
rm "${BINARIES_DIR}"/extra.vfat || true
|
|
|
|
dd if=/dev/zero of="${BINARIES_DIR}/extra.vfat" bs=50M count=1 || exit 1
|
|
"$HOST_DIR"/sbin/mkfs.vfat -F16 "${BINARIES_DIR}/extra.vfat" || exit 1
|
|
|
|
"$HOST_DIR"/bin/mmd -i "${BINARIES_DIR}/extra.vfat" ::/boot || exit 1
|
|
|
|
"$HOST_DIR"/bin/mcopy -p -m -i "${BINARIES_DIR}/extra.vfat" board/shredos/fsoverlay/etc/shredos/version.txt ::/boot/version.txt || exit 1
|
|
"$HOST_DIR"/bin/mcopy -p -m -i "${BINARIES_DIR}/extra.vfat" board/shredos/README.txt ::/README.txt || exit 1
|
|
"$HOST_DIR"/bin/mcopy -p -m -i "${BINARIES_DIR}/extra.vfat" board/shredos/autorun.inf ::/autorun.inf || exit 1
|
|
"$HOST_DIR"/bin/mcopy -p -m -i "${BINARIES_DIR}/extra.vfat" board/shredos/shredos.ico ::/shredos.ico || exit 1
|
|
|
|
exit 0
|