1.5. Obtaining and Installing KDE

You can always find the latest KDE source code and binaries at ftp://ftp.kde.org or one of the more than 100 mirrors (see http://www.kde.org/mirrors.html for a list of mirrors; you are encouraged to use a mirror site located near you.) Additionally, the support Web site for this book, http://www.samspublishing.com, contains links to source code and binaries.

To install KDE 2.0 for development, you will need, at minimum, the following packages:

  • qt-2.1.0—The Qt toolkit library

  • kdesupport—Libraries not developed by the KDE project, but needed to run KDE applications

  • kdelibs—The KDE libraries

Be sure to install these packages first and in the order given. The other packages are optional.

For a working desktop, you will also need

  • kdebase—The window manager (KWin), file manager (Konqueror), panel (Kicker), and other programs needed to create a working desktop

More KDE applications can be found in

  • kdeutils—KDE utility programs such as kedit—a text editor, and kcalc—a calculator

  • kdegraphics—Utility programs for viewing image, Postscript, and PDF file and for simple manipulating of bitmapped graphics

  • kdenetwork—KDE networking utilities, such as kppp, an Internet dial-up tool

  • kdegames—Some games for KDE, such as solitaire and mah-jongg

  • kdemultimedia—Players for audio and video files

  • kdeadmin—KDE administration tools, such as a user information editor (kuser) and tools for installing and removing Red Hat and Debian packages (.rpm and .deb)

  • kdei18n—Internationalization information for non-English installations

1.5.1. Installing Binary Packages

On systems that use the Red Hat package manager, you should install each package using the command

   2 rpm -Uvh packagename.rpm

Some RPM-based distributions are Red Hat, SuSE, and Caldera.

Users of the Debian distribution (or a Debian-based distribution, such as Corel Linux) can install packages with

   2 dkpg -install packagename.deb

Some binary TAR archive binary packages are also available. They should be installed according to the accompanying documentation.

1.5.2. Installing Source Packages

You may also compile Qt/KDE packages from their source code and install them on your system. All the packages work the following way: first, you need to unpack the package with

   2 gzip -d packagename.tar.gz
   3 tar -xvf packagename.tar.gz

This creates a new subdirectory in your current directory called packagename.

Next, to compile the source code for installation in the default locations, type

   2 cd packagename
   3 ./configure
   4 make

The default locations generally require root (superuser) access to the machine on which the code is being installed. You may choose to install in an alternative location by passing the option —prefix=newlocation to the configure script. For example, I install my Qt and KDE packages in $HOME/KDE/HEAD, so I use

   2 cd packagename
   3 ./configure —prefix=$HOME/KDE/HEAD/qt
   4 make

when building the Qt library, and

   2 cd packagename
   3 ./configure —prefix=$HOME/KDE/HEAD/kde —with-qt-dir=$HOME/KDE/HEAD/qt
   4 make

when building the KDE library.

To install the compiled code, type

   2 make install

You will need to have write permission for the directories in which you have chosen to install Qt/KDE when entering this command. For example, you will (typically) need to log in as root before typing make install to install in the default locations.