1 /* Exim: OS-specific C header file for Linux */
3 /* Some weird variants may require invocation with C99 and features.h
4 inclusion to build, with the 64-bit arithmetic. Make compiler selection
5 their problem, but build anyway. */
11 #define GLIBC_IP_OPTIONS
13 #define HAVE_BSD_GETLOADAVG
14 #define HAVE_SYS_STATVFS_H
18 /* When using the DKIM, setting HAVE_LINUX_SENDFILE can increase
19 performance on outgoing mail a bit. Note: With older glibc versions
20 this setting will conflict with the _FILE_OFFSET_BITS=64 setting
21 defined as part of the Linux CFLAGS. */
23 /* #define HAVE_LINUX_SENDFILE */
25 #define F_FREESP O_TRUNC
26 typedef struct flock flock_t;
28 #define os_strsignal strsignal
31 #if defined(__linux__) || defined(__FreeBSD_kernel__) || defined(__NetBSD_kernel__)
32 #define SIOCGIFCONF_GIVES_ADDR
33 #define HAVE_SYS_MOUNT_H
36 #if defined(__linux__)
38 /* Some versions of Linux need explicit sync-ing of directories as well as
39 files. This setting requests that. If the directory is on NFS, it may not
40 be possible to sync it - in that case, Exim now should ignore the error. But
41 if you have problems in that area, try undefining this. But be aware that you
42 may be in a situation where files are not being properly "committed to stable
43 storage" as quickly as Exim thinks they are. */
45 #define NEED_SYNC_DIRECTORY
47 /* Other OS have "const" in here */
48 #define ICONV_ARG2_TYPE char **
50 #define os_find_running_interfaces os_find_running_interfaces_linux
52 /* Need a prototype for the Linux-specific function. The structure hasn't
53 been defined yet, so we need to pre-declare it. */
55 struct ip_address_item;
56 extern struct ip_address_item *os_find_running_interfaces_linux(void);
58 #endif /* __linux__ */