June 2017
Intermediate to advanced
478 pages
13h 14m
English
Some important packages are very simple to cross compile, including the Linux kernel, the U-Boot bootloader, and BusyBox. For each of these, you only need to put the toolchain prefix in the make variable CROSS_COMPILE, for example arm-cortex_a8-linux-gnueabi-. Note the trailing dash -.
So, to compile BusyBox, you would type:
$ make CROSS_COMPILE=arm-cortex_a8-linux-gnueabihf-
Or, you can set it as a shell variable:
$ export CROSS_COMPILE=arm-cortex_a8-linux-gnueabihf-$ make
In the case of U-Boot and Linux, you also have to set the make variable ARCH to one of the machine architectures they support, which I will cover in Chapter 3, All About Bootloaders, and Chapter 4, Configuring and Building the Kernel.
Read now
Unlock full access