Chapter 18. Package Management

Table of Contents
18.1. The Main Tool: RpmDrake
18.1.1. The Main Window
18.1.2. Installable And Installed Packages
18.2. Installing Packages
18.3. Uninstalling Packages
18.4. Sources Management
18.4.1. Adding Sources
18.4.2. Updating Sources And Packages
18.5. Updating Your System

Maybe you have already noticed that your system is made of a large number of small pieces, in the same way a house is made of bricks. Here, we do not call these pieces "bricks", but packages. A package can then be seen as a box containing all the elements necessary to install and run a specific software.

In this chapter, we will speak about package management, which includes the installation of new packages (i.e.: adding software to your system), updating already installed packages when new releases or corrections appear, and also removing packages from your system. This management is eased through the use of a few tools. Nevertheless, these actions are not available to users, so you need to have super-user permissions to use the tools described below. If you launch the tools from a user's account, you will be prompted for a root password. You can always start from a sudo shell.

18.1. The Main Tool: RpmDrake

RpmDrake is the main package-management tool. You can launch it from the Mandrake Control Center+System+Software Manager sub-menu.

Figure 18-1. First RpmDrake Message

When you launch it for the first time, a dialog box appears offering you to configure a "source" for "security updates". We will explain these concepts later, so for now, simply answer NO to this question.

18.1.1. The Main Window

When launched, RpmDrake does some analysis and configuration checking, which can take some time. Finally, you see the main window, showed in this figure:

Figure 18-2. RpmDrake's Main Window

As you can see, RpmDrake's main window is basically divided into three parts.

  1. On the left, a tree showing package names (sorted and grouped by categories) along with some other information; note that you can change the view to a flat, alphabetically ordered list, just by clicking on the Flat list tab.

  2. The top-right box shows the packages you selected. If you double-click on a package name, it will be removed from this window and de-selected for maintenance.

  3. At the bottom-right, various information about the currently highlighted package, such as its name, detailed description, file list, and so on.

Take a random package in a category (remember, you just have to click on the + sign to expand a tree branch), then click on its name. The bottom-right block displays general package information as well as the packagers name. In the File list, you get a tree view of the files contained in the package, as shown below.

Figure 18-3. A Package's File List

Table 18-1. RpmDrake Icons

If you click on the first column's label, the question mark, RpmDrake will check if the files contained in the package already exist on your system.

If so, they will be marked with a green check sign.

If the files are not present, they will be marked with a red X.

Let's have a look at the Deep size column. You can see it shows only for directories. The size of a directory is defined as the sum of all files contained in it. If the directory does not contain any sub-directory, that's enough. Now, if a directory contains one or more sub-directories, then the depth size is defined as the directory's size, plus the depth size of each of its sub-directories.

In the above example, the usr directory's size is zero, because it does not contain any files. But it holds sub-directories (bin and share): therefore its depth size is the sum of the depth sizes of each sub-directories. On the other hand, if the directory bin contains some files but no sub-directory, its depth size is the same as its size.

Now we will select a package. Simply click in the little square box on the left of the package name: immediately, this package is added in the Selected block, located in the window's top-right corner (actually, you can double-click anywhere on a line associated with a package and that package will be added to the Selected packages).

You can select as many packages as you want. You may also simply browse through the packages, choosing some on the way for later use. Notice that if you click on a package, its description is displayed in the block below the Selected box.

Finally, let us talk a bit about the Find text field: as you may have already guessed, this will look for a word through all the packages' names. Simply type in a word, then click the Search button. Packages whose name contain the given word are then displayed under the Search Result tree node in the tree view, or only listed packages in the Flat List view. Also note that if you want to use the plus sign ("+") in your search (as in "C++", for instance), you have to prefix it with a backslash sign, for example: "C\+\+".

Note

For expert users, the Find field supports standard regexps (regular expressions), as defined in regexp(7).

If you type another word and then click Search again, the result of your second inquiry replaces those of your preceding one. If you want to clear your search results, use the Reset button.

18.1.2. Installable And Installed Packages

Two kinds of RpmDrake packages exist: the Installables, which holds the not yet installed packages and those you can upgrade, while the Installed RPMs are, you guessed it, already installed on your Mandrake Linux system but unfortunately, there are no upgrades available. Click on the according tab (just under the button bar) to switch between the two lists.

When you start RpmDrake, you see the list of installable packages by default, according to what is written just below the tab. This can be a rather long list, so for your convenience, use the box just below the tabs, which says All by default. Click on it, then select Updates only: this time, you get a list of the packages installed on your machine but for which there exists a more up-to-date release of the sources (more later about sources and updates). Notice that those "updating packages" are displayed with a symbol on the left of their name. For example, the symbol shows updates that come from Cooker, the development version of Mandrake Linux.

On the other hand, if you select Uninstalled only in the list instead of All or Updates only, you will see the packages that are not yet installed on your system.


Tux on Star from MandrakeSoft Linux is a registered trademark of Linus Torvalds. All other trademarks and copyrights are the property of their respective owners.
Unless otherwise stated, all the content of these pages and all images are Copyright MandrakeSoft S.A. and MandrakeSoft Inc. 2002.
http://www.mandrakelinux.com/