<para>Don't worry! Although the use of some Beta software can cause considerable grief, it is unlikely that the installation of KDE will trash your hard disk. In fact, this chapter is designed to guide you through the installation process, so that you can take a look at your new desktop as quickly (and with as little grief) as possible. As with all new Window Manager installs, it is recommended that you back up all your X11-specific configuration files before you begin the install. If you do not know the exact location of them, try all the hidden (<filename>.*</filename>) files in your home folder and the folder <filename>/usr/X11/lib/X11/xdm</filename>. </para>
<listitem><para>A running POSIX compatible UNIX system. UNIX's that are known to work with KDE include: Linux, FreeBSD, Solaris, HP-UX, and MkLinux. We are working to make KDE available for more platforms soon. </para></listitem>
<listitem><para>Some free hard disk space on the partition where <filename>/opt/kde</filename> will be created. We recommend that you reserve about 50MB if your system supports shared libraries, and considerably more if it does not. If you need or want to build KDE from the source tree, please remember to reserve about 100MB in <filename>/usr/src</filename>.</para></listitem>
<listitem><para>A running X11 system with or without <application>xdm</application>. If you have not installed the X Window System yet, first check your UNIX installation media for an installable version. If you cannot find any version working, visit <ulink url="http://www.xfree86.org">the XFree86 web site</ulink> for more information on how to get and install the X Window System, or contact your UNIX vendor support. </para></listitem>
<listitem><para>The &Qt; libraries, version 3.2 or higher. You can obtain these at <ulink url="ftp://ftp.trolltech.com/qt">Troll Tech's FTP Server</ulink> in tgz format. </para>
<title>Linux: Installing RPMs for RedHat, Caldera and SuSE.</title>
<para>Using RPMs is the easiest method to get KDE up and running. Just visit your favourite KDE mirror and visit the folder <filename>/pub/kde/stable/distribution/rpm</filename>. There, you can see folders for different operating systems. Currently, the i386, alpha and sparc architectures are supported. The RPM packages can also be found on the Red Hat contrib sites like sunsite.unc.edu or ftp.redhat.com. </para>
<para>The basic system consists of the files <filename>kde-<replaceable>component</replaceable>.<replaceable>architecture</replaceable>.rpm</filename> You need at least tdesupport, tdelibs and tdebase. After getting the base distribution, feel free to download any other RPMs that you think may come in handy. </para>
<para>Next, start installing with the base package. If you are installing KDE for the first time, use </para>
<important><para>It is important that these components are installed in the order listed, and that they are installed before any other KDE component.</para></important>
<para>If you are upgrading from a previous release, try <screen><userinput><command>rpm</command> <option>-Uvh</option> <filename>kde-<replaceable>component</replaceable>.<replaceable>arch</replaceable>.rpm</filename></userinput>
<para>If the installation of the base packages has been successful, you can install the remaining packages (use <option>-Uvh</option> instead of <option>-i</option> once again to update an existing version) the same way. </para>
<para>The installation for a Debian system is also rather straightforward. You will only find KDE 2.0 packages for Debian 2.2 (Potato) and 3.0 (Woody). We describe here how to install packages for Debian 2.2, the stable version, since Debian 3.0 is still in development. However, the installation for both versions, is almost identical. The main difference is that KDE is officially included in Debian 3.0 and you do not need to specify any special location to find the deb packages for KDE.</para>
<para>The first step is to tell your system where it can find the deb packages for KDE. A list of locations for the Debian packages is kept on your hard disk in <filename>/etc/apt/sources.list</filename>. You should add to that file the following line: <userinput>http://kde.tdyc.com/ stable kde2</userinput></para>
<para>Then you have to update your local package database so that your system knows that there are new packages available. Type the following command:</para>
<para>where <replaceable>xx</replaceable> has to be substituted by the country code.</para>
<para>The control files for some TDE applications will be placed at <filename class="directory">/etc/kde2</filename>, the executables will go in <filename class="directory">/usr/bin</filename> and most of the auxiliary files in <filename class="directory">/usr/share</filename> under different folders. </para>
<para>If you are upgrading from a previous version of KDE you should perform the following steps. First, update file <filename>/etc/apt/sources.list</filename> by changing the line with the location of KDE packages with line: <userinput>http://kde.tdyc.com/ stable kde2</userinput>. Second update your package database:</para>
<para>If your Linux distribution did not come with an RPM or DEB archive format, or you are not using Linux at all, you must compile KDE on your own. In the future, we are planning to provide a binary distribution which includes its own installation program. </para>
<para>Once you have all the needed helper applications, go to your favourite KDE mirror and retrieve the following files from the folder <filename>/pub/kde/stable/<replaceable>newest version</replaceable></filename>:</para>
<para>In all cases above, <replaceable>version</replaceable> stands for the current version number. Once you have downloaded all you need, extract these files to <filename>/usr/src</filename>. This process should yield the following folder structure:</para>
<para>Every configure script has several options available. Some are common between the packages while others are specific to an individual package. The following is a small part of the result of <command>configure <option>--help</option></command> in tdelibs:</para>
<para>Several options are not required and are only useful as workarounds for known problems (⪚ <option>--disable-FEATURE</option>). Since some are important options, for instance <emphasis>--with-shadow</emphasis>, you should always check the available options.</para>
<para>An important option is <option>--prefix</option>. This option specifies the path where configure should install (for tdesupport and tdelibs) or where to look for libraries (for the other packages). By default, configure will look in <filename>/usr/local/kde</filename> . If you want to install &kde; into <filename>/opt/kde</filename>, you have to use <command>configure <option>--prefix /opt/kde</option></command>.</para>
<para>If you have installed the &Qt; libraries in an uncommon place, for instance in <filename>$HOME/src/qt</filename>, you must use <command>configure <option>--with-qt-dir=$HOME/src/qt</option></command>. By default configure looks in the most common places for &Qt; before it gives up.</para>
<para>If you have problems that you are not able to solve, send a copy of the <filename>config.log</filename> file to the address given in the offending package's <filename>README</filename> file.</para>
<para>You must install KDE in the following order: arts, tdelibs, then the application packages (for example tdebase). All the application packages should only depend on tdelibs, so you can compile them at the same time (if you have a powerful machine).</para>
<para>If you want to take advantage of multiprocessor systems, try <command>make <option> -j <replaceable>Number of processors</replaceable></option></command> instead of <command>make</command>. </para>
<para>For &Linux;, most of the utilities needed to build &kde; can be found either at <ulink url="ftp://sunsite.unc.edu/pub/Linux/GCC">ftp://sunsite.unc.edu/pub/Linux/GCC</ulink> or <ulink url="ftp://sunsite.unc.edu/pub/GNU">ftp://sunsite.unc.edu/pub/GNU</ulink>. The Qt libraries can be found at <ulink url="ftp://ftp.troll.no/pub/qt/source">ftp://ftp.troll.no/pub/qt/source</ulink>, available as source code. Detailed instructions on how to install them are provided. Include files for X11 programs should be available at <ulink url="ftp://ftp.xfree86.org">ftp://ftp.xfree86.org</ulink> in the xdevel section. </para>
<title>Required Changes To Your Configuration Files </title>
<para>After you have placed the KDE binaries into their destination folder, there are a few adjustments you must make to your startup scripts. </para>
<para>The following procedure was tested on SuSE Linux 5.0, and should be compatible with the other popular UNIX's as well. <emphasis>Always make backups of configuration files before changing them!</emphasis> Add the following to the end of your /etc/profile: </para>
<para>Next, edit the .xinitrc file in your home folder. Look for the line that calls your window manager and replace it with <literal>starttde</literal>.</para>
<para>Now that everything needed to run KDE has been installed, you can go on to chapter 4 where you will start KDE for the first time. If something goes wrong, you may need to compile KDE on your own. Read<emphasis> <link linkend="source-distribution">Using Source Compilation to Install on Top of Other Systems</link> </emphasis>for more information. </para>
<para>We have made the installation as bulletproof as possible, so you should not encounter any serious problems unless your configuration is exotic. If you do experience difficulties feel free to use <link linkend="mailing-lists">the KDE mailing lists</link> </para>