Home | History | Annotate | Download | only in include
History log of /src/include/errno.h
RevisionDateAuthorComments
 1.11  03-Mar-2008  dholland Add a comment noting that the definition of __errno is now replicated in
signal.h. Per request of joerg@
 1.10  24-Feb-2008  dholland signal.h is not supposed to define errno, so use ___errno instead.
Adjust errno.h in a compatible fashion to avoid -Wredundant-decls issues.
I have run a build to check the tree for places where errno.h is missing,
and fixed the cases I found, but there might be more in MD code.
 1.9  24-Dec-2005  perry branches: 1.9.10; 1.9.16;
Remove leading __ from __(const|inline|signed|volatile) -- it is obsolete.
 1.8  13-Sep-2005  christos compat code reorg
 1.7  03-Feb-2005  perry de-__P -- the hack is long since useless. Discussed with christos,
matt, kleink, others. Approved by christos.
 1.6  07-Aug-2003  agc Move UCB-licensed code from 4-clause to 3-clause licence.

Patches provided by Joel Baker in PR 22270, verified by myself.
 1.5  28-Apr-2003  bjh21 Add a new feature-test macro, _NETBSD_SOURCE. If this is defined
by the application, all NetBSD interfaces are made visible, even
if some other feature-test macro (like _POSIX_C_SOURCE) is defined.
<sys/featuretest.h> defined _NETBSD_SOURCE if none of _ANSI_SOURCE,
_POSIX_C_SOURCE and _XOPEN_SOURCE is defined, so as to preserve
existing behaviour.

This has two major advantages:
+ Programs that require non-POSIX facilities but define _POSIX_C_SOURCE
can trivially be overruled by putting -D_NETBSD_SOURCE in their CFLAGS.
+ It makes most of the #ifs simpler, in that they're all now ORs of the
various macros, rather than having checks for (!defined(_ANSI_SOURCE) ||
!defined(_POSIX_C_SOURCE) || !defined(_XOPEN_SOURCE)) all over the place.

I've tried not to change the semantics of the headers in any case where
_NETBSD_SOURCE wasn't defined, but there were some places where the
current semantics were clearly mad, and retaining them was harder than
correcting them. In particular, I've mostly normalised things so that
_ANSI_SOURCE gets you the smallest set of stuff, then _POSIX_C_SOURCE,
_XOPEN_SOURCE and _NETBSD_SOURCE in that order.

Tested by building for vax, encouraged by thorpej, and uncontested in
tech-userlevel for a week.
 1.4  18-Dec-2000  christos protect against multiple declarations.
 1.3  13-Jun-2000  simonb Remove 'extern' from function declarations.
 1.2  21-Jan-2000  mycroft branches: 1.2.2;
Do the pthread errno hack. That is, *always* do:
#define errno (*__errno())
This is necessary to make non-threaded libraries (e.g. libX11) continue to
work correctly when linked with -lpthread. glibc also does this.
 1.1  12-Jan-1999  kleink branches: 1.1.2;
Separate the userland and libsa errno declarations from <sys/errno.h> into
their canonical places.
 1.1.2.1  23-Jan-2000  he Pull up revision 1.2 (requested by mycroft):
Always do the errno indirection hack, so that non-threaded
libraries get the right errno value when linked with -lpthread.
This means "always include <errno.h> and never declare errno
yourself".
 1.2.2.1  23-Jun-2000  minoura Sync w/ netbsd-1-5-base.
 1.9.16.1  24-Mar-2008  keiichi sync with head.
 1.9.10.1  23-Mar-2008  matt sync with HEAD

RSS XML Feed