.\" Automatically generated by Pod::Man v1.37, Pod::Parser v1.32 .\" .\" Standard preamble: .\" ======================================================================== .de Sh \" Subsection heading .br .if t .Sp .ne 5 .PP \fB\\$1\fR .PP .. .de Sp \" Vertical space (when we can't use .PP) .if t .sp .5v .if n .sp .. .de Vb \" Begin verbatim text .ft CW .nf .ne \\$1 .. .de Ve \" End verbatim text .ft R .fi .. .\" Set up some character translations and predefined strings. \*(-- will .\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left .\" double quote, and \*(R" will give a right double quote. | will give a .\" real vertical bar. \*(C+ will give a nicer C++. Capital omega is used to .\" do unbreakable dashes and therefore won't be available. \*(C` and \*(C' .\" expand to `' in nroff, nothing in troff, for use with C<>. .tr \(*W-|\(bv\*(Tr .ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p' .ie n \{\ . ds -- \(*W- . ds PI pi . if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch . if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch . ds L" "" . ds R" "" . ds C` "" . ds C' "" 'br\} .el\{\ . ds -- \|\(em\| . ds PI \(*p . ds L" `` . ds R" '' 'br\} .\" .\" If the F register is turned on, we'll generate index entries on stderr for .\" titles (.TH), headers (.SH), subsections (.Sh), items (.Ip), and index .\" entries marked with X<> in POD. Of course, you'll have to process the .\" output yourself in some meaningful fashion. .if \nF \{\ . de IX . tm Index:\\$1\t\\n%\t"\\$2" .. . nr % 0 . rr F .\} .\" .\" For nroff, turn off justification. Always turn off hyphenation; it makes .\" way too many mistakes in technical documents. .hy 0 .if n .na .\" .\" Accent mark definitions (@(#)ms.acc 1.5 88/02/08 SMI; from UCB 4.2). .\" Fear. Run. Save yourself. No user-serviceable parts. . \" fudge factors for nroff and troff .if n \{\ . ds #H 0 . ds #V .8m . ds #F .3m . ds #[ \f1 . ds #] \fP .\} .if t \{\ . ds #H ((1u-(\\\\n(.fu%2u))*.13m) . ds #V .6m . ds #F 0 . ds #[ \& . ds #] \& .\} . \" simple accents for nroff and troff .if n \{\ . ds ' \& . ds ` \& . ds ^ \& . ds , \& . ds ~ ~ . ds / .\} .if t \{\ . ds ' \\k:\h'-(\\n(.wu*8/10-\*(#H)'\'\h"|\\n:u" . ds ` \\k:\h'-(\\n(.wu*8/10-\*(#H)'\`\h'|\\n:u' . ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'^\h'|\\n:u' . ds , \\k:\h'-(\\n(.wu*8/10)',\h'|\\n:u' . ds ~ \\k:\h'-(\\n(.wu-\*(#H-.1m)'~\h'|\\n:u' . ds / \\k:\h'-(\\n(.wu*8/10-\*(#H)'\z\(sl\h'|\\n:u' .\} . \" troff and (daisy-wheel) nroff accents .ds : \\k:\h'-(\\n(.wu*8/10-\*(#H+.1m+\*(#F)'\v'-\*(#V'\z.\h'.2m+\*(#F'.\h'|\\n:u'\v'\*(#V' .ds 8 \h'\*(#H'\(*b\h'-\*(#H' .ds o \\k:\h'-(\\n(.wu+\w'\(de'u-\*(#H)/2u'\v'-.3n'\*(#[\z\(de\v'.3n'\h'|\\n:u'\*(#] .ds d- \h'\*(#H'\(pd\h'-\w'~'u'\v'-.25m'\f2\(hy\fP\v'.25m'\h'-\*(#H' .ds D- D\\k:\h'-\w'D'u'\v'-.11m'\z\(hy\v'.11m'\h'|\\n:u' .ds th \*(#[\v'.3m'\s+1I\s-1\v'-.3m'\h'-(\w'I'u*2/3)'\s-1o\s+1\*(#] .ds Th \*(#[\s+2I\s-2\h'-\w'I'u*3/5'\v'-.3m'o\v'.3m'\*(#] .ds ae a\h'-(\w'a'u*4/10)'e .ds Ae A\h'-(\w'A'u*4/10)'E . \" corrections for vroff .if v .ds ~ \\k:\h'-(\\n(.wu*9/10-\*(#H)'\s-2\u~\d\s+2\h'|\\n:u' .if v .ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'\v'-.4m'^\v'.4m'\h'|\\n:u' . \" for low resolution devices (crt and lpr) .if \n(.H>23 .if \n(.V>19 \ \{\ . ds : e . ds 8 ss . ds o a . ds d- d\h'-1'\(ga . ds D- D\h'-1'\(hy . ds th \o'bp' . ds Th \o'LP' . ds ae ae . ds Ae AE .\} .rm #[ #] #H #V #F C .\" ======================================================================== .\" .IX Title "OpenBSD::PackingElement 3p" .TH OpenBSD::PackingElement 3p "2008-05-30" "perl v5.8.8" "Perl Programmers Reference Guide" .SH "NAME" OpenBSD::PackingElement \- \f(CWpkg_add(1)\fR packing\-elements object hierarchy .SH "SYNOPSIS" .IX Header "SYNOPSIS" .Vb 4 \& package OpenBSD::PackingElement; \& sub method \& { \& } .Ve .PP .Vb 6 \& package OpenBSD::PackingElement::Depend; \& sub method \& { \& my ($self, @args) = @_; \& # do something \& } .Ve .PP .Vb 2 \& package main; \& use OpenBSD::PackingList; .Ve .PP .Vb 2 \& $plist = OpenBSD::PackingList->fromfile($filename); \& $plist->visit('method', @args); .Ve .SH "DESCRIPTION" .IX Header "DESCRIPTION" \&\f(CW\*(C`OpenBSD::PackingElement\*(C'\fR is the base class for all elements in a packing-list (see \fIOpenBSD::PackingList\fR\|(3p) and \f(CWpkg_create(1)\fR). .PP Manipulation of packing-lists mostly occurs through visitor patterns such as \f(CW\*(C`OpenBSD::PackingList::visit\*(C'\fR: client code defines a method for each relevant class in the hierarchy and calls \f(CW\*(C`$plist\->visit('method')\*(C'\fR to perform the processing. .PP Most actual objects have one property: their \f(CW\*(C`name\*(C'\fR. .IP "::Meta" 4 .IX Item "::Meta" base class for all meta information that can be reordered at will. .RS 4 .IP "::Unique" 4 .IX Item "::Unique" meta information with uniqueness properties. .RS 4 .IP "::Arch" 4 .IX Item "::Arch" architecture requirements. .IP "::ExtraInfo" 4 .IX Item "::ExtraInfo" some unique properties, like \f(CW\*(C`PKGPATH\*(C'\fR and allowed-for-ftp status. .IP "::Name" 4 .IX Item "::Name" the package name. .IP "::LocalBase" 4 .IX Item "::LocalBase" the local base for the package. .IP "::NoDefaultConflict" 4 .IX Item "::NoDefaultConflict" special annotation that package should not have any \f(CW\*(C`stem\-*\*(C'\fR conflict marker. .IP "::SpecialFile" 4 .IX Item "::SpecialFile" special files like the package description or install script. .RS 4 .IP "::FCONTENTS" 4 .IX Item "::FCONTENTS" contents file. .IP "::FCOMMENT" 4 .IX Item "::FCOMMENT" comment file. Deprecated. .IP "::FDESC" 4 .IX Item "::FDESC" package description. .IP "::FREQUIRE" 4 .IX Item "::FREQUIRE" Deprecated. .IP "::FMTREE_DIRS" 4 .IX Item "::FMTREE_DIRS" deprecated .IP "::DisplayFile" 4 .IX Item "::DisplayFile" abstract class for special files that can be displayed. provides method \f(CW\*(C`prepare($state)\*(C'\fR to display the file. .RS 4 .IP "::FDISPLAY" 4 .IX Item "::FDISPLAY" message displayed during package install. .IP "::FUNDISPLAY" 4 .IX Item "::FUNDISPLAY" message displayed during package uninstall. .RE .RS 4 .RE .IP "::ScriptFile" 4 .IX Item "::ScriptFile" abstract class for special files that can be run. provides method \f(CW\*(C`run($state, @args)\*(C'\fR to run the script. .RS 4 .IP "::FINSTALL" 4 .IX Item "::FINSTALL" \&\s-1INSTALL\s0 script. .IP "::FDEINSTALL" 4 .IX Item "::FDEINSTALL" \&\s-1DEINSTALL\s0 script. .IP "::FREQUIRE" 4 .IX Item "::FREQUIRE" \&\s-1REQUIRE\s0 script. .RE .RS 4 .RE .RE .RS 4 .RE .RE .RS 4 .RE .IP "::Option" 4 .IX Item "::Option" factory for \f(CW@option\fR .IP "::Comment" 4 .IX Item "::Comment" comments in the packing\-lists. The constructor is actually a factory, since some comments evolve to some other class. .IP "::CVSTag" 4 .IX Item "::CVSTag" special class of comments that get reordered to the front of packing\-lists. .IP "::Depend" 4 .IX Item "::Depend" all dependency information. .RS 4 .IP "::PkgDep" 4 .IX Item "::PkgDep" deprecated. .IP "::NewDepend" 4 .IX Item "::NewDepend" deprecated. .IP "::LibDepend" 4 .IX Item "::LibDepend" deprecated. .IP "::Wantlib" 4 .IX Item "::Wantlib" shared library needed for the package. .IP "::Dependency" 4 .IX Item "::Dependency" package needed, with the following properties: \f(CW\*(C`pkgpath\*(C'\fR is the path used to create the dependency, \f(CW\*(C`pattern\*(C'\fR is the \fIOpenBSD::PkgSpec\fR\|(3p) pattern used to match the dependency, \f(CW\*(C`def\*(C'\fR is the default value of the dependency computed during build, to use for comparing package signatures and to fullfill default dependencies. .RE .RS 4 .RE .IP "::Conflict" 4 .IX Item "::Conflict" conflict information. .RS 4 .IP "::PkgConflict" 4 .IX Item "::PkgConflict" deprecated. .RE .RS 4 .RE .RE .RS 4 .RE .IP "::Annotation" 4 .IX Item "::Annotation" stuff that doesn't really exist as objects, but is used to add properties to objects. .RS 4 .IP "::Ignore" 4 .IX Item "::Ignore" mark next object as ignored. .IP "::md5" 4 .IX Item "::md5" mark last file with a checksum. .IP "::size" 4 .IX Item "::size" mark last file with a size. .IP "::symlink" 4 .IX Item "::symlink" mark last file as a symlink. .IP "::hardlink" 4 .IX Item "::hardlink" mark last file as a hardlink. .IP "::temp" 4 .IX Item "::temp" mark last file with a temporary name. Used during extraction of packages for replacement. .RE .RS 4 .RE .IP "::Object" 4 .IX Item "::Object" somewhat concrete elements in packing\-lists. This is the base class for objects with a location in the filesystem. It defineds method \f(CW\*(C`fullname\*(C'\fR, to access the complete name of the object. .Sp Note that all objects with file names use relative names except for \&\f(CW\*(C`::Extra\*(C'\fR, \f(CW\*(C`::Sample\*(C'\fR and \f(CW\*(C`::Sampledir\*(C'\fR .RS 4 .IP "::FileObject" 4 .IX Item "::FileObject" abstract class corresponding to files and directories. Default constructor depends on a \f(CW\*(C`dirclass\*(C'\fR property, that may create objects from another class if their name ends with a \f(CW\*(C`/\*(C'\fR. The full object name is normally computed relative to the current working directory as set in \f(CW\*(C`::State\*(C'\fR. .RS 4 .IP "::FileBase" 4 .IX Item "::FileBase" abstract class for files. .RS 4 .IP "::File" 4 .IX Item "::File" actual file objects present in the packing\-list. .IP "::InfoFile" 4 .IX Item "::InfoFile" \&\s-1GNU\s0 info file objects. .IP "::Shell" 4 .IX Item "::Shell" files with shell properties. .IP "::Manpage" 4 .IX Item "::Manpage" man pages. .IP "::Lib" 4 .IX Item "::Lib" shared library files. .IP "::Sample" 4 .IX Item "::Sample" file objects not present in the packing\-list. .RE .RS 4 .RE .IP "::DirlikeObject" 4 .IX Item "::DirlikeObject" abstract class for directories. .RS 4 .IP "::DirRm" 4 .IX Item "::DirRm" deprecated. .IP "::DirBase" 4 .IX Item "::DirBase" .RS 4 .PD 0 .IP "::Dir" 4 .IX Item "::Dir" .PD normal directory, with specialized versions. .RS 4 .IP "::Infodir" 4 .IX Item "::Infodir" directory holds \s-1GNU\s0 info files. .IP "::Fontdir" 4 .IX Item "::Fontdir" directory holds X11 fonts. .IP "::Mandir" 4 .IX Item "::Mandir" directory is the root of a set of manpages. .IP "::Sampledir" 4 .IX Item "::Sampledir" directory is used to hold configuration files or similar objects. .RE .RS 4 .RE .RE .RS 4 .RE .RE .RS 4 .RE .RE .RS 4 .RE .IP "::Action" 4 .IX Item "::Action" stuff that performs some action during addition/removal of package. .RS 4 .IP "::NewUser" 4 .IX Item "::NewUser" user that needs to be created for the package to work. .IP "::NewGroup" 4 .IX Item "::NewGroup" group that needs to be created for the package to work. .IP "::Sysctl" 4 .IX Item "::Sysctl" \&\f(CWsysctl(8)\fR property needed for the package to work. .IP "::ExeclikeAction" 4 .IX Item "::ExeclikeAction" escape mechanism for embedded code that needs to be run. .RS 4 .IP "::Exec" 4 .IX Item "::Exec" code to run during installation. .IP "::Unexec" 4 .IX Item "::Unexec" code to run during deinstallation. .IP "::Extraunexec" 4 .IX Item "::Extraunexec" extra code to run during deinstallation with \-c. .RE .RS 4 .RE .RE .RS 4 .RE .IP "::State" 4 .IX Item "::State" annotation-like stuff that can't be easily moved around because it influences surrounding objects (mostly derived from \f(CW\*(C`::FileObject\*(C'\fR). .RS 4 .IP "::Cwd" 4 .IX Item "::Cwd" change the current working directory. .IP "::EndFake" 4 .IX Item "::EndFake" .PD 0 .IP "::Owner" 4 .IX Item "::Owner" .PD change the current file owner. .IP "::Group" 4 .IX Item "::Group" change the current file group. .IP "::Mode" 4 .IX Item "::Mode" change the current file mode. .RE .RS 4 .RE .RE .RS 4 .RE .SH "CAVEATS" .IX Header "CAVEATS" Some aspects of this \s-1API\s0 are likely to change in the future, although the basic class hierarchy is now more or less worked out.