public inbox for isar-users@googlegroups.com
 help / color / mirror / Atom feed
From: Jan Kiszka <jan.kiszka@siemens.com>
To: isar-users <isar-users@googlegroups.com>
Subject: [PATCH 1/4] patch: Add support for patchdir parameter
Date: Tue,  2 Apr 2019 08:20:48 +0200	[thread overview]
Message-ID: <b1d8266b127d2b0de75ab9230401e9200ee7805b.1554186051.git.jan.kiszka@siemens.com> (raw)
In-Reply-To: <cover.1554186051.git.jan.kiszka@siemens.com>
In-Reply-To: <cover.1554186051.git.jan.kiszka@siemens.com>

From: Jan Kiszka <jan.kiszka@siemens.com>

This allows to define the target directory of a patch, just like OE
supports it. Default remains ${S}.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
---
 meta/classes/patch.bbclass | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/meta/classes/patch.bbclass b/meta/classes/patch.bbclass
index c19542d..4c08193 100644
--- a/meta/classes/patch.bbclass
+++ b/meta/classes/patch.bbclass
@@ -19,13 +19,14 @@ python do_patch() {
             if not (basename.endswith(".patch") or apply == "yes"):
                 continue
 
+            patchdir = fetcher.ud[src_uri].parm.get("patchdir") or src_dir
             striplevel = fetcher.ud[src_uri].parm.get("striplevel") or "1"
 
             cmd = [
                 "patch",
                 "--no-backup-if-mismatch",
                 "-p", striplevel,
-                "--directory", src_dir,
+                "--directory", patchdir,
                 "--input", workdir + basename,
             ]
             bb.note(" ".join(cmd))
-- 
2.16.4


  reply	other threads:[~2019-04-02  6:20 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-04-02  6:20 [PATCH 0/4] Patch improvements, more templating fallouts, linux-libc-dev fix Jan Kiszka
2019-04-02  6:20 ` Jan Kiszka [this message]
2019-04-02  6:20 ` [PATCH 2/4] Make patch task repeatedly applicable Jan Kiszka
2019-04-02  6:20 ` [PATCH 3/4] template: Remove KERNEL_NAME from default TEMPLATE_VARS Jan Kiszka
2019-04-02  6:20 ` [PATCH 4/4] linux-custom: Fix linux-libc-dev version check Jan Kiszka
2019-04-03 18:36 ` [PATCH 0/4] Patch improvements, more templating fallouts, linux-libc-dev fix Maxim Yu. Osipov

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=b1d8266b127d2b0de75ab9230401e9200ee7805b.1554186051.git.jan.kiszka@siemens.com \
    --to=jan.kiszka@siemens.com \
    --cc=isar-users@googlegroups.com \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox