diff options
author | V3n3RiX <venerix@redcorelinux.org> | 2018-07-14 21:03:06 +0100 |
---|---|---|
committer | V3n3RiX <venerix@redcorelinux.org> | 2018-07-14 21:03:06 +0100 |
commit | 8376ef56580626e9c0f796d5b85b53a0a1c7d5f5 (patch) | |
tree | 7681bbd4e8b05407772df40a4bf04cbbc8afc3fa /app-backup/flexbackup | |
parent | 30a9caf154332f12ca60756e1b75d2f0e3e1822d (diff) |
gentoo resync : 14.07.2018
Diffstat (limited to 'app-backup/flexbackup')
15 files changed, 1021 insertions, 0 deletions
diff --git a/app-backup/flexbackup/Manifest b/app-backup/flexbackup/Manifest new file mode 100644 index 000000000000..63695e9c0266 --- /dev/null +++ b/app-backup/flexbackup/Manifest @@ -0,0 +1,15 @@ +AUX flexbackup-1.2.1-afio-large-files.patch 401 BLAKE2B 09d95c6f67bf368de94699dc7e597416c8a82971da780a772bd477d1fa66ad1e26057ee4f2ef814915f1dfddfebd40111fe0f883a910a1d44b3533c115ac9b23 SHA512 ad94ebbabe413b51d4f984f9a2d80b69f2998037512c0ac6077d92d0bb7f594a444503f196e668d0e91d35ad543f2cba73129ad31007a43de228fb50c0b4e870 +AUX flexbackup-1.2.1-bash.patch 445 BLAKE2B b542d44ad8e01cb27fa751efc15d5e6bd0c82de3048e193a91b876d679ba92fb137a38a5b5febb09aee299d68613e6a62693993fb8cff2615d4b4d8c0f05025c SHA512 ec74be2043c5791288abf9e5303cc24caa55ac0d14f51a7cfdd6b495f97bef1dece39e8dd0492a14df18a9b495f74463247586e2edefe0f897429631c9809745 +AUX flexbackup-1.2.1-lzma.patch 4336 BLAKE2B ed346685c6faef20ab5838f0479cd64b3dfd3eaf0c481c7707fe6ab37fbeb48549cd6fb6694f49ac0d495891b004fd07c8cb41bf0db6f9f4d84a59ad120e3f9a SHA512 de23710262aaaa79e7dda63221965267a4751cb5c1681b8d4db6ab7a065aa8dab3e6c3097d339a793650a28627eeffefeef408612c08a9bbe3f14d383179338e +AUX flexbackup-1.2.1-mbuffer-switch.patch 5550 BLAKE2B d5c7d595dece5e9101b059ef8dec024f70a7c1228a4eac7b503b8e9f0e5437fab7da365b8b02a35b0210041649a65d6f4fa1e448627ae5fdc9185d848a7fe27f SHA512 1ad0e5ac04f0c44c970954aefd62f465d1c9c9604c6ab90cd56d61d44aa8b4c23e8befe992380e10d74fdf043975969431185e1ae66297bb630a105fd5329b4c +AUX flexbackup-1.2.1-perl-5.12-deprecation-warning.patch 814 BLAKE2B 8f6264dc7a47bcf08329b537b96ce5e04d82a455dc19fddccd98e2144552471a9b9c78a2088fc558250c29cd054f52c483f04c454facf5310b0e3f01099bbb55 SHA512 ea77998e18fb7ae6612983ab2b6ebc1ab6de6056f5a60aada283ba593a60973953062dcaac9f9d2aa7068384ac4a8a0d72c439cf7cdd3c8a2b304d7ae779f302 +AUX flexbackup-1.2.1-perl-5.16-deprecation-warning.patch 374 BLAKE2B af63367cc84053551d6a3bdd57b76d796b9258058536bb506dec1ac3777d39d0b892649f23ca5f4a901f502aa0f9537535046ff66d3aada2a99c5132919fda7d SHA512 cf994cc48c735b2fe15f858b2f7f8e3d83012ad780e42b1ec05c2af2dacf04da844810e5c87d608f9bab40d2366507f2af017a7c95128f17141ce5afd5b228a4 +AUX flexbackup-1.2.1-prune.patch 5544 BLAKE2B 26f3b73f2b586a103ca3c6d16b9b84a4314537258a9f2bd26d56796dcff51233220bdabca1842ce58e406fd6b4e821bdcaac02ac8190b5c7c740915214d9025a SHA512 a2c1d7a82b3328b52a36dd04fa3f3e2a8b5918de9f3f089ef7342192bae023b3fe844ae847bf09d21348a794c06ee49185d6e49e116da2794121f005ea74b6c0 +AUX flexbackup-1.2.1-quieten.patch 418 BLAKE2B 5567c62d03043846471b53ea6df09bb92ce327e94f4f9309d5dace03cf8868292e60b7cf2ce8e8caaaa10b30653910d7e4cf4d3893111e11f113ecebab32da89 SHA512 bf263fb3c3301eb49942b1c7be3348b8b3b8584776baadc35bc34c709887a7dc48e534bc65dd543f835e6ebfe4747e9f074ded01199f4458ae974eb9565feaa2 +AUX flexbackup-1.2.1-remote-bufftest.patch 1940 BLAKE2B 17af279a19d655a9e16bb575f399fa7d4450543841ae8067758bfe388ca91b30c6c0519de2763779e2044961af467e9b3213b4eb430b3d16487ab0579d13a016 SHA512 76a3d6cb556596204791d98534ed13fc3738bed8642b4defef839d221510f6fad2d365abc524f368f43f88c710b6b6547cffd4be0e9a4ce53105bdc9dc1ed10e +AUX flexbackup-1.2.1-secure-tempfile.patch 2563 BLAKE2B 34ce762db2abaf426e165ab2971bda4a9210b93e1b5abbd5be0de79dbe82109297153c55d365af4d0d47103afd9e4809079963badd5e633bc18f2a353d969661 SHA512 14bc8bccdb9c094bea92f97a7760079233364a87530750d0f904e3831c6bf4dca69cfdfdc578af316b65d8d7ff3d1c00c53bb8aa17acd2ecd009b919d87cd1f6 +AUX flexbackup-1.2.1-spaces-in-filenames.patch 11037 BLAKE2B d0ac4cef902d5d63a099bd64c89c6ed050d3d791d4d7093ff269e21badc04b3634d5839623641ee087a48559f57db6684c6b405294b7f2671bfb0118575be30e SHA512 58fdb4fbc59eaeefaf5a552abab0adf8a4d4e258cc737a1b310c00bef6ebf61c9fa55f3b3b7c68553ed224e12c082d03a9c16fdacfa2a44a70349bd882cfe987 +AUX flexbackup-1.2.1-tar-1.29.patch 514 BLAKE2B c5ff11dd0527d376a596b09781ab57c1f5f8a0a3d1b07390a97228b4a11e7ebb95aff896187b007b065a2e3ae82f2596596a367097e9b085c44f62a529d1ee8d SHA512 b8a28c93db2b8f04bcf7c56406fd0457b837e9afea30a5a1cf37bdd64554bbb4ee665b5c15af24701eeab10a1b1c2d31371b7c0ce32cbfb29223ac34956cc962 +DIST flexbackup-1.2.1.tar.gz 80158 BLAKE2B 0e54c275ddd218184195bb5bc873db10ab144409eed9d87410e5b7ba5ed09297fbdb58f3eb69b5d55c1ec727fe79f51b376914542ba5eae70ab4f87351b6dd4c SHA512 17630bc46657becdf5d5bde4852fd6cebe189fe54d381bda6471aa2e1db1ff082ba24461e2c22ba5805c2d93ac7f9805ffbdc4904da017f1b163cc21b5a3974b +EBUILD flexbackup-1.2.1-r13.ebuild 2791 BLAKE2B 5eb4c59ef05a125252945f8739fcbd63fabc295b4adee19830c32d8885a13ef558a04af230a97f3741aee2ee4dc3b58d9cd99b6c153698981dc38488abf36847 SHA512 f33313f8842f8bd66e26ee3e1bb336c65b9cbbeba1b1d35603a7b07e487d9f5688dba5dcf58c87e929dd12b2b01966f226be5074c0ab7ddf1c44ff8bf518e0f9 +MISC metadata.xml 297 BLAKE2B f0205ea431c1b919654d761a82af8cee33ba2280a5c920242a8588edc7fd857166c07c4cfecfb28f621a7c3e77fc8ff6d21e84b7b20c0db1512129e8ed15a252 SHA512 a2fd29aba380cb3b9322131f97beed0d432569ab612118bf1a9a428a93602c859014face05fc8582c8dfdf6858296a36ae6754fdc45a78715058d779df3f7e0a diff --git a/app-backup/flexbackup/files/flexbackup-1.2.1-afio-large-files.patch b/app-backup/flexbackup/files/flexbackup-1.2.1-afio-large-files.patch new file mode 100644 index 000000000000..bf5ea230c85c --- /dev/null +++ b/app-backup/flexbackup/files/flexbackup-1.2.1-afio-large-files.patch @@ -0,0 +1,13 @@ +Index: flexbackup +=================================================================== +--- flexbackup (revision 808) ++++ flexbackup (working copy) +@@ -1155,7 +1155,7 @@ + $cmd .= "$::path{afio} -o "; + $cmd .= "$no_compress "; + $cmd .= "-z "; +- $cmd .= "-1 m "; ++ $cmd .= "-1 mC "; + $cmd .= "$::afio_z_flag "; + $cmd .= "$::afio_verb_flag "; + $cmd .= "$::afio_sparse_flag "; diff --git a/app-backup/flexbackup/files/flexbackup-1.2.1-bash.patch b/app-backup/flexbackup/files/flexbackup-1.2.1-bash.patch new file mode 100644 index 000000000000..a9da86a8e135 --- /dev/null +++ b/app-backup/flexbackup/files/flexbackup-1.2.1-bash.patch @@ -0,0 +1,18 @@ +--- flexbackup 2005-06-16 20:28:04.577086588 -0700 ++++ flexbackup 2005-06-16 22:21:14.787322560 -0700 +@@ -5396,10 +5396,10 @@ + my $shell = $1; + my $ver = $2; + if ($shell eq 'bash') { +- if ($ver =~ m/^2/) { +- $::shelltype{$host} = 'bash2'; +- } else { ++ if ($ver =~ m/^1/) { + $::shelltype{$host} = 'bash1'; ++ } else { ++ $::shelltype{$host} = 'bash2'; + } + } else { + $::shelltype{$host} = $shell; + + diff --git a/app-backup/flexbackup/files/flexbackup-1.2.1-lzma.patch b/app-backup/flexbackup/files/flexbackup-1.2.1-lzma.patch new file mode 100644 index 000000000000..95fa79ba606d --- /dev/null +++ b/app-backup/flexbackup/files/flexbackup-1.2.1-lzma.patch @@ -0,0 +1,114 @@ +--- flexbackup 2003-10-10 15:12:09.000000000 +0100 ++++ flexbackup 2007-01-15 01:08:18.000000000 +0000 +@@ -687,6 +687,8 @@ + $filename .= ".zip"; + } elsif ($cfg::compress eq "compress") { + $filename .= ".Z"; ++ } elsif ($cfg::compress eq "lzma") { ++ $filename .= ".lzma"; + } + } elsif ($cfg::type eq "afio") { + # tag these a little different, the archive file itself isn't a +@@ -701,6 +703,8 @@ + $filename .= "-zip"; + } elsif ($cfg::compress eq "compress") { + $filename .= "-Z"; ++ } elsif ($cfg::compress eq "lzma") { ++ $filename .= "-lzma"; + } + } + +@@ -2700,7 +2704,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'); +- &checkvar(\$cfg::compress,'compress','gzip bzip2 lzop compress zip false hardware','gzip'); ++ &checkvar(\$cfg::compress,'compress','gzip bzip2 lzop compress zip false hardware lzma','gzip'); + &checkvar(\$cfg::compr_level,'compr_level','exist','4'); + &checkvar(\$cfg::verbose,'verbose','bool','true'); + &checkvar(\$cfg::sparse,'sparse','bool','true'); +@@ -3001,6 +3005,16 @@ + $::z = " | $::path{zip} -$cfg::compr_level - -"; + $::unz = "$::path{funzip} | "; + } ++ } elsif ($cfg::compress eq "lzma") { ++ $::path{'lzma'} = &checkinpath($cfg::compress); ++ push(@::remoteprogs, $::path{$cfg::compress}); ++ if ($cfg::compr_level !~ m/^[123456789]$/) { ++ push(@::errors,"\$compr_level must be set to 1-9"); ++ } else { ++ $::z = " | $::path{$cfg::compress} -$cfg::compr_level "; ++ } ++ $::unz = "$::path{$cfg::compress} -d | "; ++ + } else { + $::z = ""; + $::unz = ""; +@@ -3252,6 +3266,10 @@ + $::afio_z_flag = "-P $::path{$cfg::compress} -Q -c -Z"; + $::afio_unz_flag = "-P $::path{$cfg::compress} -Q -d -Q -c -Z"; + ++ } elsif ($cfg::compress eq "lzma") { ++ $::afio_z_flag = "-P $::path{$cfg::compress} -Q -$cfg::compr_level -Z"; ++ $::afio_unz_flag = "-P $::path{$cfg::compress} -Q -d -Z"; ++ + } + $::unz = ""; # Reset & just use this for reading the archive file. + +@@ -3415,7 +3433,7 @@ + $::path{'lha'} = &checkinpath('lha'); + push(@::remoteprogs, $::path{'lha'}); + +- if ($cfg::compress =~ /^(gzip|bzip2|lzop|compress|zip)$/) { ++ if ($cfg::compress =~ /^(gzip|bzip2|lzop|compress|zip|lzma)$/) { + warn("Using type \"lha\" with compress=$cfg::compress makes no sense"); + warn("Setting compression to false"); + $::unz = ""; +@@ -3781,7 +3799,7 @@ + + # Try and guess file types and commpression scheme + # might as well since we are reading from a file in this case +- if ($file =~ m/\.(dump|cpio|tar|star|pax|a|shar|filelist)\.(gz|bz2|lzo|Z|zip)$/) { ++ if ($file =~ m/\.(dump|cpio|tar|star|pax|a|shar|filelist)\.(gz|bz2|lzo|Z|zip|lzma)$/) { + $cfg::type = $1; + $cfg::compress = $2; + $cfg::type =~ s/^a$/ar/; +@@ -3789,16 +3807,18 @@ + $cfg::compress =~ s/bz2/bzip2/; + $cfg::compress =~ s/lzo/lzop/; + $cfg::compress =~ s/Z/compress/; ++ $cfg::compress =~ s/lzma/lzma/; + &log("| Auto-set to type=$cfg::type compress=$cfg::compress"); + &optioncheck(); # redo to set a few variables over + +- } elsif ($file =~ m/\.afio-(gz|bz2|lzo|Z|zip)$/) { ++ } elsif ($file =~ m/\.afio-(gz|bz2|lzo|Z|zip|lzma)$/) { + $cfg::type = "afio"; + $cfg::compress = $1; + $cfg::compress =~ s/gz/gzip/; + $cfg::compress =~ s/bz2/bzip2/; + $cfg::compress =~ s/lzo/lzop/; + $cfg::compress =~ s/Z/compress/; ++ $cfg::compress =~ s/lzma/lzma/; + &log("| Auto-set to type=$cfg::type compress=$cfg::compress"); + &optioncheck(); # redo to set a few variables over + +@@ -5686,3 +5706,5 @@ + + return($spinner[$index]); + } ++ ++ +--- flexbackup.conf 2007-01-15 01:11:36.000000000 +0000 ++++ flexbackup.conf.new 2007-01-15 01:21:46.000000000 +0000 +@@ -33,8 +33,8 @@ + $prune{'/'} = "tmp proc"; + + # Compression +-$compress = 'gzip'; # one of false/gzip/bzip2/lzop/zip/compress/hardware +-$compr_level = '4'; # compression level (1-9) (for gzip/bzip2/lzop/zip) ++$compress = 'gzip'; # one of false/gzip/bzip2/lzop/zip/compress/hardware/lzma ++$compr_level = '4'; # compression level (1-9) (for gzip/bzip2/lzop/zip/lzma) + + # Buffering program - to help streaming + $buffer = 'false'; # one of false/buffer/mbuffer diff --git a/app-backup/flexbackup/files/flexbackup-1.2.1-mbuffer-switch.patch b/app-backup/flexbackup/files/flexbackup-1.2.1-mbuffer-switch.patch new file mode 100644 index 000000000000..d22e40f24c26 --- /dev/null +++ b/app-backup/flexbackup/files/flexbackup-1.2.1-mbuffer-switch.patch @@ -0,0 +1,130 @@ +Common subdirectories: flexbackup-1.2.1-r3/contrib and flexbackup-1.2.1-r4/contrib +diff -ubB flexbackup-1.2.1-r3/flexbackup flexbackup-1.2.1-r4/flexbackup +--- flexbackup-1.2.1-r3/flexbackup 2007-04-14 17:03:34.000000000 -0400 ++++ flexbackup-1.2.1-r4/flexbackup 2007-04-14 17:09:48.000000000 -0400 +@@ -442,7 +442,7 @@ + # Get rid of trailing / + $dir = &nuke_trailing_slash($dir); + +- # If level is icremental for the set, each dir might ++ # If level is incremental for the set, each dir might + # have a different numeric level + if (!defined($::set_incremental)) { + $level = $::level; +@@ -3090,7 +3090,7 @@ + push(@::remoteprogs, $::path{'mbuffer'}); + + my $megs = $cfg::buffer_megs . "M"; +- my $bufcmd = "$::path{mbuffer} -q -m $megs -p $cfg::buffer_fill_pct $mbuffer_blk_flag "; ++ my $bufcmd = "$::path{mbuffer} -q -m $megs -P $cfg::buffer_fill_pct $mbuffer_blk_flag "; + + $::buffer_cmd = " | $bufcmd"; + $::write_cmd = "$bufcmd -f -o "; +@@ -4884,18 +4884,24 @@ + } + + if (defined(%{$::prune{$prunekey}})) { ++ my $rex; + # FreeBSD needs -E (above) and no backslashes around the (|) chars + if ($::uname =~ /FreeBSD/) { +- $cmd .= '-regex "\./('; +- $cmd .= join('|', keys %{$::prune{$prunekey}}); +- $cmd .= ')/.*" '; +- } else { +- $cmd .= '-regex "\./\('; +- $cmd .= join('\|', keys %{$::prune{$prunekey}}); +- $cmd .= '\)/.*" '; +- } ++ $rex = '-regex "\./('; ++ $rex .= join('|', keys %{$::prune{$prunekey}}); ++ $rex .= ')/.*" '; ++ } else { ++ $rex = '-regex "\./\('; ++ $rex .= join('\|', keys %{$::prune{$prunekey}}); ++ $rex .= '\)/.*" '; ++ } ++ # Show what the darn thing is constructing for prune expressions. ++ &log("| \"find\" regex for pruning is: $rex"); ++ $cmd .= $rex; + $cmd .= '-prune -o '; + } else { ++ # Show what the darn thing is constructing for prune expressions. ++ &log("| No pruning defined for this tree."); + # Can't use find -depth with -prune (see single unix spec etc) + # (not toally required anyway, only if you are archiving dirs you + # don't have permissions on and are running as non-root) +diff -ubB flexbackup-1.2.1-r3/flexbackup.conf flexbackup-1.2.1-r4/flexbackup.conf +--- flexbackup-1.2.1-r3/flexbackup.conf 2007-04-14 17:03:35.000000000 -0400 ++++ flexbackup-1.2.1-r4/flexbackup.conf 2007-04-14 17:09:48.000000000 -0400 +@@ -30,6 +30,45 @@ + # A space-separated list of directories to prune from each backup. + # Key is a filesystem or host:dir spec as outlined above + # regular expressions allowed (not shell-type wildcards!) ++# ++# Note: These directories are actually regular expressions and must ++# match "find" output relative to the path of the current backup set. This ++# means that different exclusions are needed for different backup sets. ++# This is a little tricky, so, read on. ++# ++# The regular expressions are processed by "find" but, before "find" is run, ++# FlexBackup changes into the base directory of the backup set in progress. ++# FlexBackup then runs "find" with a path of "." which means all output lines ++# start with "./". To be helpful, FlexBackup packages each space-separated ++# prune directory as follows. If you have a prune list like this ++# ++# $prune{'/somedir'} = "one two three"; ++# ++# then, the constructed -regex argument to "find" looks like this ++# ++# -regex "\./\(one\|two\|three\)/.*" ++# ++# The last thing you need to know is that FlexBackup only uses the prune ++# terms that match the current base directory in the set you're backing ++# up. For example, if your backup set definition looks like this ++# ++# $set{'daily'} = "/home /root /var /usr"; ++# ++# and you want to do some exclusions in "/home" and "/var" (but not the other ++# directories), you must set up a prune list for those two directories ++# separately. For example, to exclude bert's and ernie's home directories plus ++# /var/tmp, you would need the following: ++# ++# $prune{'/home'} = "bert ernie"; ++# $prune{'/var'} = "tmp"; ++# ++# In particular, combining these *does not* work. For example, this ++# ++# $prune{'/'} = "home/bert home/ernie var/tmp"; ++# ++# does not work, unless, of course, your backup set is backing up "/", ++# which our example is not. ++# + $prune{'/'} = "tmp proc"; + + # Compression +@@ -84,7 +123,8 @@ + # True to try and preserve file access times during backup, if the selected + # archive program can do so. Note that if this is true, -cnewer checks (file + # permission/status changes only, not content) are turned off when deciding +-# which files to archive on the local system. ++# which files to archive on the local system. This is because preserving the ++# access time changes the permission/status change time in the filesystem. + $atime_preserve = 'false'; + + # Span across filesytems? ("dump" will ignore this option) +@@ -97,8 +137,13 @@ + # leading directories (the filesystem specs above or the "-dir" flag). + # Matches paths, not filenames, so put .* on the front/back as needed. + # Comment these out to exclude nothing. +-$exclude_expr[0] = '.*/[Cc]ache/.*'; +-$exclude_expr[1] = '.*~$'; ++# ++# Note: The first example line breaks portage in a restored backup because ++# "/usr/lib/portage/pym/cache" is not backed up. Way too general! The moral ++# of this story is, be very careful with global excludes. The second example ++# is probably okay. ++# $exclude_expr[0] = '.*/[Cc]ache/.*'; ++# $exclude_expr[1] = '.*~$'; + + # If true (default), and using a tape device, level zero "set" backups + # assume you want to erase and use a new tape for each set. If false, level diff --git a/app-backup/flexbackup/files/flexbackup-1.2.1-perl-5.12-deprecation-warning.patch b/app-backup/flexbackup/files/flexbackup-1.2.1-perl-5.12-deprecation-warning.patch new file mode 100644 index 000000000000..2976eab916f1 --- /dev/null +++ b/app-backup/flexbackup/files/flexbackup-1.2.1-perl-5.12-deprecation-warning.patch @@ -0,0 +1,29 @@ +--- flexbackup.~1~ 2010-10-09 13:19:27.633694860 +0200 ++++ flexbackup 2010-10-09 13:21:52.396818511 +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, +@@ -1050,6 +1053,6 @@ + } else { + $prunekey = $dir; + } +- if (defined(%{$::prune{$prunekey}})) { ++ if (defined($prune{$prunekey})) { + &log("| NOTE: \$prune is ignored for type=dump"); + } +@@ -4885,7 +4885,7 @@ + $prunekey = $dir; + } + +- if (defined(%{$::prune{$prunekey}})) { ++ if (defined($prune{$prunekey})) { + my $rex; + # FreeBSD needs -E (above) and no backslashes around the (|) chars + if ($::uname =~ /FreeBSD/) { diff --git a/app-backup/flexbackup/files/flexbackup-1.2.1-perl-5.16-deprecation-warning.patch b/app-backup/flexbackup/files/flexbackup-1.2.1-perl-5.16-deprecation-warning.patch new file mode 100644 index 000000000000..285cf26313f9 --- /dev/null +++ b/app-backup/flexbackup/files/flexbackup-1.2.1-perl-5.16-deprecation-warning.patch @@ -0,0 +1,11 @@ +--- flexbackup 2010-12-30 08:09:10.000000000 +0100 ++++ flexbackup 2013-12-24 15:44:25.000000000 +0100 +@@ -2688,7 +2688,7 @@ + } + + # Flag old config file +- if (defined(@cfg::filesystems) or defined($cfg::mt_var_blksize)) { ++ if (@cfg::filesystems or $cfg::mt_var_blksize) { + # so strict shuts up + my $junk = @cfg::filesystems; + $junk = $cfg::mt_var_blksize; diff --git a/app-backup/flexbackup/files/flexbackup-1.2.1-prune.patch b/app-backup/flexbackup/files/flexbackup-1.2.1-prune.patch new file mode 100644 index 000000000000..35081932e6f1 --- /dev/null +++ b/app-backup/flexbackup/files/flexbackup-1.2.1-prune.patch @@ -0,0 +1,136 @@ +diff -ub flexbackup-old/flexbackup flexbackup-new/flexbackup +--- flexbackup-old/flexbackup 2007-05-11 20:14:13.000000000 -0400 ++++ flexbackup-new/flexbackup 2007-05-11 20:22:36.000000000 -0400 +@@ -3085,7 +3085,6 @@ + $::read_cmd = "$bufcmd $read_flags"; + + } elsif ($cfg::buffer eq "mbuffer") { +- + $::path{'mbuffer'} = &checkinpath('mbuffer'); + push(@::remoteprogs, $::path{'mbuffer'}); + +@@ -3101,7 +3100,6 @@ + } + } + } else { +- + # If buffering disabled, use dd or cat depending on if blocking turned off on not + if ($cfg::blksize eq '0') { + $::buffer_cmd = ""; +@@ -4887,18 +4885,19 @@ + my $rex; + # FreeBSD needs -E (above) and no backslashes around the (|) chars + if ($::uname =~ /FreeBSD/) { +- $rex = '-regex "\./('; ++ $rex = '"\./('; + $rex .= join('|', keys %{$::prune{$prunekey}}); +- $rex .= ')/.*" '; ++ $rex .= ')"'; + } else { +- $rex = '-regex "\./\('; ++ $rex = '"\./\('; + $rex .= join('\|', keys %{$::prune{$prunekey}}); +- $rex .= '\)/.*" '; ++ $rex .= '\)"'; + } + # Show what the darn thing is constructing for prune expressions. +- &log("| \"find\" regex for pruning is: $rex"); +- $cmd .= $rex; +- $cmd .= '-prune -o '; ++ &log("| \"find\" regex for pruning is:"); ++ &log("| $rex"); ++ &line(); ++ $cmd .= '-regex ' . $rex . ' -prune -o '; + } else { + # Show what the darn thing is constructing for prune expressions. + &log("| No pruning defined for this tree."); +diff -ub flexbackup-old/flexbackup.1 flexbackup-new/flexbackup.1 +--- flexbackup-old/flexbackup.1 2007-05-11 20:14:13.000000000 -0400 ++++ flexbackup-new/flexbackup.1 2007-05-11 20:09:58.000000000 -0400 +@@ -48,7 +48,7 @@ + Extract (restore) the files listed in text file \(dqfilelist\(dq into your + current working directory. + .TP +-\fBflexbackup\fR \fI-extract\fR \fI-flist\fR <\fIfilename\fR> ++\fBflexbackup\fR \fI-extract\fR \fI-onefile\fR <\fIfilename\fR> + Extract (restore) the single file named \(dqfilename\(dq into your current + working directory. + .TP +diff -ub flexbackup-old/flexbackup.conf flexbackup-new/flexbackup.conf +--- flexbackup-old/flexbackup.conf 2007-05-11 20:14:13.000000000 -0400 ++++ flexbackup-new/flexbackup.conf 2007-05-11 20:26:48.000000000 -0400 +@@ -28,10 +28,10 @@ + + # Subtree pruning + # A space-separated list of directories to prune from each backup. +-# Key is a filesystem or host:dir spec as outlined above +-# regular expressions allowed (not shell-type wildcards!) ++# Key is a filesystem or host:dir spec as outlined above. ++# Regular expressions are allowed (not shell-type wildcards!) + # +-# Note: These directories are actually regular expressions and must ++# Note: These "directories" are actually regular expressions and must + # match "find" output relative to the path of the current backup set. This + # means that different exclusions are needed for different backup sets. + # This is a little tricky, so, read on. +@@ -46,9 +46,11 @@ + # + # then, the constructed -regex argument to "find" looks like this + # +-# -regex "\./\(one\|two\|three\)/.*" ++# -regex "\./(one|two|three)" + # +-# The last thing you need to know is that FlexBackup only uses the prune ++# (with characters escaped as necessary depending on your environment). ++# ++# Another thing you need to know is that FlexBackup only uses the prune + # terms that match the current base directory in the set you're backing + # up. For example, if your backup set definition looks like this + # +@@ -66,9 +68,16 @@ + # + # $prune{'/'} = "home/bert home/ernie var/tmp"; + # +-# does not work, unless, of course, your backup set is backing up "/", ++# doesn't work, unless, of course, your backup set is backing up "/", + # which our example is not. + # ++# Many other complex and abstruse variations are possible. Here's one ++# interesting corner case. If you want to preserve a directory but none of its ++# contents, you can do it. Picking on ernie from our previous example, preserve ++# only his home directory: ++# ++# $prune{'/home'} = "ernie/.*"; ++# + $prune{'/'} = "tmp proc"; + + # Compression +@@ -138,10 +147,10 @@ + # Matches paths, not filenames, so put .* on the front/back as needed. + # Comment these out to exclude nothing. + # +-# Note: The first example line breaks portage in a restored backup because +-# "/usr/lib/portage/pym/cache" is not backed up. Way too general! The moral +-# of this story is, be very careful with global excludes. The second example +-# is probably okay. ++# Gentoo note: The first example line breaks portage in a restored backup ++# because "/usr/lib/portage/pym/cache" is not backed up. Way too general! ++# The moral of this story is, be very careful with global excludes. The ++# second example is probably okay. + # $exclude_expr[0] = '.*/[Cc]ache/.*'; + # $exclude_expr[1] = '.*~$'; + +diff -ub flexbackup-old/flexbackup.conf.5 flexbackup-new/flexbackup.conf.5 +--- flexbackup-old/flexbackup.conf.5 2007-05-11 20:14:13.000000000 -0400 ++++ flexbackup-new/flexbackup.conf.5 2007-05-11 20:09:58.000000000 -0400 +@@ -40,7 +40,9 @@ + \fB$prune{\fI'/'\fR}\fR = \fI'tmp proc'\fR; + Configure subtree pruning. A space-separated list of directories to prune from + each backup. Key is a filesystem/directory or \(dqhost:directory\(dq spec as +-outlined above regular expressions allowed (not shell-type wildcards!). ++outlined above. Regular expressions allowed (not shell-type wildcards!). There ++is additional explanation (and a lot of examples) in the provided configuration ++file. + .TP + \fB$compress\fR = \fI'false|gzip|bzip2|lzop|zip|compress|hardware'\fR; + .TQ diff --git a/app-backup/flexbackup/files/flexbackup-1.2.1-quieten.patch b/app-backup/flexbackup/files/flexbackup-1.2.1-quieten.patch new file mode 100644 index 000000000000..4d9ad8f4e4c7 --- /dev/null +++ b/app-backup/flexbackup/files/flexbackup-1.2.1-quieten.patch @@ -0,0 +1,13 @@ +Index: flexbackup +=================================================================== +--- flexbackup (revision 814) ++++ flexbackup (revision 891) +@@ -2419,7 +2419,7 @@ + if (! -r "$configfile") { + die("config file $configfile: $OS_ERROR"); + } +- system("perl -c \"$configfile\""); ++ system("perl -c \"$configfile\" 2>&1"); + if ($CHILD_ERROR) { + die("syntax error in config file $configfile"); + } diff --git a/app-backup/flexbackup/files/flexbackup-1.2.1-remote-bufftest.patch b/app-backup/flexbackup/files/flexbackup-1.2.1-remote-bufftest.patch new file mode 100644 index 000000000000..3d473b9810ce --- /dev/null +++ b/app-backup/flexbackup/files/flexbackup-1.2.1-remote-bufftest.patch @@ -0,0 +1,59 @@ +Common subdirectories: flexbackup-1.2.1-r4/contrib and flexbackup-1.2.1-r5/contrib +diff -ubB flexbackup-1.2.1-r4/flexbackup flexbackup-1.2.1-r5/flexbackup +--- flexbackup-1.2.1-r4/flexbackup 2007-04-14 17:09:48.000000000 -0400 ++++ flexbackup-1.2.1-r5/flexbackup 2007-04-14 17:23:20.000000000 -0400 +@@ -5276,6 +5276,7 @@ + my $tmp_script = "$cfg::tmpdir/buftest.$host.$PROCESS_ID.sh"; + my $retval = 0; + my $pipecmd; ++ my $explicit_success; + + $buffer_cmd =~ s:^\s*\|\s*::; + $buffer_cmd =~ s:\s*\|\s*$::; +@@ -5290,7 +5291,7 @@ + print SCR "res=\$?\n"; + print SCR "out=\`cat \$tmp_err\`\n"; + print SCR "if [ \$res -eq 0 ]; then\n"; +- print SCR " echo successful\n"; ++ print SCR " echo \"successful\"\n"; + print SCR "else\n"; + print SCR " echo \"unsuccessful: exit code \$res: \$out\" \n"; + print SCR "fi\n"; +@@ -5302,13 +5303,19 @@ + $pipecmd = "sh $tmp_script "; + } else { + print $::msg "| Checking '$cfg::buffer' on host $host... "; +- $pipecmd = "cat $tmp_script | ($::remoteshell $host 'cat > $tmp_script; sh $tmp_script; rm -f $tmp_script')"; ++ $pipecmd = "$::remoteshell $host '$::path{mkdir} -p $cfg::tmpdir'; cat $tmp_script | ($::remoteshell $host 'cat > $tmp_script; sh $tmp_script; rm -rf $cfg::tmpdir')"; + } + + if (!defined($::debug)) { + + open(PIPE,"$pipecmd |") || die; ++ ++ $explicit_success = 0; + while (<PIPE>) { ++ if (/^successful$/) { ++ $explicit_success = 1; ++ last; ++ } + if (/^unsuccessful: exit code (\d+): (.*)/) { + $retval = $1; + my $out = $2; +@@ -5337,11 +5344,15 @@ + print $::msg "\n(debug) $pipecmd\n"; + } + +- if ($retval == 0) { ++ if ($explicit_success) { + print $::msg "Ok\n"; + } else { ++ if ($retval == 0) { ++ push(@::errors, "Unanticipated problems encountered testing '$cfg::buffer' on host '$host'."); ++ } else { + print $::msg "Failed!\n"; + } ++ } + unlink("$tmp_script"); + + return($retval); diff --git a/app-backup/flexbackup/files/flexbackup-1.2.1-secure-tempfile.patch b/app-backup/flexbackup/files/flexbackup-1.2.1-secure-tempfile.patch new file mode 100644 index 000000000000..9242f01efcfb --- /dev/null +++ b/app-backup/flexbackup/files/flexbackup-1.2.1-secure-tempfile.patch @@ -0,0 +1,72 @@ +--- a/flexbackup 2003-10-10 07:12:09.000000000 -0700 ++++ b/flexbackup 2006-05-14 13:14:54.000000000 -0700 +@@ -269,6 +269,7 @@ + untie(%::index); + } + ++system ('rm', '-rf', $cfg::tmpdir); + exit(0); + + ###################################################################### +@@ -811,6 +812,11 @@ + ($remove, @cmds) = &backup_filelist($label, $localdir, $title, $level, $remote); + } + ++ if(defined($remote)) { ++ # create our temporary directory as first remote command ++ unshift(@cmds, &maybe_remote_cmd("$::path{mkdir} -p $cfg::tmpdir", $remote)); ++ } ++ + # Nuke any tmp files used in the above routines + if ($remove ne '') { + push(@cmds, &maybe_remote_cmd("$::path{rm} -f $remove", $remote)); +@@ -827,6 +833,11 @@ + push(@cmds, &maybe_remote_cmd("$::path{rm} -f $pkglist", $remote)); + } + } ++ ++ if(defined($remote)) { ++ # remove temporary directory as our last remote command ++ push(@cmds, &maybe_remote_cmd("$::path{rm} -rf $cfg::tmpdir", $remote)); ++ } + + # Strip multiple spaces + foreach my $cmd (@cmds) { +@@ -2750,8 +2761,9 @@ + $::path{'find'} = &checkinpath('find'); + $::path{'dd'} = &checkinpath('dd'); + $::path{'printf'} = &checkinpath('printf'); ++ $::path{'mkdir'} = &checkinpath('mkdir'); + +- push(@::remoteprogs,($::path{'touch'},$::path{'rm'},$::path{'find'},$::path{'printf'})); ++ push(@::remoteprogs,($::path{'touch'},$::path{'rm'},$::path{'find'},$::path{'printf'},$::path{'mkdir'})); + + # Check device (or dir) + $::ftape = 0; +@@ -3442,6 +3454,15 @@ + push(@::errors,"\$tmpdir $cfg::tmpdir is not writable"); + } + ++ $cfg::hostname = `hostname`; ++ chomp($cfg::hostname); ++ ++ # Use a subdirectory of the user-specified directory as our tmpdir ++ # Also note that we make it closer to globally unique as we sometimes ++ # use this variable for remote systems, so PID isn't enough ++ $cfg::tmpdir = $cfg::tmpdir .'/flexbackup.'.$$.'.'.$cfg::hostname; ++ mkdir ($cfg::tmpdir) || die "Can't create temporary directory, $!"; ++ + # Levels + if (defined($::opt{'level'}) and + (defined($::opt{'incremental'}) or +@@ -5236,8 +5257,8 @@ + # Create a script which tests the buffer program + open(SCR,"> $tmp_script") || die; + print SCR "#!/bin/sh\n"; +- print SCR "tmp_data=/tmp/bufftest\$\$.txt\n"; +- print SCR "tmp_err=/tmp/bufftest\$\$.err\n"; ++ print SCR "tmp_data=\`tempfile\`\n"; ++ print SCR "tmp_err=\`tempfile\`\n"; + print SCR "echo testme > \$tmp_data\n"; + print SCR "$buffer_cmd > /dev/null 2> \$tmp_err < \$tmp_data\n"; + print SCR "res=\$?\n"; diff --git a/app-backup/flexbackup/files/flexbackup-1.2.1-spaces-in-filenames.patch b/app-backup/flexbackup/files/flexbackup-1.2.1-spaces-in-filenames.patch new file mode 100644 index 000000000000..1e9ea220ebf5 --- /dev/null +++ b/app-backup/flexbackup/files/flexbackup-1.2.1-spaces-in-filenames.patch @@ -0,0 +1,296 @@ +Index: flexbackup +=================================================================== +--- flexbackup (.../tags/flexbackup-1.2.1-r5) (revision 784) ++++ flexbackup (.../trunk) (revision 784) +@@ -1301,8 +1301,8 @@ + $cmd .= "$::unz"; + } + $cmd .= "("; +- $cmd .= "mkdir -p $::device ; "; +- $cmd .= "cd $::device ; "; ++ $cmd .= "mkdir -p \"$::device\" ; "; ++ $cmd .= "cd \"$::device\" ; "; + $cmd .= "$::path{cpio} -i "; + $cmd .= "-m "; + $cmd .= "-d "; +@@ -1351,9 +1351,8 @@ + + # Have to take leading './' off to make rsync's include/exclude work right + $cmd .= " | $::path{sed} -e \"s/\\.\\///g\" | "; +- + $cmd .= "$::path{rsync} "; +- $cmd .= "--include-from=- --exclude=* "; ++ $cmd .= "--files-from=- "; + $cmd .= "--archive "; + $cmd .= "$::rsync_verb_flag "; + $cmd .= "--delete --delete-excluded "; +@@ -1368,7 +1367,7 @@ + $cmd .= "$remote:"; + } + } +- $cmd .= "$dir/ $::device"; ++ $cmd .= "\"$dir/\" \"$::device\""; + + push(@cmds, $cmd); + +@@ -1658,7 +1657,9 @@ + my $tmpfile = "$cfg::tmpdir/ar.$PROCESS_ID"; + my $remove = ''; + +- &log("| NOTE: ar archives will not descend directories"); ++ &log("| NOTE: ar archives will not recurse into subdirectories,"); ++ &log("| which makes them inappropriate for most backups."); ++ &log("| Be sure this is what you want."); + + if (defined($remote) and ($level != 0)) { + my $time = &get_last_date($label, $level, 'numeric'); +@@ -1682,11 +1683,13 @@ + $cmd = "cd \"$dir\" && "; + $cmd .= &file_list_cmd( $dir, $stamp, 'newline', $level, $remote, '-maxdepth 1 ! -type d'); + $cmd .= "> $filelist; "; ++ # Escape any spaces in filenames. ++ $cmd .= "$::path{sed} -i -e 's/ /\\\\ /g' $filelist; "; + + $cmd .= "$::path{ar} rc"; + $cmd .= "$::ar_verb_flag "; + $cmd .= "$tmpfile "; +- $cmd .= "`$::path{cat} $filelist`"; ++ $cmd .= "\@$filelist "; + $cmd .= "; $::path{cat} $tmpfile $::z"; + + # Buffer both sides if remote +@@ -1800,12 +1803,9 @@ + + $cmd = "cd \"$dir\" && "; + $cmd .= &file_list_cmd( $dir, $stamp, 'newline', $level, $remote); +- $cmd .= "> $filelist; "; +- +- $cmd .= "$::path{lha} a"; ++ $cmd .= " | $::path{lha} a"; + $cmd .= "$::lha_verb_flag "; + $cmd .= "$tmpfile "; +- $cmd .= "`$::path{cat} $filelist`"; + $cmd .= "; $::path{cat} $tmpfile $::z"; + + # Buffer both sides if remote +@@ -2766,6 +2766,7 @@ + $::path{'dd'} = &checkinpath('dd'); + $::path{'printf'} = &checkinpath('printf'); + $::path{'mkdir'} = &checkinpath('mkdir'); ++ $::path{'sed'} = &checkinpath('sed'); + + push(@::remoteprogs,($::path{'touch'},$::path{'rm'},$::path{'find'},$::path{'printf'},$::path{'mkdir'})); + +@@ -4894,9 +4895,9 @@ + $rex .= '\)"'; + } + # Show what the darn thing is constructing for prune expressions. +- &log("| \"find\" regex for pruning is:"); +- &log("| $rex"); +- &line(); ++ (my $temp = $rex) =~ s/\\([()|])/$1/g; ++ &log("| \"find\" regex for pruning (shell escaping omitted for clarity) is:"); ++ &log("| $temp"); + $cmd .= '-regex ' . $rex . ' -prune -o '; + } else { + # Show what the darn thing is constructing for prune expressions. +@@ -4906,6 +4907,7 @@ + # don't have permissions on and are running as non-root) + $cmd .= "-depth "; + } ++ &line(); + + $cmd .= "$::mountpoint_flag "; + $cmd .= "! -type s "; +@@ -5301,12 +5303,14 @@ + print $::msg "| Checking '$cfg::buffer' on this machine... "; + $pipecmd = "sh $tmp_script "; + } else { ++ $pipecmd = ++ "$::remoteshell $host '$::path{mkdir} -p $cfg::tmpdir'; " . ++ "cat $tmp_script | ($::remoteshell $host 'cat > $tmp_script; " . ++ "sh $tmp_script; rm -rf $cfg::tmpdir')"; + print $::msg "| Checking '$cfg::buffer' on host $host... "; +- $pipecmd = "$::remoteshell $host '$::path{mkdir} -p $cfg::tmpdir'; cat $tmp_script | ($::remoteshell $host 'cat > $tmp_script; sh $tmp_script; rm -rf $cfg::tmpdir')"; + } + + if (!defined($::debug)) { +- + open(PIPE,"$pipecmd |") || die; + + $explicit_success = 0; +Index: flexbackup.conf +=================================================================== +--- flexbackup.conf (.../tags/flexbackup-1.2.1-r5) (revision 784) ++++ flexbackup.conf (.../trunk) (revision 784) +@@ -12,19 +12,27 @@ + + # Configure backup "sets". + # Not needed if you use "-dir <dir>" to backup one tree at a time. +-# Each set is a simple space-separated list of filesystems +-# Remote filesystems should denoted as 'host:dir' +-# You can use anything (other than 'all') as set names +-# +-# Example: +-# $set{'set1'} = "/home /usr"; +-# $set{'set2'} = "/dir3 machine2:/dir4 machine3:/dir5"; ++# Each set is a simple space-separated list of filesystems. Remote filesystems ++# should denoted as 'host:dir'. If the filesystem name (local or remote) ++# contains spaces, then it should be enclosed in its entirety in double quotes. ++# Multiple quoted filesystems included in a set should be space separated just ++# like unquoted filesystem. The Perl '.' string concatenation operator can be ++# used to split excessively long lines. ++# ++# You can use anything (other than 'all') as set names. ++# ++# Examples: ++# $set{'set1'} = '/home /usr'; ++# $set{'set2'} = '/dir3 machine2:/dir4 machine3:/dir5'; ++# $set{'set3'} = ++# '"/mnt/winmachine1/Documents and Settings" ' . ++# '"/mnt/winmachine1/Program Files"'; + # + # "-set all" will back up all defined sets. If you are doing a full backup + # using tapes, each "set" will go onto a different tape and you will be + # prompted for tape change in between. + # +-$set{'backup'} = "/home"; ++$set{'backup'} = '/home'; + + # Subtree pruning + # A space-separated list of directories to prune from each backup. +@@ -42,7 +50,7 @@ + # start with "./". To be helpful, FlexBackup packages each space-separated + # prune directory as follows. If you have a prune list like this + # +-# $prune{'/somedir'} = "one two three"; ++# $prune{'/somedir'} = 'one two three'; + # + # then, the constructed -regex argument to "find" looks like this + # +@@ -54,31 +62,38 @@ + # terms that match the current base directory in the set you're backing + # up. For example, if your backup set definition looks like this + # +-# $set{'daily'} = "/home /root /var /usr"; ++# $set{'daily'} = '/home /root /var /usr'; + # + # and you want to do some exclusions in "/home" and "/var" (but not the other + # directories), you must set up a prune list for those two directories + # separately. For example, to exclude bert's and ernie's home directories plus + # /var/tmp, you would need the following: + # +-# $prune{'/home'} = "bert ernie"; +-# $prune{'/var'} = "tmp"; ++# $prune{'/home'} = 'bert ernie'; ++# $prune{'/var'} = 'tmp'; + # + # In particular, combining these *does not* work. For example, this + # +-# $prune{'/'} = "home/bert home/ernie var/tmp"; ++# $prune{'/'} = 'home/bert home/ernie var/tmp'; + # + # doesn't work, unless, of course, your backup set is backing up "/", + # which our example is not. + # ++# Like the $set configuration item, special handling is required for ++# directories with spaces in them. Double quotes should surround pruning ++# targets but not the key. Example: ++# ++# $prune{'/mnt/winmachine1/Documents and Settings'} = ++# '"user1/Local Settings/Temp" user2'; ++# + # Many other complex and abstruse variations are possible. Here's one + # interesting corner case. If you want to preserve a directory but none of its + # contents, you can do it. Picking on ernie from our previous example, preserve + # only his home directory: + # +-# $prune{'/home'} = "ernie/.*"; ++# $prune{'/home'} = 'ernie/.*'; + # +-$prune{'/'} = "tmp proc"; ++$prune{'/'} = 'tmp proc'; + + # Compression + $compress = 'gzip'; # one of false/gzip/bzip2/lzop/zip/compress/hardware/lzma +Index: flexbackup.conf.5 +=================================================================== +--- flexbackup.conf.5 (.../tags/flexbackup-1.2.1-r5) (revision 784) ++++ flexbackup.conf.5 (.../trunk) (revision 784) +@@ -24,25 +24,51 @@ + .TP + \fB$set{\fI'tag'\fR}\fR = \fI'/dir'\fR; + Configure backup \(dqsets\(dq. Not needed if \(dq-dir <dir>\(dq is used to +-backup one tree at a time. Each set is a simple space-separated list of +-filesystems/directories. Remote filesystems should be denoted as +-\(dqhost:directory\(dq. You can use anything (other than \fI'all'\fR) as set +-names. Using \(dq-set all\(dq will back up all defined sets. If you are doing +-a full backup using tapes, each \(dqset\(dq will go onto a different tape and +-you will be prompted for tape change in between. Examples: ++backup one tree at a time. ++Each set is a simple space-separated list of filesystems/directories. ++Remote filesystems should be denoted as \(dqhost:directory\(dq. ++You can use anything (other than \fI'all'\fR) as set names. ++Using \(dq-set all\(dq will back up all defined sets. ++If you are doing a full backup using tapes, each \(dqset\(dq will go onto a ++different tape and you will be prompted for tape change in between. ++Examples: + .RS + .PP + \fB$set{\fI'set1'\fI}\fR = \fI'/home /usr'\fR; + .br + \fB$set{\fI'set2'\fI}\fR = \fI'/dir3 machine2:/dir4 machine3:/dir5'\fR; ++.br ++.PP ++Directories (local or remote) with spaces in their names should be enclosed in ++their entirety in double quotes. ++Multiple quoted directories included in a set should be space separated just ++like unquoted directories. ++The Perl '.' string concatenation operator can be used to split excessively ++long sets. ++Example: ++.PP ++\fB$set{\fI'set3'\fI}\fR = \fI ++ '\(dq/mnt/winmachine1/Documents and Settings\(dq ' . ++ '\(dq/mnt/winmachine1/Program Files\(dq';\fR + .RE + .TP + \fB$prune{\fI'/'\fR}\fR = \fI'tmp proc'\fR; + Configure subtree pruning. A space-separated list of directories to prune from + each backup. Key is a filesystem/directory or \(dqhost:directory\(dq spec as +-outlined above. Regular expressions allowed (not shell-type wildcards!). There +-is additional explanation (and a lot of examples) in the provided configuration +-file. ++outlined above. Regular expressions allowed (not shell-type wildcards!). ++.RS ++.PP ++Like the \fB$set\fR configuration item, special handling is required for ++directories with spaces in them. Double quotes should surround pruning targets ++but not the key. Example: ++.PP ++\fB$prune{\fI'/mnt/winmachine1/Documents and Settings'\fI}\fR = ++ \fI'\(dquser1/Local Settings/Temp\(dq user2'\fR; ++.br ++.PP ++There are lots of examples and additional explanation in the provided sample ++configuration file. ++.RE + .TP + \fB$compress\fR = \fI'false|gzip|bzip2|lzop|zip|compress|hardware'\fR; + .TQ +@@ -207,7 +233,7 @@ + .RS + .TP + If GNU \fBtar\fR is called \fB\(dqgtar\(dq\fR on your system: +-\fB$path{'tar'} = 'gtar'; ++\fB$path{'tar'} = 'gtar';\fR + .TP + Or it can be used to \fB\(dqsudo\(dq\fR certain commands: + \fB$path{\fI'find'\fR}\fR = \fI'sudo find'\fR; +@@ -304,3 +330,6 @@ + Written by Edwin Huffstutler (edwinh@computer.org) + .SH "SEE ALSO" + \fBflexbackup\fR(1) ++.\" Local Variables: ++.\" mode: nroff ++.\" End: diff --git a/app-backup/flexbackup/files/flexbackup-1.2.1-tar-1.29.patch b/app-backup/flexbackup/files/flexbackup-1.2.1-tar-1.29.patch new file mode 100644 index 000000000000..211cf2067623 --- /dev/null +++ b/app-backup/flexbackup/files/flexbackup-1.2.1-tar-1.29.patch @@ -0,0 +1,15 @@ +diff -ubBr old/flexbackup new/flexbackup +--- old/flexbackup 2016-12-01 10:52:59.088767278 -0500 ++++ new/flexbackup 2016-12-01 10:54:18.006882216 -0500 +@@ -1408,10 +1408,10 @@ + + $cmd .= "$::path{tar} --create "; + $cmd .= "--null "; ++ $cmd .= "--no-recursion "; + $cmd .= "--files-from=- "; + $cmd .= "--ignore-failed-read "; + $cmd .= "--same-permissions "; +- $cmd .= "--no-recursion "; + $cmd .= "--totals "; + if ($cfg::label ne 'false') { + if (length($title) > $::tar_max_label) { diff --git a/app-backup/flexbackup/flexbackup-1.2.1-r13.ebuild b/app-backup/flexbackup/flexbackup-1.2.1-r13.ebuild new file mode 100644 index 000000000000..528b303d318b --- /dev/null +++ b/app-backup/flexbackup/flexbackup-1.2.1-r13.ebuild @@ -0,0 +1,90 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=6 + +inherit versionator + +DESCRIPTION="Flexible backup script using perl" +HOMEPAGE="http://flexbackup.sourceforge.net/" +SRC_URI="mirror://sourceforge/${PN}/${P}.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="amd64 hppa ppc x86" +IUSE="" + +RDEPEND="app-arch/mt-st" +DEPEND="${RDEPEND}" + +DOCS="CHANGES CREDITS README TODO" +HTML_DOCS="faq.html" + +src_prepare() { + # Patch from upstream adds optional lzma compression mode. + eapply -p0 "${FILESDIR}"/${P}-lzma.patch + + # Fix bug #116510: cannot back up remote machines after patch CAN-2005-2965 + eapply "${FILESDIR}"/${P}-secure-tempfile.patch + + # Fix bug #96334: incorrectly determines bash 3.x to be bash 1.x + eapply -p0 "${FILESDIR}"/${P}-bash.patch + + # Fix bug #171205: specifies wrong command line option for mbuffer / other small enhancements + eapply "${FILESDIR}"/${P}-mbuffer-switch.patch + + # Fix bug #173672: remote host buffer test is broken + eapply "${FILESDIR}"/${P}-remote-bufftest.patch + + # Fix bug #178126: subtle subtree pruning issue / other small issues + eapply "${FILESDIR}"/${P}-prune.patch + + # Fix bug #184560: fails to back up targets with spaces in their names in some modes + eapply -p0 "${FILESDIR}"/${P}-spaces-in-filenames.patch + + # Fix bug #190357: fails on very large files with afio back end + eapply -p0 "${FILESDIR}"/${P}-afio-large-files.patch + + # Fix bug #235416: prevent normal status message during conf file read from going to stderr + eapply -p0 "${FILESDIR}"/${P}-quieten.patch + + # Fix bug #331673: perl 5.12 deprecation warnings. + eapply -p0 "${FILESDIR}"/${P}-perl-5.12-deprecation-warning.patch + + # Fix bug #495232: perl 5.16 deprecation warnings. + eapply -p0 "${FILESDIR}"/${P}-perl-5.16-deprecation-warning.patch + + # Fix bug #601368: app-backup/flexbackup breaks with >=app-arch/tar-1.29 when making tar-based backups + eapply "${FILESDIR}"/${P}-tar-1.29.patch + + eapply_user + + sed -i \ + -e '/^\$type = /s:afio:tar:' \ + -e "/^\$buffer = /s:'buffer':'false':" \ + flexbackup.conf \ + || die "Failed to set modified configuration defaults." + + MY_PV=$(replace_all_version_separators '_') + sed -i \ + -e "/^[[:blank:]]*my \$ver = /s:${MY_PV}:&-${PR}:" \ + flexbackup \ + || die "Failed to apply ebuild revision to internal version string." +} + +src_install() { + dodir /etc /usr/bin /usr/share/man/man{1,5} + emake install \ + PREFIX="${D}"/usr \ + CONFFILE="${D}"/etc/flexbackup.conf \ + || die "emake install failed" + + einstalldocs +} + +pkg_postinst() { + elog "Please edit your /etc/flexbackup.conf file to suit your" + elog "needs. If you are using devfs, the tape device should" + elog "be set to /dev/tapes/tape0/mtn. If you need to use any" + elog "archiver other than tar, please emerge it separately." +} diff --git a/app-backup/flexbackup/metadata.xml b/app-backup/flexbackup/metadata.xml new file mode 100644 index 000000000000..ee448e7097ec --- /dev/null +++ b/app-backup/flexbackup/metadata.xml @@ -0,0 +1,10 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="person"> + <email>graaff@gentoo.org</email> + </maintainer> + <upstream> + <remote-id type="sourceforge">flexbackup</remote-id> + </upstream> +</pkgmetadata> |