svn commit: r305945 - in head/ports-mgmt/portmaster: . files

Bryan Drewery bdrewery at FreeBSD.org
Tue Oct 16 03:00:01 UTC 2012


Author: bdrewery
Date: Tue Oct 16 03:00:00 2012
New Revision: 305945
URL: http://svn.freebsd.org/changeset/ports/305945

Log:
  - Update ZSH completions with pkgng support [1]
  - Enable the PKGNG patch by default if WITH_PKGNG
    is defined.
  
  Submitted by:	ume [1]
  Feature safe:	yes

Added:
  head/ports-mgmt/portmaster/files/
  head/ports-mgmt/portmaster/files/extra-patch-files::zsh-completions   (contents, props changed)
Modified:
  head/ports-mgmt/portmaster/Makefile

Modified: head/ports-mgmt/portmaster/Makefile
==============================================================================
--- head/ports-mgmt/portmaster/Makefile	Tue Oct 16 02:13:00 2012	(r305944)
+++ head/ports-mgmt/portmaster/Makefile	Tue Oct 16 03:00:00 2012	(r305945)
@@ -2,7 +2,7 @@
 
 PORTNAME=	portmaster
 PORTVERSION=	3.14
-PORTREVISION=	3
+PORTREVISION=	4
 CATEGORIES=	ports-mgmt
 MASTER_SITES=	GH \
   		http://mirror.shatow.net/freebsd/portmaster/
@@ -19,6 +19,9 @@ GH_COMMIT=	31009f6
 GH_TAGNAME=	${GH_COMMIT}
 
 OPTIONS_DEFINE=	BASH ZSH PKGNGPATCH
+.if defined(WITH_PKGNG)
+OPTIONS_DEFAULT+=	PKGNGPATCH
+.endif
 BASH_DESC=	Install programmable completions for Bash
 ZSH_DESC=	Install programmable completions for zsh
 PKGNGPATCH_DESC=Enable PKGNG support
@@ -33,6 +36,9 @@ MAN8=		portmaster.8
 RUN_DEPENDS+=	pkg>0:${PORTSDIR}/ports-mgmt/pkg
 PATCH_SITES+=	http://mirror.shatow.net/freebsd/portmaster/
 PATCHFILES+=	patch-portmaster-pkgng.gz
+.  if ${PORT_OPTIONS:MZSH}
+EXTRA_PATCHES+=	${FILESDIR}/extra-patch-files::zsh-completions
+.  endif
 .endif
 
 .if ${PORT_OPTIONS:MBASH}

Added: head/ports-mgmt/portmaster/files/extra-patch-files::zsh-completions
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/ports-mgmt/portmaster/files/extra-patch-files::zsh-completions	Tue Oct 16 03:00:00 2012	(r305945)
@@ -0,0 +1,30 @@
+Index: files/zsh-completions
+diff -u files/zsh-completions.orig files/zsh-completions
+--- files/zsh-completions.orig	2012-10-10 21:46:28.000000000 +0900
++++ files/zsh-completions	2012-10-16 01:37:31.000000000 +0900
+@@ -61,7 +61,11 @@
+ 
+ case "$state" in
+   pkgs)
+-    array=("${PKG_DBDIR:-/var/db/pkg}"/*(/:t))
++    if [ -n "$(make -V WITH_PKGNG)" ]; then
++      array=($(pkg info -aq))
++    else
++      array=("${PKG_DBDIR:-/var/db/pkg}"/*(/:t))
++    fi
+     _describe -t packages "installed ports" array
+     ;;
+   ports)
+@@ -71,7 +75,11 @@
+     _tags packages ports
+     while _tags; do
+       if _requested packages; then
+-        array=("${PKG_DBDIR:-/var/db/pkg}"/*(/:t))
++        if [ -n "$(make -V WITH_PKGNG)" ]; then
++          array=($(pkg info -aq))
++        else
++          array=("${PKG_DBDIR:-/var/db/pkg}"/*(/:t))
++        fi
+         _describe -t packages "installed ports" array && ret=0
+       fi
+       if _requested ports; then


More information about the svn-ports-all mailing list