Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Baruch Siach <baruch@tkos.co.il>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH] libinput: fix missing static_assert symbol
Date: Mon, 16 May 2016 09:36:41 +0300	[thread overview]
Message-ID: <20160516063641.GE2583@tarshish> (raw)
In-Reply-To: <20160515135505.71404da2@gmx.net>

Hi Peter,

On Sun, May 15, 2016 at 01:55:05PM +0200, Peter Seiderer wrote:
> On Sun, 15 May 2016 09:49:41 +0200, Peter Seiderer <ps.report@gmx.net> 
> wrote:
> > On Sun, 15 May 2016 08:34:04 +0300, Baruch Siach <baruch@tkos.co.il> 
> > wrote:
> > > On Sun, May 15, 2016 at 06:24:00AM +0300, Baruch Siach wrote:
> > > > static_assert() in from C++. Don't use it in C code.
> > > 
> > > This is wrong. As upstream developer Jonas ?dahl pointed out, C11 also defines 
> > > static_assert as a convenience macro for _Static_assert. uClibc{,-ng} however 
> > > that does not provide this macro. Would it make sense to disable libinput for 
> > > uClibc{,-ng}?
> > 
> > Or honor the second part of Jonas answer [1]: '... or define a no-op fallback
> > when it is not defined.'
> > 
> > Seems a less radical solution than disable complete package (plus dependencies)
> > for uClibc because of a minor issue?
> 
> Thinking more about it, I think your suggested patch is a good enough solution
> for buildroot purpose, so you can add my
> 
> Reviewed-by: Peter Seiderer <ps.report@gmx.net>
> 
> in case you change the patch descriptions to mention it is not a C++ thing but
> static_assert is from C11 standard [2] (and besides your patch changes the logic
> from compile time error to possible run time error (dependent on NDEBUG flag)...

That alone is a good enough reason to not apply this patch IMO. Upstream has a 
better suggestion along the line of no-op fallback. I plan to respin with that 
fix instead

Thanks for reviewing,
baruch

> [2] http://en.cppreference.com/w/c/error/static_assert
> > [1] 
> > https://lists.freedesktop.org/archives/wayland-devel/2016-May/028877.html

-- 
     http://baruch.siach.name/blog/                  ~. .~   Tk Open Systems
=}------------------------------------------------ooO--U--Ooo------------{=
   - baruch at tkos.co.il - tel: +972.2.679.5364, http://www.tkos.co.il -

      reply	other threads:[~2016-05-16  6:36 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-05-15  3:24 [Buildroot] [PATCH] libinput: fix missing static_assert symbol Baruch Siach
2016-05-15  5:34 ` Baruch Siach
2016-05-15  7:49   ` Peter Seiderer
2016-05-15 11:55     ` Peter Seiderer
2016-05-16  6:36       ` Baruch Siach [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=20160516063641.GE2583@tarshish \
    --to=baruch@tkos.co.il \
    --cc=buildroot@busybox.net \
    /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