CPANPLUS::Dist::Slackware::PackageDescription - Collect information on a Slackware compatible package
This documentation refers to CPANPLUS::Dist::Slackware::PackageDescription version 0.04.
CPANPLUS::Dist::Slackware::PackageDescription
use CPANPLUS::Dist::Slackware::PackageDescription; $pkgdesc = CPANPLUS::Dist::Slackware::PackageDescription->new( module => $modobj, tag => '_MYTAG', type => 'txz' ); $filename = $pkgdesc->filename(); $summary = $pkgdesc->summary(); $desc = $pkgdesc->slack_desc(); @docfiles = $pkgdesc->docfiles();
This module gets information on a yet-to-be-created Slackware compatible package. The information is obtained from a CPANPLUS::Module object, the file system and the environment. Among other things, the module translates a Perl distribution's name and version into a package name. It tries to find a short summary that describes the distribution. It can build a slack_desc description for you. It finds standard documentation files like README and Changes.
CPANPLUS::Module
Returns a newly constructed object.
$pkgdesc = CPANPLUS::Dist::Slackware::PackageDescription->new( module => $modobj, %attrs );
The CPANPLUS::Module object is mandatory. All other attributes are optional.
Returns the CPANPLUS::Module object that was passed to the constructor.
Returns the package name, e.g. "perl-Some-Module".
Returns the package version, e.g. "0.01".
Returns the package name and version, e.g. "perl-Some-Module-0.01".
Returns the package's build number. Normally "1".
As packages may be built recursively, CPANPLUS::Dist::Slackware ignores $ENV{BUILD}.
CPANPLUS::Dist::Slackware
$ENV{BUILD}
Sets the package's build number.
Returns the package architecture. If unset, either the value of $ENV{ARCH} or a platform-specific identifier like "i486" is returned.
$ENV{ARCH}
Returns a tag that is added to the package filename. Defaults to $ENV{TAG} or "_CPANPLUS".
$ENV{TAG}
Returns the package extension. Defaults to $ENV{PKGTYPE} or "tgz". Other possible values are "tbz", "tlz" and "txz".
$ENV{PKGTYPE}
Returns the package's filename, e.g. perl-Some-Module-0.01-i486-1_CPANPLUS.tgz.
Returns the directory where all created packages are stored. Defaults to $OUTPUT, $TMPDIR or /tmp.
Returns the package's full filename, e.g. /tmp/perl-Some-Module-0.01-i486-1_CPANPLUS.tgz.
Returns the packages's documentation directory, e.g. /usr/doc/perl-Some-Module-0.01.
Returns a list of standard documentation files that the distribution contains, e.g. ("Changes", "LICENSE, "README"). The filenames are relative to the distribution's top-level directory.
("Changes", "LICENSE, "README")
Must be called after the distribution has been extracted.
Returns a description of the distribution's purpose, e.g. "Drop atomic bombs on Australia".
Must not be called before the distribution has been extracted. Gives better results when called after the distribution has been built, i.e. when the "blib" directory is available.
Returns a config shell function that can be added to the doinst.sh script in the package's install directory.
config
Only the shell function is returned. You have to add the config function calls for each configuration file yourself.
Returns a Slackware package description that can be written to the slack-desc file in the package's install directory.
Returns a build script that can be written to perl-Some-Module.SlackBuild in the package's documentation directory.
Returns the text of a README.SLACKWARE file that can be stored in the package's documentation directory. The returned document lists the build dependencies. You can add more text to this document, e.g. a list of configuration files provided by the package.
Returns the staging directory where the distribution is temporarily installed, e.g. /tmp/CPANPLUS/package-perl-Some-Module-01yEr7X43K. Defaults to a package-specific subdirectory in $TMP or /tmp/CPANPLUS.
None.
See above and CPANPLUS::Dist::Slackware for supported environment variables.
Requires the modules File::Spec, File::Temp, Pod::Find, Pod::Simple, POSIX, and Text::Wrap, which are all provided by Perl 5.10. If available, the module Parse::CPAN::Meta is used.
File::Spec
File::Temp
Pod::Find
Pod::Simple
POSIX
Text::Wrap
Parse::CPAN::Meta
None known.
Andreas Voegele, <andreas at andreasvoegele.com>
<andreas at andreasvoegele.com>
Please report any bugs to bug-cpanplus-dist-slackware at rt.cpan.org, or through the web interface at http://rt.cpan.org/.
bug-cpanplus-dist-slackware at rt.cpan.org
Copyright (c) 2012 Andreas Voegele
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
See http://dev.perl.org/licenses/ for more information.
To install CPANPLUS::Dist::Slackware, copy and paste the appropriate command in to your terminal.
cpanm
cpanm CPANPLUS::Dist::Slackware
CPAN shell
perl -MCPAN -e shell install CPANPLUS::Dist::Slackware
For more information on module installation, please visit the detailed CPAN module installation guide.