Re: [hackers] [PATCH] [sbase] Include sysmacros.h directly rather than types.h

From: David Phillips <david_AT_sighup.nz>
Date: Tue, 2 Oct 2018 15:40:51 +1300

On Mon, Oct 01, 2018 at 06:35:13PM -0700, Michael Forney wrote:
> On 2018-10-01, David Phillips <david_AT_sighup.nz> wrote:
> > Hi,
> >
> > Bumping this patch since sbase master now fails to build against
> > glibc 2.28
> >
> > Let me know if there are any improvements that could be made.
> >
> > Thanks,
> > David
>
> I wish the #ifdef wasn't necessary, but it seems like the only way to
> use major/minor on glibc and non-glibc systems.
>
> As far as I can tell, glibc has had sys/sysmacros.h for a long time,
> so it should be okay to always include it when __GLIBC__ is defined.
>
> Rather than the if-else, I think we should always include sys/types.h,
> and also sys/sysmacros.h on glibc. I also think the comment is
> unnecessary. Do you mind if I apply with those two changes?

I agree with that logic, so long as that doesn't hurt BSD systems (I
can't recall at the moment if sys/types.h exists on BSD)

David
Received on Tue Oct 02 2018 - 04:40:51 CEST

This archive was generated by hypermail 2.3.0 : Tue Oct 02 2018 - 04:48:20 CEST