Hi under my bitbake file I want to stop the execution of certain tasks and want compile function to be executed every time. For this, I have done the following changes.
do_compile[nostamp] = "1"
do_clean[noexec] = "1"
do_cleanall[noexec] = "1"
do_cleansstate[noexec] = "1"
do_fetch[noexec] = "1"
do_patch[noexec] = "1"
do_unpack[noexec] = "1"
And it worked perfectly fine. I was able to stop the execution of tasks like clean, cleanall, cleansstate, fetch, patch and unpack. Also, I was able to make sure that the compile task runs every time.
However, I want to put some restrictions on the same. I want to make sure that noexec and nostamp on relevant task only applies when DEVMODE variable is set to 1. Psuedo code as follows.
if DEVMODE == 1 then
do_compile[nostamp] = "1"
do_clean[noexec] = "1"
do_cleanall[noexec] = "1"
do_cleansstate[noexec] = "1"
do_fetch[noexec] = "1"
do_patch[noexec] = "1"
do_unpack[noexec] = "1"
endif
How to achieve the same in a bitbake file? I have tried this and this links but I am not able to craft a working if condition.
NOTE: Am ok using BB_ENV_EXTRAWHITE, but am not able to code a working if condition for the bitbake file.