Reader small image

You're reading from  CUPS Administrative Guide

Product typeBook
Published inSep 2008
Publisher
ISBN-139781847192585
Edition1st Edition
Tools
Concepts
Right arrow
Author (1)
Ankur Shah
Ankur Shah
author image
Ankur Shah

Ankur Shah has been working with Linux/AIX for last 4 years as a System Administrator. His previous assignment was with Packt Publishing, where he worked as System Administrator and also started implementing CUPS. He completed his graduation in Computer Engineering from Nagpur University, India. He is currently working as a SAP Basis Administrator and also started working on Governance Risk and Compliance for access Control. He is also interested in Oracle Database Administration and Security. He is the biggest fan of Kajol (a Bollywood actress) and dedicates this book to her. The day her movie releases is a day of celebration for him and he only parties once a year - 5th August - that's Kajol's birthday. It goes without saying that he watches all her movies several times - often dragging his friends and family to participate in his madness.
Read more about Ankur Shah

Right arrow

Chapter 2. Building and Installing CUPS

Today, most of the UNIX and Linux systems come with the CUPS printing system. CUPS is supported by Caldera, Debian, Conectiva, easyLinux, HP-UX, IRIX, Linux Mandrake, Peanut, Red Hat, Solaris, SusE, Tru64, UNIX, TurboLinux, and AIX. Of these, Conectiva, easyLinux, Linux Mandrake, and Peanut use CUPS as their primary printing system.

This chapter describes how to compile and install CUPS on your system from the source code.

Downloading Source Code

Today, most of the UNIX and Linux distributions install CUPS by default. CUPS requires ANSI-compliant C and C++ compilers, a Make program and Bourne shell. The GNU compiler tools also work well with CUPS.

CUPS has been tested with GNU Make as well as the other Make programs shipped by Compaq, HP, SGI, and Sun. BSD users should use GNU make (gmake). The latest version of CUPS can be downloaded from http://www.cups.org/software.php. The current stable version of CUPS is 1.3.8.

Apart from these tools, we also require...

Downloading Source Code


Today, most of the UNIX and Linux distributions install CUPS by default. CUPS requires ANSI-compliant C and C++ compilers, a Make program and Bourne shell. The GNU compiler tools also work well with CUPS.

CUPS has been tested with GNU Make as well as the other Make programs shipped by Compaq, HP, SGI, and Sun. BSD users should use GNU make (gmake). The latest version of CUPS can be downloaded from http://www.cups.org/software.php. The current stable version of CUPS is 1.3.8.

Apart from these tools, we also require support for the following libraries that provides additional functionality for printing service. CUPS mainly supports two libraries:

  • CUPS imaging library

  • CUPS library

The CUPS imaging library consists of libraries for JPEG, PNG, TIFF, ZLIB, and so on, and it is used for images support.

The CUPS library contains CUPS-specific functions that support the use of CDSA, GNU TLS, and the OpenSSL libraries for encryption. We will discuss these in details in Chapter...

Installing the Software


Once the CUPS software is built, you need to install it. The install target provides a quick way to install the software on your local system:

#make install

You should use the following command to install built CUPS, if the system is FreeBSD, NetBSD, or OpenBSD:

#gmake install

Note

Installing CUPS will overwrite your existing printing system. If you experiences difficulties with the CUPS software and want to go back to your old printing system, the reinstallation of the old printing system can be done via the operating system CDs.

If you find any difficulties with compiling CUPS, you can submit a trouble report on the CUPS website. The Software Trouble Reports (STR) are maintained on the Bugs and Feature page on the CUPS website: http://www.cups.org/str.php.

Note

You can find the guidance documents and processes consisting of information related to STR in the developer guidelines at the following URL:

http://www.cups.org/documentation.php/spec-cmp.html

Installing a Binary Distribution


You can also build binary packages that can be installed on other machines using the RPM spec file (packaging/cups.spec) or EPM list file (packaging/cups.list). The latter also supports building of binary RPMs (Red Hat Package Manager), which makes it more convenient to use.

Building RPMs

You can find the RPM software at http://www.rpm.org/.

The source distributions include an RPM spec file that can be used to build RPM packages for your Linux distribution. The rpmbuild command is used to build from the tar files:

#rpmbuild -ta cups-version-source.tar.gz

Or

#rpmbuild -ta cups-version-source.tar.bz2

You will need the gcc, libjpeg, libjpeg-devel, libpng, libpng-devel, libtiff, libtiff-devel, zlib, and zlib-devel packages installed to compile CUPS with all the standard functionalities. The krb5-devel and krb5-libs packages, openldap and openldap-devel packages, openslp, and openslp-devel packages will allow support for Kerberos (CUPS 1.3.x only), LDAP, and SLP...

Installing CUPS Using the Package Manager on Linux


To install the CUPS software from the package manager available in the control center, click on Install Software. This will launch the package manager for software installation as shown in the following screenshot. Here, we have used the rpmdrake package manager of Mandriva (originally Mandrake) Distribution. The rpmdrake is a simple graphical frontend to manage software packages on a Mandriva Linux system. You can see the options for installation, removal and updation of software packages.

You can select the package that you want to install. The package can be selected by one of the following three options:

  1. 1. Search by choices

  2. 2. List by alphabetical order

  3. 3. All packages by group

Further, you should perform following steps to search for the desired package, cups:

  • Leave as default and enter the name of the application

  • Click on the Search button

  • On the search result, click on the correct package

Note

Some of the packages might require additional...

Testing CUPS


We have seen various processes to install CUPS. Once installed, you should test CUPS to make sure whether it is working properly. Since CUPS uses the IPP (Internet Printing Protocol), you can verify this by opening a browser and typing http://localhost:631/.

Note

The default port number on which CUPS listens is 631, but you can change it. We will see how to change this default port in Chapter 5CUPS Server Management.

Summary


This chapter describes how to download the source code for CUPS, it also describes various methods for building and installing CUPS. The following are the various ways in which we can install CUPS, which we have discussed in the chapter:

  • Using Source Code

  • Binary Installation

  • Using Subversion

  • Using Package Manager

For the Binary Installation, we have also discussed the following scenarios for the installation.

  • Using Portable Distribution

  • RPM installation

  • Debian Installation

Finally, we have seen how to access the CUPS server in a web browser using a special URL, so we can test it to see if it has been installed properly.

lock icon
The rest of the chapter is locked
You have been reading a chapter from
CUPS Administrative Guide
Published in: Sep 2008Publisher: ISBN-13: 9781847192585
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
undefined
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $15.99/month. Cancel anytime

Author (1)

author image
Ankur Shah

Ankur Shah has been working with Linux/AIX for last 4 years as a System Administrator. His previous assignment was with Packt Publishing, where he worked as System Administrator and also started implementing CUPS. He completed his graduation in Computer Engineering from Nagpur University, India. He is currently working as a SAP Basis Administrator and also started working on Governance Risk and Compliance for access Control. He is also interested in Oracle Database Administration and Security. He is the biggest fan of Kajol (a Bollywood actress) and dedicates this book to her. The day her movie releases is a day of celebration for him and he only parties once a year - 5th August - that's Kajol's birthday. It goes without saying that he watches all her movies several times - often dragging his friends and family to participate in his madness.
Read more about Ankur Shah