Trying to Build/Compile for the first time - X error
MandrivaThis Forum is for the discussion of Mandriva (Mandrake) Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Trying to Build/Compile for the first time - Qt error
Hi folks, trying to compile and install programs for the first time without using rpms...
Succesfully untar'd a package and then ran ./configure - intially it immediately exited with the error that it couldn't find an acceptable C compiler in the path. Searched around and found that the GCC libs weren't installed (bit annoying in itself - you would think these would be installed as part of the initial build of Mandrake 9.1 given how fundamental they are!). Anyway, rpm'd the GCC libs (they installed successfully) and was then able to run the ./configure command.
I now get a couple of screens of commands running past very fast and then it exits on the following error:
"Checking for X... configure: error: can't find X includes - please check your installation and add the correct paths!"
Well, thanks so much for the exclamation mark Linux, very informative - GRRRR
Anyone know what on earth I'm doing wrong? I really would like to be able to untar/configure/make/install my first program - it's a hurdle I have to jump if I'm going to really get into Linux....
Any advice greatly appreciated
Pete aka puppy
"Sometimes I want to hug penguins, sometimes I could cheerfully garotte them!"
You would think that you could compile a program out of the box. However this isn't always the case. Mandrake does not assume you are a developer, or even a compiler, unless you tell it on installation and install the many needed ???-devel-??? rpm packages.
It sounds like you installed Mandrake as a user and it does not have the needed development packages. I expect the above error is because you do not have xfree86-devel packages installed. Run rpmdrake and search for "devel" packages. You will end up with too many to count probably. Install the ones for the xwindows environment. If there are others needed the configure script will tell you next time you run it.
I know this is a pain, but without installing the development option when you installed Mandrake you need to go back and provided the needed header files and linking libraries.
If you have more questions please post them. I am sure we can get you compiling with few problems!!
Installed the Xfree86 development libs by rpm and the configuration got a bit further before exiting with another error - install needed libjpeg & Qt libs
Installed jpeg libs and Qt3.1.2.9 libs by rpm - it went past libjpeg with no probs but came back with the same error as last time again:
"checking for Qt... configure: error: Qt (>= Qt 3.0.3) (library qt-mt) not found. Please check your installation!
For more details about this problem, look at the end of config.log.
Make sure you have compiled Qt with thread support!"
Anyway I am now stumped - I HAVE INSTALLED the Qt libraries
I have had this probelm before as well. Some of the time it is because the libraries have been installed, but the configure program has not been updated to know where to look. If this doesn't solve it post back. I will have to think of another reason why it didn't see them.
Nope - tried that and it went away for a few secs and then the cursor came back (no message) - tried to ./configure again and get the same error message as before
Great start isn't it :-( and this is only my first attempt
The first ones are always the fun ones. Don't give up. I promise this is doable! For some background, what programs are you trying to compile?
I know I will get yelled at for this, but try restarting your computer and trying the ./configure again. Linux doesn't need to be restarted after adding programs and libraries, but to be honest. I don't know where all the places are to update after some installations and rebooting seems to work.
Outside of this make sure you have all the devel packages for qt installed. There are often several. It looks like these programs complained about the qt-mt lib. This is the qt libraries with multi-thread support. Double check that the qt rpms you installed were for qt-mt. I don't use qt much at all so I am looking up information on this as we go.
From what I can tell at rpmfind.net, libqt3-3.1.1-13 and libqt3-3.1.2-14 both provide libqt-mt.so.3. I would expect you version libpt3-3.1.2-9 would too. You may want to make sure it does.
After that it may be worth searching for and passing the path to the ./configure script as follows:
3129-kfiresaver3d-0.6.tar.gz (an opengl screensaver)
and
6304-alloy-0.4.1a.tar.gz (a KDE theme)
Couldn't work out whether the Qt libs I have offer multithread support but the version I have downloaded via rpm (as above) is the latest version available under the standard Mandrake 9.1 rpms (I don't use cooker sources)
I've tried all the things suggested - basically if I can't build programs there's no point is there - I'm not installing Mandrake again cos that will be the 5th time in a month since I first installed it - should I post my problems in the programming section?? I'm getting desperate...
Sorry puppy, work has been busy. I am not sure what to tell you. I don't use KDE or QT so I haven't had to work through multithreading. It should be doable without this much trouble. I wouldn't suggest even thinking about reinstalling just yet. However, I am not sure what else to suggest to you.
I may be worth looking at some qt message boards. I found this below at comp.windows.x.kde (newsgroup). You can search through these on Google. There is a lot of people with this problem so you might find some other useful information. I don't know if it will do anything, but it is worth a check.
Code:
if test -z ""; then
if test $kde_qtver = 3; then
kde_qt_verstring="QT_VERSION >= 303"
fi
The one version that did not worked had a 0x3000 instead
of 303 or something like that. I don't know if this helps.
I will keep looking to and see what I can come up with. It may be worth checking your configure script for the above. Also double check that the /usr/lib/qt3/lib dir has the libqt-mt.so.? file.
One other thing, there is a $QTDIR environment variable that should point to /usr/lib/qt3/. check to see if it is with the following.
Code:
echo $QTDIR
If it isn't set it with
Code:
export QTDIR=/usr/lib/qt3
I will post back if I find something else.
If anyone else on this board has ideas please share!
That line of code is present in the config file. I also did an $echo and sure enough it didn't come back with anything - I did the following command that you suggested and then when I $echo'd it came back with the right directory, but guess what.... I still get the same error when I try to ./configure
I also checked the directory and the /lib folder has the file libqt-mt.so. where its supposed to be.
So... I'm out of options and can't build programs in Linux... :-(
I've spent hours and hours over four tortuous weeks trying to get Linux to run properly, get all my hardware configured etc to come up against this. I can't face re-installing the o/s again - can anyone else shed any light?
This may not help much but the problem isn't compiling in linux, but compiling for KDE. In several of the posts I read the people downloaded the source for qt and compiled it themself with the -thread option. I realize that the Mandrake rpm should already support this but I am not sure what else there is. So if noone else has ideas my last resort would be to compile the qt libraries yourself instead of using the rpms. I am sure there has to be an easier fix, I just don't know what it is. Did you try looking at some of the other posts on the newsgroup? You can use google to search the groups. I found a lot of try this, but everyone seemed to have a different sollution.
Sorry puppy, I am out of ideas. If I see anything else I will pass it along. If you want to practice compiling something you could always try a GTK app. They won't depend on the qt libraries but you will need to install the gtk+-devel packages. Granted, this doesn't help you much since you are using KDE.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.