[FE training-materials-updates] U-boot lab: introduce CROSS_COMPILE properly

Boris Brezillon boris.brezillon at free-electrons.com
Fri May 22 17:13:09 CEST 2015


Repository : git://git.free-electrons.com/training-materials.git

On branch  : mtd-rework-WIP
Link       : http://git.free-electrons.com/training-materials/commit/?id=66e623bf76addf45aadb5f5b26e7162932c92d3f

>---------------------------------------------------------------

commit 66e623bf76addf45aadb5f5b26e7162932c92d3f
Author: Michael Opdenacker <michael.opdenacker at free-electrons.com>
Date:   Mon May 18 17:46:52 2015 +0200

    U-boot lab: introduce CROSS_COMPILE properly
    
    It wasn't introduced properly before)
    
    Signed-off-by: Michael Opdenacker <michael.opdenacker at free-electrons.com>


>---------------------------------------------------------------

66e623bf76addf45aadb5f5b26e7162932c92d3f
 labs/sysdev-u-boot/sysdev-u-boot.tex | 16 ++++++++++++----
 1 file changed, 12 insertions(+), 4 deletions(-)

diff --git a/labs/sysdev-u-boot/sysdev-u-boot.tex b/labs/sysdev-u-boot/sysdev-u-boot.tex
index 291158d..75f3629 100644
--- a/labs/sysdev-u-boot/sysdev-u-boot.tex
+++ b/labs/sysdev-u-boot/sysdev-u-boot.tex
@@ -145,12 +145,20 @@ combinations. In our case, we will load U-Boot, from NAND flash.
 
 Then, you've found the right \code{defconfig} file, load it using
 \code{make <defconfig_filename>} (just the file name, without
-the directory part), and you can start the compilation using
-\code{make}\footnote{You can speed up the compiling by using the
+the directory part).
+
+The next thing to do is to specific the cross-compiler prefix
+(the part before \code{gcc} in the cross-compiler executable name):
+
+\begin{verbatim}
+export CROSS_COMPILE=arm-linux-
+\end{verbatim}
+
+You can now start compiling using \code{make}
+\footnote{You can speed up the compiling by using the
   \code{-jX} option with \code{make}, where X is the number of
   parallel jobs used for compiling. Twice the number of CPU cores is a
-  good value.}. Don't forget to set the \code{CROSS_COMPILE}
-environment variable!
+  good value.}.
 
 At the end of the compilation, you should have a file called
 \code{sama5d3_xplained-nandflashboot-uboot-*.bin}, in the



More information about the training-materials-updates mailing list