Change 18814 by [EMAIL PROTECTED] on 2003/03/03 05:37:43

        Integrate:
        [ 18749]
        Subject: [PATCH] Make adding notes to patchlevel.h easier
        From: [EMAIL PROTECTED] (Andreas J. Koenig)
        Date: Tue, 18 Feb 2003 11:48:40 +0100
        Message-ID: <[EMAIL PROTECTED]>
        
        [ 18809]
        Subject: [perl #21031] $File::Find::name ne $_ w/no_chdir
        From: "Anders Johnson" (via RT) <[EMAIL PROTECTED]>
        Date: 15 Feb 2003 00:21:41 -0000
        Message-Id: <[EMAIL PROTECTED]>
        
        [ 18810]
        Subject: [PATCH] Re: [perl #18872] File::Basename example misleading
        From: Richard Soderberg <[EMAIL PROTECTED]>
        Date: Sat, 15 Feb 2003 01:27:21 -0500
        Message-Id: <[EMAIL PROTECTED]>
        
        [ 18811]
        Subject: [perl #21289] [Fwd: IPC::Msg bug report]
        From: Edmund Bacon (via RT) <[EMAIL PROTECTED]>
        Date: 18 Feb 2003 21:05:15 -0000
        Message-Id: <[EMAIL PROTECTED]>
        
        [ 18812]
        Subject: Re: [PATCH] Make adding notes to patchlevel.h easier
        From: [EMAIL PROTECTED] (Andreas J. Koenig)
        Date: Wed, 19 Feb 2003 11:05:28 +0100
        Message-ID: <[EMAIL PROTECTED]>

Affected files ...

... //depot/maint-5.8/perl/ext/IPC/SysV/Msg.pm#2 integrate
... //depot/maint-5.8/perl/lib/File/Basename.pm#4 integrate
... //depot/maint-5.8/perl/lib/File/Find.pm#3 integrate
... //depot/maint-5.8/perl/patchlevel.h#12 integrate

Differences ...

==== //depot/maint-5.8/perl/ext/IPC/SysV/Msg.pm#2 (text) ====
Index: perl/ext/IPC/SysV/Msg.pm
--- perl/ext/IPC/SysV/Msg.pm#1~17645~   Fri Jul 19 12:29:57 2002
+++ perl/ext/IPC/SysV/Msg.pm    Sun Mar  2 21:37:43 2003
@@ -69,7 +69,7 @@
     else {
        croak 'Bad arg count' if @_ % 2;
        my %arg = @_;
-       my $ds = $self->stat
+       $ds = $self->stat
                or return undef;
        my($key,$val);
        $ds->$key($val)

==== //depot/maint-5.8/perl/lib/File/Basename.pm#4 (text) ====
Index: perl/lib/File/Basename.pm
--- perl/lib/File/Basename.pm#3~18227~  Mon Dec  2 05:23:48 2002
+++ perl/lib/File/Basename.pm   Sun Mar  2 21:37:43 2003
@@ -19,7 +19,7 @@
 
     ($name,$path,$suffix) = fileparse("lib/File/Basename.pm",qr{\.pm});
     fileparse_set_fstype("VMS");
-    $basename = basename("lib/File/Basename.pm",qr{\.pm});
+    $basename = basename("lib/File/Basename.pm",".pm");
     $dirname = dirname("lib/File/Basename.pm");
 
 =head1 DESCRIPTION

==== //depot/maint-5.8/perl/lib/File/Find.pm#3 (text) ====
Index: perl/lib/File/Find.pm
--- perl/lib/File/Find.pm#2~18503~      Thu Jan 16 15:29:57 2003
+++ perl/lib/File/Find.pm       Sun Mar  2 21:37:43 2003
@@ -700,6 +700,7 @@
            }
 
            $name = $abs_dir . $_; # $File::Find::name
+           $_ = $name if $no_chdir;
 
            { $wanted_callback->() }; # protect against wild "next"
 

==== //depot/maint-5.8/perl/patchlevel.h#12 (text) ====
Index: perl/patchlevel.h
--- perl/patchlevel.h#11~18804~ Sun Mar  2 08:22:35 2003
+++ perl/patchlevel.h   Sun Mar  2 21:37:43 2003
@@ -50,9 +50,11 @@
        please place your applied patch line after its dependencies. This
        will help tracking of patch dependencies.
 
-       Please edit the hunk of diff which adds your patch to this list,
-       to remove context lines which would give patch problems.  For instance,
-       if the original context diff is
+       Please either use 'diff -u --context=0' if your diff supports
+       that or edit the hunk of the diff output which adds your patch
+       to this list, to remove context lines which would give patch
+       problems. For instance, if the original context diff is
+
           *** patchlevel.h.orig        <date here>
           --- patchlevel.h     <date here>
           *** 38,43 ***
@@ -75,13 +77,52 @@
        (Note changes to line numbers as well as removal of context lines.)
        This will prevent patch from choking if someone has previously
        applied different patches than you.
+
+        History has shown that nobody distributes patches that also
+        modify patchlevel.h. Do it yourself. The following perl
+        program can be used to add a comment to patchlevel.h:
+
+#!perl
+die "Usage: perl -x patchlevel.h comment ..." unless @ARGV;
+open PLIN, "patchlevel.h" or die "Couldn't open patchlevel.h : $!";
+open PLOUT, ">patchlevel.new" or die "Couldn't write on patchlevel.new : $!";
+my $seen=0;
+while (<PLIN>) {
+    if (/\t,NULL/ and $seen) {
+       while (my $c = shift @ARGV){
+            print PLOUT qq{\t,"$c"\n};
+       }
+    }
+    $seen++ if /local_patches\[\]/;
+    print PLOUT;
+}
+close PLOUT or die "Couldn't close filehandle writing to patchlevel.new : $!";
+close PLIN or die "Couldn't close filehandle reading from patchlevel.h : $!";
+unlink "patchlevel.bak" or warn "Couldn't unlink patchlevel.bak : $!"
+  if -e "patchlevel.bak";
+rename "patchlevel.h", "patchlevel.bak" or
+  die "Couldn't rename patchlevel.h to patchlevel.bak : $!";
+rename "patchlevel.new", "patchlevel.h" or
+  die "Couldn't rename patchlevel.new to patchlevel.h : $!";
+__END__
+
+Please keep empty lines below so that context diffs of this file do
+not ever collect the lines belonging to local_patches() into the same
+hunk.
+
  */
+
+
+
+
 #if !defined(PERL_PATCHLEVEL_H_IMPLICIT) && !defined(LOCAL_PATCH_COUNT)
 static char    *local_patches[] = {
         NULL
        ,"MAINT18638"
        ,NULL
 };
+
+
 
 /* Initial space prevents this variable from being inserted in config.sh  */
 #  define      LOCAL_PATCH_COUNT       \
End of Patch.

Reply via email to