sub maybe_command {
my($self,$file) = @_;
- return "$file.exe" if -e "$file.exe";
+ my @e = exists($ENV{'PATHEXT'})
+ ? split(/;/, $ENV{PATHEXT})
+ : qw(.com .exe .bat .cmd);
+ my $e = '';
+ for (@e) { $e .= "\Q$_\E|" }
+ chop $e;
+ # see if file ends in one of the known extensions
+ if ($file =~ /($e)$/i) {
+ return $file if -e $file;
+ }
+ else {
+ for (@e) {
+ return "$file$_" if -e "$file$_";
+ }
+ }
return;
}
my ($self) = @_;
if($OBJ) {
if ($self->{CAPI} eq 'TRUE') {
- return '$(PERL_INC)\PerlCAPI$(LIB_EXT)';
- }
- else {
- return '$(PERL_INC)\perlcore$(LIB_EXT)';
+ return '$(PERL_INC)\perlCAPI$(LIB_EXT)';
}
}
return '$(PERL_INC)\\'.$Config{'libperl'};
=cut
sub manifypods {
+ my($self) = shift;
return "\nmanifypods :\n\t$self->{NOECHO}\$(NOOP)\n";
}