Skip to content

Instantly share code, notes, and snippets.

@arturfog
Created October 4, 2018 18:19
Show Gist options
  • Save arturfog/0cf089dc2825699e15a1e4a9b31ad1f8 to your computer and use it in GitHub Desktop.
Save arturfog/0cf089dc2825699e15a1e4a9b31ad1f8 to your computer and use it in GitHub Desktop.
Chroots to ARM environment that can be used for compiling and development
apt-get install qemu-user-static
# Mount my target filesystem on /mnt
mount -o loop fs.img /mnt
# Copy the static ARM binary that provides emulation
# Or, more simply: cp /usr/bin/qemu-arm-static /mnt/usr/bin
cp $(which qemu-arm-static) /mnt/usr/bin
# Finally chroot into /mnt, then run 'qemu-arm-static bash'
# This chroots; runs the emulator; and the emulator runs bash
chroot /mnt qemu-arm-static /bin/bash
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment