develooper Front page | perl.perl5.porters | Postings from February 2003

[PATCH 5.8.0] Optimizing ExtUtils::Install::pm_to_blib()

Thread Next
From:
Barrie Slaymaker
Date:
February 27, 2003 00:20
Subject:
[PATCH 5.8.0] Optimizing ExtUtils::Install::pm_to_blib()
Message ID:
20030227093331.GC22686@jester.slaysys.com
Here's another minor patchlet that should be more appropriate; it skips
running File::Compare::compare() on each source and destination when the
mtimes are identical; pm_to_blib() tries to force identical mtimes on
all but VMS.

This both reduces scrollback in the terminal (nice on smaller screens)
and speeds things up.

- Barrie

--- ExtUtils/Install.pm.orig    2003-02-27 03:47:48.000000000 -0500
+++ ExtUtils/Install.pm 2003-02-27 04:29:13.000000000 -0500
@@ -299,7 +299,7 @@
     mkpath($autodir,0,0755);
     foreach (keys %$fromto) {
        my $dest = $fromto->{$_};
-       next if -f $dest && -M $dest < -M $_;
+       next if -f $dest && -M $dest <= -M $_ && -s $dest == -s $_;

        # When a pm_filter is defined, we need to pre-process the source first
        # to determine whether it has changed or not.  Therefore, only perform



Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About