Rudiments
filedescriptorincludes.h
1 // Copyright (c) 2002 David Muse
2 // See the COPYING file for more information.
3 
4 #include <rudiments/private/dll.h>
5 #include <rudiments/private/inttypes.h>
6 
7 #include <rudiments/resultcodes.h>
8 
9 #include <sys/types.h>
10 
11 #ifdef RUDIMENTS_HAS_SSL
12  #include <openssl/ssl.h>
13 #endif
14 
15 #ifdef RUDIMENTS_HAVE_SYS_SOCKET_H
16  // IRIX appears to need this but OpenBSD can't
17  // find select() if it's still defined later
18  #ifndef _XOPEN_SOURCE
19  #define _XOPEN_SOURCE
20  #define UN_XOPEN_SOURCE
21  #endif
22  #include <sys/socket.h>
23  #ifdef UN_XOPEN_SOURCE
24  #undef _XOPEN_SOURCE
25  #endif
26 #endif
27 
28 // so STDIN_FILENO, STDOUT_FILENO, STDERR_FILENO will be defined if they need
29 // to be used by the calling program...
30 #ifdef RUDIMENTS_HAVE_UNISTD_H
31  #include <unistd.h>
32 #endif
33 #include <stdio.h>