I have downloaded CodeBlocks 17.02 without mingw and installed it, then I downloaded MinGW64 from here(https://mingw-w64.org/doku.php/download) and only changed the architecture option from i686
to x86_64
during the installation and left the rest as default. Then tried to add this path to system paths: C:\Program Files\mingw-w64\x86_64-8.1.0-posix-seh-rt_v6-rev0\mingw64\x86_64-w64-mingw32\bin
. But when I opened the CodeBlocks, it couldn't find the compiler. Also when I go to settings>compiler
and try to set GNU GCC compiler
it says: can not find the compiler!
How should I specify the MinGW64 for CodeBlocks om Windows 10?
Answer
Here I explain the procedure with the ZIP files which does not requires administrator privilege or a setup.exe, just extract those with any decompression tool. This procedure is focused on C/C++. These settings may vary in other languages. The required links will be in last section.
Download Code::Blocks and mingw-w64 from it's download page, the file name will be like 'codeblocks-17.12-nosetup.zip' and 'x86_64-8.1.0-release-posix-seh-rt_v6-rev0.7z' respectively. The mingw-w64 file may be with seh or sjlj Extract those in any drive or any folder with 7zip. For example, here I choose
E:\CodeBlocks
andE:\mingw64
.Open CodeBlocks.exe from that extraction folder. There will be a warning like 'No compiler found'. Go to Settings > Compiler > Global Compiler Settings > Toolchain executables > Compiler's Installation Directory. Make sure GCC is default compiler. Choose the extraction folder of mingw-w64 (here
E:\mingw64
). Then select the compiler, linker, make programs one-by-one. The window will look like this screenshot:
Now it is ready to go. These configurations are saved in "%AppData%\CodeBlocks\default.conf` file.
Links:
CodeBlocks:
mingw-w64:
Comments
Post a Comment