ports/137581: [patch] archivers/lzmautils-devel (xz): correct detection of number of processors
David Naylor
naylor.b.david at gmail.com
Tue Aug 18 07:10:05 UTC 2009
The following reply was made to PR ports/137581; it has been noted by GNATS.
From: David Naylor <naylor.b.david at gmail.com>
To: bug-followup at freebsd.org,
martin at email.aon.at
Cc:
Subject: Re: ports/137581: [patch] archivers/lzmautils-devel (xz): correct detection of number of processors
Date: Tue, 18 Aug 2009 09:02:08 +0200
--Boundary-00=_zHliKmmLDcACHcH
Content-Type: text/plain;
charset="us-ascii"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline
Attached is a patch that can be applied against the port. It does fix the
output from `xz -H` however when running tests the (de)compression doesn't
use more than one thread.
--Boundary-00=_zHliKmmLDcACHcH
Content-Type: text/x-diff;
charset="iso 8859-15";
name="lzmautils-devel.diff"
Content-Transfer-Encoding: 7bit
Content-Disposition: attachment;
filename="lzmautils-devel.diff"
diff -urN /usr/ports/archivers/lzmautils-devel/Makefile lzmautils-devel/Makefile
--- /usr/ports/archivers/lzmautils-devel/Makefile 2009-03-01 18:23:41.000000000 +0200
+++ lzmautils-devel/Makefile 2009-08-18 08:14:22.000000000 +0200
@@ -7,6 +7,7 @@
PORTNAME= lzmautils
DISTVERSION= 4.999.8
+PORTREVISION= 1
CATEGORIES= archivers
MASTER_SITES= http://tukaani.org/xz/ \
http://freebsd.unixfreunde.de/sources/
diff -urN /usr/ports/archivers/lzmautils-devel/files/patch-src-xz-hardware.c lzmautils-devel/files/patch-src-xz-hardware.c
--- /usr/ports/archivers/lzmautils-devel/files/patch-src-xz-hardware.c 1970-01-01 02:00:00.000000000 +0200
+++ lzmautils-devel/files/patch-src-xz-hardware.c 2009-08-18 08:18:51.000000000 +0200
@@ -0,0 +1,17 @@
+--- src/xz/hardware.c~ 2009-08-18 08:15:18.000000000 +0200
++++ src/xz/hardware.c 2009-08-18 08:17:50.000000000 +0200
+@@ -42,12 +42,12 @@
+ static void
+ hardware_cores(void)
+ {
+-#if defined(HAVE_NUM_PROCESSORS_SYSCONF)
++#if defined(HAVE_NCPU_SYSCONF)
+ const long cpus = sysconf(_SC_NPROCESSORS_ONLN);
+ if (cpus > 0)
+ opt_threads = (size_t)(cpus);
+
+-#elif defined(HAVE_NUM_PROCESSORS_SYSCTL)
++#elif defined(HAVE_NCPU_SYSCTL)
+ int name[2] = { CTL_HW, HW_NCPU };
+ int cpus;
+ size_t cpus_size = sizeof(cpus);
--Boundary-00=_zHliKmmLDcACHcH--
More information about the freebsd-ports-bugs
mailing list