Merged silc_1_0_branch to trunk.
[silc.git] / includes / silcincludes.h.in
1 /*
2
3   silcincludes.h
4
5   Author: Pekka Riikonen <priikone@silcnet.org>
6
7   Copyright (C) 1997 - 2003 Pekka Riikonen
8
9   This program is free software; you can redistribute it and/or modify
10   it under the terms of the GNU General Public License as published by
11   the Free Software Foundation; version 2 of the License.
12
13   This program is distributed in the hope that it will be useful,
14   but WITHOUT ANY WARRANTY; without even the implied warranty of
15   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16   GNU General Public License for more details.
17
18 */
19 /*
20   This file includes common definitions for SILC. This file MUST be included
21   by all files in SILC (directly or through other global include file).
22 */
23
24 #ifndef SILCINCLUDES_H
25 #define SILCINCLUDES_H
26
27 #ifdef __cplusplus
28 extern "C" {
29 #endif
30
31 #define SILC_UNIX
32
33 #ifdef WIN32
34 #ifndef SILC_WIN32
35 #define SILC_WIN32
36 #undef SILC_UNIX
37 #endif
38 #endif
39
40 #if defined(__EPOC32__)
41 #ifndef SILC_EPOC
42 #define SILC_EPOC
43 #undef SILC_UNIX
44 #endif
45 #endif
46
47 #ifdef BEOS
48 #ifndef SILC_BEOS
49 #define SILC_BEOS
50 #undef SILC_UNIX
51 #endif
52 #elif defined(__BEOS__)
53 #ifndef SILC_BEOS
54 #define SILC_BEOS
55 #undef SILC_UNIX
56 #endif
57 #endif
58
59 #if defined(OS2)
60 #ifndef SILC_OS2
61 #define SILC_OS2
62 #undef SILC_UNIX
63 #endif
64 #endif
65
66 /* Types */
67 #define SILC_SIZEOF_LONG_LONG @SILC_SIZEOF_LONG_LONG@
68 #define SILC_SIZEOF_LONG @SILC_SIZEOF_LONG@
69 #define SILC_SIZEOF_INT @SILC_SIZEOF_INT@
70 #define SILC_SIZEOF_SHORT @SILC_SIZEOF_SHORT@
71 #define SILC_SIZEOF_CHAR @SILC_SIZEOF_CHAR@
72 #define SILC_SIZEOF_VOID_P @SILC_SIZEOF_VOID_P@
73
74 #if defined(HAVE_SILCDEFS_H) || defined(SILC_WIN32)
75 /* Automatically generated configuration header */
76 #include "silcdefs.h"
77 #endif /* HAVE_SILCDEFS_H */
78
79 /* Platform specific includes */
80
81 #if defined(SILC_WIN32)
82 #include "silcwin32.h"
83 #endif
84
85 #if defined(SILC_EPOC)
86 #include "silcepoc.h"
87 #endif
88
89 #if defined(SILC_BEOS)
90 #include "silcbeos.h"
91 #endif
92
93 #if defined(SILC_OS2)
94 #include "silcos2.h"
95 #endif
96
97 #ifndef DLLAPI
98 #define DLLAPI
99 #endif
100
101 #include <stdio.h>
102 #include <stdlib.h>
103 #include <string.h>
104 #include <stdarg.h>
105 #include <ctype.h>
106 #include <sys/types.h>
107 #include <sys/stat.h>
108 #include <time.h>
109
110 #ifdef HAVE_SIGNAL_H
111 #include <signal.h>
112 #endif
113
114 #ifdef HAVE_FCNTL_H
115 #include <fcntl.h>
116 #endif
117
118 #ifdef HAVE_ERRNO_H
119 #include <errno.h>
120 #endif
121
122 #ifdef HAVE_ASSERT_H
123 #include <assert.h>
124 #endif
125
126 #if !defined(SILC_WIN32)
127
128 #include <unistd.h>
129 #include <sys/time.h>
130 #include <pwd.h>
131 #include <grp.h>
132 #include <sys/times.h>
133
134 #ifdef HAVE_GETOPT_H
135 #include <getopt.h>
136 #endif
137
138 #ifdef SOCKS5
139 #include "socks.h"
140 #endif
141
142 #include <sys/socket.h>
143 #ifdef HAVE_NETINET_IN_H
144 #include <netinet/in.h>
145 #endif
146
147 #ifdef HAVE_XTI_H
148 #include <xti.h>
149 #else
150 #ifdef HAVE_NETINET_TCP_H
151 #include <netinet/tcp.h>
152 #endif
153 #endif
154
155 #ifdef HAVE_NETDB_H
156 #include <netdb.h>
157 #endif
158
159 #ifdef HAVE_ARPA_INET_H
160 #include <arpa/inet.h>
161 #endif
162
163 #ifdef HAVE_SYS_MMAN_H
164 #include <sys/mman.h>
165 #endif
166
167 #ifdef HAVE_DLFCN_H
168 #include <dlfcn.h>
169 #endif
170
171 #ifdef HAVE_LIMITS_H
172 #include <limits.h>
173 #endif
174
175 #ifndef HAVE_REGEX_H
176 #include "regex.h"
177 #else
178 #include <regex.h>
179 #endif
180
181 #ifdef SILC_HAVE_PTHREAD
182 #include <pthread.h>
183 #endif
184
185 #ifdef HAVE_STDDEF_H
186 #include <stddef.h>
187 #endif
188
189 #ifdef HAVE_TERMIOS_H
190 #include <termios.h>
191 #endif
192
193 #ifdef HAVE_UTIME_H
194 #include <utime.h>
195 #endif
196
197 #ifdef HAVE_ICONV_H
198 #include <iconv.h>
199 #endif
200
201 #ifdef HAVE_LOCALE_H
202 #include <locale.h>
203 #endif
204
205 #ifdef HAVE_LANGINFO_H
206 #include <langinfo.h>
207 #endif
208
209 #endif                          /* !SILC_WIN32 */
210
211 #ifndef HAVE_GETOPT_LONG
212 #include "getopt.h"
213 #endif
214
215 /* Include generic SILC type definitions */
216 #include "silctypes.h"
217 #include "silcversion.h"
218
219 /* Math library includes */
220 #include "silcmp.h"
221 #include "silcmath.h"
222
223 /* SILC util library includes */
224 #include "silcmemory.h"
225 #include "silcbuffer.h"
226 #include "silcbuffmt.h"
227
228 /* Crypto library includes */
229 #include "silccipher.h"
230 #include "silchash.h"
231 #include "silchmac.h"
232 #include "silcrng.h"
233 #include "silcpkcs.h"
234
235 /* More SILC util library includes */
236 #include "silcmutex.h"
237 #include "silcthread.h"
238 #include "silcschedule.h"
239 #include "silchashtable.h"
240 #include "silclog.h"
241 #include "silclist.h"
242 #include "silcdlist.h"
243 #include "silcnet.h"
244 #include "silcfileutil.h"
245 #include "silcstrutil.h"
246 #include "silcutil.h"
247 #include "silcconfig.h"
248 #include "silcprotocol.h"
249 #include "silcsockconn.h"
250 #include "silcvcard.h"
251 #include "silcapputil.h"
252
253 /* SILC core library includes */
254 #include "silcargument.h"
255 #include "silcstatus.h"
256 #include "silcid.h"
257 #include "silcidcache.h"
258 #include "silccommand.h"
259 #include "silcmessage.h"
260 #include "silcchannel.h"
261 #include "silcpacket.h"
262 #include "silcnotify.h"
263 #include "silcmode.h"
264 #include "silcauth.h"
265 #include "silcattrs.h"
266 #include "silcvcard.h"
267
268 #if defined(SILC_SIM)
269 /* SILC Module library includes */
270 #include "silcsim.h"
271 #include "silcsimutil.h"
272 #endif
273
274 /* SILC Key Exchange library includes */
275 #include "silcske.h"
276 #include "silcske_payload.h"
277 #include "silcske_groups.h"
278
279 /* SILC SFTP library */
280 #include "silcsftp.h"
281 #include "silcsftp_fs.h"
282
283 #ifdef __cplusplus
284 }
285 #endif
286
287 #endif /* SILCINCLUDES_H */