All of lore.kernel.org
 help / color / mirror / Atom feed
From: Davide Soldan <davide.soldan@kynetics.it>
To: "Erik Botö" <erik.boto@pelagicore.com>
Cc: "yocto@yoctoproject.org" <yocto@yoctoproject.org>
Subject: Re: extend image.bbclass (or any bbclass file)
Date: Fri, 12 Jul 2013 15:02:27 +0200	[thread overview]
Message-ID: <2012763.5YFYIADNbT@fedora-fisso> (raw)
In-Reply-To: <CA+AhUGxQGeoTj=-1Be6rOeD0fENZuP3A4qG_vk6Hz+JwJiHdCQ@mail.gmail.com>

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

Really simple!!!
Excuse me for the dumb question and thanks a lot!
Cheers
Davide
In data venerdì 12 luglio 2013 13:22:32, Erik Botö ha scritto:


Hi, 


On Fri, Jul 12, 2013 at 1:11 PM, Davide Soldan <davide.soldan@kynetics.it[1]> wrote:


Hi to all,I'm trying to move, from outside to inside my recipes, all the changes I've done for my custom image.For example I changed the image.bbclass adding a function. But this file is outside of my recipes that are stored under my git repository. So I'd like to move this function from image.bbclass to another bbclass file under mi recipes directory.I tried to copy image.bbclass under my recipes directory, change its name, and references correctly, but duplicates functions gave me some errors:

ERROR: The function normal_groups defined in image.bbclass was already declared in image-custom.bbclass. BitBake has a global python function namespace so shared functions should be declared in a common include file rather than being duplicated, or if the functions are different, please use different function names.ERROR: The function complementary_globs defined in image.bbclass was already declared in image-custom.bbclass. BitBake has a global python function namespace so shared functions should be declared in a common include file rather than being duplicated, or if the functions are different, please use different function names.ERROR: The function get_devtable_list defined in image.bbclass was already declared in image-custom.bbclass. BitBake has a global python function namespace so shared functions should be declared in a common include file rather than being duplicated, or if the functions are different, please use different function names.

So I think there should be a way to append some code to image.bbclass as I can do with recipes and bbappend files...right? How I can do that? Or maybe there's another and better way to do that?Thanks to all!




Can't your image-custom.bbclass inherit image.bbclass and then just add the function you've added? Instead of replicating all stuff from image.bbclass in your class.


Cheers, 
Erik


 
_______________________________________________


yocto mailing list

yocto@yoctoproject.org[2]
https://lists.yoctoproject.org/listinfo/yocto[3]






--------
[1] mailto:davide.soldan@kynetics.it
[2] mailto:yocto@yoctoproject.org
[3] https://lists.yoctoproject.org/listinfo/yocto

[-- Attachment #2: Type: text/html, Size: 5892 bytes --]

  reply	other threads:[~2013-07-12 13:02 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-07-12 11:11 extend image.bbclass (or any bbclass file) Davide Soldan
2013-07-12 11:22 ` Erik Botö
2013-07-12 13:02   ` Davide Soldan [this message]
  -- strict thread matches above, loose matches on Subject: below --
2013-07-12 11:10 Davide Soldan
2013-07-12 13:35 ` Otavio Salvador
2013-07-12 13:42   ` Davide Soldan

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=2012763.5YFYIADNbT@fedora-fisso \
    --to=davide.soldan@kynetics.it \
    --cc=erik.boto@pelagicore.com \
    --cc=yocto@yoctoproject.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.