[CMake] trouble with cmake 2.6-patch 0 cross compiling.

Axel Roebel axel.roebel at ircam.fr
Thu Jul 17 03:55:42 EDT 2008


On Wednesday 16 July 2008 8:54:11 pm cmake-request at cmake.org wrote:
> Hi.
>
> I've got cmake 2.6-patch 0 installed and I'm trying to get a simple
> (helloworld.cpp) compiled and built on a linux system.
>
> My toolchain file looks like this:
>
> -- toolchain.cmake --
> SET( CMAKE_SYSTEM_NAME foobar )
> SET( CMAKE_SYST EM_VERSION 1 )
> SET( CMAKE_SYSTEM_PROCESSOR arm-foo )
> SET( CMAKE_SYSTEM_C_COMPILER /absolute/path/to/compiler )
> SET( CMAKE_SYSTEM_CXX_COMPILER /absolute/path/to/compiler )
Hi Phil,

I think you simply mixed these up. The last ones should be

SET( CMAKE_C_COMPILER /absolute/path/to/compiler )
SET( CMAKE_CXX_COMPILER /absolute/path/to/compiler )

no SYSTEM_ there!

see: http://www.cmake.org/Wiki/CMake_Cross_Compiling

Cheers,

Axel

> SET( CMAKE_FIND_ROOT_PATH /absolute/path/to/compiler/tools )
>
> SET( CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER )
> SET( CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY )
> SET( CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY )



-- 
Axel Roebel
IRCAM Analysis/Synthesis Team
Phone: ++33-1-4478 4845 | Fax: ++33-1-4478 1540


More information about the CMake mailing list