All of lore.kernel.org
 help / color / mirror / Atom feed
From: Richard Purdie <richard.purdie@linuxfoundation.org>
To: Khem Raj <raj.khem@gmail.com>
Cc: Otavio Salvador <otavio.salvador@ossystems.com.br>,
	Otavio Salvador <otavio@ossystems.com.br>,
	OpenEmbedded Core Mailing List
	<openembedded-core@lists.openembedded.org>
Subject: Re: [PATCH] Rename 'BRANCH' variable to 'SRC_BRANCH' for clearness
Date: Sat, 22 Aug 2015 10:08:42 +0100	[thread overview]
Message-ID: <1440234522.12105.283.camel@linuxfoundation.org> (raw)
In-Reply-To: <F5709C6C-5297-49D4-B2BD-931B59837210@gmail.com>

On Fri, 2015-08-21 at 23:03 -0700, Khem Raj wrote:
> > On Aug 21, 2015, at 2:58 PM, Otavio Salvador <otavio.salvador@ossystems.com.br> wrote:
> > 
> > On Fri, Aug 21, 2015 at 6:49 PM, Khem Raj <raj.khem@gmail.com> wrote:
> >> 
> >>> On Aug 21, 2015, at 2:38 PM, Otavio Salvador <otavio@ossystems.com.br> wrote:
> >>> 
> >>> The 'BRANCH' variable name has no explicit relation with the
> >>> SRC_URI. Using 'SRC_BRANCH' makes it more obvious and easier to
> >>> identify.
> >> 
> >> Look good to me, just may be avoid ‘_’ and call it SRCBRANCH
> > 
> > I did this initially but looking at how it looks in the source code,
> > it seems SRC_BRANCH makes easier to spot the relation with SRC_URI. So
> > I took the second.
> 
> since bitbake use ‘_’ as a override separator, its less confusing if variables don’t have underscore in them
> for future collision.

Names with '_' in them might look better but there is a small price to
pay for it in that bitbake then has to track whether "BRANCH" is an
override. Obviously it does this in many cases already (e.g. URI from
SRC_URI) but when you've looked at what the datastore actually has to do
to keep the system working, you start to lean against creating more work
for it.

I continue to believe we should probably find a better syntax for
overrides. If someone had a good alternative, it would probably be worth
the pain of switching...

I'm not saying we shouldn't take the above patch here, just that this is
something which does have a cost and all the uses do mount up
significantly.

Cheers,

Richard



  reply	other threads:[~2015-08-22  9:09 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-08-21 21:38 [PATCH] Rename 'BRANCH' variable to 'SRC_BRANCH' for clearness Otavio Salvador
2015-08-21 21:49 ` Khem Raj
2015-08-21 21:58   ` Otavio Salvador
2015-08-22  4:20     ` Randy MacLeod
2015-08-22  6:03     ` Khem Raj
2015-08-22  9:08       ` Richard Purdie [this message]
2015-08-22 10:48         ` Otavio Salvador

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=1440234522.12105.283.camel@linuxfoundation.org \
    --to=richard.purdie@linuxfoundation.org \
    --cc=openembedded-core@lists.openembedded.org \
    --cc=otavio.salvador@ossystems.com.br \
    --cc=otavio@ossystems.com.br \
    --cc=raj.khem@gmail.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.