Application Packaging Developer's Guide


In order to support this new class archive format, three new interfaces in the form of keywords have special meaning within the pkginfo file. These keywords are used to designate classes requiring special treatment. The format of each keyword statement is: keyword=class1[class2 class3 ...]. Each keyword values are defined in the following table.




This tells pkgadd not to verify the existence and properties of the files in the delivered package's reloc or root directories if they belong to the named class. This is required for all archived classes, because those files are no longer in a reloc or root directory. They are a private format file in the archive directory.


The files in these classes are verified after installation using a quick algorithm with little to no text output. The quick verify first sets each file's attributes correctly and then checks to see if the operation succeeded. There is then a test of the file size and modification time against the pkgmap. No checksum verification is performed and there is poorer error recovery than that provided by the standard verification mechanism. In the event of a power outage or disk failure during installation, the contents file may be inconsistent with the installed files. This inconsistency can always be resolved with a pkgrm.


Normally the install class action script receives from stdin a list of source and destination pairs telling it which files to install. The classes assigned to PKG_CAS_PASSRELATIVE do not get the source and destination pairs. Instead they receive a single list, the first entry of which is the location of the source package and the rest of which are the destination paths. This is specifically for the purpose of simplifying extraction from an archive. From the location of the source package, you can find the archive in the archive directory. The destination paths are then passed to the function responsible for extracting the contents of the archive. Each destination path provided is either absolute or relative to the base directory depending on whether the path was located in root or reloc originally. If this option is chosen, it may be difficult to combine both relative and absolute paths into a single class.

For each archived class a class action script is required. This is a file containing Bourne shell commands which is executed by pkgadd to actually install the files from the archive. If a class action script is found in the install directory of the package, pkgadd turns all responsibility for installation over to that script. The class action script is run with root permissions and can place its files just about anywhere on the target system.

Note –

The only keyword that is absolutely necessary in order to implement a class archive package is PKG_SRC_NOVERIFY. The others may be used to increase installation speed or conserve code.