Answer the question
In order to leave comments, you need to log in
How to build Qt 4.8.5 from source for Linux?
I wanted to build an old project under qt 4.8.5 for linux. But I can’t do it (I’ll explain what the problem is later). I would like to make a detailed instruction on how to do this - maybe not only me it will come in handy.
Installed system: Linux Mint 16 KDE x32.
Installed packages: build-essential
Also installed the SDK: Qt 5.2.1 for Linux 32bit
So I downloaded the qt 4.8.5 sources for Linux from the site .
I unpacked them using the Ark archiver.
Found a description of how to do it .
It describes 2 ways how to do it:
1) install to /usr
2) install to /opt/qt-4.8.5
The 2nd way is more suitable for me so that several different versions of qt can be installed on the computer.
First, I installed the necessary dependencies for building qt using the command in the terminal.
sudo apt-get install libfontconfig1-dev libfreetype6-dev libx11-dev libxcursor-dev libxext-dev libxfixes-dev libxft-dev libxi-dev libxrandr-dev libxrender-dev
sed -i -e "/#if/d" -e "/#error/d" -e "/#endif/d" \
config.tests/unix/libmng/libmng.cpp &&
sed -i '/CONFIG -/ a\isEmpty(OUTPUT_DIR): OUTPUT_DIR = ../..' \
src/3rdparty/webkit/Source/WebKit2/DerivedSources.pro &&
export QTDIR=/opt/qt-4.8.5
./configure -prefix $QTDIR -sysconfdir /etc/xdg -confirm-license -opensource -release -nomake demos -nomake examples -no-webkit
make
sudo make install
Answer the question
In order to leave comments, you need to log in
I faced the same problem . You can read the article on the link above, there is a very detailed instruction for building Qt 4.8.5
In short, the problem is that your desktop environment (KDE) uses Qt 4.8.4, and accordingly there is a conflict between the libraries. You can solve it like this:
1. Install the dbus-dev package:
2. Configure Qt with something like this command:
3. Rebuild.
If you need backend support for GStreamer (to work with audio / video) - do not forget to specify -glib -phonon -phonon-backend
and install the necessary headers when configuring.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question