NVIDIA Tegra
NVIDIA Tegra Linux Driver Package

Development Guide
32.1 Release


 
The L4T Toolchain
 
Toolchain Information
Downloading the Toolchain
Extracting the Toolchain
Setting the CROSS_COMPILE Environment Variable
NVIDIA® specifies Linaro® gcc 7.3 2018.05 for the following activities:
Cross-compiling applications to run on L4T rel-32.
Cross-compiling code in the L4T rel-32 source release.
This topic describes how to obtain this toolchain.
Toolchain Information
The toolchain contains the following components:
GCC version: 7.3
Binutils version: 2.28.2.20170706
Glibc version: 2.25
The toolchain exists in both AArch64 and armhf flavors. The AArch64 toolchain should be used in almost all cases.
Downloading the Toolchain
Download the pre-built toolchain binaries from:
http://releases.linaro.org/components/toolchain/binaries/7.3-2018.05/aarch64-linux-gnu/gcc-linaro-7.3.1-2018.05-i686_aarch64-linux-gnu.tar.xz
Extracting the Toolchain
Execute the following commands to extract the toolchain:
$ mkdir $HOME/l4t-gcc
$ cd $HOME/l4t-gcc
$ tar xf gcc-linaro-7.3.1-2018.05-x86_64_aarch64-linux-gnu.tar.xz
$ tar xf gcc-linaro-7.3.1-2018.05-x86_64_arm-linux-gnueabihf.tar.xz
Setting the CROSS_COMPILE Environment Variable
Many build systems require you to set environment variable CROSS_COMPILE to point at the toolchain to use. To set CROSS_COMPILE for the AArch64 toolchain:
$ export CROSS_COMPILE=$HOME/l4t-gcc/gcc-linaro-7.3.1-2018.05-x86_64_aarch64-linux-gnu/bin/aarch64-linux-gnu-
To set CROSS_COMPILE for the armhf toolchain:
$ export CROSS_COMPILE=$HOME/l4t-gcc/gcc-linaro-7.3.1-2018.05-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-