Re: BUG #18026: compile error / fe-auth.c:807:64: error: 'CHAR_BIT' undeclared (first use in this function)

Tom Lane <tgl@sss.pgh.pa.us>

From: Tom Lane <tgl@sss.pgh.pa.us>
To: Marcel Hofstetter <hofstetter@jomasoft.ch>
Cc: pgsql-bugs@lists.postgresql.org
Date: 2023-07-17T18:55:50Z
Lists: pgsql-bugs
Marcel Hofstetter <hofstetter@jomasoft.ch> writes:
> Am 17.07.2023 um 18:15 schrieb Tom Lane:
>> Hmm.  This problem seems straightforward enough to fix, but what I
>> don't understand is why we've not seen it already.  We do have a
>> buildfarm animal running on Solaris 11.4 [1], and it's not unhappy.

> I'm the owner of margay. No idea why it works there.
> buildfarm tests and building this beta2 is on the same system.

[ noses around a bit... ]  I see that margay uses --with-gssapi,
could that be the difference?  fe-auth.c pulls in a fair amount
more stuff if ENABLE_GSS is set than if it isn't, though I did
not check to see if <limits.h> is in there in particular.

			regards, tom lane



Commits

  1. Include <limits.h> in fe-auth.c, to get CHAR_BIT reliably.