2 system.h -- system headers
4 Copyright (C) 1998-2004 Ivo Timmermans <ivo@tinc-vpn.org>
5 2004 Guus Sliepen <guus@tinc-vpn.org>
7 This program is free software; you can redistribute it and/or modify
8 it under the terms of the GNU General Public License as published by
9 the Free Software Foundation; either version 2 of the License, or
10 (at your option) any later version.
12 This program is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 GNU General Public License for more details.
17 You should have received a copy of the GNU General Public License
18 along with this program; if not, write to the Free Software
19 Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
24 #ifndef __TINC_SYSTEM_H__
25 #define __TINC_SYSTEM_H__
29 /* Include standard headers */
53 #ifdef HAVE_INTTYPES_H
57 /* Include system specific headers */
63 #ifdef HAVE_SYS_TIME_H
67 #ifdef HAVE_SYS_TYPES_H
68 #include <sys/types.h>
71 #ifdef HAVE_SYS_STAT_H
75 #ifdef HAVE_SYS_FILE_H
79 #ifdef HAVE_SYS_WAIT_H
83 #ifdef HAVE_SYS_IOCTL_H
84 #include <sys/ioctl.h>
87 #ifdef HAVE_SYS_PARAM_H
88 #include <sys/param.h>
91 /* SunOS really wants sys/socket.h BEFORE net/if.h,
92 and FreeBSD wants these lines below the rest. */
98 #ifdef HAVE_SYS_SOCKET_H
99 #include <sys/socket.h>
106 #ifdef HAVE_NETINET_IN_SYSTM_H
107 #include <netinet/in_systm.h>
110 #ifdef HAVE_NETINET_IN_H
111 #include <netinet/in.h>
114 #ifdef HAVE_ARPA_INET_H
115 #include <arpa/inet.h>
118 #ifdef HAVE_NETINET_IP_H
119 #include <netinet/ip.h>
122 #ifdef HAVE_NETINET_TCP_H
123 #include <netinet/tcp.h>
126 #ifdef HAVE_NETINET_IN6_H
127 #include <netinet/in6.h>
130 #ifdef HAVE_NETINET_IP6_H
131 #include <netinet/ip6.h>
136 #include <winsock2.h>
139 /* Include localisation support */
141 #include "support/gettext.h"
145 #ifndef HAVE_STRSIGNAL
146 # define strsignal(p) ""
149 /* Other functions */
155 #ifndef HAVE_SOCKLEN_T
156 typedef int socklen_t;
159 #endif /* __TINC_SYSTEM_H__ */