diff options
author | nobody <nobody@gnome.org> | 2003-10-23 14:45:54 +0000 |
---|---|---|
committer | nobody <nobody@gnome.org> | 2003-10-23 14:45:54 +0000 |
commit | 36bf8b28dc75f37db2cf22348eff4ffe975c4fd9 (patch) | |
tree | 0c1546254e2906d24ff75a74ba155fa227fa9a2b | |
parent | 38e91730d32daa8bf227778aa1ad7ab448b13364 (diff) |
This commit was manufactured by cvs2svn to create tagDEBIAN-1_1_0-2
'DEBIAN-1_1_0-2'.
-rwxr-xr-x | patches/apply.pl | 42 |
1 files changed, 12 insertions, 30 deletions
diff --git a/patches/apply.pl b/patches/apply.pl index 85ba70da0..46307cd43 100755 --- a/patches/apply.pl +++ b/patches/apply.pl @@ -68,7 +68,7 @@ sub slurp { return $content; } -sub list_patches { +sub apply_patches { my @Patches = (); @@ -119,14 +119,6 @@ sub list_patches { push @Patches, find_file ($patch_dir, $_); } close (PatchList); - - return @Patches; -} - -sub apply_patches { - - my @Patches = list_patches (); - print "\n" unless $quiet; for $opt (@required_opts) { @@ -204,15 +196,6 @@ sub remove_patches { rmdir $applied_patches } -sub export_series { - - my @Patches = list_patches (); - - for my $patch (@Patches) { - print "$patch -p0\n"; - } -} - (@ARGV > 1) || die "Syntax:\napply <path-to-patchdir> <src root> [--distro=Debian] [patch flags '--dry-run' eg.]\n"; $patch_dir = shift (@ARGV); @@ -223,19 +206,16 @@ $applied_patches = $dest_dir.'/applied_patches'; $quiet = 0; $remove = 0; -$export = 0; $opts = ""; $distro = 'Ximian'; @required_opts = ( 'PATCHPATH' ); foreach $a (@ARGV) { - if ($a eq '-R') { # -R will also be appended to $opts - $remove = 1; + if ($a eq '-R') { + $remove = 1; } - if ($a eq '--export-series') { - $export = 1; - } elsif ($a eq '--quiet') { + if ($a eq '--quiet') { $quiet = 1; } elsif ($a =~ m/--distro=(.*)/) { $distro = $1; @@ -246,15 +226,17 @@ foreach $a (@ARGV) { $base_cmd = "patch -l -b -p0 $opts -d $dest_dir"; +# Compatibility for a little ... +if (!($patch_dir =~ /RC3_030729/)) { + $base_cmd .= ' --fuzz=1'; +} + print "Execute: $base_cmd for distro '$distro'\n" unless $quiet; -if ($export) { - export_series(); -} -elsif ($remove) { - remove_patches(); +if (!$remove) { + apply_patches(); } else { - apply_patches(); + remove_patches(); } |