Openembedded Core Discussions
 help / color / mirror / Atom feed
From: Paulo Neves <ptsneves@gmail.com>
To: openembedded-core@lists.openembedded.org
Subject: [meta-oe][PATCH 3/3] masterimage: Check for rootfs path instead of file.
Date: Fri, 10 Aug 2018 21:37:59 +0200	[thread overview]
Message-ID: <1533929879-22972-3-git-send-email-ptsneves@gmail.com> (raw)
In-Reply-To: <1533929879-22972-1-git-send-email-ptsneves@gmail.com>

The rootfs might be a directory path or a file path. A
case in point is if the test wants to deploy a rootfs
directly by rsyncing it to the target or even use it
as part of a tftp server.

Signed-off-by: Paulo Neves <ptsneves@gmail.com>
---
 meta/lib/oeqa/controllers/masterimage.py | 6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)

diff --git a/meta/lib/oeqa/controllers/masterimage.py b/meta/lib/oeqa/controllers/masterimage.py
index 26e3870..fb8ab50 100644
--- a/meta/lib/oeqa/controllers/masterimage.py
+++ b/meta/lib/oeqa/controllers/masterimage.py
@@ -51,11 +51,7 @@ class MasterImageHardwareTarget(oeqa.targetcontrol.BaseTarget, metaclass=ABCMeta
         self.image_fstype = self.get_image_fstype(td)
         self.rootfs = os.path.join(td['DEPLOY_DIR_IMAGE'], td['IMAGE_LINK_NAME'] + '.' + self.image_fstype)
         self.kernel = os.path.join(td['DEPLOY_DIR_IMAGE'], td["KERNEL_IMAGETYPE"] + '-' + td['MACHINE'] + '.bin')
-        if not os.path.isfile(self.rootfs):
-            # we could've checked that IMAGE_FSTYPES contains tar.gz but the config for running testimage might not be
-            # the same as the config with which the image was build, ie
-            # you bitbake core-image-sato with IMAGE_FSTYPES += "tar.gz"
-            # and your autobuilder overwrites the config, adds the test bits and runs bitbake core-image-sato -c testimage
+        if not os.path.exists(self.rootfs):
             bb.fatal("No rootfs found. Did you build the image ?\n"  \
               "If yes, did you build it with IMAGE_FSTYPES += \"{}\" ?"  \
               "\nExpected path: {}".format(" ".join(self.supported_image_fstypes), self.rootfs))
-- 
2.7.4



  parent reply	other threads:[~2018-08-10 19:38 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-08-10 19:37 [meta-oe][PATCH 1/3] testimage: Refactoring and fixing Paulo Neves
2018-08-10 19:37 ` [meta-oe][PATCH 2/3] testimage: target.start exceptions not masked Paulo Neves
2018-08-10 19:37 ` Paulo Neves [this message]
2018-08-11 12:29 ` [meta-oe][PATCH 1/3] testimage: Refactoring and fixing Richard Purdie
2018-08-12 19:49 ` Paulo Neves
2018-08-13 14:33   ` Richard Purdie
2018-08-18 16:40   ` Paulo Neves
2018-08-19 22:14     ` Richard Purdie

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=1533929879-22972-3-git-send-email-ptsneves@gmail.com \
    --to=ptsneves@gmail.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox