Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 20 Mar 2013 03:36:44 +0000 (UTC)
From:      Alexey Dokuchaev <danfe@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r314709 - in head/archivers: . zpaq zpaq/files
Message-ID:  <201303200336.r2K3aiK9062898@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: danfe
Date: Wed Mar 20 03:36:44 2013
New Revision: 314709
URL: http://svnweb.freebsd.org/changeset/ports/314709

Log:
  Add zpaq 6.22, a journaling, incremental, deduplicating archiver.

Added:
  head/archivers/zpaq/
  head/archivers/zpaq/Makefile   (contents, props changed)
  head/archivers/zpaq/distinfo   (contents, props changed)
  head/archivers/zpaq/files/
  head/archivers/zpaq/files/patch-zpaq.cc   (contents, props changed)
  head/archivers/zpaq/pkg-descr   (contents, props changed)
Modified:
  head/archivers/Makefile

Modified: head/archivers/Makefile
==============================================================================
--- head/archivers/Makefile	Wed Mar 20 03:02:51 2013	(r314708)
+++ head/archivers/Makefile	Wed Mar 20 03:36:44 2013	(r314709)
@@ -211,6 +211,7 @@
     SUBDIR += zip
     SUBDIR += zipmix
     SUBDIR += zipper
+    SUBDIR += zpaq
     SUBDIR += zoo
     SUBDIR += zutils
 

Added: head/archivers/zpaq/Makefile
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/archivers/zpaq/Makefile	Wed Mar 20 03:36:44 2013	(r314709)
@@ -0,0 +1,36 @@
+# Created by: Alexey Dokuchaev <danfe@FreeBSD.org>
+# $FreeBSD$
+
+PORTNAME=	zpaq
+PORTVERSION=	6.22
+CATEGORIES=	archivers
+MASTER_SITES=	http://mattmahoney.net/dc/
+DISTNAME=	${PORTNAME}${PORTVERSION:S/.//g}
+
+MAINTAINER=	danfe@FreeBSD.org
+COMMENT=	Journaling, incremental, deduplicating archiver
+
+LICENSE=	GPLv3
+
+USE_ZIP=	yes
+USE_DOS2UNIX=	zpaq.cpp
+NO_WRKSUBDIR=	yes
+
+PLIST_FILES=	bin/zpaq bin/zpaqd
+
+.include <bsd.port.pre.mk>
+
+.if ${ARCH} != "i386" && ${ARCH} != "amd64"
+CXXFLAGS+=	-DNOJIT
+.endif
+
+do-build:
+	cd ${BUILD_WRKSRC} && ${CXX} ${CXXFLAGS} -Dunix -DNDEBUG zpaq.cpp \
+		libzpaq.cpp divsufsort.c -o zpaq -fopenmp -pthread
+	cd ${BUILD_WRKSRC} && ${CXX} ${CXXFLAGS} -Dunix zpaqd.cpp \
+		libzpaq.cpp -o zpaqd
+
+do-install:
+	${INSTALL_PROGRAM} ${WRKSRC}/zpaq ${WRKSRC}/zpaqd ${PREFIX}/bin
+
+.include <bsd.port.post.mk>

Added: head/archivers/zpaq/distinfo
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/archivers/zpaq/distinfo	Wed Mar 20 03:36:44 2013	(r314709)
@@ -0,0 +1,2 @@
+SHA256 (zpaq622.zip) = aceae6dba77240425c8498ff588e7a40260fe59ea9f5b81e7bb3e0ab13535ba5
+SIZE (zpaq622.zip) = 827047

Added: head/archivers/zpaq/files/patch-zpaq.cc
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/archivers/zpaq/files/patch-zpaq.cc	Wed Mar 20 03:36:44 2013	(r314709)
@@ -0,0 +1,38 @@
+--- zpaq.cpp.orig	2013-03-20 11:24:18.000000000 +0800
++++ zpaq.cpp	2013-03-20 11:26:23.000000000 +0800
+@@ -147,7 +147,7 @@
+ The default is to detect the number of processor cores and use that value
+ or the limit according to -method, whichever is less. The number of cores
+ is detected from the environment variable %NUMBER_OF_PROCESSORS% in
+-Windows or /proc/cpuinfo in Linux.
++Windows or via sysconf(_SC_NPROCESSORS_ONLN) in Unix.
+ 
+   -method M[n|e][C[N1][,N2]...]...
+ 
+@@ -1090,25 +1090,7 @@
+ int numberOfProcessors() {
+   int rc=0;  // result
+ #ifdef unix
+-
+-  // Count lines of the form "processor\t: %d\n" in /proc/cpuinfo
+-  // where %d is 0, 1, 2,..., rc-1
+-  FILE *in=fopen("/proc/cpuinfo", "r");
+-  if (!in) return 1;
+-  std::string s;
+-  int c;
+-  while ((c=getc(in))!=EOF) {
+-    if (c>='A' && c<='Z') c+='a'-'A';  // convert to lowercase
+-    if (c>' ') s+=c;  // remove white space
+-    if (c=='\n') {  // end of line?
+-      if (size(s)>10 && s.substr(0, 10)=="processor:") {
+-        c=atoi(s.c_str()+10);
+-        if (c==rc) ++rc;
+-      }
+-      s="";
+-    }
+-  }
+-  fclose(in);
++  rc = sysconf(_SC_NPROCESSORS_ONLN);
+ #else
+ 
+   // In Windows return %NUMBER_OF_PROCESSORS%

Added: head/archivers/zpaq/pkg-descr
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/archivers/zpaq/pkg-descr	Wed Mar 20 03:36:44 2013	(r314709)
@@ -0,0 +1,22 @@
+ZPAQ is a journaling, incremental, deduplicating archiver for Windows and
+Unix.  "Journaling" means that when you update a file or directory, both the
+old and new versions are saved.  You can extract from the archive as it
+existed at any time in the past.
+
+"Incremental" means that when you back up your entire hard drive, only those
+files whose last-modified date has changed since the previous backup are
+added.  For 100 GB of files, this typically takes 1-2 minutes, vs. few hours
+to create the first version.
+
+"Deduplicating" means that identical files or fragments are stored only once
+to save time and space.
+
+Files are compressed in the open standard ZPAQ format, which is supported by
+a specification, reference decoder, and a test case (which should decode to
+the Calgary corpus), and a public domain C++ API that provides compression
+and decompression services.  The format is not known to be encumbered by any
+patents.  ZPAQ stores the decompression algorithm description in the archive,
+which means that when archive is updated to a better compression algorithm,
+older extractors will still be able to read the new archives.
+
+WWW: http://mattmahoney.net/dc/zpaq.html



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