pkgsrc-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

pkg/42967: pkgsrc does not support 7z archive file (archivers/p7zip)



>Number:         42967
>Category:       pkg
>Synopsis:       pkgsrc does not support 7z archive file (archivers/p7zip)
>Confidential:   no
>Severity:       critical
>Priority:       high
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Sat Mar 13 20:40:00 +0000 2010
>Originator:     Ryo ONODERA
>Release:        NetBSD 5.99.24
>Organization:
        
>Environment:
        
        
System: NetBSD hydrogen.elements.tetera.org 5.99.24 NetBSD 5.99.24 
(BRIGHTGIRL7) #5: Sat Mar 13 20:03:36 JST 2010 
root%hydrogen.elements.tetera.org@localhost:/usr/obj/sys/arch/i386/compile/BRIGHTGIRL7
 i386
Architecture: i386
Machine: i386
>Description:
New fonts/umefont-ttf (0.413) is released and only distributed in 7z archive 
format now.
Please support 7z archive.

I want to update fonts/umefont-ttf to 0.413.


>How-To-Repeat:

>Fix:
I think that following patches enable 7z support.
Please review and commit it.

--- mk/extract/bsd.extract-vars.mk.orig 2010-03-14 02:55:39.000000000 +0900
+++ mk/extract/bsd.extract-vars.mk      2010-03-14 05:18:21.000000000 +0900
@@ -83,3 +83,6 @@
 .if !empty(EXTRACT_ONLY:M*.gem)
 USE_TOOLS+=    gem
 .endif
+.if !empty(EXTRACT_ONLY:M*.7z)
+USE_TOOLS+=    7za
+.endif
--- mk/extract/extract.orig     2010-03-14 03:03:31.000000000 +0900
+++ mk/extract/extract  2010-03-14 05:19:18.000000000 +0900
@@ -118,6 +118,7 @@
 : ${UNRAR:=unrar}
 : ${UNZIP_CMD:=unzip}
 : ${UNZOO:=unzoo}
+: ${P7ZA:="7za x"}
 
 : ${TMPDIR:=/tmp}
 
@@ -217,6 +218,7 @@
 *.rpm)         _format=rpm ;;
 *.bin)         _format=jre-bin ;;
 *.gem)         _format=gem ;;
+*.7z)          _format=7z ;;
 *)             _format=none ;;
 esac
 ${TEST} -n "$format" || format="$_format"
@@ -340,6 +342,10 @@
        ${GEM} "$distfile"
        ;;
 
+7z)
+       ${P7ZA} "$distfile"
+       ;;
+
 none)
        # By default, copy the distfile over to the current working directory.
        ${CP} "$distfile" .
--- mk/extract/extract.mk.orig  2010-03-14 03:07:57.000000000 +0900
+++ mk/extract/extract.mk       2010-03-14 05:18:57.000000000 +0900
@@ -177,6 +177,7 @@
 _EXTRACT_ENV+= ${TOOLS_UNZIP_CMD:D     UNZIP_CMD=${TOOLS_UNZIP_CMD:Q}}
 _EXTRACT_ENV+= ${TOOLS_UNZOO:D         UNZOO=${TOOLS_UNZOO:Q}}
 _EXTRACT_ENV+= ${TOOLS_XZCAT:D         XZCAT=${TOOLS_XZCAT:Q}}
+_EXTRACT_ENV+= ${TOOLS_7ZA:D           P7ZA=${TOOLS_7ZA:Q}}
 _EXTRACT_ENV+= ${EXTRACT_ENV}
 
 .if !empty(EXTRACT_USING:Mbsdtar)
--- mk/tools/replace.mk.orig    2010-03-14 04:22:12.000000000 +0900
+++ mk/tools/replace.mk 2010-03-14 05:21:06.000000000 +0900
@@ -205,6 +205,17 @@
 # command, e.g., TOOLS_TBL, TOOLS_YACC, etc., provided that "TOOL" has
 # been associated with <tool>.
 #
+.if !defined(TOOLS_IGNORE.7za) && !empty(_USE_TOOLS:M7za)
+.  if !empty(PKGPATH:Marchivers/p7zip)
+MAKEFLAGS+=                    TOOLS_IGNORE.7za=
+.  elif !empty(_TOOLS_USE_PKGSRC.7za:M[yY][eE][sS])
+TOOLS_DEPENDS.7za?=            p7zip>=9.04:../../archivers/p7zip
+TOOLS_CREATE+=                 7za
+TOOLS_FIND_PREFIX+=            TOOLS_PREFIX.7za=7za
+TOOLS_PATH.7za=                        ${TOOLS_PREFIX.7za}/bin/7za
+.  endif
+.endif
+
 .if !defined(TOOLS_IGNORE.awk) && !empty(_USE_TOOLS:Mawk)
 .  if !empty(PKGPATH:Mlang/nawk)
 MAKEFLAGS+=                    TOOLS_IGNORE.awk=
--- mk/tools/defaults.mk.orig   2010-03-14 04:31:29.000000000 +0900
+++ mk/tools/defaults.mk        2010-03-14 05:18:07.000000000 +0900
@@ -113,6 +113,7 @@
 _TOOLS_VARNAME.nice=           NICE
 _TOOLS_VARNAME.nroff=          NROFF
 _TOOLS_VARNAME.openssl=                OPENSSL
+_TOOLS_VARNAME.7za=            P7ZA
 _TOOLS_VARNAME.patch=          PATCH
 _TOOLS_VARNAME.pax=            PAX
 _TOOLS_VARNAME.perl=           PERL5


>Unformatted:
        
        


Home | Main Index | Thread Index | Old Index