#! /usr/bin/env perl use strict; use warnings; use App::cpackage; App::cpackage->run(); =head1 NAME cpackage - Create installation packages from CPAN modules =head1 SYNOPSYS cpackage My::CPAN::Module cpackage --mirror http://cpan.local --mirror-only My::Private::Module =head1 DESCRIPTION B builds installation packages from CPAN modules, containing all dependencies and an F script. Running F will install the module (and dependencies) without requiring Internet access or a configured CPAN client on the target machine. =head2 Usage To create an installer from a CPAN module, run the command: cpackage My::CPAN::Module B will use L to download the module and its dependencies - these files will be placed in the F directory. Your currently installed version of L will be copied and bundled into the F directory. Finally an F file will be written - running this script will install the module together with its dependencies. All files will be written to the current working directory. =head2 Using your own CPAN mirror B accepts the same command-line options as L, so you can use it to build an installer from your own private CPAN or DarkPAN mirror. cpackage --mirror http://my.cpan --mirror-only My::Private::Module If you have a DarkPAN mirror set up (e.g. using CPAN::Mini::Inject) you can create installers that contain a mix of private code and public CPAN code with full dependency resolution between the two. =head2 Running the installer To run the generated installer script, use the command: perl install.pl Because the installer uses the bundled copy of L, you can also give any of L's standard options, e.g. perl install.pl --sudo =head1 SEE ALSO L =head1 AUTHOR Jon Allen (JJ) =head1 LICENSE Copyright 2011 Jon Allen (JJ). This program is free software; you can redistribute it and/or modify it under the terms of either: the GNU General Public License as published by the Free Software Foundation; or the Artistic License. See http://dev.perl.org/licenses/ for more information. =cut