<?Pub UDT _bookmark _target?><?Pub EntList bull rArr sect?><chapter id="ch1designpkg-51728"><title>Designing  a Package</title><highlights><para>Before you build a package, you need to know which files you need to
create and the commands you need to execute. You also need to consider your
application software's requirements and the needs of your customers. Your
customers are the administrators who will be installing your package. This
chapter discusses the files, commands, and criteria you should know and consider
before building a package.</para><para>This is a list of the information in this chapter. </para><itemizedlist><listitem><para><olink targetptr="ch1designpkg-13" remap="internal">Where to Find Packaging
Tasks</olink></para>
</listitem><listitem><para><olink targetptr="ch1designpkg-30852" remap="internal">What Are Packages?</olink></para>
</listitem><listitem><para><olink targetptr="ch1designpkg-24309" remap="internal">Package Components</olink></para>
</listitem><listitem><para><olink targetptr="ch1designpkg-28244" remap="internal">Considerations Before
Building a Package</olink></para>
</listitem><listitem><para><olink targetptr="ch1designpkg-21979" remap="internal">Packaging Commands,
Files, and Scripts</olink></para>
</listitem>
</itemizedlist>
</highlights><sect1 id="ch1designpkg-13"><title>Where to Find Packaging Tasks</title><para>Use these task maps to find step-by-step instructions for building and
verifying packages.</para><itemizedlist><listitem><para><olink targetptr="ch2buildpkg-30163" remap="internal">The Process of Building
a Package (Task Map)</olink></para>
</listitem><listitem><para><olink targetptr="ch3enhancepkg-1" remap="internal">Creating Information Files
and Installation Scripts (Task Map)</olink></para>
</listitem><listitem><para><olink targetptr="ch4verifypkg-13" remap="internal">Verifying and Transferring
a Package (Task Map)</olink></para>
</listitem>
</itemizedlist>
</sect1><sect1 id="ch1designpkg-30852"><title>What Are Packages?</title><para><indexterm id="ch1designpkg-ix1"><primary>software package</primary><see>package</see></indexterm><indexterm id="ch1designpkg-ix2"><primary>package</primary><secondary>description</secondary></indexterm>Application software is delivered
in units called <firstterm>packages</firstterm>. A package is a collection
of files and directories that are required for a software product. A package
is usually designed and built by the application developer after completing
the development of the application code. A software product needs to be built
into one or more packages so that it can easily be transferred to a distribution
medium. Then, the software product can be mass produced and installed by administrators. </para><para><indexterm><primary>application binary interface (ABI)</primary></indexterm><indexterm><primary>system V interface definition</primary></indexterm>A package is a collection of files and directories in a defined
format. This format conforms to the application binary interface (ABI), which
is a supplement to the System V Interface Definition.</para>
</sect1><sect1 id="ch1designpkg-24309"><title>Package Components</title><para>The components of a package fall into two categories.</para><itemizedlist><listitem><para><firstterm>package objects</firstterm> are the application
files to be installed.</para>
</listitem><listitem><para><firstterm>control files</firstterm> control how, where, and
if the package is installed.</para>
</listitem>
</itemizedlist><para><indexterm id="ch1designpkg-ix3"><primary>package components</primary></indexterm><indexterm id="ch1designpkg-ix4"><primary>package</primary><secondary>components</secondary></indexterm><indexterm><primary>package</primary><secondary>control files</secondary><tertiary>information files</tertiary></indexterm><indexterm><primary>package</primary><secondary>control files</secondary><tertiary>installation scripts</tertiary></indexterm><indexterm><primary>control files</primary><secondary>description</secondary><seealso>information files and installation scripts</seealso></indexterm>The control files are also divided
into two categories: <firstterm>information files</firstterm> and <firstterm>installation
scripts</firstterm>. Some control files are required. Some control files are
optional.  </para><para><indexterm><primary><command>pkgmk</command> command</primary><secondary>package components</secondary><tertiary>building the package</tertiary></indexterm>To
package your applications, you must first create the required components,
and any optional components, that make up your package. You can then build
the package by using the <command>pkgmk</command> command.</para><para>To build a package, you must provide the following:</para><itemizedlist><listitem><para>Package objects (the application software's files and directories)</para>
</listitem><listitem><para><indexterm><primary><filename>pkginfo</filename> file</primary></indexterm><indexterm><primary><filename>prototype</filename> file</primary></indexterm>Two required information files (the <filename>pkginfo</filename> and <filename>prototype</filename> files)</para>
</listitem><listitem><para>Optional information files</para>
</listitem><listitem><para>Optional installation scripts</para>
</listitem>
</itemizedlist><para>The following figure describes the contents of a package.</para><figure id="ch1designpkg-fig-1"><title id="ch1designpkg-17188">The Contents
of a Package</title><mediaobject><imageobject><imagedata entityref="fig53.epsi"/>
</imageobject><textobject><simpara>The preceding context and the following context describe
the graphic.</simpara>
</textobject>
</mediaobject>
</figure><sect2 id="ch1designpkg-2"><title>Required Package Components</title><para><indexterm id="ch1designpkg-ix5"><primary>package components</primary><secondary>required</secondary></indexterm><indexterm id="ch1designpkg-ix6"><primary>package</primary><secondary>required components</secondary></indexterm><indexterm id="ch1designpkg-ix7"><primary>package</primary><secondary>object</secondary></indexterm>You must create the following components before you build your
package: </para><itemizedlist><listitem><para>Package objects </para><para>These components make up the
application. They can consist of the following items:</para><itemizedlist><listitem><para>Files (executable files or data files)</para>
</listitem><listitem><para>Directories</para>
</listitem><listitem><para>Named pipes </para>
</listitem><listitem><para>Links</para>
</listitem><listitem><para>Devices</para>
</listitem>
</itemizedlist>
</listitem><listitem><para>The <filename>pkginfo</filename> file </para><para><indexterm id="ch1designpkg-ix8"><primary><filename>pkginfo</filename> file</primary><secondary>description</secondary></indexterm>The <filename>pkginfo</filename> file
is a required package information file that defines parameter values. Parameter
values include the package abbreviation, the full package name, and the package
architecture. For more information, see <olink targetptr="ch2buildpkg-11300" remap="internal">Creating
a pkginfo File</olink> and the <olink targetdoc="refman4" targetptr="pkginfo-4" remap="external"><citerefentry><refentrytitle>pkginfo</refentrytitle><manvolnum>4</manvolnum></citerefentry></olink> man
page. </para><note><para>There are two <olink targetdoc="refman1" targetptr="pkginfo-1" remap="external"><citerefentry><refentrytitle>pkginfo</refentrytitle><manvolnum>1</manvolnum></citerefentry></olink> man
pages. The first man page describes a section 1 command that displays information
about installed packages. The second man page describes a section 4 file that
describes the characteristics of a package. When accessing the man pages,
be sure to specify the applicable man page section. For example:  <command>man
-s 4 pkginfo</command>.</para>
</note>
</listitem><listitem><para>The <filename>prototype</filename> file </para><para>The <filename>prototype</filename> file is a required package information file that lists
the components of the package. One entry exists for each package object, information
file, and installation script. An entry consists of several fields of information
that describe each component, including its location, attributes, and file
type. For more information, see <olink targetptr="ch2buildpkg-16803" remap="internal">Creating
a prototype File</olink> and the <olink targetdoc="refman4" targetptr="prototype-4" remap="external"><citerefentry><refentrytitle>prototype</refentrytitle><manvolnum>4</manvolnum></citerefentry></olink> man page.</para>
</listitem>
</itemizedlist>
</sect2><sect2 id="ch1designpkg-3"><title>Optional Package Components</title><indexterm id="ch1designpkg-ix10"><primary>package components</primary><secondary>optional</secondary>
</indexterm><indexterm id="ch1designpkg-ix11"><primary>package</primary><secondary>optional components</secondary>
</indexterm><sect3 id="ch1designpkg-12793"><title>Package Information Files</title><para>You can include four optional package information files in your package: </para><itemizedlist><listitem><para><indexterm id="ch1designpkg-ix12"><primary><filename>compver</filename> file</primary></indexterm>The <filename>compver</filename> file </para><para>Defines
previous versions of the package that are compatible with this version of
your package. </para>
</listitem><listitem><para><indexterm id="ch1designpkg-ix13"><primary><filename>depend</filename> file</primary></indexterm>The <filename>depend</filename> file </para><para>Indicates
other packages that have a special relationship with your package. </para>
</listitem><listitem><para><indexterm id="ch1designpkg-ix14"><primary><filename>space</filename> file</primary></indexterm>The <filename>space</filename> file </para><para>Defines
disk space requirements for the target environment, beyond what is required
by the objects defined in the <filename>prototype</filename> file. For example,
additional space might be needed for files that are dynamically created at
installation time. </para>
</listitem><listitem><para><indexterm id="ch1designpkg-ix15"><primary><filename>copyright</filename> file</primary></indexterm>The <filename>copyright</filename> file </para><para>Defines
the text for a copyright message that displays at the time of package installation. </para>
</listitem>
</itemizedlist><para>Each package information file should have an entry in the <filename>prototype</filename> file. See <olink targetptr="ch3enhancepkg-31830" remap="internal">Creating Information
Files</olink> for more information on creating these files.</para>
</sect3><sect3 id="ch1designpkg-4"><title>Package Installation Scripts</title><indexterm id="ch1designpkg-ix16"><primary>installation scripts</primary><secondary>characteristics</secondary>
</indexterm><para>Installation scripts are not required. However, you can provide scripts
that perform customized actions during the installation of your package. An
installation script has the following characteristics:</para><itemizedlist><listitem><para>The script is composed of Bourne shell commands.</para>
</listitem><listitem><para>The script's file permissions should be set to 0644.</para>
</listitem><listitem><para>The script does not need to contain the shell identifier (<literal>#! /bin/sh</literal>).</para>
</listitem>
</itemizedlist><para><indexterm><primary>installation scripts</primary><secondary>types of</secondary></indexterm>The four script types are as follows:</para><itemizedlist><listitem><para>The <filename>request</filename> script </para><para><indexterm><primary><filename>request</filename> script</primary></indexterm>The <filename>request</filename> script requests input from the administrator who is installing
the package.</para>
</listitem><listitem><para>The <filename>checkinstall</filename> script</para><para><indexterm><primary><filename>checkinstall</filename> script</primary></indexterm>The <filename>checkinstall</filename> script performs special file system verification.</para><note><para>The <filename>checkinstall</filename> script is only available
with the <trademark>Solaris</trademark> 2.5 release and compatible releases.</para>
</note>
</listitem><listitem><para><indexterm><primary>procedure scripts</primary></indexterm>Procedure
scripts</para><para><indexterm><primary>procedure scripts</primary><secondary>predefined names of</secondary></indexterm><firstterm>Procedure scripts</firstterm> define
actions that occur at particular points during package installation and removal.
You can create four procedure scripts with these predefined names: <filename>preinstall</filename>, <filename>postinstall</filename>, <filename>preremove</filename>,
and <filename>postremove</filename>.</para>
</listitem><listitem><para><indexterm><primary>class action script</primary></indexterm>Class
action scripts</para><para><firstterm>Class action scripts</firstterm> define
a set of actions to be performed on a group of objects.</para>
</listitem>
</itemizedlist><para>See <olink targetptr="ch3enhancepkg-10289" remap="internal">Creating Installation Scripts</olink> for
a more information on installation scripts.</para>
</sect3>
</sect2>
</sect1><sect1 id="ch1designpkg-28244"><title>Considerations Before Building a Package</title><para><indexterm id="ch1designpkg-ix17"><primary>packaging guidelines</primary></indexterm>Before building a package, you need to decide whether your product
will consist of one or more packages. Note that many small packages take longer
to install than one big package. Although creating a single package is a good
idea, doing so is not always possible. If you decide to build more than one
package, you need to determine how to segment the application code. This section
provides a list of criteria to use when planning to build a package.</para><para>Many of the packaging criteria present trade-offs among themselves.
Satisfying all requirements equally is often difficult. These criteria are
presented in order of importance. However, this sequence is meant to serve
as a flexible guide depending on the circumstances. Although each criterion
is important, it is up to you to optimize these requirements to produce a
good set of packages.</para><para>For more design ideas, see <olink targetptr="ch6advtech-96543" remap="internal">Chapter&nbsp;6,
Advanced Techniques for Creating Packages</olink>.</para><sect2 id="ch1designpkg-14"><title>Make Packages Remotely Installable</title><para>All packages must be <emphasis>remotely installable</emphasis>. Being
remotely installable means that the administrator installing your package
might be trying to install it on a client system, not necessarily to the root
(<literal>/</literal>) file system where the <command>pkgadd</command> command
is being executed.</para>
</sect2><sect2 id="ch1designpkg-5"><title>Optimize for Client-Server Configurations</title><para>Consider the various types of system software configurations (for example,
standalone system and server) when laying out packages. Good packaging design
divides the affected files to optimize installation of each configuration
type. For example, the contents of the root (<literal>/</literal>) and <literal>/usr</literal> file systems should be segmented so that server configurations
can easily be supported.</para>
</sect2><sect2 id="ch1designpkg-6"><title>Package by Functional Boundaries</title><para>Packages should be self-contained and distinctly identified with a set
of functionality. For example, a package that contains UFS should contain
all UFS utilities and be limited to only UFS binaries. </para><para>Packages should be organized from a customer's point of view into functional
units.</para>
</sect2><sect2 id="ch1designpkg-7"><title>Package Along Royalty Boundaries</title><para>Put code that requires royalty payments due to contractual agreements
in a dedicated package or group of packages. Do not disperse the code into
more packages than necessary. </para>
</sect2><sect2 id="ch1designpkg-8"><title>Package by System Dependencies</title><para>Keep system-dependent binaries in dedicated packages. For example, the
kernel code should be in a dedicated package, with each implementation architecture
consisting of a distinct package instance. This rule also applies to binaries
for different architectures. For example, binaries for a SPARC system would
be in one package and binaries for an x86 system would be in another package.</para>
</sect2><sect2 id="ch1designpkg-9"><title>Eliminate Overlap in Packages</title><para>When constructing packages, eliminate duplicate files whenever possible.
Unnecessary duplication of files results in support and version difficulties.
If your product has multiple packages, repeatedly compare the contents of
these packages for duplicated files.</para>
</sect2><sect2 id="ch1designpkg-11"><title>Package Along Localization Boundaries</title><para>Localization-specific items should be in their own package. An ideal
packaging model would have a product's localizations delivered as one package
per locale. Unfortunately, in some cases organizational boundaries conflict with the functional and product boundaries criteria. </para><para>International defaults can also be delivered in a package. This design
isolates the files that are necessary for localization changes and standardizes
the delivery format of localization packages.</para>
</sect2>
</sect1><sect1 id="gheph"><title>Image Packaging System (IPS) Packages</title><para><indexterm><primary>Image Packaging System</primary></indexterm><indexterm><primary>IPS packages</primary></indexterm>This document discusses SVR4 packages.
For delivery into the OpenSolaris operating environment, consider using Image
Packaging System (IPS) packages. OpenSolaris supports both SVR4 and IPS packages.
The IPS software interacts with network repositories and uses the ZFS file
system. In the OpenSolaris environment, you can publish existing SVR4 packages
to an IPS repository with the <literal>pkgsend(1)</literal> command.</para><para>The following table contains a comparison of commands for the SVR4 packaging
system and the IPS packaging system. For detailed information on IPS, see <ulink url="http://dlc.sun.com/osol/docs/content/IPS/ggcph.html" type="text_url">Getting
Started With the Image Packaging System</ulink>.</para><table frame="topbot" id="gheuh"><title>Packaging Tasks: IPS and SVR4</title><tgroup cols="3" colsep="0" rowsep="0"><colspec colwidth="33*"/><colspec colwidth="33*"/><colspec colwidth="33*"/><thead><row><entry valign="top"><para>Task</para>
</entry><entry valign="top"><para>IPS command</para>
</entry><entry valign="top"><para>SVR4 command</para>
</entry>
</row>
</thead><tbody><row><entry><para>Install a new package</para>
</entry><entry><para><literal>pkg install</literal></para>
</entry><entry><para><literal>pkgadd -a</literal></para>
</entry>
</row><row><entry><para>Display information about a package's state</para>
</entry><entry><para><literal>pkg list</literal></para>
</entry><entry><para><literal>pkginfo</literal></para>
</entry>
</row><row><entry><para>Verify correct installation of a package</para>
</entry><entry><para><literal>pkg verify</literal></para>
</entry><entry><para><literal>pkgchk -v</literal></para>
</entry>
</row><row><entry><para>Display information about a package</para>
</entry><entry><para><literal>pkg info</literal></para>
</entry><entry><para><literal>pkginfo -l</literal></para>
</entry>
</row><row><entry><para>Listing the contents of a package</para>
</entry><entry><para><literal>pkg contents</literal></para>
</entry><entry><para><literal>pkgchk -l</literal></para>
</entry>
</row><row><entry><para>Uninstall a package</para>
</entry><entry><para><literal>pkg uninstall</literal></para>
</entry><entry><para><literal>pkgrm</literal></para>
</entry>
</row>
</tbody>
</tgroup>
</table>
</sect1><sect1 id="ch1designpkg-21979"><title>Packaging Commands, Files, and Scripts</title><para>This section describes the commands, files, and scripts that you might
use when manipulating packages. They are described in man pages and in detail
throughout this book, in relation to the specific task they perform.</para><para><indexterm><primary>package</primary><secondary>commands</secondary></indexterm>The following table shows the commands to help you build, verify,
install, and obtain information about a package.</para><table frame="topbot" pgwide="1" id="ch1designpkg-tbl-12"><title>Packaging
Commands</title><tgroup cols="4" colsep="0" rowsep="0"><colspec colwidth="72*"/><colspec colname="column1" colwidth="82*"/><colspec colname="column2" colwidth="97*"/><colspec colname="column3" colwidth="144*"/><thead><row rowsep="1"><entry><para>Task</para>
</entry><entry><para>Command/ man Page</para>
</entry><entry><para>Description</para>
</entry><entry><para>For More Information</para>
</entry>
</row>
</thead><tbody><row><entry><para>Create packages</para>
</entry><entry><para><olink targetdoc="refman1" targetptr="pkgproto-1" remap="external"><citerefentry><refentrytitle>pkgproto</refentrytitle><manvolnum>1</manvolnum></citerefentry></olink></para>
</entry><entry><para>Generates a <filename>prototype</filename> file for input to the <command>pkgmk</command> command</para>
</entry><entry><para><olink targetptr="ch2buildpkg-35610" remap="internal">Example&mdash;Creating a prototype
File With the pkgproto Command</olink></para>
</entry>
</row><row rowsep="1"><entry><para><olink targetdoc="refman1" targetptr="pkgmk-1" remap="external"><citerefentry><refentrytitle>pkgmk</refentrytitle><manvolnum>1</manvolnum></citerefentry></olink></para>
</entry><entry><para>Creates an installable package</para>
</entry><entry><para><olink targetptr="ch2buildpkg-17051" remap="internal">Building a Package</olink></para>
</entry><entry><para></para>
</entry>
</row><row><entry><para>Install, remove, and transfer packages</para>
</entry><entry><para><olink targetdoc="refman1m" targetptr="pkgadd-1m" remap="external"><citerefentry><refentrytitle>pkgadd</refentrytitle><manvolnum>1M</manvolnum></citerefentry></olink></para>
</entry><entry><para>Installs a software package onto a system</para>
</entry><entry><para><olink targetptr="ch4verifypkg-2" remap="internal">Installing Software Packages</olink></para>
</entry>
</row><row><entry><para><olink targetdoc="refman1m" targetptr="pkgask-1m" remap="external"><citerefentry><refentrytitle>pkgask</refentrytitle><manvolnum>1M</manvolnum></citerefentry></olink></para>
</entry><entry><para>Stores answers to a <command>request</command> script</para>
</entry><entry><para><olink targetptr="ch3enhancepkg-25" remap="internal">Design Rules for request Scripts</olink></para>
</entry><entry><para></para>
</entry>
</row><row><entry><para><olink targetdoc="refman1" targetptr="pkgtrans-1" remap="external"><citerefentry><refentrytitle>pkgtrans</refentrytitle><manvolnum>1</manvolnum></citerefentry></olink></para>
</entry><entry><para>Copies packages onto a distribution medium</para>
</entry><entry><para><olink targetptr="ch4verifypkg-32" remap="internal">Transferring a Package to a Distribution
Medium</olink></para>
</entry><entry><para></para>
</entry>
</row><row rowsep="1"><entry><para><olink targetdoc="refman1m" targetptr="pkgrm-1m" remap="external"><citerefentry><refentrytitle>pkgrm</refentrytitle><manvolnum>1M</manvolnum></citerefentry></olink></para>
</entry><entry><para>Removes a package from a system</para>
</entry><entry><para><olink targetptr="ch4verifypkg-34" remap="internal">Removing a Package</olink></para>
</entry><entry><para></para>
</entry>
</row><row><entry><para>Obtain information about packages</para>
</entry><entry><para><olink targetdoc="refman1m" targetptr="pkgchk-1m" remap="external"><citerefentry><refentrytitle>pkgchk</refentrytitle><manvolnum>1M</manvolnum></citerefentry></olink></para>
</entry><entry><para>Verifies the integrity of a software package</para>
</entry><entry><para><olink targetptr="ch4verifypkg-39428" remap="internal">Verifying the Integrity of a Package</olink></para>
</entry>
</row><row><entry><para><olink targetdoc="refman1" targetptr="pkginfo-1" remap="external"><citerefentry><refentrytitle>pkginfo</refentrytitle><manvolnum>1</manvolnum></citerefentry></olink></para>
</entry><entry><para>Displays software package information</para>
</entry><entry><para><olink targetptr="ch4verifypkg-36" remap="internal">The pkginfo Command</olink></para>
</entry><entry><para></para>
</entry>
</row><row rowsep="1"><entry><para><olink targetdoc="refman1" targetptr="pkgparam-1" remap="external"><citerefentry><refentrytitle>pkgparam</refentrytitle><manvolnum>1</manvolnum></citerefentry></olink></para>
</entry><entry><para>Displays package parameter values</para>
</entry><entry><para><olink targetptr="ch4verifypkg-51186" remap="internal">The pkgparam Command</olink></para>
</entry><entry><para></para>
</entry>
</row><row><entry><para>Modify installed packages</para>
</entry><entry><para><olink targetdoc="refman1m" targetptr="installf-1m" remap="external"><citerefentry><refentrytitle>installf</refentrytitle><manvolnum>1M</manvolnum></citerefentry></olink></para>
</entry><entry><para>Incorporates a new package object into an already installed package</para>
</entry><entry><para><olink targetptr="ch3enhancepkg-28" remap="internal">Design Rules for Procedure Scripts</olink> and <olink targetptr="ch5pkgcasestudies-80583" remap="internal">Chapter&nbsp;5, Case Studies of Package
Creation</olink></para>
</entry>
</row><row><entry><para><olink targetdoc="refman1m" targetptr="removef-1m" remap="external"><citerefentry><refentrytitle>removef</refentrytitle><manvolnum>1M</manvolnum></citerefentry></olink></para>
</entry><entry><para>Removes a package object from an already installed package</para>
</entry><entry><para><olink targetptr="ch3enhancepkg-28" remap="internal">Design Rules for Procedure Scripts</olink> </para>
</entry><entry><para></para>
</entry>
</row>
</tbody>
</tgroup>
</table><para><indexterm><primary>package</primary><secondary>information files</secondary></indexterm>The following table shows the information files that help you
build a package.</para><table frame="topbot" id="ch1designpkg-34222"><title>Package Information Files</title><tgroup cols="3" colsep="0" rowsep="0"><colspec colname="column1" colwidth="101*"/><colspec colname="column2" colwidth="203*"/><colspec colname="column3" colwidth="152*"/><thead><row rowsep="1"><entry><para>File</para>
</entry><entry><para>Description</para>
</entry><entry><para>For More Information</para>
</entry>
</row>
</thead><tbody><row><entry><para><olink targetdoc="refman4" targetptr="admin-4" remap="external"><citerefentry><refentrytitle>admin</refentrytitle><manvolnum>4</manvolnum></citerefentry></olink></para>
</entry><entry><para>Package installation defaults file</para>
</entry><entry><para><olink targetptr="ch6advtech-34" remap="internal">The Administrative Defaults File</olink></para>
</entry>
</row><row><entry><para><olink targetdoc="refman4" targetptr="compver-4" remap="external"><citerefentry><refentrytitle>compver</refentrytitle><manvolnum>4</manvolnum></citerefentry></olink></para>
</entry><entry><para>Package compatibility file</para>
</entry><entry><para><olink targetptr="ch3enhancepkg-28289" remap="internal">Defining Package Dependencies</olink></para>
</entry>
</row><row><entry><para><olink targetdoc="refman4" targetptr="copyright-4" remap="external"><citerefentry><refentrytitle>copyright</refentrytitle><manvolnum>4</manvolnum></citerefentry></olink></para>
</entry><entry><para>Package copyright information file</para>
</entry><entry><para><olink targetptr="ch3enhancepkg-32564" remap="internal">Writing a Copyright Message</olink></para>
</entry>
</row><row><entry><para><olink targetdoc="refman4" targetptr="depend-4" remap="external"><citerefentry><refentrytitle>depend</refentrytitle><manvolnum>4</manvolnum></citerefentry></olink></para>
</entry><entry><para>Package dependencies file</para>
</entry><entry><para><olink targetptr="ch3enhancepkg-28289" remap="internal">Defining Package Dependencies</olink></para>
</entry>
</row><row><entry><para><olink targetdoc="refman4" targetptr="pkginfo-4" remap="external"><citerefentry><refentrytitle>pkginfo</refentrytitle><manvolnum>4</manvolnum></citerefentry></olink></para>
</entry><entry><para>Package characteristics file</para>
</entry><entry><para><olink targetptr="ch2buildpkg-11300" remap="internal">Creating a pkginfo File</olink></para>
</entry>
</row><row><entry><para><olink targetdoc="refman4" targetptr="pkgmap-4" remap="external"><citerefentry><refentrytitle>pkgmap</refentrytitle><manvolnum>4</manvolnum></citerefentry></olink></para>
</entry><entry><para>Package contents description file</para>
</entry><entry><para><olink targetptr="ch2buildpkg-10222" remap="internal">The pkgmap File</olink></para>
</entry>
</row><row><entry><para><olink targetdoc="refman4" targetptr="prototype-4" remap="external"><citerefentry><refentrytitle>prototype</refentrytitle><manvolnum>4</manvolnum></citerefentry></olink></para>
</entry><entry><para>Package information file</para>
</entry><entry><para><olink targetptr="ch2buildpkg-16803" remap="internal">Creating a prototype File</olink></para>
</entry>
</row><row><entry><para><olink targetdoc="refman4" targetptr="space-4" remap="external"><citerefentry><refentrytitle>space</refentrytitle><manvolnum>4</manvolnum></citerefentry></olink></para>
</entry><entry><para>Package disk space requirements file</para>
</entry><entry><para><olink targetptr="ch3enhancepkg-10245" remap="internal">Reserving Additional Space on
a Target System</olink></para>
</entry>
</row>
</tbody>
</tgroup>
</table><para><indexterm><primary>package</primary><secondary>installation scripts</secondary></indexterm>The following table describes optional installation scripts that
you can write that affect if and how a package is installed.</para><table frame="topbot" id="ch1designpkg-26841"><title>Package Installation
Scripts</title><tgroup cols="3" colsep="0" rowsep="0"><colspec colname="column1" colwidth="101*"/><colspec colname="column2" colwidth="203*"/><colspec colname="column3" colwidth="152*"/><thead><row rowsep="1"><entry><para>Script</para>
</entry><entry><para>Description</para>
</entry><entry><para>For More Information</para>
</entry>
</row>
</thead><tbody><row><entry><para><filename>request</filename></para>
</entry><entry><para>Solicits information from the installer</para>
</entry><entry><para><olink targetptr="ch3enhancepkg-21209" remap="internal">Writing a request Script</olink></para>
</entry>
</row><row><entry><para><filename>checkinstall</filename></para>
</entry><entry><para>Gathers file system data</para>
</entry><entry><para><olink targetptr="ch3enhancepkg-21872" remap="internal">Gathering File System Data With
the checkinstall Script</olink></para>
</entry>
</row><row><entry><para><filename>preinstall</filename></para>
</entry><entry><para>Performs any custom installation requirements before class installation</para>
</entry><entry><para><olink targetptr="ch3enhancepkg-14637" remap="internal">Writing Procedure Scripts</olink></para>
</entry>
</row><row><entry><para><filename>postinstall</filename></para>
</entry><entry><para>Performs any custom installation requirements after all volumes are
installed</para>
</entry><entry><para><olink targetptr="ch3enhancepkg-14637" remap="internal">Writing Procedure Scripts</olink></para>
</entry>
</row><row><entry><para><filename>preremove</filename></para>
</entry><entry><para>Performs any custom removal requirements before class removal</para>
</entry><entry><para><olink targetptr="ch3enhancepkg-14637" remap="internal">Writing Procedure Scripts</olink></para>
</entry>
</row><row><entry><para><filename>postremove</filename></para>
</entry><entry><para>Performs any custom removal requirements after all classes have been
removed</para>
</entry><entry><para><olink targetptr="ch3enhancepkg-14637" remap="internal">Writing Procedure Scripts</olink></para>
</entry>
</row><row><entry><para>Class action</para>
</entry><entry><para>Performs a series of actions on a specific group of objects</para>
</entry><entry><para><olink targetptr="ch3enhancepkg-37319" remap="internal">Writing Class Action Scripts</olink></para>
</entry>
</row>
</tbody>
</tgroup>
</table>
</sect1>
</chapter><?Pub *0000031941 0?>