Module Name: src Committed By: mrg Date: Sun Aug 15 07:27:34 UTC 2010
Modified Files: src/distrib/sets: Makefile maketars src/share/mk: bsd.README bsd.own.mk src/tools: Makefile Log Message: add new option to build/use tools/pigz for compressing sets. for now USE_PIGZGZIP defaults to "no". (it depends upon local <pthread.h> and -lz.) you can set it to "yes" on most modern platforms just fine. To generate a diff of this commit: cvs rdiff -u -r1.79 -r1.80 src/distrib/sets/Makefile cvs rdiff -u -r1.73 -r1.74 src/distrib/sets/maketars cvs rdiff -u -r1.273 -r1.274 src/share/mk/bsd.README cvs rdiff -u -r1.638 -r1.639 src/share/mk/bsd.own.mk cvs rdiff -u -r1.139 -r1.140 src/tools/Makefile Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/distrib/sets/Makefile diff -u src/distrib/sets/Makefile:1.79 src/distrib/sets/Makefile:1.80 --- src/distrib/sets/Makefile:1.79 Tue Jun 29 05:51:53 2010 +++ src/distrib/sets/Makefile Sun Aug 15 07:27:33 2010 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.79 2010/06/29 05:51:53 mrg Exp $ +# $NetBSD: Makefile,v 1.80 2010/08/15 07:27:33 mrg Exp $ # The `all' target must appear before bsd.own.mk is pulled in. all: @@ -8,6 +8,12 @@ .include <bsd.own.mk> .include "${NETBSDSRCDIR}/distrib/common/Makefile.distrib" +.if ${USE_PIGZGZIP} != "no" +COMPRESS_PROGRAM=${TOOL_PIGZ:Q} +.else +COMPRESS_PROGRAM=gzip +.endif + SETSENV= DESTDIR=${DESTDIR:Q} \ MACHINE=${MACHINE:Q} \ MACHINE_ARCH=${MACHINE_ARCH:Q} \ @@ -19,7 +25,7 @@ MKTEMP=${TOOL_MKTEMP:Q} \ MTREE=${TOOL_MTREE:Q} \ PAX=${TOOL_PAX:Q} \ - PIGZ=${TOOL_PIGZ:Q} \ + COMPRESS_PROGRAM=${COMPRESS_PROGRAM:Q} \ PKG_CREATE=${TOOL_PKG_CREATE:Q} \ SED=${TOOL_SED:Q} \ TSORT=${TSORT:Q} Index: src/distrib/sets/maketars diff -u src/distrib/sets/maketars:1.73 src/distrib/sets/maketars:1.74 --- src/distrib/sets/maketars:1.73 Thu Dec 10 02:22:57 2009 +++ src/distrib/sets/maketars Sun Aug 15 07:27:33 2010 @@ -1,6 +1,6 @@ #!/bin/sh # -# $NetBSD: maketars,v 1.73 2009/12/10 02:22:57 uebayasi Exp $ +# $NetBSD: maketars,v 1.74 2010/08/15 07:27:33 mrg Exp $ # # Make release tar files for some or all lists. Usage: # maketars [-b] [-x] [-i installdir] [-a arch] [-m machine] [-s setsdir] @@ -217,6 +217,7 @@ TMPFILES="${TMPFILES} ${tars}/${out}.tmp" ( cd "${dest}"; \ ${PAX} -O -w -d -z -N"${etcdir}" ${metalog:+-M} \ + --use-compress-program ${COMPRESS_PROGRAM} \ < "${setlistdir}/set.${setname}" ) \ > "${tars}/${out}.tmp" && mv "${tars}/${out}.tmp" "${tars}/${out}" Index: src/share/mk/bsd.README diff -u src/share/mk/bsd.README:1.273 src/share/mk/bsd.README:1.274 --- src/share/mk/bsd.README:1.273 Sun Jun 20 06:54:24 2010 +++ src/share/mk/bsd.README Sun Aug 15 07:27:33 2010 @@ -1,4 +1,4 @@ -# $NetBSD: bsd.README,v 1.273 2010/06/20 06:54:24 mrg Exp $ +# $NetBSD: bsd.README,v 1.274 2010/08/15 07:27:33 mrg Exp $ # @(#)bsd.README 8.2 (Berkeley) 4/2/94 This is the README file for the make "include" files for the NetBSD @@ -416,6 +416,11 @@ various system utilities/libraries that support it. If ${MKYP} is "no", USE_YP will also be forced to "no". +USE_PIGZGZIP If "no", use the host "gzip" program to compress sets. + Otherwise, build tools/pigz and use nbpigz to compress + the sets. + Default: "no". + X11FLAVOUR Set to "Xorg" or "XFree86", depending on whether to build XFree86 or modular Xorg. Only matters if MKX11!=no. Default: "Xorg" on amd64, i386, macppc, shark and sparc64, Index: src/share/mk/bsd.own.mk diff -u src/share/mk/bsd.own.mk:1.638 src/share/mk/bsd.own.mk:1.639 --- src/share/mk/bsd.own.mk:1.638 Mon Aug 2 07:08:26 2010 +++ src/share/mk/bsd.own.mk Sun Aug 15 07:27:34 2010 @@ -1,4 +1,4 @@ -# $NetBSD: bsd.own.mk,v 1.638 2010/08/02 07:08:26 jmmv Exp $ +# $NetBSD: bsd.own.mk,v 1.639 2010/08/15 07:27:34 mrg Exp $ # This needs to be before bsd.init.mk .if defined(BSD_MK_COMPAT_FILE) @@ -869,9 +869,10 @@ # # USE_* options which default to "no". # -#.for var in -#${var}?= no -#.endfor +# For now, disable pigz as compressor by default +.for var in USE_PIGZGZIP +${var}?= no +.endfor # # Where X11 sources are and where it is installed to. Index: src/tools/Makefile diff -u src/tools/Makefile:1.139 src/tools/Makefile:1.140 --- src/tools/Makefile:1.139 Fri Jun 18 18:57:27 2010 +++ src/tools/Makefile Sun Aug 15 07:27:33 2010 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.139 2010/06/18 18:57:27 jmcneill Exp $ +# $NetBSD: Makefile,v 1.140 2010/08/15 07:27:33 mrg Exp $ .include <bsd.own.mk> @@ -74,6 +74,10 @@ SUBDIR+= autoconf .WAIT gettext .endif +.if ${USE_PIGZGZIP} != "no" +SUBDIR+= pigz +.endif + .if ${MACHINE} == "hp700" SUBDIR+= hp700-mkboot .endif