diff --git a/mk/bsd.pkg.extract.mk b/mk/bsd.pkg.extract.mk index 0fd6f6e82c81..502a39842fb0 100644 --- a/mk/bsd.pkg.extract.mk +++ b/mk/bsd.pkg.extract.mk @@ -1,4 +1,4 @@ -# $NetBSD: bsd.pkg.extract.mk,v 1.5 2005/05/16 04:22:40 jlam Exp $ +# $NetBSD: bsd.pkg.extract.mk,v 1.6 2005/05/16 18:43:20 jlam Exp $ # # This Makefile fragment is included to bsd.pkg.mk and defines the # relevant variables and targets for the "extract" phase. @@ -22,8 +22,8 @@ # that ends in . # # EXTRACT_USING specifies the tool used to extract tar/ustar-format -# archives. The possible values are "pax" and "gtar". By -# default, we use the "pax" tool. +# archives. The possible values are "gtar", "nbtar", and "pax". +# By default, we use the "nbtar" tool (NetBSD's pax-as-tar). # # EXTRACT_ELEMENTS is a list of files within the distfile to extract. # This variable only takes effect for distfiles that are tarballs. @@ -38,7 +38,7 @@ EXTRACT_ONLY?= ${DISTFILES} EXTRACT_SUFX?= .tar.gz -EXTRACT_USING?= pax +EXTRACT_USING?= nbtar _EXTRACT_SUFFIXES= .tar.gz .tgz .tar.bz2 .tbz .tar.Z .tar _tar.gz _EXTRACT_SUFFIXES+= .shar.gz .shar.bz2 .shar.Z .shar @@ -55,6 +55,8 @@ _EXTRACT_SUFFIXES+= .rar !empty(EXTRACT_SUFX:M*.tbz) || !empty(EXTRACT_SUFX:M*.tgz) . if !empty(EXTRACT_USING:Mgtar) PKGSRC_USE_TOOLS+= gtar +. elif !empty(EXTRACT_USING:Mnbtar) +PKGSRC_USE_TOOLS+= tar . else PKGSRC_USE_TOOLS+= pax . endif @@ -165,6 +167,8 @@ EXTRACT_CMD${__suffix__}?= ${DECOMPRESS_CMD${__suffix__}} $${extract_file} | ${S .if !empty(EXTRACT_USING:Mgtar) _DFLT_EXTRACT_CMD?= ${DECOMPRESS_CMD} $${extract_file} | ${GTAR} -xf - ${EXTRACT_ELEMENTS} +.elif !empty(EXTRACT_USING:Mnbtar) +_DFLT_EXTRACT_CMD?= ${DECOMPRESS_CMD} $${extract_file} | ${TAR} -xf - ${EXTRACT_ELEMENTS} .else _DFLT_EXTRACT_CMD?= ${DECOMPRESS_CMD} $${extract_file} | ${PAX} -O -r ${EXTRACT_ELEMENTS} .endif @@ -173,6 +177,8 @@ _DFLT_EXTRACT_CMD?= ${DECOMPRESS_CMD} $${extract_file} | ${PAX} -O -r ${EXTRACT_ . if !defined(EXTRACT_CMD${__suffix__}) . if !empty(EXTRACT_USING:Mgtar) EXTRACT_CMD${__suffix__}?= ${DECOMPRESS_CMD${__suffix__}} $${extract_file} | ${GTAR} -xf - ${EXTRACT_ELEMENTS} +. elif !empty(EXTRACT_USING:Mnbtar) +EXTRACT_CMD${__suffix__}?= ${DECOMPRESS_CMD${__suffix__}} $${extract_file} | ${TAR} -xf - ${EXTRACT_ELEMENTS} . else EXTRACT_CMD${__suffix__}?= ${DECOMPRESS_CMD${__suffix__}} $${extract_file} | ${PAX} -O -r ${EXTRACT_ELEMENTS} . endif diff --git a/mk/defaults/mk.conf b/mk/defaults/mk.conf index 446f6350d12a..fc68d8dd7e9e 100644 --- a/mk/defaults/mk.conf +++ b/mk/defaults/mk.conf @@ -1,4 +1,4 @@ -# $NetBSD: mk.conf,v 1.41 2005/05/16 03:07:38 jlam Exp $ +# $NetBSD: mk.conf,v 1.42 2005/05/16 18:43:20 jlam Exp $ # # A file providing defaults for pkgsrc and the packages collection. @@ -507,10 +507,10 @@ PATCH_FUZZ_FACTOR?= -F0 # Possible: any combination of packages # Default: not set -EXTRACT_USING?= pax +EXTRACT_USING?= nbtar # Use the specified tool to extract tar/ustar archives. -# Possible: pax, gtar -# Default: pax +# Possible: gtar, nbtar, pax +# Default: nbtar #FAILOVER_FETCH= # Perform a checksum at "make fetch" time. If the checksum doesn't