I have two things I can't figure out.
(1)When using CMake-GUI
, we can specify makefile generator. I am going to cross compile for Raspberry PI with Debian Linux. I can't find the relevant generator. Which generator I have to choose?
I have toolchain-rpi.cmake
as follow.
INCLUDE(CMakeForceCompiler)
SET(CMAKE_SYSTEM_NAME Linux) # this one is important
SET(CMAKE_SYSTEM_VERSION 1) # this one not so much
SET(CMAKE_C_COMPILER $ENV{RPI_CC}/bin/arm-bcm2708hardfp-linux-gnueabi-gcc)
SET(CMAKE_CXX_COMPILER $ENV{RPI_CC}/bin/arm-bcm2708hardfp-linux-gnueabi-g++)
SET(CMAKE_AR $ENV{RPI_CC}/bin/arm-bcm2708hardfp-linux-gnueabi-ar)
SET(CMAKE_LINKER $ENV{RPI_CC}/bin/arm-bcm2708hardfp-linux-gnueabi-ld)
SET(CMAKE_NM $ENV{RPI_CC}/bin/arm-bcm2708hardfp-linux-gnueabi-nm)
SET(CMAKE_OBJCOPY $ENV{RPI_CC}/bin/arm-bcm2708hardfp-linux-gnueabi-objcopy)
SET(CMAKE_OBJDUMP $ENV{RPI_CC}/bin/arm-bcm2708hardfp-linux-gnueabi-objdump)
SET(CMAKE_STRIP $ENV{RPI_CC}/bin/arm-bcm2708hardfp-linux-gnueabi-strip)
SET(CMAKE_RANLIB $ENV{RPI_CC}/bin/arm-bcm2708hardfp-linux-gnueabi-tanlib)
# where is the target environment
SET(CMAKE_FIND_ROOT_PATH $ENV{RPI_CC}/arm-bcm2708hardfp-linux-gnueabi)
# search for programs in the build host directories
SET(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
# for libraries and headers in the target directories
SET(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
SET(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)
(2) When I run cmake at command window at Windows7, it is compiling for Visual Studio 10 in default (I don't choose any option and it happens in default) as -- Building for: Visual Studio 10
. How can I change it to build for Debian Linux?
Thanks