tech-toolchain archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: Host requirements to build the Tools binaries



On Tue, 2024-08-13 at 21:27 +0200, Jan-Benedict Glaw wrote:
> Hi!
> 
> Building with latest Debian "unstable" containers doesn't work for me
> right now, as strptime() (used in bin/date/date.c) isn't made visible
> through features.h pulled in via tools/compat/compat_defs.h . 

The Open Group's Single Unix Specification (a roll up of various C /
Unix specs and published as IEEE Std 1003.1-2017) says that in time.h
strptime "shall be declared as [a] function". That makes it sound like
a GNU libc bug to me. 

It seems that newer versions of GNU libc require _XOPEN_SOURCE to be
defined before #including time.h. This is not what the spec requires.
The spec states that _XOPEN_SOURCE is used to specify that your program
uses nothing beyond XSI. i.e. defining it should turn off library
extensions, not turn them on. 

I'm sure someone else here has seen this before and can say something
smarter than me.

Ngā mihi,
Lloyd



Home | Main Index | Thread Index | Old Index