I I've used Codeblocks up to 1.0 beta 7 and then stuck to that version. Now I downloaded the RC 1-1 and wow!!! support for qt 4 open source edition. Since you see the post in this thread you realize that I have the same problems.
1 - Go to QT app properties and check the "this is a custom makefile" checkbox.
Now click on project's build options button, select the default brach at left and, in commands area, type the following into pre-build-steps:
qmake -project
qmake
2 - Make sure you have selected "invoke compiler directly" as the build method in settings->compiler->other.
3 - Compile the project; if you have includes of type "#include <QtGui>" those won't be found, returning errors. The makefile is now created.
4 - Change again the build method, now it must be "Work with makefiles" and try to compile again; it must work now.
I have solved the above issue by creating two tool entries in code blocks:
First:Name : generate .pro file
Executable: C:\Qt\4.0.0\bin\qmake.exe (note must be full path)
Parameters: -project
Working Directory: ${PROJECT_DIR}
Second:Same as above changing parameters field to -makefile and name to generate makefile.
The build method, should be "Work with makefiles" and in QT app properties the "this is a custom makefile" checkbox should be checked as quoted above. When you first build your project you should run the tools once (first the generate .pro file then generate makefile) and work as usual, you will only need to run the tools again if you for instance add new files etc.
The thing now is that doing the above we totally override CodeBlocks (we just use it as a fancy editor) and its a pity not being able to take advantage of all the features it provides.
Compiler can’t find “#include <QtGui>” because it can’t find standard path to included file. In my case Qt Application set path “$QTDIR/include/Qt/QtGui” (look at Project->Build Option -/ Directories -/ Compiler) and the real path was “$QTDIR/include/QtGui”. And so for all.
The REAL problem is a linking.
Qt uses *.moc files, but how can I tell compiler to generate them, compile and link? 
All hopes is to use Makefiles.
e-axis you are 100% right. Firstly to the code::blocks team this problem with the folders should be looked into. Secondly qt generates "intermediate" files source files using the moc (meta object compiler). And if you are looking for the real qt experience you must also use the designer thus support .ui files etc. etc. I am navigating through the options I am given and I'll get back to you. In the mean time I will email to the qt mailing list I' m subscribed to, to suggest this beautiful IDE, believe it or not it's the only one to support Qt open source edition.
I will get back with this issue, as this IDE is a neccessesity to me...