Path: blob/master/thirdparty/linuxbsd_headers/X11/Xosdefs.h
9898 views
/*1* O/S-dependent (mis)feature macro definitions2*3Copyright 1991, 1998 The Open Group45Permission to use, copy, modify, distribute, and sell this software and its6documentation for any purpose is hereby granted without fee, provided that7the above copyright notice appear in all copies and that both that8copyright notice and this permission notice appear in supporting9documentation.1011The above copyright notice and this permission notice shall be included in12all copies or substantial portions of the Software.1314THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR15IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,16FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE17OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN18AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN19CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.2021Except as contained in this notice, the name of The Open Group shall not be22used in advertising or otherwise to promote the sale, use or other dealings23in this Software without prior written authorization from The Open Group.24*/2526#ifndef _XOSDEFS_H_27# define _XOSDEFS_H_2829/*30* X_NOT_POSIX means does not have POSIX header files. Lack of this31* symbol does NOT mean that the POSIX environment is the default.32* You may still have to define _POSIX_SOURCE to get it.33*/343536# ifdef _SCO_DS37# ifndef __SCO__38# define __SCO__39# endif40# endif4142# ifdef __i386__43# ifdef SYSV44# if !defined(__SCO__) && \45!defined(__UNIXWARE__) && !defined(__sun)46# if !defined(_POSIX_SOURCE)47# define X_NOT_POSIX48# endif49# endif50# endif51# endif5253# ifdef __sun54/* Imake configs define SVR4 on Solaris, but cc & gcc only define __SVR455* This check allows non-Imake configured programs to build correctly.56*/57# if defined(__SVR4) && !defined(SVR4)58# define SVR4 159# endif60# ifdef SVR461/* define this to whatever it needs to be */62# define X_POSIX_C_SOURCE 199300L63# endif64# endif6566# ifdef WIN3267# ifndef _POSIX_68# define X_NOT_POSIX69# endif70# endif717273# ifdef __APPLE__74# define NULL_NOT_ZERO7576/* Defining any of these will sanitize the namespace to JUST want is defined by77* that particular standard. If that happens, we don't get some expected78* prototypes, typedefs, etc (like fd_mask). We can define _DARWIN_C_SOURCE to79* loosen our belts a tad.80*/81# if defined(_XOPEN_SOURCE) || defined(_POSIX_SOURCE) || defined(_POSIX_C_SOURCE)82# ifndef _DARWIN_C_SOURCE83# define _DARWIN_C_SOURCE84# endif85# endif8687# endif8889# ifdef __GNU__90# ifndef PATH_MAX91# define PATH_MAX 409692# endif93# ifndef MAXPATHLEN94# define MAXPATHLEN 409695# endif96# endif9798# if defined(__SCO__) || defined(__UNIXWARE__)99# ifndef PATH_MAX100# define PATH_MAX 1024101# endif102# ifndef MAXPATHLEN103# define MAXPATHLEN 1024104# endif105# endif106107# if defined(__OpenBSD__) || defined(__NetBSD__) || defined(__FreeBSD__) \108|| defined(__APPLE__) || defined(__DragonFly__)109# ifndef CSRG_BASED110# define CSRG_BASED111# endif112# endif113114#endif /* _XOSDEFS_H_ */115116117118