How to build RT on Windows?

The -mwindows flag is your friend

Edit : perhaps you are doing a debug build? If you specify a release build there should not be a console window.