Use Perl 5 even if Perl 4 comes first in the search path.
This commit is contained in:
parent
a8da89186c
commit
a5a47e4afb
@ -731,7 +731,8 @@ sub which
|
||||
{
|
||||
if (-x "$path/$name")
|
||||
{
|
||||
return "$path/$name";
|
||||
return "$path/$name" unless ($name eq "perl" and
|
||||
system("$path/$name -e " . '\'exit($]<5.0);\''));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
4
config
4
config
@ -344,13 +344,15 @@ fi
|
||||
if [ ".$PERL" = . ] ; then
|
||||
for i in . `echo $PATH | sed 's/:/ /g'`; do
|
||||
if [ -f "$i/perl" ] ; then
|
||||
if "$i/perl" -e 'exit($]<5.0)'; then
|
||||
PERL="$i/perl"
|
||||
break;
|
||||
fi;
|
||||
fi;
|
||||
done
|
||||
fi
|
||||
|
||||
if $PERL -e 'exit($]>=5.0);' ; then
|
||||
if [ ".$PERL" = . ] ; then
|
||||
echo "You need Perl 5."
|
||||
exit 1
|
||||
fi
|
||||
|
Loading…
x
Reference in New Issue
Block a user