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

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

Thread Previous | Thread Next
From:
sthoenna
Date:
March 23, 2003 21:38
Subject:
Re: [PATCH 5.8.0] Optimizing ExtUtils::Install::pm_to_blib()
Message ID:
2Lpf+gzkgOoR092yn@efn.org
On Thu, 27 Feb 2003 01:44:50 -0800, schwern@pobox.com wrote:
>On Thu, Feb 27, 2003 at 04:33:39AM -0500, Barrie Slaymaker wrote:
>> 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.
>
>MakeMaker has drifted significantly from what's in the core.  You can find
>the latest snapshots on www.makemaker.org.  Patches go to makemaker@perl.org.
>
>I'm not sure I understand the logic of the patch below.  Why is it comparing
>the size of the file?
>
>
>> 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

Sorry for the late addition to the discussion...I'm catching up on some older
p5p posts I had skipped.

-M *is* *not* mtime. The above patch looks like a big mistake. perlfunc says:
    -M  Script start time minus file modification time, in days.

Thread Previous | 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