summaryrefslogtreecommitdiffstats
path: root/board
diff options
context:
space:
mode:
Diffstat (limited to 'board')
-rwxr-xr-xboard/kosagi/novena/novena_make_debian_rootfs_ext4.sh45
-rwxr-xr-xboard/kosagi/novena/novena_make_rom.sh2
2 files changed, 46 insertions, 1 deletions
diff --git a/board/kosagi/novena/novena_make_debian_rootfs_ext4.sh b/board/kosagi/novena/novena_make_debian_rootfs_ext4.sh
new file mode 100755
index 000000000..af6ee7cc8
--- /dev/null
+++ b/board/kosagi/novena/novena_make_debian_rootfs_ext4.sh
@@ -0,0 +1,45 @@
+#!/bin/sh
+
+set -e # halt on failure
+
+BOARD_DIR="$(dirname $0)"
+
+ROOTFS_IMG=$BINARIES_DIR/debian-rootfs.ext4
+ROOTFS_TARBALL=$BINARIES_DIR/debian-rootfs.tar
+
+WORK_DIR=$BASE_DIR/debian_rootfs_work
+
+FAKEROOT=$HOST_DIR/usr/bin/fakeroot
+# use wrapper script
+GENEXT2FS=$BASE_DIR/../fs/ext2/genext2fs.sh
+
+if [ ! -f $FAKEROOT ] ||
+ [ ! -f $GENEXT2FS ]; then
+ echo "makedisk and/or genfatfs missing."
+ exit 1
+fi
+
+if [ ! -f $ROOTFS_TARBALL ]; then
+ echo "debian rootfs tarball image missing."
+ exit 1
+fi
+
+if [ "$FAKEROOTKEY" = "" ]; then
+ echo "re-executing script inside fakeroot"
+ $FAKEROOT "$0" "$@";
+ exit
+fi
+
+PATH=$HOST_DIR/usr/bin/:$HOST_DIR/usr/sbin/:$PATH
+
+# alright, on with it.
+mkdir -p $WORK_DIR
+cd $WORK_DIR
+tar xf $ROOTFS_TARBALL
+GEN=4 REV=1 $GENEXT2FS -d $WORK_DIR $ROOTFS_IMG
+
+cd ..
+rm -rf $WORK_DIR
+
+set +x # verbose command output off
+echo "Created $ROOTFS_IMG"
diff --git a/board/kosagi/novena/novena_make_rom.sh b/board/kosagi/novena/novena_make_rom.sh
index 976cc5f8f..31ad49aa1 100755
--- a/board/kosagi/novena/novena_make_rom.sh
+++ b/board/kosagi/novena/novena_make_rom.sh
@@ -15,7 +15,7 @@ KERNEL_DTB_RENAME=uImage-novena.dtb
UBOOT_BIN=$BINARIES_DIR/u-boot.imx
UBOOT_SCR=$BINARIES_DIR/boot.scr
-ROOTFS_IMG=$BINARIES_DIR/rootfs.ext4
+ROOTFS_IMG=$BINARIES_DIR/debian-rootfs.ext4
WORK_DIR=$BASE_DIR/makedisk
FATFS_BLOCKS=65536