more user manual questions about bitbake tasks
it's humbling to realize all the niggling little details i don't
understand completely. oh, well ... some questions about bitbake tasks, most of which i think i know the answers to but let's play it safe.
first, is it true that the *only* way to define a bitbake task is
with the "addtask" directive? given that, one can at least consult OE's base.bbclass to see the low-level tasks that will be defined for all work, which i just noticed is a surprisingly short list:
$ grep "^addtask" meta/classes/base.bbclass addtask fetch addtask unpack after do_fetch addtask configure after do_patch addtask compile after do_configure addtask install after do_compile addtask build after do_populate_sysroot addtask cleansstate after do_clean addtask cleanall after do_cleansstate $
a couple observations about the above. i notice the general format
of the "addtask" directive:
addtask X after do_Y
where the "do_" prefix is used only on the latter task name. (you'll see why i mention this shortly.)
also, i notice that
addtask build after do_populate_sysroot
defines a task as being run after another task that is undefined in base.bbclass; that's ok, i can see it being defined in staging.bbclass:
addtask populate_sysroot after do_install
so i assume the general rule is that you can define tasks that "depend" on other tasks that you only have to *eventually* define, correct?
one more question. i'm puzzled by this snippet from staging.bbclass:
python do_populate_sysroot_setscene () {
sstate_setscene(d)
}
addtask do_populate_sysroot_setscenewhy is it
addtask do_populate_sysroot_setscene
rather than:
addtask populate_sysroot_setscene
i thought the general form of addtask was:
addtask X ... etc etc ...
the bitbake user manual definitely doesn't explain the syntax of
addtask do_X ...
but there seems to be some of that scattered around:
$ grep -r "^addtask do_" * meta/classes/kernel.bbclass:addtask do_strip before do_sizecheck after do_kernel_link_vmlinux meta/classes/staging.bbclass:addtask do_populate_sysroot_setscene meta/classes/package_rpm.bbclass:addtask do_package_write_rpm_setscene meta/classes/license.bbclass:addtask do_populate_lic_setscene meta/classes/archiver.bbclass:addtask do_ar_original after do_unpack ... snip ...
are both forms valid? more task questions coming shortly on another
topic.
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
========================================================================