All of lore.kernel.org
 help / color / mirror / Atom feed
From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH] rpi-userland: Add patches to fix compilation with musl libc
Date: Fri, 12 Sep 2014 17:11:06 +0200	[thread overview]
Message-ID: <20140912171106.246cfd12@free-electrons.com> (raw)
In-Reply-To: <4834283.TufUKxLIMj@hyperion>

Dear Maarten ter Huurne,

On Fri, 12 Sep 2014 16:56:37 +0200, Maarten ter Huurne wrote:

> That's what you'd expect from the HAVE_* name, but there isn't a timer_h 
> check in the rpi-userland build system. There is a hardcoded "CFLAGS+=-
> D_HAVE_TIMER_T" for a single application inside rpi-userland, the other 
> applications don't define it.
> 
> The reason I wrote "every application" is that this header can be indirectly 
> included by applications using EGL:
> 
> $ output/host/usr/bin/pkg-config --cflags egl
> -I/home/mth/pi/buildroot/output/host/usr/arm-pingux-linux-
> musleabihf/sysroot/usr/include/
> -I/home/mth/pi/buildroot/output/host/usr/arm-pingux-linux-
> musleabihf/sysroot/usr/include/interface/vcos/pthreads/
> -I/home/mth/pi/buildroot/output/host/usr/arm-pingux-linux-
> musleabihf/sysroot/usr/include/interface/vmcs_host/linux/
> 
> In theory -D_HAVE_TIMER_H could be added to Cflags in egl.pc, but that might 
> interfere with application packages. At least in the context of Buildroot, 
> where none of the supported libcs require this typedef, disabling this check 
> is the safest approach, in my opinion.
> 
> Also I wonder if there really is a platform on which this typedef helps: it 
> would only help on a platform that does implement POSIX timers (it's an 
> optional feature), but for some reason doesn't define timer_t. It just 
> doesn't sound very likely...
> 
> Looking at the header again, I see it doesn't actually use timer_t anywhere. 
> In fact, nowhere in the entire rpi_userland package is timer_t used. So the 
> whole check + typedef can just be removed.

Ok, thanks a lot for the explanation. Then just remove the definition,
and submit the patch upstream.

> 
> > Also, could you submit those patches upstream? We don't like much to
> > carry a lot of patches in Buildroot, so the more patches can be merged
> > upstream, the better.
> 
> https://github.com/raspberrypi/userland/issues/202
> https://github.com/raspberrypi/userland/pull/201

Great!

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

  reply	other threads:[~2014-09-12 15:11 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-09-12  1:45 [Buildroot] [PATCH] rpi-userland: Add patches to fix compilation with musl libc Maarten ter Huurne
2014-09-12  7:32 ` Thomas Petazzoni
2014-09-12 14:56   ` Maarten ter Huurne
2014-09-12 15:11     ` Thomas Petazzoni [this message]
2014-09-12 17:01       ` Maarten ter Huurne
2014-10-17 15:57         ` [Buildroot] [PATCH v3] rpi-userland: bump revision for musl compile fixes Maarten ter Huurne
2014-10-17 20:31           ` Yann E. MORIN
2014-10-18 11:05           ` Yann E. MORIN
2014-10-18 11:34             ` Yann E. MORIN
2014-10-18 12:15               ` Maarten ter Huurne
2014-10-18 13:02                 ` Yann E. MORIN
2014-10-18 16:46                   ` Maarten ter Huurne
2014-10-18 17:16                     ` Yann E. MORIN
2014-10-18 17:22                       ` Maarten ter Huurne
2014-10-18 17:58                     ` [Buildroot] [PATCH v4] rpi-userland: bump revision and add patch to fix compile with musl Maarten ter Huurne
2014-10-19 10:32                       ` Yann E. MORIN
2014-10-19 14:37                       ` Thomas Petazzoni

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=20140912171106.246cfd12@free-electrons.com \
    --to=thomas.petazzoni@free-electrons.com \
    --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 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.