Subject: | not working with perl 5.10 |
version.pm version strings are starting with v
so modules are not found.
e.g.: the module foo 0.50 is placed under 0.50/foo.pm
it will be searched at v0.50/foo.pm
this wouldn't be that bad, but only.pm also tries to compare the versions
and this will fail because "v0.50" isn't numeric.
conclusion
redirect the call to the method "qv" and cut off the leading 'v';
#in only.pm near line 10 ...
BEGIN {
*to_version = eval {require 'version.pm'} ? \&_qv : sub{$_[0]};
}
sub _qv{
my $x = version::qv($_[0]);
$x = $x->stringify();
if ($x =~ m/^v(.*)$/){
$x = $1;
#die "starts with v $1 $x";
}else{
#die "not starts with v $x";
}
return $x;
}
#...