[ARMedslack] QEMU support - does anybody care about it?
cedric.vincent at gmail.com
Thu Sep 6 08:25:52 UTC 2012
For information, QEMU user-mode doesn't require any "guest" kernel
since all privileged operations are redirected to the "host" one.
Moreover the user-mode is a lot faster than the system-mode since
there's no device emulation at all .
Let me demonstrate how you can use your favorite distro with QEMU
user-mode and PRoot (its companion, http://proot.me) without any setup
or privilege. In the following example I assume the Slackware/ARM
rootfs  was extracted in the "./rootfs/" directory:
proot -Q qemu-arm -r ./rootfs/
At this point, you are running a shell "confined" in the Slackware/ARM
rootfs and all ARM programs are "translated" by QEMU user-mode:
guest$ file /bin/echo
/bin/echo: ELF 32-bit LSB executable, ARM, version 1 (SYSV),
dynamically linked (uses shared libs), stripped
guest$ /bin/echo "hello, world."
That way, you can do whatever you would do with a "real" Slackware/ARM
installation, for instance download and install new packages:
guest$ installpkg slackpkg-2.82.0-arm-3.tgz
guest$ installpkg ncurses-5.9-arm-2.tgz
For programs that require privileges, you can use the "-0" option to
fake the "root" id:
guest$ slackpkg update
Only root can install, upgrade, or remove packages.
Please log in as root or contact your system administrator.
host$ proot -Q qemu-arm -r ./rootfs/ -0
guest# slackpkg update
guest# slackpkg upgrade-all
guest# slackpkg install-new
Feel free to ask me for support,
PS: A couple of words about the use of PRoot and QEMU user-mode in the
industry: my team uses it to develop and optimize (GCC profile
base optimizations) embedded applications on x86_64 farms.
More information about the ARMedslack