All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Steve Sakoman" <steve@sakoman.com>
To: openembedded-core@lists.openembedded.org
Subject: [OE-core][dunfell 01/21] sanity: Verify that user isn't building in PSEUDO_IGNORE_PATHS
Date: Mon,  1 Feb 2021 06:24:32 -1000	[thread overview]
Message-ID: <a20b0f80c2d169115a0336f155a834a5801982f9.1612188857.git.steve@sakoman.com> (raw)
In-Reply-To: <cover.1612188857.git.steve@sakoman.com>

From: Dorinda <dorindabassey@gmail.com>

If a user builds in a path in PSEUDO_IGNORE_PATHS, random failures
are generated. Hence this patch adds a sanity check in sanity.bbclass
to ensure that a user isn't building in PSEUDO_IGNORE_PATHS.

[YOCTO #14179]

Signed-off-by: Dorinda Bassey <dorindabassey@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
(cherry picked from commit 7a681525e904914e938de25df5cc64209097d15d)
Signed-off-by: Steve Sakoman <steve@sakoman.com>
---
 meta/classes/sanity.bbclass | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/meta/classes/sanity.bbclass b/meta/classes/sanity.bbclass
index cdef8e0c7d..4dc21bf0a9 100644
--- a/meta/classes/sanity.bbclass
+++ b/meta/classes/sanity.bbclass
@@ -703,6 +703,13 @@ def check_sanity_version_change(status, d):
     if (tmpdirmode & stat.S_ISUID):
         status.addresult("TMPDIR is setuid, please don't build in a setuid directory")
 
+    # Check that a user isn't building in a path in PSEUDO_IGNORE_PATHS
+    pseudoignorepaths = d.getVar('PSEUDO_IGNORE_PATHS', expand=True).split(",")
+    workdir = d.getVar('WORKDIR', expand=True)
+    for i in pseudoignorepaths:
+        if i and workdir.startswith(i):
+            status.addresult("You are building in a path included in PSEUDO_IGNORE_PATHS " + str(i) + " please locate the build outside this path.\n")
+
     # Some third-party software apparently relies on chmod etc. being suid root (!!)
     import stat
     suid_check_bins = "chown chmod mknod".split()
-- 
2.25.1


  reply	other threads:[~2021-02-01 16:25 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-02-01 16:24 [OE-core][dunfell 00/21] Patch review Steve Sakoman
2021-02-01 16:24 ` Steve Sakoman [this message]
2021-02-01 16:24 ` [OE-core][dunfell 02/21] sanity.bbclass: sanity check for if bitbake is present in PATH Steve Sakoman
2021-02-01 16:24 ` [OE-core][dunfell 03/21] oeqa/ptest: print a warning if ptests failed Steve Sakoman
2021-02-01 16:24 ` [OE-core][dunfell 04/21] flex: fix build with autoconf 2.70 Steve Sakoman
2021-02-01 16:24 ` [OE-core][dunfell 05/21] flex: Refresh patch Steve Sakoman
2021-02-01 16:24 ` [OE-core][dunfell 06/21] flex: Fix --noline option behavior Steve Sakoman
2021-02-01 16:24 ` [OE-core][dunfell 07/21] toolchain-shar-relocate.sh: Fix handling files with colons Steve Sakoman
2021-02-01 16:24 ` [OE-core][dunfell 08/21] devtool: Fix source extraction for gcc shared source Steve Sakoman
2021-02-01 16:24 ` [OE-core][dunfell 09/21] externalsrc: Fix parsing error with devtool non-git sources Steve Sakoman
2021-02-01 16:24 ` [OE-core][dunfell 10/21] oeqa/selftest/cases/tinfoil.py: increase timeout 10->60s test_wait_event Steve Sakoman
2021-02-01 16:24 ` [OE-core][dunfell 11/21] devtool: Fix file:// fetcher symlink directory structure Steve Sakoman
2021-02-01 16:24 ` [OE-core][dunfell 12/21] dtc: improve reproducibility Steve Sakoman
2021-02-01 16:24 ` [OE-core][dunfell 13/21] core-image-sato-sdk-ptest: these images need ptest Steve Sakoman
2021-02-01 16:24 ` [OE-core][dunfell 14/21] ovmf-shell-image: image is only buildable on x86-64 Steve Sakoman
2021-02-01 16:24 ` [OE-core][dunfell 15/21] selftest/devtool: Add modify_localfiles_only test checking symlink path Steve Sakoman
2021-02-01 16:24 ` [OE-core][dunfell 16/21] timezone: upgrade to 2021a Steve Sakoman
2021-02-01 16:24 ` [OE-core][dunfell 17/21] strace: increase ptest timeout duration 120->240s Steve Sakoman
2021-02-01 16:24 ` [OE-core][dunfell 18/21] externalsrc: Detect code changes in submodules Steve Sakoman
2021-02-01 16:24 ` [OE-core][dunfell 19/21] ncurses: Don't put terminfo into the sysroot Steve Sakoman
2021-02-01 16:24 ` [OE-core][dunfell 20/21] python3: Avoid installing test data into recipe-sysroot Steve Sakoman
2021-02-01 16:24 ` [OE-core][dunfell 21/21] staging: Clean up files installed into the sysroot Steve Sakoman

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=a20b0f80c2d169115a0336f155a834a5801982f9.1612188857.git.steve@sakoman.com \
    --to=steve@sakoman.com \
    --cc=openembedded-core@lists.openembedded.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.