On Wed, 09 Jan 2019 17:22:36 +0100, Jay Foster wrote: > > > > On 1/9/2019 3:10 AM, Takashi Iwai wrote: > > On Tue, 08 Jan 2019 18:00:18 +0100, > > Jay Foster wrote: > >> I am attempting to build the 1.1.8 release of alsa-utils and getting > >> an error about POLLRDNORM (and others) undefined. This error comes > >> from axfer/waiter-select.c. axfer/waiter-select.c includes > >> "waiter.h", which includes "poll.h". This build is for a linux > >> target. > >> > >> poll.h includes sys/poll.h which includes bits/poll.h, which only > >> defines POLLRDNORM (and others) when __USE_XOPEN is defined (which it > >> is not). > >> > >> However, linux/poll.h includes asm/poll.h which includes > >> asm-generic/poll.h which does define POLLRDNORM (and others). > >> > >> Should I change my build to define__USE_XOPEN or should I patch > >> waiter.h to include linux/poll.h instead of just poll.h? > > Which libc are you using? The POSIX man page (man poll.h) mentions > > POLLRDNORM defined there, at least, on my system with glibc 2.27. > > > > > > thanks, > > > > Takashi > > > > > This is a legacy ARM product using glibc 2.9. Neither of the > approaches I mentioned above actually worked. <linux/poll.h> is the > kernel headers, which results in a duplicate definition of struct > pollfds. The other approach (I added 'CFLAGS=-D_XOPEN_SOURCE=500' to > the make command line, and other variations) failed elsewhere due to > missing or mismatched function prototypes (ref <features.h>). > > I got this to work by patching axfer/waiter.h to add the missing > defintions, based on those found in <asm-generic/poll.h>. I wonder what is supposed on such a system. poll() needs these POLL* constant definitions, and they aren't available by simple poll.h? That's weird. What does "man poll.h" say in your version? thanks, Takashi _______________________________________________ Alsa-devel mailing list Alsa-devel@xxxxxxxxxxxxxxxx http://mailman.alsa-project.org/mailman/listinfo/alsa-devel