Change 29558 by [EMAIL PROTECTED] on 2006/12/15 13:51:44
Subject: Re: [PATCH] Errno doesnt rebuild when things it depends on in
Config.pm change
From: demerphq <[EMAIL PROTECTED]>
Date: Fri, 15 Dec 2006 12:52:45 +0100
Message-ID: <[EMAIL PROTECTED]>
Affected files ...
... //depot/perl/ext/Errno/Makefile.PL#4 edit
Differences ...
==== //depot/perl/ext/Errno/Makefile.PL#4 (text) ====
Index: perl/ext/Errno/Makefile.PL
--- perl/ext/Errno/Makefile.PL#3~1967~ 1998-10-14 19:46:08.000000000 -0700
+++ perl/ext/Errno/Makefile.PL 2006-12-15 05:51:44.000000000 -0800
@@ -1,7 +1,26 @@
use ExtUtils::MakeMaker;
+use Config;
@VMS = ($^O eq 'VMS') ? (MAN3PODS => {}) : ();
+my $arch = "$Config{'archname'}-$Config{'osvers'}";
+my $got = "";
+if (-e 'arch.txt') {
+ open my $in, "<", "arch.txt" or die "Can't read 'arch.txt': $!";
+ $got = <$in>;
+ close $in;
+}
+if ($got ne $arch) {
+ if (-e "Errno.pm") {
+ print "Removing old 'Errno.pm'\n";
+ unlink "Errno.pm"
+ or die "Failed to remove out of date 'Errno.pm': $!";
+ }
+ open my $out, ">", "arch.txt" or die "Can't write 'arch.txt': $!";
+ print $out $arch;
+ close $out;
+}
+
WriteMakefile(
NAME => 'Errno',
VERSION_FROM => 'Errno_pm.PL',
End of Patch.