HP-UX Reference (11i v1 05/09) - 4 File Formats (vol 8)
s
swpackage(4) swpackage(4)
(HP-UX Software Distributor)
-g [
group[,]][gid
]
Defines the destination file’s group name and/or or gid. If only the group is specified, the group
and gid attributes are set for the destination file object, based on the packaging host’s
/etc/group . If only the group is specified, and it contains digits only, it is interpreted as the
gid, and is set as the gid attribute for the destination object; no group name is assigned to the
object. If both are specified, each sets the corresponding attribute for the file object. During an
installation, the group attribute is used to set the group name and gid, unless the group name is
not defined in the target system’s
/etc/group . In this case, the gid attribute is used to set
the gid.
-t type [ mode_options ] source [
filename ]
Defines a file of type
d (directory), s (symbolic), or h (hard link). (Files do not need exist before
packaging.) For links, both source and path are required. For hard links, the source must exist
as a regular file elsewhere in the fileset. If the source and path both exist, then attributes from
the source are used in the target path, unless redefined by the mode_options.
-v Marks the file as volatile, meaning it can be modified (i.e. deleted) after installed without
impacting the fileset.
When processing existing files in a source directory, a number of problems may be encountered. Errors or
warning messages are printed for each problem. (The
swpackage command terminates when errors are
encountered in reading the PSF or accessing the source files.)
Default Permission Specification
By default, a destination file object will inherit the mode, owner, and group of the source file. The
file_permissions keyword can be specified to set a default permission umask/mode, owner, and
group for all the files being packaged into the fileset. This includes files specified by -t that do not exist
before packaging. (See the EXAMPLES section for sample permission specifications.)
file_permissions [-m
mode|-u umask][-o[owner[,]][uid]] \
[-g[
group[,]][gid]] [-t type]
file_permissions
Applies only to the fileset it is defined in. Multiple file_permissions
can be specified,
later definitions simply replace previous definitions.
-m mode
Defines a default (octal) mode for all file objects.
-u umask
Instead of specifying an octal mode as the default, the user can specify an octal umask(1) value
which gets "subtracted" from an existing source file’s mode to generate the mode of the destina-
tion file.
By specifying a
umask, the user can set a default mode for executable files, non-executable files,
and directories. (A specific mode can be set for any file, as described above.)
-o [owner[,]][uid]
Defines the destination file’s owner name and/or or uid (as defined above).
-g [group[,]][gid]
Defines the destination file’s group name and/or or gid (as defined above).
-t type [ mode_options ] source [ filename ]
Defines a file of type d (directory), s (symbolic), or h (hard link). (Files do not need to exist
before packaging.) For links, both source and path are required. For hard links, the source must
exist as a regular file elsewhere in the fileset. If the source and path both exist, then attributes
from the source are used in the target path, unless redefined by the mode_options.
PSF Extensions
A PSF can contain extended file definitions. SD currently supports exclude and include files.
Exclude files let you explicitly exclude files that would otherwise be included in the PSF. The syntax is:
exclude filename
An exclude file can only be specified after a file definition. The file listed after the exclude keyword is
excluded from the current context (for example, from a recursive file definition or wildcard).
Section 4−−310 Hewlett-Packard Company − 22 − HP-UX 11i Version 1: September 2005