Yocto/Bitbake build task default execution order

40 Views Asked by At

In what order are Yocto's "Normal Recipe Build Tasks" executed by default? Is there a list in text format in the reference manual? Or is it available elsewhere?

The Normal recipe build tasks such as do_fetch, do_unpack, etc is found the Yocto reference manual but says nothing about the order.

1

There are 1 best solutions below

0
MiEbe On

As far as I know there is no way to generate a list of tasks which have to be executed upfront. The next best thing to what you are looking for is most likely the file log.task_order which can be found under <your_build_directory>/tmp/work/... after you built a certain recipe.

You can find all available log.task_order files by running

$ find <your_build_directory> -name "log.task_order"

If you are looking for a certain recipe better use

$ find <your_build_directory> -name "log.task_order" | grep <recipe_name>

For example if I want to see all the tasks which were executed for building u-boot-tools I run the following from my build directory:

$ find . -name "log.task_order" | grep u-boot-tools
./tmp/work/x86_64-linux/u-boot-tools-native/1_2021.07-r0/temp/log.task_order
$ cat ./tmp/work/x86_64-linux/u-boot-tools-native/1_2021.07-r0/temp/log.task_order
do_fetch (31716): log.do_fetch.31716
do_unpack (46850): log.do_unpack.46850
do_prepare_recipe_sysroot (46851): log.do_prepare_recipe_sysroot.46851
do_patch (46901): log.do_patch.46901
do_deploy_source_date_epoch (46980): log.do_deploy_source_date_epoch.46980
do_configure (47005): log.do_configure.47005
do_compile (47032): log.do_compile.47032
do_install (49251): log.do_install.49251
do_populate_sysroot (49265): log.do_populate_sysroot.49265

Looking at the file with cat lists the tasks in the order they were executed. Note that this only lists the tasks that have been tried so far. In case the recipe was built successfully this includes all tasks but if it fails only the tasks up to the failing one are listed.