User forums > Using Code::Blocks

Using Qt4 with Code::Blocks (QtNetwork, QTcpClient, ... etc)

(1/1)

YoSarin:
Hello,
i have a small problem with compiling an application which uses libs QtNetwork, QTcpClient, ... etc. In source code is standard include:
#include <QtNetwork>
During compilation there is allways error message like this:

QtNetwork: No such file or directory

At Qt forums is solution - add line QT += network into *.pro file. Well, i done this, after that i have succesfully compiled program:
$ qmake
$ make
Voilá! Succes. But in Code::Blocks i am unable to compile it succesfully. Even if in project/Build options.../pre-build steps is qmake written. Still gets the same error.

Thanks for each advice.

And apologize my english please, i'm not used to use it. :)

yop:
Qt is not supported with the out of the box installation of C::B. Try using a custom Makefile or the QtWorkbench plugin.

YoSarin:
Thanks for answer. Just trying QT Workbench, seems it working.

Z.K.:
I do not know if this is your problem or not, but I had a similar problem which I finally narrowed down to my being on a power user account in windows XP. Even if permissions and securities of the folder are set to full access for the power user, it still fails to compile and I get errors similar to what you are getting; it can not see the QT files.   :) 

Navigation

[0] Message Index

Go to full version