Ok, thanks.
It shouldn't be a big deal to modify compilers.dll, and I've added a new class using the tried & true 'copy something that already works and change the name' principle. This builds OK, but the resulting DLL doesn't work, because Code::Blocks can't load it. I get the standard 'One of more plugins were not loaded' message.
The build environment should be fine, which is to say that I can build a simple console Hello World using MinGW. A hex dump of my compilers.dll and the original shows that the headers are broadly similar, so it doesn't look like I'm building for the wrong target or anything like that. Is there some common mistake or other that people tend to make in these circumstances? I'm kind of stuck because I can't see any clue as to why compilers.dll can't be loaded.