3. Enhancing the Functionality of a Package (Tasks)
4. Verifying and Transferring a Package
5. Case Studies of Package Creation
Soliciting Input From the Administrator
Creating a File at Installation and Saving It During Removal
The i.admin Class Action Script
Modifying a File by Using Standard Classes and Class Action Scripts
The i.inittab Installation Class Action Script
The r.inittab Removal Class Action Script
Modifying a File by Using the sed Class and a postinstall Script
The sed Class Action Script (/etc/inittab)
Modifying a File by Using The build Class
Modifying crontab Files During Installation
The i.cron Installation Class Action Script
The r.cron Removal Class Action Script
Installing and Removing a Driver With Procedure Scripts
Installing a Driver by Using the sed Class and Procedure Scripts
The sed Class Action Script (/etc/devlink.tab)
The postinstall Installation Script
The package in this case study uses optional information files to define package compatibilities and dependencies, and to present a copyright message during installation.
This case study demonstrates the following techniques:
Using the copyright file
Using the compver file
Using the depend file
For more information on these files, see Creating Information Files.
To meet the requirements in the description, you must:
Create a copyright file.
A copyright file contains the ASCII text of a copyright message. The message shown in the sample file is displayed on the screen during package installation.
Create a compver file.
The pkginfo file shown in the next figure defines this package version as version 3.0. The compver file defines version 3.0 as being compatible with versions 2.3, 2.2, 2.1, 2.1.1, 2.1.3 and 1.7.
Create a depend file.
Files listed in a depend file must already be installed on the system when a package is installed. The example file has 11 packages which must already be on the system at installation time.
PKG=case3 NAME=Case Study #3 CATEGORY=application BASEDIR=/opt ARCH=SPARC VERSION=Version 3.0 CLASSES=none
Copyright (c) 1999 company_name All Rights Reserved. THIS PACKAGE CONTAINS UNPUBLISHED PROPRIETARY SOURCE CODE OF company_name. The copyright notice above does not evidence any actual or intended publication of such source code
Version 3.0 Version 2.3 Version 2.2 Version 2.1 Version 2.1.1 Version 2.1.3 Version 1.7
P acu Advanced C Utilities Issue 4 Version 1 P cc C Programming Language Issue 4 Version 1 P dfm Directory and File Management Utilities P ed Editing Utilities P esg Extended Software Generation Utilities Issue 4 Version 1 P graph Graphics Utilities P rfs Remote File Sharing Utilities Issue 1 Version 1 P rx Remote Execution Utilities P sgs Software Generation Utilities Issue 4 Version 1 P shell Shell Programming Utilities P sys System Header Files Release 3.1