[PC-BSD Commits] r15980 - pcbsd/current/src-sh/pc-metapkgmanager

svn at pcbsd.org svn at pcbsd.org
Fri Mar 23 17:04:35 PDT 2012


Author: kris
Date: 2012-03-24 00:04:35 +0000 (Sat, 24 Mar 2012)
New Revision: 15980

Modified:
   pcbsd/current/src-sh/pc-metapkgmanager/pc-metapkgmanager
Log:

When doing a meta pkg status, ignore the port version number. We just
want to be sure (a) copy is installed. This means the meta-pkg will
still show as installed, even if the user manually updates / downgrades
the port. 



Modified: pcbsd/current/src-sh/pc-metapkgmanager/pc-metapkgmanager
===================================================================
--- pcbsd/current/src-sh/pc-metapkgmanager/pc-metapkgmanager	2012-03-23 23:53:02 UTC (rev 15979)
+++ pcbsd/current/src-sh/pc-metapkgmanager/pc-metapkgmanager	2012-03-24 00:04:35 UTC (rev 15980)
@@ -328,7 +328,12 @@
 	# Now query pkg_info to confirm each pkg is installed
 	while read pkg
 	do
-		if [ -e "${_chroot}/var/db/pkg/${pkg}" ] ; then
+		# See if the pkg is installed, without worrying about
+		# version numbers. This means a meta-pkg shows as
+		# installed even if the user manually updated
+    		pName=`echo $pkg | rev | cut -d "-" -f 2-25 | rev`
+		ls -d ${_chroot}/var/db/pkg/${pName}-* >/dev/null 2>/dev/null
+		if [ $? -eq 0 ] ; then
 			found=0
 		else
 			nfound=1



More information about the Commits mailing list