All of lore.kernel.org
 help / color / mirror / Atom feed
From: "André Draszik" <git@andred.net>
To: Ross Burton <ross.burton@intel.com>,
	 openembedded-core@lists.openembedded.org
Subject: Re: [PATCH] bitbake.conf: add default for IMAGE_FSTYPES_DEBUGFS
Date: Fri, 27 May 2016 11:54:23 +0100	[thread overview]
Message-ID: <1464346463.28160.45.camel@andred.net> (raw)
In-Reply-To: <1462534000-18539-1-git-send-email-ross.burton@intel.com>

[-- Attachment #1: Type: text/plain, Size: 1260 bytes --]

This doesn't work for me (at least on krogoth):

    ERROR: poky/meta/recipes-core/images/build-appliance-image_14.0.0.bb: No IMAGE_CMD defined for IMAGE_FSTYPES entry 'debugfs_vmdk' - possibly invalid type name or missing support class
    ERROR: Failed to parse recipe: poky/meta/recipes-core/images/build-appliance-image_14.0.0.bb

I *instead* am using the attached patch successfully.

Is anybody else facing the same issue?


On Fr, 2016-05-06 at 12:26 +0100, Ross Burton wrote:
> If debug filesystem generation is enabled but this isn't assigned then the
> generation code throws exceptions.
> 
> Signed-off-by: Ross Burton <ross.burton@intel.com>
> ---
>  meta/conf/bitbake.conf | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/meta/conf/bitbake.conf b/meta/conf/bitbake.conf
> index 1c4175f..8e02e91 100644
> --- a/meta/conf/bitbake.conf
> +++ b/meta/conf/bitbake.conf
> @@ -713,6 +713,7 @@ require conf/sanity.conf
>  DL_DIR ?= "${TOPDIR}/downloads"
>  SSTATE_DIR ?= "${TOPDIR}/sstate-cache"
>  IMAGE_FSTYPES ?= "tar.gz"
> +IMAGE_FSTYPES_DEBUGFS ?= "${IMAGE_FSTYPES}"
>  
>  INITRAMFS_FSTYPES ?= "cpio.gz"
>  # The maximum size in Kbytes for the generated initramfs image size.
> -- 
> 2.8.0.rc3
> 

[-- Attachment #2: 0001-image.bbclass-allow-IMAGE_FSTYPES_DEBUGFS-to-be-unse.patch --]
[-- Type: text/x-patch, Size: 2157 bytes --]

From 001ab66c36b18b8a3f25b1116a8c6580c676a673 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Draszik?= <git@andred.net>
Date: Tue, 12 Apr 2016 09:14:40 +0100
Subject: [PATCH] image.bbclass: allow IMAGE_FSTYPES_DEBUGFS to be unset (as
 per the documentation)

conf/local.conf.sample.extended describes IMAGE_FSTYPES_DEBUGFS as defaulting
to IMAGE_FSTYPES if unset.

If you actually do that, i.e. enable IMAGE_GEN_DEBUGFS but don't set
IMAGE_FSTYPES_DEBUGFS, you get the following parse error:

ERROR: Error executing a python function in <code>:

The stack trace of python calls that resulted in this exception/failure was:
File: '<code>', lineno: 14, function: <module>
     0010:__anon_38__meta_classes_rootfs_ipk_bbclass(d)
     0011:__anon_113__meta_classes_image_bbclass(d)
     0012:__anon_176__meta_classes_image_bbclass(d)
     0013:__anon_146__meta_classes_siteinfo_bbclass(d)
 *** 0014:__anon_437__meta_classes_image_bbclass(d)
File: '<poky>meta/classes/image.bbclass', lineno: 322, function: __anon_437__meta_classes_image_bbclass
     0318:    typedeps = {}
     0319:
     0320:    if d.getVar('IMAGE_GEN_DEBUGFS', True) == "1":
     0321:        debugfs_fstypes = d.getVar('IMAGE_FSTYPES_DEBUGFS', True).split()
 *** 0322:        for t in debugfs_fstypes:
     0323:            alltypes.append("debugfs_" + t)
     0324:
     0325:    def _add_type(t):
     0326:        baset = _image_base_type(t)
Exception: AttributeError: 'NoneType' object has no attribute 'split'
---
 meta/classes/image.bbclass | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/meta/classes/image.bbclass b/meta/classes/image.bbclass
index acaa9ec..59ba38e 100644
--- a/meta/classes/image.bbclass
+++ b/meta/classes/image.bbclass
@@ -318,8 +318,8 @@ python () {
     typedeps = {}
 
     if d.getVar('IMAGE_GEN_DEBUGFS', True) == "1":
-        debugfs_fstypes = d.getVar('IMAGE_FSTYPES_DEBUGFS', True).split()
-        for t in debugfs_fstypes:
+        debugfs_fstypes = d.getVar('IMAGE_FSTYPES_DEBUGFS', True) or ''
+        for t in debugfs_fstypes.split():
             alltypes.append("debugfs_" + t)
 
     def _add_type(t):
-- 
2.8.1


  parent reply	other threads:[~2016-05-27 10:54 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-05-06 11:26 [PATCH] bitbake.conf: add default for IMAGE_FSTYPES_DEBUGFS Ross Burton
2016-05-06 11:40 ` Martin Jansa
2016-05-06 13:51 ` Mark Hatle
2016-05-06 14:13   ` Khem Raj
2016-05-27 10:54 ` André Draszik [this message]
2016-05-27 14:21   ` Mark Hatle
2016-05-27 14:42     ` André Draszik
2016-05-27 15:21       ` Mark Hatle
2016-05-27 20:42         ` André Draszik
2016-07-14 10:04           ` André Draszik

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=1464346463.28160.45.camel@andred.net \
    --to=git@andred.net \
    --cc=openembedded-core@lists.openembedded.org \
    --cc=ross.burton@intel.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 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.