Re: [PATCH 3/4] tools/nolibc: move FD_* definitions to sys/select.h
From: Willy Tarreau
Date: Sun Jun 29 2025 - 05:41:02 EST
On Sun, Jun 29, 2025 at 11:37:06AM +0200, Thomas Weißschuh wrote:
> On 2025-06-29 11:25:52+0200, Willy Tarreau wrote:
> > On Sun, Jun 29, 2025 at 10:53:34AM +0200, Thomas Weißschuh wrote:
> > > On 2025-06-29 10:46:28+0200, Willy Tarreau wrote:
> > > > On Mon, Jun 23, 2025 at 04:56:18AM +0200, Willy Tarreau wrote:
>
> <snip>
>
> > > > Trying it has reopened the circular dependencies can of worms :-(
> > > > It's the same problem as usual that we've worked around till now
> > > > by placing some types in types.h, except that this time fd_set is
> > > > defined based on the macros FD_* that I moved to sys/select.h.
> > >
> > > Can't fd_set also move to sys/select.h? This is how I read fd_set(3).
> >
> > That was what I did and precisely what was causing the problem. We
> > have sys.h defining select() with fd_set in it with sys/select not yet
> > being included. I moved sys.h after all sys/* and it broke something
> > else instead.
>
> Ah. Then move select() also into sys/select.h; where it belongs. :-)
For an unknown reason I thought we avoided to move the syscall definitions
there and only used sys/*, but I was apparently confused as we have exactly
that in prctl or wait. I can give that one a try again.
Thanks,
Willy