CLion CMake问题

时间:2016-10-09 01:18:02

标签: cmake clion

在CLion上加载CMake时遇到问题。我正在尝试为Arduino编程设置适当的环境。

我可能错过了一些明显的东西,但我无法找到一个功能性解决方案。任何人都可以给我一个关于导致以下错误的提示吗?

Error:The CMAKE_C_COMPILER:
 avr-gcc 
is not a full path and was not found in the PATH.
Tell CMake where to find the compiler by setting either the environment 
variable "CC" or the CMake cache entry CMAKE_C_COMPILER to the full path to 
the compiler, or to the compiler name if it is in the PATH.

Error:The CMAKE_CXX_COMPILER:
  avr-g++
is not a full path and was not found in the PATH.
Tell CMake where to find the compiler by setting either the environment 
variable "CXX" or the CMake cache entry CMAKE_CXX_COMPILER to the full path 
to the compiler, or to the compiler name if it is in the PATH.

1 个答案:

答案 0 :(得分:0)

我按照arduino-cmake repo中给出的步骤开始工作。如果您正在使用Windows,请确保已安装arduino sdk。并在sdk中设置正确的路径。

如果您正在使用linux,请确保按照github repo中的readme.md中的指定安装了所有正确的依赖项。

最后但并非最不重要的是,确保项目文件夹中存在de cmake目录和工具链文件。

请参阅 https://github.com/arduino-cmake/arduino-cmake 如需正确的说明。