I have mentioned this in my earlier comment. Personally I use standalone MinGW-W64 installation and use a batch file that it shipped together which set the env-vars as necessary before launching a CMD shell. We have received reports from our users before that they have better success with standalone MinGW installation, especially MinGW-W64, The TDM-GCC compiler toolchain provided by C::B has been known to cause problems to our users, although I have not verified that personally. And to do that you have to adjust the environment variable(s), usually it is just PATH env-var, correctly for the selected compiler toolchain. Basically what you need to ensure is to let CMake able to find the compiler toolchain that you want to use whether it is MinGW, MSVC, or any others. You do not need to uninstall VS from your host system. if you get problem on one then you will get problem on the other. Whether CLI or GUI, they are just the same, i.e. Our convenient batch file simply invokes cmake (CLI) to do the actual work.
#Codeblocks mingw windows#
With the assumption that there are nothing wrong with our CMake scripts, the root cause of your problem is still within your Windows host system. Or corrupt [D:\Resources\M圜ode\Urho\Urho3D-1.5\Urho3D-1.5-Win32\mingw_sysroot\CĬMake will not be able to correctly generate this project. [D:\Resources\M圜ode\Urho\Urho3D-1.5\Urho3D-1.5-Win32\mingw_sysroot\CMakeFiles LINK : fatal error LNK1123: failure during conversion to COFF: file invalid Ysroot/CMakeFiles/CMakeTmp/Debug/cmTC_996ce.lib" /MACHINE:X86 cmTC_996ce.dir\DebĬmTC_996ce.dir\Debug\testCCompiler.obj /machine:X86 /debug " /MANIFESTUAC:"level='asInvoker' uiAccess='false'" /DĮBUG /PDB:"D:/Resources/M圜ode/Urho/Urho3D-1.5/Urho3D-1.5-Win32/mingw_sysroot/CMĪkeFiles/CMakeTmp/Debug/cmTC_996ce.pdb" /SUBSYSTEM:CONSOLE /TLBID:1 /DYNAMICBASE Mdlg32.lib advapi32.lib /MANIFEST /ManifestFile:"cmTC_996ce.dir\Debug\cmTC_996ce User32.lib gdi32.lib winspool.lib shell32.lib ole32.lib oleaut32.lib uuid.lib co Oot\CMakeFiles\CMakeTmp\Debug\cmTC_996ce.exe" /INCREMENTAL /NOLOGO kernel32.lib MTC_996ce.dir\Debug\cmTC_.res" cmTC_996ce.dir\Debug\cmTCĬ:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\bin\link.exe /ERRORRE TDIR=\"Debug\"" /D _MBCS /Gm- /RTC1 /MDd /GS /fp:precise /Zc:wchar_t /Zc:forScopĮ /Fo"cmTC_996ce.dir\Debug\\" /Fd"cmTC_996ce.dir\Debug\vc100.pdb" /Gd /TC /analyĬ:\Program Files (x86)\Microsoft SDKs\Windows\v7.0A\bin\rc.exe /nologo /fo"c Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 9.01 for 80Ĭl /c /Zi /W3 /WX- /Od /Ob0 /Oy- /D WIN32 /D _WINDOWS /D _DEBUG /D "CMAKE_IN WX- /Od /Ob0 /Oy- /D WIN32 /D _WINDOWS /D _DEBUG /D "CMAKE_INTDIR=\"Debug\"" /ĭ _MBCS /Gm- /RTC1 /MDd /GS /fp:precise /Zc:wchar_t /Zc:forScope /Fo"cmTC_996ce.ĭir\Debug\\" /Fd"cmTC_996ce.dir\Debug\vc100.pdb" /Gd /TC /analyze- /errorReport: See also "D:/Resources/M圜ode/Urho/Urho3D-1.5/Urho3D-1.5-Win32/mingw_sysroot/CMaĬreating directory "D:\Resources\M圜ode\Urho\Urho3D-1.5\Urho3D-1.5-Win32\mingĬreating "cmTC_996ce.dir\Debug\cmTC_996ce.unsuccessfulbuild" because "AlwaysĬ:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\bin\CL.exe /c /Zi /W3 Configuring incomplete, errors occurred! "D:\Resources\M圜ode\Urho\Urho3D-1.5\Urho3D-1.5-Win32\mingw_sysroot\CMakeFilesĬreating directory "cmTC_996ce.dir\Debug\". Microsoft (R) Build Engine version 9.17929Ĭopyright (C) Microsoft Corporation. "cmTC_996ce.vcxproj" "/p:Configuration=Debug" "/p:VisualStudioVersion=10.0" The C compiler "C:/Program Files (x86)/Microsoft Visual Studioġ0.0/VC/bin/cl.exe" is not able to compile a simple test program.Ĭhange Dir: D:/Resources/M圜ode/Urho/Urho3D-1.5/Urho3D-1.5-Win32/mingw_sysrooĬommand:"C:/Windows/Microsoft.NET/Framework/v9/MSBuild.exe" Check for working C compiler using: Visual Stu- brokenĬMake Error at C:/Program Files (x86)/CMake/share/cmake-3.4/Modules/CMakeTestCCo Check for working C compiler using: Visual Studio 10 2010 The CXX compiler identification is MSVC 9.1
The C compiler identification is MSVC 9.1 Sysroot="C:\Program Files (x86)\CodeBlocks\MinGW\bin" D:\Resources\M圜ode\Urho\Urho3D-1.5\Urho3D-1.5-Win32>cmake_codeblocks.bat mingw_