1 |
commit: 1d2e1ee6ec7fd3d9a1e2713a19ef8a4f4db6ecf0 |
2 |
Author: Zac Medico <zmedico <AT> gentoo <DOT> org> |
3 |
AuthorDate: Thu Aug 16 17:11:29 2018 +0000 |
4 |
Commit: Zac Medico <zmedico <AT> gentoo <DOT> org> |
5 |
CommitDate: Thu Aug 16 17:11:29 2018 +0000 |
6 |
URL: https://gitweb.gentoo.org/proj/portage.git/commit/?id=1d2e1ee6 |
7 |
|
8 |
bin/ebuild: fix --debug to work during manifest generation |
9 |
|
10 |
Reported-by: M. J. Everitt <m.j.everitt <AT> iee.org> |
11 |
|
12 |
bin/ebuild | 6 ++++++ |
13 |
1 file changed, 6 insertions(+) |
14 |
|
15 |
diff --git a/bin/ebuild b/bin/ebuild |
16 |
index 5aa3ead95..8b58988c4 100755 |
17 |
--- a/bin/ebuild |
18 |
+++ b/bin/ebuild |
19 |
@@ -104,6 +104,12 @@ if not opts.ignore_default_opts: |
20 |
debug = opts.debug |
21 |
force = opts.force |
22 |
|
23 |
+if debug: |
24 |
+ # Ensure that all config instances have this setting, |
25 |
+ # including the one that's used by portdbapi for aux_get. |
26 |
+ os.environ['PORTAGE_DEBUG'] = '1' |
27 |
+ portage._reset_legacy_globals() |
28 |
+ |
29 |
# do this _after_ 'import portage' to prevent unnecessary tracing |
30 |
if debug and "python-trace" in portage.features: |
31 |
import portage.debug |