diff options
author | Steve Peters <steve@fisharerojo.org> | 2006-07-06 15:38:51 +0000 |
---|---|---|
committer | Steve Peters <steve@fisharerojo.org> | 2006-07-06 15:38:51 +0000 |
commit | f943a5bf3fa0f85f262e926ddedb02aad0fc623c (patch) | |
tree | a0d6857e95fe5912dd07c0001496e4ab2b8903f5 /lib/Module/Build/Base.pm | |
parent | affad850140455cfdbfe87c7519ca10909a8bf23 (diff) | |
download | perl-f943a5bf3fa0f85f262e926ddedb02aad0fc623c.tar.gz |
Upgrade to Module-Build-0.2801.
p4raw-id: //depot/perl@28495
Diffstat (limited to 'lib/Module/Build/Base.pm')
-rw-r--r-- | lib/Module/Build/Base.pm | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/lib/Module/Build/Base.pm b/lib/Module/Build/Base.pm index c8d6275c8f..bb17f6673a 100644 --- a/lib/Module/Build/Base.pm +++ b/lib/Module/Build/Base.pm @@ -1272,6 +1272,13 @@ sub make_executable { } } +sub is_executable { + # We assume this does the right thing on generic platforms, though + # we do some other more specific stuff on Unixish platforms. + my ($self, $file) = @_; + return -x $file; +} + sub _startperl { shift()->config('startperl') } # Return any directories in @INC which are not in the default @INC for @@ -2496,7 +2503,7 @@ sub htmlify_pods { my $pods = $self->_find_pods( $self->{properties}{"${type}doc_dirs"}, exclude => [ qr/\.(?:bat|com|html)$/ ] ); - next unless %$pods; # nothing to do + return unless %$pods; # nothing to do unless ( -d $htmldir ) { File::Path::mkpath($htmldir, 0, 0755) @@ -3955,7 +3962,7 @@ sub copy_if_modified { $self->log_info("$file -> $to_path\n") if $args{verbose}; File::Copy::copy($file, $to_path) or die "Can't copy('$file', '$to_path'): $!"; # mode is read-only + (executable if source is executable) - my $mode = 0444 | ( -x $file ? 0111 : 0 ); + my $mode = 0444 | ( $self->is_executable($file) ? 0111 : 0 ); chmod( $mode, $to_path ); return $to_path; |