I didn't remember how I created it, so I created a new one as a copy of Cygwin GCC. I get the same problem.
How does Code::Blocks know that it needs to execute things under Cygwin, and how does it run them? Should I see Cygwin invoked in the build log?