1 # Platform defines. 2 set(CMAKE_SYSTEM_NAME Linux) 3 set(CMAKE_CROSSCOMPILING 1) 4 set(DE_CPU "DE_CPU_ARM") 5 6 # Toolchain/compiler base. 7 set(ARM_CC_BASE "/opt/arm-2011.03" CACHE STRING "CodeSourcery GCC cross-compiler path") 8 set(CROSS_COMPILE "${ARM_CC_BASE}/bin/arm-none-linux-gnueabi-" CACHE STRING "Cross compiler prefix") 9 10 set(CMAKE_C_COMPILER "${CROSS_COMPILE}gcc") 11 set(CMAKE_CXX_COMPILER "${CROSS_COMPILE}g++") 12 13 # Search libs and include files (but not programs) from toolchain dir. 14 set(CMAKE_FIND_ROOT_PATH "${ARM_CC_BASE}/arm-none-linux-gnueabi/libc/" ${ARM_CC_EXTRA_ROOT_PATHS}) 15 set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER) 16 set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY) 17 set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY) 18