在VSCODE里运行。出现报错
这是为什么呢?
D:\IGCA\Commander\src_cpp> .\build.bat
-- The C compiler identification is GNU 10.1.0
-- The CXX compiler identification is GNU 10.1.0
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - failed
-- Check for working C compiler: D:/2020.5.30_mingw64/mingw64/bin/gcc.exe
-- Check for working C compiler: D:/2020.5.30_mingw64/mingw64/bin/gcc.exe - broken
CMake Error at F:/C_make/share/cmake-3.20/Modules/CMakeTestCCompiler.cmake:66 (message):
The C compiler
"D:/2020.5.30_mingw64/mingw64/bin/gcc.exe"
is not able to compile a simple test program.
It fails with the following output:
Change Dir: D:/IGCA/Commander/src_cpp/Build/CMakeFiles/CMakeTmp
Run Build Command(s):D:/2020.5.30_mingw64/mingw64/bin/mingw32-make.exe -f Makefile cmTC_610d2/fast && D:/2020.5.30_mingw64/mingw64/bin/mingw32-make.exe -f CMakeFiles\cmTC_610d2.dir\build.make CMakeFiles/cmTC_610d2.dir/build
mingw32-make[1]: Entering directory 'D:/IGCA/Commander/src_cpp/Build/CMakeFiles/CMakeTmp'
Building C object CMakeFiles/cmTC_610d2.dir/testCCompiler.c.obj
D:\2020.5.30_mingw64\mingw64\bin\gcc.exe -o CMakeFiles\cmTC_610d2.dir\testCCompiler.c.obj -c D:\IGCA\Commander\src_cpp\Build\CMakeFiles\CMakeTmp\testCCompiler.c
Linking C executable cmTC_610d2.exe
F:\C_make\bin\cmake.exe -E cmake_link_script CMakeFiles\cmTC_610d2.dir\link.txt --verbose=1
F:\C_make\bin\cmake.exe -E rm -f CMakeFiles\cmTC_610d2.dir/objects.a
D:\2020.5.30_mingw64\mingw64\bin\ar.exe cr CMakeFiles\cmTC_610d2.dir/objects.a @CMakeFiles\cmTC_610d2.dir\objects1.rsp
D:\2020.5.30_mingw64\mingw64\bin\gcc.exe -Wl,--whole-archive CMakeFiles\cmTC_610d2.dir/objects.a -Wl,--no-whole-archive -o cmTC_610d2.exe -Wl,--out-implib,libcmTC_610d2.dll.a -Wl,--major-image-version,0,--minor-image-version,0 @CMakeFiles\cmTC_610d2.dir\linklibs.rsp
D:/2020.5.30_mingw64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/10.1.0/../../../../x86_64-w64-mingw32/bin/ld.exe: cannot find crt2.o: No such file or directory
D:/2020.5.30_mingw64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/10.1.0/../../../../x86_64-w64-mingw32/bin/ld.exe: cannot find crtbegin.o: No such file or directory
D:/2020.5.30_mingw64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/10.1.0/../../../../x86_64-w64-mingw32/bin/ld.exe: cannot find default-manifest.o: No such file or directory
D:/2020.5.30_mingw64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/10.1.0/../../../../x86_64-w64-mingw32/bin/ld.exe: cannot find crtend.o: No such file or directory
collect2.exe: error: ld returned 1 exit status
mingw32-make[1]: *** [CMakeFiles\cmTC_610d2.dir\build.make:100: cmTC_610d2.exe] Error 1
mingw32-make[1]: Leaving directory 'D:/IGCA/Commander/src_cpp/Build/CMakeFiles/CMakeTmp'
mingw32-make: *** [Makefile:126: cmTC_610d2/fast] Error 2
CMake will not be able to correctly generate this project.
Call Stack (most recent call first):
CMakeLists.txt:3 (project)
-- Configuring incomplete, errors occurred!
See also "D:/IGCA/Commander/src_cpp/Build/CMakeFiles/CMakeOutput.log".
See also "D:/IGCA/Commander/src_cpp/Build/CMakeFiles/CMakeError.log".
mingw32-make: *** No targets specified and no makefile found. Stop.
mingw32-make: *** No rule to make target 'install'. Stop.