Chapter 2. Requirements

You will need Qt Designer and KDevelop for this tutorial, as well as the KDE 3.2.x libraries installed. We will build a simple KDE3 program that takes a name, an email address and a comment and generates a signature for an email.

How to get Qt Designer

From your distribution

Qt Designer is part of the qt-3.2.x package and above. If you have an older Qt on your system, you should get at least this version. At the time of writing, Qt latest version is 3.3.2.

Please remember to check if you have all the qt-related packages installed. You need the qt headers in order to compile this tutorial application. These headers usually come in the devel package. You also need to be sure you have designer. In some distributions, it comes in a separate package.

To check if you have everything, do a

locate qstring.h

If you get something like /usr/lib/qt3/include/qstring.h then you can set your QTDIR variable to /usr/lib/qt3/. In bash environment, this is done by typing

export QTDIR= /usr/lib/qt3

Tarball or anonymous cvs

You can download the tarball from the Trolltech website or also get the qt-copy module from cvs. Please note that Qt for Linux is GPL.

For an explanation for how to use anonymous cvs, get the qt-copy and kde modules and compile them, please see a great documentation here.

You must then set the QTDIR environment variable. This should point to the directory into which you installed Qt. In bash, for example, you would type:

export QTDIR= /usr/local/qt

provided that /usr/local/qt is the directory into which you installed Qt. Please read the INSTALL file for more details.

You then compile by issuing the following commands, here is the recommended compile line:



./configure -system-zlib -qt-gif -system-libpng -system-libjpeg \
  -plugin-imgfmt-mng -thread -no-exceptions -debug -fast
 make


The command make install is not needed.

Qt Designer is located in the bin directory of your Qt installation directory. You can run it by typing

/usr/local/qt/bin/designer

in a console.

Please see here for a detailed explanation of how to compile Qt from a tarball.