Dies ist eine alte Version des Dokuments!


Toradex Colibri i.MX6 - Toolchain (for applications)

rootfs GCC 5.3

If you use our standard rootfs, you have GCC 5.3 installed. To build an application for that system, provide CMake the path to the CMake toolchainfile. This file can be found in /usr/share/buildroot/toolchain.cmake

rootfs GCC 4.8

If you use our PATHOS-rootfs built with Buildroot (uses GLIBC), you can use the default Toolchain from Ubuntu.

Install toolchain (4.8.2) with Ubuntu 14.04:

$ sudo apt-get install g++-arm-linux-gnueabihf

To compile applications with cmake use this toolchain file:

set(CMAKE_SYSTEM_NAME Linux)

set(TOOLCHAIN_PREFIX arm-linux-gnueabihf)
set(CMAKE_C_COMPILER ${TOOLCHAIN_PREFIX}-gcc)
set(CMAKE_CXX_COMPILER ${TOOLCHAIN_PREFIX}-g++)

set(CMAKE_FIND_ROOT_PATH /usr/${TOOLCHAIN_PREFIX})
set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)

And configure cmake with this command:

$ cd path/to/working/directory
$ mkdir build
$ cd build
$ cmake path/to/application/source/ -DCMAKE_TOOLCHAIN_FILE=path/to/arm-linux-gnueabihf.cmake