Gentoo Logo
Gentoo Spaceship




Note: Due to technical difficulties, the Archives are currently not up to date. GMANE provides an alternative service for most mailing lists.
c.f. bug 424647
List Archive: gentoo-commits
Navigation:
Lists: gentoo-commits: < Prev By Thread Next > < Prev By Date Next >
Headers:
To: gentoo-commits@g.o
From: "Paul Varner (fuzzyray)" <fuzzyray@g.o>
Subject: gentoolkit r537 - in trunk: . src/gentoolkit
Date: Fri, 09 Jan 2009 04:20:49 +0000
Author: fuzzyray
Date: 2009-01-09 04:20:48 +0000 (Fri, 09 Jan 2009)
New Revision: 537

Modified:
   trunk/ChangeLog
   trunk/src/gentoolkit/package.py
Log:
Fix package.py to account for PORTDIR being a symbolic link when checking if a package is in an overlay. (Bug #253968)

Modified: trunk/ChangeLog
===================================================================
--- trunk/ChangeLog	2009-01-07 10:46:21 UTC (rev 536)
+++ trunk/ChangeLog	2009-01-09 04:20:48 UTC (rev 537)
@@ -1,3 +1,7 @@
+2009-01-08: Paul Varner <fuzzyray@g.o>
+	* equery: Fix package.py to account for PORTDIR being a symbolic link
+	when checking if a package is in an overlay. (Bug #253968)
+
 2008-11-25: Paul Varner <fuzzyray@g.o>
 	* revdep-rebuild: Fixes for non-linux Gentoo systems. Add patch from
 	igli to fix find command to comply with POSIX. Change awk calls to

Modified: trunk/src/gentoolkit/package.py
===================================================================
--- trunk/src/gentoolkit/package.py	2009-01-07 10:46:21 UTC (rev 536)
+++ trunk/src/gentoolkit/package.py	2009-01-09 04:20:48 UTC (rev 537)
@@ -7,6 +7,7 @@
 #
 # $Header$
 
+import os
 from errors import FatalError
 import portage
 from gentoolkit import *
@@ -25,6 +26,9 @@
 		self._db = None
 		self._settings = settings
 		self._settingslock = settingslock
+		self._portdir_path = settings["PORTDIR"]
+		if os.path.islink(self._portdir_path):
+			self._portdir_path = os.path.join(os.path.dirname(self._portdir_path), os.readlink(self._portdir_path))
 
 	def get_name(self):
 		"""Returns base name of package, no category nor version"""
@@ -151,7 +155,7 @@
 	def is_overlay(self):
 		"""Returns true if the package is in an overlay."""
 		dir,ovl = portage.portdb.findname2(self._cpv)
-		return ovl != settings["PORTDIR"]
+		return ovl != self._portdir_path
 
 	def is_masked(self):
 		"""Returns true if this package is masked against installation. Note: We blindly assume that



Navigation:
Lists: gentoo-commits: < Prev By Thread Next > < Prev By Date Next >
Previous by thread:
gentoo-x86 commit in net-misc/openssh: openssh-5.1_p1-r3.ebuild ChangeLog
Next by thread:
gentoo-x86 commit in app-emulation/libvirt: libvirt-0.4.6-r1.ebuild libvirt-0.5.1.ebuild ChangeLog metadata.xml libvirt-0.4.6.ebuild libvirt-0.4.4-r2.ebuild
Previous by date:
gentoo-x86 commit in profiles: ChangeLog package.mask
Next by date:
gentoo-x86 commit in profiles: ChangeLog use.local.desc


Updated May 17, 2012

Summary: Archive of the gentoo-commits mailing list.

Donate to support our development efforts.

Copyright 2001-2013 Gentoo Foundation, Inc. Questions, Comments? Contact us.