These notes are tailored to Ubuntu. Other distributions of Linux have their own way of doing installation. We’ll talk about those in lesser detail. In all systems, you have to either be the superuser or be a user who has the capacity to do superuser-type actions.
Ubuntu uses the dpkg (Debian Package) management system. Each software package has all its files bundled up into a dpkg files that tells where it should reside, what files need to change when it is installed (such as menus in GNOME or KDE), and, most important, the package’s dependencies–what other packages must be installed along with the one you are interested in.
Ubuntu keeps repositories, which are servers that contain the latest version of all the packages, and they get downloaded when you need them.
From the System/Administration menu, choose Synaptic Package Manager. Once it starts, you may wish to choose Repositories from the Settings menu so you can see how all of this is set up. Changes that you make to the repositories are reflected in the file /etc/apt/sources.list
You can select packages by their category (at the left panel), or you may search for specific keywords. Use the search menu to search for chess programs:

From the resulting list, right-click 3dchess and then left-click the Mark menu item to mark it for installation.

When you do this, the package manager realizes that there is a dependency and tells you about it and lets you mark those for installation as well.

Once that is done, click the Apply button, and the package will be installed.
In Mandriva Linux, you can get to the GUI package installation by choosing Install & Remove Software from the main KDE menu, or by typing rpmdrake from the command line.
Exit from Synaptic now (if you don’t, this next step will give you an error message telling you that the package management database is locked or in use by another program).
If you know the name of the package you want, you can install from from the command line by typing:
sudo apt-get install packagename
Try installing the tuxeyes package with this command:
sudo apt-get install tuxeyes
In Mandriva, the command is
sudo urpmi packagename
What if you just have a package file (with a .deb extension)
that someone has sent you or you have just downloaded? Then you can
use the dpkg command.
Download this raw package file from the server: xeji_1.2-11ubuntu1_i386.deb
Use the dpkg command to see the contents of the
package:
dpkg --contents xeji_1.2-11ubuntu1_i386.deb
Then install it:
dpkg --install xeji_1.2-11ubuntu1_i386.deb
For Mandriva, the package format is RPM (stands for Red Hat Package Manager, so Red Hat and Fedora Linux both use this format as well). Download xeyes-1.0.1-7mdv2010.0.i586.rpm and use these commands:
# see package contents rpm -qilp xeyes-1.0.1-7mdv2010.0.i586.rpm # install rpm -ivh xeyes-1.0.1-7mdv2010.0.i586.rpm
Download zsnes.tar.gz from the server. It is a SuperNintendo emulator for Linux. Unpack it to your home directory, and then unpack the source:
tar -xvzf zsnes.tar.gz cd zsnes tar -xvjf zsnes151src.tar.bz2
Do a cd zsnes_1_51/docs and then ls. In the
normal Linux/UNIX packaging world, there should always be a
README file. IfWhen you read file
README.LINUX you will find that you need to install
the development libraries for SDL (Simple DirectMedia Layer); do this
by going to Synaptic and installing libsdl1.2-dev
Now cd ../src; ls This is
a standard Linux/UNIX source packaging scheme; there’s a file named
configure. This file will test to see that you have everything
needed to build the package. Run it by typing:
It will give some messages, and then halt with an error:
configure: error: You need NASM installed to compile ZSNES
You can install NASM (the Netwide Assembler) from Synaptic, or install it from the command line:
sudo apt-get install nasm # Ubuntu sudo urpmi nasm # Mandriva
Now when you type ./configure again, you should have
everything needed to do the build. If you don’t, then
use Synaptic to download the appropriate files. For example, if it
says you are missing zlib, go to Synaptic and do a search
for zlib. You will find that zlib1g is installed,
but just below it is the zlib1g-dev package. The dev
means that this package contains the files necessary to develop other
programs (which is what you are doing).
You may also need to install libpng12-dev and libncurses5-dev.
Once you get through ./configure without errors,
you will find a file named Makefile
that contains the instructions needed to compile and install the
software.
From the command line, type:
make
and just watch as the messages scroll by. Normally, I like to divert the messages to a file so that I can keep a record in case something goes wrong:
make 1>makelog.txt 2>&1
This builds the files. If you look at the directory, you will see that
there is now an executable file named zsnes; if you
type ./zsnes it should run. Some packages won’t
run properly until they are installed in their appropriate destination
folder, but this one will, so try it now.
You may then install the software to its destination by typing the following. Since the install puts files into system-access folders, you need to be the superuser to make this work:
sudo make install
That’s all there is to it. You should then be able to execute
the program by just typing zsnes.