LinuxBasics.org

The community that helps people to run Linux

rss
Table of Contents

Installing Applications

During the initial installation it is often best *not* to install too many applications along with the base-system. This document explains how programs can be installed as they are needed.

What should be installed during the initial install?

During the first run of the installation you should install (of course) the base-system, the editor of your choice (or, if you don’t know yet which one, you should be safe with vi, emacs and pico), and X11 along with a desktop environment (KDE or Gnome).

While X11 and the desktop environment might not be strictly neccessary, there are systems that preconfigure those two components very well during the initial install, but might give new linux users a hard time if the configuration should be done after.

What should be installed later?

Well, just about everything else. The reason for this is that you get a running system quickly and install components as you need them. Your system will stay slim (hopefully :).

So, the office-suite, the big browser, games and the like are perfect for a later run of the installer. After some installations, you get to know the distributions better and get a feeling about what to install first and what to install later.

Packages

Your distribution has a preferred way of packing all files needed for a program together to make it easy to install software. These packages usually include information on what other programs are needed to run the software you want to install.

For example, the xclock package (which shows a clock in an X11-window) needs X11 to work. While this is still obvious, this technique is also used to break large projects into manageable chunks. KDE for example needs the kde-base package, but does not need kde-games, although people can choose to install those, too.

This makes it possible to download and install only what you want.

Use the package manager!

Whenever possible, use the package-manager that comes with your distribution and packages that are made for this distribution. The package manager will do many things for you, like detecting and resolving dependencies and conflicts. It will help you to install, update and remove software. But it can only do so, if its database is current, that means the package manager “knows what is installed”.

So, use the regular probrams that come with your distributions (Yast for Suse, drake for Mandrake, dselect for Debian, …). They are set up so that they access your CD/DVD or the source you have used for the install. Other sources can also be configured.

If these front-ends are not what you want to use (maybe you have downloaded a whole bunch of RPMs and want to install them with one command), then use the appropriate command-line tool. Check the manpages for details on how to use “rpm”, “dselect”, “apt-get” and others

Installing binaries: RPM

To install a RPM that you have downloaded, you can do so by typing “rpm -i package.rpm” on the command line. Any unmet dependencies and conflicts are reported and have to be fixed before this will work successfully. See “man rpm” for more commands and details

Installing binaries: DEB

To find the package you want, use “apt-cache search whatever”. Apt will search all sources specified in /etc/apt/sources.list and give you the exact name. Then a “apt-get install whatever” will download the package and install it. Apt will also offer to resolve all dependencies and conflicts for you. Works very nicely. See “man dselect” and “man apt-get” for more commands and details.

If you have your Debian system on a slow Internet connection and find you have a large download needed for something like an upgrade, you can use apt-zip to get those files using a different computer that has a faster connection. See more on apt-zip.

A signature check is done with apt-get. Explanation of how it works is here in Section 7.4 “Package signing in Debian”: http://www.debian.org/doc/manuals/securing-debian-howto/ch7.en.html

Installing binaries: Slackware

Installing from source: Tarballs

When installing tarballs, you leave the well-charted streets of your package-management. So what comes in this section is mainly for those who “want to know what’s going on inside”. Anita has put together some fine instructions on using checkinstall in order to convert tarballs into packages that can be installed with the regular package-manager. James has put up a tutorial on how to install WindowMaker (which is one of the fancier Windowmanager for X11) . It is a nice example of the real steps neccesary for installing real applications.

Tarball collections of files that are put together into one file using tar. Most of them are compressed using either zip or bzip2. So the possible file-extensions include

Both compression algorithms are included in the tar-binary, so extracting can be done with one command.

After unpacking, enter the directory that has been created (“cd tarball”) and read all available README or INSTALLING files that are relevant for your system. Follow the instructions in those files.

Usually, these instructions boil down to

  1. ./configure –with_options –depending –on_your_system
    This configures the software and is the most important step. If you get the options wrong, your application will not work as expected. So read the documentation that comes along with the tarball! This step can be done as mere user.
  2. make
    This “builds” the program. Usually the source is compiled and linked. This step can be done as mere user.
  3. su
    The next step is usually done by root.
  4. make install
    This copies the fresh binaries into the directories where they are expected to be. Since this is usually something like /usr/bin or the like, only root can do this.

You can also install the software inside your home-directory if you do not have root-privileges on the machine. But then you need to tell ./configure in step one.

Installing from source using checkinstall and the package manager

Installing packages using the package manager for your distribution of Linux is a very good idea. Your database of packages will stay up to date that way. If you don’t keep the database up to date, you can find yourself trying to install something with the package manager and having it not install due to missing dependencies - programs you know are installed, but the package manager does not know! It also makes it much easier to find the files of programs or remove programs later. Package managers give you information on programs that you will not have it they have not been installed through that means. So, first be sure your distribution of Linux doesn’t have the package. If you can’t find the package, you can still use your package manager to install the program by using checkinstall to install from the source code.

Finding programs:

If you don’t find the program you want on your chosen distro’s homepage or cdrom check out our Application Links. My favorite is Freshmeat.net.

Getting and installing 'checkinstall':

Get the stable source code or binary if you wish at http://asic-linux.com.mx/~izto/checkinstall/ You may find the program on your installation CDROM, but it is only a 88Kb download. I found it in Slackware on CDROM #3 under the “extra” directory. There are some notes there about using it with Slackware. Read the INSTALL file for how to install. That’s very easy. /etc/checkinstall/checkinstallrc holds the configuration. That is where the type of package is set to S, D, or R for Slackware, Debian, or RPM.

Install programs using checkinstall:


Created by stwaidele


Copyright (c) by the authors.
Prior to editing, authors agreed to license their contributions by the terms of the GPL.
See our licensing page for details.


Linux® is a registered trademark of Linus Torvalds.


 
  tutorials/using/installing_applications.txt · Last modified: 2007/11/16 12:24

LinuxBasics.org

Start Linux-Course Tutorials Linux Links Security Mailing List Online Chat Blog Forum

Site-Info

Help Get in Touch Making of LBo

Wiki-Control

Powered by

Linux Apache DokuWiki Mailman RUTE ht://Dig