diff options
author | V3n3RiX <venerix@redcorelinux.org> | 2017-10-09 18:53:29 +0100 |
---|---|---|
committer | V3n3RiX <venerix@redcorelinux.org> | 2017-10-09 18:53:29 +0100 |
commit | 4f2d7949f03e1c198bc888f2d05f421d35c57e21 (patch) | |
tree | ba5f07bf3f9d22d82e54a462313f5d244036c768 /app-backup/flexbackup |
reinit the tree, so we can have metadata
Diffstat (limited to 'app-backup/flexbackup')
16 files changed, 1108 insertions, 0 deletions
diff --git a/app-backup/flexbackup/Manifest b/app-backup/flexbackup/Manifest new file mode 100644 index 000000000000..28e42125b8ad --- /dev/null +++ b/app-backup/flexbackup/Manifest @@ -0,0 +1,18 @@ +AUX flexbackup-1.2.1-afio-large-files.patch 401 SHA256 d9f87c376c305a440ed0b0444c1b196648b89ce6ade9231a8f4cc0914f3a2762 SHA512 ad94ebbabe413b51d4f984f9a2d80b69f2998037512c0ac6077d92d0bb7f594a444503f196e668d0e91d35ad543f2cba73129ad31007a43de228fb50c0b4e870 WHIRLPOOL 45e5f87cf02e637b719c654b5d0a81b8fb490141bd2511a8e11866b3e5805fbd5a90839d05a9a23cecbff43c2b7b1b80781a6662ced52b8c86535020ac3e057a +AUX flexbackup-1.2.1-bash.patch 445 SHA256 a072869e37b50f5da8652686a56aed8a45a225bb4eb00818377e006614e4a88e SHA512 ec74be2043c5791288abf9e5303cc24caa55ac0d14f51a7cfdd6b495f97bef1dece39e8dd0492a14df18a9b495f74463247586e2edefe0f897429631c9809745 WHIRLPOOL 27d3c05e362d1ee429c718de69783201203ccab46408dc0a9dbad094cd123fdbc92da1190717e33288cef1a7337555efb0f5fce9fca9386bc0c243cd054eb506 +AUX flexbackup-1.2.1-lzma.patch 4336 SHA256 5a716af1d3a90c64808b8f40ea9ff1b8d2c37e726f4a90c88e87d75da0049baa SHA512 de23710262aaaa79e7dda63221965267a4751cb5c1681b8d4db6ab7a065aa8dab3e6c3097d339a793650a28627eeffefeef408612c08a9bbe3f14d383179338e WHIRLPOOL 8782d600774e0d28fb28259def1e66afc5e57583447db7050e67717fffe2e208d1e66f0ff3e620f30b6c5d8966b76d83877402ed9b9da36200fd1b6a9102fc2f +AUX flexbackup-1.2.1-mbuffer-switch.patch 5550 SHA256 a11379db1eca89398e3917ee9a6fa57e416ffdb0cabb773444ad53629b6e2917 SHA512 1ad0e5ac04f0c44c970954aefd62f465d1c9c9604c6ab90cd56d61d44aa8b4c23e8befe992380e10d74fdf043975969431185e1ae66297bb630a105fd5329b4c WHIRLPOOL 762b3949b35af8e9411f2058872ee92e33693f2b3c6e0a056e2fb098aa968c176bb7b0b9ca4aabc53ed2fcc5ed259dac49b9e81fb1dc94de513c4f192d1abebd +AUX flexbackup-1.2.1-perl-5.12-deprecation-warning.patch 814 SHA256 7d66e5265de7e26dfd37cc832024be8ecc951f17d4ede838e9a903ab588edde7 SHA512 ea77998e18fb7ae6612983ab2b6ebc1ab6de6056f5a60aada283ba593a60973953062dcaac9f9d2aa7068384ac4a8a0d72c439cf7cdd3c8a2b304d7ae779f302 WHIRLPOOL b59aef62836e299d2b5a834a80c12aa9b03427206c1211ef3cbd61ca461061ee2063459e567e4cd1cf77b8e7dd65347fe9f685ab1f3c29970756758010c4a427 +AUX flexbackup-1.2.1-perl-5.16-deprecation-warning.patch 374 SHA256 3873bd00a81a6a490080705cc6adfde19b3ed88180b230c45873d817ea21902b SHA512 cf994cc48c735b2fe15f858b2f7f8e3d83012ad780e42b1ec05c2af2dacf04da844810e5c87d608f9bab40d2366507f2af017a7c95128f17141ce5afd5b228a4 WHIRLPOOL 1c9d5156ba144c8edea2d090ae41e8e26e31c6cfd278b274f70c294324cccf2add49563f283cf42dfa388eb6c41bfc729aba0c46d04e392c5daeb64afe81708a +AUX flexbackup-1.2.1-prune.patch 5544 SHA256 146e636ca08c21a3ec7f9e18c59f89e48a74db581ad3d5ca3a606093e6407fc7 SHA512 a2c1d7a82b3328b52a36dd04fa3f3e2a8b5918de9f3f089ef7342192bae023b3fe844ae847bf09d21348a794c06ee49185d6e49e116da2794121f005ea74b6c0 WHIRLPOOL 0790022df75d8baeb53d26d0fe5363a0061760d84d125a17d1c23e80d30e8ace56ecd9df3d9d01d1e889041d8b2385ea3d872352f288538c78f7dbdb80fe67f1 +AUX flexbackup-1.2.1-quieten.patch 418 SHA256 dc658315bfe5f204137dd03005e1d5a44c8efcc1c09cf2c6bb840516dfe7984b SHA512 bf263fb3c3301eb49942b1c7be3348b8b3b8584776baadc35bc34c709887a7dc48e534bc65dd543f835e6ebfe4747e9f074ded01199f4458ae974eb9565feaa2 WHIRLPOOL 78785a877b4216a7e1fd534ceef0737eac579b83b784a980dcc85d92ac7a9bda6b8f8b077c44ea303db379aafd9900c8d8de597a0d31e892ee18cd967d0100a0 +AUX flexbackup-1.2.1-remote-bufftest.patch 1940 SHA256 aa209656fea52a4f541ff9eca4099e2b7dfc42f7efc52ec46016a95af378d7cc SHA512 76a3d6cb556596204791d98534ed13fc3738bed8642b4defef839d221510f6fad2d365abc524f368f43f88c710b6b6547cffd4be0e9a4ce53105bdc9dc1ed10e WHIRLPOOL 7b0ca60b284beab669425c28788fa6ed69a8fe80d74cfb9a5ac772a7d59913721547b7d635e48da4410e5c8c9058cbfd0689af27ccec0413f9f40d6264f15e0c +AUX flexbackup-1.2.1-secure-tempfile.patch 2563 SHA256 b8842e0f65bef6150f968d7d1113b83e8c5c54ab5d18ab86b582fa1ccea4bdf1 SHA512 14bc8bccdb9c094bea92f97a7760079233364a87530750d0f904e3831c6bf4dca69cfdfdc578af316b65d8d7ff3d1c00c53bb8aa17acd2ecd009b919d87cd1f6 WHIRLPOOL afbf11b1c52ef65a45e2701c72126c6ccac0f74ee6ba3f2108f7f523cdbcb59aa45784ea038c50e52b753628b9ce963e98a8fa5ab9732d3830473f012a16b22e +AUX flexbackup-1.2.1-spaces-in-filenames.patch 11037 SHA256 4dde33d92ff0e97a614807f50a7a28a08c485a0cee5f19ab512550e0d431c5e2 SHA512 58fdb4fbc59eaeefaf5a552abab0adf8a4d4e258cc737a1b310c00bef6ebf61c9fa55f3b3b7c68553ed224e12c082d03a9c16fdacfa2a44a70349bd882cfe987 WHIRLPOOL 95dedead01ce89c367479991ca1cb3e96307ff08e717674e69d0ff44e0bf262286347ba9b0739e81f2b304790359f8f546b55b5eb3342dfee38064483b01b07e +AUX flexbackup-1.2.1-tar-1.29.patch 514 SHA256 f52a1593e97c8355a3e876a217846c42c17c89df2b5baf39de49732032d1ebb4 SHA512 b8a28c93db2b8f04bcf7c56406fd0457b837e9afea30a5a1cf37bdd64554bbb4ee665b5c15af24701eeab10a1b1c2d31371b7c0ce32cbfb29223ac34956cc962 WHIRLPOOL 1c5e109905617eadb564bcc0ec213b78f0d512b9a0b9083c3ea2139a021011d2d09ad387aedb61fde0b8b23b4d7b93766ee9dc77a0b25dbd9c4fc2b83990012b +DIST flexbackup-1.2.1.tar.gz 80158 SHA256 58282b21985be75f1219c5ff4906d217055ed8627ea3e2ffdfe7a2393bc9d2c3 SHA512 17630bc46657becdf5d5bde4852fd6cebe189fe54d381bda6471aa2e1db1ff082ba24461e2c22ba5805c2d93ac7f9805ffbdc4904da017f1b163cc21b5a3974b WHIRLPOOL 0beb123986579b5f5c9add2e1ccc02b11e687dfce7a093d550239aec50cf5a35cf15da066a6b0f23819a001dce222d5167874527411bb31bca405b55c8f2d171 +EBUILD flexbackup-1.2.1-r12.ebuild 2606 SHA256 f3e543097e8fc465635b57a83a41077760532bd7bf5f8f85c4853b10c0ef2a40 SHA512 2ca29183f1305b765bf78d2c626f5d645769fdb8a8bf532d85bb24a78c5e8873bbb539b7ebd2deeb7dfc8bc18e57389c628b7f7c5abfab06a7a49951d8eb68e9 WHIRLPOOL 90c4fddbb5ba2d139f79f3925974b36480e806a443f8ff29fe759b9687378b5938f061eda02099850eff701c16715049b0c52ad1774540827f5ec47dcaf2301b +EBUILD flexbackup-1.2.1-r13.ebuild 2795 SHA256 db5c55ad89d286dfc846e527e61f5cd016939b30f2946151ba49627e3e3d1df5 SHA512 f60b9a5bd354633c94158b593fbf3e40ee32b579764d053ee13f138bf9f3ea61bf47481e4945a1e2d770b5930cdbd8a91a789a209a94043b64c85a759349fed2 WHIRLPOOL 4ef3cb4dfc5e6c932494fd2dc4d675c7c46c3a05d861a6680e767974f24fec3af1cadf0a43ba48211ccc607bbe6f362853dfd97b035413245537021130a89822 +MISC ChangeLog 3284 SHA256 fdbf252c8f5ed7fd57c076f11b4894818fa9609596de7a5400226bf39993a416 SHA512 50d45872acfd1fc90dd8c932011c9df8d83ec0026a2f096348cbf8a74123ca798a8f5ba83159d410ab1db6e52c8d1cc1c5b2f64f64b425228154acc664231601 WHIRLPOOL 9c9ab3a38b7f177e9359502047e02dd2f0dbe0299b3ae6c7c5d75e6754f05b26c77b1d0941b077c946adae25143c651a0b55aacabb7138f49ff6c4d7860f476e +MISC ChangeLog-2015 10208 SHA256 1305eacdc53c71c785e4a4fd3dc0b345b75a829b32c6b1bdc9ed6c6d24bbd44e SHA512 f8ae697645bdf546be4dbbc9e846b268e397aaa09ffe13a2b6eca0fbf46c9e9bf1e7d6cadc6f1ce41b099f7ba2c1d0f646367fb6fa1d71dfc1b0321aedfa54a4 WHIRLPOOL 5a0f2caf5d765acd764dbddd4b387a1c6cf4526436728128f29a312c0575f765bf39537de630c8fde59ceddfdb93990084b7147146c79056b148270168ffd04f +MISC metadata.xml 297 SHA256 3ce3e95d0bea1cc0143e47f0e392ace0d523b426f7ba1b79a992a6ad13a3f82e SHA512 a2fd29aba380cb3b9322131f97beed0d432569ab612118bf1a9a428a93602c859014face05fc8582c8dfdf6858296a36ae6754fdc45a78715058d779df3f7e0a WHIRLPOOL 9cdd49618cd91688347db268b6da4a62f784efd9a89ba5d7dc8604e1ece6d12c22769f805632cbfde830f8935f4face3c677aeec9d4762c18e38049c15c1d1fa 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-r12.ebuild b/app-backup/flexbackup/flexbackup-1.2.1-r12.ebuild new file mode 100644 index 000000000000..4a3b7e0147d3 --- /dev/null +++ b/app-backup/flexbackup/flexbackup-1.2.1-r12.ebuild @@ -0,0 +1,84 @@ +# Copyright 1999-2014 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +inherit eutils 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}" + +src_unpack() { + unpack ${A} + cd "${S}" + + # Patch from upstream adds optional lzma compression mode. + epatch "${FILESDIR}"/${P}-lzma.patch + + # Fix bug #116510: cannot back up remote machines after patch CAN-2005-2965 + epatch "${FILESDIR}"/${P}-secure-tempfile.patch + + # Fix bug #96334: incorrectly determines bash 3.x to be bash 1.x + epatch "${FILESDIR}"/${P}-bash.patch + + # Fix bug #171205: specifies wrong command line option for mbuffer / other small enhancements + epatch "${FILESDIR}"/${P}-mbuffer-switch.patch + + # Fix bug #173672: remote host buffer test is broken + epatch "${FILESDIR}"/${P}-remote-bufftest.patch + + # Fix bug #178126: subtle subtree pruning issue / other small issues + epatch "${FILESDIR}"/${P}-prune.patch + + # Fix bug #184560: fails to back up targets with spaces in their names in some modes + epatch "${FILESDIR}"/${P}-spaces-in-filenames.patch + + # Fix bug #190357: fails on very large files with afio back end + epatch "${FILESDIR}"/${P}-afio-large-files.patch + + # Fix bug #235416: prevent normal status message during conf file read from going to stderr + epatch "${FILESDIR}"/${P}-quieten.patch + + # Fix bug #331673: perl 5.12 deprecation warnings. + epatch "${FILESDIR}"/${P}-perl-5.12-deprecation-warning.patch + + # Fix bug #495232: perl 5.16 deprecation warnings. + epatch "${FILESDIR}"/${P}-perl-5.16-deprecation-warning.patch + + 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" + + dodoc CHANGES CREDITS README TODO + dohtml faq.html +} + +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/flexbackup-1.2.1-r13.ebuild b/app-backup/flexbackup/flexbackup-1.2.1-r13.ebuild new file mode 100644 index 000000000000..8aff19cd8b55 --- /dev/null +++ b/app-backup/flexbackup/flexbackup-1.2.1-r13.ebuild @@ -0,0 +1,90 @@ +# Copyright 1999-2016 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> |