在Windows 10上设置Clion

时间:2018-06-06 14:59:39

标签: clion

我正在按照StackOverflow上的指南配置Clion,但我遇到了问题。关于make,C编译器和C ++编译器的部分有一些问题,但我不明白我应该做什么。

enter image description here

注意"测试CMake运行结束时出现错误"信息。当我点击"更多..."时,我看到了:

-- The C compiler identification is unknown
-- The CXX compiler identification is unknown
CMake Warning at /cygdrive/c/Users/SpeedHunter/.CLion2018.1/system/cygwin_cmake/share/cmake-3.10.3/Modules/Platform/CYGWIN.cmake:15 (message):
  CMake no longer defines WIN32 on Cygwin!

  (1) If you are just trying to build this project, ignore this warning or
  quiet it by setting CMAKE_LEGACY_CYGWIN_WIN32=0 in your environment or in
  the CMake cache.  If later configuration or build errors occur then this
  project may have been written under the assumption that Cygwin is WIN32.
  In that case, set CMAKE_LEGACY_CYGWIN_WIN32=1 instead.

  (2) If you are developing this project, add the line

    set(CMAKE_LEGACY_CYGWIN_WIN32 0) # Remove when CMake >= 2.8.4 is required

  at the top of your top-level CMakeLists.txt file or set the minimum
  required version of CMake to 2.8.4 or higher.  Then teach your project to
  build on Cygwin without WIN32.
Call Stack (most recent call first):
  /cygdrive/c/Users/SpeedHunter/.CLion2018.1/system/cygwin_cmake/share/cmake-3.10.3/Modules/CMakeSystemSpecificInformation.cmake:26 (include)
  CMakeLists.txt:1 (project)


-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- broken
CMake Error at /cygdrive/c/Users/SpeedHunter/.CLion2018.1/system/cygwin_cmake/share/cmake-3.10.3/Modules/CMakeTestCCompiler.cmake:52 (message):
  The C compiler

    "/usr/bin/cc"

  is not able to compile a simple test program.

It fails with the following output:

Change Dir: /cygdrive/c/Users/SpeedHunter/AppData/Local/Temp/cmake_check_environment/_build/CMakeFiles/CMakeTmp

Run Build Command:"/usr/bin/make.exe" "cmTC_4ca12/fast"

CMake will not be able to correctly generate this project.
Call Stack (most recent call first):
 CMakeLists.txt:1 (project)


-- Configuring incomplete, errors occurred!
See also "/cygdrive/c/Users/SpeedHunter/AppData/Local/Temp/cmake_check_environment/_build/CMakeFiles/CMakeOutput.log".
See also "/cygdrive/c/Users/SpeedHunter/AppData/Local/Temp/cmake_check_environment/_build/CMakeFiles/CMakeError.log".

Error code: 1

我该怎么办?

0 个答案:

没有答案