Subject: Re: FYI: upgrading GNU tar
To: NetBSD-current Discussion List <current-users@NetBSD.ORG>
From: Greg A. Woods <woods@weird.com>
List: current-users
Date: 10/11/2002 18:27:40
[ On Friday, October 11, 2002 at 18:05:51 (-0400), Greg A. Woods wrote: ]
> Subject: Re: FYI: upgrading GNU tar
>
> I haven't ever encountered any tar archives on the net that cause me any
> grief with 'pax', though I can't claim to have unpacked even all those
> used in pkgsrc (${GTAR} is defined in pkgsrc, but I don't immediately
> see any use of it in any of the makefiles I have, and I have had
> EXTRACT_USING_PAX defined for quite a long time now and I've patched the
> related _DFLT_EXTRACT_CMD to use 'pax -O' instead of 'dd | pax' too).

Hmmm... that's not quite right....  I screwed up the search....

I don't know how many of these are "necessary" uses of GNU Tar and how
many are "Just Because" (not many/any I suspect, though I only use one
of them -- most should probably be modified to use ${EXTRACT_CMD}, and
some like sysutils/cpuburn/Makefile are particularly strange):

$ fgrep GTAR */*/Makefile.common       
fonts/acroread-font-share/Makefile.common:      @${GTAR} xf ${TAR_FILE} -C ${PREFIX}/Acrobat4/Resource
fonts/acroread5-font-share/Makefile.common:     @${GTAR} xf ${TAR_FILE} -C ${PREFIX}/Acrobat5/Resource/Font
fonts/cyr-rfx-share/Makefile.common:    @${GTAR} xzf ${_DISTDIR}/${DISTFILES} -C ${PREFIX}/lib/X11/fonts/local ${CYR_RFX_ENCODING}/misc ${CYR_RFX_ENCODING}/75dpi
www/navigator/Makefile.common:  cd ${MOZILLA_HOME} ; ${GTAR} xpzf ${WRKSRC}/nethelp-v${NS_VERS_SHORT}.nif
www/navigator/Makefile.common:  cd ${MOZILLA_HOME} ; ${GTAR} --exclude 'libflashplayer.so' \
www/navigator/Makefile.common:  cd ${MOZILLA_HOME} ; ${GTAR} xpzf ${WRKSRC}/spellchk-v${NS_VERS_SHORT}.nif

$ fgrep GTAR */*/Makefile        
cad/qcad/Makefile:      (cd ${WRKSRC}; ${GTAR} cf - AUTHORS COPYING README     \
cad/qcad/Makefile:      (cd ${PREFIX}/share/qcad; ${GTAR} vxf - )
databases/tcl-postgresql/Makefile:      ${GTAR} zxCf ${PREFIX}/man ${WRKSRC}/doc/man.tar.gz             \
databases/tk-postgresql/Makefile:       ${GTAR} zxCf ${PREFIX}/man ${WRKSRC}/doc/man.tar.gz             \
devel/libnet/Makefile:  @(cd ${WRKSRC}/doc/html; ${GTAR} cf - *.html *.gif */*.c | \
devel/libnet/Makefile:          (cd ${PREFIX}/${DOCDIR};${GTAR} xf -))
devel/patch/Makefile:.if !exists(${GTAR})
devel/patch/Makefile:GTAR=              /usr/bin/tar            # Solaris
editors/ted-en-us/Makefile:     @cd ${WRKSRC} ; ${GTAR} xf tedPackage/TedBindist.tar
editors/ted/Makefile:   @cd ${WRKSRC} ; ${GTAR} xf tedPackage/TedBindist.tar
editors/xemacs-packages/Makefile:       @${GTAR} xCzf ${PREFIX}/lib/xemacs/xemacs-packages \
editors/xemacs/Makefile:                ${GTAR} xzCf ${WRKDIR} ${DISTDIR}/${DIST_SUBDIR}/$$FILE; \
emulators/linuxppc_lib/Makefile:        cd ${PREFIX}/${EMUL_LINUX}/usr/X11R6 ; ${GTAR} -x 'lib/*.so*' \
fonts/freefonts/Makefile:       ${GTAR} Cxzf ${PREFIX}/lib/X11/fonts \
games/abuse/Makefile:       ${GZCAT} ${DISTDIR}/abuse_data.tar.gz | ${GTAR} xf -
games/battalion/Makefile:           ${GZCAT} ${DISTDIR}/battalionSUN4.tar.gz | ${GTAR} xmf -
games/crossfire-cli/Makefile:       ${GZCAT} ${DISTDIR}/${CF_SND} | ${GTAR} xmf -
games/crossfire-cli/Makefile:       ${GZCAT} ${DISTDIR}/${CF_RAW} | ${GTAR} xmf -
games/crossfire-srv/Makefile:       ${GZCAT} ${DISTDIR}/${CF_MAPS} | ${GTAR} xmf -
games/heretic2-demo/Makefile:                                                  ${GTAR} xzf -
games/kulki/Makefile:           ( ${GUNZIP_CMD} -c ${WRKSRC}/images.tgz | ${GTAR} xf - )
games/quake3arena-demo/Makefile:                                               ${GTAR} xzf -
games/quake3arena/Makefile:                                                    ${GTAR} xzf -
games/rollemup/Makefile:        @${GTAR} xCzf ${PREFIX}/${GAMES_DIR} ${_DISTDIR}/${DISTFILES}
games/xdoom/Makefile:   (cd ${WRKDIR}; ${GTAR} xzf linuxdoom-1.10.src.tgz)
games/xdoom/Makefile:   (cd ${WRKDIR}; ${GTAR} xzf sndserv.tgz)
graphics/CompuPic/Makefile:     ${GTAR} plzxCf ${PREFIX}/libexec/ ${_DISTDIR}/${DISTFILES}
graphics/Ngraph/Makefile:       ${GTAR} -C ${WRKSRC}/combo -xzf ${DISTDIR}/ileaf-widgets.tar.Z
graphics/Ngraph/Makefile:       ${GTAR} -C ${PREFIX}/libexec/Ngraph -xzf ${DISTDIR}/Ngraph-6.3-doc.tar.gz
graphics/gmplayer/Makefile:     @${GTAR} xCzf ${PREFIX}/share/mplayer/Skin/ ${DISTDIR}/${DIST_SUBDIR}/${SKIN}
graphics/plplot/Makefile:       @cd ${WRKSRC}/doc; ${GTAR} zxf plplotdoc-info-0.4.1.tar.gz
graphics/sketch/Makefile:       (cd ${WRKSRC}; ${GTAR} -c -f - --exclude-from=${FILESDIR}/excludelist ${dir}) | \
graphics/sketch/Makefile:           (cd ${SKETCHDIR}/; ${GTAR} xf -)
graphics/urt/Makefile:      ${GTAR} xf ${DISTDIR}/urt-doc.tar; \
graphics/urt/Makefile:      ${GTAR} xf ${DISTDIR}/urt-img.tar; \
inputmethod/canuum/Makefile:    @${GTAR} -xzf ${DISTDIR}/Canna35b2.tar.gz -C ${WRKDIR} \
lang/brandybasic/Makefile:      cd ${WRKSRC}/docs && ${GTAR} -cf - `ls |grep -v .orig` | (cd ${DOCDIR} && tar xf -)
lang/brandybasic/Makefile:      cd ${WRKSRC}/examples && ${GTAR} -cf - [a-z]* | (cd ${EXAMPLEDIR} && tar xf -)
lang/jbuilder-jit/Makefile:     @cd ${WRKDIR} && ${GTAR} -xzf ${EXTRACT_ELEMENTS}
lang/tcl-tclX/Makefile:MAKE_ENV+=               GTAR=${GTAR} CHOWN=${CHOWN} CHMOD=${CHMOD} \
lang/tk-tclX/Makefile:MAKE_ENV+=                GTAR=${GTAR} CHOWN=${CHOWN} CHMOD=${CHMOD} \
math/gap/Makefile:      ( cd ${WRKSRC} && ${GTAR} zxf ${DISTDIR}/fix4r3n1.tar.gz )
misc/dnetc/Makefile:    @cd ${WRKSRC}; ${GTAR} -zxf ${DISTDIR}/${DISTFILES}
misc/ja-man/Makefile:   @${GTAR} cCf ${PREFIX}/share/groff/tmac - tmac.andoc tmac.doc \
misc/ja-man/Makefile:       ${GTAR} xCf ${WRKSRC} -
net/dgd/Makefile:       ${GTAR} cCf ${WRKDIR}/dgd/doc - . | ${GTAR} xCf ${PREFIX}/share/doc/dgd -
net/dgd/Makefile:       ${GTAR} cCf ${WRKDIR}/dgd - mud | ${GTAR} xCf ${PREFIX}/libdata/dgd -
pkgtools/pkg_install/Makefile:#CFLAGS+= -DTAR_FULLPATHNAME='\"${GTAR}\"'
pkgtools/port2pkg/Makefile:     ${SED} -e 's|$${GTAR}|${GTAR}|g' ${FILESDIR}/port2pkg.pl \
print/cnprint/Makefile: ${GTAR} plzvxf hbf.tar.gz ; ${MV} hbf/* . ; \
print/texfamily-share/Makefile: @${GTAR} -plzx -C ${PREFIX}/share/texmf.local \
print/texfamily-share/Makefile: @${GTAR} Ccf ${WRKDIR}/morisawa/tfm/ptex - . | \
print/texfamily-share/Makefile:         ${GTAR} Cxf ${PREFIX}/share/texmf.local/fonts/tfm/ptex -
print/texfamily-share/Makefile: @${GTAR} Ccf ${WRKDIR}/${font} - tfm/dvips vf | \
print/texfamily-share/Makefile:         ${GTAR} Cxf ${PREFIX}/share/texmf.local/fonts -
print/texfamily/Makefile:       ${GTAR} -xzf ${DISTDIR}/${DIST_SUBDIR}/texfam-1.2${EXTRACT_SUFX} \
print/texfamily/Makefile:       ${GTAR} -xzf ${DISTDIR}/${DIST_SUBDIR}/web2c-j1.9${EXTRACT_SUFX} \
print/texfamily/Makefile:       ${GTAR} -xzf ${DISTDIR}/${DIST_SUBDIR}/web2c-j1.9.1${EXTRACT_SUFX} \
print/texfamily/Makefile:       ${GTAR} -xzf ${DISTDIR}/${DIST_SUBDIR}/web2c-m0.8${EXTRACT_SUFX} \
print/texfamily/Makefile:       ${GTAR} -xzf ${DISTDIR}/${DIST_SUBDIR}/web2c-m0.8.1${EXTRACT_SUFX} \
print/texfamily/Makefile:       ${GTAR} -xzf ${DISTDIR}/${DIST_SUBDIR}/ptex-src-${TEXFAMILY_PTEXVERSION}${EXTRACT_SUFX} \
print/texfamily/Makefile:       ${GTAR} -xzf ${DISTDIR}/${DIST_SUBDIR}/dvi2ps-3.2j${EXTRACT_SUFX} \
print/texfamily/Makefile:       ${GTAR} -xzf \
print/texfamily/Makefile:       ${GTAR} -xzf ${DISTDIR}/${DIST_SUBDIR}/mendexk${TEXFAMILY_MENDEXVERSION}${EXTRACT_SUFX} \
print/texfamily/Makefile:       ${GTAR} -xzf ${DISTDIR}/${DIST_SUBDIR}/jmakeindex${EXTRACT_SUFX} \
security/PAM/Makefile:          ${GZCAT} ${DISTNAME}-docs.tar.gz | ${GTAR} -xf -;       \
security/pgp2/Makefile: cd ${WRKDIR} && ${GTAR} xf pgp263ii.tar && ${RM} -f pgp263ii.tar
sysutils/cpuburn/Makefile:EXTRACT_CMD=  ${GZCAT} ${DOWNLOADED_DISTFILE} | ${GTAR} -xf -
sysutils/lsof/Makefile:         ${GTAR} -xf ${SRCBALL_NAME}.tar; \
textproc/eb/Makefile:           ${GTAR} -C ${EB_APPENDIXDIR} -zxmf ${_DISTDIR}/$${f}; \
textproc/html/Makefile: ${GTAR} -plzx -C ${INSTDIR} -f ${DISTDIR}/${DISTNAME}${EXTRACT_SUFX}
time/cardboard-schedule/Makefile:               @(cd ${WRKDIR}/C:/projects && ${GTAR} cf - ${CSFILES} | (cd ${PREFIX}/lib/cardboard-schedule && ${GTAR} xvf -))
wm/ethemes/Makefile:    ${GTAR} -C ${PREFIX}/${E_DATADIR}/$$NAME \
wm/fvwm2/Makefile:      ${GTAR} -xzf ${DISTDIR}/fvwm_icons.tgz -C ${WRKDIR}/icons
www/jsdk20/Makefile:    cd ${WRKSRC}/doc ; ${GTAR} pcf - . | ( cd ${PREFIX}/share/doc/java/jsdk20 ; ${GTAR} pvxf - )
www/jsdk20/Makefile:    cd ${WRKSRC}/examples ; ${GTAR} pcf - . | ( cd ${PREFIX}/share/examples/java/jsdk20 ; ${GTAR} pvxf - )
www/wwwoffle/Makefile:PLIST_SUBST+=     GTAR="${GTAR}" PKG_SYSCONFDIR="${PKG_SYSCONFDIR}"
www/wwwoffle/Makefile:  ${GTAR} czCf / ${PREFIX}/libdata/wwwoffle-spool.tar.gz \
x11/xservers/Makefile:  ${GTAR} --exclude '*/CVS' -c -C ${BSDXSRCDIR}/xc -f - ${X11_SRCS} | \
x11/xservers/Makefile:  ${GTAR} xCf ${WRKSRC} -


-- 
								Greg A. Woods

+1 416 218-0098;            <g.a.woods@ieee.org>;           <woods@robohack.ca>
Planix, Inc. <woods@planix.com>; VE3TCP; Secrets of the Weird <woods@weird.com>