Using qt3 with Kdevelop.

Code junkies hangout here

Moderators: ChrisThornett, LXF moderators

Using qt3 with Kdevelop.

Postby GMorgan » Mon Mar 13, 2006 8:12 pm

I've been trying to get qt3 to work with Kdevelop in Kubuntu. I've downloaded and installed the qt-x11-free-3.3.5.tar.gz file from the trolltech site but Kdevelop still doesn't find the headers qapplication.h and qlabel.h. Anyone know how to get it running.
GMorgan
LXF regular
 
Posts: 684
Joined: Thu Jan 12, 2006 6:58 pm
Location: South Wales, UK

Postby wiz » Mon Mar 13, 2006 10:17 pm

Try using Adept to download the matching kubuntu Qt & kdevelop packages.

Installing from a Qt tar.gz will put the header files & libraries in odd places and will require an enormous amount of faffing about symlinking everything here & there. I tried to do this myself (once).
wiz
LXF regular
 
Posts: 119
Joined: Thu Apr 07, 2005 6:20 pm
Location: In front of a computer

Postby thoughtpolice » Fri Mar 17, 2006 8:01 pm

I've also got something that may be similar to your issue

I'm coming from bloodshed's dev c++ and a bit confused here, when trying to run a hello world, I'm getting a message that there is no makefile and configure script - what is this?

and then after running ./configure I have this error message
checking for Qt... configure: error: Qt (>= Qt 3.2) (library qt-mt) not found. Please check your installation!

are these hand in hand?
thoughtpolice
 
Posts: 13
Joined: Thu Mar 16, 2006 7:49 pm
Location: Raleigh, North Carolina

Postby thoughtpolice » Fri Mar 17, 2006 8:02 pm

let me make sense of that,

I WAS on bloodshed and now I'm trying to work in kdevelop ;)
thoughtpolice
 
Posts: 13
Joined: Thu Mar 16, 2006 7:49 pm
Location: Raleigh, North Carolina

Postby GMorgan » Fri Mar 17, 2006 9:09 pm

I've solved it now. You have to use the QMake command rather than standard c++ methods. When you create a KDevelop project select a QMake 'hello world' rather than a standard one. The will run the QMake command for you. The other posibility is to create a folder (say hello with main file hello.cpp) then cd to that

folder and run qmake -project
then qmake hello.pro
finally make.

Obviously this is dependant on the correct tools being installed.

My problem was I just assumed that Qt uses standard C++ headers and could compile directly on a normal compiler. You have to run QMake first.

How you get it working in Dev-CPP I don't know.
GMorgan
LXF regular
 
Posts: 684
Joined: Thu Jan 12, 2006 6:58 pm
Location: South Wales, UK

Postby thoughtpolice » Sat Mar 18, 2006 1:21 am

I'm still wrestling with my above problem, and when I run, I get a message that there is no makefile, but I've quadruple checked, there's 3 makefiles upon opening the directory.

:?
thoughtpolice
 
Posts: 13
Joined: Thu Mar 16, 2006 7:49 pm
Location: Raleigh, North Carolina

Postby GMorgan » Sat Mar 18, 2006 9:29 pm

Three makefiles :? there should only be one at most. What happens when you try to run qmake -project. Remember that the folder the source is in should have the same name as the main source file. If you wrote the code using KDevelop there should be a src directory within the project folder. The source files would be in there. Copy them into a directory with the same name as the main source file then run qmake as I described above.

Make sure you run the qmake -main.pro step where main is the name of the folder the source is in. This will develop a Makefile you can then compile with make.
GMorgan
LXF regular
 
Posts: 684
Joined: Thu Jan 12, 2006 6:58 pm
Location: South Wales, UK

Postby thoughtpolice » Sun Mar 19, 2006 6:13 pm

I'll give it a go. Thanks
thoughtpolice
 
Posts: 13
Joined: Thu Mar 16, 2006 7:49 pm
Location: Raleigh, North Carolina


Return to Programming

Who is online

Users browsing this forum: Yahoo [Bot] and 0 guests

cron