Skip to contentSkip to conversation

in sysfsutils_2.1.0.bb, is 'S = "${WORKDIR}/sysfsutils-${PV}"' redundant?

DISCUSSION Robert P. J. Day 2 participants 4 messages Jan 13, 2015 – Jan 21, 2015

lore
Share & tools
lore
#0 lore raw

more nitpickery, but was demonstrating OE recipe structure to class
yesterday, arbitrarily picked sysfsutils_2.1.0.bb, going through it line by line, and a sharp-eyed student noticed this line:

S = "${WORKDIR}/sysfsutils-${PV}"

and wondered what it was doing there, since bitbake.conf sets the default of:

S = "${WORKDIR}/${BP}"

and since, by default:

BP = "${BPN}-${PV}"

the source directory for sysfsutils would already appear to be correct. setting S that way in the recipe obviously doesn't do any harm, but is it accurate to say that, at least in this case, it's unnecessary?

rday

Signature · 7 lines
========================================================================
Robert P. J. Day                                 Ottawa, Ontario, CANADA
                        http://crashcourse.ca

Twitter:                                       http://twitter.com/rpjday
LinkedIn:                               http://ca.linkedin.com/in/rpjday
========================================================================
#1 lore raw
Quoted 4 lines · Robert P. J. Day

setting S that way in the recipe obviously doesn't do any harm, but is it accurate to say that, at least in this case, it's unnecessary?

Correct. A patch from the student is welcome. :)

Ross

#2 lore raw
Quoted 8 lines · Ross

On 13 January 2015 at 12:57, Robert P. J. Day <[email protected]> wrote:
setting S that way in the recipe obviously doesn't do any harm, but is it accurate to say that, at least in this case, it's unnecessary?

Correct.  A patch from the student is welcome. :)

actually, there appears to be quite a lot of that scattered
throughout oe-core, so i'm not sure it's worth trying to clean it up piecemeal as opposed to just doing it in one large patch. as i said, i realize it doesn't hurt, but i'm a big fan of not having lines where lines are unnecessary.

i'll defer to the list ... is it worth tracking down all the recipes
that are doing that and just deleting that redundant line from them? or is that just unnecessary code churn?

rday

Signature · 7 lines
========================================================================
Robert P. J. Day                                 Ottawa, Ontario, CANADA
                        http://crashcourse.ca

Twitter:                                       http://twitter.com/rpjday
LinkedIn:                               http://ca.linkedin.com/in/rpjday
========================================================================
#3 lore raw
Quoted 4 lines · Robert P. J. Day

i'll defer to the list ... is it worth tracking down all the recipes
that are doing that and just deleting that redundant line from them? or is that just unnecessary code churn?

A single patch to clean up all of oe-core would be clean and as you say, removing redundancy is good.

Ross