user1481
user1481

Reputation: 859

What is the relationship between Perl PAR::Packer's pp, par.pl, parl scripts?

I'm trying to learn PAR and PAR::Packer. I understand that PAR is a module which allows loading modules from .par archives. I don't understand the three scripts pp, par.pl, parl in PAR::Packer. (Note: in this question parl includes parl.exe for windows).

  1. What exactly is par.pl supposed to be? Is it a perl script which contains the perl interpreter (the same one as on the development machine) and the PAR module?
  2. What exactly is parl? Is it a binary which contains the same thing as par.pl?
  3. If I'm not mistaken in what par.pl and parl are, why would anyone want par.pl? parl seems strictly superior since it can run without a pre-existing perl.
  4. Is parl safe to distribute to end users with no perl what so ever? For example, if I have several scripts I want to distribute, both sharing many modules, can I distribute parl, the pars for the scripts and modules, and simple wrapper scripts to launch the par'd scripts with parl?
  5. parl and par.pl can both produce standalone scripts/exectubles with the -b and -B options, respectively. Does this mean that pp just a frontend/wrapper?

Upvotes: 3

Views: 622

Answers (1)

Ashok Vairavan
Ashok Vairavan

Reputation: 1962

What exactly is par.pl supposed to be? Is it a perl script which contains the perl interpreter (the same one as on the development machine) and the PAR module?

par.pl is a perl script that embeds core, non-core modules and shared libraries as PAR objects. It also generates the equivalent perl script from the specified PAR object. It can also invoke the perl script embedded inside PAR object. It is also used to make and manipulate PAR distributions. It is not a perl interpreter but instead invokes perl interpreter by itself.

What exactly is parl? Is it a binary which contains the same thing as par.pl?

parl is binary version of par.pl

If I'm not mistaken in what par.pl and parl are, why would anyone want par.pl? parl seems strictly superior since it can run without a pre-existing perl.

Though the functionality provided by par.pl and parl are same, par.pl needs perl interpreter whereas parl doesn't need that.

Is parl safe to distribute to end users with no perl what so ever? For example, if I have several scripts I want to distribute, both sharing many modules, can I distribute parl, the pars for the scripts and modules, and simple wrapper scripts to launch the par'd scripts with parl?

Yes.

parl and par.pl can both produce standalone scripts/exectubles with the -b and -B options, respectively. Does this mean that pp just a frontend/wrapper?

pp detects and packs the dependent modules whereas parl packs only the speicifed modules and scripts.

Upvotes: 4

Related Questions