Subject: | Volume included in Windows test |
Following up the cpan-testers report:
http://www.nntp.perl.org/group/perl.cpan.testers/175082
It appears that the 'plugins' method mistakenly believes abs2rel is to be trusted on non-unix platforms. Whether this is a 5.6.1 thing or not I don't know, but the version of File::Spec (0.82) that I have forgets to remove the volume, in this case 'c:', and consequently the rebuilding of the plugin package name adds a mysterious 'c:::' in the middle!
Attached is the patch to fix this for windows.
--- C:\wip\diffs\Module-Pluggable\Module-Pluggable-2.4/lib/Module/Pluggable.pm Wed Dec 15 11:37:55 2004
+++ C:\wip\diffs\Module-Pluggable\Module-Pluggable-2.4-barbie/lib/Module/Pluggable.pm Tue Jan 18 17:08:37 2005
@@ -229,7 +229,7 @@
$opts{'require'} = 1 if $opts{'inner'};
- # automatically turn a scalr search path or namespace into a arrayref
+ # automatically turn a scalar search path or namespace into a arrayref
for (qw(search_path search_dirs)) {
$opts{$_} = [ $opts{$_} ] if exists $opts{$_} && !ref($opts{$_});
}
@@ -293,6 +293,7 @@
my ($name, $directory) = fileparse($file, qr{\.pm});
$directory = abs2rel($directory, $sp);
# then create the class name in a cross platform way
+ $directory =~ s/^[a-z]://i if($^O =~ /MSWin32|dos/); # remove volume
push @plugins, join "::", splitdir catdir($searchpath, $directory, $name);
}