Mount USB rootfs in sysroot
Owners: Haitao Feng, Kevin Wang
Developers can create a USB booting disk and mount it directly then build and install binaries to the disk and use the USB to boot the Netbook for testing and debugging.
Requirements
- Netbook
- 2 USB disks (>4G)
Create Moblin development image
-
Install Moblin Image Creator 2. - Create Moblin development image
Please use the kickstart file in the SDK tarball to create your own development image:
$ sudo moblin-image-creator -c ~/moblin-sdk-${version}/tools/ks_files/2.1-developer.ks -f livecd --cache=/tmp/mycacheFor details about creating a new development image, please refer to: Using Moblin Image Creator 2
Create USB booting disk
- Burn the image to the USB disk1
- Install Moblin to the USB disk2
- Update USB disk2 to make it bootable
- Edit "menu.list" of the grub, to make moblin boot from /dev/sdb1 with "rootdelay=10"
- Edit "etc/fstab" to update "sdc" with "sdb"
Build the Moblin developer image to the USB disk1, assuming the USB stick is /dev/sdb in your system:
$ sudo dd if=moblin-2.1-developer-XXXXXXXX.iso of=/dev/sdbinsert two USB disks to the netbook, and boot the netbook with USB1, select "Boot and Install" and install the Moblin image to USB disk2 (not netbook) and install boot loader on the USB disk2.
Mount the USB disk2 to sys-root
you could mount the USB disk2 to the sys-root directly, and build the application with the sys-root, and install the binaries to the USB disk2 directly, assuming the USB stick is /dev/sdb in your system:
$ sudo mount /dev/sdb1 ~/moblin-sdk-${version}/moblin-cross-toolchain/i586-moblin-linux/sys-root/Umount the sys-root
$ sudo umount ~/moblin-sdk-${version}/moblin-cross-toolchain/i586-moblin-linux/sys-root/ Boot the netbook with the USB disk2
You can install the app binaries to the USB disk2, boot with that disk and debug with the USB disk directly.
- Printer-friendly version
- Login or register to post comments