Method 1: Install from the precise repository
This method is easier and faster, but it may not work for newer versions of Ubuntu. You will need to add the precise repository, which contains packages for Ubuntu 12.04 LTS, to your sources list. Then you can install the qt3-dev-tools package, which includes the Qt3 runtime library and other development tools. Here are the steps:
Open a terminal and enter the following command to add the precise repository:
echo "deb [4](http://archive.ubuntu.com/ubuntu) precise main universe multiverse" sudo tee /etc/apt/sources.list.d/precise.list
Update your package lists with this command:
sudo apt-get update
Install the qt3-dev-tools package with this command:
sudo apt-get install qt3-dev-tools
Remove the precise repository from your sources list with this command:
sudo rm /etc/apt/sources.list.d/precise.list
Update your package lists again with this command:
sudo apt-get update
You should now have the Qt3 runtime library installed on your system. You can verify it by running this command:
ldconfig -p grep libqt
You should see something like this:
libqt-mt.so.3 (libc6,x86-64) => /usr/lib/x86_64-linux-gnu/libqt-mt.so.3
libqt-mt.so (libc6,x86-64) => /usr/lib/x86_64-linux-gnu/libqt-mt.so
libqt.so.3 (libc6,x86-64) => /usr/lib/x86_64-linux-gnu/libqt.so.3
libqt.so (libc6,x86-64) => /usr/lib/x86_64-linux-gnu/libqt.so
Method 2: Install from source
This method is more complicated and time-consuming, but it may work for newer versions of Ubuntu. You will need to download the source code of Qt3 and compile it yourself. Here are the steps:
Download the source code of Qt3 from [here] and save it in your home directory.
Extract the tarball with this command:
tar xvf PyQt3Support-PyQt4.4.4-gpl-r4.tar.gz
Change to the extracted directory with this command:
cd PyQt3Support-PyQt4.4.4-gpl-r4/qt-x11-free-3.3.8b
Configure the source code with this command:
./configure -thread -prefix /usr/local/qt -no-stl -no-xft -no-exceptions -no-opengl -no-sql-sqlite -no-sql-mysql -no-sql-odbc -no-sql-psql -no-sql-ibase -no-cups -no-nis -no-gif -no-libmng -no-libjpeg -no-libpng -no-zlib -system-libpng -system-zlib -system-libjpeg
This will disable some features that are not needed for the Qt3 runtime library.
Compile the source code with this command:
make
This may take a long time depending on your system.
Install the compiled library with this command:
sudo make install
You should now have the Qt3 runtime library installed on your system. You can verify it by running this command:
/usr/local/qt/bin/qmake -v
You should see something like this:
QMake version 2.01a
Using Qt version 3.3.8b in /usr/local/qt/lib
Conclusion
In this article, we have shown you how to install the Qt3 runtime library on Ubuntu using two methods: from the precise repository and from source. You can use either method depending on your preference and compatibility. The Qt3 runtime library is required for some programs that were developed with Qt3, such as the driver for the ZTE MF180S USB modem. We hope this article was helpful for you.
References:
: [How to Install QT3 Runtime Library? - Ask Ubuntu]
: [How to install qt3-dev-tools package - Ask Ubuntu]
: [Install Qt Creator on Linux - Stanford University]
: [Ubuntu â Details of package qt3-dev-tools in precise](https://packages.ubuntu.com/precise/qt3-dev-tools)
: [PyQt3Support-PyQt4.4.4-gpl-r4.tar.gz](https://www.develer.com/naufraghi/PyQt3Support/PyQt3Support-PyQt4.4.4-gpl-r4.tar.gz)
a104e7fe7e