diff options
author | Zac Medico <zmedico@gentoo.org> | 2015-02-17 14:56:47 -0800 |
---|---|---|
committer | Zac Medico <zmedico@gentoo.org> | 2015-03-04 13:32:07 -0800 |
commit | 34055adae6bd90fc64f18421e2cec5f8da6f7c33 (patch) | |
tree | b7f20aee368696ff77d064d794f03cbb230982be /pym/portage/dbapi/vartree.py | |
parent | setup.py: Set version for new release (diff) | |
download | portage-34055adae6bd90fc64f18421e2cec5f8da6f7c33.tar.gz portage-34055adae6bd90fc64f18421e2cec5f8da6f7c33.tar.bz2 portage-34055adae6bd90fc64f18421e2cec5f8da6f7c33.zip |
binpkg-multi-instance 1 of 7
Extend the _pkg_str class with build_id, build_time, file_size, and
mtime attributes. These will be used to distinguish binary package
instances that have the same cpv. Package sorting accounts for
build_time, which will be used to prefer newer builds over older builds
when their versions are identical.
Diffstat (limited to 'pym/portage/dbapi/vartree.py')
-rw-r--r-- | pym/portage/dbapi/vartree.py | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/pym/portage/dbapi/vartree.py b/pym/portage/dbapi/vartree.py index cf31c8e9c..277c2f188 100644 --- a/pym/portage/dbapi/vartree.py +++ b/pym/portage/dbapi/vartree.py @@ -173,7 +173,8 @@ class vardbapi(dbapi): self.vartree = vartree self._aux_cache_keys = set( ["BUILD_TIME", "CHOST", "COUNTER", "DEPEND", "DESCRIPTION", - "EAPI", "HDEPEND", "HOMEPAGE", "IUSE", "KEYWORDS", + "EAPI", "HDEPEND", "HOMEPAGE", + "BUILD_ID", "IUSE", "KEYWORDS", "LICENSE", "PDEPEND", "PROPERTIES", "PROVIDE", "RDEPEND", "repository", "RESTRICT" , "SLOT", "USE", "DEFINED_PHASES", "PROVIDES", "REQUIRES" @@ -425,7 +426,10 @@ class vardbapi(dbapi): continue if len(mysplit) > 1: if ps[0] == mysplit[1]: - returnme.append(_pkg_str(mysplit[0]+"/"+x)) + cpv = "%s/%s" % (mysplit[0], x) + metadata = dict(zip(self._aux_cache_keys, + self.aux_get(cpv, self._aux_cache_keys))) + returnme.append(_pkg_str(cpv, metadata=metadata)) self._cpv_sort_ascending(returnme) if use_cache: self.cpcache[mycp] = [mystat, returnme[:]] |