On Wed, Apr 20, 2022 at 12:28 PM Russ Dill <[email protected]>
wrote:

> do_kernel_configcheck utilizes pathnames relative to the sourcedir
> but does not specify ${S} in [dirs]. tasks that do not specify
> [dirs] default to the cwd of the bitbake parent process. This can be
> seen by inspection of exec_func/exec_func_python of
> bitbake/lib/bb/build.py or by placing a "print('CWD', os.getcwd())"
> at the head of do_kernel_configcheck.
>
> This is problematic if bitbake is run from a directory that
> contains a meta/ subdirectory. In this case the code:
>
>     kmeta = d.getVar("KMETA") or "meta"
>     if not os.path.exists(kmeta):
>         kmeta = subprocess.check_output(['kgit', '--meta'],
> cwd=d.getVar('S')).decode('utf-8').rstrip()
>
> Causes kmeta to be set to just "meta" if a meta directory exists
> in the cwd of the bitbake parent process, or to the output of
>

That isn't actually a problem, and is the design intent of that check. It
allows a temporary/local override of the meta data, simply by creating a
'meta' subdir.

Bruce



> kgit --meta if it does not.
>
> Signed-off-by: Russ Dill <[email protected]>
> ---
>  meta/classes/kernel-yocto.bbclass | 1 +
>  1 file changed, 1 insertion(+)
>
> diff --git a/meta/classes/kernel-yocto.bbclass
> b/meta/classes/kernel-yocto.bbclass
> index 1d5a8cdf29..c787b2a122 100644
> --- a/meta/classes/kernel-yocto.bbclass
> +++ b/meta/classes/kernel-yocto.bbclass
> @@ -620,6 +620,7 @@ python do_kernel_configcheck() {
>      if warnings_detected and kmeta_audit_werror:
>          bb.fatal( "configuration warnings detected, werror is set,
> promoting to fatal" )
>  }
> +do_kernel_configcheck[dirs] = "${S}"
>
>  # Ensure that the branches (BSP and meta) are on the locations specified
> by
>  # their SRCREV values. If they are NOT on the right commits, the branches
> --
> 2.25.1
>
>

-- 
- Thou shalt not follow the NULL pointer, for chaos and madness await thee
at its end
- "Use the force Harry" - Gandalf, Star Trek II
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#164717): 
https://lists.openembedded.org/g/openembedded-core/message/164717
Mute This Topic: https://lists.openembedded.org/mt/90587617/21656
Group Owner: [email protected]
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to