Reputation: 13
As much searching as I've done, I've found so many answered questions here, yet absolutely none of them help my problem. I've been using gcc
to compile my C
code, and it's been working fine. I decided to start using C++
. I tried compiling it and didn't work:
PS D:\huntr> gcc ./test.cpp -o ./test.exe
gcc.exe: error: CreateProcess: No such file or directory
I have tried adding things to path, removing things from path, everything. No matter what I do, it keeps giving me this error. This is the output with -v
enabled:
PS D:\huntr> gcc ./test.cpp -o ./test.exe -v
Using built-in specs.
COLLECT_GCC=C:\MinGW\bin\gcc.exe
COLLECT_LTO_WRAPPER=c:/mingw/bin/../libexec/gcc/mingw32/6.3.0/lto-wrapper.exe
Target: mingw32
Configured with: ../src/gcc-6.3.0/configure --build=x86_64-pc-linux-gnu --host=mingw32 --target=mingw32 --with-gmp=/mingw --with-mpfr --with-mpc=/mingw --with-isl=/mingw --prefix=/mingw --disable-win32-registry --with-arch=i586 --with-tune=generic --enable-languages=c,c++,objc,obj-c++,fortran,ada --with-pkgversion='MinGW.org GCC-6.3.0-1' --enable-static --enable-shared --enable-threads --with-dwarf2 --disable-sjlj-exceptions --enable-version-specific-runtime-libs --with-libiconv-prefix=/mingw --with-libintl-prefix=/mingw --enable-libstdcxx-debug --enable-libgomp --disable-libvtv --enable-nls
Thread model: win32
gcc version 6.3.0 (MinGW.org GCC-6.3.0-1)
COLLECT_GCC_OPTIONS='-o' './test.exe' '-v' '-mtune=generic' '-march=i586'
cc1plus -quiet -v -iprefix c:\mingw\bin\../lib/gcc/mingw32/6.3.0/ ./test.cpp -quiet -dumpbase test.cpp -mtune=generic -march=i586 -auxbase test -version -o C:\Users\FOXROC~1\AppData\Local\Temp\cc44oQcd.s
gcc.exe: error: CreateProcess: No such file or directory
What should I do??
Upvotes: 1
Views: 1749
Reputation: 1
That happened to me a few days ago... I just installed again the compiler and then it worked
Upvotes: 0
Reputation: 38332
You did not install the required component mingw32-gcc-g++. You want to run the MinGW Installation Manager and select the required option on the Basic Setup pan.
Upvotes: 1