Gentoo Archives: gentoo-commits

From: Fabian Groffen <grobian@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/portage:prefix commit in: /
Date: Fri, 02 Dec 2011 18:04:05
Message-Id: f5b5a26b7d729a93b784de29e438ad76b3e7c433.grobian@gentoo
1 commit: f5b5a26b7d729a93b784de29e438ad76b3e7c433
2 Author: Fabian Groffen <grobian <AT> gentoo <DOT> org>
3 AuthorDate: Fri Dec 2 18:02:26 2011 +0000
4 Commit: Fabian Groffen <grobian <AT> gentoo <DOT> org>
5 CommitDate: Fri Dec 2 18:02:26 2011 +0000
6 URL: http://git.overlays.gentoo.org/gitweb/?p=proj/portage.git;a=commit;h=f5b5a26b
7
8 Merge commit 'v2.2.0_alpha72' into prefix
9
10 Conflicts:
11 bin/lock-helper.py
12 bin/xpak-helper.py
13 pym/_emerge/actions.py
14 pym/portage/__init__.py
15
16
17 bin/ebuild | 4 +-
18 bin/egencache | 87 ++++--
19 bin/emaint | 22 +-
20 bin/glsa-check | 5 +-
21 bin/lock-helper.py | 4 +-
22 bin/portageq | 81 +++--
23 bin/quickpkg | 24 +-
24 bin/regenworld | 5 +-
25 bin/repoman | 11 +-
26 bin/xpak-helper.py | 4 +-
27 man/emerge.1 | 4 +
28 man/make.conf.5 | 9 +-
29 man/portage.5 | 12 +-
30 man/repoman.1 | 5 +-
31 pym/_emerge/BlockerDB.py | 5 +-
32 pym/_emerge/EbuildFetchonly.py | 4 +-
33 pym/_emerge/EbuildMetadataPhase.py | 6 +-
34 pym/_emerge/FakeVartree.py | 11 +-
35 pym/_emerge/Package.py | 8 +-
36 pym/_emerge/RootConfig.py | 2 +-
37 pym/_emerge/Scheduler.py | 17 +-
38 pym/_emerge/actions.py | 304 +++++++----------
39 pym/_emerge/depgraph.py | 33 +-
40 pym/_emerge/main.py | 49 ++-
41 pym/_emerge/unmerge.py | 4 +-
42 pym/portage/__init__.py | 42 ++-
43 pym/portage/_global_updates.py | 2 +-
44 pym/portage/_legacy_globals.py | 12 +-
45 pym/portage/_sets/__init__.py | 38 ++-
46 pym/portage/cache/metadata.py | 1 -
47 pym/portage/cache/template.py | 5 +
48 pym/portage/checksum.py | 41 ++-
49 pym/portage/dbapi/_expand_new_virt.py | 3 +-
50 pym/portage/dbapi/bintree.py | 35 ++-
51 pym/portage/dbapi/porttree.py | 43 ++-
52 pym/portage/dbapi/vartree.py | 110 +++++--
53 pym/portage/dep/dep_check.py | 8 +-
54 pym/portage/elog/mod_syslog.py | 2 +-
55 pym/portage/news.py | 74 ++++-
56 .../package/ebuild/_config/KeywordsManager.py | 6 +-
57 .../package/ebuild/_config/LocationsManager.py | 83 ++++-
58 pym/portage/package/ebuild/_config/MaskManager.py | 37 ++-
59 pym/portage/package/ebuild/_config/UseManager.py | 18 +-
60 pym/portage/package/ebuild/config.py | 96 +++---
61 pym/portage/package/ebuild/digestcheck.py | 2 +-
62 pym/portage/package/ebuild/doebuild.py | 25 +-
63 pym/portage/repository/config.py | 358 +++++++++++++-------
64 pym/portage/tests/ebuild/test_config.py | 8 +-
65 pym/portage/tests/ebuild/test_doebuild_spawn.py | 2 +-
66 pym/portage/tests/emerge/test_global_updates.py | 39 +++
67 pym/portage/tests/emerge/test_simple.py | 39 ++-
68 pym/portage/tests/repoman/test_simple.py | 2 +-
69 pym/portage/tests/resolver/ResolverPlayground.py | 27 +-
70 pym/portage/update.py | 5 +
71 pym/portage/util/__init__.py | 11 +-
72 pym/portage/util/env_update.py | 13 +-
73 pym/repoman/utilities.py | 4 +
74 runtests.sh | 20 ++
75 58 files changed, 1253 insertions(+), 678 deletions(-)
76
77 diff --cc bin/lock-helper.py
78 index 886b52d,065ddcb..23db096
79 --- a/bin/lock-helper.py
80 +++ b/bin/lock-helper.py
81 @@@ -1,5 -1,5 +1,5 @@@
82 -#!/usr/bin/python
83 +#!@PREFIX_PORTAGE_PYTHON@
84 - # Copyright 2010 Gentoo Foundation
85 + # Copyright 2010-2011 Gentoo Foundation
86 # Distributed under the terms of the GNU General Public License v2
87
88 import os
89 diff --cc bin/xpak-helper.py
90 index 4d096cc,ef74920..1d57069
91 --- a/bin/xpak-helper.py
92 +++ b/bin/xpak-helper.py
93 @@@ -1,5 -1,5 +1,5 @@@
94 -#!/usr/bin/python
95 +#!@PREFIX_PORTAGE_PYTHON@
96 - # Copyright 2009 Gentoo Foundation
97 + # Copyright 2009-2011 Gentoo Foundation
98 # Distributed under the terms of the GNU General Public License v2
99
100 import optparse
101 diff --cc pym/_emerge/actions.py
102 index 46d68b8,af3780e..7e032d1
103 --- a/pym/_emerge/actions.py
104 +++ b/pym/_emerge/actions.py
105 @@@ -25,7 -30,7 +30,7 @@@ from portage import o
106 from portage import subprocess_getstatusoutput
107 from portage import _unicode_decode
108 from portage.cache.cache_errors import CacheError
109 - from portage.const import GLOBAL_CONFIG_PATH, NEWS_LIB_PATH, EPREFIX
110 -from portage.const import GLOBAL_CONFIG_PATH
111 ++from portage.const import GLOBAL_CONFIG_PATH, EPREFIX
112 from portage.const import _ENABLE_DYN_LINK_MAP, _ENABLE_SET_CONFIG
113 from portage.dbapi.dep_expand import dep_expand
114 from portage.dbapi._expand_new_virt import expand_new_virt
115 diff --cc pym/portage/__init__.py
116 index 3de273f,27353a1..c5b7f76
117 --- a/pym/portage/__init__.py
118 +++ b/pym/portage/__init__.py
119 @@@ -491,15 -495,25 +496,27 @@@ def create_trees(config_root=None, targ
120 portdbapi.portdbapi_instances.remove(portdb)
121 del trees[myroot]["porttree"], myroot, portdb
122
123 - eprefix = os.environ.get("__PORTAGE_TEST_EPREFIX")
124 + if trees is None:
125 + trees = _trees_dict()
126 + elif not isinstance(trees, _trees_dict):
127 + # caller passed a normal dict or something,
128 + # but we need a _trees_dict instance
129 + trees = _trees_dict(trees)
130 +
131 + if env is None:
132 + env = os.environ
133 + eprefix = env.get("__PORTAGE_TEST_EPREFIX")
134 + if not eprefix:
135 + eprefix = EPREFIX
136 settings = config(config_root=config_root, target_root=target_root,
137 - config_incrementals=portage.const.INCREMENTALS, _eprefix=eprefix)
138 + env=env, _eprefix=eprefix)
139 settings.lock()
140
141 - myroots = [(settings["ROOT"], settings)]
142 - if settings["ROOT"] != "/":
143 + trees._target_eroot = settings['EROOT']
144 + myroots = [(settings['EROOT'], settings)]
145 + if settings["ROOT"] == "/":
146 + trees._running_eroot = trees._target_eroot
147 + else:
148
149 # When ROOT != "/" we only want overrides from the calling
150 # environment to apply to the config that's associated
151 diff --cc pym/portage/dbapi/vartree.py
152 index f333494,73772b0..d189775
153 --- a/pym/portage/dbapi/vartree.py
154 +++ b/pym/portage/dbapi/vartree.py
155 @@@ -29,11 -29,9 +29,12 @@@ portage.proxy.lazyimport.lazyimport(glo
156 'portage.util.listdir:dircache,listdir',
157 'portage.util._dyn_libs.PreservedLibsRegistry:PreservedLibsRegistry',
158 'portage.util._dyn_libs.LinkageMapELF:LinkageMapELF@LinkageMap',
159 + 'portage.util._dyn_libs.LinkageMapMachO:LinkageMapMachO',
160 + 'portage.util._dyn_libs.LinkageMapPeCoff:LinkageMapPeCoff',
161 + 'portage.util._dyn_libs.LinkageMapXCoff:LinkageMapXCoff',
162 'portage.versions:best,catpkgsplit,catsplit,cpv_getkey,pkgcmp,' + \
163 '_pkgsplit@pkgsplit',
164 + 'tarfile',
165 )
166
167 from portage.const import CACHE_PATH, CONFIG_MEMORY_FILE, \
168 diff --cc pym/portage/package/ebuild/_config/MaskManager.py
169 index 89c06fd,bce1152..7d44e79
170 --- a/pym/portage/package/ebuild/_config/MaskManager.py
171 +++ b/pym/portage/package/ebuild/_config/MaskManager.py
172 @@@ -102,22 -116,16 +116,27 @@@ class MaskManager(object)
173 #to allow profiles to override masks from their parent profiles.
174 profile_pkgmasklines = []
175 profile_pkgunmasklines = []
176 - for x in profiles:
177 + # PREFIX LOCAL: Prefix has unmasks for stuff in profiles/package.mask
178 + # If we don't consider the repomasks here, those unmasks are
179 + # lost, causing lots of issues (e.g. Portage being masked)
180 + # for minimal/concentrated code change, empty repo_pkgmasklines here
181 + # such that they don't count double
182 + repo_pkgmasklines = []
183 + repo_pkgunmasklines = []
184 + all_profiles = []
185 + for repo in repositories.repos_with_profiles():
186 + all_profiles.append(os.path.join(repo.location, "profiles"))
187 + all_profiles.extend(profiles)
188 + for x in all_profiles:
189 profile_pkgmasklines.append(grabfile_package(
190 - os.path.join(x, "package.mask"), recursive=1, remember_source_file=True, verify_eapi=True))
191 - profile_pkgunmasklines.append(grabfile_package(
192 - os.path.join(x, "package.unmask"), recursive=1, remember_source_file=True, verify_eapi=True))
193 + os.path.join(x.location, "package.mask"),
194 + recursive=x.portage1_directories,
195 + remember_source_file=True, verify_eapi=True))
196 + if x.portage1_directories:
197 + profile_pkgunmasklines.append(grabfile_package(
198 + os.path.join(x.location, "package.unmask"),
199 + recursive=x.portage1_directories,
200 + remember_source_file=True, verify_eapi=True))
201 profile_pkgmasklines = stack_lists(profile_pkgmasklines, incremental=1, \
202 remember_source_file=True, warn_for_unmatched_removal=True,
203 strict_warn_for_unmatched_removal=strict_umatched_removal)
204 diff --cc runtests.sh
205 index b8be75c,b7313b7..d2299f6
206 --- a/runtests.sh
207 +++ b/runtests.sh
208 @@@ -27,11 -27,31 +27,31 @@@ interrupted()
209
210 trap interrupted SIGINT
211
212 + unused_args=()
213 +
214 + while [[ -n $1 ]] ; do
215 + case "$1" in
216 + --python-versions=*)
217 + PYTHON_VERSIONS=${1#--python-versions=}
218 + ;;
219 + --python-versions)
220 + shift
221 + PYTHON_VERSIONS=$1
222 + ;;
223 + *)
224 + unused_args[${#unused_args[@]}]=$1
225 + ;;
226 + esac
227 + shift
228 + done
229 +
230 + set -- "${unused_args[@]}"
231 +
232 exit_status="0"
233 for version in ${PYTHON_VERSIONS}; do
234 - if [[ -x /usr/bin/python${version} ]]; then
235 + if [[ -x @PREFIX_PORTAGE_PYTHON@${version} ]]; then
236 echo -e "${GOOD}Testing with Python ${version}...${NORMAL}"
237 - if ! /usr/bin/python${version} -Wd pym/portage/tests/runTests "$@" ; then
238 + if ! @PREFIX_PORTAGE_PYTHON@${version} -Wd pym/portage/tests/runTests "$@" ; then
239 echo -e "${BAD}Testing with Python ${version} failed${NORMAL}"
240 exit_status="1"
241 fi