Bill Allombert on Mon, 19 Jan 2015 12:20:56 +0100


[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

Re: Install Perl scripts with #!/usr/bin/env perl


On Tue, Jan 13, 2015 at 09:39:40AM +0100, Jeroen Demeyer wrote:
> Hello PARI developers,
> 
> when installing Perl scripts, it is better to use
> #!/usr/bin/env perl
> instead of using the Perl path found at Configure time.

Hello Jeroen,

your proposal defeats the purpose of the Configure check, since the perl
program checked by Configure might not be the perl program that will be used.

Also, this is incompatible with the use of flags:
#! /usr/bin/env perl -w 
is no valid.

> This is especially needed for binary installs, where the system that
> PARI was compiled on is not the system that PARI is run on. For Perl
> scripts at build time, this is not an issue.

This is assuming that /usr/bin/env exists on the target system.

What we should do is to allow the user to specify the perl
executable in the PERL environment variable, including "/usr/bin/env perl"
if the user so wishes.

Cheers,
Bill.