Usually most module files are compressed into .zip files. So, utilize libarchive(3) ability to read zip archives through tar(1) for this popular format. Because tar(1) is in base no more need to keep archivers/unzip just for audio/xmp sake. Fix: Patch attached with submission follows: How-To-Repeat: 1. assure your tar(1) is able to extract zip archives into stdout 2. install audio/xmp with WITHOUT_UNZIP defined 3. delete archivers/unzip package 4. try to play any zip-compressed module file
Responsible Changed From-To: freebsd-ports-bugs->anders Over to maintainer (via the GNATS Auto Assign Tool)
Here is an updated one for xmp-2.7.1 --- xmp-no-unzip-2.7.1.diff begins here --- Index: audio/xmp/Makefile =================================================================== RCS file: /home/csup/ports/audio/xmp/Makefile,v retrieving revision 1.38 diff -u -p -r1.38 Makefile --- audio/xmp/Makefile 18 May 2008 12:16:40 -0000 1.38 +++ audio/xmp/Makefile 26 Jul 2009 08:07:30 -0000 @@ -26,7 +26,8 @@ MAN1= xmp.1 MLINKS= xmp.1 xxmp.1 OPTIONS= XMMS "Build XMMS plugin" off \ - ESOUND "EsounD support" off + ESOUND "EsounD support" off \ + UNZIP "Use unzip(1) for .zip-compressed files" on CFLAGS+= -fPIC @@ -45,6 +46,13 @@ CONFIGURE_ARGS+= --enable-xmms-plugin CONFIGURE_ARGS+= --disable-xmms .endif +# use unzip(1) or fall back to libarchive(3) reader +.if defined(WITH_UNZIP) +RUN_DEPENDS+= ${LOCALBASE}/bin/unzip:${PORTSDIR}/archivers/unzip +.else +EXTRA_PATCHES+= ${PATCHDIR}/extra-patch-src-misc-load.c +.endif + post-patch: .for f in docs/xmp.1 etc/xmp.conf etc/xmp-modules.conf @${REINPLACE_CMD} -e "s|/etc/xmp|${PREFIX}/etc/xmp|g" ${WRKSRC}/${f} Index: audio/xmp/files/extra-patch-src-misc-load.c =================================================================== RCS file: audio/xmp/files/extra-patch-src-misc-load.c diff -N audio/xmp/files/extra-patch-src-misc-load.c --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ audio/xmp/files/extra-patch-src-misc-load.c 26 Jul 2009 08:06:18 -0000 @@ -0,0 +1,16 @@ +--- src/misc/load.c~ ++++ src/misc/load.c +@@ -99,8 +99,11 @@ static int decrunch(struct xmp_context * + cmd = "unzip -pqqC \"%s\" -x readme *.diz *.nfo *.txt *.exe *.com " + "README *.DIZ *.NFO *.TXT *.EXE *.COM " REDIR_STDERR; + #else +- cmd = "unzip -pqqC \"%s\" -x readme '*.diz' '*.nfo' '*.txt' '*.exe' " +- "'*.com' README '*.DIZ' '*.NFO' '*.TXT' '*.EXE' '*.COM' " ++ cmd = "tar xOf \"%s\" --exclude readme --exclude '*.diz' " ++ "--exclude '*.nfo' --exclude '*.txt' --exclude '*.exe' " ++ "--exclude '*.com' --exclude README --exclude '*.DIZ' " ++ "--exclude '*.NFO' --exclude '*.TXT' --exclude '*.EXE' " ++ "--exclude '*.COM' " + REDIR_STDERR; + #endif + } else if (b[2] == '-' && b[3] == 'l' && b[4] == 'h') { --- xmp-no-unzip-2.7.1.diff ends here ---
Hi, Did you try to talk to the xmp developers about this change? It would be better to get the configure scripts to discover this feature in FreeBSD I think. But in any case the change does look OK. Are you ok to take over maintainership over xmp? You seem to have more interest in this port than me, I just reset MAINTAINERSHIP in Makefile. I'll help you get through the two PRs that have been assigned to me though. Bye, -- Anders.
Responsible Changed From-To: anders->ehaupt over to new maintainer.
State Changed From-To: open->closed Port was updated a while ago, as far as I can tell some of your additions are now available in the current version, thanks.
ehaupt@FreeBSD.org writes: > Synopsis: [patch] audio/xmp: add option to use tar(1) instead of unzip(1) to play zip-compressed module files > > State-Changed-From-To: open->closed > State-Changed-By: ehaupt > State-Changed-When: Fri Oct 16 12:46:11 CEST 2009 > State-Changed-Why: > Port was updated a while ago, as far as I can tell some of your > additions are now available in the current version, thanks. I've seen your commit and updated my snapshot[1]. I believe -fPIC can be removed entirely because distfile already has it. It doesn't break build/run if I remove it on amd64 from port's Makefile. However, this PR is about unzip(1) but update to 2.7.1 and -fPIC was part of ports/137148. [1] ftp://ftp.lissyara.su/users/Guest/xmp.diff > > http://www.freebsd.org/cgi/query-pr.cgi?pr=132435
State Changed From-To: closed->open Reopen, new patches have been submitted.
ehaupt 2009-10-17 09:11:17 UTC FreeBSD ports repository Modified files: audio/xmp Makefile distinfo pkg-plist Added files: audio/xmp/files extra-patch-src-misc-load.c Removed files: audio/xmp/files patch-src-drivers-oss_seq.c Log: Update to 3.0.0.20090929 PR: 132435 Submitted by: swell.k@gmail.com Revision Changes Path 1.43 +91 -12 ports/audio/xmp/Makefile 1.11 +3 -3 ports/audio/xmp/distinfo 1.1 +16 -0 ports/audio/xmp/files/extra-patch-src-misc-load.c (new) 1.3 +0 -26 ports/audio/xmp/files/patch-src-drivers-oss_seq.c (dead) 1.6 +9 -3 ports/audio/xmp/pkg-plist _______________________________________________ cvs-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/cvs-all To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
State Changed From-To: open->closed Committed, thanks for the great work.