All of lore.kernel.org
 help / color / mirror / Atom feed
From: Bruce Ashfield <bruce.ashfield@gmail.com>
To: mark.hatle@kernel.crashing.org
Cc: meta-virtualization@lists.yoctoproject.org
Subject: Re: [meta-virtualization][scarthgap][PATCH] linux-yocto_virtualization.inc: If using externalsrc adjust dependency
Date: Thu, 10 Oct 2024 13:17:30 +0000	[thread overview]
Message-ID: <ZwfT6m8YpLYe4w+9@gmail.com> (raw)
In-Reply-To: <1727908743-22316-1-git-send-email-mark.hatle@kernel.crashing.org>

merged (and typo fixed)

Bruce

In message: [meta-virtualization][scarthgap][PATCH] linux-yocto_virtualization.inc: If using externalsrc adjust dependency
on 02/10/2024 Mark Hatle via lists.yoctoproject.org wrote:

> From: Mark Hatle <mark.hatle@amd.com>
> 
> When using externalsrc, the system will disable a number of tasks such as
> do_validate_branches, do_unpack and do_patch.  The do_kernel_metadata task
> is configured to run after do_validate_branches do_unpack and before
> do_patch.  Since all of these have been removed, the task will never
> run.
> 
> The do_kernel_metadata task is responsible for populating the
> recipe-sysroot-native/kcfg directory via it's own dependency to
> yocto-cfg-fragments-native:do_populate_sysroot.
> 
> Without do_kernel_metadata running, do_kernel_configme will fail to run
> with errors like:
>   ERROR: linux-xlnx-6.6.40+git-r0 do_kernel_configme: Feature '../recipe-sysroot-native/kcfg/cfg/virtio.scc' not found, this will cause configuration failures.
>   ERROR: linux-xlnx-6.6.40+git-r0 do_kernel_configme: Check the SRC_URI for meta-data repositories or directories that may be missing
>   ERROR: linux-xlnx-6.6.40+git-r0 do_kernel_configme: Set KERNEL_DANGLING_FEATURES_WARN_ONLY to ignore this issue
> 
> Fix this issue by detecting if we're running with externalsrc, and then
> adding the task do_kernel_metadata (from the current recipe) as a
> dependency of do_kernel_configme.
> 
> To reproduce th original issue:
> 
>   $ . ./oe-initbuild-env
>   $ bitbake linux-yocto -c patch
>   $ cp -r tmp/work-shared/<machine>/kernel-source linux-yocto
> 
>   edit the conf/local.conf adding:
>   DISTRO_FEATURES:append = " virtualization"
>   INHERIT += "externalsrc"
>   EXTERNALSRC:pn-linux-yocto = "${TOPDIR}/linux-yocto"
> 
>   $ rm -rf tmp
>   $ bitbake linux-yocto -c menuconfig
> 
> Signed-off-by: Mark Hatle <mark.hatle@amd.com>
> ---
>  recipes-kernel/linux/linux-yocto_virtualization.inc | 6 ++++++
>  1 file changed, 6 insertions(+)
> 
> diff --git a/recipes-kernel/linux/linux-yocto_virtualization.inc b/recipes-kernel/linux/linux-yocto_virtualization.inc
> index 9a6554d..f0ec80c 100644
> --- a/recipes-kernel/linux/linux-yocto_virtualization.inc
> +++ b/recipes-kernel/linux/linux-yocto_virtualization.inc
> @@ -49,6 +49,12 @@ KERNEL_FEATURES:append = " ${KERNEL_CACHE_FEATURES}"
>  # features can be enabled via the fragments
>  do_kernel_metadata[depends] += "${@['', 'yocto-cfg-fragments-native:do_populate_sysroot'][(bb.data.inherits_class('kernel-yocto', d))]}"
>  
> +# if externalsrc is enabled, do_kernel_metadata dependency on
> +# yocto-cfg-fragments-native won't be run to populate
> +# recipe-sysroot-native/kcfg because do_patch is not run.  Manully add
> +# the dependency to do_kernel_configme for this special case
> +do_kernel_configme[depends] += "${@['', d.getVar('PN') + ':do_kernel_metadata'][(bb.data.inherits_class('externalsrc', d))]}"
> +
>  # xen kernel support
>  # SRC_URI += "${@bb.utils.contains('DISTRO_FEATURES', 'xen', ' file://xen.scc', '', d)}"
>  KERNEL_FEATURES:append = "${@distro_cond_feature('cfg/xen.scc', 'xen', d )}"
> -- 
> 2.34.1
> 

> 
> -=-=-=-=-=-=-=-=-=-=-=-
> Links: You receive all messages sent to this group.
> View/Reply Online (#8912): https://lists.yoctoproject.org/g/meta-virtualization/message/8912
> Mute This Topic: https://lists.yoctoproject.org/mt/108789783/1050810
> Group Owner: meta-virtualization+owner@lists.yoctoproject.org
> Unsubscribe: https://lists.yoctoproject.org/g/meta-virtualization/unsub [bruce.ashfield@gmail.com]
> -=-=-=-=-=-=-=-=-=-=-=-
> 



  parent reply	other threads:[~2024-10-10 13:17 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-10-02 22:39 [meta-virtualization][scarthgap][PATCH] linux-yocto_virtualization.inc: If using externalsrc adjust dependency Mark Hatle
2024-10-03  1:11 ` Peter Kjellerstedt
2024-10-03  1:32   ` Bruce Ashfield
2024-10-10 13:17 ` Bruce Ashfield [this message]
     [not found] <169112f3-874a-44fb-9898-98330b4a9d07@kernel.crashing.org>
2024-10-03  1:21 ` Mark Hatle

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=ZwfT6m8YpLYe4w+9@gmail.com \
    --to=bruce.ashfield@gmail.com \
    --cc=mark.hatle@kernel.crashing.org \
    --cc=meta-virtualization@lists.yoctoproject.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.