There is the following code in bitbake/bin/bitbake-runtask: cooker.bb_cache.setData(fn, buildfile, the_data) cooker.bb_cache.handle_data(fn, cooker.status) The API setData has been removed in 1.0.1 and 1.1, so it doesn't work, I think that replace them by: cooker.bb_cache.handle_data(fn, cooker.status) would make it work.
This is not an enhancement request, bitbake-runtask exists and its broken. That is a bug.
Fixed in master http://git.yoctoproject.org/cgit.cgi/poky/commit/?id=37c4f373e42b54f6c65b8482bd1172563fbc1ea5
verified on following git commit : commit 4cd96710785eb05abeff1f281878655118d4a7dd Author: Richard Purdie <richard.purdie@linuxfoundation.org> Date: Fri Nov 25 14:57:53 2011 +0000 bitbake: Update users of getVar/setVar to use the data store functions direc Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> git branch: poky/master test steps: 1.set build env. 2.run "bitbake man-1.6f". 3.run "bitbake man-1.6f -cclean". 4.run "bitbake-runtask man_1.6f do_fetch" . also run "bitbake-runtask man_1.6f do_unpack","bitbake-runtask man_1.6f do_patch","bitbake-runtask man_1.6f do_configure","bitbake-runtask man_1.6f do_compile","bitbake-runtask man_1.6f do_install","bitbake-runtask man_1.6f do_populate_lic","bitbake-runtask man_1.6f do_populate_sysroot" 5.check return value of these command using "echo $?",all get 0. 6.check related logs in tmp/work/ppc603e-poky-linux/man-1.6f-r1/temp (qemuppc for example) test following platforms: qemux86,qemux86-64,qemuppc,qemumips,qemuarm,mpc8315e-rdb no error met execute bitbake-runtask,so change status to verified.
bitbake-runtask can not work on 1.2 M3 RC1: git info : 320558f494c618f53e0c773db3ea0109476e8359 git branch : 1.2_M3 test steps just as Comment 3: when run "bitbake-runtask man_1.6f do_fetch" ,errors below found: ERROR: Build of do_fetch failed ERROR: Traceback (most recent call last): File "/buildarea1/tester/test_git/bitbake/lib/bb/build.py", line 386, in exec_task return _exec_task(fn, task, d, quieterr) File "/buildarea1/tester/test_git/bitbake/lib/bb/build.py", line 376, in _exec_task make_stamp(task, localdata) File "/buildarea1/tester/test_git/bitbake/lib/bb/build.py", line 431, in make_stamp stamp = stamp_internal(task, d, file_name) File "/buildarea1/tester/test_git/bitbake/lib/bb/build.py", line 420, in stamp_internal stamp = bb.parse.siggen.stampfile(stamp, file_name, taskname, extrainfo) File "/buildarea1/tester/test_git/bitbake/lib/bb/siggen.py", line 222, in stampfile h = self.taskhash[k] KeyError: '/buildarea1/tester/test_git/meta/recipes-extended/man/man_1.6f.bb.do_fetch' when change "do_fecth" to others such as "do_unpack", same error as above.
Whilst the error is pretty nasty, if you set BB_SIGNATURE_HANDLER = 'OEBasic', the error will not happen. The problem is the default handler, OEBasicHash is not going to be compatible with the bitbake-runtask mechanism of running tasks since there is no task signature data to use with the stamp. I'm therefore not sure this is an error we can fix, it just needs to be documented as something that is not expected to work.
(In reply to comment #5) > Whilst the error is pretty nasty, if you set BB_SIGNATURE_HANDLER = 'OEBasic', > the error will not happen. > > The problem is the default handler, OEBasicHash is not going to be compatible > with the bitbake-runtask mechanism of running tasks since there is no task > signature data to use with the stamp. I'm therefore not sure this is an error > we can fix, it just needs to be documented as something that is not expected to > work. Thanks your advice, I have tried that : change following part of file "meta-yocto/conf/distro/poky.conf": # Default hash policy for distro BB_SIGNATURE_HANDLER ?= 'OEBasicHash' to : # Default hash policy for distro BB_SIGNATURE_HANDLER ?= 'OEBasic' then rerun steps in Comment 3,bitbake-runtask can work.
This needs to have a reasonable error message vs the Python backtrace
Fixed: http://git.yoctoproject.org/cgit.cgi/poky/commit/?id=664fb2753798da8f4ea6a5556c6ada986fdda8e9
bitbake-runtask can work using steps in Comment 3: git info:fe0659991b826eb3b4163743d29533fe5f91cb12 git branch: poky/master next weekly test if no error met, will change to verified.