Proper Conditionals for POSIX CX and XSI
Joel Sherrill
joel.sherrill@oarcorp.com
Thu Jul 18 16:01:00 GMT 2013
On 7/18/2013 9:49 AM, Joseph S. Myers wrote:
> On Thu, 18 Jul 2013, Joel Sherrill wrote:
>
>> FWIW glibc uses this for memccpy() which is an XSI routine. It is
>> not protected in newlib:
>>
>> #if defined __USE_SVID || defined __USE_BSD || defined __USE_XOPEN
>> extern void *memccpy (void *__restrict __dest, const void *__restrict __src,
>> int __c, size_t __n)
>> __THROW __nonnull ((1, 2));
>> #endif /* SVID. */
> There are a great many bugs in the header conditionals in glibc. You
> should refer to the relevant standards in each case rather than assuming
> the glibc headers are correct.
>
I am trying to write the rules to give to a future volunteer which
may or may not be me.
Is it possible to get group consensus on the conditionals which reflect
each of the columns in the API tables for SUS V4?
http://www.unix.org/version4/GS5_APIs.pdf
I am having trouble seeing how each API standard doesn't correspond
to a single conditional or maybe a POSIX standard range. And if it
was required by K&R or C89 or XXX, then it is unconditional.
--
Joel Sherrill, Ph.D. Director of Research & Development
joel.sherrill@OARcorp.com On-Line Applications Research
Ask me about RTEMS: a free RTOS Huntsville AL 35805
Support Available (256) 722-9985
More information about the Newlib
mailing list