Home > Articles > Operating Systems, Server > Linux/UNIX/Open Source

  • Print
  • + Share This

Done Downloading—Now What?

You now have some flavor of KDE2 on your local drive: binary package, snapshot, or CVS tree. What are you supposed to do with one of these?

Well, you're not supposed to just install it without making any preparations. Your preparations will vary depending on a number of factors determined by your current setup and its limitations. For example, you'll consider whether you're currently running KDE-1.x or some other desktop, whether you have lots of drive space or just a little, and how much disruption you're willing to endure.

In the best of all possible worlds, you have a machine that is available just for testing new software and is removed (except perhaps by a network card) from your production machine. Both your production and test machines will have dual 1-gig processors, a gig of RAM, 2 MB of L2 cache, and multiple fast SCSI drives configured as a RAID. Of course, because you're probably like the rest of us who reside in a less-than-best-possible world, we'll need to discuss some compromises.

If You're Running KDE-1.x

Ironically, it's a little more difficult to try out KDE2 if you're already running a release version of KDE, but you'll also be more likely to know how to do it. It is possible to keep both KDE-1.x and KDE2 on the same machine and to switch freely between them. In fact, it's easy—there are even several ways to do it. The KDE developer David Faure has produced a recipe that allows you to choose between KDE and KDE2 at the graphical KDM login. There is another method that lacks such elegance, but it is simple and foolproof. Before we get to that, however, we need to deal with QT.

As you probably know (if you're already running KDE), KDE is built against the QT libraries from Troll Tech. KDE-1.x requires QT-1.x, typically 1.44. KDE2 requires QT-2.1, which is manifested in the package you downloaded called qt-copy. No problem, you say: Just install it in place of QT-1.44 and that will be that, right? Wrong. QT-2.1 is not backward compatible with QT-1.44. If you replace QT-1.44 with QT-2.1, your KDE-1.x won't work anymore. If you don't install QT-2.1, your KDE2 won't work. Quite a mess.

Thus we arrive at the first part of the simple, inelegant, and foolproof solution. Chances are that your QT-1.44 resides in a directory all by itself, under /usr. Take a look to make sure that this is the case. While you're there, look at /usr/lib/qt. Is it a symbolic link to the QT-1.44 directory? If so, you can go ahead and install qt-copy to /usr/qt-copy, /usr/qt21, or whatever suits you. When you are ready to switch to KDE2, one of the things you'll do is change this symbolic link, deleting the one that points to your old QT and making one that points to the new version.

Now comes the matter of your existing KDE. Even though many people are using KDE2 productively and exclusively, most likely nobody just up and deleted his existing KDE before installing KDE2. A path out of a bad situation is always a good idea, and with new, untested software, success is not assured.

KDE has traditionally resided in /opt/kde; in Caldera Open Linux, /opt is a symbolic link to /usr/opt, so KDE is actually in /usr/opt/kde, which is just fine. The important thing is that it is in a directory all its own rather than splattered across /usr, as is the unfortunate case in some Linux distributions. (An aside: If you have such a distribution, which is typically a recent Red Hat Linux or one of its derivatives, you can use the RPM command to remove all of its packages, and then download fresh RPMs from kde.org and install them where they belong— at least for your current purposes. If you do this, you will need to change the $KDEDIR= variable in /etc/profile.d/kde.sh. Do it—you'll be glad you did.)

We now must move to a pure command line interface, without KDE running at all, and as root. Change to the directory above KDE—/opt is safe, even as a symbolic link, because it will take you to /usr/opt. Then do the following, assuming that you have KDE-1.1.2:

cp -r /kde /kde112 

You will now have a directory, /usr/opt/kde112, containing everything in your /usr/opt/kde directory. (If you have a shortage of space on a partition containing /opt, you can put your KDE-1.1.2 pretty much anywhere else—although choosing your /home directory is a bad idea because it can accidentally be altered quite easily. Just make sure that the symbolic link is in /opt.) It's a good idea to use the du command to make sure that the two directories, old and new, are the same size. If they are, swallow hard and do this:

rmdir -r /kde 

For a moment, you do not have a working KDE, but our next step will fix that. (By the way, all of this moving and renaming of things is a lot simpler if you have Midnight Commander installed.) Our next step is to create a symbolic link between /kde112 and /kde:

ln -s /kde112 /kde

Now, as far as your computer knows, nothing has changed: To the computer, that which was in /kde still is in /kde, even though it's actually in /kde112. But there is method in all of this madness: Go ahead and exit root, and restart KDE. See? It still works.

Now you are prepared to take KDE2 for a spin without breaking your existing KDE.

  • + Share This
  • 🔖 Save To Your Account

Related Resources

There are currently no related titles. Please check back later.