All of lore.kernel.org
 help / color / mirror / Atom feed
From: Konrad Weihmann <kweihmann@outlook.com>
To: openembedded-core@lists.openembedded.org
Cc: Alexander Kanavin <alex.kanavin@gmail.com>,
	Richard Purdie <richard.purdie@linuxfoundation.org>
Subject: Re: [OE-core] [meta-oe][RFC PATCH 2/2] insane: make patch upstream-status configurable
Date: Wed, 15 Dec 2021 11:06:37 +0100	[thread overview]
Message-ID: <AM9PR09MB4642F33198D3E8BC03E9B403A8769@AM9PR09MB4642.eurprd09.prod.outlook.com> (raw)
In-Reply-To: <16C0E58BF5CDEB84.23449@lists.openembedded.org>

Picking up where Alex left it last time, this proposes a different way 
to make the layers where the Upstream-Status check is run configurable.

Please share your thoughs - esp. about the vardepsexclude, as I so far 
don't see any other option to get rid of the BBFILE_PATTERN creeping 
into the task hash

On 15.12.21 11:03, Konrad Weihmann wrote:
> instead of hard coding /meta/ into a skip condition introduce a
> variable called QA_PATCH_CHECK_LAYER containing a space
> separated list of layer names to perform the upstrem-status check
> against.
> 
> as this will add BBFILE_PATTERN_* and therefore host specific paths
> to the task hash, we need to exclude do_qa_patch function from
> task hashing.
> As it is a postfunc it should run anyway, once do_patch needs to rerun
> 
> Signed-off-by: Konrad Weihmann <kweihmann@outlook.com>
> ---
>   meta/classes/insane.bbclass | 10 ++++++++--
>   1 file changed, 8 insertions(+), 2 deletions(-)
> 
> diff --git a/meta/classes/insane.bbclass b/meta/classes/insane.bbclass
> index 240f3aad62..c19cc6f629 100644
> --- a/meta/classes/insane.bbclass
> +++ b/meta/classes/insane.bbclass
> @@ -65,6 +65,8 @@ QA_EMPTY_DIRS ?= " \
>   # message if the directory is not empty. If it is not specified for a directory,
>   # then "but it is expected to be empty" will be used.
>   
> +QA_PATCH_CHECK_LAYER ?= "core"
> +
>   def package_qa_clean_path(path, d, pkg=None):
>       """
>       Remove redundant paths from the path for display.  If pkg isn't set then
> @@ -1171,12 +1173,15 @@ python do_qa_patch() {
>       # Check if the patch contains a correctly formatted and spelled Upstream-Status
>       import re
>       from oe import patch
> +    from oe.recipeutils import get_layer_name
> +
> +    check_layer = (d.getVar("QA_PATCH_CHECK_LAYER") or "").split()
>   
>       for url in patch.src_patches(d):
>          (_, _, fullpath, _, _, _) = bb.fetch.decodeurl(url)
>   
> -       # skip patches not in oe-core
> -       if '/meta/' not in fullpath:
> +       # skip patches in all but the configured ones
> +       if get_layer_name(fullpath, d) not in check_layer:
>              continue
>   
>          content = open(fullpath, encoding='utf-8', errors='ignore').read()
> @@ -1298,6 +1303,7 @@ do_populate_sysroot[postfuncs] += "do_qa_staging "
>   
>   # Check for patch fuzz
>   do_patch[postfuncs] += "do_qa_patch "
> +do_patch[vardepsexclude] += "do_qa_patch "
>   
>   # Check broken config.log files, for packages requiring Gettext which
>   # don't have it in DEPENDS.
> 
> 
> 
> -=-=-=-=-=-=-=-=-=-=-=-
> Links: You receive all messages sent to this group.
> View/Reply Online (#159718): https://lists.openembedded.org/g/openembedded-core/message/159718
> Mute This Topic: https://lists.openembedded.org/mt/87741230/3647476
> Group Owner: openembedded-core+owner@lists.openembedded.org
> Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [kweihmann@outlook.com]
> -=-=-=-=-=-=-=-=-=-=-=-
> 


  parent reply	other threads:[~2021-12-15 10:06 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20211215100344.3266900-1-kweihmann@outlook.com>
2021-12-15 10:03 ` [meta-oe][RFC PATCH 2/2] insane: make patch upstream-status configurable Konrad Weihmann
     [not found] ` <16C0E58BF5CDEB84.23449@lists.openembedded.org>
2021-12-15 10:06   ` Konrad Weihmann [this message]
2021-12-15 14:55     ` [OE-core] " Alexander Kanavin

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=AM9PR09MB4642F33198D3E8BC03E9B403A8769@AM9PR09MB4642.eurprd09.prod.outlook.com \
    --to=kweihmann@outlook.com \
    --cc=alex.kanavin@gmail.com \
    --cc=openembedded-core@lists.openembedded.org \
    --cc=richard.purdie@linuxfoundation.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.