📄 conf.h
字号:
/* SCO UNIX 3.2v4.0 Open Desktop 2.0 and earlier */
#ifdef _SCO_unix_
# include <sys/stream.h> /* needed for IP_SRCROUTE */
# define SYSTEM5 1 /* include all the System V defines */
# define HASGETUSERSHELL 0 /* does not have getusershell(3) call */
# define NOFTRUNCATE 0 /* has (simulated) ftruncate call */
# define USE_SIGLONGJMP 1 /* sigsetjmp needed for signal handling */
# define MAXPATHLEN PATHSIZE
# define SFS_TYPE SFS_4ARGS /* use <sys/statfs.h> 4-arg impl */
# define SFS_BAVAIL f_bfree /* alternate field name */
# define SPT_TYPE SPT_SCO /* write kernel u. area */
# define TZ_TYPE TZ_TM_NAME /* use tm->tm_name */
# define UID_T uid_t
# define GID_T gid_t
# define GIDSET_T gid_t
# define _PATH_UNIX "/unix"
# ifndef _PATH_VENDOR_CF
# define _PATH_VENDOR_CF "/usr/lib/sendmail.cf"
# endif /* ! _PATH_VENDOR_CF */
# ifndef _PATH_SENDMAILPID
# define _PATH_SENDMAILPID "/etc/sendmail.pid"
# endif /* ! _PATH_SENDMAILPID */
/* stuff fixed in later releases */
# ifndef _SCO_unix_4_2
# define SYS5SIGNALS 1 /* SysV signal semantics -- reset on each sig */
# endif /* ! _SCO_unix_4_2 */
# ifndef _SCO_DS
# define ftruncate chsize /* use chsize(2) to emulate ftruncate */
# define NEEDFSYNC 1 /* needs the fsync(2) call stub */
# define NETUNIX 0 /* no unix domain socket support */
# define LA_TYPE LA_SHORT
# endif /* ! _SCO_DS */
#endif /* _SCO_unix_ */
/*
** ISC (SunSoft) Unix.
**
** Contributed by J.J. Bailey <jjb@jagware.bcc.com>
*/
#ifdef ISC_UNIX
# include <net/errno.h>
# include <sys/stream.h> /* needed for IP_SRCROUTE */
# include <sys/bsdtypes.h>
# define SYSTEM5 1 /* include all the System V defines */
# define SYS5SIGNALS 1 /* SysV signal semantics -- reset on each sig */
# define HASGETUSERSHELL 0 /* does not have getusershell(3) call */
# define HASSETREUID 1 /* has setreuid(2) call */
# define NEEDFSYNC 1 /* needs the fsync(2) call stub */
# define NETUNIX 0 /* no unix domain socket support */
# define MAXPATHLEN 1024
# define LA_TYPE LA_SHORT
# define SFS_TYPE SFS_STATFS /* use <sys/statfs.h> statfs() impl */
# define SFS_BAVAIL f_bfree /* alternate field name */
# define _PATH_UNIX "/unix"
# ifndef _PATH_VENDOR_CF
# define _PATH_VENDOR_CF "/usr/lib/sendmail.cf"
# endif /* ! _PATH_VENDOR_CF */
# ifndef _PATH_SENDMAILPID
# define _PATH_SENDMAILPID "/etc/sendmail.pid"
# endif /* ! _PATH_SENDMAILPID */
#endif /* ISC_UNIX */
/*
** Altos System V (5.3.1)
** Contributed by Tim Rice <tim@trr.metro.net>.
*/
#ifdef ALTOS_SYSTEM_V
# include <sys/stream.h>
# include <limits.h>
# define SYSTEM5 1 /* include all the System V defines */
# define SYS5SIGNALS 1 /* SysV signal semantics -- reset on each sig */
# define HASGETUSERSHELL 0 /* does not have getusershell(3) call */
# define WAITUNION 1 /* use "union wait" as wait argument type */
# define NEEDFSYNC 1 /* no fsync(2) in system library */
# define NEEDSTRSTR 1 /* need emulation of the strstr(3) call */
# define NOFTRUNCATE 1 /* do not have ftruncate(2) */
# define MAXPATHLEN PATH_MAX
# define LA_TYPE LA_SHORT
# define SFS_TYPE SFS_STATFS /* use <sys/statfs.h> statfs() impl */
# define SFS_BAVAIL f_bfree /* alternate field name */
# define TZ_TYPE TZ_TZNAME /* use tzname[] vector */
# define NETUNIX 0 /* no unix domain socket support */
# undef WIFEXITED
# undef WEXITSTATUS
# define strtoul strtol /* gcc library bogosity */
typedef unsigned short uid_t;
typedef unsigned short gid_t;
typedef short pid_t;
typedef unsigned long mode_t;
/* some stuff that should have been in the include files */
extern char *malloc();
extern struct passwd *getpwent();
extern struct passwd *getpwnam();
extern struct passwd *getpwuid();
extern char *getenv();
extern struct group *getgrgid();
extern struct group *getgrnam();
#endif /* ALTOS_SYSTEM_V */
/*
** ConvexOS 11.0 and later
**
** "Todd C. Miller" <millert@mroe.cs.colorado.edu> claims this
** works on 9.1 as well.
**
** ConvexOS 11.5 and later, should work on 11.0 as defined.
** For pre-ConvexOOS 11.0, define NEEDGETOPT, undef IDENTPROTO
**
** Eric Schnoebelen (eric@cirr.com) For CONVEX Computer Corp.
** (now the CONVEX Technologies Center of Hewlett Packard)
*/
#ifdef _CONVEX_SOURCE
# define HASGETDTABLESIZE 1 /* has getdtablesize(2) */
# define HASINITGROUPS 1 /* has initgroups(3) */
# define HASUNAME 1 /* use System V uname(2) system call */
# define HASSETSID 1 /* has POSIX setsid(2) call */
# define HASUNSETENV 1 /* has unsetenv(3) */
# define HASFLOCK 1 /* has flock(2) */
# define HASSETRLIMIT 1 /* has setrlimit(2) */
# define HASSETREUID 1 /* has setreuid(2) */
# define BROKEN_RES_SEARCH 1 /* res_search(unknown) returns h_error=0 */
# define NEEDPUTENV 1 /* needs putenv (written in terms of setenv) */
# define NEEDGETOPT 0 /* need replacement for getopt(3) */
# define IP_SRCROUTE 0 /* Something is broken with getsockopt() */
# define LA_TYPE LA_FLOAT
# define SFS_TYPE SFS_VFS /* use <sys/vfs.h> statfs() implementation */
# ifndef _PATH_VENDOR_CF
# define _PATH_VENDOR_CF "/usr/lib/sendmail.cf"
# endif /* ! _PATH_VENDOR_CF */
# ifndef S_IREAD
# define S_IREAD _S_IREAD
# define S_IWRITE _S_IWRITE
# define S_IEXEC _S_IEXEC
# define S_IFMT _S_IFMT
# define S_IFCHR _S_IFCHR
# define S_IFBLK _S_IFBLK
# endif /* ! S_IREAD */
# ifndef TZ_TYPE
# define TZ_TYPE TZ_TIMEZONE
# endif /* ! TZ_TYPE */
# ifndef IDENTPROTO
# define IDENTPROTO 1
# endif /* ! IDENTPROTO */
# ifndef SHARE_V1
# define SHARE_V1 1 /* version 1 of the fair share scheduler */
# endif /* ! SHARE_V1 */
# if !defined(__GNUC__ )
# define UID_T int /* GNUC gets it right, ConvexC botches */
# define GID_T int /* GNUC gets it right, ConvexC botches */
# endif /* !defined(__GNUC__ ) */
# if SECUREWARE
# define FORK fork /* SecureWare wants the real fork! */
# else /* SECUREWARE */
# define FORK vfork /* the rest of the OS versions don't care */
# endif /* SECUREWARE */
#endif /* _CONVEX_SOURCE */
/*
** RISC/os 4.52
**
** Gives a ton of warning messages, but otherwise compiles.
*/
#ifdef RISCOS
# define HASUNSETENV 1 /* has unsetenv(3) call */
# ifndef HASFLOCK
# define HASFLOCK 1 /* has flock(2) call */
# endif /* ! HASFLOCK */
# define WAITUNION 1 /* use "union wait" as wait argument type */
# define NEEDGETOPT 1 /* need a replacement for getopt(3) */
# define NEEDPUTENV 1 /* need putenv(3) call */
# define NEEDSTRSTR 1 /* need emulation of the strstr(3) call */
# define SFS_TYPE SFS_VFS /* use <sys/vfs.h> statfs() implementation */
# define LA_TYPE LA_INT
# define LA_AVENRUN "avenrun"
# define _PATH_UNIX "/unix"
# undef WIFEXITED
# define setpgid setpgrp
typedef int pid_t;
# define SIGFUNC_DEFINED
# define SIGFUNC_RETURN (0)
# define SIGFUNC_DECL int
typedef int (*sigfunc_t)();
extern char *getenv();
extern void *malloc();
/* added for RISC/os 4.01...which is dumber than 4.50 */
# ifdef RISCOS_4_0
# ifndef ARBPTR_T
# define ARBPTR_T char *
# endif /* ! ARBPTR_T */
# undef HASFLOCK
# define HASFLOCK 0
# endif /* RISCOS_4_0 */
# include <sys/time.h>
#endif /* RISCOS */
/*
** Linux 0.99pl10 and above...
**
** Thanks to, in reverse order of contact:
**
** John Kennedy <warlock@csuchico.edu>
** Andrew Pam <avatar@aus.xanadu.com>
** Florian La Roche <rzsfl@rz.uni-sb.de>
** Karl London <karl@borg.demon.co.uk>
**
** Last compiled against: [07/21/98 @ 11:47:34 AM (Tuesday)]
** sendmail 8.9.1 bind-8.1.2 db-2.4.14
** gcc-2.8.1 glibc-2.0.94 linux-2.1.109
**
** NOTE: Override HASFLOCK as you will but, as of 1.99.6, mixed-style
** file locking is no longer allowed. In particular, make sure
** your DBM library and sendmail are both using either flock(2)
** *or* fcntl(2) file locking, but not both.
*/
#ifdef __linux__
# include <linux/version.h>
# if !defined(KERNEL_VERSION) /* not defined in 2.0.x kernel series */
# define KERNEL_VERSION(a,b,c) (((a) << 16) + ((b) << 8) + (c))
# endif /* KERNEL_VERSION */
# define BSD 1 /* include BSD defines */
# define USESETEUID 0 /* Have it due to POSIX, but doesn't work */
# define NEEDGETOPT 1 /* need a replacement for getopt(3) */
# define HASUNAME 1 /* use System V uname(2) system call */
# define HASUNSETENV 1 /* has unsetenv(3) call */
# ifndef HASSNPRINTF
# define HASSNPRINTF 1 /* has snprintf(3) and vsnprintf(3) */
# endif /* ! HASSNPRINTF */
# define ERRLIST_PREDEFINED /* don't declare sys_errlist */
# define GIDSET_T gid_t /* from <linux/types.h> */
# define HASGETUSERSHELL 0 /* getusershell(3) broken in Slackware 2.0 */
# ifndef IP_SRCROUTE
# define IP_SRCROUTE 0 /* linux <= 1.2.8 doesn't support IP_OPTIONS */
# endif /* ! IP_SRCROUTE */
# ifndef HAS_IN_H
# define HAS_IN_H 1 /* use netinet/in.h */
# endif /* ! HAS_IN_H */
# define USE_SIGLONGJMP 1 /* sigsetjmp needed for signal handling */
# ifndef HASFLOCK
# if LINUX_VERSION_CODE < 66399
# define HASFLOCK 0 /* flock(2) is broken after 0.99.13 */
# else /* LINUX_VERSION_CODE < 66399 */
# define HASFLOCK 1 /* flock(2) fixed after 1.3.95 */
# endif /* LINUX_VERSION_CODE < 66399 */
# endif /* ! HASFLOCK */
# ifndef LA_TYPE
# define LA_TYPE LA_PROCSTR
# endif /* ! LA_TYPE */
# define SFS_TYPE SFS_VFS /* use <sys/vfs.h> statfs() impl */
# define SPT_PADCHAR '\0' /* pad process title with nulls */
# if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,0,0))
# ifndef HASURANDOMDEV
# define HASURANDOMDEV 1 /* 2.0 (at least) has linux/drivers/char/random.c */
# endif /* ! HASURANDOMDEV */
# endif /* LINUX_VERSION_CODE */
# ifndef TZ_TYPE
# define TZ_TYPE TZ_NONE /* no standard for Linux */
# endif /* ! TZ_TYPE */
# ifndef _PATH_SENDMAILPID
# define _PATH_SENDMAILPID "/var/run/sendmail.pid"
# endif /* ! _PATH_SENDMAILPID */
# include <sys/sysmacros.h>
# undef atol /* wounded in <stdlib.h> */
# if NETINET6
/*
** Linux doesn't have a good way to tell userland what interfaces are
** IPv6-capable. Therefore, the BIND resolver can not determine if there
** are IPv6 interfaces to honor AI_ADDRCONFIG. Unfortunately, it assumes
** that none are present. (Excuse the macro name ADDRCONFIG_IS_BROKEN.)
*/
# define ADDRCONFIG_IS_BROKEN 1
/*
** Indirectly included from glibc's <feature.h>. IPv6 support is native
** in 2.1 and later, but the APIs appear before the functions.
*/
# if defined(__GLIBC__) && defined(__GLIBC_MINOR__)
# define GLIBC_VERSION ((__GLIBC__ << 8) + __GLIBC_MINOR__)
# if (GLIBC_VERSION >= 0x201)
# undef IPPROTO_ICMPV6 /* linux #defines, glibc enums */
# else /* (GLIBC_VERSION >= 0x201) */
# include <linux/in6.h> /* IPv6 support */
# endif /* (GLIBC_VERSION >= 0x201) */
# if (GLIBC_VERSION == 0x201 && !defined(NEEDSGETIPNODE))
/* Have APIs in <netdb.h>, but no support in glibc */
# define NEEDSGETIPNODE 1
# endif /* (GLIBC_VERSION == 0x201 && ! NEEDSGETIPNODE) */
# undef GLIBC_VERSION
# endif /* defined(__GLIBC__) && defined(__GLIBC_MINOR__) */
# endif /* NETINET6 */
# ifndef HASFCHOWN
# define HASFCHOWN 1 /* fchown(2) */
# endif /* ! HASFCHOWN */
#endif /* __linux__ */
/*
** DELL SVR4 Issue 2.2, and others
** From Kimmo Suominen <kim@grendel.lut.fi>
**
** It's on #ifdef DELL_SVR4 because Solaris also gets __svr4__
** defined, and the definitions conflict.
**
** Peter Wemm <peter@perth.DIALix.oz.au> claims that the setreuid
** trick works on DELL 2.2 (SVR4.0/386 version 4.0) and ESIX 4.0.3A
** (SVR4.0/386 version 3.0).
*/
#ifdef DELL_SVR4
/* no changes necessary */
/* see general __svr4__ defines below */
#endif /* DELL_SVR4 */
/*
** Apple A/UX 3.0
*/
#ifdef _AUX_SOURCE
# include <sys/sysmacros.h>
# define BSD /* has BSD routines */
# define HASSETRLIMIT 0 /* ... but not setrlimit(2) */
# define BROKEN_RES_SEARCH 1 /* res_search(unknown) returns h_errno=0 */
# define BOGUS_O_EXCL 1 /* exclusive open follows symlinks */
# define HASUNAME 1 /* use System V uname(2) system call */
# define HASFCHMOD 1 /* has fchmod(2) syscall */
# define HASINITGROUPS 1 /* has initgroups(3) call */
# define HASSETVBUF 1 /* has setvbuf(3) in libc */
# define HASSTRERROR 1 /* has strerror(3) */
# define SIGFUNC_DEFINED /* sigfunc_t already defined */
# define SIGFUNC_RETURN /* POSIX-mode */
# define SIGFUNC_DECL void /* POSIX-mode */
# define ERRLIST_PREDEFINED 1
# ifndef IDENTPROTO
# define IDENTPROTO 0 /* TCP/IP implementation is broken */
# endif /* ! IDENTPROTO */
# ifndef LA_TYPE
# define LA_TYPE LA_INT
# define FSHIFT 16
# endif /* ! LA_TYPE */
# define LA_AVENRUN "avenrun"
# define SFS_TYPE SFS_VFS /* use <sys/vfs.h> statfs() implementation */
# define TZ_TYPE TZ_TZNAME
# ifndef _PATH_UNIX
# define _PATH_UNIX "/unix" /* should be in <paths.h> */
# endif /* ! _PATH_UNIX */
# ifndef _PATH_VENDOR_CF
# define _PATH_VENDOR_CF "/usr/lib/sendmail.cf"
# endif /* ! _PATH_VENDOR_CF */
# undef WIFEXITED
# undef WEXITSTATUS
#endif /* _AUX_SOURCE */
/*
** Encore UMAX V
**
** Not extensively tested.
*/
#ifdef UMAXV
# define HASUNAME 1 /* use System V uname(2) system call */
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -