From: Lennart Poettering <mznyfn@0pointer.de>
To: alsa-devel@alsa-project.org
Subject: Re: [PATCH 3/3] Define _GNU_SOURCE so that <fcntl.h> gives O_CLOEXEC
Date: Sun, 8 Nov 2009 16:40:17 +0100 [thread overview]
Message-ID: <20091108154017.GE25366@tango.0pointer.de> (raw)
In-Reply-To: <200911081723.37763.remi@remlab.net>
On Sun, 08.11.09 17:23, Rémi Denis-Courmont (remi@remlab.net) wrote:
>
> Le dimanche 8 novembre 2009 16:49:37 Lennart Poettering, vous avez écrit :
> > On Thu, 05.11.09 21:17, Rémi Denis-Courmont (remi@remlab.net) wrote:
> > > Signed-off-by: Rémi Denis-Courmont <remi@remlab.net>
> > > ---
> > > configure.in | 2 ++
> > > 1 files changed, 2 insertions(+), 0 deletions(-)
> > >
> > > diff --git a/configure.in b/configure.in
> > > index a455de1..cc8950f 100644
> > > --- a/configure.in
> > > +++ b/configure.in
> > > @@ -38,6 +38,8 @@ then
> > > AC_MSG_RESULT($CC)
> > > fi
> > >
> > > +CFLAGS="$CFLAGS -D_GNU_SOURCE"
> >
> > There's acually an autoconf macro for this. AC_GNU_SOURCE. And even
> > better than that is usually AC_SYSTEM_EXTENSIONS.
>
> AC_SYSTEM_EXTENSIONS is not much extra help from AC_GNU_SOURCE in a Linux-only
> library.
In the past there was some work to port it to some BSD iirc, using the
OSS backend that is currently in alsa-plugins. Not that I cared a tiny
bit about BSD but I generally think that if there are two otherwise
equal options one should pick the portable one. But then again, this
certainly doesn't matter much.
> alsa-lib does not systematically include <config.h> first, so neither
> of them will work anyway.
A nice fix for that could be simply adding -include
$(top_builddir)/config.h to AM_CPPFLAGS. A couple of packages do that
now, e.g. udev.
Lennart
--
Lennart Poettering Red Hat, Inc.
lennart [at] poettering [dot] net
http://0pointer.net/lennart/ GnuPG 0x1A015CC4
next prev parent reply other threads:[~2009-11-08 15:40 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-11-05 19:16 [PATCHv2 alsa-lib 0/3] Close-on-exec flag for device nodes Rémi Denis-Courmont
2009-11-05 19:17 ` [PATCH 1/3] Open device nodes with close-on-exec flag Rémi Denis-Courmont
2009-11-06 10:06 ` Takashi Iwai
2009-11-07 19:28 ` Rémi Denis-Courmont
2009-11-07 19:29 ` Rémi Denis-Courmont
2009-11-08 8:29 ` Takashi Iwai
2009-11-05 19:17 ` [PATCH 2/3] Remove old commented-out FD_CLOEXEC code Rémi Denis-Courmont
2009-11-05 19:17 ` [PATCH 3/3] Define _GNU_SOURCE so that <fcntl.h> gives O_CLOEXEC Rémi Denis-Courmont
2009-11-08 14:49 ` Lennart Poettering
2009-11-08 15:23 ` Rémi Denis-Courmont
2009-11-08 15:40 ` Lennart Poettering [this message]
-- strict thread matches above, loose matches on Subject: below --
2009-11-04 18:38 [RESEND] [PATCH 0/3] Close alsa-lib file descriptors on exec Rémi Denis-Courmont
2009-11-04 18:38 ` [PATCH 3/3] Define _GNU_SOURCE so that <fcntl.h> gives O_CLOEXEC Rémi Denis-Courmont
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=20091108154017.GE25366@tango.0pointer.de \
--to=mznyfn@0pointer.de \
--cc=alsa-devel@alsa-project.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox