1 | | = MinGW Troubleshooting = |
| 1 | = MinGW Troubleshooting Q&A = |
| 2 | |
| 3 | === Q: My MSYS window is black / can't be resized to fullscreen === |
| 4 | |
| 5 | A: You're using the wrong shortcut to open MSYS. See the note at the bottom of [wiki:WindowsMinGW/current#MSYS the "MSYS" section in the installation guide]. |
| 6 | |
| 7 | === Q: When I use the "cm" (or "cmake") command, I get an error === |
| 8 | |
| 9 | There are multiple errors with multiple reasons. Sometimes this can be solved by closing (all instances of) MSYS and/or rebooting Windows. If this doesn't help, compare your error message to the examples below: |
| 10 | |
| 11 | A1. "cm" alias is not defined: |
| 12 | {{{ |
| 13 | sh: cm: command not found |
| 14 | }}} |
| 15 | If your error looks like this, you have to define the "cm" alias as explained here: [wiki:WindowsMinGW/current#BuildOrxonox]. |
| 16 | |
| 17 | A2: MinGW not installed properly / MSYS not correctly configured |
| 18 | {{{ |
| 19 | $ cm |
| 20 | -- The C compiler identification is unknown |
| 21 | -- The CXX compiler identification is unknown |
| 22 | -- Check for working C compiler: /mingw/bin/gcc.exe |
| 23 | -- Check for working C compiler: /mingw/bin/gcc.exe -- broken |
| 24 | CMake Error at C:/Program Files/CMake 2.8/share/cmake-2.8/Modules/CMakeTestCCompiler.cmake:52 (MESSAGE): |
| 25 | The C compiler "/mingw/bin/gcc.exe" is not able to compile a simple test |
| 26 | program. |
| 27 | |
| 28 | ... |
| 29 | }}} |
| 30 | If CMake prints an error like this (and about 30 more lines), the GCC compiler was not found. Make sure you installed MinGW and MSYS properly by following [wiki:WindowsMinGW/current the guide]. You can also open the file {{{c:\<msys-install-path>\etc\fstab}}} with a text-editor (WordPad, Notepad) and check if the path to MinGW is configured correctly (default is {{{c:/mingw /mingw}}}). |
| 31 | |
| 32 | A3: g++ is not installed |
| 33 | {{{ |
| 34 | $ cm |
| 35 | -- The C compiler identification is GNU |
| 36 | -- The CXX compiler identification is unknown |
| 37 | -- Check for working C compiler: C:/MinGW/bin/gcc.exe |
| 38 | -- Check for working C compiler: C:/MinGW/bin/gcc.exe -- works |
| 39 | -- Detecting C compiler ABI info |
| 40 | -- Detecting C compiler ABI info - done |
| 41 | -- Check for working CXX compiler: g++.exe |
| 42 | CMake Error at C:/Program Files/CMake 2.8/share/cmake-2.8/Modules/Platform/Windows-g++.cmake:1 (INCLUDE): |
| 43 | include could not find load file: |
| 44 | |
| 45 | ... |
| 46 | }}} |
| 47 | If CMake prints an error like this (and about 20 more lines), you probably missed to install g++ with MinGW. Please refer to [wiki:WindowsMinGW/current#MinGW the installation guide] and ensure you selected "C++ Compiler" in the installation menu of MinGW. |