diff options
Diffstat (limited to 'sys-fs/dd-rescue')
-rw-r--r-- | sys-fs/dd-rescue/Manifest | 6 | ||||
-rw-r--r-- | sys-fs/dd-rescue/dd-rescue-1.46.ebuild | 83 | ||||
-rw-r--r-- | sys-fs/dd-rescue/dd-rescue-1.99.8-r1.ebuild (renamed from sys-fs/dd-rescue/dd-rescue-1.99.8.ebuild) | 3 | ||||
-rw-r--r-- | sys-fs/dd-rescue/files/dd-rescue-1.99.8-sysrandom.patch | 27 | ||||
-rw-r--r-- | sys-fs/dd-rescue/files/dd-rescue-1.99.8-testhole.patch | 32 |
5 files changed, 65 insertions, 86 deletions
diff --git a/sys-fs/dd-rescue/Manifest b/sys-fs/dd-rescue/Manifest index 3f1faeb106a7..3c6b1f5b0e60 100644 --- a/sys-fs/dd-rescue/Manifest +++ b/sys-fs/dd-rescue/Manifest @@ -1,7 +1,7 @@ +AUX dd-rescue-1.99.8-sysrandom.patch 1204 BLAKE2B 4ef909c294a9299c93fb0ca793e5815fa6f98a9860de1886d9f8da8584a16c0320d56c6ecb6894cbe7f62be62e290f36b76319ed714ccc085c59f952a03cacc6 SHA512 14020e023ea7cf5b56d78776149933241f7424fb22076686a9541737f2fe887406b94e584c5cf650d754e9ead9bf6f2f96c390a2c1fba49f961955df49445a06 +AUX dd-rescue-1.99.8-testhole.patch 1267 BLAKE2B 137961d607cd93ad758c7cf6b8f8ab4b2e54017f43585e277563a5050e9c32ee52567de08af83a048e7e59b2ed05753fc67286d640d3c7998504bd11e9a1286c SHA512 f6a6649a4bce486a07f2eac382db609a47585361ad24ce03bad49da284c0b5485e35fcaec95445c46b74f6dfa5fe09d28c45a33a1b319a03c8cbb15c03a4ee8d AUX dd-rescue-1.99.8-xattr.patch 9308 BLAKE2B 0874806f5394759edacdc4d937619b4ab568cfa501b14f1b56a48f80f7e9777e8be439fe0f1edbe9eb6232344e850360b504dc81ffd1052067c1f68b2152d78e SHA512 b9a2a0c3c035b89c9ef45f52b48d247bcb56f250e86e39bce905826c83823eb855407aeaeadefbf878c946ac019b4f7ec58a46930f0b3450b191b62bd524690a AUX dd_rescue-1.99-musl-r2.patch 4035 BLAKE2B cffc620f429db2042a405174a280e44c27dc60f9b3da007969b77d66df599b9c4b9fb02cb2799017c7fb6a0a0f1e8b785c88fb741fb478b6a8f256d0e461bf78 SHA512 a0fe42686852cbdd4ce5a4c55c9dc77cff7165109f3c7d4dfaaec527fa116a17f602ad4fab22410991f05aac6aa8f5b57bb711c05e08f146d532aaa807dbfd66 -DIST dd_rescue-1.46.tar.gz 126790 BLAKE2B 027d509349e77fa020757b826184b4a2206c3f5923c797c294ca8caf210cf6af20afa1d518d826413989612295a4365c480d7aa4293686824ee96394cbbe9851 SHA512 efd1bf5d80d4bafa6e6971caa84205dc5df4456a29a9fa3bb56aa984d68675ae3418e8ba3a355906f491f0f2e750c38fd695e37dbd193e554cd41afec3841e28 DIST dd_rescue-1.99.8.tar.bz2 174594 BLAKE2B 51e62989bf6318cb5926f30bc1db746bddd41fb49aab15dc2b1c67e0af079469161d390ba4e1e109d195249b3aace3aa830a3aec14ba534eb47f38c0136f910c SHA512 a230e1df4532671ea631036012dd1e38614e45bed58b00757f0017b0ea60f14ac3bdac07777d175aa4929def593b3c8485e463b1fc25b5067adf4cf3f3ac040d -EBUILD dd-rescue-1.46.ebuild 1935 BLAKE2B 96cb26dbaf1af6e3653593bb3416b27165a078e2211519dd94ac7bdc889cba2c66ac9f04dee253828b56c00a8aaf9de51091aabe706b0bfe6e27de9d44854066 SHA512 57bdaccabd2da99bb329c82f47e52fbd2066f736c742b8de551671fab294297e45a874daa0ddd701234a3e6c216f52ddee55283d70bf1a166d3538f32485e8c7 -EBUILD dd-rescue-1.99.8.ebuild 2378 BLAKE2B b8ab4343968e553642a4140384428799e3abf27709f578cc1752dfaa0f5da7a903992ab9df13863dbf671044c185718d8484ea936a3288d16e988dc1c56168dc SHA512 be7c043fbfc0110bbc412ea93bc00fccb2ab49eaa94e2847665285f422968ae2396692d4bd4dd95c4ecf016a50318b1b7ead9f25d70aa4e405974ce447fa6780 +EBUILD dd-rescue-1.99.8-r1.ebuild 2502 BLAKE2B 8d7f487f02b8c6cbb1ecab1d9226f646a8a6118eb4d90b25128538b1d4a3430d99a1eb2d17f8e70600346e2f3b987e3cf86276c360bc127d90f15dde0c60a099 SHA512 7df6dceb92cdb93f43002cf33f138cdee775ab431e761663cbb6ea4b15c2bec73d73dabb11347d2a3e6cbbb04a2e1feee8f3bff128bdc9c3cc5b6891e00aacd3 MISC metadata.xml 253 BLAKE2B 295e9d6d93aaa12af413972e1590c67087801cc09c9aa6b59d4606c0f4106d1dacf2baa9858559083b4c6d91beeef218d0729e8593a33788958da6d2897e8ce2 SHA512 54a9069aeb4165d2dff3d473c8001bc51613aac9dff3f7f5e9971a9891a737a31511ffa11cbd523febe581ac1d9de2bdf2f40410f0c4239138f2ccca3ef15555 diff --git a/sys-fs/dd-rescue/dd-rescue-1.46.ebuild b/sys-fs/dd-rescue/dd-rescue-1.46.ebuild deleted file mode 100644 index 70f8a57d7af3..000000000000 --- a/sys-fs/dd-rescue/dd-rescue-1.46.ebuild +++ /dev/null @@ -1,83 +0,0 @@ -# Copyright 1999-2015 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 - -EAPI=5 - -inherit toolchain-funcs flag-o-matic multilib autotools - -MY_PN=${PN/-/_} -MY_P=${MY_PN}-${PV} - -DESCRIPTION="Similar to dd but can copy from source with errors" -HOMEPAGE="http://www.garloff.de/kurt/linux/ddrescue/" -SRC_URI="http://www.garloff.de/kurt/linux/ddrescue/${MY_P}.tar.gz" - -LICENSE="GPL-2" -SLOT="0" -KEYWORDS="amd64 ~arm ~mips ppc ~sparc x86 ~amd64-linux ~x86-linux ~ppc-macos" -IUSE="cpu_flags_x86_avx2 lzo cpu_flags_x86_sse4_2 static xattr" - -RDEPEND="lzo? ( dev-libs/lzo ) - xattr? ( sys-apps/attr )" -DEPEND="${RDEPEND}" - -S=${WORKDIR}/${MY_PN} - -src_prepare() { - sed -i \ - -e 's:-ldl:$(LDFLAGS) -ldl:' \ - -e 's:-shared:$(CFLAGS) $(LDFLAGS) -shared:' \ - Makefile - eautoreconf -} - -src_configure() { - use static && append-ldflags -static - # OpenSSL is only used by a random helper tool we don't install. - ac_cv_header_attr_xattr_h=$(usex xattr) \ - ac_cv_header_openssl_evp_h=no \ - ac_cv_lib_lzo2_lzo1x_1_compress=$(usex lzo) \ - econf -} - -_emake() { - local arch - case ${ARCH} in - x86) arch=i386;; - amd64) arch=x86_64;; - arm) arch=arm;; - arm64) arch=aarch64;; - esac - - local os=$(usex kernel_linux Linux IDK) - - # The Makefile is a mess. Override a few vars rather than patch it. - emake \ - MACH="${arch}" \ - OS="${os}" \ - HAVE_SSE42=$(usex cpu_flags_x86_sse4_2 1 0) \ - HAVE_AVX2=$(usex cpu_flags_x86_avx2 1 0) \ - RPM_OPT_FLAGS="${CFLAGS} ${CPPFLAGS}" \ - CFLAGS_OPT='$(CFLAGS)' \ - LDFLAGS="${LDFLAGS} -Wl,-rpath,${EPREFIX}/usr/$(get_libdir)/${PN}" \ - CC="$(tc-getCC)" \ - "$@" -} - -src_compile() { - _emake -} - -src_test() { - _emake check -} - -src_install() { - # easier to install by hand than trying to make sense of the Makefile. - dobin dd_rescue - dodir /usr/$(get_libdir)/${PN} - cp -pPR libddr_*.so "${ED}"/usr/$(get_libdir)/${PN}/ || die - dodoc README.dd_rescue - doman dd_rescue.1 - use lzo && doman ddr_lzo.1 -} diff --git a/sys-fs/dd-rescue/dd-rescue-1.99.8.ebuild b/sys-fs/dd-rescue/dd-rescue-1.99.8-r1.ebuild index 59957af5e23c..d421dc83aa03 100644 --- a/sys-fs/dd-rescue/dd-rescue-1.99.8.ebuild +++ b/sys-fs/dd-rescue/dd-rescue-1.99.8-r1.ebuild @@ -26,6 +26,8 @@ S="${WORKDIR}/${MY_P}" PATCHES=( "${FILESDIR}"/${MY_PN}-1.99-musl-r2.patch "${FILESDIR}"/${PN}-1.99.8-xattr.patch + "${FILESDIR}"/${PN}-1.99.8-sysrandom.patch + "${FILESDIR}"/${PN}-1.99.8-testhole.patch ) src_prepare() { @@ -91,6 +93,7 @@ src_compile() { } src_test() { + append-cflags -fcommon # bug 707796 _emake check } diff --git a/sys-fs/dd-rescue/files/dd-rescue-1.99.8-sysrandom.patch b/sys-fs/dd-rescue/files/dd-rescue-1.99.8-sysrandom.patch new file mode 100644 index 000000000000..5ef3da297747 --- /dev/null +++ b/sys-fs/dd-rescue/files/dd-rescue-1.99.8-sysrandom.patch @@ -0,0 +1,27 @@ +Use sys/random.h for getrandom() decl if present. + +--- a/configure.in ++++ b/configure.in +@@ -6,7 +6,7 @@ AC_C_INLINE + AC_HEADER_STDC + #AC_PROG_INSTALL + #CFLAGS="$CFLAGS -DHAVE_CONFIG_H" +-AC_CHECK_HEADERS([fallocate.h dlfcn.h unistd.h sys/xattr.h sys/acl.h sys/ioctl.h sys/reg.h endian.h linux/fs.h linux/fiemap.h stdint.h lzo/lzo1x.h openssl/evp.h linux/random.h malloc.h sched.h sys/statvfs.h]) ++AC_CHECK_HEADERS([fallocate.h dlfcn.h unistd.h sys/xattr.h sys/acl.h sys/ioctl.h sys/reg.h endian.h linux/fs.h linux/fiemap.h stdint.h lzo/lzo1x.h openssl/evp.h linux/random.h sys/random.h malloc.h sched.h sys/statvfs.h]) + AC_CHECK_FUNCS([ffs ffsl basename fallocate64 splice getopt_long open64 pread pread64 lseek64 stat64 posix_fadvise posix_fadvise64 __builtin_prefetch htobe64 feof_unlocked getline getentropy getrandom posix_memalign valloc sched_yield fstatvfs __builtin_cpu_supports]) + AC_CHECK_LIB(dl,dlsym) + AC_CHECK_LIB(fallocate,linux_fallocate64) +--- a/random.c ++++ b/random.c +@@ -23,6 +23,10 @@ typedef unsigned int __u32; + #include <linux/random.h> + #endif + ++#ifdef HAVE_SYS_RANDOM_H ++#include <sys/random.h> ++#endif ++ + static void msleep(unsigned int msecs) + { + struct timespec ts1, ts2; + diff --git a/sys-fs/dd-rescue/files/dd-rescue-1.99.8-testhole.patch b/sys-fs/dd-rescue/files/dd-rescue-1.99.8-testhole.patch new file mode 100644 index 000000000000..444907088b3b --- /dev/null +++ b/sys-fs/dd-rescue/files/dd-rescue-1.99.8-testhole.patch @@ -0,0 +1,32 @@ +commit 7f2ff6434586083747bc5d046e0207886025e684 +Author: Kurt Garloff <kurt@garloff.de> +Date: Sat May 12 09:54:45 2018 +0000 + + Fix test case by ensuring there is a hole ... + +diff --git a/test_crypt.sh b/test_crypt.sh +index 47f1fc9..62cf853 100755 +--- a/test_crypt.sh ++++ b/test_crypt.sh +@@ -52,13 +52,20 @@ rm dd_rescue2 + + # Holes (all), skiphole + echo "*** Holes ***" ++# Produce file that consists of dd_rescue + hole + dd_rescue + ./dd_rescue -qpt dd_rescue dd_rescue3 + ./dd_rescue -qS 512k dd_rescue dd_rescue3 ++# Ensure there is a hole even if dd_rescue is long ++./dd_rescue -qS 384k -m 128k /dev/zero dd_rescue3 ++# Test without and with skiphole + enc_dec_compare_keys dd_rescue3 AES192-CTR keygen:ivgen "" "" "-qpt" + enc_dec_compare_keys dd_rescue3 AES192-CTR keygen:ivgen skiphole "" "-qpt" ++# Store 384k-512k in cmp3 + ./dd_rescue -qt -s 384k -m 128k -S 0 dd_rescue3.cmp dd_rescue3.cmp3 ++# Should be 128k of zeroes + ./dd_rescue -qm 128k /dev/zero dd_rescue3.cmp2 + cmp dd_rescue3.cmp2 dd_rescue3.cmp3 || exit 4 ++# Repeat test with reverse + enc_dec_compare_keys dd_rescue3 AES192-CTR keygen:ivgen "" "" "-qptr" + enc_dec_compare_keys dd_rescue3 AES192-CTR keygen:ivgen skiphole "" "-qptr" + ./dd_rescue -qt -s 384k -m 128k -S 0 dd_rescue3.cmp dd_rescue3.cmp3 + |