summaryrefslogtreecommitdiff
path: root/lib/ExtUtils
diff options
context:
space:
mode:
authorJarkko Hietaniemi <jhi@iki.fi>2000-05-29 03:01:38 +0000
committerJarkko Hietaniemi <jhi@iki.fi>2000-05-29 03:01:38 +0000
commit0af2a2907a21f2e6ff6ca5f8df976d75a98b9794 (patch)
tree822de246c205c41c606a4c905ae610c6158e3f9a /lib/ExtUtils
parentd67bf1d95495fd9f41cabf2a1f9dc1f266c1575d (diff)
parent413e5597fa15080977e13a1ad58f104914a75a31 (diff)
downloadperl-0af2a2907a21f2e6ff6ca5f8df976d75a98b9794.tar.gz
Integrate with Sarathy.
p4raw-id: //depot/cfgperl@6156
Diffstat (limited to 'lib/ExtUtils')
-rw-r--r--lib/ExtUtils/MM_Unix.pm16
-rw-r--r--lib/ExtUtils/MakeMaker.pm2
-rwxr-xr-xlib/ExtUtils/xsubpp17
3 files changed, 28 insertions, 7 deletions
diff --git a/lib/ExtUtils/MM_Unix.pm b/lib/ExtUtils/MM_Unix.pm
index da2255271f..65b0bd91c4 100644
--- a/lib/ExtUtils/MM_Unix.pm
+++ b/lib/ExtUtils/MM_Unix.pm
@@ -1249,11 +1249,6 @@ eval 'exec $interpreter $arg -S \$0 \${1+"\$\@"}'
next;
}
my($dev,$ino,$mode) = stat FIXIN;
- # If they override perm_rwx, we won't notice it during fixin,
- # because fixin is run through a new instance of MakeMaker.
- # That is why we must run another CHMOD later.
- $mode = oct($self->perm_rwx) unless $dev;
- chmod $mode, $file;
# Print out the new #! line (or equivalent).
local $\;
@@ -1261,7 +1256,15 @@ eval 'exec $interpreter $arg -S \$0 \${1+"\$\@"}'
print FIXOUT $shb, <FIXIN>;
close FIXIN;
close FIXOUT;
- # can't rename open files on some DOSISH platforms
+
+ # can't rename/chmod open files on some DOSISH platforms
+
+ # If they override perm_rwx, we won't notice it during fixin,
+ # because fixin is run through a new instance of MakeMaker.
+ # That is why we must run another CHMOD later.
+ $mode = oct($self->perm_rwx) unless $dev;
+ chmod $mode, $file;
+
unless ( rename($file, "$file.bak") ) {
warn "Can't rename $file to $file.bak: $!";
next;
@@ -1276,6 +1279,7 @@ eval 'exec $interpreter $arg -S \$0 \${1+"\$\@"}'
}
unlink "$file.bak";
} continue {
+ close(FIXIN) if fileno(FIXIN);
chmod oct($self->perm_rwx), $file or
die "Can't reset permissions for $file: $!\n";
system("$Config{'eunicefix'} $file") if $Config{'eunicefix'} ne ':';;
diff --git a/lib/ExtUtils/MakeMaker.pm b/lib/ExtUtils/MakeMaker.pm
index 9906fd5383..bef12b54da 100644
--- a/lib/ExtUtils/MakeMaker.pm
+++ b/lib/ExtUtils/MakeMaker.pm
@@ -82,7 +82,7 @@ if ($Is_OS2) {
require ExtUtils::MM_OS2;
}
if ($Is_Mac) {
- require ExtUtils::MM_Mac;
+ require ExtUtils::MM_MacOS;
}
if ($Is_Win32) {
require ExtUtils::MM_Win32;
diff --git a/lib/ExtUtils/xsubpp b/lib/ExtUtils/xsubpp
index 5a71e89636..eb085f542f 100755
--- a/lib/ExtUtils/xsubpp
+++ b/lib/ExtUtils/xsubpp
@@ -847,7 +847,14 @@ EOM
print("#line 1 \"$filename\"\n")
if $WantLineNumbers;
+firstmodule:
while (<$FH>) {
+ if (/^=/) {
+ do {
+ next firstmodule if /^=cut\s*$/;
+ } while (<$FH>);
+ &Exit;
+ }
last if ($Module, $Package, $Prefix) =
/^MODULE\s*=\s*([\w:]+)(?:\s+PACKAGE\s*=\s*([\w:]+))?(?:\s+PREFIX\s*=\s*(\S+))?\s*$/;
@@ -886,6 +893,16 @@ sub fetch_para {
}
for(;;) {
+ # Skip embedded PODs
+ while ($lastline =~ /^=/) {
+ while ($lastline = <$FH>) {
+ last if ($lastline =~ /^=cut\s*$/);
+ }
+ death ("Error: Unterminated pod") unless $lastline;
+ $lastline = <$FH>;
+ chomp $lastline;
+ $lastline =~ s/^\s+$//;
+ }
if ($lastline !~ /^\s*#/ ||
# CPP directives:
# ANSI: if ifdef ifndef elif else endif define undef