cross-compiling

Setting up a crosstool-ng environment for ARM7 target

apt-get install ia32-libs ia32-libs-gtk

gcc -m32 (see http://wiki.debian.org/DebianAMD64Faq)

linux32 make

Building an i386 kernel package on an amd64 machine without chroot

In addition to ia32-libs, install gcc-arm-linux-gnueabi (armel), or gcc-arm-linux-gnueabihf (armhf).

We can do clean cross-builds using full qemu emulation or using user mode emulation with a chroot. Both options are described in the Ubuntu RootfsFromScratch page.

See also:

Using qemu. Here we create a rootfs with rootstock and run qemu with full emulation, which allows us to build packages inside the VM with the usual tools like pbuilder.

Using a chroot. Qemu with user mode emulation and a chroot to be able to run the binaries.

Useful Linaro cross-build pages.

The latest way of creating a rootfs is through Ubuntu Core.

http://ports.ubuntu.com/ubuntu-ports/dists/precise/main/installer-armel/current/images/omap4/cdrom/vmlinuz

rootstock --fqdn qemu-test --login qemu --password qemu --imagesize 2G --seed build-essential,openssh-server --notarball
wget http://ports.ubuntu.com/ubuntu-ports/dists/precise/main/installer-armel/current/images/omap4/cdrom/vmlinuz
  • cross-compiling.txt
  • Last modified: 5 years ago
  • by admin