public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Mike Frysinger <vapier@gentoo.org>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH] dts/Makefile: Turn off system-/gcc-specific predefined macros
Date: Thu, 26 Jul 2012 12:23:20 -0400	[thread overview]
Message-ID: <201207261223.21738.vapier@gentoo.org> (raw)
In-Reply-To: <5010EC5E.40109@aon.at>

On Thursday 26 July 2012 03:06:06 Horst Kronstorfer wrote:
> On 07/25/2012 06:06 PM, Mike Frysinger wrote:
> > On Tuesday 24 July 2012 15:38:55 Horst Kronstorfer wrote:
> >> On 07/24/2012 05:28 PM, Mike Frysinger wrote:
> >>> On Tuesday 24 July 2012 06:11:04 Horst Kronstorfer wrote:
> >>>> On 07/19/2012 05:22 AM, Mike Frysinger wrote:
> >>>>> On Friday 13 July 2012 09:03:40 Horst Kronstorfer wrote:
> >>>>>> Add '-undef' to DTS_CPPFLAGS to avoid unwanted expansion of dts
> >>>>>> content that matches system-specific or gcc-specific predefined
> >>>>>> macros.
> >>>>>> 
> >>>>>> Example: A number of PowerPC related *.dts files in the kernel
> >>>>>> define a property named 'linux,network-index' which (w/o '-undef')
> >>>>>> is expanded to '1,network-index' by the preprocessor because of
> >>>>>> '#define linux 1.'
> >>>>> 
> >>>>> i think you should use -ansi instead.  that's what we use in other
> >>>>> places for the same reason.
> >>>> 
> >>>> this would increase the probability of a name clash.
> >>> 
> >>> no idea what you're talking about.  have you actually looked at the
> >>> output of `gcc -E -dD -ansi` ?
> >> 
> >> $ gcc -E -dM -ansi - </dev/null | wc -l
> >> 229
> >> $ gcc -E -dM -undef - </dev/null | wc -l
> >> 2
> > 
> > and ?  did you *look* at the output ?  they're all of the form __foo__.
> 
> i already considered that.
> 
> > do any device trees really use __foo__ names ?  i don't think so.
> 
> is there any drawback using '-undef' in this particular case besides
> "we use -ansi in other places for the same reason"?

we use -ansi because it's more portable and has known behavior in the build 
system
-mike
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: This is a digitally signed message part.
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20120726/1480d2fb/attachment.pgp>

  reply	other threads:[~2012-07-26 16:23 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-07-13 13:03 [U-Boot] [PATCH] dts/Makefile: Turn off system-/gcc-specific predefined macros Horst Kronstorfer
2012-07-19  3:22 ` Mike Frysinger
2012-07-24 10:11   ` Horst Kronstorfer
2012-07-24 15:28     ` Mike Frysinger
2012-07-24 19:38       ` Horst Kronstorfer
2012-07-25 16:06         ` Mike Frysinger
2012-07-26  7:06           ` Horst Kronstorfer
2012-07-26 16:23             ` Mike Frysinger [this message]
2012-07-26 21:26 ` [U-Boot] [PATCH,v2] dts/Makefile: Turn off some " Horst Kronstorfer
2012-08-10 21:53   ` [U-Boot] [PATCH, v2] " Wolfgang Denk
2012-08-10 21:50 ` [U-Boot] [PATCH] dts/Makefile: Turn off system-/gcc-specific " Wolfgang Denk

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=201207261223.21738.vapier@gentoo.org \
    --to=vapier@gentoo.org \
    --cc=u-boot@lists.denx.de \
    /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