|
|
Before beginning any packaging procedure, you must first have planned your packaging needs based on the information presented in ``Basic steps of packaging''. This section covers only the required steps.
[volno] ftype class pathname [major minor] [mode owner group] [mac fixed inherited]
volno designates the medium volume number on which the object should be placed. If no volno is given, pkgmk(C) distributes package components across volumes automatically.
ftype must be one of these object file types:
f (standard executable or data file)
e (file to be edited upon installation or removal)
v (volatile file, contents will change)
d (directory)
x (exclusive directory)
l (linked file)
p (named pipe)
c (character special device)
b (block special device)
i (installation script or package information file)
s (symbolic link)
class defines the class to which the object belongs. Place an object into the class of none if no special handling is required.
pathname defines the pathname of an object. It can be in one of these formats:
This pathname defines where the component should reside on the installation medium and also tells pkgmk(C) where to find it on your machine. If these names differ, use the path1``=''path2 format for pathname, where path1 is the name it should have on the installation machine and path2 is the name it has on your machine.
major minor defines the major and minor numbers for a block or character special device.
mode owner group defines the mode, owner and group for the object. If not defined, the value of the default command is used. If no default value is defined, 644 root other is assigned.
You can use four types of command lines in a prototype(F) file:
search pathnames (defines a search path for pkgmk(C) to use when creating your package)
include filename (nests prototype(F) files)
default mode owner group (defines a default mode owner group for objects defined in this prototype(F) file)
param=value (defines parameter values for pkgmk(C))
All command lines must begin with an exclamation point (``!'').
pkgproto [-i] [-c class] [path1[=path2] . . . ] > filename
where -i tells pkgproto(C) to record symbolic links with an ftype of f (not s), -c defines the class of all objects as class, and path1 defines the object pathname (or names) to be included in the prototype file. If path1 is a directory, entries for all objects in that directory will be generated.
Use the path1=path2 format to give an object a different pathname in the prototype(F) file than it has on your machine. path1 is the pathname where objects can be located on your machine and path2 is the pathname that should be substituted for those objects.
pkgproto(C) writes its output to the standard output. To create a file, you should redirect the output to a file. That file can be named prototype (although it is not required).
Use any editor. Define one entry per line per parameter in this format:
PARAM="value"
where PARAM is the name of one of the standard installation parameters defined in the pkginfo(F) manual page and value is the value you assign to it.
You can also define values for your own installation parameters using the same format. Names for parameters that you create must begin with an uppercase letter and be followed by only lowercase letters.
The following five parameters are required in every pkginfo file: PKG, NAME, ARCH, VERSION, and CATEGORY. No other restrictions apply concerning which parameters or how many parameters you define.
The CLASSES parameter dictates which classes are installed and the order of installation. Although the parameter is not required, no classes will be installed without it. Even if you have no class action scripts, the none class must be defined in the CLASSES parameter before objects belonging to that class will be installed.
pkgmk [-d device] [-r rootpath] [-b basedir] [-f filename]where -d specifies that the package should be copied onto device, -r requests that the root directory rootpath be used to locate objects on your machine, -b requests that basedir be prepended to relocatable paths when searching for them on your machine, and -f names a file, filename, to be used as your prototype(F) file. (Other options are described in the pkgmk(C) manual page.)