gtk-icon-cache: Fix rdepends construction
PATCH 1/1 gtk-icon-cache: Fix rdepends construction
The rdepends getVar is returning NoneType and the string constuction fails this occurs with the hicolor-icon-theme recipe.
--- meta/classes/gtk-icon-cache.bbclass | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-)
meta/classes/gtk-icon-cache.bbclass +2 -3
@@ -67,9 +67,8 @@ python populate_packages_append () { continue bb.note("adding hicolor-icon-theme dependency to %s" % pkg) - rdepends = d.getVar('RDEPENDS_%s' % pkg, True) - rdepends = rdepends + ' ' + d.getVar('MLPREFIX') + "hicolor-icon-theme" - d.setVar('RDEPENDS_%s' % pkg, rdepends) + rdepends = ' ' + d.getVar('MLPREFIX') + "hicolor-icon-theme" + d.appendVar('RDEPENDS_%s' % pkg, rdepends) bb.note("adding gtk-icon-cache postinst and postrm scripts to %s" % pkg)
Signature · 1 line
1.7.10.4
meta/classes/gtk-icon-cache.bbclass python populate_packages_append () { · line 71
Quoted 7 lines · Saul Wold
(quoted diff) +0
-2- rdepends = d.getVar('RDEPENDS_%s' % pkg, True) - rdepends = rdepends + ' ' + d.getVar('MLPREFIX') +"hicolor-icon-theme"
meta/classes/gtk-icon-cache.bbclass +2
-1- d.setVar('RDEPENDS_%s' % pkg, rdepends) + rdepends = ' ' + d.getVar('MLPREFIX') + "hicolor-icon-theme" + d.appendVar('RDEPENDS_%s' % pkg, rdepends)
The new version isn't using a getVar of the old rdepends at all, so it's just replacing it every time. Is that really what you intended here? Wouldn't a getVar() or '' be a better approach? Further, the '' + d.getVar('MLPREFIX') is pointless if you aren't including the original value, as it adds a separator to the beginning when there's nothing to separate.
Signature · 1 line
Christopher Larson
Quoted 10 lines · Chris Larson
meta/classes/gtk-icon-cache.bbclass python populate_packages_append () { · line 71
Quoted 7 lines · Saul Wold
(quoted diff) +0
-2- rdepends = d.getVar('RDEPENDS_%s' % pkg, True) - rdepends = rdepends + ' ' + d.getVar('MLPREFIX') +"hicolor-icon-theme"
meta/classes/gtk-icon-cache.bbclass +2
-1- d.setVar('RDEPENDS_%s' % pkg, rdepends) + rdepends = ' ' + d.getVar('MLPREFIX') + "hicolor-icon-theme" + d.appendVar('RDEPENDS_%s' % pkg, rdepends)
Quoted 6 lines
The new version isn't using a getVar of the old rdepends at all, so it's just replacing it every time. Is that really what you intended here? Wouldn't a
getVar()or '' be a better approach? Further, the '' +d.getVar('MLPREFIX')is pointless if you aren't including the original value, as it adds a separator to the beginning when there's nothing to separate.
Erm, ignore this, I'm apparently blind as a bat if I can't see 'appendVar' :)
Signature · 1 line
Christopher Larson
Quoted 24 lines · Chris Larson
On Thu, Jan 31, 2013 at 12:50 PM, Chris Larson <[email protected] <mailto:[email protected]>> wrote:
On Thu, Jan 31, 2013 at 12:11 PM, Saul Wold <[email protected] <mailto:[email protected]>> wrote:
- rdepends =
d.getVar('RDEPENDS_%s' % pkg, True)
- rdepends = rdepends + ' ' +d.getVar('MLPREFIX')+
"hicolor-icon-theme"
-d.setVar('RDEPENDS_%s' % pkg, rdepends)
+ rdepends = ' ' +d.getVar('MLPREFIX')+
"hicolor-icon-theme"
+d.appendVar('RDEPENDS_%s' % pkg, rdepends)The new version isn't using a getVar of the old rdepends at all, so it's just replacing it every time. Is that really what you intended here? Wouldn't a
getVar()or '' be a better approach? Further, the '' +d.getVar('MLPREFIX')is pointless if you aren't including the original value, as it adds a separator to the beginning when there's nothing to separate.
Quoted 2 lines
Erm, ignore this, I'm apparently blind as a bat if I can't see 'appendVar' :)
No problem, I have had those days also.
Sau!
Quoted 2 lines
--
Christopher Larson