rschupp / PAR-Packer

(perl) Generate stand-alone executables, perl scripts and PAR files https://metacpan.org/pod/PAR::Packer
Other
48 stars 13 forks source link

This is the README file for PAR-Packer, a part of the PAR toolkit. PAR-Packer is the PAR component that can generate stand-alone executables and ".par" archives.

The main front-end for PAR-Packer is the "pp" utility.

For packing scripts with prerequisite modules into stand-alone scripts or executables (aka PerlApp, Perl2exe, or 'perlcc that works'), see "perldoc pp" and "perldoc tkpp".

For running ".par" files directly, see "perldoc parl".

To generate/execute self-contained perl scripts, see "perldoc pp" or "perldoc par.pl".

An extensive "Cross-Platform Packaging and Deployment with PAR" tutorial is available as "perldoc PAR::Tutorial" from the PAR distribution which is a prerequisite for this distribution.

If you have cpanm, you only need one line:

cpanm PAR::Packer

Alternatively, if your CPAN shell is set up, you should just be able to do:

cpan PAR:Packer

As a last resort, you can manually install it. Download the tarball, untar it, then build it:

perl Makefile.PL make make test make install

Note that all of the above require that you have a C compiler installed.

If your Perl distribution is Strawberry Perl, you already have the MinGW C compiler installed. If you are using ActiveState Perl, you may want to install the MinGW C compiler with:

ppm install MinGW

Here are some recipes showing how to utilize pp to bundle source.pl with all its dependencies, on target machines with different expected settings:

Note that if your perl was built with a shared library, the 'Stand-alone setup' above will still need a separate perl5x.dll or libperl.so to function correctly. Patches to include a copy of libperl with the executable are most welcome. (Note: This might not apply any more.)

Please consult the documentation of 'pp' for more information.

You can write to the mailing list at par@perl.org (no subscription required). Archives of the mailing list are available at http://www.nntp.perl.org/group/perl.par or https://www.mail-archive.com/par@perl.org/.

Please submit bug reports to https://github.com/rschupp/PAR-Packer/issues.

Copyright 2002-2010 by Audrey Tang cpan@audreyt.org.

All rights reserved. You can redistribute and/or modify this bundle under the same terms as Perl itself.

See LICENSE.