line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
#!/usr/local/bin/perl |
2
|
|
|
|
|
|
|
|
3
|
|
|
|
|
|
|
eval 'exec /usr/local/bin/perl -S $0 ${1+"$@"}' |
4
|
|
|
|
|
|
|
if 0; # not running under some shell |
5
|
|
|
|
|
|
|
eval 'exec /usr/bin/perl -S $0 ${1+"$@"}' |
6
|
|
|
|
|
|
|
if 0; # not running under some shell |
7
|
|
|
|
|
|
|
|
8
|
|
|
|
|
|
|
package __par_pl; |
9
|
|
|
|
|
|
|
|
10
|
|
|
|
|
|
|
# --- This script must not use any modules at compile time --- |
11
|
|
|
|
|
|
|
# use strict; |
12
|
|
|
|
|
|
|
|
13
|
|
|
|
|
|
|
=head1 NAME |
14
|
|
|
|
|
|
|
|
15
|
|
|
|
|
|
|
par.pl - Make and run Perl Archives |
16
|
|
|
|
|
|
|
|
17
|
|
|
|
|
|
|
=head1 SYNOPSIS |
18
|
|
|
|
|
|
|
|
19
|
|
|
|
|
|
|
(Please see L for convenient ways to make self-contained |
20
|
|
|
|
|
|
|
executables, scripts or PAR archives from perl programs.) |
21
|
|
|
|
|
|
|
|
22
|
|
|
|
|
|
|
To make a I from a CPAN module distribution: |
23
|
|
|
|
|
|
|
|
24
|
|
|
|
|
|
|
% par.pl -p # make a PAR dist under the current path |
25
|
|
|
|
|
|
|
% par.pl -p Foo-0.01 # assume unpacked CPAN dist in Foo-0.01/ |
26
|
|
|
|
|
|
|
|
27
|
|
|
|
|
|
|
To manipulate a I: |
28
|
|
|
|
|
|
|
|
29
|
|
|
|
|
|
|
% par.pl -i Foo-0.01-i386-freebsd-5.8.0.par # install |
30
|
|
|
|
|
|
|
% par.pl -i http://foo.com/Foo-0.01 # auto-appends archname + perlver |
31
|
|
|
|
|
|
|
% par.pl -i cpan://AUTRIJUS/PAR-0.74 # uses CPAN author directory |
32
|
|
|
|
|
|
|
% par.pl -u Foo-0.01-i386-freebsd-5.8.0.par # uninstall |
33
|
|
|
|
|
|
|
% par.pl -s Foo-0.01-i386-freebsd-5.8.0.par # sign |
34
|
|
|
|
|
|
|
% par.pl -v Foo-0.01-i386-freebsd-5.8.0.par # verify |
35
|
|
|
|
|
|
|
|
36
|
|
|
|
|
|
|
To use F from F<./foo.par>: |
37
|
|
|
|
|
|
|
|
38
|
|
|
|
|
|
|
% par.pl -A./foo.par -MHello |
39
|
|
|
|
|
|
|
% par.pl -A./foo -MHello # the .par part is optional |
40
|
|
|
|
|
|
|
|
41
|
|
|
|
|
|
|
Same thing, but search F in the F<@INC>; |
42
|
|
|
|
|
|
|
|
43
|
|
|
|
|
|
|
% par.pl -Ifoo.par -MHello |
44
|
|
|
|
|
|
|
% par.pl -Ifoo -MHello # ditto |
45
|
|
|
|
|
|
|
|
46
|
|
|
|
|
|
|
Run F or F |