diff options
author | bnewbold <bnewbold@robocracy.org> | 2013-08-23 06:52:25 +0000 |
---|---|---|
committer | bnewbold <bnewbold@robocracy.org> | 2013-08-23 06:52:25 +0000 |
commit | c56b187192567696d00b792759aebc5b40f271eb (patch) | |
tree | ffb6dc58e52165fd7490025666be79ea3a4b850b | |
parent | e82063b4aa9a4803a8fcb62bea6638112e636a5a (diff) | |
download | buildroot-novena-c56b187192567696d00b792759aebc5b40f271eb.tar.gz buildroot-novena-c56b187192567696d00b792759aebc5b40f271eb.zip |
early work on debian rootfs integration
-rwxr-xr-x | board/kosagi/novena/novena_make_debian_rootfs_ext4.sh | 45 | ||||
-rwxr-xr-x | board/kosagi/novena/novena_make_rom.sh | 2 |
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 |