Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 2 Mar 2017 09:25:10 +0000 (UTC)
From:      Mahdi Mokhtari <mmokhi@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r435219 - in head/sysutils: . myrescue myrescue/files
Message-ID:  <201703020925.v229PAkQ005171@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: mmokhi
Date: Thu Mar  2 09:25:10 2017
New Revision: 435219
URL: https://svnweb.freebsd.org/changeset/ports/435219

Log:
  sysutils/myrescue: Add the port to the tree.
  myrescue is a program to rescue the still-readable data from a damaged
  hard-disk, similar in purpose to dd_rescue.
  
  PR:     217433
  Submitted by:   Mageirias Anastasios <anastasios@mageirias.com>
  Reported by:    Mageirias Anastasios <anastasios@mageirias.com>
  Reviewed by:    feld, mat
  Approved by:    feld, mat (mentors)
  Differential Revision:  https://reviews.freebsd.org/D9845

Added:
  head/sysutils/myrescue/
  head/sysutils/myrescue/Makefile   (contents, props changed)
  head/sysutils/myrescue/distinfo   (contents, props changed)
  head/sysutils/myrescue/files/
  head/sysutils/myrescue/files/patch-myrescue.c   (contents, props changed)
  head/sysutils/myrescue/pkg-descr   (contents, props changed)
Modified:
  head/sysutils/Makefile

Modified: head/sysutils/Makefile
==============================================================================
--- head/sysutils/Makefile	Thu Mar  2 09:20:24 2017	(r435218)
+++ head/sysutils/Makefile	Thu Mar  2 09:25:10 2017	(r435219)
@@ -650,6 +650,7 @@
     SUBDIR += munin-node
     SUBDIR += muse
     SUBDIR += mybashburn
+    SUBDIR += myrescue
     SUBDIR += n98-magerun
     SUBDIR += nagios-statd
     SUBDIR += namefix

Added: head/sysutils/myrescue/Makefile
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/sysutils/myrescue/Makefile	Thu Mar  2 09:25:10 2017	(r435219)
@@ -0,0 +1,23 @@
+# $FreeBSD$
+
+PORTNAME=	myrescue
+PORTVERSION=	0.9.4
+CATEGORIES=	sysutils
+MASTER_SITES=	SF/${PORTNAME}/${PORTNAME}/${PORTNAME}-${PORTVERSION}/
+
+MAINTAINER=	anastasios@mageirias.com
+COMMENT=	Rescue still-readable data from a damaged harddisk
+
+LICENSE=	GPLv2
+LICENSE_FILE=	${WRKSRC}/../COPYING
+
+WRKSRC_SUBDIR=	src
+
+PLIST_FILES=	bin/myrescue \
+		man/man1/myrescue.1.gz
+
+do-install:
+	${INSTALL_PROGRAM} ${WRKSRC}/myrescue ${STAGEDIR}${PREFIX}/bin
+	${INSTALL_MAN} ${WRKDIR}/${DISTNAME}/doc/myrescue.1 ${STAGEDIR}${MANPREFIX}/man/man1
+
+.include <bsd.port.mk>

Added: head/sysutils/myrescue/distinfo
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/sysutils/myrescue/distinfo	Thu Mar  2 09:25:10 2017	(r435219)
@@ -0,0 +1,3 @@
+TIMESTAMP = 1486501077
+SHA256 (myrescue-0.9.4.tar.gz) = 0cdfa61df0f73e3a3362dcacd944b7d25223b679a66f53f65b97de45c4aa5501
+SIZE (myrescue-0.9.4.tar.gz) = 16932

Added: head/sysutils/myrescue/files/patch-myrescue.c
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/sysutils/myrescue/files/patch-myrescue.c	Thu Mar  2 09:25:10 2017	(r435219)
@@ -0,0 +1,74 @@
+--- myrescue.c.orig	2017-02-10 01:59:06 UTC
++++ myrescue.c
+@@ -36,7 +36,7 @@
+ 
+ long long filesize ( int fd )
+ {
+-	long long rval = lseek64(fd, 0, SEEK_END) ;
++	long long rval = lseek(fd, 0, SEEK_END) ;
+ 	if (rval < 0) {
+ 		perror("filesize");
+ 		exit(-1);
+@@ -47,8 +47,8 @@ long long filesize ( int fd )
+ int peek_map(int bitmap_fd, int block)
+ {
+ 	char c = 0;
+-	if (lseek64(bitmap_fd, block, SEEK_SET) < 0) {
+-		perror("peek_map lseek64");
++	if (lseek(bitmap_fd, block, SEEK_SET) < 0) {
++		perror("peek_map lseek");
+ 		exit(-1);
+ 	}
+ 	if (read(bitmap_fd, &c, 1) < 0) {
+@@ -60,8 +60,8 @@ int peek_map(int bitmap_fd, int block)
+ 
+ void poke_map(int bitmap_fd, int block, char val)
+ {
+-	if (lseek64(bitmap_fd, block, SEEK_SET) < 0) {
+-		perror("poke_map lseek64");
++	if (lseek(bitmap_fd, block, SEEK_SET) < 0) {
++		perror("poke_map lseek");
+ 		exit(-1);
+ 	}
+ 	if (write(bitmap_fd, &val, 1) != 1) {
+@@ -81,13 +81,13 @@ int copy_block( int src_fd, int dst_fd, 
+ 	filepos = block_num;
+ 	filepos *= block_size;
+ 
+-	if (lseek64(src_fd, filepos, SEEK_SET) < 0) {
+-		perror("lseek64 src_fd");
++	if (lseek(src_fd, filepos, SEEK_SET) < 0) {
++		perror("lseek src_fd");
+ 		return errno;
+ 	}
+ 
+-	if (lseek64(dst_fd, filepos, SEEK_SET) < 0) {
+-		perror("lseek64 dst_fd");
++	if (lseek(dst_fd, filepos, SEEK_SET) < 0) {
++		perror("lseek dst_fd");
+ 		return errno;
+ 	}
+ 
+@@ -479,19 +479,19 @@ int main(int argc, char** argv)
+ 
+ 	/* open files */
+ 
+-	src_fd = open64(src_name, O_RDONLY);
++	src_fd = open(src_name, O_RDONLY);
+ 	if ( src_fd < 0 ) {
+ 		perror ( "source open failed" ) ;
+ 		exit(-1) ;
+ 	}
+ 
+-	dst_fd = open64(dst_name, O_RDWR | O_CREAT, 0600);
++	dst_fd = open(dst_name, O_RDWR | O_CREAT, 0600);
+ 	if ( dst_fd < 0 ) {
+ 		perror ( "destination open failed" ) ;
+ 		exit(-1) ;
+ 	}
+ 
+-	bitmap_fd = open64(bitmap_name, O_RDWR | O_CREAT, 0600);
++	bitmap_fd = open(bitmap_name, O_RDWR | O_CREAT, 0600);
+ 	if ( bitmap_fd < 0 ) {
+ 		perror ( "bitmap open failed" ) ;
+ 		exit(-1) ;

Added: head/sysutils/myrescue/pkg-descr
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/sysutils/myrescue/pkg-descr	Thu Mar  2 09:25:10 2017	(r435219)
@@ -0,0 +1,6 @@
+myrescue is a program to rescue the still-readable data from a damaged 
+hard-disk. It is similar in purpose to dd_rescue, but it tries to quickly get
+out of damaged areas, handling the non-damaged areas and then returning to
+the damaged sections later.
+
+WWW: https://sourceforge.net/projects/myrescue



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201703020925.v229PAkQ005171>