1 |
commit: 70376e296ccf04cd15c03db6fd7a8c83bf0cf09f |
2 |
Author: Brian Dolbec <dolsen <AT> gentoo <DOT> org> |
3 |
AuthorDate: Tue May 31 14:19:21 2016 +0000 |
4 |
Commit: Brian Dolbec <dolsen <AT> gentoo <DOT> org> |
5 |
CommitDate: Tue May 31 14:20:16 2016 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=70376e29 |
7 |
|
8 |
app-portage/layman: Bump with patch, fixes bug 582154 |
9 |
|
10 |
Package-Manager: portage-2.3.0_rc1 |
11 |
|
12 |
.../layman-2.4.1-sourcefileattributechanges.patch | 42 ++++++++++++++++++++++ |
13 |
...{layman-2.4.1.ebuild => layman-2.4.1-r1.ebuild} | 4 +++ |
14 |
2 files changed, 46 insertions(+) |
15 |
|
16 |
diff --git a/app-portage/layman/files/layman-2.4.1-sourcefileattributechanges.patch b/app-portage/layman/files/layman-2.4.1-sourcefileattributechanges.patch |
17 |
new file mode 100644 |
18 |
index 0000000..207f474 |
19 |
--- /dev/null |
20 |
+++ b/app-portage/layman/files/layman-2.4.1-sourcefileattributechanges.patch |
21 |
@@ -0,0 +1,42 @@ |
22 |
+From 90fe6724d0a8d1ebfe6443dee118432e20432b8b Mon Sep 17 00:00:00 2001 |
23 |
+From: Brian Dolbec <dolsen@g.o> |
24 |
+Date: Tue, 10 May 2016 15:12:02 -0700 |
25 |
+Subject: [PATCH] layman/module.py: Fix commit 63808ef00f94 mis-applied |
26 |
+ 'sourcefile' attribute changes |
27 |
+ |
28 |
+It was not looking for the 'sourcefile' attribute first, then falling back to the kidname for |
29 |
+backward compatibility. |
30 |
+It was incorrectly looking for an ImportError, instead of a 'sourcefile' KeyError. |
31 |
+The filepath of the affected file for the error message had an extra leading '_'. |
32 |
+Add the module name to the warning message. |
33 |
+--- |
34 |
+ layman/module.py | 11 ++++++----- |
35 |
+ 1 file changed, 6 insertions(+), 5 deletions(-) |
36 |
+ |
37 |
+diff --git a/layman/module.py b/layman/module.py |
38 |
+index 08bcbc2..092418f 100644 |
39 |
+--- a/layman/module.py |
40 |
++++ b/layman/module.py |
41 |
+@@ -49,13 +49,14 @@ class Module(object): |
42 |
+ kid = self.module_spec['provides'][submodule] |
43 |
+ kidname = kid['name'] |
44 |
+ try: |
45 |
++ kid['module_name'] = '.'.join([mod_name, kid['sourcefile']]) |
46 |
++ except KeyError: |
47 |
+ kid['module_name'] = '.'.join([mod_name, kidname]) |
48 |
+- except ImportError: |
49 |
+- kid['module_name'] = '.'.join([mod_name, self.name]) |
50 |
+- f = self.__module.__file__ |
51 |
+- msg = 'Module.__initialize(); module spec is old, missing '\ |
52 |
++ f = self._module.__file__ |
53 |
++ msg = 'Module.__initialize(); %(module)s module spec is old, missing '\ |
54 |
+ 'attribute: \'sourcefile\'.\nBackward compatibility '\ |
55 |
+- 'may be removed in the future.\nFile: %(f)s' % {'f': f} |
56 |
++ 'may be removed in the future.\nFile: %(f)s' % { |
57 |
++ 'module': self.name, 'f': f} |
58 |
+ self.output.warn(msg) |
59 |
+ kid['is_imported'] = False |
60 |
+ self.kids[kidname] = kid |
61 |
+-- |
62 |
+2.8.3 |
63 |
+ |
64 |
|
65 |
diff --git a/app-portage/layman/layman-2.4.1.ebuild b/app-portage/layman/layman-2.4.1-r1.ebuild |
66 |
similarity index 96% |
67 |
rename from app-portage/layman/layman-2.4.1.ebuild |
68 |
rename to app-portage/layman/layman-2.4.1-r1.ebuild |
69 |
index 79dcd8c..748813b 100644 |
70 |
--- a/app-portage/layman/layman-2.4.1.ebuild |
71 |
+++ b/app-portage/layman/layman-2.4.1-r1.ebuild |
72 |
@@ -41,6 +41,10 @@ RDEPEND=" |
73 |
>=dev-python/ssl-fetch-0.4[${PYTHON_USEDEP}] |
74 |
" |
75 |
|
76 |
+PATCHES=( |
77 |
+ "${FILESDIR}/layman-2.4.1-sourcefileattributechanges.patch" |
78 |
+) |
79 |
+ |
80 |
layman_check_kernel_config() { |
81 |
local CONFIG_CHECK |
82 |
use squashfs && CONFIG_CHECK+=" ~BLK_DEV_LOOP ~SQUASHFS" |