【发布时间】:2016-06-24 23:32:06
【问题描述】:
尝试为我正在编写的 c++ 游戏构建一些有用的库。但是 CMAKE 不想使用我的编译器?
我正在运行 OS Windows 7,尝试为 Windows 32 构建库。我正在运行最新版本的 CMAKE(32 位(64 位也不行))我的编译器是 Codeblocks MinGW 编译器,应该基于 32 位。
这是错误日志:
Compiling the C compiler identification source file "CMakeCCompilerId.c" failed.
Compiler: C:/Program Files (x86)/CodeBlocks/MinGW/bin/gcc.exe
Build flags:
Id flags:
The output was:
1
Compiling the C compiler identification source file "CMakeCCompilerId.c" failed.
Compiler: C:/Program Files (x86)/CodeBlocks/MinGW/bin/gcc.exe
Build flags:
Id flags: -c
The output was:
1
Compiling the C compiler identification source file "CMakeCCompilerId.c" failed.
Compiler: C:/Program Files (x86)/CodeBlocks/MinGW/bin/gcc.exe
Build flags:
Id flags: -Aa
The output was:
1
<command-line>:0:1: error: missing '(' after predicate
Compiling the C compiler identification source file "CMakeCCompilerId.c" failed.
Compiler: C:/Program Files (x86)/CodeBlocks/MinGW/bin/gcc.exe
Build flags:
Id flags: -D__CLASSIC_C__
The output was:
1
Checking whether the C compiler is IAR using "" did not match "IAR .+ Compiler":
gcc.exe: fatal error: no input files
compilation terminated.
Compiling the CXX compiler identification source file "CMakeCXXCompilerId.cpp" failed.
Compiler: C:/Program Files (x86)/CodeBlocks/MinGW/bin/g++.exe
Build flags:
Id flags:
The output was:
1
Compiling the CXX compiler identification source file "CMakeCXXCompilerId.cpp" failed.
Compiler: C:/Program Files (x86)/CodeBlocks/MinGW/bin/g++.exe
Build flags:
Id flags: -c
The output was:
1
Checking whether the CXX compiler is IAR using "" did not match "IAR .+ Compiler":
g++.exe: fatal error: no input files
compilation terminated.
Determining if the C compiler works failed with the following output:
Change Dir: C:/Program Files (x86)/TGUI/TGUI-Build/CMakeFiles/CMakeTmp
Run Build Command:"C:/PROGRA~2/CODEBL~1/MinGW/bin/mingw32-make.exe" "cmTC_9275e/fast"
C:/PROGRA~2/CODEBL~1/MinGW/bin/mingw32-make.exe -f CMakeFiles\cmTC_9275e.dir\build.make CMakeFiles/cmTC_9275e.dir/build
mingw32-make.exe[1]: Entering directory 'C:/Program Files (x86)/TGUI/TGUI-Build/CMakeFiles/CMakeTmp'
Building C object CMakeFiles/cmTC_9275e.dir/testCCompiler.c.obj
C:\PROGRA~2\CODEBL~1\MinGW\bin\gcc.exe -o CMakeFiles\cmTC_9275e.dir\testCCompiler.c.obj -c "C:\Program Files (x86)\TGUI\TGUI-Build\CMakeFiles\CMakeTmp\testCCompiler.c"
CMakeFiles\cmTC_9275e.dir\build.make:64: recipe for target 'CMakeFiles/cmTC_9275e.dir/testCCompiler.c.obj' failed
mingw32-make.exe[1]: *** [CMakeFiles/cmTC_9275e.dir/testCCompiler.c.obj] Error 1
mingw32-make.exe[1]: Leaving directory 'C:/Program Files (x86)/TGUI/TGUI-Build/CMakeFiles/CMakeTmp'
Makefile:125: recipe for target 'cmTC_9275e/fast' failed
mingw32-make.exe: *** [cmTC_9275e/fast] Error 2
【问题讨论】:
-
标题 (
Could not locate libintl-8.dll) 与问题(错误日志)有何关联? -
@Tsyvarev 当我按“配置”并选择代码块 mingw 编译器(使用默认的本机编译器)时,我得到这个:i.imgur.com/54baAPs.png
标签: cmake mingw codeblocks