aboutsummaryrefslogtreecommitdiff
path: root/sysutils/flexbackup
diff options
context:
space:
mode:
authorMarcus von Appen <mva@FreeBSD.org>2011-07-06 18:21:17 +0000
committerMarcus von Appen <mva@FreeBSD.org>2011-07-06 18:21:17 +0000
commit55667bb7b86432190bd7dcc066d176236b8bdfe2 (patch)
treeef41d1ce72397a177b1caa002f8d8dc959d2ca4c /sysutils/flexbackup
parent7fc211233c6cce31f92f728fb62b20d0102ec27d (diff)
downloadports-55667bb7b86432190bd7dcc066d176236b8bdfe2.tar.gz
ports-55667bb7b86432190bd7dcc066d176236b8bdfe2.zip
Notes
Diffstat (limited to 'sysutils/flexbackup')
-rw-r--r--sysutils/flexbackup/Makefile2
-rw-r--r--sysutils/flexbackup/files/patch-flexbackup90
2 files changed, 57 insertions, 35 deletions
diff --git a/sysutils/flexbackup/Makefile b/sysutils/flexbackup/Makefile
index b7f2bd4b3448..9059ab951eaa 100644
--- a/sysutils/flexbackup/Makefile
+++ b/sysutils/flexbackup/Makefile
@@ -7,7 +7,7 @@
PORTNAME= flexbackup
PORTVERSION= 1.2.1
-PORTREVISION= 4
+PORTREVISION= 5
CATEGORIES= sysutils
MASTER_SITES= http://www.edwinh.org/flexbackup/tarball/ \
http://www.reynoldsnet.org/flexbackup/tarball/
diff --git a/sysutils/flexbackup/files/patch-flexbackup b/sysutils/flexbackup/files/patch-flexbackup
index 1f6d10dfa245..c4e7cafcd09c 100644
--- a/sysutils/flexbackup/files/patch-flexbackup
+++ b/sysutils/flexbackup/files/patch-flexbackup
@@ -1,6 +1,16 @@
---- flexbackup.orig 2003-10-10 22:12:09.000000000 +0800
-+++ flexbackup 2008-09-13 22:12:36.000000000 +0800
-@@ -269,6 +269,7 @@
+--- flexbackup.orig 2003-10-10 16:12:09.000000000 +0200
++++ flexbackup 2011-07-06 18:55:24.000000000 +0200
+@@ -133,6 +133,9 @@
+ # tar has a limit of this many chars in its volume label
+ $::tar_max_label = 99;
+
++# Define the prune hash to avoid warnings with perl 5.12
++use vars qw( %prune );
++
+ # Get commandline flags
+ %::opt = ();
+ if (! &::GetOptions(\%::opt,
+@@ -269,6 +272,7 @@
untie(%::index);
}
@@ -8,7 +18,7 @@
exit(0);
######################################################################
-@@ -441,7 +442,7 @@
+@@ -441,7 +445,7 @@
# Get rid of trailing /
$dir = &nuke_trailing_slash($dir);
@@ -17,7 +27,7 @@
# have a different numeric level
if (!defined($::set_incremental)) {
$level = $::level;
-@@ -687,6 +688,8 @@
+@@ -687,6 +691,8 @@
$filename .= ".zip";
} elsif ($cfg::compress eq "compress") {
$filename .= ".Z";
@@ -26,7 +36,7 @@
}
} elsif ($cfg::type eq "afio") {
# tag these a little different, the archive file itself isn't a
-@@ -701,6 +704,8 @@
+@@ -701,6 +707,8 @@
$filename .= "-zip";
} elsif ($cfg::compress eq "compress") {
$filename .= "-Z";
@@ -35,7 +45,7 @@
}
}
-@@ -811,6 +816,11 @@
+@@ -811,6 +819,11 @@
($remove, @cmds) = &backup_filelist($label, $localdir, $title, $level, $remote);
}
@@ -47,7 +57,7 @@
# Nuke any tmp files used in the above routines
if ($remove ne '') {
push(@cmds, &maybe_remote_cmd("$::path{rm} -f $remove", $remote));
-@@ -827,6 +837,11 @@
+@@ -827,6 +840,11 @@
push(@cmds, &maybe_remote_cmd("$::path{rm} -f $pkglist", $remote));
}
}
@@ -59,7 +69,16 @@
# Strip multiple spaces
foreach my $cmd (@cmds) {
-@@ -1140,7 +1155,7 @@
+@@ -1035,7 +1053,7 @@
+ } else {
+ $prunekey = $dir;
+ }
+- if (defined(%{$::prune{$prunekey}})) {
++ if (defined($prune{$prunekey})) {
+ &log("| NOTE: \$prune is ignored for type=dump");
+ }
+
+@@ -1140,7 +1158,7 @@
$cmd .= "$::path{afio} -o ";
$cmd .= "$no_compress ";
$cmd .= "-z ";
@@ -68,7 +87,7 @@
$cmd .= "$::afio_z_flag ";
$cmd .= "$::afio_verb_flag ";
$cmd .= "$::afio_sparse_flag ";
-@@ -1286,8 +1301,8 @@
+@@ -1286,8 +1304,8 @@
$cmd .= "$::unz";
}
$cmd .= "(";
@@ -79,7 +98,7 @@
$cmd .= "$::path{cpio} -i ";
$cmd .= "-m ";
$cmd .= "-d ";
-@@ -1336,9 +1351,8 @@
+@@ -1336,9 +1354,8 @@
# Have to take leading './' off to make rsync's include/exclude work right
$cmd .= " | $::path{sed} -e \"s/\\.\\///g\" | ";
@@ -90,7 +109,7 @@
$cmd .= "--archive ";
$cmd .= "$::rsync_verb_flag ";
$cmd .= "--delete --delete-excluded ";
-@@ -1353,7 +1367,7 @@
+@@ -1353,7 +1370,7 @@
$cmd .= "$remote:";
}
}
@@ -99,7 +118,7 @@
push(@cmds, $cmd);
-@@ -1643,7 +1657,9 @@
+@@ -1643,7 +1660,9 @@
my $tmpfile = "$cfg::tmpdir/ar.$PROCESS_ID";
my $remove = '';
@@ -110,7 +129,7 @@
if (defined($remote) and ($level != 0)) {
my $time = &get_last_date($label, $level, 'numeric');
-@@ -1667,11 +1683,13 @@
+@@ -1667,11 +1686,13 @@
$cmd = "cd \"$dir\" && ";
$cmd .= &file_list_cmd( $dir, $stamp, 'newline', $level, $remote, '-maxdepth 1 ! -type d');
$cmd .= "> $filelist; ";
@@ -125,7 +144,7 @@
$cmd .= "; $::path{cat} $tmpfile $::z";
# Buffer both sides if remote
-@@ -1785,12 +1803,9 @@
+@@ -1785,12 +1806,9 @@
$cmd = "cd \"$dir\" && ";
$cmd .= &file_list_cmd( $dir, $stamp, 'newline', $level, $remote);
@@ -139,7 +158,7 @@
$cmd .= "; $::path{cat} $tmpfile $::z";
# Buffer both sides if remote
-@@ -2700,7 +2715,7 @@
+@@ -2700,7 +2718,7 @@
# First check if things are defined in the config file
# Checks exist, true/false, or one of options
&checkvar(\$cfg::type,'type','dump afio cpio tar star pax zip ar shar lha copy rsync filelist','tar');
@@ -148,7 +167,7 @@
&checkvar(\$cfg::compr_level,'compr_level','exist','4');
&checkvar(\$cfg::verbose,'verbose','bool','true');
&checkvar(\$cfg::sparse,'sparse','bool','true');
-@@ -2750,8 +2765,10 @@
+@@ -2750,8 +2768,10 @@
$::path{'find'} = &checkinpath('find');
$::path{'dd'} = &checkinpath('dd');
$::path{'printf'} = &checkinpath('printf');
@@ -160,7 +179,7 @@
# Check device (or dir)
$::ftape = 0;
-@@ -3001,6 +3018,16 @@
+@@ -3001,6 +3021,16 @@
$::z = " | $::path{zip} -$cfg::compr_level - -";
$::unz = "$::path{funzip} | ";
}
@@ -177,7 +196,7 @@
} else {
$::z = "";
$::unz = "";
-@@ -3059,12 +3086,11 @@
+@@ -3059,12 +3089,11 @@
$::read_cmd = "$bufcmd $read_flags";
} elsif ($cfg::buffer eq "mbuffer") {
@@ -191,7 +210,7 @@
$::buffer_cmd = " | $bufcmd";
$::write_cmd = "$bufcmd -f -o ";
-@@ -3075,7 +3101,6 @@
+@@ -3075,7 +3104,6 @@
}
}
} else {
@@ -199,7 +218,7 @@
# If buffering disabled, use dd or cat depending on if blocking turned off on not
if ($cfg::blksize eq '0') {
$::buffer_cmd = "";
-@@ -3252,6 +3277,10 @@
+@@ -3252,6 +3280,10 @@
$::afio_z_flag = "-P $::path{$cfg::compress} -Q -c -Z";
$::afio_unz_flag = "-P $::path{$cfg::compress} -Q -d -Q -c -Z";
@@ -210,7 +229,7 @@
}
$::unz = ""; # Reset & just use this for reading the archive file.
-@@ -3415,7 +3444,7 @@
+@@ -3415,7 +3447,7 @@
$::path{'lha'} = &checkinpath('lha');
push(@::remoteprogs, $::path{'lha'});
@@ -219,7 +238,7 @@
warn("Using type \"lha\" with compress=$cfg::compress makes no sense");
warn("Setting compression to false");
$::unz = "";
-@@ -3442,6 +3471,15 @@
+@@ -3442,6 +3474,15 @@
push(@::errors,"\$tmpdir $cfg::tmpdir is not writable");
}
@@ -235,7 +254,7 @@
# Levels
if (defined($::opt{'level'}) and
(defined($::opt{'incremental'}) or
-@@ -3781,7 +3819,7 @@
+@@ -3781,7 +3822,7 @@
# Try and guess file types and commpression scheme
# might as well since we are reading from a file in this case
@@ -244,7 +263,7 @@
$cfg::type = $1;
$cfg::compress = $2;
$cfg::type =~ s/^a$/ar/;
-@@ -3789,16 +3827,18 @@
+@@ -3789,16 +3830,18 @@
$cfg::compress =~ s/bz2/bzip2/;
$cfg::compress =~ s/lzo/lzop/;
$cfg::compress =~ s/Z/compress/;
@@ -264,10 +283,13 @@
&log("| Auto-set to type=$cfg::type compress=$cfg::compress");
&optioncheck(); # redo to set a few variables over
-@@ -4843,23 +4883,31 @@
+@@ -4841,25 +4884,32 @@
+ } else {
+ $prunekey = $dir;
}
-
- if (defined(%{$::prune{$prunekey}})) {
+-
+- if (defined(%{$::prune{$prunekey}})) {
++ if (defined($prune{$prunekey})) {
+ my $rex;
# FreeBSD needs -E (above) and no backslashes around the (|) chars
if ($::uname =~ /FreeBSD/) {
@@ -305,7 +327,7 @@
$cmd .= "$::mountpoint_flag ";
$cmd .= "! -type s ";
-@@ -5229,6 +5277,7 @@
+@@ -5229,6 +5279,7 @@
my $tmp_script = "$cfg::tmpdir/buftest.$host.$PROCESS_ID.sh";
my $retval = 0;
my $pipecmd;
@@ -313,7 +335,7 @@
$buffer_cmd =~ s:^\s*\|\s*::;
$buffer_cmd =~ s:\s*\|\s*$::;
-@@ -5236,14 +5285,14 @@
+@@ -5236,14 +5287,14 @@
# Create a script which tests the buffer program
open(SCR,"> $tmp_script") || die;
print SCR "#!/bin/sh\n";
@@ -331,7 +353,7 @@
print SCR "else\n";
print SCR " echo \"unsuccessful: exit code \$res: \$out\" \n";
print SCR "fi\n";
-@@ -5254,14 +5303,22 @@
+@@ -5254,14 +5305,22 @@
print $::msg "| Checking '$cfg::buffer' on this machine... ";
$pipecmd = "sh $tmp_script ";
} else {
@@ -356,7 +378,7 @@
if (/^unsuccessful: exit code (\d+): (.*)/) {
$retval = $1;
my $out = $2;
-@@ -5290,11 +5347,15 @@
+@@ -5290,11 +5349,15 @@
print $::msg "\n(debug) $pipecmd\n";
}
@@ -373,7 +395,7 @@
unlink("$tmp_script");
return($retval);
-@@ -5396,10 +5457,10 @@
+@@ -5396,10 +5459,10 @@
my $shell = $1;
my $ver = $2;
if ($shell eq 'bash') {
@@ -387,7 +409,7 @@
}
} else {
$::shelltype{$host} = $shell;
-@@ -5686,3 +5747,5 @@
+@@ -5686,3 +5749,5 @@
return($spinner[$index]);
}