diff options
author | joey <joey> | 2000-11-07 23:56:05 +0000 |
---|---|---|
committer | joey <joey> | 2000-11-07 23:56:05 +0000 |
commit | 5615612cd688bb01f13b9ea966b4c8d801f03449 (patch) | |
tree | 038a981fe18d45e4352ca479960d090a798274da /dh_perl | |
parent | 1d9a72073d0f54f96be2404929a452cdf90c2f6b (diff) |
r384: ugh
Diffstat (limited to 'dh_perl')
-rwxr-xr-x | dh_perl | 4 |
1 files changed, 3 insertions, 1 deletions
@@ -13,7 +13,9 @@ my $lib_dir = 'usr/lib/perl5'; # it points to, otherwise query perl directly. my $version=sprintf("%.3f", $]); if (defined $ENV{PERL}) { - $version=`$ENV{PERL} -e 'printf "%.3f", \$]'`; + # This is pretty gawd-aweful ugly, because we need "5.00[45]" + # and "5.[6789]" to be returned. + $version=`$ENV{PERL} -e '\$] < 5.006 ? printf "%.3f", \$] : printf "%vd\n", substr \$^V, 0, -1'`; } # Cleaning the paths given on the command line |