Error When Calling Gcc.exe
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies of this site About Us Learn more about Stack Overflow the company Business Learn more about hiring developers or posting ads with us Stack Overflow Questions Jobs Documentation Tags Users Badges Ask Question x Dismiss Join the Stack Overflow Community Stack Overflow is a community of 4.7 million programmers, just like you, helping each other. Join them; it only takes a minute: Sign up CreateProcess: No such file or directory up vote 28 down vote favorite 4 I am getting this error whenever I try to run GCC outside of its installation directory (E:\MinGW\bin). So, let's say I am in E:\code and have a file called one.c. Running: gcc one.c -o one.exe will give me this error: gcc: CreateProcess: No such file or directory The only workaround is to navigate to its installation directory, run gcc from there, and specify all the other paths. My environmental variable "Path" contains E:\MinGW\bin. Any suggestions to fixing this problem? I am running Windows XP SP3. c gcc mingw share|improve this question edited Aug 4 at 17:22 Adrian McCarthy 24.3k653103 asked Oct 3 '10 at 2:49 Insomaniacal 5222610 3 Did you add it to the path AFTER you got this error using the windows environment variables GUI? If you did, and you're trying to run gcc in the same command shell you were using originally, it isn't going to work. That shell has its own copy of PATH that didn't get changed when you used the GUI. You can see this by typing echo %PATH% in your command shell. The fastest way to fix it would be to log out and log back in. –George Oct 3 '10 at 4:01 Ah, I figured that just spawning a new instance of CMD.exe would be enough for it to use the new "PATH" variable. However, it works fine now that I've tried logging out and in, it seems to work fine. Thanks! –Insomaniacal Oct 3 '10 at 11:49 add a comment| 24 Answers 24 active oldest votes up vote 0 down vote accepted Its specifically told that you need to reboot after you set the environmental variables in windows for migwin. share|improve this answer answered Dec 15 '10 at 7:14 kadaj 3,26622047 28 incorrect: in Windows 7 (per
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies of this site About Us Learn more about Stack Overflow the company Business Learn more about hiring developers or posting ads with us Stack Overflow Questions Jobs Documentation Tags Users Badges Ask Question x Dismiss Join the Stack Overflow Community Stack Overflow is http://stackoverflow.com/questions/3848357/createprocess-no-such-file-or-directory a community of 4.7 million programmers, just like you, helping each other. Join them; it only takes a minute: Sign up Cmake refuses to find the correct MinGW folder up vote 1 down vote favorite I'm completely at a loss here. I have a C++ project that uses CMake. It used to work, http://stackoverflow.com/questions/16797925/cmake-refuses-to-find-the-correct-mingw-folder but recently some weird problems came up, so I decided to reinstall the Qt SDK and CMake. However, now I get the following error when trying to build a file: CMake Error at C:/Program Files (x86)/CMake 2.8/share/cmake-2.8/Modules/CMakeTestCCompiler.cmake:61 (message): The C compiler "C:/Qt/Qt5.0.1/Tools/MinGW/bin/gcc.exe" is not able to compile a simple test program. It fails with the following output: CMake will not be able to correctly generate this project. Call Stack (most recent call first): CMakeLists.txt:1 (project) CMake Error: your C compiler: "C:/Qt/Qt5.0.1/Tools/MinGW/bin/gcc.exe" was not found. Please set CMAKE_C_COMPILER to a valid compiler path or name. CMake Error: your CXX compiler: "C:/Qt/Qt5.0.1/Tools/MinGW/bin/g++.exe" was not found. Please set CMAKE_CXX_COMPILER to a valid compiler path or name. CMake Error: Internal CMake error, TryCompile configure of cmake failed CMake Error: your C compiler: "C:/Qt/Qt5.0.1/Tools/MinGW/bin/gcc.exe" was not found. Please set CMAKE_C_COMPILER to a valid compiler path or name.-- The C compiler identification is unknown -- The CXX compiler identification is unknown -
Bender Books CalaTK CDash CMake Dart DataFusion Farsight IGSTK Insight https://itk.org/Bug/view.php?id=8516 Journal Insight Software Consortium KWStyle KWWidgets LesionSizingKit NSF_HE Old ParaView Bugs OpenGeoscience ParaQ-Administrative Publication Database SlideAtlas SOViewer System Administration VES Visomics VTKEdge Xdmf My https://intellij-support.jetbrains.com/hc/en-us/community/posts/205822049-New-User-Getting-Started-Problem-with-MinGW-Simple-Test View | View Issues | Change Log | RoadmapView Issue Details[Jump to Notes] [Issue History] [Print] IDProjectCategoryView StatusDate SubmittedLast Update0008516CMakeCMakepublic2009-02-11 16:142016-06-10 14:30ReporterLudovic MagerandAssigned error when ToBill HoffmanPrioritynormalSeveritymajorReproducibilityalwaysStatusclosedResolutionmovedPlatformOSOS VersionProduct VersionCMake-2-6Target VersionFixed in VersionSummary0008516: Failled to test C compiler with MinGWDescriptionI was trying to generate Code::Blocks project using CMake 2.6.2-patch2 and this is failling with error like the one in the log provided as additional information. I tested with other generators using MinGW, and they error when calling all fails with the exact same error. I also tested with the nightly build of CMake 2.7 of a few days ago, the same thing happen. I now use the latest MinGW and utils freshly downloaded but I originaly tried with the MinGW embedded into Code::Blocks 8.02, same happen on both. As I'm reading the log again, I just remarks that there is a "é" in the path to the written file, so I just tested on a new directory without such character and it's working. I'm not sure if it's a CMake or MinGW bug but as I found it with CMake I report it there.Additional InformationThe C compiler identification is GNU The CXX compiler identification is GNU Check for working C compiler: C:/MinGW/bin/gcc.exe Check for working C compiler: C:/MinGW/bin/gcc.exe -- broken CMake Error at C:/Program Files/CMake 2.6/share/cmake-2.6/Modules/CMakeTestCCompiler.cmake:32
I have installed CLion on a Windows 10 system and would like to learn how to use it to write and compile C++ programs, but I am seeing errors everf before I can get started. This is a copy of the the error I am seeing in every project I have created or opened:Error:The C compiler "C:/MinGW/bin/gcc.exe" is not able to compile a simple test program. It fails with the following output: Change Dir: C:/Users/Gil/.CLion12/system/cmake/generated/282db9ba/282db9ba/__default__/CMakeFiles/CMakeTmp Run Build Command:"C:/MinGW/bin/mingw32-make.exe" "cmTC_bec7a/fast" C:/MinGW/bin/mingw32-make.exe -f CMakeFiles\cmTC_bec7a.dir\build.make CMakeFiles/cmTC_bec7a.dir/build mingw32-make.exe[1]: Entering directory 'C:/Users/Gil/.CLion12/system/cmake/generated/282db9ba/282db9ba/__default__/CMakeFiles/CMakeTmp' Building C object CMakeFiles/cmTC_bec7a.dir/testCCompiler.c.obj C:\MinGW\bin\gcc.exe -o CMakeFiles\cmTC_bec7a.dir\testCCompiler.c.obj -c C:\Users\Gil\.CLion12\system\cmake\generated\282db9ba\282db9ba\__default__\CMakeFiles\CMakeTmp\testCCompiler.c Linking C executable cmTC_bec7a.exe "C:\Program Files (x86)\JetBrains\CLion 1.2.4\bin\cmake\bin\cmake.exe" -E cmake_link_script CMakeFiles\cmTC_bec7a.dir\link.txt --verbose=1 Error opening link script "CMakeFiles\cmTC_bec7a.dir\link.txt" CMakeFiles\cmTC_bec7a.dir\build.make:98: recipe for target 'cmTC_bec7a.exe' failed mingw32-make.exe[1]: *** [cmTC_bec7a.exe] Error 1 mingw32-make.exe[1]: Leaving directory 'C:/Users/Gil/.CLion12/system/cmake/generated/282db9ba/282db9ba/__default__/CMakeFiles/CMakeTmp' Makefile:125: recipe for target 'cmTC_bec7a/fast' failed mingw32-make.exe: *** [cmTC_bec7a/fast] Error 2 CMake will not be able to correctly generate this project.Using SysInternal's Procmon to get a grasp of what is happening I can see a file being created called "CMakeFiles\cmTC_bec7a.dir\link.txt," but it is deleted before the CLion cmake.exe program attempts to open the file.I think I have the toolchain setup correctly for this, but you can see what I have here:I have also noticed with procmon.exe that the failing process is looking for link.txt here: c:\CMakeFiles\cmTC_bec7a.dir\link.txt. It appears that instance of cmd.exe that executes this call has a default directory of c:\ while other related processes are run from a cmd.exe that has C:/Users/Gil/.CLion12/system/cmake/generated/282db9ba/282db9ba/__default__/CMakeFiles/CMakeTmp set as the default direct