Reputation: 517
I am new to Ubuntu and i am getting a message while building Qt 4.8.3 on Ubuntu 12:
Basic XLib functionality test failed! You might need to modify the include and library search paths by editing QMAKE_INCDIR_X11 and QMAKE_LIBDIR_X11 in /home/majidmax/qt-everywhere-opensource-src-4.8.3/mkspecs/linux-g++.
what the proper steps to build Qt on Ubuntu?
Upvotes: 7
Views: 11413
Reputation: 71
The error message doesn't give a lot of information as to the actual issue of XLib failing.
To get more information on the error causing it to fail you can 'make' the xlib tests:
$ cd <Qt_Source_Directory>/config.tests/x11/xlib/
$ make
g++ -Wl,-O1 -o xlib xlib.o -L/usr/X11R6/lib -ltcg -lXext -lX11 -lm
/usr/bin/ld: cannot find -ltcg
collect2: error: ld returned 1 exit status
make: *** [xlib] Error 1
In my case above, I was using -ltcg which was being interpreted as an explicit library to include. I was using this option as it is listed on the qt 4.8 configure options as:
Use Link Time Code Generation
When I looked at the configure options using ./configure --help
I noticed that this option isn't listed. Removing the option from my configure line fixed my issue.
Upvotes: 2
Reputation: 21
Same problem i faced in fedora20 (64-bit) for Qt-4.8.3
1)- yum install libXext-devel
(internet connectivity should be there for checking the dependency and install all dependency).
2)- ./configure
3)- make
4)- make install
5)- Installation finish successfully.
Upvotes: 1
Reputation: 11923
These are the packages you need to install and you'll be good to go. I just had this same problem and this worked for me. These came from the link provided by Garlic Tseng in the accepted answer. I am just putting these here for convenience:
libfontconfig1-dev
libfreetype6-dev
libx11-dev
libxcursor-dev
libxext-dev
libxfixes-dev
libxft-dev
libxi-dev
libxrandr-dev
libxrender-dev
One (copy pastable) command to install all:
sudo apt-get install libfontconfig1-dev libfreetype6-dev libx11-dev libxcursor-dev libxext-dev libxfixes-dev libxft-dev libxi-dev libxrandr-dev libxrender-dev
Upvotes: 8
Reputation: 7173
What about sudo apt-get build-dep qt4-qmake
?
Try to run that command before you compile Qt (on Debian-like distros).
Upvotes: 4
Reputation: 4858
what the proper steps to build Qt on Ubuntu?
Check the Qt supported Platforms.
Check Qt for X11 requirements.
3a. Check steps to install Qt on X11 platforms(along with build).
or
3b. Check steps to build static Qt.
Upvotes: 0
Reputation: 490
http://qt-project.org/doc/qt-4.8/requirements-x11.html
the website provide the package list which must be installed
try it~
Upvotes: 9