Toolchain-rpi64.cmake 538 B

12345678910111213
  1. # -- How to cross compile for Raspberry Pi (on a 64bit host) --
  2. # 1) get the toolchain
  3. # cd ~
  4. # git clone https://github.com/raspberrypi/tools
  5. # 2) export path to one of the compilers
  6. # export PATH=$PATH:~/tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian-x64/bin/
  7. # 3) use this toolchain file
  8. # cmake -DCMAKE_TOOLCHAIN_FILE=../tools/cmake/Toolchain-rpi64.cmake -DEXAMPLESERVER=ON ..
  9. # make
  10. set(CMAKE_C_COMPILER arm-linux-gnueabihf-gcc)
  11. set(CMAKE_CXX_COMPILER arm-linux-gnueabihf-g++)
  12. set(CMAKE_STRIP arm-linux-gnueabihf-strip)