Index: pym/portage/dbapi/vartree.py =================================================================== --- pym/portage/dbapi/vartree.py (revision 14747) +++ pym/portage/dbapi/vartree.py (working copy) @@ -1819,13 +1819,14 @@ This is called before an after any modifications, so that consumers can use directory mtimes to validate caches. See bug #290428. """ - base = self.root + _os.sep + VDB_PATH + base = os.path.join(self.root, VDB_PATH) cat = catsplit(cpv)[0] - catdir = base + _os.sep + cat + catdir = os.path.join(base, cat) t = time.time() t = (t, t) for x in (catdir, base): - os.utime(x, t) + if os.path.lexists(x): + os.utime(x, t) def cpv_exists(self, mykey): "Tells us whether an actual ebuild exists on disk (no masking)"