G++ 5.2.0 on Windows using MinGW and Code::Blocks

Teacher Don's picture

Recently I've been frustrated by the lack of availability of regex on the GCC compilers on Windows. I don't want to pull in the full Cygwin support. However MinGW support for GCC seems to have stopped at G++ 4.8, just short of regex support.

Although I really wanted the official MinGW.org website to have the newest build, I instead finally had to resort to 3rd party releases. Stephan T. Lavavej's personal website, http://nuwen.net/, has been releasing updated G++ for MinGW since 2010, and now has the newest available G++ 5.2.0 on Windows.

Integrating it with Code::Blocks IDE was a little bit of work, since Code::Blocks expects all the executable names to be prefixed with mingw-. Once the prefixes were removed, the new setup works like a charm.

Hope that helps someone!