aboutsummaryrefslogtreecommitdiff
path: root/archivers
diff options
context:
space:
mode:
authorMartin Matuska <mm@FreeBSD.org>2010-11-23 10:26:40 +0000
committerMartin Matuska <mm@FreeBSD.org>2010-11-23 10:26:40 +0000
commitf7bfa6901d8b25005b6509b8e7e1e7d0e3696d11 (patch)
tree3937e02c67d4ee66ff7abdeb819a36bf859c0f21 /archivers
parentc24e2a6b7cdce23864f027acd785d6d07e8d6fee (diff)
downloadports-f7bfa6901d8b25005b6509b8e7e1e7d0e3696d11.tar.gz
ports-f7bfa6901d8b25005b6509b8e7e1e7d0e3696d11.zip
Parallel XZ is a compression utility that takes advantage of running LZMA
compression of different parts of an input file on multiple cores and processors simultaneously. Its primary goal is to utilize all resources to speed up compression time with minimal possible influence on compression ratio. WWW: http://jnovy.fedorapeople.org/pxz/
Notes
Notes: svn path=/head/; revision=264990
Diffstat (limited to 'archivers')
-rw-r--r--archivers/Makefile1
-rw-r--r--archivers/pxz/Makefile50
-rw-r--r--archivers/pxz/distinfo2
-rw-r--r--archivers/pxz/files/patch-pxz.c47
-rw-r--r--archivers/pxz/pkg-descr7
5 files changed, 107 insertions, 0 deletions
diff --git a/archivers/Makefile b/archivers/Makefile
index 8cde62745310..9d35a6900502 100644
--- a/archivers/Makefile
+++ b/archivers/Makefile
@@ -141,6 +141,7 @@
SUBDIR += ppmd
SUBDIR += ppmd-7z
SUBDIR += ppunpack
+ SUBDIR += pxz
SUBDIR += py-liblzma
SUBDIR += py-librtfcomp
SUBDIR += py-lzma
diff --git a/archivers/pxz/Makefile b/archivers/pxz/Makefile
new file mode 100644
index 000000000000..a8e28a9a2b83
--- /dev/null
+++ b/archivers/pxz/Makefile
@@ -0,0 +1,50 @@
+# New ports collection makefile for: pxz
+# Date created: 2011-23-16
+# Whom: mm
+#
+# $FreeBSD$
+#
+
+PORTNAME= pxz
+PORTVERSION= 0.20101123
+CATEGORIES= archivers
+MASTER_SITES= ${MASTER_SITE_LOCAL}
+MASTER_SITE_SUBDIR= mm
+DISTNAME= pxz-git-${PORTVERSION:S/0.//}
+
+MAINTAINER= mm@FreeBSD.org
+COMMENT= Parallel LZMA compressor using liblzma
+
+WRKSRC= ${WRKDIR}/${PORTNAME}
+
+PLIST_FILES= bin/pxz
+MAN1= pxz.1
+
+MAKE_ENV+= BINDIR=${PREFIX}/bin \
+ MANDIR=${MANPREFIX}/man
+
+.if !defined(NOPORTDOCS)
+PORTDOCS= COPYING
+.endif
+
+.include <bsd.port.pre.mk>
+
+.if ${OSVERSION} < 800505 || (${OSVERSION} >= 900000 && ${OSVERSION} < 900012)
+LIB_DEPENDS+= lzma.5:${PORTSDIR}/archivers/xz
+CFLAGS+= -I${LOCALBASE}/include
+LDFLAGS+= -L${LOCALBASE}/lib
+MAKE_ENV+= LDFLAGS="${LDFLAGS}"
+.endif
+
+post-patch:
+ @${REINPLACE_CMD} -e 's/CC=.*/CC:=$${CC}/g' ${WRKSRC}/Makefile
+
+post-install:
+.if !defined(NOPORTDOCS)
+ @${MKDIR} ${DOCSDIR}
+. for FILE in ${PORTDOCS}
+ @${INSTALL_DATA} ${WRKSRC}/${FILE} ${DOCSDIR}/${FILE}
+. endfor
+.endif
+
+.include <bsd.port.post.mk>
diff --git a/archivers/pxz/distinfo b/archivers/pxz/distinfo
new file mode 100644
index 000000000000..bf23e0dcc7da
--- /dev/null
+++ b/archivers/pxz/distinfo
@@ -0,0 +1,2 @@
+SHA256 (pxz-git-20101123.tar.gz) = 8f823dd1f5d7a02a8d28420964450b63946ed10dc8435284566297be34b1e43d
+SIZE (pxz-git-20101123.tar.gz) = 50700
diff --git a/archivers/pxz/files/patch-pxz.c b/archivers/pxz/files/patch-pxz.c
new file mode 100644
index 000000000000..8878d8ea28c5
--- /dev/null
+++ b/archivers/pxz/files/patch-pxz.c
@@ -0,0 +1,47 @@
+--- pxz.c.orig 2010-11-23 10:35:25.720939440 +0100
++++ pxz.c 2010-11-23 10:46:28.910235910 +0100
+@@ -21,11 +21,17 @@
+
+ #include <string.h>
+ #include <stdio.h>
+-#include <stdio_ext.h>
++#ifndef __FreeBSD__
++#include <stdio_ext.h>
++#endif
+ #include <stdlib.h>
+ #include <inttypes.h>
+ #include <unistd.h>
+-#include <error.h>
++#ifdef __FreeBSD__
++#include <err.h>
++#else
++#include <error.h>
++#endif
+ #include <errno.h>
+ #include <sys/stat.h>
+ #include <sys/mman.h>
+@@ -40,6 +46,10 @@
+ #include <omp.h>
+ #endif
+
++#ifdef __FreeBSD__
++#define error errc
++#endif
++
+ #ifndef XZ_BINARY
+ #define XZ_BINARY "xz"
+ #endif
+@@ -119,6 +129,13 @@
+ { NULL, 0, NULL, 0 }
+ };
+
++#ifdef __FreeBSD__
++static size_t __fpending (FILE *fp)
++{
++ return (fp->_p - fp->_bf._base);
++}
++#endif
++
+ void __attribute__((noreturn)) run_xz( char **argv ) {
+ execvp(XZ_BINARY, argv);
+ error(0, errno, "execution of "XZ_BINARY" binary failed");
diff --git a/archivers/pxz/pkg-descr b/archivers/pxz/pkg-descr
new file mode 100644
index 000000000000..3356326a5918
--- /dev/null
+++ b/archivers/pxz/pkg-descr
@@ -0,0 +1,7 @@
+Parallel XZ is a compression utility that takes advantage of running LZMA
+compression of different parts of an input file on multiple cores and
+processors simultaneously.
+Its primary goal is to utilize all resources to speed up compression time
+with minimal possible influence on compression ratio.
+
+WWW: http://jnovy.fedorapeople.org/pxz/