All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Robert P. J. Day" <rpjday@crashcourse.ca>
To: OE Core mailing list <openembedded-core@lists.openembedded.org>
Subject: Re: would replacing packagegroup names with "${PN}" be useless code churn?
Date: Tue, 15 Jul 2014 08:03:19 -0400 (EDT)	[thread overview]
Message-ID: <alpine.LFD.2.11.1407150759260.6548@localhost> (raw)
In-Reply-To: <alpine.LFD.2.11.1407150720001.5794@localhost>

On Tue, 15 Jul 2014, Robert P. J. Day wrote:

>
>   just my sheldon cooper-like OCD coming through again, but i long ago
> noted that some packagegroup files do this:
>
>   RDEPENDS_${PN} = "openssh"
>
> while others spell out (unnecessarily) the packagegroup name:
>
>   RDEPENDS_packagegroup-core-buildessential = "\
>
> when using ${PN} would have worked just fine. i'm a big fan of brevity
> so i can whip up a patch to shorter all those lines and make them
> clearer, unless folks think that's just unnecessary code churn.

  my own followup to this ... there's the occasional packagegroup file
for which this would cause numerous changes; take a look at
packagegroup-base.bb:

PACKAGES = ' \
            packagegroup-base \
            packagegroup-base-extended \
            packagegroup-distro-base \
            packagegroup-machine-base \
            \
            ${@bb.utils.contains("MACHINE_FEATURES", "acpi", "packagegroup-base-acpi", "",d)} \
            ${@bb.utils.contains("MACHINE_FEATURES", "alsa", "packagegroup-base-alsa", "", d)} \
            ${@bb.utils.contains("MACHINE_FEATURES", "apm", "packagegroup-base-apm", "", d)} \
            ${@bb.utils.contains("MACHINE_FEATURES", "ext2", "packagegroup-base-ext2", "", d)} \
            ${@bb.utils.contains("MACHINE_FEATURES", "vfat", "packagegroup-base-vfat", "", d)} \
            ${@bb.utils.contains("MACHINE_FEATURES", "irda", "packagegroup-base-irda", "",d)} \
            ${@bb.utils.contains("MACHINE_FEATURES", "keyboard", "packagegroup-base-keyboard", "", d)} \
            ... snip ...

  i'm guessing that one could shorten all that to:

PACKAGES = ' \
            ${PN} \
            ${PN}-extended \
            packagegroup-distro-base \
            packagegroup-machine-base \
            \
            ${@bb.utils.contains("MACHINE_FEATURES", "acpi", "${PN}-acpi", "",d)} \
            ${@bb.utils.contains("MACHINE_FEATURES", "alsa", "${PN}-alsa", "", d)} \
            ${@bb.utils.contains("MACHINE_FEATURES", "apm", "${PN}-apm", "", d)} \
            ${@bb.utils.contains("MACHINE_FEATURES", "ext2", "${PN}-ext2", "", d)} \
            ${@bb.utils.contains("MACHINE_FEATURES", "vfat", "${PN}-vfat", "", d)} \
            ${@bb.utils.contains("MACHINE_FEATURES", "irda", "${PN}-irda", "",d)} \
            ${@bb.utils.contains("MACHINE_FEATURES", "keyboard", "${PN}-keyboard", "", d)} \
            ... snip ...

so while most packagegroup files would just get a couple tweaked
lines, it's files like the above for which i asked whether this would
be just code churn. i'll let someone else make that decision.

rday

-- 

========================================================================
Robert P. J. Day                                 Ottawa, Ontario, CANADA
                        http://crashcourse.ca

Twitter:                                       http://twitter.com/rpjday
LinkedIn:                               http://ca.linkedin.com/in/rpjday
========================================================================



      reply	other threads:[~2014-07-15 12:03 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-07-15 11:23 would replacing packagegroup names with "${PN}" be useless code churn? Robert P. J. Day
2014-07-15 12:03 ` Robert P. J. Day [this message]

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=alpine.LFD.2.11.1407150759260.6548@localhost \
    --to=rpjday@crashcourse.ca \
    --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.