无法在 clion 中运行任何程序
can't run any program in clion
我下载了clion,并在以下位置浏览了jetbeans提供的设置指南:https://www.jetbrains.com/help/clion/2016.3/quick-tutorial-on-configuring-clion-on-windows.html我尝试将cygwin和minGW都设置为环境,但程序无法运行。我遵循了这个问题:如何设置Clion进行编译和运行
我也在路径中附加了cygwin和minGW的目录,但仍然无法运行我的程序。
它引发了一个长期错误,即:
CMake Error at /cygdrive/c/Users/dell/.CLion2016.3/system/cygwin_cmake/share/cmake-3.6.3/Modules/CMakeTestCCompiler.cmake:61 (message):
The C compiler "/cygdrive/c/MinGW/bin/gcc.exe" is not able to compile a
simple test program.
它失败,输出如下:
Change Dir: /cygdrive/c/Users/dell/Desktop/jetBeans/c_c++/cmake-build-debug/CMakeFiles/CMakeTmp
Run Build Command:"/usr/bin/make.exe" "cmTC_2284f/fast"
/usr/bin/make -f CMakeFiles/cmTC_2284f.dir/build.make
CMakeFiles/cmTC_2284f.dir/build
make[1]: Entering directory
'/cygdrive/c/Users/dell/Desktop/jetBeans/c_c++/cmake-build-debug/CMakeFiles/CMakeTmp'
Building C object CMakeFiles/cmTC_2284f.dir/testCCompiler.c.o
/cygdrive/c/MinGW/bin/gcc.exe -o
CMakeFiles/cmTC_2284f.dir/testCCompiler.c.o -c
/cygdrive/c/Users/dell/Desktop/jetBeans/c_c++/cmake-build-debug/CMakeFiles/CMakeTmp/testCCompiler.c
gcc.exe: error:
/cygdrive/c/Users/dell/Desktop/jetBeans/c_c++/cmake-build-debug/CMakeFiles/CMakeTmp/testCCompiler.c:
No such file or directory
gcc.exe: fatal error: no input files
compilation terminated.
make[1]: *** [CMakeFiles/cmTC_2284f.dir/build.make:66:
CMakeFiles/cmTC_2284f.dir/testCCompiler.c.o] Error 1
make[1]: Leaving directory
'/cygdrive/c/Users/dell/Desktop/jetBeans/c_c++/cmake-build-debug/CMakeFiles/CMakeTmp'
make: *** [Makefile:126: cmTC_2284f/fast] Error 2
CMake will not be able to correctly generate this project.
Call Stack (most recent call first):
CMakeLists.txt:2 (project)
-- Configuring incomplete, errors occurred!
See also "/cygdrive/c/Users/dell/Desktop/jetBeans/c_c++/cmake-build-debug/CMakeFiles/CMakeOutput.log".
See also "/cygdrive/c/Users/dell/Desktop/jetBeans/c_c++/cmake-build-debug/CMakeFiles/CMakeError.log".
[Previous CMake output restored: 11-02-2017 04:45]
我在下载CLion产品时也遇到了一些问题,因为它对我来说很多时候都不起作用。然而,我发现了这个视频:
安装&配置CLion学生副本||C/C++的最佳IDE。
我所做的是卸载了CLion MinGW,然后重新开始。这可能不是最好的选择,但我无法确定手头的问题,所以我按照上面的视频重新安装了它。CLion现在为我工作。该视频用于在windows操作计算机上安装CLion。
只是一个建议,你可以先看看视频,看看你是否犯了任何错误。将视频中的讲师的做法与你的做法进行比较。如果你错过了导入某个包(本视频使用MinGW)之类的东西,那么这就是你错的地方。这样也可以解决问题。如果您无法确定错误,请尝试重新安装。祝您好运!
EDIT:为什么要安装MinGW和cygwin?你只需要其中一个。
相关文章:
- 在实践中,在运行时为零的乘法中是否有任何"lazy"评估
- 如果第一个元素包含任何零,则我的程序以不希望的方式运行
- 如何创建一个模板化函数,可以在任何具有字符串键的 std::map 上运行?
- Antlr cpp 运行时 任何错误的指针转换?
- 继续运行程序而无需任何干预,直到要求退出为止
- 我最近更改了编译器路径以运行 c++ 代码,但现在我无法运行任何 python 代码。我该如何解决这个问题?
- Qt qml - 在没有任何条件的情况下运行一行(while(true))
- 是否有任何 C 函数或 API 来获取当前登录用户下运行的进程列表
- 使用 CodeBlocks + GCC 构建的可执行文件是否可以在任何 Windows 上运行?
- Windows7+:如何构建不需要任何额外/外部运行时库的C++ Windows 控制台应用程序?
- 如何子类可运行任何成员功能
- 由于错误,c ++代码无法在Visual Studios上运行,但不显示任何错误
- 是否有任何可能的方法将事件(自定义)附加到在运行时创建的对象?[C 构建器]
- 程序在运行时不执行任何操作
- 无法在 clion 中运行任何程序
- Microsoft Visual Studio Express 2012将不会运行任何程序
- 无法在代码块中的多个文件中运行任何具有类的C++程序
- 除了 clang 之外,"clang -S -emit-llvm file.cpp"运行任何其他可执行文件吗?
- CEF上的WebRTC(getUserMedia)不工作.但它能在Chrome上运行.任何想法
- Eclipse没有运行任何应用程序