This is the mail archive of the
mailing list for the newlib project.
Re: [PATCH] Feature test macros: ctermid, cuserid
- From: Joel Sherrill <joel dot sherrill at oarcorp dot com>
- To: newlib at sourceware dot org
- Date: Sun, 22 May 2016 17:30:26 -0500
- Subject: Re: [PATCH] Feature test macros: ctermid, cuserid
- Authentication-results: sourceware.org; auth=none
- References: <CAG1-Us098Ap_h1QSxoE1iLgv=sf6McxKiTqW-JgB5JDQ6u5=0g at mail dot gmail dot com> <1463782304-12104-1-git-send-email-yselkowi at redhat dot com> <20160521165034 dot GA14025 at calimero dot vinschen dot de>
On 5/21/2016 11:50 AM, Corinna Vinschen wrote:
On May 20 17:11, Yaakov Selkowitz wrote:
The proper location for these functions has always been <stdio.h>, however
XPG4 and SUSv2 did mandate a duplicate declaration in <unistd.h>. cuserid
was dropped in SUSv3 (it was marked legacy since XPG4) and the ctermid
declaration in <unistd.h> was made optional and obsolete in SUSv4.
Thanks, just one point of discussion:
#define L_ctermid 16
I think we should get rid of the ifdef CYGWIN. This is a POSIX mandated
macro (for some given value of POSIX) so we should simply enable it for
all targets. If any system has a particular wish to change the numbers
we can adapt.
Speaking for RTEMS, our tools and OS are always built from source so
changing numbers is no big deal to us. We would **MUCH** rather use
common definitions and prototypes.
It really makes it easier for us all to have confidence we are following
standards when we share the same code.