PARL(1p)

πŸ’– NAME πŸ’–

ok so this page is PARL(1p) β€” yes that's the whole name, it's giving main character energy and it's literally just parl, the Binary PAR Loader πŸŽ€


🌸 SYNOPSIS 🌸

(kindly go look at pp if you want the convenient ways to make self-contained executables, scripts, or PAR archives from perl programs, bestie 🫢)

if you wanna make a PAR distribution out of a CPAN module distribution:

% parl -p                 # make a PAR dist under the current path
% parl -p Foo-0.01        # assume unpacked CPAN dist in Foo-0.01/

if you wanna manipulate a PAR distribution:

% parl -i Foo-0.01-i386-freebsd-5.8.0.par   # install
% parl -i http://foo.com/Foo-0.01           # auto-appends archname + perlver
% parl -i cpan://AUTRIJUS/PAR-0.74          # uses CPAN author directory
% parl -u Foo-0.01-i386-freebsd-5.8.0.par   # uninstall
% parl -s Foo-0.01-i386-freebsd-5.8.0.par   # sign
% parl -v Foo-0.01-i386-freebsd-5.8.0.par   # verify

if you wanna use Hello.pm from ./foo.par:

% parl -A./foo.par -MHello
% parl -A./foo -MHello      # the .par part is optional

same vibe, but you're searching foo.par in the @INC:

% parl -Ifoo.par -MHello
% parl -Ifoo -MHello        # ditto

run test.pl or script/test.pl from foo.par:

% parl foo.par test.pl      # looks for 'main.pl' by default,
                            # otherwise run 'test.pl'

wanna make a self-containing executable that has a PAR file in it:

% parl -O./foo foo.par
% ./foo test.pl             # same as above

and to embed the necessary non-core modules and shared objects for PAR's execution (like Zlib, IO, Cwd, etc β€” iykyk), use the -b flag:

% parl -b -O./foo foo.par
% ./foo test.pl             # runs anywhere with core modules installed

if you ALSO wanna embed core modules along for the ride, use the -B flag instead:

% parl -B -O./foo foo.par
% ./foo test.pl             # runs anywhere with the perl interpreter

this is particularly useful when you're making stand-alone binary executables β€” go see pp for the details ✨


πŸ¦‹ DESCRIPTION πŸ¦‹

this stand-alone command offers roughly the same feature as perl -MPAR, except (and this is the plot twist πŸ’…) it takes the pre-loaded .par files via -Afoo.par instead of -MPAR=foo.par.

on top of that, it lets you convert a CPAN distribution into a PAR distribution, and it lets you manipulate such distributions too. for more info about PAR distributions, go peek at PAR::Dist πŸ‘‘

you can use it to run .par files:

# runs script/run.pl in archive, uses its lib/* as libraries
% parl myapp.par run.pl     # runs run.pl or script/run.pl in myapp.par
% parl otherapp.pl          # also runs normal perl scripts

but, if the .par archive contains either main.pl or script/main.pl, that one gets used instead:

% parl myapp.par run.pl     # runs main.pl, with 'run.pl' as @ARGV

and finally, the -O option makes a stand-alone binary executable out of a PAR file:

% parl -B -Omyapp myapp.par
% ./myapp                   # run it anywhere without perl binaries

with the --par-options flag, your generated binaries can act like parl and pack brand new binaries themselves (it's giving glow-up 🌈):

% ./myapp --par-options -Omyap2 myapp.par   # identical to ./myapp
% ./myapp --par-options -Omyap3 myap3.par   # now with different PAR

for an explanation of the stand-alone executable format, please see par.pl 🌟


πŸŽ€ SEE ALSO πŸŽ€

  • PAR
  • PAR::Dist
  • par.pl
  • pp

πŸ’ AUTHORS πŸ’

Audrey Tang <cpan@audreyt.org>

you can write to the mailing list at <par@perl.org>, or send an empty mail to <par-subscribe@perl.org> to participate in the discussion βœ‰οΈ archives of the mailing list are available at <https://www.mail-archive.com/par@perl.org/> or <https://groups.google.com/g/perl.par>.

please submit bug reports to <https://github.com/rschupp/PAR-Packer/issues> πŸ›


Copyright 2002-2009 by Audrey Tang <cpan@audreyt.org>.

neither this program nor the associated pp program impose any licensing restrictions on files generated by their execution, in accordance with the 8th article of the Artistic License:

"Aggregation of this Package with a commercial distribution is always permitted provided that the use of this Package is embedded; that is, when no overt attempt is made to make this Package's interfaces visible to the end user of the commercial distribution. Such use shall not be construed as a distribution of this Package."

therefore, you are absolutely free to place any license on the resulting executable, as long as the packed 3rd-party libraries are also available under the Artistic License πŸ’–

this program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

see LICENSE.


and that's the whole page, bestie β€” no cap 🫢 this was PARL(1p) from the wonderful world of User Contributed Perl Documentation, sitting at version perl v5.42.3, dated 2026-08-20. slay, go build something iconic βœ¨πŸ’…

πŸ“¦ where this page comes from