mirror of
https://github.com/RsyncProject/rsync.git
synced 2026-03-05 15:06:50 -05:00
- Make sure the Makefile is up-to-date before running "make gen".
- The release-rsync script now creates the generated patches in a separate dir from the normal patches.
This commit is contained in:
@@ -239,7 +239,7 @@ if ($diffdir ne $dest) {
|
||||
}
|
||||
|
||||
print "Creating $diff_file ...\n";
|
||||
system "make gen; rsync -a @extra_files b/";
|
||||
system "./config.status Makefile; make gen; rsync -a @extra_files b/";
|
||||
my $sed_script = 's:^((---|\+\+\+) [ab]/[^\t]+)\t.*:\1:';
|
||||
system "(git diff v$lastversion v$version; diff -up a b | sed -r '$sed_script') | gzip -9 >$diff_file";
|
||||
system "rm -rf a";
|
||||
@@ -250,11 +250,10 @@ system "git archive --format=tar --prefix=rsync-$version/ v$version | tar xf -";
|
||||
system "support/git-set-file-times --prefix=rsync-$version/";
|
||||
system "fakeroot tar czf $srctar_file rsync-$version; rm -rf rsync-$version";
|
||||
|
||||
system "support/patch-update --gen";
|
||||
|
||||
symlink('.', "rsync-$version");
|
||||
system "fakeroot tar chzf $pattar_file rsync-$version/patches";
|
||||
unlink("rsync-$version");
|
||||
mkdir("rsync-$version", 0755);
|
||||
mkdir("rsync-$version/patches", 0755);
|
||||
system "support/patch-update --gen=rsync-$version/patches";
|
||||
system "fakeroot tar chzf $pattar_file rsync-$version/patches; rm -rf rsync-$version";
|
||||
|
||||
print "Updating the other files in $dest ...\n";
|
||||
system "rsync -a README NEWS OLDNEWS TODO $dest";
|
||||
|
||||
@@ -7,7 +7,16 @@
|
||||
|
||||
use strict;
|
||||
|
||||
die "No 'patches' directory present in the current dir.\n" unless -d 'patches';
|
||||
my $patches_dir = 'patches';
|
||||
my $incl_generated_files;
|
||||
|
||||
if (@ARGV && $ARGV[0] =~ /^--gen(?:=(\S+))?$/) {
|
||||
$patches_dir = $1 if defined $1;
|
||||
$incl_generated_files = 1;
|
||||
shift;
|
||||
}
|
||||
|
||||
die "No '$patches_dir' directory was found.\n" unless -d $patches_dir;
|
||||
die "No '.git' directory present in the current dir.\n" unless -d '.git';
|
||||
|
||||
my @extra_files;
|
||||
@@ -23,13 +32,11 @@ while (<IN>) {
|
||||
}
|
||||
close IN;
|
||||
|
||||
my $incl_generated_files = shift if @ARGV && $ARGV[0] eq '--gen';
|
||||
|
||||
system "git checkout master" and exit 1;
|
||||
if ($incl_generated_files) {
|
||||
die "'a' must not exist in the current directory.\n" if -e 'a';
|
||||
die "'b' must not exist in the current directory.\n" if -e 'b';
|
||||
system "make gen && rsync -a @extra_files a/" and exit 1;
|
||||
system "./config.status Makefile && make gen && rsync -a @extra_files a/" and exit 1;
|
||||
}
|
||||
my $last_touch = time;
|
||||
|
||||
@@ -110,7 +117,7 @@ sub update_patch
|
||||
system "git checkout --track -b patch/$patch origin/patch/$patch" and exit 1;
|
||||
}
|
||||
|
||||
open(OUT, '>', "patches/$patch.diff") or die $!;
|
||||
open(OUT, '>', "$patches_dir/$patch.diff") or die $!;
|
||||
print OUT $description{$patch}, "\n";
|
||||
|
||||
if (system("git rebase -m $parent") != 0) {
|
||||
@@ -120,7 +127,7 @@ sub update_patch
|
||||
}
|
||||
|
||||
if ($incl_generated_files) {
|
||||
system "make gen && rsync -a @extra_files b/" and exit 1;
|
||||
system "./config.status Makefile && make gen && rsync -a @extra_files b/" and exit 1;
|
||||
}
|
||||
$last_touch = time;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user