This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Porting/bench.pl: new syntax for perl args and env
authorDavid Mitchell <davem@iabyn.com>
Mon, 19 Jun 2017 11:47:35 +0000 (12:47 +0100)
committerDavid Mitchell <davem@iabyn.com>
Wed, 21 Jun 2017 09:56:24 +0000 (10:56 +0100)
commit99b1e78ba0b3d8d62ea568ced2feb335c1896f3f
tree558befb78d9800764dfbc9bba101fb4a956fdbca
parent81cb9d799a02a8edb6b6ed4bab5c0837fcfbd749
Porting/bench.pl: new syntax for perl args and env

The existing syntax for supplying per-perl-executable command-line
arguments and environment was clunky and buggy.

Replace it with the following syntax and add tests:

One of more perls to execute is listed on the command line after all
switches have been processed. Each perl is of the form:

    some-perl [--args='-Mstrict -Mwarnings' ] \
              [ --env='A=a' --env='B=b' .... ]

i.e. the name of a perl executable, optionally succeeded by --args and
--env switches.

E.g. the above invokes

    'some-perl -Mstrict -Mwarnings'

with the A and B environment variables set.

See http://nntp.perl.org/group/perl.perl5.porters/240004
Porting/bench.pl
t/porting/bench.t