.\" .\" CDDL HEADER START .\" .\" The contents of this file are subject to the terms of the .\" Common Development and Distribution License (the "License"). .\" You may not use this file except in compliance with the License. .\" .\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE .\" or http://www.opensolaris.org/os/licensing. .\" See the License for the specific language governing permissions .\" and limitations under the License. .\" .\" When distributing Covered Code, include this CDDL HEADER in each .\" file and include the License file at usr/src/OPENSOLARIS.LICENSE. .\" If applicable, add the following below this CDDL HEADER, with the .\" fields enclosed by brackets "[]" replaced with your own identifying .\" information: Portions Copyright [yyyy] [name of copyright owner] .\" .\" CDDL HEADER END .\" Copyright 1989 AT&T .\" Copyright (c) 2004, Sun Microsystems, Inc. All Rights Reserved .\" Portions Copyright (c) 2007 Gunnar Ritter, Freiburg i. Br., Germany .\" .\" Sccsid @(#)pkgmap.5 1.8 (gritter) 2/25/07 .\" .\" from OpenSolaris pkgmap 4 "12 Jul 2006" "SunOS 5.11" "File Formats" .TH PKGMAP 5 "2/25/07" "Heirloom Packaging Tools" "File Formats" .SH NAME pkgmap \- package contents description file .SH DESCRIPTION \fBpkgmap\fR is an \fBASCII\fR file that provides a complete listing of the package contents. It is automatically generated by .IR pkgmk (1) using the information in the .IR prototype (5) file. .PP Each entry in \fBpkgmap\fR describes a single ``deliverable object file.'' A deliverable object file includes shell scripts, executable objects, data files, directories, and so forth. The entry consists of several fields of information, each field separated by a space. The fields are described below and must appear in the order shown. .TP 10 \fB\fIpart\fR An optional field designating the part number in which the object resides. A part is a collection of files and is the atomic unit by which a package is processed. A developer can choose the criteria for grouping files into a part (for example, based on class). If no value is defined in this field, part 1 is assumed. .TP \fB\fIftype\fR A one-character field that indicates the file type. Valid values are listed below. File types are divided between those that are not to be modified and those that are modifiable. Files of the following types must never be modified: .RS 14 .TP .PD 0 .B b block special device .TP .B c character special device .TP .B d directory .TP .B f a standard executable file, data file, or other type of file, the contents of which must never be modified. .TP .B i information file (such as a file containing a copyright, list of dependencies, or package information) or installation script (such as checkinstall, class action [\fBi.\fR], pre/post install/remove), the contents of which must never be modified. .TP .B l linked file .TP .B p named pipe .TP .B s symbolic link .TP .B x an exclusive directory accessible only by this package .PD .RE .IP Files of the following types can be modified: .RS 14 .TP .PD 0 .B e An editable file, intended to be edited (selectively modified) after installation. An editable file is expected to change on installation or removal, can be shared by several packages, and must be installed by a class action script. Examples are a configuration file or a list of users. .TP .B v A volatile file, intended to be overwritten or appended to after installation. A volatile file is not expected to change on installation or removal, is not preserved between installations, and can be installed by a class action script. Examples are a log file or a lock file. .RE .PD .IP Following package installation, the contents of files of all types except \fBe\fR and \fBv\fR must not change. Any file that is subject to change should be marked as \fBe\fR or \fBv\fR. .TP \fB\fIclass\fR The installation class to which the file belongs. This name must contain only alphanumeric characters and be no longer than 12 characters. It is not specified if the \fIftype\fR is \fBi\fR (information file). .TP \fB\fIpathname\fR \fIpathname\fR may contain variables of the form \fB$\fR\fIvariable\fR that support install-time configuration of the file. \fIvariable\fR may be embedded in the pathname structure. (See .IR prototype (5) for definitions of variable specifications.) .IP Do not use the following reserved words in \fIpathname\fR, since they are applied by .IR pkgadd (1M) using a different mechanism: .sp .RS 14 .nf PKG_INSTALL_ROOT BASEDIR CLIENT_BASEDIR .fi .RE .TP \fB\fImajor\fR The major device number. The field is only specified for block or character special devices. .TP \fB\fIminor\fR The minor device number. The field is only specified for block or character special devices. .TP \fB\fImode\fR The octal mode of the file (for example, 0664). A question mark (\fB?\fR) indicates that the mode will be left unchanged, implying that the file already exists on the target machine. This field is not used for linked files, packaging information files, or non-installable files. .IP The mode can contain a variable specification. (See .IR prototype (5) for definitions of variable specifications.) .TP \fB\fIowner\fR The owner of the file (for example, \fBbin\fR or \fBroot\fR). The field is limited to 14 characters in length. A question mark (\fB?\fR) indicates that the owner will be left unchanged or changed to the owner stored in the package database, which could be different from what is on the file system. When the question mark is used, it implies that the file is already on the file system. This field is not used for linked files or non-installable files. It is used optionally with a package information file. If used, it indicates with what owner an installation script will be executed. .IP The owner can contain a variable specification. (See .IR prototype (5) for definitions of variable specifications.) .TP \fB\fIgroup\fR The group to which the file belongs (for example, \fBbin\fR or \fBsys\fR). The field is limited to 14 characters in length. A question mark (\fB?\fR) indicates that the group will be left unchanged or changed to the owner stored in the package database, which could be different from what is on the file system. When the question mark is used, it implies that the file is already on the file system. This field is not used for linked files or non-installable files. It is used optionally with a package information file. If used, it indicates with what group an installation script will be executed. .IP The group can contain a variable specification. (See .IR prototype (5) for definitions of variable specifications.) .TP \fB\fIsize\fR The actual size of the file in bytes. This field is not specified for named pipes, special devices, directories or linked files. .TP \fB\fIcksum\fR The checksum of the file contents. This field is not specified for named pipes, special devices, directories, or linked files. .TP \fB\fImodtime\fR The time of last modification, as reported by the .IR stat (2) function call. This field is not specified for named pipes, special devices, directories, or linked files. .PP Each \fBpkgmap\fR file must have one line that provides information about the number of parts, maximum size of parts that make up the package, and, optionally, the size of the package after compression (where size is given in 512-byte blocks). This line is in the following format: .RS .sp \fB:\fR \fInumber_of_parts\fR \fImaximum_part_size\fR \fIcompressed_pkg_size\fR .sp .RE Lines that begin with ``\fB#\fR'' are comment lines and are ignored. .PP When files are saved during installation before they are overwritten, they are normally just copied to a temporary pathname. However, for files whose mode includes execute permission (but which are not editable), the existing version is linked to a temporary pathname and the original file is removed. This allows processes which are executing during installation to be overwritten. .SH EXAMPLES \fBExample 1 \fRA Sample \fBpkgmap\fR File .LP .RS .nf \fB: 2 500 1 i pkginfo 237 1179 541296672 1 b class1 /dev/diskette 17 134 0644 root other 1 c class1 /dev/rdiskette 17 134 0644 root other 1 d none bin 0755 root bin 1 f none bin/INSTALL 0755 root bin 11103 17954 541295535 1 f none bin/REMOVE 0755 root bin 3214 50237 541295541 1 l none bin/UNINSTALL=bin/REMOVE 1 f none bin/cmda 0755 root bin 3580 60325 541295567 1 f none bin/cmdb 0755 root bin 49107 51255 541438368 1 f class1 bin/cmdc 0755 root bin 45599 26048 541295599 1 f class1 bin/cmdd 0755 root bin 4648 8473 541461238 1 f none bin/cmde 0755 root bin 40501 1264 541295622 1 f class2 bin/cmdf 0755 root bin 2345 35889 541295574 1 f none bin/cmdg 0755 root bin 41185 47653 541461242 2 d class2 data 0755 root bin 2 p class1 data/apipe 0755 root other 2 d none log 0755 root bin 2 v none log/logfile 0755 root bin 41815 47563 541461333 2 d none save 0755 root bin 2 d none spool 0755 root bin 2 d none tmp 0755 root bin\fR .fi .RE .SH SEE ALSO .IR pkgmk (1), .IR pkgadd (1M), .IR stat (2), .IR pkginfo (5), .IR prototype (5) .SH NOTES The \fBpkgmap\fR file may contain only one entry per unique pathname.